15.12.2012, 01:29
fis um aqui mano no meu gm deu certo ve ai no seu
@EDIT:talves de alguns loose indentation dai tente desse jeito
pawn Код:
COMMAND:darskin(playerid, params[])
{
new Msg[158], Skinid, id, nome[MAX_PLAYER_NAME], admnome[MAX_PLAYER_NAME], msg[158];
if (APlayerData[playerid][LoggedIn] == true)
{
if (APlayerData[playerid][PlayerLevel] >= 0)
{
if (sscanf(params, "ui",id, Skinid)) SendClientMessage(playerid, 0xFF0000AA, "Use: /darskin [playerid] [id(0-299)]");
else
{
if ((Skinid >= 0) && (Skinid <= 299))
{
GetPlayerName(playerid,admnome,sizeof(admnome));
GetPlayerName(id,nome,sizeof(nome));
SetPlayerSkin(playerid, Skinid);
format(Msg, 158, "Vocк mudou a skin do %s para %i", nome, Skinid);
SendClientMessage(playerid, 0x00FF00, Msg);
format(msg, 158, "O Adm: %s Mudou sua skin para %i", admnome, Skinid);
SendClientMessage(id, 0x00FF00, msg);
}
else
SendClientMessage(playerid, 0xFF0000, "id da skin invalida ids: 0-299");
}
return 1;
}
pawn Код:
COMMAND:darskin(playerid, params[])
{
new Msg[158], Skinid, id, nome[MAX_PLAYER_NAME], admnome[MAX_PLAYER_NAME], msg[158];
if (APlayerData[playerid][LoggedIn] == true)
{
if (APlayerData[playerid][PlayerLevel] >= 0)
{
if (sscanf(params, "ui",id, Skinid)) SendClientMessage(playerid, 0xFF0000AA, "Use: /darskin [playerid] [id(0-299)]");
else
{
if ((Skinid >= 0) && (Skinid <= 299))
{
SetPlayerSkin(playerid, Skinid);
format(Msg, 158, "Vocк mudou a skin do %s para %i", nome, Skinid);
SendClientMessage(playerid, 0x00FF00, Msg);
format(msg, 158, "O Adm: %s Mudou sua skin para %i", admnome, Skinid);
SendClientMessage(id, 0x00FF00, msg);
}
else
SendClientMessage(playerid, 0xFF0000, "id da skin invalida ids: 0-299");
}
}
else
return 0;
}
else
return 0;
return 1;
}