• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Help with gate switch

Status
Not open for further replies.
Level 9
Joined
Mar 10, 2005
Messages
326
This is a pretty simple question and I'm not sure why it's not working. Basically I want a gate to open and close. I tried giving it a modified version of the "bear form" that has 0 collison size for when the gate is open. However, whenever I use bear form in game, it crashes.

Any ideas?
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
Please be more specific, what do you mean by "Gate Switch"?

When I think of a "gate switch", I think of the lever destructable that has two animations depending which side the lever is pulled to.

At the same time, you say that you added a modified version of "Bear Form" to the gate switch, which would suggest the gate switch is a unit, and not the destructable I was thinking.

Please, when you're explaining something like this be extra specific, there are tons of ways of doing what you want and in order to give you the best explanation I really need to understand the situation entirely.
 
Level 9
Joined
Mar 10, 2005
Messages
326
Please be more specific, what do you mean by "Gate Switch"?

When I think of a "gate switch", I think of the lever destructable that has two animations depending which side the lever is pulled to.

At the same time, you say that you added a modified version of "Bear Form" to the gate switch, which would suggest the gate switch is a unit, and not the destructable I was thinking.

Please, when you're explaining something like this be extra specific, there are tons of ways of doing what you want and in order to give you the best explanation I really need to understand the situation entirely.

Basically I have a unit that's a gate. I gave it the bear form ability so that it can transform into an "open" gate that units can pass through. I put this open gate with 0 collison size so units can pass through.

However, as soon as I use bear form, the game would crash.
 
Level 5
Joined
Feb 27, 2009
Messages
115
Why aren't you using the destructible gate? Anyway...

Try using the Metamorphosis of the Demon Hunter for your "gate". It is less prone to crash. You could also try the 'bird mode' of Medivh as the bird has no collision since it is in the air. But Metamorphosis is the least likely to crash the game.

For a gate switch, I would use a destructable. Create a little region location that is just barely larger than the gate, large enough where a unit can be in if they were to walk up to the gate in either side.

Two triggers: one to open gate and one to close gate.

First trigger have the event be "Unit enters Region X" and then the trigger opens the gate.

Second trigger has the event Unit leaves Region X and then the trigger closes the gate. Very simple.

Sometimes I have troubles in complex maps with the gate not closing. It opens fine but it refuses to close. In that case, I just add a Wait a Few Seconds and tell it to close the gate in the 'open trigger'. That works too.
 
Level 2
Joined
Mar 9, 2009
Messages
21
Are you trying to make some kind of "buildable gate"? Like the gates in Age of Empires for example?

I would, like Mr.Cheese, use Medivhs flying form. Practically the same you tried with the bear form.

If your gate hasn't to be buildable (like static, maybe indestructible gates, placed in the editor) you should use the "destructible - open / close / destroy gate" trigger.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
What the destructable Open/Close/Destroy trigger does is evaluate what the Gate is doing currently, and makes appropriate changes.

Open - Gate is dead, playing its alternate death animation.
Closed - Gate's life has been restored, playing stand animation.
 
Level 9
Joined
Mar 10, 2005
Messages
326
Are you trying to make some kind of "buildable gate"? Like the gates in Age of Empires for example?

I would, like Mr.Cheese, use Medivhs flying form. Practically the same you tried with the bear form.

If your gate hasn't to be buildable (like static, maybe indestructible gates, placed in the editor) you should use the "destructible - open / close / destroy gate" trigger.

Yup, buildable gates. Kinda like walls that can deactivate for units to pass. Thanks! I'll try making it flying =D
 
Status
Not open for further replies.
Top