diff --git a/source/KadeEngineData.hx b/source/KadeEngineData.hx index 5ae671a..39275f3 100644 --- a/source/KadeEngineData.hx +++ b/source/KadeEngineData.hx @@ -81,6 +81,9 @@ class KadeEngineData if (FlxG.save.data.customStrumLine == null) FlxG.save.data.customStrumLine = 0; + if (FlxG.save.data.camzoom == null) + FlxG.save.data.camzoom = true; + Conductor.recalculateTimings(); PlayerSettings.player1.controls.loadKeyBinds(); KeyBinds.keyCheck(); diff --git a/source/Options.hx b/source/Options.hx index 1d6208c..770568e 100644 --- a/source/Options.hx +++ b/source/Options.hx @@ -614,3 +614,23 @@ class BotPlay extends Option private override function updateDisplay():String return "BotPlay " + (FlxG.save.data.botplay ? "on" : "off"); } + +class CamZoomOption extends Option +{ + public function new(desc:String) + { + super(); + description = desc; + } + public override function press():Bool + { + FlxG.save.data.camzoom = !FlxG.save.data.camzoom; + display = updateDisplay(); + return true; + } + + private override function updateDisplay():String + { + return "Camera Zoom " + (!FlxG.save.data.camzoom ? "off" : "on"); + } +} diff --git a/source/OptionsMenu.hx b/source/OptionsMenu.hx index 9d690e7..03cf31c 100644 --- a/source/OptionsMenu.hx +++ b/source/OptionsMenu.hx @@ -39,15 +39,14 @@ class OptionsMenu extends MusicBeatState new CustomizeGameplay("Drag'n'Drop Gameplay Modules around to your preference") ]), new OptionCategory("Appearance", [ - #if desktop new DistractionsAndEffectsOption("Toggle stage distractions that can hinder your gameplay."), + new CamZoomOption("Toggle the camera zoom in-game."), + #if desktop new RainbowFPSOption("Make the FPS Counter Rainbow"), new AccuracyOption("Display accuracy information."), new NPSDisplayOption("Shows your current Notes Per Second."), new SongPositionOption("Show the songs current position (as a bar)"), new CpuStrums("CPU's strumline lights up when a note hits it."), - #else - new DistractionsAndEffectsOption("Toggle stage distractions that can hinder your gameplay.") #end ]), diff --git a/source/PlayState.hx b/source/PlayState.hx index b5107eb..25c04c3 100644 --- a/source/PlayState.hx +++ b/source/PlayState.hx @@ -3458,25 +3458,28 @@ class PlayState extends MusicBeatState // FlxG.log.add('change bpm' + SONG.notes[Std.int(curStep / 16)].changeBPM); wiggleShit.update(Conductor.crochet); - // HARDCODING FOR MILF ZOOMS! - if (curSong.toLowerCase() == 'milf' && curBeat >= 168 && curBeat < 200 && camZooming && FlxG.camera.zoom < 1.35) + if (FlxG.save.data.camzoom) { - FlxG.camera.zoom += 0.015; - camHUD.zoom += 0.03; + // HARDCODING FOR MILF ZOOMS! + if (curSong.toLowerCase() == 'milf' && curBeat >= 168 && curBeat < 200 && camZooming && FlxG.camera.zoom < 1.35) + { + FlxG.camera.zoom += 0.015; + camHUD.zoom += 0.03; + } + + if (camZooming && FlxG.camera.zoom < 1.35 && curBeat % 4 == 0) + { + FlxG.camera.zoom += 0.015; + camHUD.zoom += 0.03; + } + + iconP1.setGraphicSize(Std.int(iconP1.width + 30)); + iconP2.setGraphicSize(Std.int(iconP2.width + 30)); + + iconP1.updateHitbox(); + iconP2.updateHitbox(); } - if (camZooming && FlxG.camera.zoom < 1.35 && curBeat % 4 == 0) - { - FlxG.camera.zoom += 0.015; - camHUD.zoom += 0.03; - } - - iconP1.setGraphicSize(Std.int(iconP1.width + 30)); - iconP2.setGraphicSize(Std.int(iconP2.width + 30)); - - iconP1.updateHitbox(); - iconP2.updateHitbox(); - if (curBeat % gfSpeed == 0) { gf.dance();