![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | blinkingcape |
im have this script:
extends Area2D
func _on_body_entered(body):
if body.name == “CharacterBody2D”:
get_tree().change_scene(“res://level2.tscn”)
but when i enter in the flag it just crash and give this error:
Invalid call. Nonexistent function ‘change_scene’ in base ‘SceneTree’.