PDA

View Full Version : [317] a Better ::player for Delta [317] Snippet



Xdragon
June 20th, 2010, 19:48
You need only to copy and paste lol

Open client.java and do this whith your other Commands:


if (command.equalsIgnoreCase("players")) {
sM("There are currently " + PlayerHandler.getPlayerCount()
+ " players!");
sendQuest("@dre@SERVERNAME - Online Players", 8144);
clearQuestInterface();
sendQuest("@dbl@Online players(" + PlayerHandler.getPlayerCount()
+ "):", 8145);
int line = 8146;
for (int i = 1; i < PlayerHandler.maxPlayers; i++) {
client playa = getClient(i);
if (!validClient(i))
continue;
if (playa.playerName != null) {
String title = "";
if (playa.playerRights == 1) {
title = "Mod, ";
} else if (playa.playerRights == 2) {
title = "Admin, ";
}
title += "level-" + playa.combatLevel;
String extra = "";
if (playerRights > 0) {
extra = "(" + playa.playerId + ") ";
}
sendQuest("@dre@" + extra + playa.playerName + "@dbl@ ("
+ title + ") is at " + playa.absX + ", "
+ playa.absY, line);
line++;
}
}
sendQuestSomething(8143);
showInterface(8134);
flushOutStream();
}
If that Dont work try this one :

if (command.equalsIgnoreCase("players")) {
sM("There are currently " + onlinePlayers + " players!");
sendQuest("@dre@SERVERNAME - @RED@O@bla@@blu@n@bla@@gre@line@bla@ @red@Players@bla@", 8144);
clearQuestInterface();
sendQuest("@dbl@Online players(" + PlayerHandler.getPlayerCount()
+ "):", 8145);
int line = 8146;
for (int i = 1; i < PlayerHandler.maxPlayers; i++) {
client playa = getClient(i);
if (!validClient(i))
continue;
if (playa.playerName != null) {
String title = "";
if (playa.playerRights == 1) {
title = "Mod, ";
} else if (playa.playerRights == 2) {
title = "Admin, ";
}
title += "level-" + playa.combatLevel;
String extra = "";
if (playerRights > 0) {
extra = "(" + playa.playerId + ") ";
}
sendQuest("@dre@" + extra + playa.playerName + "@dbl@ ("
+ title + ") is at " + playa.absX + ", "
+ playa.absY, line);
line++;
}
}
sendQuestSomething(8143);
showInterface(8134);
flushOutStream();
}

I didnt make this i dont know who did but i thought more helpful threads more people here :D
So no Credit for me !
Have fun!

Ninga Nun
June 21st, 2010, 16:51
Nice Custom ::yell =p ty and ty for the person who originally made it
:) :) :) :) :) :) :) :) :) :) :)

Xdragon
June 21st, 2010, 17:27
Yw :p

Malik
June 21st, 2010, 18:39
Wait, this command like also shows all the total online players too?

TehCow
June 21st, 2010, 19:01
Wait, this command like also shows all the total online players too?

Obviously:
i'ts like

PlayerHandler.getPlayerCount+ That aint correct I know. ;)

TehCow
June 21st, 2010, 19:02
It should be:

+ PlayerHandler.getPlayerCount()
+ ")
but sometimes it's just
+ onlinePlayers + etc.

Xdragon
June 21st, 2010, 19:12
Oh lol Il edit the players thing

TehCow
June 21st, 2010, 19:17
Try:


if (command.equalsIgnoreCase("players")) {
sM("There are currently " + PlayerHandler.getPlayerCount()
+ " players!");
sendQuest("@dre@SERVERNAME - Online Players", 8144);
clearQuestInterface();
sendQuest("@dbl@Online players(" + PlayerHandler.getPlayerCount()
+ "):", 8145);
int line = 8146;
for (int i = 1; i < PlayerHandler.maxPlayers; i++) {
client playa = getClient(i);
if (!validClient(i))
continue;
if (playa.playerName != null) {
String title = "";
if (playa.playerRights == 1) {
title = "Mod, ";
} else if (playa.playerRights == 2) {
title = "Admin, ";
}
title += "level-" + playa.combatLevel;
String extra = "";
if (playerRights > 0) {
extra = "(" + playa.playerId + ") ";
}
sendQuest("@dre@" + extra + playa.playerName + "@dbl@ ("
+ title + ") is at " + playa.absX + ", "
+ playa.absY, line);
line++;
}
}
sendQuestSomething(8143);
showInterface(8134);
flushOutStream();
}
If that Dont work try this one :

if (command.equalsIgnoreCase("players")) {
sM("There are currently " + onlinePlayers + " players!");
sendQuest("@dre@SERVERNAME - @RED@O@bla@@blu@n@bla@@gre@line@bla@ @red@Players@bla@", 8144);
clearQuestInterface();
sendQuest("@dbl@Online players(" + PlayerHandler.getPlayerCount()
+ "):", 8145);
int line = 8146;
for (int i = 1; i < PlayerHandler.maxPlayers; i++) {
client playa = getClient(i);
if (!validClient(i))
continue;
if (playa.playerName != null) {
String title = "";
if (playa.playerRights == 1) {
title = "Mod, ";
} else if (playa.playerRights == 2) {
title = "Admin, ";
}
title += "level-" + playa.combatLevel;
String extra = "";
if (playerRights > 0) {
extra = "(" + playa.playerId + ") ";
}
sendQuest("@dre@" + extra + playa.playerName + "@dbl@ ("
+ title + ") is at " + playa.absX + ", "
+ playa.absY, line);
line++;
}
}
sendQuestSomething(8143);
showInterface(8134);
flushOutStream();
}

What effect does that give?
It makes your digits and numbers a colour. I will make a teaching tut on that.

XxBryantD
June 21st, 2010, 20:04
thanks

P r 0 tank
September 16th, 2010, 14:58
v nic===e

Prototype'
September 21st, 2010, 08:11
if(command.equalsIgnoreCase"players")) {
sM("there are currently " + onlinePlayers + " players online.");

Or


if (command.equalsIgnoreCase("players")) {
sM("There are currently sM("There are currently " + PlayerHandler.getPlayerCount()
+ " players!");
Doesn't take lots of space just a simple command,you can do that id you want but takes a lot of space.

Deadly a g s
September 25th, 2010, 10:18
@tehcow What's so hard about adding @blu@Players Online:
Because that's all you did, no need for a teaching tutorial on it
:S

Deviation
September 26th, 2010, 01:18
got this for PI?