With a family and a full time job, free time that I can dedicate to my own pursuits (as opposed to spending time with my wife playing board games, for example) is limited and I have a lot of activities to spread around in there. Sometimes what catches my focus is development, sometimes it’s playing around on my guitar a little, and sometimes it’s actually playing games. This week it’s been a little of all three columns, skewed a bit more in favour of game playing due to the release of Stardew Valley.
Nevertheless, some progress has been made! This week I got some code written and finished editing the second part of my small series on vector math; it occurred to me that I never actually pointed out where these things can be found. So lets fix that!
The site sidebar has an option named GameDev Math which is itself a page that links to all of the current “articles” along with a brief description. In addition, it’s also the head of a little menu structure to allow you to find a page directly as well.
There are now two pages on vector math, the definition of a vector and the basics of math with them. If you read these please send me some feedback (e.g. on twitter @OdatNurd) to let me know how coherent they seem. Although they’re kind of short it’s been taking me a while to get them to a state that I’m happy with. Tentatively (stuff is written but not finalized yet) the next will be on the dot product and what you might use it for.
Although I am (or was) a big math nerd long ago, I want these to be more accessible, showing you how to do something with a little bit of an explanation, but nothing overly rigorous. I don’t think it’s important to get bogged down in the finer points if they’re not necessary to get results, although I do like the idea of providing at least some small amount of background knowledge to provide initial avenues of investigation for people. That’s tend to be how I learn best, as I’m more of a learn by doing kind of guy.
Since this is a game development related update, lets mention a little about that as well.
I’m a little closer to the current goal, which is to provide more complex line intersections with rectangles and circles. Currently my Collider class does not handle collisions with objects that are rotated, but it would be easy (or easier) to implement that fully with what I’m currently working on. I do have some code written in a separate test bed application that I’m using for testing before final integration, but it’s a little bit flakey and could use a little cleanup besides.
My ultimate goals are to have code that works even if that means that it’s not optimized; having something that is easy to read and see what is happening is usually more important to me. At this stage, I think it’s important important to be able to follow how things are fitting together since in the end something like Unity would be doing the heavy lifting anyway.
Progress has not been quite as fast as one might like, but I’m OK with that. I’m not setting out to set the world on fire or anything, I’m mostly in this just to have fun, and (believe it or not) hashing out the specifics of vector math very much falls in my wheelhouse in that regard. I’ve always been a guy that likes to learn just for learning’s sake.
That’s part of the reason why I’m focusing on this aspect right now while working on a Pong game, which most certainly does not require complex code of this type; one of my goals is to get some articles written about the math of game development, and this seems like a good impetus to doing it.
That’s all for this week’s update; I’m hoping that I will have some code to actually publicly share next week, time (and Stardew Valley) willing.