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

2 Questions Concerning Triggers

Status
Not open for further replies.
Level 9
Joined
Nov 4, 2007
Messages
933
First, how do I check in conditions if the unit is carrying a specific item type?
Second, how do I order a unit to use a specific item?
These two areas are really annoying me to no end and I have yet to find any way at all to do either one.
 
Level 11
Joined
Aug 1, 2009
Messages
963
#1: Add a behavior linked to that item type that has the hidden flag checked. Then, check if the unit has that behavior - if it does, it has the item.

Unsure about the second one. Maybe just apply the effect then decrease the charges on the item by one? :|
 
Level 9
Joined
Nov 4, 2007
Messages
933
For the first point, that will work.
For the second, I can't see how to do that, I haven't found any action that changes the charges on an item, not in abilities, effects, behaviors, triggers, I've looked everywhere but I think I just need another pair of eyes to look as well.
 
Status
Not open for further replies.
Top