20.01.2014, 14:53
Ou ...
й sу vocк por onde seta o cargo da org a Skin por exemplo
e la onde compra skin, por algo para o player nгo poder trocar
por exemplo
й sу vocк por onde seta o cargo da org a Skin por exemplo
PHP Code:
if ( !strcmp(cmd,"/recrutarorg", true))
{
new plid, skin;
tmp = strtok(cmdtext, idx);
if (!strlen(tmp))
return SendClientMessage(playerid, -1, "** Digite: /recrutarorg [id] [ 1 a 2 ]");
plid = strval(tmp);
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
return SendClientMessage(playerid, -1, "** Digite: [id] [ 1 a 2 ]");
skin = strval(tmp);
if(!IsPlayerConnected(plid))
return SendClientMessage(playerid, -1, "** Jogador nгo conectado.");
new aname[MAX_PLAYER_NAME];
GetPlayerName(playerid, aname, MAX_PLAYER_NAME);
new pname[MAX_PLAYER_NAME];
GetPlayerName(plid, pname, MAX_PLAYER_NAME);
format(file, sizeof(file), PASTA_CONTAS, pname);
switch ( skin )
{
case 0:
{
format(string, sizeof(string), "» O Dono da Org: %s (%d) (») retirou o jogador: %s (%d) da [ORG].", aname,playerid,pname,plid);
SendClientMessageToAll(-1, string);
SetPlayerSkin(playerid, 0);
}
case 1:
{
format(string, sizeof(string), "» O Dono da Org: %s (%d) (») Promoveu: %s (%d) para Patente 1 da [ORG].", aname,playerid,pname,plid,skin);
SendClientMessageToAll(-1, string);
SetPlayerSkin(playerid, 2);
}
case 2:
{
format(string, sizeof(string), "» O Dono da Org: %s (%d) (») Promoveu: %s (%d) para Patente 2 da [ORG].", aname,playerid,pname,plid,skin);
SendClientMessageToAll(-1, string);
SetPlayerSkin(playerid, 10);
}
default: SendClientMessage(playerid, -1, "** Skin invalida! Use valores de 0 a 8!");
}
return 1;
}
por exemplo
PHP Code:
if(InfoP[playerid][Org])
{
SendClientMessage(playerid, -1, "Vocк й membro de uma org, e nгo pode trocar sua skin");
return 1;
}