• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Trigger] Conquer System

Status
Not open for further replies.
Level 36
Joined
Nov 24, 2007
Messages
4,386
So, I have this conquer system on my map, though its a bit leaky.
I'm looking for one of two possible triggers, either one would be great but I cant figure out myself how to make it.

The Conquer system work in the way that when one player kills the others hero that player will ally with the killing player. The problem with this trigger is, that if the player who kills the hero already got a ally, then the killed player and the ally wont ally, they will only both be allyed to the player which conquered them, and not each other.

So, my first possibility is; how can I make it so that when a player gets conquered then he will ally all allies of the killing player as well as the player that killed him?

My second possibility is, how can i make it so that when a player conquers anther then the conquer trigger wont work for those players any more, making it so that every player can ONLY conquer just ONE other player.

Thanks for your time, and I hope someone can help ^^
 
Level 19
Joined
Sep 4, 2007
Messages
2,826
I've been working on a similar system. Modify this to fit your map.
  • Conqure Player
    • Events
      • Unit - A unit Dies
    • Conditions
      • And - All (Conditions) are true
        • Conditions
          • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
          • ((Dying unit) is A Hero) Equal to True
    • Actions
      • Set Attacker = (Owner of (Killing unit))
      • Set Attacked = (Owner of (Dying unit))
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set Current_Player = (Player((Integer A)))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Current_Player is an ally of Attacker) Equal to True
            • Then - Actions
              • Player - Make Attacked treat Current_Player as an Ally with shared vision
              • Player - Make Current_Player treat Attacked as an Ally with shared vision
            • Else - Actions
              • Player - Make Attacked treat Current_Player as an Enemy
              • Player - Make Current_Player treat Attacked as an Enemy
 
Status
Not open for further replies.
Top