tcod-rs
tcod-rs copied to clipboard
Replace bools with enums where appropriate
Things like setting fullscreen/windowed mode or whether path.walk should recalculate or not should use aptly-named enums instead of an opaque boolean that you have to dig into docs to figure out.
Is it possible that we could also replace the bitflags with enums? Most of them are just mutually exclusive settings anyway (we'd need to keep them internally to pass through to tcod-sys but it's a good opportunity to provide a nicer interface).
I tried to use enums where the values were exclusive and bitflags where you could genuinely specify multiple options at once.
But yeah, I may have missed something and it's quite possible that we can design a better API for the bitflags cases, too.