Jump to content
Sign in to follow this  
JAP

Replace objects, or make dis(appear) objects

Recommended Posts

Hey,

I m not that good with the setpos getpos stuff.

I m looking for a way to replace on object with another when a trigger is triggered.

I have a steel gate that i want shut ( steel gate closed ) and when it can be opened ( when trigger is met ) that object need to be replaced with (steel gate open ) kinda to simulate the gate being opened.

Now how can i do that the best way ?

Cheers,

Thx upfront.

Share this post


Link to post
Share on other sites

You could do:

_Steelgateclosedpos= getpos steelgateclosed

Steelgateclosed setpos [0,0,0]

Steelgateopen setpos _steelgateclosedpos

OR you could do this:

#loop1

Steelgateclosed setdir (getdir steelgateclosed) + 1

~0.1

? (Getdir steelgateclosedpos) >= 140:exit

goto "loop1"

You'll have to adjust the "? (Getdir steelgateclosedpos) >= 140:exit" bit to the direction you wish it to stop at, but this way makes it smoother.

tounge.gif PEACE

Share this post


Link to post
Share on other sites

THX gamer77

I ll give it a shot smile.gif

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  

×