Warcraft III resources & community, 2003–2006 · archived

75 % chance to effect.

2 posts
#1

75 % chance to effect.

Ok, ill start from that i'm not really advanced from math. I want to make 75 % chance to my skill that finishes enemies that are below 30 % of health.

So i made :

Set chance_ex = (Random integer number between 1 and 2)

And if chance_ex will be 1 then it will proc, but thats 50 % chance. How i will make a 75% with that? Random number between 1 and 3 = 33 %, between 1 and 4 = 25 % etc. I hope you understand what i mean, im not best in english ;)
#2
dont use a variable, u can just use an integer variable => math random number => random numbere between 1 and 100 is equal to or less then 75