COMMAND:admins(playerid, params[]) { new iname[MAX_PLAYER_NAME], string[180], count=0; SendClientMessage(playerid, AdminColor, "List of online admins:"); for(new i; i < MAX_PLAYERS; i++) { if(level[i] >= 1) { GetPlayerName(i, iname, sizeof(iname)); format(string, sizeof(string), "%s [Level: %i]",iname,level[i]); SendClientMessage(playerid, AdminColor, string); count++; } } if(count==0) SendClientMessage(playerid, AdminColor, "No Online Admins."); return 1; } |
public OnPlayerCommandText(playerid, cmdtext[]) { new cmd[256], idx; cmd = strtok(cmdtext, idx); dcmd(admins, 6, cmdtext); return 0; } dcmd_admins{playerid, params[]} { new iname[MAX_PLAYER_NAME], string[180], count=0; SendClientMessage(playerid, AdminColor, "List of online admins:"); for(new i; i < MAX_PLAYERS; i++) { if(level[i] >= 1) { GetPlayerName(i, iname, sizeof(iname)); format(string, sizeof(string), " %s Level: %i",iname,level[i]); SendClientMessage(playerid, AdminColor, string); count++; } } if(count==0) SendClientMessage(playerid, AdminColor, "No admins online."); return 1; } |
|
E:\GTA San Andreas\Server\pawno\include\dini.inc(239) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(28) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(132) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(172) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(280) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(318) : warning 219: local variable "count" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(337) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(337) : warning 219: local variable "count" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\dutils.inc(379) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\Double-O-Files.inc(131) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\pawno\include\Double-O-Files.inc(613) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(154) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(181) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(188) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(211) : warning 219: local variable "string" shadows a variable at a preceding level
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(227) : error 017: undefined symbol "dcmd"
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(227) : error 017: undefined symbol "admins"
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(227) : error 010: invalid function or declaration
E:\GTA San Andreas\Server\gamemodes\Kopi (2) af DM.pwn(227) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
dcmd_admins(playerid, params[])
{
new iname[MAX_PLAYER_NAME], string[180], count=0;
SendClientMessage(playerid, AdminColor, "List of online admins:");
for(new i; i < MAX_PLAYERS; i++)
{
if(level[i] >= 1)
{
GetPlayerName(i, iname, sizeof(iname));
format(string, sizeof(string), " %s Level: %i",iname,level[i]);
SendClientMessage(playerid, AdminColor, string);
count++;
}
}
if(count==0) SendClientMessage(playerid, AdminColor, "No admins online.");
return 1;
}
dcmd_admins{playerid,params[]}
dcmd_admins(playerid,params[])