Telephonepole Electricution by a switch
Posted: Thu Mar 04, 2004 9:02 pm
I was needing some help in scripting a trigger that when activated by a switch it would hurt a player if on some telephone wires.
my current code is
all thats in my map scr file and is properly called by
Any help with this would be gratly appreciated.
my current code is
Code: Select all
wireelectricution:
while ((level.rightwire != -1) && (level.righttime != 5))
{
$alliesright_wire volumedamage 10
level.righttime = level.righttime + 1
wait 1
}
if (level.righttime == 5 )
{
level.rightwire = -1
level.righttime = 0
}
end
alliesright:
$alliesright_trigger waittill trigger
$alliesright_switch anim turnon
$alliesright_switch playsound alarm_switch
wait 0.5
level.rightwire = 1
goto alliesright
end
Code: Select all
level waittill prespawn
thread alliesright
thread wireelectricution