From c4ca095b410780f90d4957358e7fde86e22f45b6 Mon Sep 17 00:00:00 2001 From: Hyper_ <40342021+NotHyper-474@users.noreply.github.com> Date: Sun, 13 Oct 2024 13:43:12 -0300 Subject: [PATCH] Replace deprecated screenX/Y in MouseUtil --- source/funkin/util/MouseUtil.hx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/funkin/util/MouseUtil.hx b/source/funkin/util/MouseUtil.hx index 5248437a8f..fa498a9a5a 100644 --- a/source/funkin/util/MouseUtil.hx +++ b/source/funkin/util/MouseUtil.hx @@ -28,13 +28,13 @@ class MouseUtil if (jusPres) { oldCamPos.set(target.x, target.y); - oldMousePos.set(FlxG.mouse.screenX, FlxG.mouse.screenY); + oldMousePos.set(FlxG.mouse.viewX, FlxG.mouse.viewY); } if (pressed) { - target.x = oldCamPos.x - (FlxG.mouse.screenX - oldMousePos.x); - target.y = oldCamPos.y - (FlxG.mouse.screenY - oldMousePos.y); + target.x = oldCamPos.x - (FlxG.mouse.viewX - oldMousePos.x); + target.y = oldCamPos.y - (FlxG.mouse.viewY - oldMousePos.y); } }