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

Please Help My Trigger

Status
Not open for further replies.
Level 3
Joined
Feb 14, 2013
Messages
26
  • Events
    • Unit - A unit Is attacked
    • Conditions
      • ((Attacking unit) belongs to an ally of Player12) Equal to True
      • ((Attacking unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Unit-type of (Attacking unit)) Equal to Infernal
        • Then - Actions
          • Set Real = 6.00
          • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Unit-type of (Attacking unit)) Equal to Skeleton Warrior
            • Then - Actions
              • Set Real = 3.00
              • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
            • Else - 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 (Attacking unit)) Equal to Dreadlord
                      • (Unit-type of (Attacking unit)) Equal to Death Knight
                      • (Unit-type of (Attacking unit)) Equal to Lich
                      • (Unit-type of (Attacking unit)) Equal to Mini Lord
                • Then - Actions
                  • Set Real = (3.00 + ((Real((Agility of (Attacking unit) (Include bonuses)))) x 1.90))
                  • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
                • Else - Actions
      • Set Real = 0.10
      • Hashtable - Save 0.00 as (Key Ctime) of (Key (Attacking unit)) in Hashtable
      • Hashtable - Save Real as (Key Mtime) of (Key (Attacking unit)) in Hashtable
      • Hashtable - Save Handle Of(Triggering unit) as (Key target) of (Key (Attacking unit)) in Hashtable
      • Unit Group - Add (Attacking unit) to Group_gold
purpose of this trigger is :
when an unit attacks on the enermies or tower of enermies, the unit will receive an amount of gold
but when gamer controls the unit pressing "S" (Stop) continiously the unit will not lose HP and still recieving gold.
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
  • Events
    • Unit - A unit Is attacked
    • Conditions
      • ((Attacking unit) belongs to an ally of Player12) Equal to True
      • ((Attacking unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Unit-type of (Attacking unit)) Equal to Infernal
        • Then - Actions
          • Set Real = 6.00
          • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Unit-type of (Attacking unit)) Equal to Skeleton Warrior
            • Then - Actions
              • Set Real = 3.00
              • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
            • Else - 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 (Attacking unit)) Equal to Dreadlord
                      • (Unit-type of (Attacking unit)) Equal to Death Knight
                      • (Unit-type of (Attacking unit)) Equal to Lich
                      • (Unit-type of (Attacking unit)) Equal to Mini Lord
                • Then - Actions
                  • Set Real = (3.00 + ((Real((Agility of (Attacking unit) (Include bonuses)))) x 1.90))
                  • Hashtable - Save Real as (Key damage) of (Key (Attacking unit)) in Hashtable
                • Else - Actions
      • Set Real = 0.10
      • Hashtable - Save 0.00 as (Key Ctime) of (Key (Attacking unit)) in Hashtable
      • Hashtable - Save Real as (Key Mtime) of (Key (Attacking unit)) in Hashtable
      • Hashtable - Save Handle Of(Triggering unit) as (Key target) of (Key (Attacking unit)) in Hashtable
      • Unit Group - Add (Attacking unit) to Group_gold
purpose of this trigger is :
when an unit attacks on the enermies or tower of enermies, the unit will receive an amount of gold
but when gamer controls the unit pressing "S" (Stop) continiously the unit will not lose HP and still recieving gold.

maybe because u dont removed from group?

where the trigger what remove unit from Group_gold?
 
Level 3
Joined
Feb 14, 2013
Messages
26
maybe because u dont removed from group?
where the trigger what remove unit from Group_gold?
  • GoldS3
    • Events
      • Unit - A unit Is issued an order targeting an object
      • Unit - A unit Is issued an order targeting a point
      • Unit - A unit Is issued an order with no target
    • Conditions
      • ((Ordered unit) belongs to an ally of Player12) Equal to True
    • Actions
      • Unit Group - Remove (Ordered unit) from Group_gold
this is it
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
  • GoldS3
    • Events
      • Unit - A unit Is issued an order targeting an object
      • Unit - A unit Is issued an order targeting a point
      • Unit - A unit Is issued an order with no target
    • Conditions
      • ((Ordered unit) belongs to an ally of Player12) Equal to True
    • Actions
      • Unit Group - Remove (Ordered unit) from Group_gold
this is it

then like others said use the DDS (i think bribe dds easy to implent also enough gui friendly too) then u add gold in set damage trigger and dont need unit group anymore and ur 1st trigger, just a if
 
Status
Not open for further replies.
Top