The Dink Network

Button Global

September 16th 2004, 04:48 AM
pig.gif
sjoerdje
Peasant He/Him Netherlands
Lava pig to the rescue! 
Hey all,
I'd like to know, how can I let something check a global and then use it. So a global goes up and down, and when I use an object it should show the current global number... I hope I am clear enough.

Thanks
Regards, Sjoerdje
Edit: Never mind, got it
September 17th 2004, 05:26 PM
anon.gif
Ric
Ghost They/Them
 
That's the whole learning to write .c scripts idea. There is a lot to it.
Like the story variable...
void main ()
{
if (&story == 1)
{
say_stop("the story variable is &story",1);
}
&story += 1;
}
If this script is attached to a sprite, then as soon as the sprite appears it will check to see if the value of &story is currently set at 1. If it is, Dink will say 'the story variable is 1'.
Then the next line will add 1, so &story will then be 2.
There is much to learn, but it can do so much!