Is it possible....?
#1

Is it possible to make a kill/death ratio system?
Today i tried to do something similar but i ["COLOR=RED"]FAILED[/"COLOR"]
Anyways could somebody give me an idea or if its possible give me an example of a K/D System?
Reply
#2

Probably your kills/deaths variables are integers. So:
pawn Код:
new Float:rat;
rat = float(YourKillsVariable[playerid])/float(YourDeathsVariable[playerid]);

//---A way to print it:
format(array,sizeof(array),"Your ratio: {FF0000}%.2f",rat);
//%.2f because if you get. 1.5999999 that will print just 1.59
Good luck!
Reply
#3

Thank you
+rep.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)