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

Another Trigger Help!

Status
Not open for further replies.
Level 4
Joined
May 22, 2011
Messages
68
  • HAMode x KillsTeam1
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Unit-type of (Dying unit)) is A Hero) Equal to True
      • ((Playable map area) contains (Dying unit)) Equal to True
    • Actions
      • Set HAMode_KillTeam1_Integer = (HAMode_KillTeam1_Integer + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Killing unit) is in HAMode_KillTeam1) Equal to True
        • Then - Actions
          • Player - Add 1 to Player 1 (Red) Food max
          • Player - Add 1 to Player 2 (Blue) Food max
          • Player - Add 1 to Player 3 (Teal) Food max
          • Player - Add 1 to Player 4 (Purple) Food max
          • Player - Add 1 to Player 5 (Yellow) Food max
          • Game - Display to (All players) for 5.00 seconds the text: 1
        • Else - Actions

Ok heres the deal

ill set up a hero kill limits , lets just say its 20 kills

just like in Hero Arena's, when you kill an enemy unit +1 Kills to that killing unit team.

is this trigger correct??

please help T_T


sorry for my bad english ... :ogre_rage:
 
Level 6
Joined
May 11, 2010
Messages
237
Pretty sure that'll work fine as long as you've made the unit group in a different trigger and you've added the player's heroes to it, otherwise this will go off each time any unit kills any hero . Also you don't need
  • ((Playable map area) contains (Dying unit)) Equal to True
On another note, put these kinds of triggers in the Trigger's and Scripts section (Ones that involve already created triggers)
 
You can use this instead:
  • Death
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • Set Integer = 0
      • For each (Integer Integer) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set WhichPlayer = (Player(Integer))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (WhichPlayer controller) Equal to User
              • ((Triggering unit) belongs to an enemy of WhichPlayer) Equal to True
            • Then - Actions
              • Player - Add 1 to WhichPlayer Food max
            • Else - Actions
WhichPlayer is an Player variable and Integer an Integer one.
 
Status
Not open for further replies.
Top