Pitching BGM added and implemented in replays

This commit is contained in:
Ishaan Bhardwaj
2023-07-30 04:53:23 -04:00
parent cd90405865
commit a79552a6f3
5 changed files with 15 additions and 2 deletions

View File

@@ -107,6 +107,8 @@ function ReplayScene:onInputPress(e)
e.input == "menu_decide" or
e.input == "retry"
) then
switchBGM(nil)
pitchBGM(1)
self.game:onExit()
loadSave()
love.math.setRandomSeed(os.time())
@@ -126,11 +128,13 @@ function ReplayScene:onInputPress(e)
if self.replay_speed < 1 then
self.replay_speed = 1
end
pitchBGM(self.replay_speed)
elseif e.input == "right" then
self.replay_speed = self.replay_speed + 1
if self.replay_speed > 99 then
self.replay_speed = 99
end
pitchBGM(self.replay_speed)
elseif e.input == "hold" then
self.show_invisible = not self.show_invisible
end