Skripta koju koristim: moja
Detaljan opis problema: ustimao sam da se igracu kad mu glad i wc dodje do 0 smanjuju helti, ali kada dodje do 0 nista se ne desava u cemu je problem?
Dio skripte:
public GladWCCheck() {
for(new i=0;i<MAX_PLAYERS;i++) {
if(IsPlayerConnected(i)) {
new Float:phealth; GetPlayerHealth(i, phealth);
GiveGlad(i, -1);
if(GetPVarInt(i, "glad") < 0) { SetPVarInt(i, "glad", 0); SetPlayerHealth(i, phealth-10); }
GiveWC(i, -1);
if(GetPVarInt(i, "wc") < 0) { SetPVarInt(i, "wc", 0); SetPlayerHealth(i, phealth-10); }
UpdateGladWCText(i); } }
return 1; }
tako sam uradio