How do I make this happen, like what code would I use?
(red is the original force, green is gravity, blue is the path that the earth "follows")
double mouseangle = direction(xscreen, yscreen, object.x, object.y);
vectoradd(&angle, &directional_velocity, mouseangle, 1);
directional_velocity = min(directional_velocity, 10);
if(!earthHit)
{
double mouseangle = direction(xscreen, yscreen, object.x, object.y);
vectoradd(&angle, &directional_velocity, mouseangle, 1);
directional_velocity = min(directional_velocity, 10);
}
Users browsing this forum: No registered users and 1 guest