Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Documentation

Author
Message
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 6th Jan 2017 08:45
We would like to get some feedback on the state of AGK's documentation so that we can figure out what needs improving.

Do you feel as though the documentation is lacking in any ways?
Would we benefit from having tutorials covering specific functionality?
Would it be useful to have guides showing how to make simple games as a way of getting started?
Might the documentation benefit from many more examples showing how to use specific commands?
Would the addition of video tutorials be helpful?
For a beginner do you feel the documentation is adequate?
Are enough advanced topics covered?

Please let us know your thoughts on the above questions and anything else that comes to mind.
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 6th Jan 2017 08:53
I feel the documentation is alright. Could do with more examples for the commands that don't have any, but otherwise it does what it needs to.
bjadams
AGK Backer
16
Years of Service
User Offline
Joined: 29th Mar 2008
Location:
Posted: 6th Jan 2017 09:38
After updating the text documentation maybe you can do a series of basic game programming videos for beginners, as it will boost new users
Kevin Cross
20
Years of Service
User Offline
Joined: 15th Nov 2003
Location: London, UK
Posted: 6th Jan 2017 09:39 Edited at: 6th Jan 2017 09:52
I also feel the documentation is adequate as well as the example projects enclosed with AGK. It's much easier to navigate too with the recent addition of "Search Commands".

I remember learning from the documentation and examples when I started using AppGameKit 1.

I did have a bit of problem with implementing in-apps. For this I had to browse the forums for a better understanding, so maybe if there was a good example and better documentation for that that would be beneficial to beginners. I was close to buying one of the official books for it but it didn't look like they covered in-apps either based on the contents list on Steam.
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 6th Jan 2017 09:40
I agree with Mobiius we could use some more small examples, I usually look on the forums for a new command when I'm trying to use it.
The problem I find is the command don't always have meaning until you've used it atleast once. No fault of the names its more some of the effects
we may want to use, a person such as myself may never have heard of the effect. (hence why there are many forum posts asking for things that
are already covered under a different name) not so sure how this could be improved tho.

Keep up the great work AppGameKit is truly a great powerful language

fubar
Creative Magic Man
11
Years of Service
User Offline
Joined: 14th Nov 2012
Location: Frinton On Sea, Essex, UK
Posted: 6th Jan 2017 10:10 Edited at: 6th Jan 2017 12:30
As others have said, fill in the commands that do not have any help at the moment ( ie. Gamecenter commands) & give examples
Van B
Moderator
21
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 6th Jan 2017 10:19
I would prefer to see small, concise examples for each command - without having to be an actual functioning piece of code, but then had a link to a functional example. Most of the time I just want to see the syntax and basics and how it can apply to what I am doing... I mean, the per-command example could be short and descriptive, but then link to a showcase example. For instance, all the text commands could have a combined showcase example that can go into depth with the more obscure commands. If people need to experiment, learn how it works, see what it can do, then they can check the showcase example.

So much smaller and less functional code snippet per command, but with a link to a showcase example that goes into detail... chances are that if we are looking at the docs for a specific command, we are more interested in syntax than an example. To me at least, it seems that the AppGameKit commands either have a big example or no example at all... the examples are good but it seems to me that it's a waste of effort to have a full example of every command, there's duplication and procrastination to consider - mostly I just need to know how the command is applied and there are a few weak spots in the documentation, esp with newer commands.
The code is dark and full of errors
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 6th Jan 2017 10:41
I Agree with Van B.
Small, concise syntax examples are what most users need.
A link to a larger 'showcase' would also be handy but shouldn't be the main focus. Nobody wants to trawl through 100's of lines of code to find the specific syntax example of the one command they want help with.
AGK V2 user - Tier 1 (mostly)
Wizzkid
AGK Tool Maker
17
Years of Service
User Offline
Joined: 14th Aug 2006
Location: Northern Ireland
Posted: 6th Jan 2017 11:33
Perhaps now that HTML export is available for AppGameKit it might be good to show some example code actually running in the help pages to show what the output would be? Would save having to create an AppGameKit project and copy and paste sample code in, so you would be able to see the output right away.
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 6th Jan 2017 11:50
The core commands showing examples of update render and swap etc are quite powerful
but a beginner might find a very simple example useful. I believe when people first look to these
commands they just want to know how to draw something to screen without syncs built in ClearScreen()
being called. Well that was my case anyway.

example


