resetGameData参数更高级

This commit is contained in:
MrZ626
2020-12-21 08:37:15 +08:00
parent a97fc8b53a
commit a38e1f201d
4 changed files with 10 additions and 9 deletions

View File

@@ -30,7 +30,7 @@ function scene.sceneInit()
love.keyboard.setKeyRepeat(false)
GAME.restartCount=0
if GAME.init then
resetGameData(false,false)
resetGameData()
GAME.init=nil
end
noKey=GAME.replaying
@@ -204,7 +204,7 @@ function scene.update(dt)
elseif P1.keyPressing[10]then
GAME.restartCount=GAME.restartCount+1
if GAME.restartCount>20 then
resetGameData(false,false)
resetGameData()
return
end
elseif GAME.restartCount>0 then