• 🏆 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] Kill System

Status
Not open for further replies.
Level 12
Joined
Mar 23, 2008
Messages
942
When someone die, the killer always get 200 gold...
Why?

  • FirstBlood
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Dying unit) is A Hero) Equal to True
      • ((Dying unit) is an illusion) Equal to False
      • ((Owner of (Dying unit)) slot status) Equal to Is playing
    • Actions
      • Trigger - Turn off (This trigger)
      • Trigger - Turn on Kill <gen>
      • Game - Display to (All players) the text: ((Player_Colors[(Player number of (Owner of (Killing unit)))] + ((Name of PlayerHero[(Player number of (Owner of (Killing unit)))]) + |r )) + ( pwned + ((Name of (Dying unit)) + ( for + ((String(Bounty[(Player number of (Owner of (Dying unit)))])) + gold!)
      • Game - Display to (All players) the text: ((Name of PlayerHero[(Player number of (Owner of (Killing unit)))]) + ( just drew + ((|cffff0000 + (First Blood + |r)) + (+ 200 gold!))))
      • Player - Add Bounty[(Player number of (Owner of (Dying unit)))] to (Owner of (Killing unit)) Current gold
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Bounty[(Player number of (Owner of (Dying unit)))] Greater than or equal to 100
        • Then - Actions
          • Set Bounty[(Player number of (Owner of (Dying unit)))] = (Bounty[(Player number of (Owner of (Dying unit)))] - (20 x KillsCombo[(Player number of (Owner of (Dying unit)))]))
        • Else - Actions
          • Set Bounty[(Player number of (Owner of (Dying unit)))] = 100
      • Set KillsCombo[(Player number of (Owner of (Dying unit)))] = 1
      • Set KillsCombo[(Player number of (Owner of (Killing unit)))] = (KillsCombo[(Player number of (Owner of (Killing unit)))] + 1)
      • Set Points_Kill[(Player number of (Owner of (Killing unit)))] = (Points_Kill[(Player number of (Owner of (Killing unit)))] + 1)
      • Set Points_Death[(Player number of (Owner of (Dying unit)))] = (Points_Death[(Player number of (Owner of (Dying unit)))] + 1)
      • Set Bounty[(Player number of (Owner of (Killing unit)))] = (Bounty[(Player number of (Owner of (Dying unit)))] + 20)
      • Sound - Play firstblood <gen>
      • Countdown Timer - Start KillingTimer[(Player number of (Owner of (Killing unit)))] as a One-shot timer that will expire in 5.00 seconds
  • Kill
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Dying unit) is A Hero) Equal to True
      • ((Dying unit) is an illusion) Equal to False
      • ((Owner of (Dying unit)) slot status) Equal to Is playing
    • Actions
      • Game - Display to (All players) the text: ((Player_Colors[(Player number of (Owner of (Killing unit)))] + ((Name of PlayerHero[(Player number of (Owner of (Killing unit)))]) + |r )) + ( pwned + ((Name of (Dying unit)) + ( for + ((String(Bounty[(Player number of (Owner of (Dying unit)))])) + gold!)
      • Player - Add Bounty[(Player number of (Owner of (Dying unit)))] to (Owner of (Killing unit)) Current gold
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Bounty[(Player number of (Owner of (Dying unit)))] Greater than or equal to 100
        • Then - Actions
          • Set Bounty[(Player number of (Owner of (Dying unit)))] = (Bounty[(Player number of (Owner of (Dying unit)))] - (20 x KillsCombo[(Player number of (Owner of (Dying unit)))]))
        • Else - Actions
          • Set Bounty[(Player number of (Owner of (Dying unit)))] = 100
      • Set KillsCombo[(Player number of (Owner of (Dying unit)))] = 1
      • Set KillsCombo[(Player number of (Owner of (Killing unit)))] = (KillsCombo[(Player number of (Owner of (Killing unit)))] + 1)
      • Set Points_Kill[(Player number of (Owner of (Killing unit)))] = (Points_Kill[(Player number of (Owner of (Killing unit)))] + 1)
      • Set Points_Death[(Player number of (Owner of (Dying unit)))] = (Points_Death[(Player number of (Owner of (Dying unit)))] + 1)
      • Set Bounty[(Player number of (Owner of (Killing unit)))] = (Bounty[(Player number of (Owner of (Dying unit)))] + 20)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (KillsCombo[(Player number of (Owner of (Killing unit)))] - 1) Equal to 2
          • (Remaining time for KillingTimer[(Player number of (Owner of (Killing unit)))]) Greater than 0.00
        • Then - Actions
          • Game - Display to (All players) the text: ((Player_Colors[(Player number of (Owner of (Killing unit)))] + ((Name of PlayerHero[(Player number of (Owner of (Killing unit)))]) + |r )) + just got a |cffffa000Double Kill|r!)
          • Sound - Play Double_Kill <gen>
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (KillsCombo[(Player number of (Owner of (Killing unit)))] - 1) Equal to 3
              • (Remaining time for KillingTimer[(Player number of (Owner of (Killing unit)))]) Greater than 0.00
            • Then - Actions
              • Game - Display to (All players) the text: ((Player_Colors[(Player number of (Owner of (Killing unit)))] + ((Name of PlayerHero[(Player number of (Owner of (Killing unit)))]) + |r )) + just got a |cff00ff00Triple Kill|r!)
              • Sound - Play triple_kill <gen>
            • Else - Actions
      • Countdown Timer - Start KillingTimer[(Player number of (Owner of (Killing unit)))] as a One-shot timer that will expire in 5.00 seconds
 
Status
Not open for further replies.
Top