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

Items Problems!! Help Please?!

Status
Not open for further replies.
Level 14
Joined
Sep 29, 2003
Messages
1,255
How can I make my hero only to wear one item of its kind? lol my english suck!

Forexsampel: My tauren Chieftain finds a item named Cloak of Flame, he pick it up.
Later he finds another item named Cloak of Flame, but he can't pick it up, because he only can wear one item of Cloak of Flames!

So i am only asking for how to make a hero wear one item and not to wear a similar one?

But! he can still wear other items but not the similar one.

PLZ PLZ PLZ PLZ :arrow: HELP HELP HELP HELP!!!! :(
 
Level 1
Joined
Jul 25, 2004
Messages
6
Hmm, try this-

Event: A unit acquires an item.

Conditions:
(Name of (Hero Manipulating item)) equal to Tauren Chieftain
Or any conditions are true:
(Item type of (item being manipulated)) equal to Cloak of Flame

Actions:
set (variable) = (hero manipulating item) (lets call this variable (1))
set (variable) = (item being manipulated) (lets call this variable (2))

For each integer (integer A) from 1 to 6, do Actions
Loop actions:
If all conditions are true then do then actions else do else actions:
IF- or any conditons are true:
(Item type of (item carried by (hero manipulating item) in slot (interger A) equal to Cloak of Flame
THEN- Set (variable) = (variable +1) (lets call this variable (3)) (3) = ((3) +1)
ELSE- do nothing

If all conditions are true then do then actions else do else actions:
IF- (variable)(3) greater than 1
THEN- Hero- drop (variable)(2) from (variable)(1)
ELSE- do nothing

set (variable)(3) = 0


This should work, and if not it should be a good guideline for you. I've used something similar in one of my maps. Oh, good luck understanding my bad explanation. I hope it helps.
 
Status
Not open for further replies.
Top