• 🏆 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!

[Trigger] Set Items

Status
Not open for further replies.
Level 7
Joined
Dec 8, 2008
Messages
243
Casual set item trigger. Click on the item, or pick it up, since it's actively used on pick-up, and this happens.
The trigger searched the triggering units inventory in inventory spaces 1 to 6 for the items required to make the item. I figure it's going wrong because in the conditions I'm using "AND", and since it's 1 to 6 (and this is just what I think), it needs all 1 to 6 to be that item, which is why it's going wrong.

In the mean time, I'm gunna bury my face into my pillow and dream ASCII girls. If anyone could help me out...

...with the trigger


...I'll be very greatful.

Nighty-night, HIVE.

  • Gambit Set
    • Events
      • Unit - A unit Uses an item
    • Conditions
      • (Item being manipulated) Equal to (Item carried by (Triggering unit) of type [|cff32cd32SET ITEM|r] Gambit's Shadow)
    • Actions
      • 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
              • And - All (Conditions) are true
                • Conditions
                  • (Item carried by (Triggering unit) in slot (Integer A)) Equal to (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's hood of Mischeif)
                  • (Item carried by (Triggering unit) in slot (Integer A)) Equal to (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's boots of swiftness)
                  • (Item carried by (Triggering unit) in slot (Integer A)) Equal to (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's Pocket Knife)
            • Then - Actions
              • Item - Remove (Item being manipulated)
              • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's Pocket Knife)
              • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's boots of swiftness)
              • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's hood of Mischeif)
              • Hero - Create [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's ShadowSet and give it to (Triggering unit)
            • Else - Actions
 
Level 13
Joined
Mar 24, 2010
Messages
950
You dont need to set it up this way at all.

Theres no need for the 1-6 loop, also if you were to do it this way you should have a skip remaining actions after Hero - create etc..

get rid of the if then else and the Int A loop first off.
Then use the conditions (triggering unit has (item of type)) for all the items you want it to have, i see you have 3 in your example above.

then just have your triggers under your "then actions" and thats it, its a very simple trigger you over complicated lol xD


Edit:

made a quick example..
  • Untitled Trigger 001
    • Events
      • Unit - A unit Uses an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to [|cff32cd32SET ITEM|r] Gambit's Shadow)
      • ((Triggering unit) has an item of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's Pocket Knife)) Equal to True
      • ((Triggering unit) has an item of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's boots of swiftness)) Equal to True
      • ((Triggering unit) has an item of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's hood of Mischeif)) Equal to True
    • Actions
      • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's Pocket Knife)
      • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's boots of swiftness)
      • Item - Remove (Item carried by (Triggering unit) of type [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's hood of Mischeif)
      • Hero - Create [|cff7777aaLvl 3|r] [|cff32cd32SET ITEM|r] Gambit's ShadowSet and give it to (Triggering unit)
If the item is used when acquired and then gone you dont need to removed it with trigger

Done :)
 
Level 7
Joined
Dec 8, 2008
Messages
243
Thanks. I decided to stick around and try and work it out myself, but I didn't think of using booleans. I thought you could only have more than one condition if you use AND, or, OR, but hey, awesome :) learn something new everyday... or. night in this case.
 
Status
Not open for further replies.
Top