if…I mean I've been wrapping my head around this one all day…. :shock:
Im using the message command for testing to make sure this is working…the variable is definetly being set properly…the if statement is where the problem is…
i've tryed several methods…please help…
if $roadside == rightEndRoadPoints, message right, message left
if ($roadside == rightEndRoadPoints) message right
else if ($roadside == leftEndRoadPoints) message left
else
endif
if ($roadside == “rightEndRoadPoints”) then
message right
else if ($roadside == “leftEndRoadPoints”) then
message left
else
message nothing
endif
if ($roadside == rightEndRoadPoints) then
message right
else ($roadside == leftEndRoadPoints) then
message left
endif
I've basically tryed anything I could think of…adding parenthesis, quotations…
I pulled up the scripting pdf from houdini 6.1 docs and read up on if statements and the syntax…but no luck here :?
thank you in advance for any help!!!!!!!
if statement
2282 2 0- lynch_ppl
- Member
- 176 posts
- Joined: July 2005
- Offline
- wolfwood
- Member
- 4261 posts
- Joined: July 2005
- Offline
The last two of your examples should work….
set test = e
if ($test==“d”)
message Nope
else if ($test ==“a”)
message Yulp
else
message Ummmm
endif
I'd double check the variable….I've lost count of the number of times that I've spent hours debugging a script and it ended up being a simple case of a mis-spelt variable.
Try doing
echo $leftEndRoadPoints
Then copy and paste output into the if statement….
if (copy_and_paste_here == “right”)
…
set test = e
if ($test==“d”)
message Nope
else if ($test ==“a”)
message Yulp
else
message Ummmm
endif
I'd double check the variable….I've lost count of the number of times that I've spent hours debugging a script and it ended up being a simple case of a mis-spelt variable.
Try doing
echo $leftEndRoadPoints
Then copy and paste output into the if statement….
if (copy_and_paste_here == “right”)
…
if(coffees<2,round(float),float)
- lynch_ppl
- Member
- 176 posts
- Joined: July 2005
- Offline
-
- Quick Links