I was stucked on the question: “What do I going todo now? SW:ToR or some music creation?”.
I just couldn’t decide. But I assumed, I had wish to play some SW:ToR PvPs to about 70%, and I would like to drop a 7/3 coin instead of a classic 1/1 coin.
A bit of quick JavaScript helped me through:
1
decide=function(x){returnMath.random()*100<x;}
This should return true with a probality of x %….
I was quite sure, the random number must be less then x, but did some tests to prove it: