Closed pfgithub closed 4 years ago
Yup, you're completely right. Thanks for the feedback, I'll get right to it.
Should work now. Feel free to reopen if it doesn't
PS: you mixed up enumToInt
and intToEnum
. The latter would have worked before this fix, but with raylib-zig I'm trying to avoid conversions as much as possible, to improve code readability.
intToEnum
is what I meant, and that didn't work before the fix because the enum is exhaustive and 0 is not a valid option. I didn't try, but I'm assuming it would also trigger a runtime panic if I forced it to be runtime.
Currently, this is required to disable the exit key:
This would be nicer if the KeyboardKey enum was non-exhaustive, then it would be,
or if KeyboardKey had a null option,