Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Falcon on July 02, 2004, 02:35:40 pm

Title: Question
Post by: Falcon on July 02, 2004, 02:35:40 pm
Would there be any possibility in adding a sexp that can activate or deactivate events. This would be nice since I could do loopin of events. Basically  when an event plays it only does it once and just specifying intervals will not help. I want it so when I press a specific key it plays out once and deactivates itself but activates another event when going to the second event the event will play out deactivate itself and go back to the first. Thats what I want.
Title: Question
Post by: HotSnoJ on July 02, 2004, 02:43:30 pm
IIRC the sexp is in a loop. Therefore, what do you think if-{insert name here}'s are for?
Title: Re: Question
Post by: karajorma on July 02, 2004, 02:53:27 pm
Quote
Originally posted by Falcon
Would there be any possibility in adding a sexp that can activate or deactivate events. This would be nice since I could do loopin of events. Basically  when an event plays it only does it once and just specifying intervals will not help. I want it so when I press a specific key it plays out once and deactivates itself but activates another event when going to the second event the event will play out deactivate itself and go back to the first. Thats what I want.


Try the every-time SEXP instead of when.
Title: Question
Post by: WMCoolmon on July 02, 2004, 04:30:43 pm
I'm not much of a FREDder, but couldn't you do this with variables?
Title: Question
Post by: karajorma on July 02, 2004, 04:47:02 pm
Ironically not only can you do it with variables but I FREDded a mission for Black Wolf a little while back showing exactly how to do it :D

http://www.hard-light.net/forums/index.php/topic,24148.0.html

That said using the every-time SEXP is also another way of doing it. Depends on what was going on in your mission :)
Title: Question
Post by: Falcon on July 02, 2004, 09:11:20 pm
Baiscally switching the AI on and off......