roguelike-tutorial
roguelike-tutorial copied to clipboard
Bonus chapter idea: split to multiple files
Show how to use modules and organise the dodebase into more than one file. That seems to be the most controversial aspect of the original tutorial. And it seems to me, modules trip beginners out.
I think this is a great idea. Would like to see the original python code split up, too; it's so easy, there's no excuse for not making this modular. Rust is a little more difficult; it took me a while to figure out the use of mod, use, and extern (just noticed I have a relic of this my ui code...). It's not particularly difficult, but for me at least this didn't seem well documented.
I split things out into separate modules as soon as I finished the tutorial, here. A work in progress and I'm not sure the divisions are completely valid, but it got me started.
Not sure how much this helps, but I split most of the files in this commit.
Completely agree, module chapter would be great.
Thanks, I think so too. Not sure when I'll be able to put the work in, though. So the issues are all up for taking :-).