Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | Lgdn |
Hello
i have a game with a home
i’ve put a area2D in the home to detect if the character is in the home
if he was in the home we can show what is inside the home
else,if we aren’t in the how then we can watch what outside the home
but that doesn’t work
how can i fix this ?
code (body of the character):
extends RigidBody2D
export var wall : NodePath
func onArea2Dareaexited(area):
get_node(wall).visible = true
func onArea2Dareaentered(area):
get_node(wall).visible = false
some images and videos to understand what i whant to do :
Godot version 3.3.2