From 634e05ea0d1a075aae7972258c600893b4b43148 Mon Sep 17 00:00:00 2001 From: Hide_D Date: Mon, 28 Mar 2022 01:15:20 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=A7=80=EA=B8=89=EB=A5=A0=20=EA=B3=84?= =?UTF-8?q?=EC=82=B0=EC=8B=9D=EC=97=90=EC=84=9C=20=EB=B6=80=EB=8C=80?= =?UTF-8?q?=EC=9E=A5=EC=9D=B4=20=ED=8F=AC=ED=95=A8=EB=90=98=EB=8A=94=20?= =?UTF-8?q?=EB=B2=84=EA=B7=B8=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/sammo/GeneralAI.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hwe/sammo/GeneralAI.php b/hwe/sammo/GeneralAI.php index 662034cc..9573674f 100644 --- a/hwe/sammo/GeneralAI.php +++ b/hwe/sammo/GeneralAI.php @@ -4100,7 +4100,10 @@ class GeneralAI $dedicationList = array_map(function (General $general) { return $general->getRaw(); - }, $nationGenerals); + }, array_filter($this->nationGenerals, function (General $rawGeneral) { + return $rawGeneral->getVar('npc') != 5; + })); + $goldIncome = getGoldIncome($nation['nation'], $nation['level'], $nation['rate'], $nation['capital'], $nation['type'], $cityList); $warIncome = getWarGoldIncome($nation['type'], $cityList); @@ -4144,7 +4147,9 @@ class GeneralAI $dedicationList = array_map(function (General $general) { return $general->getRaw(); - }, $nationGenerals); + }, array_filter($this->nationGenerals, function (General $rawGeneral) { + return $rawGeneral->getVar('npc') != 5; + })); $riceIncome = getRiceIncome($nation['nation'], $nation['level'], $nation['rate'], $nation['capital'], $nation['type'], $cityList); $wallIncome = getWallIncome($nation['nation'], $nation['level'], $nation['rate'], $nation['capital'], $nation['type'], $cityList);