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

Leader Board Scour problem

Status
Not open for further replies.
Level 1
Joined
Jan 3, 2014
Messages
4
I am working on a map, 5 vs 5 game, and I want to create a leader board if a player die from team 1 a point would be scoured to team 2 and if a player die from team 2 a point scoured to team 2.

The problem begin here, that at the beginning of the game I create an item and one player of each team need to get this item, the player that get the item become the king of that team, and if the king die the enemy team gain 5 point instead of 1. And what I am having a problem with that when the king die it add one point instead of the 5.

I will be looking forward for your help guys, and thanks.
 
Level 28
Joined
Sep 26, 2009
Messages
2,520
You can check if the dying unit has the item... if yes, you add 5 points, if no, you add 1.

In case the above does not work, I would do it via variables like this:
  • Carries item
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Your_Item
    • Actions
      • Set King1 = (Triggering unit)
  • Loses item
    • Events
      • Unit - A unit Loses an item
    • Conditions
      • (Item-type of (Item being manipulated)) Equal to Your_Item
    • Actions
      • Set King1 = No unit
Then you simply check if the dying unit == King1 ... if yes, add 5 points, else add 1 point.
 
Status
Not open for further replies.
Top