godot icon indicating copy to clipboard operation
godot copied to clipboard

CharacterBody2D sliding off edges of AnimatableBody2D while landing

Open SilverWolveGames opened this issue 9 months ago • 0 comments
trafficstars

Tested versions

Godot v4.4.rc1.mono

System information

Godot v4.4.rc1.mono - Windows 10 (build 19045) - Multi-window, 2 monitors - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3060 (NVIDIA; 32.0.15.6636) - AMD Ryzen 7 5800X 8-Core Processor (16 threads)

Issue description

I’m currently adding a trampoline mechanic to my game, similar to Super Mario Bros 3, in Godot 4.4 rc-1.

To make the trampoline, i’ve used an AnimatableBody2D (the red box in the video), with Sync to Physics checked. When the player stands on, it compresses first, then releases while propelling the player in air. The trampoline is animated with an AnimationPlayer The problem i’m facing though is that when the player (Character Body 2D) stands near an edge, it is curiously pushed away from the trampoline, causing the character to fall on the ground. I’ve shared a video showcasing my project settings, in case.

Steps to reproduce

This video showcases what my issue is, as well as my project settings.

https://github.com/user-attachments/assets/5209468a-e451-4a5f-9c44-bd5be391b65d

Minimal reproduction project (MRP)

None

SilverWolveGames avatar Feb 23 '25 15:02 SilverWolveGames