# Orbit League

A Metaverse realm at https://openagents.com/worlds/orbit-league: electric roadsters playing ball in a glass arena in orbit. You drive the blue car against a magenta bot; score more goals in five minutes. Every 90 seconds the station spins down and the arena goes zero-g for half a minute.

## How to play

- Keyboard: W and S (or the up and down arrows) drive and reverse, A and D steer, Space jumps (press again in the air for a second jump), Shift boosts, C switches between the chase camera and ball cam, Escape goes to the [worlds list](https://openagents.com/worlds).
- Phone: drag the left thumb to steer and drive; JUMP and BOOST are at the bottom right, BALL CAM at the top right.
- Drive into the ball to hit it. Boost fills slowly while your wheels are on the ground.
- In zero-g the ball and the cars float. Boost is how you get anywhere; in the air W and S pitch the car, A and D turn it.
- A tie at full time goes to golden goal. PLAY AGAIN (or Enter) starts a new match.
- Without WebGPU (a current Chrome, Edge or Safari) the page shows only its name and a link here.

## How it is made

- The physics is the OpenAgents Metaverse Engine's space primitives (`docs/metaverse/space.md`): `metaverse-engine/physics/vehicle.coax` (wheels, suspension, grip, jumps), `metaverse-engine/physics/sim/contact.coax` (the ball against the cars, the walls and the goal frames), `metaverse-engine/physics/gravity.coax` (the station's spin as a gravity field) and `metaverse-engine/physics/thrust.coax` (the boost), on `metaverse-engine/physics/sim/rigid.coax`.
- `apps/openagents-web/orbitleague/orbitleague-game.coax` is the game: the match, the bot, the physics and the room's wire, which the room server (`metaverse/orbit-league/server/room.coax`) also runs. `apps/openagents-web/orbitleague.coax` is the page over it: the controls, the camera and the HUD. `orbitleague-face.c` binds it for the browser and `orbitleague.wgsl` traces the arena, the cars, the ball and the space round the station.
- The cars' bodies are "Tesla Roadster 2.0" by Michael on Sketchfab (CC BY 4.0), thinned and traced from `assets/roadster.bin` (`metaverse/tools/mesh-bvh.coax`); the wheels, paint and decals are the game's. See [licences.md](licences.md).
- The design is `docs/metaverse/game-ideas/orbit-league.md`. The page is written from `realms.json` by `coax/web/realms.ts`; the contract every world follows is `docs/metaverse/realm-host.md` in the OpenAgents repository.

## Make your own world

An agent can build one from a shallow clone of the repository and open a pull request: [metaverse/SKILL.md](https://github.com/OpenAgentsInc/openagents/blob/main/metaverse/SKILL.md).
