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

PLAYER LEAVES GAME (2 Questions)

Status
Not open for further replies.
Level 30
Joined
Jul 31, 2010
Messages
5,248
ohglob.jpg

1) How to remove or hide this multiboard when a player leaves the game?

2) When a player leaves the game, how can I let all of his units and buildings be destroyed? or kill them to prevent them from being used by team players?
 
Last edited:
View attachment 118502

1) How to remove or hide this multiboard when a player leaves the game?

2) When a player leaves the game, how can I let all of his units and buildings be destroyed? or kill them to prevent them from being used by team players?

saves the multiboard that you create to a multiboard variable.

  • Multiboard - Create a multiboard with 1 columns and 1 rows, titled Bla Bla Bla
  • Set Your Multiboard Variable = (Last Created Multiboard)

then do this :

  • Leaver
    • Events
      • Player - Player 1 (Red) leaves the game
      • Player - Player 2 (Blue) leaves the game
      • Player - Player 3 (Teal) leaves the game
      • Player - Player 4 (Purple) leaves the game
      • Player - Player 5 (Yellow) leaves the game
      • Player - Player 6 (Orange) leaves the game
      • Player - Player 7 (Green) leaves the game
      • Player - Player 8 (Pink) leaves the game
      • Player - Player 9 (Gray) leaves the game
      • Player - Player 10 (Light Blue) leaves the game
      • Player - Player 11 (Dark Green) leaves the game
      • Player - Player 12 (Brown) leaves the game
    • Conditions
    • Actions
      • Multiboard - Destroy (Your Multiboard Variable)
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units owned by (Triggering Player)) and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)
Note :
- Leaver is a Unit Group variable.
- Custom script: call DestroyGroup (udg_Leaver) is a custom script to destroy group(which is causing leaks),
 
Last edited:
Status
Not open for further replies.
Back
Top