Well this is unfortunate. I’ve realized that I have neglected to use either normalized vectors or un-normalized vectors all over. So essentially I’m always scrambling to figure out what a given vector really is.
Not to mention that I’ve got my code split into components within itself, that is a unit has itself, then under it, it has its AI and Shooter component. I’m mixing and matching name variables and methods everywhere, it’s getting very easy to get lost.
I imagine if I ever get around to rewriting, I’m going to have to create a class for vectors, with all the methods I can think of, such as length, distance, dot, cross product, atan and all that kind of stuff.
I’m trying to get a cone of vision going, but it’s all zany sized, which makes me think it’s the un/normalized vectors messing with me. I can’t be sure.
Thinking about putting up a link to this blog soon though.