vendredi 9 janvier 2015

Chance of winning PHP percent calculation

I have a "battle" system, the attacker has a battle strength of e.g. 100, the defender has a strength of e.g. 75.


But I'm stuck now, I can't figure out how to find the winner. I know the attacker has a 25% chance of loosing, but I can't figure the script.


Any ideas?





Aucun commentaire:

Enregistrer un commentaire