Need some help with this formula to calculate kill death ratio
#3

Quote:
Originally Posted by Rav
pawn Код:
new Float: ratio;
if (kills[killerid] > 0 && deaths[killerid] > 0)
  ratio = kills[killerid] / deaths[killerid];
else
  ratio = 0;
then use the variable to save it, it looks much cleaner
Ehh no thanks, it's only one line to calculate the ratio. Can anyone fix that up for me?

I just need this part fixed up

Код:
(dUserINT(PlayerName(killerid)).("kills")/(dUserINT(PlayerName(killerid)).("deaths")));
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)