# led_board
LED advertising strip on the pitch boards (arena.shaders.led_board), 0.78 m panels.
# night.sceneSetup
The Arena Bola na Rede night: navy starry sky held at 22:30, blue moon rim, cool ambient, light haze for the floodlight air, bloom, broadcast grade and vignette. The floodlights themselves are the Stadium's spot lights.
# goal_net
The goal net, bulging on impact (arena.shaders.goal_net), blended both sides.
# led_fascia
LED ribbon on the stand fronts and the upper tier fascia (arena.shaders.led_board), 1.1 m panels.
# Stadium
Arena Bola na Rede, the night stadium round the 44 x 26 m walled pitch: striped pitch with painted lines, 1 m LED ad boards (art only, no colliders), two goals with bulging nets, a two-tier bowl with a 7000-fan instanced crowd, a roof over the far side, video screens, four floodlight towers with real spot lights, flags, flares, confetti, and the night scene setup. Inputs: `lighting` (place the night setup, default true), `towerShadows` (how many floodlights cast shadows, default 2), `crowdDensity` (0..1, lower for phones). Expects to stand at the world origin. See arena/README.md.
# ArenaFx
Lives on the `Arena` root that arena.Stadium builds (added by the builder; needs nothing else). On start it draws the crowd as one instanced population (a low-poly fan per occupied seat of arena.layout, `density` sets the share of seats filled), and every frame it turns the arena.arena calls into shader state: net bulge lanes, crowd mood on the crowd material, flares, confetti, the GOL! flash on the LED boards and screens, flag colours. Writes only what changed, so an idle stadium costs almost nothing.
# flare_smoke
Supporters' flares: core and smoke (arena.shaders.flare_smoke), blended.
# flag
Waving flags and banners (arena.shaders.flag), both sides drawn.
# BolaShell
The presentation shell of Bola na Rede. Put one on an entity in the match scene (no sibling components needed). In play it opens the title screen, runs the menus (quick match setup, Cup and Online placeholders, settings, pause, results), starts and ends matches through ui.match, and drives the HUD, callouts, touch controls, sounds and effects from match events. Escape / Start pause through ui.pauseKeys. Field `startScreen`: title, setup or none.
# confetti
Goal confetti (arena.shaders.confetti), both sides drawn.
# pitch
The Arena Bola na Rede ground: striped grass, painted lines and apron (arena.shaders.pitch).
# sim/consts
Numbers of a Bola na Rede match: pitch sizes per CONTRACT.md, movement and ball feel, match flow timings and the four difficulty tunings (easy, normal, hard, lenda). Read by every sim module and by `scenes/main.scene/build.luau`.
# sim/match
The Bola na Rede match simulation and its public API, called by the shell and the scene.
```luau
local Match = require("sim.match")
Match.start({ home = "praia", away = "trovao", difficulty = "normal", minutes = 3, humanTeam = "home" })
Match.on("goal", function(e) print(e.team, e.scorer) end)
local s = Match.state()
Match.pause(true)
Match.quit()
```
- `start(opts)`: home/away are team definitions or ids from `sim.teams`; difficulty easy|normal|hard|lenda; minutes; humanTeam "home"|"away"|nil (nil = CPU vs CPU); intro=false skips the walkout.
- `on(name, fn)` returns an unsubscribe function. Events and payloads per CONTRACT.md, plus `result` at full time.
- `state()` per CONTRACT.md, plus period (regular|golden|shootout), controlled, result, goal, shootout.
- `autostart` (default true): the scene starts a human match on entering play; the shell sets it false and calls `start` itself.
- `setCameraStyle("broadcast"|"close")`, `stats()`.
Phases: idle, intro, kickoff, play, goal, golden (banner before golden goal), shootout, fulltime.