Altho I did find the snowflake example very good and will give credit where credit is due but I believe
that you need atleast one example as simple as possible. Hopefully then the learner can feel inspired
to play with the command a little to create there own effects
fubar
Humildadever
13
Years of Service
User Offline
Joined: 17th Aug 2010
Location:
Posted: 6th Jan 2017 12:40
I think is important examples like in old times in dark basic , to construct a plataform game, space game etc step to step ....
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 6th Jan 2017 12:44
Core commands can't be found with the search commands function.
And some of them don't seem to be in the documentation at all.
I'm thinking specifically of select, case, etc. I can't find any mention of those in the help files anywhere.
But all core commands should be there for beginners to easily find with search. For...Next, Repeat....Until etc.
AGK V2 user - Tier 1 (mostly)
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 6th Jan 2017 13:04
Thanks for the feedback so far. Lots of good suggestions. Please keep them coming.

For each command would you like to see a complete program demonstrating its usage, with the intention of focusing primarily on that command and keeping the program as small as possible? Say for example we chose the GetImageWidth command, the example program could load an image, then have a loop that calls it and displays the return value on screen. Certainly in some instances more code will be required to set things up, but ideally keeping it tight and focused on what is required. We can have the fancier, more complex, larger examples shown elsewhere.
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 6th Jan 2017 13:38
Quote: "Perhaps now that HTML export is available for AppGameKit it might be good to show some example code actually running in the help pages to show what the output would be? "

Finally, a use for the freedom engine!
Jeff Miller
19
Years of Service
User Offline
Joined: 22nd Mar 2005
Location: New Jersey, USA
Posted: 6th Jan 2017 13:53 Edited at: 6th Jan 2017 13:55
Scraggle --
The syntax specs for those words are in the Language section, not the Commands section.

I noticed that several of the "sample code" examples attached to individual command pages do not contain even a single instance of the command. There are also some instances of using the word "affect" where "effect" would be proper, and vice versa.
MikeHart
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 9th Jun 2003
Location:
Posted: 6th Jan 2017 14:41
Hi Orvillian, it is great to read about the plans to update the help section.

Being a published author myself, I can relate to the amount of work that can go into documentation and also teaching game development. Does TGC look for additional help regarding this process?
Running Windows 7 Home, 64 bit, 8 GB ram, Athlon II X2 255, ATI Radeon HD 4200. Using AGK2 Tier 1.
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 6th Jan 2017 14:45
Quote: "Being a published author myself, I can relate to the amount of work that can go into documentation and also teaching game development. Does TGC look for additional help regarding this process?"


If anyone wishes to volunteer their time and assist in the creation of updated and new material that would be great. If you are interested please PM me so we can get a discussion going.
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 6th Jan 2017 15:01 Edited at: 6th Jan 2017 15:02
I think an important missing piece is using associated commands together. Some commands don't make any sense in isolation (e.g CreateEditBox())

For example, createParticles() doesn't do anything until you assign an image, set the size and update particles before each Sync as an absolute minimum requirement. Then you can use the other associated commands to do more.

In respect of the comments above, the same "All particle commands example" could be linked to all of the commands used, saving effort in building the help.

...and welcome back to the outside world, does anyone know you got out?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 6th Jan 2017 15:36
Quote: "The syntax specs for those words are in the Language section, not the Commands section.
"

That's a problem right there!
They are commands and should be in the command section. Under the heading of language perhaps but not in a separate page altogether.
AGK V2 user - Tier 1 (mostly)
AreCustomize
10
Years of Service
User Offline
Joined: 22nd Dec 2013
Location: Cyberspace
Posted: 6th Jan 2017 15:45
Hi!

Tutorials and examples for setting up 3D game and shaders/lighting for games would be nice!
So far I have just checked example projects made by other users but I still don't understand the mechanism.
For example how to add lighting using commands createobjectquad(), drawsprite() and creating renderImage and quadImage then using some swap(), clearscreen() etc.
it's really confusing for me.

-AreCustomize
"Anyone who has never made a mistake has never tried anything new."
-Albert Einstein
CJB
Valued Member
20
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 6th Jan 2017 17:22
Tutorials on how to setup and configure third party services (facebook, in-app purchasing, advertising networks, gamecentre etc.). Would be nice to see how we're supposed to set those other systems up to interact with AGK. At the moment, there's a LOT of trial and error going on to get these features working. For example, I'm still not seeing any AdMob interstital ads for my latest release and don't know whether it's a problem with my code, agk, AdMob, or whether AdMod only serve interstitials when traffic goes above a certain lvl etc. as I can't find much documentation on the subject.

