05.09.2011, 15:37
pawn Код:
if (strcmp("/status", cmd, true, 8) == 0)
{
Status(playerid);
return 1;
}
PHP код:
SalvarPlayer(playerid)
{
new Float:Vida;
new Float:Colete;
GetPlayerHealth(playerid, Vida);
GetPlayerArmour(playerid, Colete);
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
new String[50];
format(String, sizeof(String), CONTAS, Nome);
dini_IntSet(String,"Dinheiro", GetPlayerMoney(playerid));
dini_FloatSet(String,"Vida", Vida);
dini_FloatSet(String,"Colete", Colete);
dini_IntSet(String,"Matou", Matou[playerid]);
dini_IntSet(String,"Morreu", Morreu[playerid]);
dini_IntSet(String,"Logou", Logou[playerid]);
return 1;
}
SetarPlayer(playerid)
{
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
new String[50];
format(String, sizeof(String), CONTAS, Nome);
GivePlayerMoney(playerid, dini_Int(String,"Dinheiro"));
SetPlayerHealth(playerid, dini_Int(String,"Vida"));
SetPlayerArmour(playerid, dini_Int(String,"Colete"));
Matou[playerid] = dini_Int(String, "Matou");
Morreu[playerid] = dini_Int(String, "Morreu");
Logou[playerid] = dini_Int(String, "Logou");
return 1;
}
Status(playerid)
{
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
new String[128];
SendClientMessage(playerid, 0xFF0000AA, "================================================");
format(String, sizeof(String),"Minhas Informaзхes : %s",Nome);
SendClientMessage(playerid, 0xFFFF00AA,String);
format(String, sizeof(String),"Dinheiro: %d", GetPlayerMoney(playerid));
SendClientMessage(playerid, 0x1E90FFAA,String);
format(String, sizeof(String),"Matou: %d",Matou[playerid]);
SendClientMessage(playerid, 0x1E90FFAA,String);
format(String, sizeof(String),"Morreu: %d",Morreu[playerid]);
SendClientMessage(playerid, 0x1E90FFAA,String);
format(String, sizeof(String),"Vocк Jб Logou %d Vezes Neste Servidor",Logou[playerid]);
SendClientMessage(playerid, 0x1E90FFAA,String);
SendClientMessage(playerid, 0xFF0000AA, "================================================");
return 1;
}