Spielerando

One-Way Platforms

A one-way platform is a ledge the character can jump up through from below and then stand on from above. It catches only a character that was above the top before the move and is coming down, checked along the whole move so fast falls cannot skip it. Down plus jump drops through.

Also called: Jump-through platforms, Pass-through platforms, Semi-solid platforms.

A red panda in a blue hooded cape rises up through a thin pink stone slab, half its body above and half below, while a faint copy of it drops down through another slab below.
Quillmorrow Climb, an invented cave-climbing platformer. Invented game, image generated with AI.

Paste this to your AI

Copy it into Claude, Cursor or ChatGPT. It already has good values and the usual mistakes in it.

Add "One-Way Platforms" to my game.

What it should do: A ledge that is open from below and solid from above. It lets the player climb through platforms by jumping, stand on them, and drop back down on purpose, so a level can stack floors without walls and ceilings getting in the way.

Build it exactly as this state machine. First check that it fits my game, then build it like this:

```mermaid
stateDiagram-v2
  [*] --> ground
  ground: On the ground
  platform: On the platform
  air: In the air
  dropping: Dropping through
  ground --> air: jumps
  platform --> air: jumps or steps off
  platform --> dropping: down plus jump
  dropping --> air: feet clear the top
  dropping --> ground: lands on the ground
  air --> platform: lands on top
  air --> ground: lands on the ground
```

Use these starting values:
- jumpSpeed: 12 units/s
- dropSpeed: 3 units/s
- dropDepth: 0.3 units
- gravity: 32 units/s²
- maxFallSpeed: 20 units/s

Watch out for these common mistakes:
- Looking only at where the feet are now: Tell your AI: catch the character only if its feet were at or above the top at the start of the move and are at or below it at the end.
- A fast fall skips a thin platform: Tell your AI: check the whole move from the old height to the new one, not only where it ends.
- The drop lands again at once: Tell your AI: mark the character as dropping, ignore the platform while it is marked, and clear the mark once the feet are a margin below the top.
- Feet exactly on the edge: Tell your AI: count equal as above when deciding where the feet were.
- A platform right above the floor: Tell your AI: clear the dropping mark on every landing, not only when the feet pass the margin.
- Down alone drops the character: Tell your AI: ask for down and a fresh jump press together, so holding down alone never drops.

Do not change anything else in the game. Do not claim anything without proof: model what it takes, and show me what your solution rests on and how I can see that it works. If you cannot show something, say you do not know. When you are done, tell me in plain words how to try it.

Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP

What it does

A ledge that is open from below and solid from above. It lets the player climb through platforms by jumping, stand on them, and drop back down on purpose, so a level can stack floors without walls and ceilings getting in the way.

How it runs, as a diagram

Everything it can be in, and what moves it on. Your AI builds from exactly this.

jumpsjumps or steps offdown plus jumpfeet clear the toplands on the groundlands on toplands on the groundOn the groundOn the platformIn the airDropping through
How it runs, as a diagram
  • On the ground → In the air: jumps
  • On the platform → In the air: jumps or steps off
  • On the platform → Dropping through: down plus jump
  • Dropping through → In the air: feet clear the top
  • Dropping through → On the ground: lands on the ground
  • In the air → On the platform: lands on top
  • In the air → On the ground: lands on the ground

Good starting values

ValueStart withWhat it changes
jumpSpeed12 units/sHow hard the character pushes off. It must be strong enough to rise above the platform, or the platform cannot be climbed.
dropSpeed3 units/sThe little push downward when dropping through. It moves the feet off the top at once, so the drop looks like a drop and not a pause.
dropDepth0.3 unitsHow far the feet must sink under the top before the platform can catch the character again. Too small and a thin platform catches it on the way down. Too large and a low platform is skipped.
gravity32 units/s²How fast a rise slows down.
maxFallSpeed20 units/sThe fastest the character can fall. It also decides how thin a platform can be before a fast fall could skip it, if the platform is checked badly.

What usually goes wrong

Looking only at where the feet are now

If the platform catches anything whose feet are at or just under its top, a jump that stops just short of the top gets snapped up onto it, as if the character was pulled by magic.

Fix: Tell your AI: catch the character only if its feet were at or above the top at the start of the move and are at or below it at the end.

A fast fall skips a thin platform

A character falling fast, or in a slow frame, can move from above the platform to below it in one tick. Checking only the end position never sees the platform.

Fix: Tell your AI: check the whole move from the old height to the new one, not only where it ends.

The drop lands again at once

With down plus jump the feet are still on the top for a moment, so the platform catches the character right away and nothing seems to happen.

Fix: Tell your AI: mark the character as dropping, ignore the platform while it is marked, and clear the mark once the feet are a margin below the top.

Feet exactly on the edge

A character whose feet are exactly at the top height, like one that stood there a tick ago, falls through if the check says strictly above instead of at or above.

Fix: Tell your AI: count equal as above when deciding where the feet were.

A platform right above the floor

Dropping through a platform that is lower than the margin has no room to clear it, so the mark could stay on after landing on the ground and make the next platform unreachable.

Fix: Tell your AI: clear the dropping mark on every landing, not only when the feet pass the margin.

Down alone drops the character

If holding down is enough, a player who holds down while landing on a platform falls straight through it, and crouching on a platform becomes impossible.

Fix: Tell your AI: ask for down and a fresh jump press together, so holding down alone never drops.

How to check it works

Works well with

Clashes with Jump Buffering: A remembered jump fires on landing. If the player holds down, it becomes a drop-through right after landing on a platform. Let a remembered jump only jump, never drop. Drop only on a fresh press.

Common questions

how do i make a platform you can jump through from below

Paste this: Add one-way platforms: they catch the character only when its feet were at or above the top before the move, it is moving down, and the move ends at or below the top. Jumping up from below passes through. Pressing down plus jump drops through and ignores that platform until the feet are clear.

why does my character fall through a one way platform

Most often the check looks only at where the feet end up, so a fast fall skips a thin platform. Check the whole move from the old height to the new one.

why does my character get pulled up onto a platform

The check is asking where the feet are now. Ask where they were before the move. If they were below the top, the platform must not catch them.

how do i let the player drop down through a platform

Ask for down and a fresh jump press together. Then mark the character as dropping, ignore the platform until the feet are a small margin below its top, and clear the mark on any landing.

Where it comes from

We could not find a reliable origin for this one yet.

Where this mechanic comes from has not been researched yet.

Games are named only as references. Names and marks belong to their owners, and nothing here is endorsed by them.

What was checked

This is what separates the blueprint from a catalogue entry: the values on this page come from code that runs.

Your AI gets the code

Tested example code comes through the Spielerando connection, so your AI can use it right away. How to connect it