• 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.

Requesting a Trigger Fix:

Status
Not open for further replies.
Level 4
Joined
Oct 4, 2005
Messages
65
Event-
Unit - A unit Begins an upgrade

Conditon-
(Mana of (Triggering unit)) Less than or equal to 499.00

Action-
Unit - Order (Triggering unit) to Cancel

I am trying to make it so that a building called "Village" to not upgrade to another building (but it does anyways). Some reason this trigger does not fire up.
 
Level 9
Joined
Aug 27, 2004
Messages
471
If you're using meta-morph abilities, it wont cancel quick enough. Instead make the whole thing triggered:

Event
Unit - Begins upgrade

Condition
null

actions
if(Mana of (upgrading unit) <= 500)
then
DoNothing()
else
replace unit - blah blah, blah blah
endif


Sorry, didint have time to get the actual code, but you get the point yes?
 
Level 4
Joined
Oct 4, 2005
Messages
65
Okay, the trigger works, but now I can't upgrade when I have 500 mana.

The trigger is set to not allow the upgrade if its lower than 500 mana, if the building is 500, then it should be allowed to upgrade but it does not.
 
Status
Not open for further replies.
Top