game: NPC의 이후 임관 확률을 낮춤

This commit is contained in:
2022-06-09 01:30:08 +09:00
parent 47e6b91b82
commit 42579810a2
+10 -4
View File
@@ -3310,7 +3310,11 @@ class GeneralAI
}
if ($this->rng->nextBool(0.3)) {
if ($env['startyear'] + 3 > $env['year']) {
if ($general->getVar('affinity') == 999) {
return null;
}
if ($env['year'] < $env['startyear'] + 3) {
//초기 임관 기간에서는 국가가 적을수록 임관 시도가 적음
$nationCnt = $db->queryFirstField('SELECT count(nation) FROM nation');
$notFullNationCnt = $db->queryFirstField('SELECT count(nation) FROM nation WHERE gennum < %i', GameConst::$initialNationGenLimit);
@@ -3322,9 +3326,11 @@ class GeneralAI
return null;
}
}
if ($general->getVar('affinity') == 999) {
return null;
else{
//임관 기간이 끝나면 고정 확률로 낮춤 0.3 * 0.5 = 0.15
if ($this->rng->nextBool()){
return null;
}
}
//랜임 커맨드 입력.