resetGameData参数更高级
This commit is contained in:
@@ -137,11 +137,11 @@ function scene.keyDown(key)
|
||||
GAME.prevBG=BG.cur
|
||||
SCN.go("setting_sound")
|
||||
elseif key=="r"then
|
||||
resetGameData(false,false)
|
||||
resetGameData()
|
||||
SCN.swapTo("play","none")
|
||||
elseif key=="p"then
|
||||
if(GAME.result or GAME.replaying)and #PLAYERS==1 then
|
||||
resetGameData(true,false)
|
||||
resetGameData("r")
|
||||
SCN.swapTo("play","none")
|
||||
end
|
||||
elseif key=="o"then
|
||||
|
||||
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user