• 💀 Happy Halloween! 💀 It's time to vote for the best terrain! Check out the entries to Hive's HD Terrain Contest #2 - Vampire Folklore.❗️Poll closes on November 14, 2023. 🔗Click here to cast your vote!
  • 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 HD Level Design Contest #1 is OPEN! Contestants must create a maze with at least one entry point, and at least one exit point. The map should be made in HD mode, and should not be openable in SD. Only custom models from Hive's HD model and texture sections are allowed. The only exceptions are DNC models and omnilights. This is mainly a visual and design oriented contest, not technical. The UI and video walkthrough rules are there to give everyone an equal shot at victory by standardizing how viewers see the terrain. 🔗Click here to enter!

Item System

Status
Not open for further replies.
Level 6
Joined
Jun 24, 2011
Messages
202
I need a system that I can edit to use with custom units. It has to determine the type of item a hero it trying to get and see if it already has that item type in its inventory. If so it displays a message and drops the item.

Ex:
Unit aquires Item ??? and that same unit has ??? in its inventory.
A Message says: You already have that item
Item is dropped.
 
Level 7
Joined
May 18, 2010
Messages
264
ill test it out later. thanks

  • ad
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • Set Item = (Position of (Item being manipulated))
        • Do Multiple ActionsFor each (Integer A) from 1 to 6, do (Actions)
          • Loop - Actions
            • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Item-type of (Item being manipulated)) Equal to (==) (Item-type of (Item carried by (Hero manipulating item) in slot (Integer A)))
              • Then - Actions
                • Unit - Order (Hero manipulating item) to drop (Item being manipulated) at Item
              • Else - Actions
Not shure if the Set Item (works) u may need to do 2 triggers for this one ^^
 
Level 13
Joined
Oct 25, 2009
Messages
995
  • ad
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • Set Item = (Position of (Item being manipulated))
        • Do Multiple ActionsFor each (Integer A) from 1 to 6, do (Actions)
          • Loop - Actions
            • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Item-type of (Item being manipulated)) Equal to (==) (Item-type of (Item carried by (Hero manipulating item) in slot (Integer A)))
              • Then - Actions
                • Unit - Order (Hero manipulating item) to drop (Item being manipulated) at Item
              • Else - Actions
Not shure if the Set Item (works) u may need to do 2 triggers for this one ^^

You didn't remove the leaks...
  • Custom script - call RemoveLocation(udg_Item)
 
Status
Not open for further replies.
Top