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

[Trigger] Leaving players

Status
Not open for further replies.
Theres a simple event called player-player leaves game or something like that^^

Other possibility:

  • Check
  • Events
    • Time - Every 10.00 seconds of game time
  • Conditions
  • Actions
    • For each (Integer A) from 1 to 12, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • 'IF'-Conditions
            • ((Player((Integer A))) slot status) equal to Left the Game
          • 'Then'-Actions
            • (Insert your actions)
          • 'Else'-Actions
Off-Topic: Hurray, 200th post.
 
Level 6
Joined
Sep 5, 2007
Messages
264
What you could do is use a trigger to detect it a player leaves, setting a boolean variable, EG: Player_Left_Game(index) = true

You could then use your periodic check to see if that variable is true. If you don't want to pick-up the same player over and over, use another boolean variable, EG: Player_Leaving_Done(index) = true. Then when you look through your list of players, just check the "Player_Left_Game" variable, if true, then check the "Player_Leaving_Done" variable, if that's false, then set it to true and do the rest of your actions.

Hope I've enlightened... :thumbs_up:
 
Level 14
Joined
Jul 1, 2008
Messages
1,314
What you could do is use a trigger to detect it a player leaves, setting a boolean variable, EG: Player_Left_Game(index) = true

You could then use your periodic check to see if that variable is true. If you don't want to pick-up the same player over and over, use another boolean variable, EG: Player_Leaving_Done(index) = true. Then when you look through your list of players, just check the "Player_Left_Game" variable, if true, then check the "Player_Leaving_Done" variable, if that's false, then set it to true and do the rest of your actions.

Hope I've enlightened... :thumbs_up:

that would be completely unnessecairy, because one trigger with Event "a Player leaves" would be enough
 
Level 6
Joined
Sep 5, 2007
Messages
264
That's true.

But, if they are using a periodic event, then obviously they are trying to get all the players that have left the game, in say the last 10 seconds, at once.

I fully agree with you there, if you want it to trigger immediately, then that is obviously the best solution. But, what if you don't?
 
Level 9
Joined
Jun 7, 2008
Messages
440
Your definately right. i dont want it to notify all the remaining players immediatly though it may happen, i wanted it to be completely random even when the player left it would take up to (i said 10 seconds, but it could be anything) <lets say x amount of seconds> It has to be random to be fair (i think anyway. And since it is my map :p

.
Edit. As well, i wonder what i would use to make that trigger work.
I kinda get what your saying, but im still new to formalizing triggers myself. perhaps you could elaborate.
 
Status
Not open for further replies.
Top