Some comprehensive multi-player tutorials for various multi-player scenarios. Examples would be MMORPG (maybe using Preben's awesome GG loader), space trading/combat (Eve style), arcade action (slither.io style) etc.


V2 T1 (Mostly)
Phone Tap!
Uzmadesign
BitManip
10
Years of Service
User Offline
Joined: 20th Dec 2013
Location: Essex
Posted: 6th Jan 2017 18:30
My thoughts are the following;

1) Good clear concise examples in both T1 and T2
2) Make it even more accessible...(see following points)
3) A good description of the 2D system (with images for newbies)
3a) how 2d cordinates work (x,y) in reference to virtual screen dims/percentage
3a1) how to make a tiled map (static/scrolling)
3b) What a sprite is (simple maybe but for a newbie...)
3c) layers and drawing order
4) the 3d cordinate system (describe with images)
4a) how to place/rotate 3d objects and camaras
5) examples of the brilliant education app (especially Shape Up lol) that was used to create a commercial product!

Just my thoughts.
I control all the juicy in here!
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 7th Jan 2017 11:05
from feature request:
can u create the online docu in more rows like this?
it will using the screen area better, more overview and less scroll. same for opposite commands get / set.

GetDeviceWidth GetDeviceHeight
GetDisplayAspect
GetMaxDeviceWidth GetMaxDeviceHeight
GetOrientation
GetPaused GetResumed
GetPolygonsDrawn
GetScreenBoundsLeft GetScreenBoundsRight GetScreenBoundsTop GetScreenBoundsBottom
GetVerticesProcessed
GetViewOffsetX GetViewOffsetY
GetViewZoom
GetVirtualWidth GetVirtualHeight
AGK (Steam) V2.0.22 : Windows 10 Pro 64 Bit : AMD (16.12.1) Radeon R7 265 : Mac mini OS Sierra (10.12)
Resourceful
10
Years of Service
User Offline
Joined: 29th Jan 2014
Location: every ware
Posted: 7th Jan 2017 16:44
A few more example would be nice

the Layout of the text is the one thing that could be improved

reading a explantion of what a command in a long sentance makes me a bit buggy eyed

example :

to load a image you need to find the image you want to load and the image but not be any bigger than 10 x 20 and have ony 500 colors

Correct layout would look more like this:

to load a image you need to find the image you want to load
and the image but not be any bigger than 10 x 20
and have ony 500 colors

people do the same thing in the forums and it's like some one typing in all Cap's
DarkGriffin
7
Years of Service
User Offline
Joined: 7th Jan 2017
Location: Noblesville, IN
Posted: 7th Jan 2017 20:20
I have some free time, so here's some free answers.

Do you feel as though the documentation is lacking in any ways?

One thing I found very lacking when trying to use AppGameKit the first time is examples of what happens to the "data", "memory", or "display" for the commands.

