Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | HarryCourt | |
Old Version | Published before Godot 3 was released. |
I’m trying to make some code that once the player has collided with another KinematicBody2D, which has a Sprite and a CollisionShape2D as its child, It will make itself hidden or delete itself. Am I on the right track with this code?
extends KinematicBody2D
func _ready():
set_fixed_process(true)
func _fixed_process(delta):
if is_colliding():
self.hide()