K/D Ratio
#1

OKay so heres my script for the K/D ratio. and it doesnt seem to be working u might wanna take a look

pawn Код:
new playerkill[256];
new playerdeath[256];
new Float:KD;
pawn Код:
OnPlayerConnect(playerid)
{
    playerkill[playerid] = 0;
    playerdeath[playerid] = 0;
}
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
        SendDeathMessage(killerid, playerid, reason);
        playerkill[killerid]++;
        playerdeath[playerid]++;

        KD = floatdiv(playerkill[killerid],playerdeath[killerid]);
        new string[32];
        format(string,32, "%.2f",KD);
        TextDrawSetString(Textdraw3[killerid],string);

        KD = floatdiv(playerkill[playerid],playerdeath[playerid]);
        format(string,32, "%.2f",KD);
        TextDrawSetString(Textdraw3[killerid],string);
   
        return 1;
}
the KD doesnt increase at all.. its always 0.00
Reply


Messages In This Thread
K/D Ratio - by spd_sahil - 08.11.2011, 18:46
Re: K/D Ratio - by Stigg - 08.11.2011, 18:49
Re: K/D Ratio - by spd_sahil - 08.11.2011, 18:51
Re: K/D Ratio - by SmiT - 08.11.2011, 18:53
Re: K/D Ratio - by Stigg - 08.11.2011, 18:53
Re: K/D Ratio - by spd_sahil - 08.11.2011, 18:58
Re: K/D Ratio - by Stigg - 08.11.2011, 19:02
Re: K/D Ratio - by [03]Garsino - 08.11.2011, 19:03
Re: K/D Ratio - by spd_sahil - 08.11.2011, 19:08
Re: K/D Ratio - by [03]Garsino - 08.11.2011, 20:27

Forum Jump:


Users browsing this thread: 1 Guest(s)