The issue is the manual assumes the commands will work out of the box. (They usually do but most require other commands to setup things in memory beforehand, which isn't always explained very well). The manual then leaves it up to the user to see what the result is, or in most cases, to figure out HOW to see what the result is.

I also think a lot of the graphical, file accessing, and text display examples would benefit greatly by including "before and after" like screen shots. Or in the case of the file accessing, screenshots visually showing what the engine is reading/writing in an example file.

Then a new user could compare the result they are getting with the manual's expected result to more easily figure out what they are doing wrong. These screenshots showing how the data is being processed visually would also help remove some of the ambiguity of commands such as the file/line reading commands, graphical shader effects, or string processing operators.

Would we benefit from having tutorials covering specific functionality?

The manual would, yes. I would love to see some examples of multiple command "systems" like loading a level's "blocks" from a file, for example. A lot of the current documentation focuses on a single command at a time, which is great for learning the commands. But then it leaves connecting them almost entirely up to the user. Which can be very daunting to someone not versed in how to "think in game code".

One issue I ran into when using AppGameKit for the first time is the lack of documentation on "best practices". It would be great to have some "best practices" articles for mid level concepts like creating a "game loop", iterating over image slots, creating input control globals that can be read by the rest of the game code and when to update them, using multiple script files to keep a game's code and objects organized, and so fourth.

Would it be useful to have guides showing how to make simple games as a way of getting started?

It would be useful, but I would be careful to not make them too detailed. A recreation of asteroids with lots of multiplayer features sounds like great practice on paper. But a simple "here's a ship and some asteroids that wrap around the screen" would be more useful to a new coder. New coders do not want to make billions of options for an asteroids multiplayer game just yet, they just need to know how to get their hero to load up and move about the screen.

For example, the asteroids game could focus on basic sprite rotation and movement/input techniques, leaving expanding the game up to the user from there. A separate game could then focus on multiplayer networking and syncing the game state, or on making an options menu, and so on. I think small games that focus on good coding practices for part X of the game would be much more useful then full blown games. The tutorials would also be shorter and easier to follow that way.

Might the documentation benefit from many more examples showing how to use specific commands?

There's a few places it might help, as many of the same examples are just copied over many different applicable command pages right now.

One big gap is the shader, lighting, and texture commands. They tell exactly what they do, but don't provide any screenshots or best practice info on how to get good results. With how much time it takes to set up a testing environment for lighting or make shading materials, a screen shot and best practice bullet point would go a long way to helping teach newcomers how to do 3D or shaders the "AGK way". Or what they should be expecting as the results.

The mobile focused commands are also woefully under explained. The current approach requires lots of hours invested into making a test mobile app and trying out all the different commands. Once again, it would be really nice to "know" the result of commands by reading/seeing it without needing to try them myself.

Would the addition of video tutorials be helpful?

It wouldn't hurt, but should not replace the text manual. As AppGameKit is mostly a code focused development tool, I think it's more useful to read the text and type commands at our own pace then to try to follow and pause a video. One place videos would shine though is in showing the results of tutorials or graphical commands, so users can confirm they did them right or are getting the correct result. And of course a few rare visual things would be better explained in video. But please include text explanations too, for those with slower internet connections!

For an example of doing this wrong, look at Unity's all video concept lessons, which are very helpful, but I try to avoid needing them because my internet is not stable enough to watch the videos on high quality. (I love Unity otherwise, but sometimes they do silly things and forget we don't all have high speed internet yet.) So always remember that some users will not have video capability when viewing your documentation.

For a beginner do you feel the documentation is adequate?

It's adequate IF the beginner has had previous coding and video game structuring/logic experience. However to a complete new user, it is severely lacking in best practice knowledge, which could get them "boxed in" to bad code structure later in development. Anything that helps minimize long term "traps" like this for new users will help them be more effective in using AGK.

Are enough advanced topics covered?

I would like to see a few guides on structuring game loops and using multiple script files effectively. These are not "fun" things to try to figure out on your own, and it's easy to affect game performance by mistake simply by structuring your basic game loops or loading resource code wrong.

Another topic not covered well is good practice for making games support "options", like rendering resolutions, lower graphic settings, or even dynamically changing the resolution and controls to match mobile or desktop. A tutorial or guide giving some concept examples of how to go about coding such "bread and butter" features could help newcomers and pros alike add that "extra polish" to their games.
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 8th Jan 2017 18:35
Please add these 3D physics demos.

https://forum.thegamecreators.com/thread/216683
The coffee is lovely dark and deep,and I have code to write before I sleep.
kslam212003
11
Years of Service
User Offline
Joined: 10th Dec 2012
Location:
Posted: 10th Jan 2017 06:23
Tutorial and example needed:
Tile - Loading layer, object, collision detect.
Admob
IAP
GameCenter
GooglePlay
Blendman
10
Years of Service
User Offline
Joined: 17th Feb 2014
Location: Arkeos
Posted: 11th Jan 2017 16:03 Edited at: 12th Jan 2017 11:03

The documentation is great, but there isn't examples for some functions :
- 2D physic : RayCast, Joints, Contacts, Forces, Debug
- Sprite : in physics part (SetSpritePhysicsRestitution, SetSpritePhysicsTorque...)
- 3D
- extras (iap, admob, facebook...)


Would we benefit from having tutorials covering specific functionality?

Maybe for beginners.
But simples examples are generally simplier to do, and usefull.

Might the documentation benefit from many more examples showing how to use specific commands?
Yes, and specifics examples too, especially :

- pathfinding
- IA
- Tween of screen for Android/ios games
- android gesture (zoom with 2 fingers)

More examples for rendering could be great too :
*) 2D
- Shaders example : normalmap example, refraction/distortion example,
- 2Disometric ia enemy, collision or avoid obstacle

