if(strcmp(cmdtext,"/admins",true)==0)
{
new string[128];
SendClientMessage(playerid,0x00CD00FF,"Admins online");
for(new i;i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(IsPlayerAdmin(i))
{
new name[24];
GetPlayerName(i,name,sizeof(name));
format(string,sizeof(string),"Nome: %s [ID: %i]",name,i);
SendClientMessage(playerid,0x0000FFFF,string);
}
}
}
return 1;
}
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\pawno\include\dini.inc(239) : warning 219: local variable "string" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(59) : warning 219: local variable "string" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(60) : warning 219: local variable "name" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(73) : warning 219: local variable "string" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(102) : warning 219: local variable "string" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(563) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(566) : error 021: symbol already defined: "SendClientMessage"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(567) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(569) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(571) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(574) : error 021: symbol already defined: "GetPlayerName"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(580) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(585) : warning 203: symbol is never used: "name"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(585) : warning 203: symbol is never used: "string"
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
7 Errors.
59: new string[128];
60: new name[24];
73: new pname[MAX_PLAYER_NAME], string[22 + MAX_PLAYER_NAME];
102: new pname[MAX_PLAYER_NAME], string[39 + MAX_PLAYER_NAME];
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(563) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(566) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(568) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(570) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(578) : error 010: invalid function or declaration
if(!strcmp(cmdtext, "/admins", true))
{
SendClientMessage(playerid, 0x00CD00FF, "(INFO) Checando por administradores on-line...");
new count=0;
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(IsPlayerAdmin(i))
{
new str[128];
new pname[24];
GetPlayerName(i, pname, 24);
format(str, 128, "Nome: [%s] | [ID: %d] ", pname, playerid);
SendClientMessage(playerid, -1, str);
count++;
}
}
}
}
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(73) : warning 219: local variable "pname" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(102) : warning 219: local variable "pname" shadows a variable at a preceding level
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(563) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(567) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(569) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(571) : error 010: invalid function or declaration
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(575) : error 021: symbol already defined: "GetPlayerName"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(584) : warning 203: symbol is never used: "count"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(584) : warning 203: symbol is never used: "pname"
C:\Documents and Settings\Hwak v1\Meus documentos\MyServer (STAP)\Server\gamemodes\hwakworld.pwn(584) : warning 203: symbol is never used: "str"
if(strcmp(cmdtext, "/admins", true) == 0)
{
new Jogador[24];
new count = 0;
new msg[120];
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && IsPlayerAdmin(i))
{
GetPlayerName(i,Jogador,24);
format(msg,sizeof(msg),"Nome: [%s] | ID: [%d]", Jogador,playerid);
SendClientMessage(playerid, 0x000FFFAA, msg);
count++;
}
}
if(count == 0)
{
SendClientMessage(playerid, -1, "Nгo tem nenhum adm online agora!");
}
return 1;
}
tenta
pawn Код:
|
if(!strcmp(cmdtext, "/admins", true))
{
SendClientMessage(playerid, 0x00CD00FF, "(INFO) Checando por administradores on-line...");
new count = 0;
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && IsPlayerAdmin(i))
{
new str[70], pname[MAX_PLAYER_NAME];
GetPlayerName(i, pname, 24);
format(str, 70, "Nome: [%s] | [ID: %d] ", pname, playerid);
SendClientMessage(playerid, -1, str);
count++;
}
}
if(count == 0) {
SendClientMessage(playerid, -1, "Sem admins online.");
}
return 1;
}
Vocк nгo sabe o que й return nгo?
pawn Код:
|