game-village-politics-backend/config/game/buildings.php

207 lines
8.4 KiB
PHP
Raw Normal View History

<?php
// Values per building type. Levels start at 1, which has the base values.
// `space` is how much of the village's building space an instance takes, at any level.
// Level n: cost = cost × factor^(n−1), build time = base × factor^(n−1) seconds at world
// speed 1, workers = round(base × factor^(n−1)), and production, capacity, hides,
// detection and beds = base × factor^(n−1).
// The n-th instance of a type (0-based) costs instance_cost_factor^n times as much.
// Map points of an instance: round(points.base × points.factor^(level−1)).
return [
'headquarters' => [
'space' => 9,
'max_per_village' => 1,
'max_level' => 30,
'cost' => ['wood' => 90, 'clay' => 80, 'iron' => 70, 'factor' => 1.26],
'build_time' => ['base' => 120, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.1],
'production' => null,
'instance_cost_factor' => 1.0,
'points' => ['base' => 10, 'factor' => 1.2],
'requires' => [],
],
'storage' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 30,
'cost' => ['wood' => 60, 'clay' => 50, 'iron' => 40, 'factor' => 1.27],
'build_time' => ['base' => 100, 'factor' => 1.2],
'workers' => ['base' => 1, 'factor' => 1.1],
'production' => null,
'capacity' => ['base' => 1000, 'factor' => 1.23],
'instance_cost_factor' => 2.0,
'points' => ['base' => 6, 'factor' => 1.2],
'requires' => [],
],
'farm' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 30,
'cost' => ['wood' => 45, 'clay' => 40, 'iron' => 30, 'factor' => 1.27],
'build_time' => ['base' => 120, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.1],
'production' => ['resource' => 'food', 'base' => 30, 'factor' => 1.25],
'instance_cost_factor' => 2.0,
'points' => ['base' => 5, 'factor' => 1.2],
'requires' => [],
],
'timber_camp' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 30,
'cost' => ['wood' => 50, 'clay' => 60, 'iron' => 40, 'factor' => 1.25],
'build_time' => ['base' => 90, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.12],
'production' => ['resource' => 'wood', 'base' => 30, 'factor' => 1.163],
'instance_cost_factor' => 2.0,
'points' => ['base' => 6, 'factor' => 1.2],
'requires' => [],
],
'clay_pit' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 30,
'cost' => ['wood' => 65, 'clay' => 50, 'iron' => 40, 'factor' => 1.27],
'build_time' => ['base' => 90, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.12],
'production' => ['resource' => 'clay', 'base' => 30, 'factor' => 1.163],
'instance_cost_factor' => 2.0,
'points' => ['base' => 6, 'factor' => 1.2],
'requires' => [],
],
'iron_mine' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 30,
'cost' => ['wood' => 75, 'clay' => 65, 'iron' => 70, 'factor' => 1.252],
'build_time' => ['base' => 110, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.12],
'production' => ['resource' => 'iron', 'base' => 30, 'factor' => 1.163],
'instance_cost_factor' => 2.0,
'points' => ['base' => 6, 'factor' => 1.2],
'requires' => [],
],
'hiding_place' => [
'space' => 1,
'max_per_village' => null,
'max_level' => 10,
'cost' => ['wood' => 50, 'clay' => 60, 'iron' => 50, 'factor' => 1.25],
'build_time' => ['base' => 60, 'factor' => 1.2],
'workers' => ['base' => 0, 'factor' => 1.0],
'production' => null,
// Wood, clay and iron each that raiders can't take; instances add up.
'hides' => ['base' => 150, 'factor' => 1.3335],
'instance_cost_factor' => 2.0,
'points' => ['base' => 5, 'factor' => 1.2],
'requires' => [],
],
'wall' => [
// Surrounds the village and takes no building space.
'space' => 0,
'max_per_village' => 1,
'max_level' => 20,
'cost' => ['wood' => 50, 'clay' => 100, 'iron' => 20, 'factor' => 1.26],
'build_time' => ['base' => 300, 'factor' => 1.2],
'workers' => ['base' => 1, 'factor' => 1.1],
'production' => null,
'instance_cost_factor' => 1.0,
'points' => ['base' => 8, 'factor' => 1.2],
'requires' => [],
],
'rally_point' => [
'space' => 1,
'max_per_village' => 1,
'max_level' => 1,
'cost' => ['wood' => 10, 'clay' => 40, 'iron' => 30, 'factor' => 1.26],
'build_time' => ['base' => 60, 'factor' => 1.2],
'workers' => ['base' => 0, 'factor' => 1.0],
'production' => null,
'instance_cost_factor' => 1.0,
'points' => ['base' => 2, 'factor' => 1.2],
'requires' => [],
],
// Spots incoming groups further out: adds `detection` fields to the village's radius.
'watchtower' => [
'space' => 2,
'max_per_village' => 1,
'max_level' => 20,
'cost' => ['wood' => 12000, 'clay' => 14000, 'iron' => 10000, 'factor' => 1.17],
'build_time' => ['base' => 6000, 'factor' => 1.2],
'workers' => ['base' => 1, 'factor' => 1.1],
'production' => null,
'detection' => ['base' => 1.1, 'factor' => 1.162],
'instance_cost_factor' => 1.0,
'points' => ['base' => 42, 'factor' => 1.2],
'requires' => ['headquarters' => 5, 'farm' => 5],
],
// Military buildings. Each instance runs its own recruiting queue; its level and
// staffing speed up training there (economy.recruit_speed_per_level).
'barracks' => [
'space' => 6,
'max_per_village' => null,
'max_level' => 25,
'cost' => ['wood' => 200, 'clay' => 170, 'iron' => 90, 'factor' => 1.26],
'build_time' => ['base' => 600, 'factor' => 1.2],
'workers' => ['base' => 3, 'factor' => 1.1],
'production' => null,
'instance_cost_factor' => 2.0,
'points' => ['base' => 16, 'factor' => 1.2],
'requires' => [],
],
'stable' => [
'space' => 6,
'max_per_village' => null,
'max_level' => 20,
'cost' => ['wood' => 270, 'clay' => 240, 'iron' => 260, 'factor' => 1.26],
'build_time' => ['base' => 1200, 'factor' => 1.2],
'workers' => ['base' => 3, 'factor' => 1.1],
'production' => null,
'instance_cost_factor' => 2.0,
'points' => ['base' => 20, 'factor' => 1.2],
'requires' => ['barracks' => 3],
],
'workshop' => [
'space' => 6,
'max_per_village' => null,
'max_level' => 15,
'cost' => ['wood' => 300, 'clay' => 240, 'iron' => 260, 'factor' => 1.26],
'build_time' => ['base' => 1800, 'factor' => 1.2],
'workers' => ['base' => 4, 'factor' => 1.1],
'production' => null,
'instance_cost_factor' => 2.0,
'points' => ['base' => 24, 'factor' => 1.2],
'requires' => ['barracks' => 5],
],
// The Adelshof: trains noblemen. The one advanced building with real requirements.
'academy' => [
'space' => 9,
'max_per_village' => 1,
'max_level' => 3,
'cost' => ['wood' => 15000, 'clay' => 25000, 'iron' => 10000, 'factor' => 2.0],
'build_time' => ['base' => 5400, 'factor' => 1.5],
'workers' => ['base' => 5, 'factor' => 1.2],
'production' => null,
'instance_cost_factor' => 1.0,
'points' => ['base' => 512, 'factor' => 1.2],
'requires' => ['headquarters' => 5, 'barracks' => 1],
],
// The Lazarett: a share of the own troops who fall defending the village come back
// wounded into its beds and heal after a while (combat.hospital). A bed holds one
// wounded; beds add up over instances and shrink with staffing like production.
'hospital' => [
'space' => 4,
'max_per_village' => null,
'max_level' => 20,
'cost' => ['wood' => 160, 'clay' => 200, 'iron' => 120, 'factor' => 1.26],
'build_time' => ['base' => 900, 'factor' => 1.2],
'workers' => ['base' => 2, 'factor' => 1.1],
'production' => null,
'beds' => ['base' => 20, 'factor' => 1.2],
'instance_cost_factor' => 2.0,
'points' => ['base' => 12, 'factor' => 1.2],
'requires' => ['barracks' => 1],
],
];