I am trying to implement the use of bazooka into AI. I calculate the trajectory of the bullet, but the equations are not really simple to solve:
the parametric coordinates are: x(t) = -m/k * (v0x + W/m)(exp(-k/m * t) -1) -W/m *t + x0 y(t) = -m/k * (v0y + g)(exp(-k/m * t) -1) -g*t +y0 where x0 y0 are the coordinates of the origine of movement (the shooter) k is the air visosity, m is the bullet mass, W the wind value, t is the time. As we are trying to guess the trajectory to shoot the enemy, we know the x and y of the target. So what is missing is v0x and v0y (speed on x and y of the bullet when leaving the weapon) I think it would be really simple to ask something like mathlab or mapple for the exact solution, so if someone has something like that around... On another hand, I am not really sure of my calculations so please feel free to correct me. SG _______________________________________________ Wormux-dev mailing list Wormux-dev@gna.org https://mail.gna.org/listinfo/wormux-dev