The y coordinate of the mouse translated to the camera view.
Moving or zooming the camera will not change sprite positions nor the values of World.mouseX
and World.mouseY
. camera.mouseY values are not limited to the size of the display area. As the camera moves down the camera.mouseY values will increase, as the camera moves up the camera.mouseY values will decrease.
function draw() { background("white"); camera.y=World.mouseY; text("worldMouseY"+World.mouseY,World.mouseY,200); text("camera.y"+ camera.y,World.mouseY,225); text("cameraMouseY"+camera.mouseY,World.mouseY,250); }
camera.mouseY
The y coordinate of the mouse translated to the camera view.
Found a bug in the documentation? Let us know at documentation@code.org