Jump to content

Recommended Posts

I am using opengl with java light weight game library and I am trying to figure out how Kevin Forbes programmed the selection of objects in the game. I can currently ray cast out of my 3d perspective camera, and have the ray detect if it collided with a box the size of the object (say a tree), but in Don't Starve, it can detect if the mouse collided with the tree outline and it ignores the transparent parts of the .png tree. How did Kevin program this? I am very impressed by it, and just can't figure it out! I am trying to implement this in code in my own game. Thank you very much for responses!

Link to comment
https://forums.kleientertainment.com/forums/topic/69918-programming-question/
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...