Featured Site
» Posted in the Flash Kit Links section
» Title: Passinglane
» Comments: Since 1996 Passinglane has been providing compelling communication products for business, enterainment and education.
BBM.net is designed to save you time and deliver the highest quality royalty-free music for your multimedia projects. Features include: over 450 Music Loop Packages from some of the best composers in the business, our music search engine to speed your selection process, alternate music versions & bonus sounds to use for rollovers or transitions, free technical support and free consulting.
There are many ways to determine the mouse angle, the main method currently in use involves the use of sine lookup tables and lots of fairly complicated looking loops. What we all want is a fast easy way to determine the mouse angle. This method approximates the angle. The movement of a bullet from the origin to the mouse is also calculated, however this is exact.
Glossary of Terms
Origin - the spot where the mouse angle is relative to. Normalisation - making two values sum to 1, whilst maintaining their relative proportions. Quadrant - the direction of the mouse angle, for this tutorial they are:
up and left
up and right
down and left
down and right