I wanted to find a way to get the position of my mouse without moving it (using "mousemove" eventlistener) , because if the screen gets scrolled without the move of a mouse, the coordinants dont match up.
so i planned on getting it to move via adding the offset, !but only when im not getting the right coordinants! .
window.addEventListener("mousemove", myFunction);
function myFunction() {
//offset Code
}
if( event("mousemove") == active) {
//so if i move the mouse this will be active
} else {
//thus not active (and vice versa)
}