Report as inappropriate.
This code is a demo for the rotator class that enables actors to rotate around a specific point on screen. In this demo, the robot rotates around a ball that can be dragged anywhere.
Source code is avilable, along with a fairly detailed commentary of the maths behind the positioning, so if you're interested in how it's done you should be able to follow - nothing hideously complicated though you do need to use the sine rule.
I've felt the need for a method like this in a few scenarios so if others have as well, hope this helps.
If you just want the Rotator.java file, visit the web site link.
8963 views / 8 in the last 7 days
4 votes | 0 in the last 7 days
This scenario is a member of: Reusable actors & support classes
Want to leave a comment? You must first log in.