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

How to make a hero equip only 1 kind of item

Status
Not open for further replies.
Level 25
Joined
May 11, 2007
Messages
4,650
This should probably work. Use the item categories for different types of items, like:
Helmets - Artifacts
Hands - Purchasable
Weapons - Permanent
Chest - Charged
Potions, Etc - Misc
  • Events
    • Unit - A unit Acquires an item
  • Conditions
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • For each (Integer tempInt) from 1 to 6, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Item-class of (Item being manipulated)) Equal to (Item-class of (Item carried by (Triggering unit) in slot tempInt))
          • Then - Actions
            • Game - Display to (All players) the text: You cannot have two...
            • Hero - Drop (Item being manipulated) from (Triggering unit)
          • Else - Actions
 
Status
Not open for further replies.
Top