Skip to content

power.ron

The power grid and room lights. Read by the game’s rules: a change here changes how the game plays, and a world remembers the content it was made with.

File: assets/data/power.ron

Electricity and room lights (zombye_sim::power). Every field is optional.

The file is one PowerDef.

assets/data/power.ron: the grid and the lights. Every field is optional (these defaults).

Field Type What it is
grid GridDef
lights_on_at_start f32 The share of rooms (not halls, porches or garages) with a light left on when the world begins.
lit_room_seen f32 How well zombies see a player standing in a lit room at night, as daylight (0 dark, 1 full day).

The grid as power.ron describes it.

Field Type What it is
on bool On when the world begins.
fails_after_hours Option<f32> Game hours after the world began when the grid fails for good (None: it never does).
The whole file as shipped
// Electricity and room lights (`zombye_sim::power`). Every field is optional.
(
grid: (
// The town's grid is on when the world begins.
on: true,
// Game hours after the world began when the grid fails for good: None, it never does
// (Some(72.0): three days of power).
fails_after_hours: None,
),
// The share of rooms (not halls, porches or garages) with a light left on at the start.
lights_on_at_start: 0.22,
// How well zombies, and other survivors, see you in a lit room at night, as daylight
// (0 dark, 1 broad day): a light left on gives you away through the windows.
lit_room_seen: 0.8,
)