WatchNon-threaded

Forums » Advanced Editor Forum » Read Message

Talk about it. Ask for help on it. Compliment it.

Question on global scripts

one year ago

So I read up on scripts and I have a question about global scripts.

When i go to ste scripts page in the editor I can see two script pages (is that a correct term?). One says global link the other says global page.

Now if I understand the difference between a link script and a page script correct it is like this.

A link script gets run when a link is clicked.

A page script gets run when the page it is connected to opens up.

Now what is the difference from a link script to a global link script? does the global link script run whenever i click a link or can I define which link has to be clicked? Same for global page script. Does it run whenever i open a page or does it run when i open certain pages?

 

Question on global scripts

one year ago
Global means everywhere all the time.

It can be switched on or off if you enclose it in an IF statement that checks for a variable, but it will run that check constantly.

The usual example is something like a global script that checks for a player's hit points and punts them to a death page if they hit zero.

Question on global scripts

one year ago

Oh well guess I should ask questions beforehand in the future would have saved me a hell ton of time with my riddle storygame.