Trigger Help (Darimus come!)

JetFangInferno

Member!
Joined
Feb 2, 2004
Messages
23
Reaction score
0
Website
Visit site
How do you make a trigger where a unit attacks a lever, the unit instantly stops attacking, the lever becomes invulnerable and unusable, a gate opens. Then after 5 seconds, the lever is vulnerable and usable again so if a unit attacks the lever again, the gate is closed. Every 5 seconds there should be a trigger to check for any destroyed gate and if there is one, it is revived, Please tell me how to make a trigger like this.:scary
 

Darimus

BattleForums Addict
Joined
Oct 2, 2003
Messages
681
Reaction score
0
Website
www.spaceman.vze.com
How about have: Event - Destructable Dies

Conditions: Dying destro is your lever

[Create boolean GateOpened]

Actions:

If: GateOpened=False
Then do: set GateOpened=True

Create (Type of Dying Destructable) at (Position of Dying Destructable)

Make last created destructable invulernable

open gate

wait 5 seconds

make last created destructable vulernable

Else do: set GateOpened=False

Create (Type of Dying Destructable) at (Position of Dying Destructable)

Make last created destructable invulernable

close gate

wait 5 seconds

make last created destructable vulernable

Next Trigger

How about have: Event - Destructable Dies

Conditions: Dying destro is your gate

Actions: Revive the gate at position of gate
 

jetlee

Member!
Joined
Feb 7, 2003
Messages
167
Reaction score
0
Location
Ohio
Website
www.geocities.com
Hey darimus with that knowledge you possess how would you make a trap step such as you know a lever but is a step...when a hero steps on the trap step....it goes down and a fire trap fires....i want the trap step to stay down until the hero leaves or goes off of it and the trap fire stops attaking....how do u do that with triggs...give me ex not dl thanks darimus
 

DisTurBeD-OrC

Member!
Joined
Dec 22, 2003
Messages
46
Reaction score
0
Location
Ohio
I know that.
First lay fire on a switch, then creat a location above switch (in my example i called it switch)

Events:
map initialization

Actions:
Animation - Play the death animation for all doodads of type Fire within Switch <gen>

Events:
Unit - A unit enters Switch <gen>

Actions:
Destructible - Kill Foot Switch 0001 <gen>

Animation - Play the stand animation for all doodads of type Fire within Switch <gen>

Wait until ((Number of units in (Units in Switch <gen>)) Equal to 0), checking every 0.50 seconds


Destructible - Resurrect Foot Switch 0001 <gen> with (Max life of Foot Switch 0001 <gen>) life and Show birth animation

Animation - Play the death animation for all doodads of type Fire within Switch <gen>

(just incase you didn't notice but I change it just in case there is more than one unit manipulating the switch)
 
Top