Citat: Dzanan_Beg poslato Januar 24, 2016, 19:18:45 POSLE PODNE
sigurno imas definisano negdje za max helt ili slicno
Imam samo ovo new Float:Health; GetPlayerHealth(playerid, Health);
if(Health > HeltiIgraca[playerid])
{
SetPlayerHealth(playerid, HeltiIgraca[playerid]);
return 1;
}
Citat: Deci poslato Januar 24, 2016, 19:36:33 POSLE PODNE
Daj komandu /aduty.
Evo:
YCMD:aduty(playerid, params[], help)
{
#pragma unused help
#pragma unused params
if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"LoB:RP | "CRVENA"Moras se ulogirati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] == 0) return SCM(playerid, -1, ""CRVENA"LoB:RP © "BELA"Samo Admini!");
new string[256];
if(AdminDuty[playerid] == 0)
{
format(string,sizeof(string),""CRVENA"(( "BELA"Administrator "CRVENA"%s "BELA"je na duznosti,za pomoc kucajte "ZUTA"/pitaj "CRVENA"))",GetName(playerid));
SCMTA(-1,string);
AdminDuty[playerid] = 1;
SetPlayerColor(playerid, 0xFF0000FF);
SetPlayerArmour(playerid, 99.0);
g_SetPlayerHealth(playerid, 9999.0);
g_GivePlayerWeapon(playerid, 14, 1);
}
else if(AdminDuty[playerid] == 1)
{
SetPlayerArmour(playerid, 0);
g_SetPlayerHealth(playerid, 99.0);
ResetPlayerWeapons(playerid);
format(string,sizeof(string),""CRVENA"(( "BELA"Administrator "CRVENA"%s "BELA"vise nije na duznosti "CRVENA"))",GetName(playerid));
SCMTA(-1,string);
SetPlayerColor(playerid, BELA2);
AdminDuty[playerid] = 0;
}
return 1;
}