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

if you pick up one item, and then pick up another of same sort, how to make him die?

Status
Not open for further replies.
Level 6
Joined
Dec 6, 2009
Messages
173
Hi!
I want to know how to make a unit die if he picks up two of same items.

For example: I got my paladin, he picks up Potion of Divinity and uses it. And I want to make him die if he picks up Potion of Divinity again and uses it.
(if he not uses it he shall stay alive).

So I hope maby someone knows how to do this, cause it whould be helpfull for many people I think :ogre_haosis: .

THX!
 
  • Item Death
    • Events
      • Unit - A unit Uses an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Scroll of the Beast
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Key time) is stored as a Integer of (Key (Triggering unit)) in I_Hash) Equal to False
        • Then - Actions
          • Hashtable - Save 1 as (Key time) of (Key (Triggering unit)) in I_Hash
        • Else - Actions
          • Hashtable - Clear all child hashtables of child (Key (Triggering unit)) in I_Hash
          • Unit - Kill (Triggering unit)
 

Attachments

  • Item Death.w3x
    16.9 KB · Views: 40
Level 6
Joined
Dec 6, 2009
Messages
173
thx alot:D

Hmm, while I am on this, on my map I got different ''Fruit items'' so if you use one you get a power. but theese aint the same items, so what if I whould use one of them and pick up another and use it. how to make the guy die then?

Still thx! (this was the thing I actually needed help with.... sorry for not being this clear:()
 
Status
Not open for further replies.
Top