So I have an object which is moving in a circular path and enemy in the centre of this circle. I'm trying to find out how to calculate shotingDirection for bullets. Transform.position isn't ennough since bullets will be shooted in last known object position, so I need to predict/calculate object position such way, so bullets would fly in a front, so they could hit object
Suppose I have this information:
Vector3 targetPosition = transform.position;
Vector3 shooterPosition = otherTransform.position;
Vector3 rotationAxis = Vector3.forward; // axis of circle
// in counter-clockwise degrees per second around axis
Vector3 targetAngularVelocity = 90f;
Vector3 circleRadius = 5f; // in world units;
Vector3 projectileVelocity = 5f; // in world units per second;
and I want to find a Vector3 shootDirection
.