물자조달 턴 추가 기타 커맨드 버그 수정

This commit is contained in:
2018-10-16 00:53:19 +09:00
parent 928e8a200b
commit 90736b52be
13 changed files with 195 additions and 90 deletions
+12 -10
View File
@@ -5,18 +5,20 @@ use \sammo\{
DB, Util, JosaUtil,
General,
ActionLogger,
getGeneralLeadership,getGeneralPower,getGeneralIntel,
GameConst,
LastTurn,
GameUnitConst,
Command
};
use function \sammo\{
getDomesticExpLevelBonus,
CriticalRatioDomestic, CriticalScore,
uniqueItemEx,
LastTurn
CriticalRatioDomestic,
CriticalScoreEx,
uniqueItemEx
};
use \sammo\Command;
use \sammo\Constraint\Constraint;
use function sammo\CriticalScore;
use function sammo\uniqueItemEx;
use function sammo\getGeneralLeadership;
class che_주민선정 extends Command\GeneralCommand{
@@ -72,13 +74,13 @@ class che_주민선정 extends Command\GeneralCommand{
$general = $this->generalObj;
if(static::$statKey == 'leader'){
$score = getGeneralLeadership($general->getRaw(), true, true, true, false);
$score = $general->getLeadership(true, true, true, false);
}
else{
throw new \sammo\MustNotBeReachedException();
}
$score *= getDomesticExpLevelBonus($general['explevel']);
$score *= getDomesticExpLevelBonus($general->getVar('explevel'));
$score *= Util::randRange(0.8, 1.2);
$score = $general->onCalcDomestic(static::$actionKey, 'score', $score);
$score = Util::valutFit($score, 1);