*) 3D
- shaders : normalmap, reflection, refraction, shadows, rimlight ...
- Physics & characters : enemy moved by a character
- very simple physic collision between two objects


For a beginner do you feel the documentation is adequate?

If all the functions have examples, I say yes.

Are enough advanced topics covered?
More examples on those topics could be great :
- Multiplayer (with server : password/login) + php page (to register)
- Third party : iap, admob, advert, googlecentre...

- 2D : isometric move, collision, IA movements with physic...
- 3D : Always shaders ^^, pathfinding, collision and physic with IA/characters

I think, you could add more "little games" example :
For now, we can find :
- 2D shooter, snaker
- tutorial : Physic game (angry bird like)


posted in showcase forum :
- 3D fps
- sort of RPG
- flappy bird like


It could be great to have those examples :
- 2D Match3 example (and other puzzle examples)
- 2D : (isometric & Normal 2D) movement with collision, pathfinding or Avoid obstacles, simple IA
- 3D : third person example, with physic collision & sort of pathfinding
- 3D : physic car example (simple car race)
AGK2 tier1 - http://www.dracaena-studio.com
damothegreat
User Banned
Posted: 11th Jan 2017 18:35
I have added an example for some tween commands - at the moment for Sprite Chains mainly with:-

SetSpriteTweenX
SetSpriteTweenY
CreateTweenSprite
CreateTweenChain
AddTweenChainSprite
UpdateTweenChain
PlayTweenChain
CreateTweenText
SetTweenTextAngle
SetTweenTextX
SetTweenTextY
SetTweenTextSize
PlayTweenChain
PlayTweenText
UpdateAllTweens

More examples to follow in a few days for various other tween commands

Damo


Using Tier 1 AppGameKit V2
Started coding with AMOS
Works with a Lenovo IdeaPad 700, 1TB SSD (Data), 128GB HD (System), 12GB Ram, GeForce Nvdia 950M, Windows 10, 2.3Ghz (Turbo to 3.2ghz when required)
Humildadever
13
Years of Service
User Offline
Joined: 17th Aug 2010
Location:
Posted: 13th Jan 2017 01:14
I think is very interesting for a learning u do a course in e-learning with many levels that we can learn, i think if u sell this we bought that and the assimilattion is better. In the end you give like a diplom
Harlequin
14
Years of Service
User Offline
Joined: 22nd Mar 2010
Location: Melbourne (AU)
Posted: 13th Jan 2017 01:28
The description layout of the commands needs to cleaned up and perhaps made a little more details in some cases.
A good example of commands that need work on improving their layout are the Memblock and Mesh commands (they also need some examples).

Probably the worst description of a command is "CreateMemblockFromObjectMesh", that will give you a headache trying read it....lol
It\'s late, I\'m tired, out of coffee and now I\'m wet.
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 13th Jan 2017 14:39 Edited at: 13th Jan 2017 14:41
More examples needed.
People are asking everyday on how to make platformers and multiplayer. So maybe example project for popular game genres.
Also fill in examples for the commands help file.
damothegreat
User Banned
Posted: 15th Jan 2017 20:57
Will write some more examples of tweens over the next few days and post them up
Using Tier 1 AppGameKit V2
Started coding with AMOS
Works with a Lenovo IdeaPad 700, 1TB SSD (Data), 128GB HD (System), 12GB Ram, GeForce Nvdia 950M, Windows 10, 2.3Ghz (Turbo to 3.2ghz when required)
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 18th Jan 2017 12:03
Thanks for the feedback so far. Lots of new content is on its way.

I have just uploaded one new guide - https://www.appgamekit.com/documentation/guides/creating_first_project.htm This is the kind of thing we're aiming for going from simple topics all the way to more advanced content.
MikeHart
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 9th Jun 2003
Location:
Posted: 18th Jan 2017 18:51 Edited at: 18th Jan 2017 18:53
Thanks for sharing this first piece. Your example on formating the code... mmh. You should maybe mention that someone should indent properly. While all these code samples work, they are badly formated.
Running Windows 7 Home, 64 bit, 8 GB ram, Athlon II X2 255, ATI Radeon HD 4200. Using AGK2 Tier 1.
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 19th Jan 2017 13:30
A new guide has been uploaded today. This one is all about variables - https://www.appgamekit.com/documentation/guides/variables.htm

