Commit 6e3b6d0c authored by Neoony's avatar Neoony
Browse files

Added showing @Lobby or @servername when players are in lobby or when Game On! server

parent 1c5d2096
......@@ -206,6 +206,7 @@ function RefreshSQL()
}
var HighestCurPopulation = 0;
var HighestPopServer;
for (i = 0; i < numberofservers; i++)
{
......@@ -214,6 +215,7 @@ function RefreshSQL()
if (HighestCurPopulation < playersx[i])
{
HighestCurPopulation = playersx[i];
HighestPopServer = i;
}
playersoutoflobby = playersoutoflobby + playersx[i];
......@@ -244,14 +246,14 @@ function RefreshSQL()
client.user.setStatus('available');
//client.user.setActivity(numberofallplayers + ' players');
client.user.setPresence({ game: { name: "with " + playersinlobby + " players", type: "Playing", url: "https://empiresmod.com"}});
client.user.setPresence({ game: { name: "with " + playersinlobby + " players @Lobby", type: "Playing", url: "https://empiresmod.com"}});
}
if (playersinlobby == 1 && playersoutoflobby < 8)
{
client.user.setStatus('available');
//client.user.setActivity(numberofallplayers + ' players');
client.user.setPresence({ game: { name: "with " + playersinlobby + " player", type: "Playing", url: "https://empiresmod.com"}});
client.user.setPresence({ game: { name: "with " + playersinlobby + " player @Lobby", type: "Playing", url: "https://empiresmod.com"}});
}
if (playersinlobby == 0 && playersoutoflobby < 8)
......@@ -265,13 +267,15 @@ function RefreshSQL()
client.user.setStatus('available');
//client.user.setActivity(numberofallplayers + ' players');
client.user.setPresence({ game: { name: "Game On!", type: "Playing", url: "https://empiresmod.com"}});
client.user.setPresence({ game: { name: "Game On!" + " @" + namex[HighestPopServer], type: "Playing", url: "https://empiresmod.com"}});
}
messageServerOn += "```CSS\n" + "Total number of players: " + numberofallplayers + "\nServers: " + numberofservers + "\n" + "```";
if (numberofallplayers == 0)
{
//client.user.setActivity('Waiting for players');
client.user.setPresence({ game: { name: "Waiting for players", type: "Playing", url: "https://empiresmod.com"}});
client.user.setStatus('idle');
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment