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

Weapon Type ??? :)

Status
Not open for further replies.
Level 15
Joined
Sep 27, 2009
Messages
676
Hi guys, you can see system that i'm looking for in many ORPG maps.. example "Gaias Retalation".....
-Need:
Example: When warrior has 1 weapon he can't get another one.
Like weapon has some thing that's blocking a use of another one.
----------------------
In my map it's warrior can use axes (can't equip another axe, it's same for helmet and other items)...
How can i do this (NO MULTI TRIGGERS LIKE EVERY ITEM WITH EVERY ITEM :grin:)
 
Level 15
Joined
Sep 27, 2009
Messages
676
Level 2
Joined
Jan 4, 2011
Messages
22
my trigger looks like this:
  • Item limit
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • Set ItemClassCounter = 0
      • For each (Integer A) 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 (Hero manipulating item) in slot (Integer A)) Not equal to No item
              • (Item-class of (Item carried by (Hero manipulating item) in slot (Integer A))) Equal to (Item-class of (Item being manipulated))
            • Then - Actions
              • Set ItemClassCounter = (ItemClassCounter + 1)
            • Else - Actions
              • Do nothing
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ItemClassCounter Greater than 1
        • Then - Actions
          • Hero - Drop (Item being manipulated) from (Hero manipulating item)
          • Game - Display to (Player group((Owner of (Hero manipulating item)))) the text: |cffffcc00You can't carry that many of this item type!|r
        • Else - Actions
          • Do nothing
Right now im just trying to figure out how to make it ignore misc items that i will use for potions, food and other

EDIT
I found out how to do so ;) here is the new trigger
EDIT EDIT
Now it works for sure! :goblin_yeah:
 
Last edited:
Level 15
Joined
Sep 27, 2009
Messages
676
Can someone tell me why isn't this trigger working good??
  • Chain Armor
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Chain Armor
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Unit-type of (Hero manipulating item)) Not equal to Celan) or (((Unit-type of (Hero manipulating item)) Not equal to Defos) or ((Unit-type of (Hero manipulating item)) Not equal to Repen))
        • Then - Actions
          • Hero - Drop (Item being manipulated) from (Hero manipulating item)
        • Else - Actions
 
Level 28
Joined
Jan 26, 2007
Messages
4,789
First of all: it really isn't a good idea to make a trigger per item.
I highly recommend using either item classes or item levels (for which you only need 1 trigger).

What I always do instead of "Hero - Drop (Item being manipulated) from (Hero manipulating item)", is moving the item to the position of the item.
Although this sounds weird, it does work (and better than just dropping it).
If you drop the item, it should move to the position of the hero (kind of), if you move it to the position of the manipulating item, it doesn't move at all (so you can't move the item all across the map).

Try doing that.
Don't forget to remove the location leak!
 
Level 15
Joined
Sep 27, 2009
Messages
676
First of all: it really isn't a good idea to make a trigger per item.
I highly recommend using either item classes or item levels (for which you only need 1 trigger).

What I always do instead of "Hero - Drop (Item being manipulated) from (Hero manipulating item)", is moving the item to the position of the item.
Although this sounds weird, it does work (and better than just dropping it).
If you drop the item, it should move to the position of the hero (kind of), if you move it to the position of the manipulating item, it doesn't move at all (so you can't move the item all across the map).

Try doing that.
Don't forget to remove the location leak!

Yea, but I need to make level requirement.
Example: I have some items that needs 7 lvl hero.
Example 2: Mail Armor (3 classes) Leather (2) Cloth armor (3 classes)
How should i make this??? can you make me trigger for 1 item, i'll try to figure it out :wink:
 
Status
Not open for further replies.
Top