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

Item permanent bonus

Status
Not open for further replies.
Level 3
Joined
Feb 21, 2012
Messages
38
Guys can u give me a code that is how to make a trigger for-
-A unit buys and item the item is destroyed as soon as it comes in inventory
IF- the item is equal to My Item
Action - Increase damage of all footmen horsemen and militia by 3

PLEASE Give me in format-
"Event-
Unit-Genric unit Event
A unit -________
Condition-"
As i am extremely new to world editor
thanks ina dvance
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
  • Untitled Trigger 001
    • Events
      • Unit - A unit Sells an item (from shop)
    • Conditions
      • (Item-type of (Sold Item)) Equal to Claws of Attack +15
    • Actions
      • Item - Remove (Sold Item)
      • Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Unit-type of (Picked unit)) Equal to Footman
                  • (Unit-type of (Picked unit)) Equal to Militia
            • Then - Actions
              • Unit - Add Item Damage Bonus (+3) to (Picked unit)
            • Else - Actions
this applied the current militia and footmans, but no if u create another later, the best way if u want make to all unit is:

make upgrade what add +3 damagem, add it to footman/militia in object editor and when unit buy that item then increase player -techtree level-your upgrade to level 1
like
  • Player - Set the current research level of Iron Forged Swords to 1 for (Owner of (Buying unit))
 
Level 3
Joined
Feb 21, 2012
Messages
38
Thanks man for ur post but with this thres one problem

it increases the damage once and after that it dont............................................any suggestion?
isnt thre a trigger like -Give all units of type +3 damage

so my real purupose is that -
Anybody buys a particular item-
Item is qual to My Item-
Give all units +3 damage when ever the item is brought
 
Level 3
Joined
Feb 21, 2012
Messages
38
Shadow u didnt got my point see in ur map wen u buy tht item it gives +3 damage to all units but when u buy that item again it remains +3 and not +6
 
Status
Not open for further replies.
Top