mirror of
https://github.com/git-learning-game/oh-my-git.git
synced 2025-05-07 05:02:04 +02:00
return to level menu after chapter is finished
This commit is contained in:
parent
fc2be5214e
commit
7b12cc1467
2 changed files with 9 additions and 2 deletions
scenes
|
@ -124,8 +124,13 @@ func reload_level():
|
|||
load_level(game.current_level)
|
||||
|
||||
func load_next_level():
|
||||
game.current_level = (game.current_level + 1) % levels.chapters[game.current_chapter].levels.size()
|
||||
load_level(game.current_level)
|
||||
game.current_level += 1
|
||||
if game.current_level >= levels.chapters[game.current_chapter].levels.size():
|
||||
|
||||
back()
|
||||
else:
|
||||
load_level(game.current_level)
|
||||
|
||||
|
||||
func show_win_status(win_states):
|
||||
var all_won = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue