[881bf08aee]v.0.10.0 커밋까지 반영
This commit is contained in:
@@ -345,6 +345,20 @@ class DiplomaticMessage extends Message{
|
||||
$this->invalidate();
|
||||
$newMsg->send();
|
||||
|
||||
$newMsg = new Message(
|
||||
self::MSGTYPE_DIPLOMACY,
|
||||
$this->dest,
|
||||
$this->src,
|
||||
"【외교】{$year}년 {$month}월: {$this->src->nationName}{$josaYi} {$this->dest->nationName}에게 제안한 {$this->diplomacyDetail}{$this->diplomacyName} 동의.",
|
||||
new \DateTime(),
|
||||
new \DateTime('9999-12-31'),
|
||||
[
|
||||
'delete'=>$this->id,
|
||||
'silence'=>true,
|
||||
]
|
||||
);
|
||||
$newMsg->send();
|
||||
|
||||
return self::ACCEPTED;
|
||||
|
||||
}
|
||||
|
||||
@@ -1107,6 +1107,12 @@ class GeneralAI{
|
||||
$arg = null;
|
||||
$generalObj->setVar('killturn', 1);
|
||||
}
|
||||
else if($general->getVar('level') == 12){
|
||||
$command = 'che_선양';
|
||||
$arg = [
|
||||
'destGeneralID'=> $db->queryFirstField('SELECT `no` FROM general WHERE nation = %i AND npc != 5 ORDER BY RAND() LIMIT 1', $general->getNationID())
|
||||
];
|
||||
}
|
||||
else{
|
||||
$command = 'che_집합'; //집합
|
||||
$arg = [];
|
||||
@@ -1618,6 +1624,10 @@ class GeneralAI{
|
||||
//이 함수를 부르는건 군주 AI이므로, 군주는 세지 않아도 됨
|
||||
$userChief = [];
|
||||
|
||||
$db->update('general', [
|
||||
'permission'=>'ambassador',
|
||||
], 'nation=%i AND npc < 2 AND level > 4', $nationID);
|
||||
|
||||
foreach($db->query(
|
||||
'SELECT no, npc, level, killturn FROM general WHERE nation = %i AND 12 > level AND level > 4', $nationID
|
||||
) as $chief){
|
||||
|
||||
Reference in New Issue
Block a user