• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

Simple trigger

Status
Not open for further replies.

ECP_Ozz

E

ECP_Ozz

Ok so i'm no good at triggers, I would like to ask someone to, well instead of making me a trigger tell me how to make it. I want a set up where every 50 kills a player makes he/she would receive 1 peice of lumber. Please be in-depth if it's not too much trouble as, again im not really that good with triggers.
 
Variables (you can edit those by pressing cntrl + B in the trigger editor)

Name: Variable (pick another name if you wish)
Type: Integer
Array: 12 (One for each player)
Initial Value: 0


Triggers

Trigger 1
Event: A unit dies
Condition: None (unless you only want E.g. neutral hostile kills to be counted...)
Action: Set Variable [(Player number of (Owner of (Killing unit)))]
= Variable [(Player number of (Owner of (Killing unit)))] + 1

Trigger 2
Event: a unit dies
Condition: Integer Comparison - Variable [(Player number of (Owner of (Killing unit)))] Equal to 50
Action: Set Variable [(Player number of (Owner of (Killing unit)))] Equal to 0
Add 1 to (Owner of (Killing unit))'s current Lumber
 
Status
Not open for further replies.
Back
Top