Cast value to State, add missing newline

This commit is contained in:
Nathan Lovato 2019-12-24 10:30:39 +01:00
parent 1e73557106
commit e24388a778
2 changed files with 2 additions and 2 deletions

View file

@ -14,7 +14,7 @@ var _parent: State = null
func _ready() -> void:
yield(owner, "ready")
_parent = get_parent()
_parent = get_parent() as State
func unhandled_input(event: InputEvent) -> void:

View file

@ -58,4 +58,4 @@ func _on_Player_health_depleted() -> void:
func _on_Events_checkpoint_visited(checkpoint_name: String) -> void:
last_checkpoint = LevelLoader._level.get_node("Checkpoints/%s" % checkpoint_name)
last_checkpoint = LevelLoader._level.get_node("Checkpoints/%s" % checkpoint_name)