Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 05-16-2007, 07:51 AM
zokemon zokemon is offline
That one guy...
zokemon's Avatar
Join Date: Mar 2001
Location: Sonoma County, California
Posts: 2,925
zokemon is a jewel in the roughzokemon is a jewel in the rough
Send a message via ICQ to zokemon Send a message via AIM to zokemon Send a message via MSN to zokemon Send a message via Yahoo to zokemon
I try to teach lots of people GS2 who choose to come to me and it usually works rather well. I PERSONNALY believe the best way to start teaching it is to explain the following:
- How a script is read (compiled together and all the functions are stored to be run when "called")
- The 2 different things you can do in a gs2 script (call functions and set variables)
- How functions work (Also: calling built-in functions [such as onCreated()] and redefining built-in functions [such as function show() {}])
- The 4 variable types: (Float, String, Object, Array)

I believe the last of those things to be the MOST important to actually grasp the concepts of gs2 coding. I am a GUI man though, so my ideas may just be biased as I use objects a lot.

If anyone wants to try to make a guide like such, feel free!
I should get around to actually making one sometime (when I'm not so swamped D: ).
__________________
Do it with a DON!
Reply With Quote
  #2  
Old 05-17-2007, 09:52 PM
Crow Crow is offline
ǝɔɐɹq ʎןɹnɔ
Crow's Avatar
Join Date: Dec 2006
Location: Germany
Posts: 5,153
Crow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond repute
Quote:
Originally Posted by zokemon View Post
- The 4 variable types: (Float, String, Object, Array)
GScript variables are always 'Double' though. Sorry, just had to point that out
Reply With Quote
  #3  
Old 05-18-2007, 05:27 AM
zokemon zokemon is offline
That one guy...
zokemon's Avatar
Join Date: Mar 2001
Location: Sonoma County, California
Posts: 2,925
zokemon is a jewel in the roughzokemon is a jewel in the rough
Send a message via ICQ to zokemon Send a message via AIM to zokemon Send a message via MSN to zokemon Send a message via Yahoo to zokemon
Quote:
Originally Posted by Crow View Post
GScript variables are always 'Double' though. Sorry, just had to point that out
In C++, yes. But if you use the wiki.graal.net at all you will notice every parameter marked with one of these 4 variable types. You don't ever see one marked with "double".
__________________
Do it with a DON!
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 08:49 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.