How to make player die when it walks into enemy or vice versa?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Amateur.game.dev.

I’m creating my first godot 2D platformer game but am having some issues regarding then enemies. I have looked online for days but nothing works, I have no idea how to kill the player. Could I have some help please?

Edit: I have created a die animation for when the player dies and also a game over animation that queues the die animation

There’s barely any information about your game or what exactly you’re struggling with, so answering your question properly is more or less impossible.

Have you worked through the “Your first game”-section of the docs? While not about a platforming game, it contains everything you’d need: how to implement enemies that move around and how to trigger a gameover-screen once they are touched.

njamster | 2020-08-31 16:29