• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Need help with spell.

Status
Not open for further replies.
Level 2
Joined
Oct 23, 2011
Messages
28
I wanted to create a recipe spell. so.. now i need to put in multiple stackable items like 2 clarity potions into 1 imba potion.. how do i do that? heres the trigger
  • Recipe
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Hero manipulating item) has an item of type Wood) Equal to True
          • ((Hero manipulating item) has an item of type Wood) Equal to True
        • Then - Actions
          • Item - Remove (Item carried by (Hero manipulating item) of type Wood)
          • Item - Remove (Item carried by (Hero manipulating item) of type Wood)
          • Hero - Create |cFF970707Axe|r and give it to (Hero manipulating item)
          • Special Effect - Create a special effect attached to the overhead of (Hero manipulating item) using Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
          • Wait 2.00 seconds
          • Special Effect - Destroy (Last created special effect)
        • Else - Actions
          • Do nothing
 
Level 17
Joined
Feb 11, 2011
Messages
1,860
  • Trigger
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Wood
    • Actions
      • Set Temp_Point = (Position of (Triggering unit))
      • Unit - Order (Triggering unit) to drop (Item being manipulated) at Temp_Point
      • Custom script: call RemoveLocation(udg_Temp_Point)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) has an item of type Wood) Equal to True
        • Then - Actions
          • Item - Remove (Item being manipulated)
          • Item - Remove (Item carried by (Triggering unit) of type Wood)
          • Hero - Create |cFF970707Axe|r and give it to (Triggering unit)
          • Special Effect - Create a special effect attached to the overhead of (Triggering unit) using Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
          • Special Effect - Destroy (Last created special effect)
        • Else - Actions
          • Hero - Give (Item being manipulated) to (Triggering unit)
- Use Triggering Unit instead of Hero Manipulating Item. It is faster to run.
- You can "destroy" the effect immediately, it will still be created.
- You do not need to use "Do nothing" :D
- Do you want the effect to be created overhead? It would look better attached to origin, unless you want it that way.
 
Level 2
Joined
Oct 23, 2011
Messages
28
Yes, thank you, but that isnt what i asked. I asked how to make recipe trigger with 2 items in 1 slot. example: 2 potions of health in 1 slot and 2 potions of mana in other when u get them it should give u 1 potion of invulnerability... so i used another trigger to make wood stackable its made by filip or smth.
  • Acquire
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Charges remaining in (Item being manipulated)) Not equal to 0
    • 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
              • (Item-type of (Item carried by (Hero manipulating item) in slot (Integer A))) Equal to (Item-type of (Item being manipulated))
              • (Charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A))) Less than (Item level of (Item carried by (Hero manipulating item) in slot (Integer A)))
              • (Item carried by (Hero manipulating item) in slot (Integer A)) Not equal to (Item being manipulated)
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ((Charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A))) + (Charges remaining in (Item being manipulated))) Greater than (Item level of (Item being manipulated))
                • Then - Actions
                  • Item - Set charges remaining in (Item being manipulated) to (((Charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A))) + (Charges remaining in (Item being manipulated))) - (Item level of (Item being manipulated)))
                  • Item - Set charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A)) to (Item level of (Item being manipulated))
                • Else - Actions
                  • Item - Set charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A)) to ((Charges remaining in (Item carried by (Hero manipulating item) in slot (Integer A))) + (Charges remaining in (Item being manipulated)))
                  • Item - Remove (Item being manipulated)
            • Else - Actions
 
Status
Not open for further replies.
Top