Log inGet started
World

BATTLEBOX: Robot Combat Arena

Branchmain
Commit7fbeff3a68

README.md

ArenaCam

The broadcast camera behaviour. It is Camera.behavior on the player prototype's CameraRig (which also carries the scene's AudioListener), and follows Camera.follow, the local player's HAVOC.

  • chase (default): distance 6 m behind and height 4 m above HAVOC along its smoothed heading, aimed lookAhead in front, about 35 degrees down: the gameplay reference's framing. It is clamped ARENA.cameraInset inside the walls so the shot is never taken through the polycarbonate.
  • faceoff: a low front shot of both bots (title screen).
  • orbit: a slow orbit of the shot focus (KO / decision).
  • garage: the showroom shot of the bot on the garage turntable (the shot focus), from the arena's south side garageDistance m away and garageHeight m up (garageTall* on a portrait screen). The screens say where the layout leaves room for the bot with Rules.state().shotFrame = { x, y, tall } (0..1 screen fractions) and the shot aims off the bot so it lands there.

Rules.kickCamera(strength) shakes it and pushes it in, dying away in about half a second. Rules.setShot picks the shot. Needs a Camera on the same entity.