How can you make a command/series of commands happen when N amount of players are in a server?

Discussion in 'Plugin Development' started by die_lolol, Dec 27, 2020.

Thread Status:
Not open for further replies.
  1. Offline

    die_lolol

    So I'm gonna make a duels plugin that when two people are in a server it starts a countdown and does some commands but how would I do this?

    Keep in mind I haven't attached code because I haven't written any yet
     
  2. Offline

    Kars

  3. Offline

    SuperSniper

    If you're using the *entire* server as a duel room, getOnlinePlayers() and the PlayerJoinEvent would be what you want

    but I'm going to assume you wanna have duel "rooms", in which you'd need to keep track of the amount of players in each room, and when someone joins a room, you check the amount of players in that room, then do whatever you need to do
     
Thread Status:
Not open for further replies.

Share This Page