Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


pointing one object at another

This topic is 5939 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have two objects rotating around a third, and I would like one of these objects always pointing at another. How can I find this information? I have the X,Y,Z coordinates of each. But how do I point one (say its top) at the other?

Share this post

Link to post
Share on other sites
find the diffrence between them, and use arctangent to find the angle, ie


make the heading for the 2nd object revolving around the center object the angle above, that should keep it pointing in the right direction

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!