• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Trigger] Item - Recipe - Upgrade?

Status
Not open for further replies.

Rui

Rui

Level 41
Joined
Jan 7, 2005
Messages
7,550
icon4.gif
Sticky: Is your TRIGGER NOT WORKING? Post on Triggers & Scripts!

Post any trigger-related (except scratch trigger-creation) on Triggers & Scripts, please!
~Thread Moved
 
Level 3
Joined
Mar 27, 2005
Messages
38
ok sry
btw my trigger "Item2 + Item1 = Item3" is the same like the one in my post, I just switched the items in the Thread.
 
Level 4
Joined
Aug 1, 2007
Messages
66
I suggest you use Diablo_DK's recipe system, which can be found here in the spell section. Just search in the spell section for item and look for the one made by Diablo_DK. You may have to learn a little bit of jass, but not much as it has good directions. It'll make all your item combinations very simple.
 
Level 3
Joined
Mar 27, 2005
Messages
38
Hi, i got another problem with this trigger:
  • Untitled Trigger 001
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Claws of Attack +15
    • Actions
      • For each (Integer A) from 1 to 6, do (If ((Item-type of (Item carried by (Hero manipulating item) in slot (Integer A))) Equal to Claws of Attack +15) then do (Set ItemAmount = (ItemAmount + 1)) else do (Do nothing))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ItemAmount Equal to 2
        • Then - Actions
          • Hero - Drop (Item carried by (Hero manipulating item) of type Claws of Attack +15) from (Hero manipulating item)
          • Item - Remove (Last dropped item)
          • Hero - Drop (Item carried by (Hero manipulating item) of type Claws of Attack +15) from (Hero manipulating item)
          • Item - Remove (Last dropped item)
          • Hero - Create Crown of Kings +5 and give it to (Hero manipulating item)
        • Else - Actions
          • Set ItemAmount = 0
It works, but if there are 2 or more Players it does not work, what do i have to change?
 
Level 4
Joined
Aug 1, 2007
Messages
66
You should make the variable an array so each player has a slot. You should probably set the variable back to 0 in your then action as well as your else, or set it to 0 at the begining instead. I think you should be able to remove the item directly without first putting it on the ground as well.
 
Status
Not open for further replies.
Top