From 03f9c5692836b3d64b817dcbfbe4465f67294718 Mon Sep 17 00:00:00 2001 From: hide_d Date: Sat, 15 Sep 2018 03:49:08 +0900 Subject: [PATCH] =?UTF-8?q?=EC=A0=95=EC=9E=A5,=20=EC=84=A0=EC=A0=95=20?= =?UTF-8?q?=EC=BB=A4=EB=A7=A8=EB=93=9C=20=EB=AC=B8=EC=A0=9C=EB=A1=9C=20?= =?UTF-8?q?=EB=AA=85=EC=84=B1,=EA=B3=84=EA=B8=89=20=EB=B0=98=EC=98=81=20?= =?UTF-8?q?=EC=9C=84=EC=B9=98=20=EC=9D=B4=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/sammo/Command/che_기술연구.php | 6 ++++-- hwe/sammo/Command/che_상업투자.php | 7 ++++--- hwe/sammo/Command/che_정착장려.php | 23 +++++++++++------------ hwe/sammo/Command/che_주민선정.php | 10 ++++++---- 4 files changed, 25 insertions(+), 21 deletions(-) diff --git a/hwe/sammo/Command/che_기술연구.php b/hwe/sammo/Command/che_기술연구.php index f0c539f9..69e84beb 100644 --- a/hwe/sammo/Command/che_기술연구.php +++ b/hwe/sammo/Command/che_기술연구.php @@ -79,6 +79,10 @@ class che_기술연구 extends che_상업투자{ $score *= CriticalScoreEx($pick); $score = Util::round($score); + + $exp = $score * 0.7; + $ded = $score * 1.0; + $scoreText = number_format($score, 0); $josaUl = JosaUtil::pick(static::$actionName, '을'); @@ -92,8 +96,6 @@ class che_기술연구 extends che_상업투자{ $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 하여 $scoreText 상승했습니다. <1>$date"); } - $exp = $score * 0.7; - $ded = $score * 1.0; $exp = $general->onPreGeneralStatUpdate($general, 'experience', $exp); $ded = $general->onPreGeneralStatUpdate($general, 'dedication', $ded); diff --git a/hwe/sammo/Command/che_상업투자.php b/hwe/sammo/Command/che_상업투자.php index 73071546..a44b9bc8 100644 --- a/hwe/sammo/Command/che_상업투자.php +++ b/hwe/sammo/Command/che_상업투자.php @@ -106,6 +106,10 @@ class che_상업투자 extends BaseCommand{ $score *= CriticalScoreEx($pick); $score = Util::round($score); + + $exp = $score * 0.7; + $ded = $score * 1.0; + $scoreText = number_format($score, 0); $josaUl = JosaUtil::pick(static::$actionName, '을'); @@ -119,9 +123,6 @@ class che_상업투자 extends BaseCommand{ $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 하여 $scoreText 상승했습니다. <1>$date"); } - $exp = $score * 0.7; - $ded = $score * 1.0; - $exp = $general->onPreGeneralStatUpdate($general, 'experience', $exp); $ded = $general->onPreGeneralStatUpdate($general, 'dedication', $ded); diff --git a/hwe/sammo/Command/che_정착장려.php b/hwe/sammo/Command/che_정착장려.php index d5396fe3..6d9c1b56 100644 --- a/hwe/sammo/Command/che_정착장려.php +++ b/hwe/sammo/Command/che_정착장려.php @@ -48,13 +48,7 @@ class che_상업투자 extends BaseCommand{ protected function calcBaseScore():float{ $general = $this->generalObj; - if(static::$statKey == 'intel'){ - $score = getGeneralIntel($general->getRaw(), true, true, true, false); - } - else if(static::$statKey == 'power'){ - $score = getGeneralPower($general->getRaw(), true, true, true, false); - } - else if(static::$statKey == 'leader'){ + if(static::$statKey == 'leader'){ $score = getGeneralLeadership($general->getRaw(), true, true, true, false); } else{ @@ -99,21 +93,26 @@ class che_상업투자 extends BaseCommand{ $score *= CriticalScoreEx($pick); $score = Util::round($score); + + $exp = $score * 0.7; + $ded = $score * 1.0; + + $score *= 10; + $scoreText = number_format($score, 0); $josaUl = JosaUtil::pick(static::$actionName, '을'); if($pick == 'fail'){ - $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 실패하여 $scoreText 상승했습니다. <1>$date"); + $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 실패하여 주민이 $scoreText명 증가했습니다. <1>$date"); } else if($pick == 'success'){ - $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 성공하여 $scoreText 상승했습니다. <1>$date"); + $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 성공하여 주민이 $scoreText명 증가했습니다. <1>$date"); } else{ - $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 하여 $scoreText 상승했습니다. <1>$date"); + $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 하여 주민이 $scoreText명 증가했습니다. <1>$date"); } - $exp = $score * 0.7; - $ded = $score * 1.0; + $exp = $general->onPreGeneralStatUpdate($general, 'experience', $exp); $ded = $general->onPreGeneralStatUpdate($general, 'dedication', $ded); diff --git a/hwe/sammo/Command/che_주민선정.php b/hwe/sammo/Command/che_주민선정.php index fc40227e..d2e2ddf1 100644 --- a/hwe/sammo/Command/che_주민선정.php +++ b/hwe/sammo/Command/che_주민선정.php @@ -55,7 +55,6 @@ class che_주민선정 extends BaseCommand{ throw new \sammo\MustNotBeReachedException(); } - $score /= 10; $score *= getDomesticExpLevelBonus($general['explevel']); $score *= Util::randRange(0.8, 1.2); $score = $general->onCalcDomestic(static::$actionKey, 'score', $score); @@ -94,6 +93,12 @@ class che_주민선정 extends BaseCommand{ $date = substr($general->getVar('turntime'),11,5); $score *= CriticalScoreEx($pick); + + $exp = $score * 0.7; + $ded = $score * 1.0; + + $score /= 10; + $scoreText = number_format($score, 1); $josaUl = JosaUtil::pick(static::$actionName, '을'); @@ -107,9 +112,6 @@ class che_주민선정 extends BaseCommand{ $logger->pushGeneralActionLog(static::$actionName."{$josaUl} 하여 $scoreText 상승했습니다. <1>$date"); } - $exp = $score * 0.7; - $ded = $score * 1.0; - $exp = $general->onPreGeneralStatUpdate($general, 'experience', $exp); $ded = $general->onPreGeneralStatUpdate($general, 'dedication', $ded);