• 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.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

item replace

Status
Not open for further replies.
Level 4
Joined
Apr 30, 2009
Messages
47
thanks but i wanna move it to back item place
examaple i wanna replace item x with item y
i create item y and give it to hero and delete item x and move item y to place of item x but i dont know set slot to what?
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
thanks but i wanna move it to back item place
examaple i wanna replace item x with item y
i create item y and give it to hero and delete item x and move item y to place of item x but i dont know set slot to what?

just detect item slot of item x
i think you can move item to item,not sure

but u can use integer X actions from 1 to 6
if (your item) is in slot X equal to true
than move (item) to slot X
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
you can use (Integer A) instead,but your own integer N variable would be nice
  • Actions
    • For each (Integer N) from 1 to 6, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Item carried by (YourUnit) in slot N) Equal to (YourItem)
          • Then - Actions
            • (you can delete your item X here)
            • Unit - Order (YourUnit) to move (YourItem)) to inventory slot N
          • Else - Actions
btw
if unti is ordered to move item x in slot y and slot y has item,bot items will be switched
 
Status
Not open for further replies.
Top