MikeHart, thanks for your feedback. I intend to write a document going into more details about code formatting and the choices that can be made. Would you prefer to see this mentioned at an early stage, such as in the creating a project guide or perhaps later on?

Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 19th Jan 2017 14:26
Good habits should be formed early and maintained throughout
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
Blendman
10
Years of Service
User Offline
Joined: 17th Feb 2014
Location: Arkeos
Posted: 19th Jan 2017 16:49
@Orvillian : great new guide .

For variable, you have not talk about : global and local.
I don't know if it's the good guide for those words ^^
AGK2 tier1 - http://www.dracaena-studio.com
MikeHart
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 9th Jun 2003
Location:
Posted: 19th Jan 2017 20:58
Orvillian wrote: "Would you prefer to see this mentioned at an early stage, such as in the creating a project guide or perhaps later on?"


I would have placed it inside what you have written there.

Ortu wrote: "Good habits should be formed early and maintained throughout"


Absolutely!

Blendman wrote: "For variable, you have not talk about : global and local."


Very important. Sure you can get away without it. But that makes code at least less readable and maintable.
I recomment to use #option_explicit so you avoid having mixups and false assignments.
Running Windows 7 Home, 64 bit, 8 GB ram, Athlon II X2 255, ATI Radeon HD 4200. Using AGK2 Tier 1.
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 19th Jan 2017 21:11
I don't like the very first line.
It suggests that you share variables between all of your programs - a bit odd!
AGK V2 user - Tier 1 (mostly)
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 19th Jan 2017 22:06 Edited at: 19th Jan 2017 22:07
Quote: "Every program you create is going to share consist of a bunch of common elements, one of which are variables."


?

Or maybe:

Variables are a basic component of any program.
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
damothegreat
User Banned
Posted: 19th Jan 2017 22:14 Edited at: 19th Jan 2017 22:15
Global declarations = every function see's its values

Non global - only the function or the main.agc where the game loop resides only sees these values

So say,

if we have a function that' uses 2 variables - but the rest of the app doesn't need to know what these are - then declare them inside, at the top of the function.

If we need variables which are required all over the app - then declare them as global at the top of the main.agc.
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 20th Jan 2017 04:01
Please remove all the deprecated commands from the help files.
Please updated all the commands with what they currently do on all platforms.
The coffee is lovely dark and deep,and I have code to write before I sleep.
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 20th Jan 2017 07:55
Thanks for the feedback.

Another document is planned where the intention is to talk about locals and globals along with things such as option explicit. I want to introduce the user to a few more things first.

I will update the section about formatting of code and add in some new information.

Will change the first line about sharing variables.

If anyone wishes to contribute please PM me. Any advice that can be placed into an article is welcome.
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 20th Jan 2017 15:52
What about all the other forms of comment?

// This is a comment

' so is this

rem so is this

/* and this
this too
*/

Remstart
I'm a comment
So am I
Remend
AGK V2 user - Tier 1 (mostly)
damothegreat
User Banned
Posted: 20th Jan 2017 15:59
Don't forget to try and use

( and )

to separate mathematical calculations

each of the

* / + - % etc has an order of which comes priority, so

a = 10 * 3 + 2 / 4

May get a different response to doing something like

a = ( ( 10 * 30 ) + ( 2 / 4 ) )

Damo
Orvillian
TGC Developer
8
Years of Service
User Offline
Joined: 8th Feb 2016
Location:
Posted: 20th Jan 2017 16:03
Scraggle, my thinking behind not covering those right now is that I don't want to overload the users with too much information at this stage. It's difficult to know whether to show everything or just try and give some kind of brief overview, with the intention of offering more information as the user makes more progress. Not entirely sure what the best approach is.
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 20th Jan 2017 17:19
Can you link to greater detail that readers can follow or skip as they like?

"Click to see additional comment types "
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 20th Jan 2017 18:18
Quote: "It's difficult to know whether to show everything or just try and give some kind of brief overview, with the intention of offering more information as the user makes more progress. Not entirely sure what the best approach is."


Using variables as an example, I would finish with something along the lines of:

In follow-up tutorials, we will go into more depth regarding the scope of variables, and how they can be made globally available or constrained to an isolated function.

Then, the reader knows there is more to learn without being overwhelmed.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt

Login to post a reply

Server time is: 2024-05-03 19:04:33
Your offset time is: 2024-05-03 19:04:33