2026-10-28 18:17:34 +00:00
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
|
|
// World defaults. A world's `config` JSON overrides any key (see WorldConfig).
|
|
|
|
|
|
|
|
|
|
|
|
return [
|
|
|
|
|
|
// Multiplies production and divides every duration.
|
|
|
|
|
|
'speed' => 1.0,
|
|
|
|
|
|
|
2026-10-30 10:27:14 +00:00
|
|
|
|
// A player not seen for this many real days (not world days: it measures people)
|
|
|
|
|
|
// loses their villages to the barbarians, so abandoned accounts don't block the map.
|
|
|
|
|
|
// They can start again on the world. 0 turns it off.
|
|
|
|
|
|
'inactive_days' => 14,
|
|
|
|
|
|
|
2026-10-28 18:17:34 +00:00
|
|
|
|
'village' => [
|
2026-10-28 21:16:45 +00:00
|
|
|
|
// Building space: the sum of the buildings' `space` may not exceed
|
2026-10-29 15:20:52 +00:00
|
|
|
|
// space + space_per_hq_level × (headquarters level − 1): 40 at level 1, 45 at 2, 85 at
|
|
|
|
|
|
// 10. Scarce on purpose: what goes in is the village's main choice.
|
2026-10-28 21:16:45 +00:00
|
|
|
|
'space' => 40,
|
2026-10-29 15:20:52 +00:00
|
|
|
|
'space_per_hq_level' => 5,
|
|
|
|
|
|
// What fills the space gives a village its role. When one role's buildings take at
|
|
|
|
|
|
// least `share` of the space both roles' buildings take together, and min_space of
|
|
|
|
|
|
// it, the village has that role and its bonus: a resource village produces more in
|
|
|
|
|
|
// its camps, a military village trains faster and its defenders fight harder.
|
|
|
|
|
|
'specialisation' => [
|
|
|
|
|
|
'share' => 0.7,
|
|
|
|
|
|
'min_space' => 16,
|
|
|
|
|
|
'roles' => [
|
|
|
|
|
|
'resources' => ['buildings' => ['timber_camp', 'clay_pit', 'iron_mine'], 'production' => 0.2],
|
|
|
|
|
|
'military' => ['buildings' => ['barracks', 'stable', 'workshop', 'academy'], 'recruit_speed' => 0.2, 'defense' => 0.1],
|
|
|
|
|
|
],
|
|
|
|
|
|
],
|
2026-10-28 18:17:34 +00:00
|
|
|
|
'start_resources' => ['wood' => 500, 'clay' => 500, 'iron' => 500, 'food' => 300],
|
2026-10-28 21:26:25 +00:00
|
|
|
|
// Auto-placed at level 1 in this order.
|
2026-10-28 18:17:34 +00:00
|
|
|
|
'start_buildings' => ['headquarters', 'storage', 'farm'],
|
|
|
|
|
|
],
|
|
|
|
|
|
|
2026-10-29 15:31:34 +00:00
|
|
|
|
// A world is a season. crowns_after_days (at world speed) after it starts, `crowns`
|
|
|
|
|
|
// crown forts appear on a ring of `radius` fields around 0|0: barbarian villages with
|
|
|
|
|
|
// these building levels and this garrison, which never raid. A player who holds more
|
|
|
|
|
|
// than half of them for hold_days wins; the world ends and the next one opens.
|
|
|
|
|
|
'season' => [
|
|
|
|
|
|
'crowns_after_days' => 30,
|
|
|
|
|
|
'crowns' => 5,
|
|
|
|
|
|
'radius' => 10,
|
|
|
|
|
|
'buildings' => ['headquarters' => 20, 'storage' => 20, 'farm' => 30, 'wall' => 20, 'timber_camp' => 15, 'clay_pit' => 15, 'iron_mine' => 15],
|
|
|
|
|
|
'garrison' => ['spear' => 300, 'sword' => 300, 'archer' => 150, 'heavy_cavalry' => 50],
|
|
|
|
|
|
'hold_days' => 7,
|
|
|
|
|
|
],
|
|
|
|
|
|
|
2026-10-28 18:17:34 +00:00
|
|
|
|
'builders' => [
|
|
|
|
|
|
'base' => 2,
|
|
|
|
|
|
// One more builder from each of these headquarters levels on.
|
|
|
|
|
|
'extra_at_hq_levels' => [10, 20],
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
|
|
|
|
'map' => [
|
2026-10-29 00:51:37 +00:00
|
|
|
|
// Fields per side. The world starts at 0|0; coordinates run from −size/2 to size/2 − 1.
|
2026-10-28 18:17:34 +00:00
|
|
|
|
'size' => 1000,
|
2026-10-28 18:45:02 +00:00
|
|
|
|
// Most fields one map.view may cover in each direction.
|
2026-10-28 19:21:34 +00:00
|
|
|
|
'max_view' => 61,
|
2026-10-29 00:51:37 +00:00
|
|
|
|
// Like Die Stämme, villages settle on a frontier around 0|0 that grows with all
|
|
|
|
|
|
// villages (players and barbarians): start_radius + sqrt(villages / (π·density)),
|
|
|
|
|
|
// ± band fields. 0.29 is DS's density: about one village in 3.4 fields. A new
|
|
|
|
|
|
// player avoids the fields right next to other players for as long as it can.
|
|
|
|
|
|
'spawn' => ['start_radius' => 0, 'density' => 0.29, 'band' => 3],
|
|
|
|
|
|
// Barbarian villages come with the players: per_join on average for each joining
|
|
|
|
|
|
// player (1.3 = one, and a second with 30% chance, as in DS), within near fields of
|
|
|
|
|
|
// the new village, buildings at random levels up to max_level. Every few hours (at
|
|
|
|
|
|
// world speed) one building of each grows a level, up to growth.max_level.
|
2026-10-28 20:32:09 +00:00
|
|
|
|
'barbarians' => [
|
2026-10-29 00:51:37 +00:00
|
|
|
|
'per_join' => 1.3,
|
|
|
|
|
|
'near' => 4,
|
2026-10-28 20:32:09 +00:00
|
|
|
|
'max_level' => 3,
|
|
|
|
|
|
'growth' => ['every_hours' => 8, 'max_level' => 10],
|
2026-11-03 08:31:21 +00:00
|
|
|
|
// Waves keep a quiet world moving: every every_days (world days, at world speed,
|
|
|
|
|
|
// drawn evenly between the two for each wave) new barbarian villages settle near
|
|
|
|
|
|
// the active players, per_player on average for each (1.5 = one, and a second
|
|
|
|
|
|
// with 50% chance), within near fields of a random village of theirs. Active
|
|
|
|
|
|
// means seen within inactive_days (every player with a village when that is 0).
|
|
|
|
|
|
// They start like the ones that come with a join.
|
|
|
|
|
|
'waves' => [
|
|
|
|
|
|
'enabled' => true,
|
|
|
|
|
|
'every_days' => [5, 9],
|
|
|
|
|
|
'per_player' => 1.5,
|
|
|
|
|
|
'near' => 8,
|
|
|
|
|
|
],
|
2026-10-29 15:02:49 +00:00
|
|
|
|
// Troops a barbarian village holds at full strength: per_point × (points −
|
|
|
|
|
|
// free_points) heads, split by its profile's shares (the profile follows from
|
|
|
|
|
|
// the village id), and never eating more than max_food_share of its farms'
|
|
|
|
|
|
// food budget. After a hit, or when the village grows, it regroups: every
|
|
|
|
|
|
// regroup.every_hours (at world speed) it gets regroup.share of full strength back.
|
|
|
|
|
|
'garrison' => [
|
|
|
|
|
|
'per_point' => 0.1,
|
|
|
|
|
|
'free_points' => 30,
|
|
|
|
|
|
'max_food_share' => 0.5,
|
|
|
|
|
|
'profiles' => [
|
|
|
|
|
|
'spearmen' => ['spear' => 0.7, 'sword' => 0.3],
|
|
|
|
|
|
'swordsmen' => ['sword' => 0.7, 'spear' => 0.3],
|
|
|
|
|
|
'archers' => ['archer' => 0.6, 'spear' => 0.4],
|
|
|
|
|
|
'riders' => ['light_cavalry' => 0.5, 'spear' => 0.5],
|
|
|
|
|
|
],
|
|
|
|
|
|
'regroup' => ['every_hours' => 2, 'share' => 0.25],
|
|
|
|
|
|
],
|
2026-10-28 20:32:09 +00:00
|
|
|
|
],
|
2026-10-28 18:17:34 +00:00
|
|
|
|
],
|
|
|
|
|
|
];
|