Currently, I am in the process of creating a mouse-controlled roulette without using canvas or SVG. Instead, I am relying solely on CSS3 rotation and some jQuery.
My goal is to allow users to rotate the wheel by moving their mouse up and down while clicking and holding it over the roulette. To achieve this, I am utilizing event.offsetY
to track the mouse position and adjust the wheel's rotation accordingly.
However, I have encountered an issue where the mouse offset position seems to change based on the wheel's rotation. Is there a way to maintain the true mouse offset position relative to the document?
-Alternatively-
Does anyone have a better idea for implementing this functionality?
You can view the code here: http://jsfiddle.net/MZxgp/ (compatible with Chrome only)
Thank you in advance!