Jump to content
Sign in to follow this  
Winters!

Simple question ( I think )

Recommended Posts

How do i stop a script, if this one has been launched

For example :

The AJMRespawn script create units forever ...

how do it stop it ?

thx

biggrin_o.gif

Share this post


Link to post
Share on other sites

Somewhere in the script loop for your mission, add a condition checking if a variable is either set to true or set to a specific number, or any kind of condition suiting your mission

If this condition is done , just exit the script.

example

Quote[/b] ]

#mainloop

?!(alive unit01) : exit

unit01 sidechat "Hey, i am always alive"

~5

goto "mainloop"

That script will lead a soldier named unit01 to say repeatedly , each 5 seconds, "Hey, i am always alive"

The once the soldier unit01 is dead, the script stop and the "Hey, i am always alive" sentence will not appear anymore.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×