Skip to main content
7 events
when toggle format what by license comment
Nov 9, 2011 at 11:40 comment added hiddensunset4 @zacharmarz Fixed, forgot to write that in originally cheers. It was a simply as just offsetting the direction to begin with. No need to use matrices to transform the coordinate spaces; unless you start moving coordinate systems around arbitrarily.
Nov 9, 2011 at 11:39 history edited hiddensunset4 CC BY-SA 3.0
added 131 characters in body
Nov 9, 2011 at 10:49 comment added zacharmarz No. You understood me wrong. By this, you shift yout NewPos somewhere (you take tanks position), but you do not transfer it to global coordinate system, because you don't take tanks rotation into account. So your options are: compute transformation matrix, which recomputes vector from tanks coordinate system to global coordinate system. Or it should be enough just to recompute angle in the beginning of your computation.
Nov 9, 2011 at 10:03 history edited hiddensunset4 CC BY-SA 3.0
added 8 characters in body
Nov 9, 2011 at 10:03 comment added hiddensunset4 @zacharmaz I already mentioned that, you first compute it in the source Tank's coordinate space, then to transfer it you just add the Tanks position in the world space (see end of my answer).
Nov 9, 2011 at 9:49 comment added zacharmarz I think this will compute bad NewPos vector. It takes angle as it is related with global coordinate system. But it's related to local tank coordinate system given by tank direction vector and vector perpendicular to it. You should first recompute angle - substract part of angle, which is under X axis.
Nov 9, 2011 at 9:34 history answered hiddensunset4 CC BY-SA 3.0