mirror of https://github.com/dirtbags/tanks.git
Fix bug with 0 rand
This commit is contained in:
parent
933d4746ab
commit
e0947dcc57
|
@ -175,6 +175,7 @@ forf_proc_random(struct forf_env *env)
|
|||
|
||||
if (max < 1) {
|
||||
forf_push_num(env, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
forf_push_num(env, rand() % max);
|
||||
|
|
Loading…
Reference in New Issue