Okay! I will chime in my solution, which is more general but may or may not 
work for you. Play around with it and see if it does work for you:

Substract the position of the follower ship, B, from the position of the 
player, A. This is the distance between the two. If you divide the distance 
by its norm you get an unit vector pointing in the direction of the player. 
Multiply it by a constant, the speed of the follower ship, and you get a 
velocity in the direction of the player.

velocity = speed * (A - B) / ||A - B||

Here is some sample code:
http://pastebin.com/8TVrN8eg

-- 
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pyglet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to