CameraTools.updateScrollWheelZoom

This commit is contained in:
2022-06-27 14:03:26 +00:00
parent 41af3009bb
commit 4b72739a9c
3 changed files with 12 additions and 6 deletions

View File

@@ -83,11 +83,7 @@
(method &override :Void update [:Float elapsed]
(super.update elapsed)
// scroll to zoom:
#{
if (FlxG.mouse.wheel != 0) {
FlxG.camera.zoom += (FlxG.mouse.wheel / 10);
}
}#
(worldCamera.updateScrollWheelZoom elapsed 1)
// F1 to toggle fullscreen:
(when FlxG.keys.justPressed.F1
(set FlxG.fullscreen !FlxG.fullscreen))