Moving triggers?
Posted: July 27th, 2010, 8:03 am
Is it possible to make moving (hurt)triggers?Second how can i make a trigger what if i triggered a hurt trigger activate or deactivate?
CoDJumper.com - For all your CoDJumping needs!
https://codjumper.com/forums/
Code: Select all
main()
{
thread movetrig();
}
movetrig()
{
trigger1 = getEnt("trigger_multiple","targetname") //the reason i added this is because of avoid moving all the time; this moves trigger2 only when your player touches the trigger1
trigger2 = getEnt("trigger_hurt","targetname")
trigger1 waittill("trigger") //waits until the trigger1 is triggered
trigger2 moveZ(12, 2, 2, 5);
}
/*
Explanation:
moveZ = move up or down
12 = units to move (+ = up, - = down)
2 = movement acceleration (seconds)
2 = movement decceleration (seconds)
5 = the time it does all the moving
*/
Code: Select all
trig = getEnt("blabla", "targetname");
brush = getEnt("djklsdjfk", "targetname");
trig enableLinkTo();
trig linkTo(brush);
brush moveZ(...);