Spielerando

Make a bird flap and glide in a natural rhythm that follows its height

A bird that flaps forever looks like a toy, and one that only follows a sine wave in the sky looks like a drifting cut-out. Real birds climb with a few beats and then coast down. Here is the small rule that gives the rhythm and sets the proportion of flapping to gliding by itself.

Why this works

A bird rests by gliding and works by flapping, and it switches when it has sunk too low or climbed high enough. Using two different thresholds keeps the rhythm calm; with one it would flip back and forth every frame.

When not to use it

Don't use it for a bird that circles a target, dives, or follows a path the player must read. A bird like that needs to be steered along its route, not left to rise and sink on its own.

In the full entry

  • What to build, step by step
  • Starting values and the reason for each
  • 3 common mistakes and the fix
  • A diagram of every state
  • 29 lines of example code with 4 checks that pass
  • How your AI shows you that it works

Say this to your AI

Use the Spielerando entry "Make a bird flap and glide in a natural rhythm that follows its height" (read_entry crow-flaps-then-glides-by-altitude) in my game. Build it step by step, and show me how you checked that it works.

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