From 09caff2b2a06d1f8ac8203567035a21c612165f9 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Thu, 11 Jan 2024 13:15:02 +0100 Subject: send resources --- src/Model/Building/PostOffice.php | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 src/Model/Building/PostOffice.php (limited to 'src/Model/Building/PostOffice.php') diff --git a/src/Model/Building/PostOffice.php b/src/Model/Building/PostOffice.php new file mode 100644 index 0000000..5765a0f --- /dev/null +++ b/src/Model/Building/PostOffice.php @@ -0,0 +1,32 @@ + 1000, + 'clay' => 1000, + 'iron' => 800, + ]; + public array $resourceRequirementsFactor = [ + 'wood' => 10.0, + 'clay' => 10.0, + 'iron' => 8.0, + ]; + + public static function getResourceCapabilities(Village $village): int + { + $mailCarriers = Village::getUnit($village, 'MailCarrier', Village::FETCH_UNIT_RESIDENCE, Village::RETURN_UNIT_EXISTING); + + return MailCarrier::getResourceCapabilities($village) * $mailCarriers->amount; + } +} -- cgit v1.2.3