OnPlayerUpdate problem
#6

instead of using it on OnPlayerUpdate try it on this:-

pawn Код:
new UpdatingTimer[MAX_PLAYERS];

public OnPlayerConnect(playerid)
{
   UpdatingTimer[playerid] = SetTimerEx("UpdatePlayer", 1000, true, "i", playerid);
   return 1;
}

public OnPlayerDisconnect(playerid)
{
   KillTimer(UpdatingTimer[playerid]);
   return 1;
}

forward UpdatePlayer(playerid);
public UpdatePlayer(playerid);
{
   new string[128], playerid, Float:ratio = floatdiv(PlayerInfo[playerid][Kills], PlayerInfo[playerid][Deaths]);
   format(string, sizeof(string), "~y~Score: ~w~%d~n~~y~Money: ~w~$%d~n~~y~Kills: ~w~%d~n~~y~Deaths: ~w~%d~n~~y~K/D Ratio: ~w~%0.2f", GetPlayerScore(playerid), GetPlayerMoney(playerid), PlayerInfo[playerid][Kills], PlayerInfo[playerid][Deaths], ratio);
   TextDrawSetString(Textdraw[playerid], string);
   TextDrawShowForPlayer(playerid, Textdraw[playerid]);
   return 1;
}
Reply


Messages In This Thread
OnPlayerUpdate problem - by Fantje - 14.03.2015, 09:38
Re: OnPlayerUpdate problem - by CalvinC - 14.03.2015, 09:52
Re: OnPlayerUpdate problem - by Fantje - 14.03.2015, 09:52
Re: OnPlayerUpdate problem - by PrivatioBoni - 14.03.2015, 09:58
Re: OnPlayerUpdate problem - by Fantje - 14.03.2015, 10:24
Re: OnPlayerUpdate problem - by ReD_HunTeR - 14.03.2015, 10:35
Re: OnPlayerUpdate problem - by Fantje - 14.03.2015, 10:45
Re: OnPlayerUpdate problem - by Tamer - 14.03.2015, 10:50
Re: OnPlayerUpdate problem - by Vince - 14.03.2015, 11:02
Re: OnPlayerUpdate problem - by Pottus - 14.03.2015, 14:29

Forum Jump:


Users browsing this thread: 1 Guest(s)