I'm encountering an issue when my player sprite stands still on top of a moving platform - the animations/states (debug text above for current state) begins flipping through between "idle" "falling" "landed" again and again as long as the player is riding this horizontally moving platform back and fourth.
The player is also being bumped back or something as the animations/states are flickering.
I have been trying to solve this issue for days and have tried many many combinations of failed solutions.
Some context that is important. I have my animations as a child to a basic Player sprite that only is an invisible rectangle. I'm using the Platformer behavior on the player sprite.
Attempts:
I did use ChatGPT to help me try to fix this but it was no help, here is what I tried using their suggestions:
Default Sine behavior
• Let the platform move via the built-in Sine behavior — (flicker persisted).
Manual platform movement
• Removed Sine, drove X by Speed * dt between left/right bounds — (no effect on flicker).
Basic “Platform → Is on floor” checks
• Tried gating idle only when player.Platform is on floor = true (and inverted for “not on floor” debug) — flag still blinked.
Velocity-threshold idle detection
• Checked abs(player.Platform.VectorX) < threshold and abs(VectorY) < threshold before calling idle — micro-jitters still broke it.
Platform → IsFalling inverted
• Combined Is on floor with “not Platform.IsFalling” — still unreliable on moving rails.
stateLocked boolean
• Introduced a flag to lock out state changes during transforms/attacks — didn’t stop the underlying “fall” flicker.
IdleTriggerBox pinned to each platform
• Spawned a tiny invisible box above each MovingRail, used “player overlaps IdleTriggerBox” to trigger idle — screen still “bumped” as underlying physics fought it.
-----
I've seen youtube videos showing people how to setup moving platforms using Sine and I did that and yet their player is able to stand completely still, unmoved by the motion of the platform beneath them and mine is cycling through falling and landing and idling and is being pushed back from the inertia or the animation cycling. It is confirmed that the Player is not on the floor consistently.
Really could use some help on this, thank you all very much!