%, chance, random
Hello guys!
I'm wondering how to calculate ACCURATE chance to do something. At the moment I use that script but it's lame and doesn't calculate right chance. Code:
Can anyone manage how to be more accurate with setting %chance? |
Re: %, chance, random
That is how to do it. If you want an alternative, have a look at the random functions from xs.inc.
Code:
xs_seed(seed) |
Re: %, chance, random
Sorry, but I'm new in Pawn and I don't know really what structure should I build. Would you help me?
|
Re: %, chance, random
so xs_irand_range gives better results than random_num i presume ?
|
Re: %, chance, random
I bet. But can you give me example of usage?
|
Re: %, chance, random
Quote:
Code:
static cell AMX_NATIVE_CALL core_random(AMX *amx,cell *params) |
Re: %, chance, random
I though seed was hardcoded seeing xs code.
|
Re: %, chance, random
Quote:
|
Re: %, chance, random
I feel like
http://www.gagful.com/uploads/2012_4..._doing_gag.jpg when reading it. Can anyone put new function and cvar, please? |
Re: %, chance, random
Quote:
|
| All times are GMT -4. The time now is 06:15. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.