From 82cdaa433ea29d709b10fc7c9232a503b0ce15ee Mon Sep 17 00:00:00 2001 From: Hide_D Date: Tue, 4 Oct 2022 01:07:11 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=B5=9C=EB=8C=80=20=EC=9E=84=EA=B4=80?= =?UTF-8?q?=EB=85=84=EB=8F=84=20=EC=88=98=20=EA=B3=84=EC=82=B0=20=EB=B2=84?= =?UTF-8?q?=EA=B7=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/func.php | 2 +- hwe/sammo/Command/General/che_등용수락.php | 2 +- hwe/sammo/Command/General/che_하야.php | 2 +- hwe/sammo/InheritancePointManager.php | 10 +++++----- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/hwe/func.php b/hwe/func.php index d1c60b04..aab6aadf 100644 --- a/hwe/func.php +++ b/hwe/func.php @@ -1828,7 +1828,7 @@ function deleteNation(General $lord, bool $applyDB): array InheritanceKey::max_belong->value, max( $general->getVar('belong'), - $general->getInheritancePoint(InheritanceKey::max_belong) ?? 0 + ($general->getInheritancePoint(InheritanceKey::max_belong) ?? 0) / 10 ) ); } diff --git a/hwe/sammo/Command/General/che_등용수락.php b/hwe/sammo/Command/General/che_등용수락.php index 5417f067..47a4e4dd 100644 --- a/hwe/sammo/Command/General/che_등용수락.php +++ b/hwe/sammo/Command/General/che_등용수락.php @@ -184,7 +184,7 @@ class che_등용수락 extends Command\GeneralCommand{ InheritanceKey::max_belong->value, max( $general->getVar('belong'), - $general->getInheritancePoint(InheritanceKey::max_belong) ?? 0 + ($general->getInheritancePoint(InheritanceKey::max_belong) ?? 0) / 10 ) ); } diff --git a/hwe/sammo/Command/General/che_하야.php b/hwe/sammo/Command/General/che_하야.php index 7b465306..69223596 100644 --- a/hwe/sammo/Command/General/che_하야.php +++ b/hwe/sammo/Command/General/che_하야.php @@ -118,7 +118,7 @@ class che_하야 extends Command\GeneralCommand{ InheritanceKey::max_belong->value, max( $general->getVar('belong'), - $general->getInheritancePoint(InheritanceKey::max_belong) ?? 0 + ($general->getInheritancePoint(InheritanceKey::max_belong) ?? 0) / 10 ) ); } diff --git a/hwe/sammo/InheritancePointManager.php b/hwe/sammo/InheritancePointManager.php index 17f97cdf..1e120997 100644 --- a/hwe/sammo/InheritancePointManager.php +++ b/hwe/sammo/InheritancePointManager.php @@ -172,7 +172,7 @@ class InheritancePointManager break; case InheritanceKey::max_belong: $extractFn = function () use ($general, $multiplier) { - $maxBelong = max($general->getVar('belong'), $general->getAuxVar(InheritanceKey::max_belong->value) ?? 0); + $maxBelong = max($general->getVar('belong'), ($general->getAuxVar(InheritanceKey::max_belong->value) ?? 0) / 10); return [$maxBelong * $multiplier, null]; }; break; @@ -362,15 +362,15 @@ class InheritancePointManager /** @var InheritancePointType */ $keyTypeObj = $this->inheritanceKey->get($key); - if($isRebirth){ - if($keyTypeObj->rebirthStoreCoeff === null){ + if ($isRebirth) { + if ($keyTypeObj->rebirthStoreCoeff === null) { $keepValues[$rKey] = [$value, $auxV]; continue; } $value *= $keyTypeObj->rebirthStoreCoeff; } - + $keyText = $this->getInheritancePointType($key)->info; $userLogger->push("{$keyText} 포인트 {$value} 증가", "inheritPoint"); $totalPoint += $value; @@ -381,7 +381,7 @@ class InheritancePointManager $inheritStor->resetValues(); - foreach($keepValues as $rKey => $pointPair){ + foreach ($keepValues as $rKey => $pointPair) { $inheritStor->setValue($rKey, $pointPair); } $inheritStor->setValue(InheritanceKey::previous->value, [$totalPoint, null]);