fix: 랜덤임관 적용이 거꾸로된 것 수정
This commit is contained in:
@@ -2,33 +2,30 @@
|
||||
|
||||
namespace sammo\Command\Nation;
|
||||
|
||||
use\sammo\{
|
||||
DB,
|
||||
Util,
|
||||
JosaUtil,
|
||||
General,
|
||||
DummyGeneral,
|
||||
ActionLogger,
|
||||
GameConst,
|
||||
LastTurn,
|
||||
GameUnitConst,
|
||||
Command,
|
||||
MessageTarget,
|
||||
DiplomaticMessage,
|
||||
Message,
|
||||
};
|
||||
use \sammo\DB;
|
||||
use \sammo\Util;
|
||||
use \sammo\JosaUtil;
|
||||
use \sammo\General;
|
||||
use \sammo\DummyGeneral;
|
||||
use \sammo\ActionLogger;
|
||||
use \sammo\GameConst;
|
||||
use \sammo\LastTurn;
|
||||
use \sammo\GameUnitConst;
|
||||
use \sammo\Command;
|
||||
use \sammo\MessageTarget;
|
||||
use \sammo\DiplomaticMessage;
|
||||
use \sammo\Message;
|
||||
|
||||
use function\sammo\{
|
||||
getDomesticExpLevelBonus,
|
||||
CriticalRatioDomestic,
|
||||
CriticalScoreEx,
|
||||
getAllNationStaticInfo,
|
||||
getNationStaticInfo,
|
||||
GetImageURL
|
||||
};
|
||||
use function \sammo\getDomesticExpLevelBonus;
|
||||
use function \sammo\CriticalRatioDomestic;
|
||||
use function \sammo\CriticalScoreEx;
|
||||
use function \sammo\getAllNationStaticInfo;
|
||||
use function \sammo\getNationStaticInfo;
|
||||
use function \sammo\GetImageUR;
|
||||
|
||||
use \sammo\Constraint\Constraint;
|
||||
use \sammo\Constraint\ConstraintHelper;
|
||||
use sammo\Json;
|
||||
|
||||
class che_불가침수락 extends Command\NationCommand
|
||||
{
|
||||
@@ -191,6 +188,12 @@ class che_불가침수락 extends Command\NationCommand
|
||||
$destNationID = $destNation['nation'];
|
||||
$destNationName = $destNation['name'];
|
||||
|
||||
$destNationAux = Json::decode($db->queryFirstField('SELECT aux FROM nation WHERE nation = %i', $destNationID));
|
||||
if(!key_exists('resp_assist', $destNationAux)){
|
||||
$destNationAux['resp_assist'] = [];
|
||||
}
|
||||
$destNationAux['resp_assist'][$nationID] = $destNationAux['recv_assist'][$nationID]??0;
|
||||
|
||||
$year = $this->arg['year'];
|
||||
$month = $this->arg['month'];
|
||||
|
||||
@@ -200,6 +203,10 @@ class che_불가침수락 extends Command\NationCommand
|
||||
$currentMonth = $env['year'] * 12 + $env['month'] - 1;
|
||||
$reqMonth = $year * 12 + $month - 1;
|
||||
|
||||
$db->update('nation', [
|
||||
'aux'=>Json::encode($destNationAux)
|
||||
], 'nation=%i', $destNationID);
|
||||
|
||||
$db->update(
|
||||
'diplomacy',
|
||||
[
|
||||
|
||||
Reference in New Issue
Block a user