forked from devsam/core
기술연구의 calcBaseScore는 상업 투자 것을 가져오기로
This commit is contained in:
@@ -17,7 +17,7 @@ use function sammo\uniqueItemEx;
|
||||
use function sammo\getGeneralLeadership;
|
||||
|
||||
|
||||
class che_기술연구 extends BaseCommand{
|
||||
class che_기술연구 extends che_상업투자{
|
||||
static $statKey = 'intel';
|
||||
static $actionKey = '기술';
|
||||
static $actionName = '기술 연구';
|
||||
@@ -43,25 +43,6 @@ class che_기술연구 extends BaseCommand{
|
||||
$this->reqGold = $reqGold;
|
||||
}
|
||||
|
||||
protected function calcBaseScore():float{
|
||||
$general = $this->generalObj;
|
||||
|
||||
if(static::$statKey == 'intel'){
|
||||
$score = getGeneralIntel($general->getRaw(), true, true, true, false);
|
||||
}
|
||||
else{
|
||||
throw new \sammo\MustNotBeReachedException();
|
||||
}
|
||||
|
||||
$trust = Util::valueFit($this->city['trust'], 50);
|
||||
$score *= $trust / 100;
|
||||
$score *= getDomesticExpLevelBonus($general['explevel']);
|
||||
$score *= Util::randRange(0.8, 1.2);
|
||||
$score = $general->onCalcDomestic(static::$actionKey, 'score', $score);
|
||||
|
||||
return $score;
|
||||
}
|
||||
|
||||
public function run():bool{
|
||||
if(!$this->isAvailable()){
|
||||
throw new \RuntimeException('불가능한 커맨드를 강제로 실행 시도');
|
||||
|
||||
Reference in New Issue
Block a user