
Gamma927
Joined: Jun 12, 2008
Steam: gamma927
|
Posted: Jun 3, 2009 12:07 AM
Msg. 1 of 7
This has been bugging me for some time. How do I use the [else] inside an if clause?
|
|
|

chrisk123999
Joined: Aug 10, 2008
=CE= Chris [Captain] [=]
|
Posted: Jun 3, 2009 12:14 AM
Msg. 2 of 7
-Snip- Posted onto the wrong thread somehow? ... Edited by chrisk123999 on Jun 3, 2009 at 12:39 AM
|
|
|

Polamee
Joined: Feb 25, 2008
MP2SPMT's founder
|
Posted: Jun 3, 2009 08:14 AM
Msg. 3 of 7
Like I said just now on Xfire, I don't think it works for Halo. You could, like I suggested, use some booleans to mimic the effect.
|
|
|

Gamma927
Joined: Jun 12, 2008
Steam: gamma927
|
Posted: Jun 3, 2009 10:32 AM
Msg. 4 of 7
No. It does work for Halo. If you read HS Doc, or the scripting bible, there is an else command in the if clause.
|
|
|

kirby_422
Joined: Jan 22, 2006
Apparently public enemy number 1?
|
Posted: Jun 3, 2009 11:10 AM
Msg. 5 of 7
Quote: --- Original message by: Gamma927 This has been bugging me for some time. How do I use the [else] inside an if clause? the if checks if the result is true, if its true, it preforms the first action. if its false, it does the second action. (1=true, 0=false)
|
|
|

Gamma927
Joined: Jun 12, 2008
Steam: gamma927
|
Posted: Jun 3, 2009 11:19 AM
Msg. 6 of 7
So would I just put the commands outside of the if clause? Like: (if (= x 1) (begin (set x 2) ) ([COMMANDS?]) )
|
|
|

kirby_422
Joined: Jan 22, 2006
Apparently public enemy number 1?
|
Posted: Jun 3, 2009 01:03 PM
Msg. 7 of 7
Quote: --- Original message by: Gamma927So would I just put the commands outside of the if clause? Like: (if (= x 1) (begin (set x 2) ) ([COMMANDS?]) )
(if (volume_test_object volumetrigger8 warthog8) (object_create_anew_containing ninja) (object_destroy_containing ninja)) if it fines the warthog there, it creates the ninja items, if its not there, it destroys them.
|
|
|