Fix win screen bug
This commit is contained in:
parent
444bacb717
commit
24aa4aea4b
3 changed files with 3 additions and 2 deletions
|
@ -78,7 +78,7 @@ func _process(delta: float) -> void:
|
|||
|
||||
rand = randi_range(0, 1)
|
||||
|
||||
if not Persister.get_value("building_mode"):
|
||||
if not Persister.get_value("building_mode") and Persister.get_value("flood_level", PersisterEnums.Scope.UNKNOWN, 0) < level:
|
||||
if rock_spots.has(tile):
|
||||
last_text = NAME_ICON.instantiate()
|
||||
last_text.text = "[center]Rock"
|
||||
|
|
|
@ -17,3 +17,4 @@ flood_levels[]
|
|||
1
|
||||
0
|
||||
5
|
||||
0
|
||||
|
|
|
@ -21,7 +21,7 @@ func _process(delta: float) -> void:
|
|||
|
||||
Persister.change_value("days", 1)
|
||||
|
||||
if current_flood_state > globals.flood_levels.size():
|
||||
if current_flood_state >= globals.flood_levels.size() + 1:
|
||||
Persister.persist_data("win", true)
|
||||
return
|
||||
|
||||
|
|
Loading…
Reference in a new issue