mirror of
https://github.com/JHDev2006/Super-Mario-Bros.-Remastered-Public.git
synced 2025-10-22 15:38:14 +00:00
couple fixes, to do with minus world
This commit is contained in:
@@ -81,6 +81,8 @@ func write_save(campaign: String = Global.current_campaign, force := false) -> v
|
||||
save_json = SAVE_TEMPLATE.duplicate(true)
|
||||
match Global.current_game_mode:
|
||||
Global.GameMode.CAMPAIGN:
|
||||
if Global.world_num < 0:
|
||||
Global.world_num = 1
|
||||
if Global.high_score < Global.score:
|
||||
Global.high_score = Global.score
|
||||
save_json["World"] = Global.world_num
|
||||
|
@@ -124,8 +124,6 @@ func get_highscore() -> void:
|
||||
|
||||
func clear_stats() -> void:
|
||||
Global.clear_saved_values()
|
||||
Global.world_num = 1
|
||||
Global.level_num = 1
|
||||
LevelTransition.level_to_transition_to = Level.get_scene_string(Global.world_num, Global.level_num)
|
||||
|
||||
func start_game() -> void:
|
||||
@@ -227,6 +225,8 @@ func quit_game() -> void:
|
||||
get_tree().quit()
|
||||
|
||||
func new_game_selected() -> void:
|
||||
Global.world_num = 1
|
||||
Global.level_num = 1
|
||||
Global.second_quest = false
|
||||
Global.current_game_mode = Global.GameMode.CAMPAIGN
|
||||
if Global.game_beaten:
|
||||
|
Reference in New Issue
Block a user