Originally Posted by myrroddin
I should point out that checking for 1/nil does not work as per above. If you do find a 1/nil, you will have to check, but there are a few ways.
|
That's not actually the case. Lua's if statement works with any value, not just booleans. nil and false are false-equivalent, all other values are true-equivalent.
if a then will still work as expected if a is 1/nil instead of true/false.