misinformed 0 Posted July 10, 2007 Is there any way that one script can be told to exit/stop running, etc by another script. Im not after setting a variable to false. ie Script A) Thatscript=true Script B) ? Thatscript : exit Ive got a kind of jukebox thing going that cycles through tracks unfortunalty if one were to turn it off. Then turn it on again, at the moment you would get two incarnations of the same script running and interrupting each others tracks. Any ideas? Thx. Share this post Link to post Share on other sites
moricky 211 Posted July 10, 2007 What about terminate? Share this post Link to post Share on other sites
misinformed 0 Posted July 10, 2007 Awesome thanks. Hadn't seen that one in the listings. Share this post Link to post Share on other sites
misinformed 0 Posted July 10, 2007 Did a search but theres not much on the subject. Does the terminate command only work for the .sqf files? Ive tried it numerous ways with my sqs and cant for the life of me get it to work. The wiki example/suggested usage doesn't actually terminate the script, it just ends up executing it again for me. Ive tried various things but im not getting the result i want. ie Quote[/b] ]_Script=[] exec "musicplayer.sqs";Terminate _Script; Share this post Link to post Share on other sites
UNN 0 Posted July 11, 2007 Quote[/b] ]Does the terminate command only work for the .sqf files? Terminate only works with scripts launched using execVM or spawn. For scripts launched with exec you should be able to use the exit command. Share this post Link to post Share on other sites
misinformed 0 Posted July 11, 2007 Right so basically i cant terminate an sqs remotely then? Or will this Quote[/b] ]_Script=[] exec "musicplayer.sqs"; Exit _Script; do the job then? Love the wiki its got a misleading sqs hint at the bottom that suggests theres more going on, it isn't clear at all. Share this post Link to post Share on other sites