• 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.
  • It's time for the first HD Modeling Contest of 2025. Join the theme discussion for Hive's HD Modeling Contest #7! Click here to post your idea!

[General] Revolving unit control based on player absence?

Status
Not open for further replies.
Level 19
Joined
Feb 19, 2009
Messages
855
Need a little help with a player system in my newest map. There are four players in the playable force. I want to make it so that if one leaves, the now-empty player is set to treat every other player as an ally with shared unit control. I need to have this work for every single one of the first four players to make sure that a game is never ruined by a missing player, and don't no matter who leaves and who is left, all four armies can still be controlled.

Any help with this?
 
Level 29
Joined
Aug 29, 2012
Messages
1,292
Did you try using something simple like this?

  • Temp
    • Evénements
      • Joueur - Joueur 1 (Rouge) leaves the game
      • Joueur - Joueur 2 (Bleu) leaves the game
      • Joueur - Joueur 3 (Cyan) leaves the game
      • Joueur - Joueur 4 (Pourpre) leaves the game
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 4, do (Actions)
        • Boucle - Actions
          • Joueur - Make (Player((Integer A))) treat (Triggering player) as an Allié avec partage complet vue et unités
Sorry, my editor's in French, last line should be something like "ally with full shared vision and units". Also, this is assuming human players are players 1 - 4.
 
Level 19
Joined
Feb 19, 2009
Messages
855
Did you try using something simple like this?

  • Temp
    • Evénements
      • Joueur - Joueur 1 (Rouge) leaves the game
      • Joueur - Joueur 2 (Bleu) leaves the game
      • Joueur - Joueur 3 (Cyan) leaves the game
      • Joueur - Joueur 4 (Pourpre) leaves the game
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 4, do (Actions)
        • Boucle - Actions
          • Joueur - Make (Player((Integer A))) treat (Triggering player) as an Allié avec partage complet vue et unités
Sorry, my editor's in French, last line should be something like "ally with full shared vision and units". Also, this is assuming human players are players 1 - 4.

What is this "player((Integer A))" line? I can't figure out how to duplicate this in my editor.
 
Last edited:
Status
Not open for further replies.
Top