Here's a little snippet for ya all :)
It lists out all the players in the player file. Have fun!
In act.informative.c add this stuff:
extern struct player_index_element *player_table;
extern int top_of_p_table;
ACMD(do_players)
{
int i, count = 0;
for (i = 0; i <= top_of_p_table + 1; i++) {
sprintf(buf, "%s %-20.20s", buf, (player_table + i)->name);
count++;
if (count == 3) {
count = 0;
send_to_char(buf, ch);
send_to_char("\r\n", ch);
sprintf(buf, "");
}
}
}
Now in interpeter.c add this junk:
ACMD(do_players);
{ "players" , POS_DEAD , do_players , 0, 0 },
Have fun!!!! Let me know if there's any problems with this!
Justin - Primacy
http://wired.uvm.edu/~jmrobins/
jmrobins@wired.uvm.edu
telnet to:wired.uvm.edu 4000 (Ruin! MUD)
This archive was generated by hypermail 2b30 : 12/07/00 PST