Hell, I’m not convinced anyone has a good sense of how to do it. I’m still not sure I have a good sense of how to do it. And, I note: structuring a software project is hard, and you only really get a good sense of how to do it from experience. This raises the question of how I want to structure this project in general. Cats love to be in little boxes, you see. All that code that’s specific to him should be put off in a little box somewhere. Star Anise is part of the game, but he isn’t the whole game. That doesn’t really sit right with me as the main entry points, they should be about updating and drawing the game itself. Adding some structureĪs of where I left off last time, my special _update() and _draw() functions are mostly full of code for updating and drawing Star Anise. Also, collision detection is a big fucking hairy mess, so I definitely want to be able to shove it in a corner somewhere I’ll never have to look at it again.Ī good start would be to build towards having a corner to shove it into. That’s perfectly fine when he’s the only thing in the game, but I don’t expect he’ll stay alone for long! Collision detection in particular is a pretty major component of a platformer, so I definitely want to be able to reuse it for other things in the game. Everything I’ve written is designed to work for Star Anise and only Star Anise. Luckily for you, someone else has already written it: me!īefore I can get to that, though, I need to add some structure to the code I have so far. Collision detection is a real big pain in the ass to write, so needing it this early is a hell of a big spike in the learning curve. I’m going to need it, and I’m going to need it real soon.Īnd, hey, that sucks. What I am trying to say here is that I feel the looming spectre of collision detection hanging over me. The problem with gravity is that it means things are always moving downwards, and if there’s nothing to stop them, they will continue off indefinitely into the void. Most conspicuously, this is going to be a platformer, so I need gravity.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |