이민족 코드를 5에서 9로 이동. 그에따른 추가 코드 변경

This commit is contained in:
2018-08-08 02:31:49 +09:00
parent 975bdd5897
commit 34623fca94
6 changed files with 13 additions and 12 deletions
+2 -2
View File
@@ -90,13 +90,13 @@ class RaiseInvader extends \sammo\Event\Action{
if($npcEachCount < 0){
$npcEachCount =
$db->queryFirstField('SELECT count(no) from general where npc<5') / count(self::INVADER_LIST);
$db->queryFirstField('SELECT count(no) from general where npc < 9') / count(self::INVADER_LIST);
$npcEachCount /= -1 * $this->npcEachCount;
}
$specAvg = $this->specAvg;
if($specAvg < 0){
$specAvg = $db->queryFirstField('SELECT avg(sum(`leader` + `power` + `intel`)) from general where npc<5');
$specAvg = $db->queryFirstField('SELECT avg(sum(`leader` + `power` + `intel`)) from general where npc < 9');
$specAvg /= -1 * $this->specAvg;
}
+3 -2
View File
@@ -22,6 +22,7 @@ class NPC{
public $ego;
public $charDomestic = 0;
public $charWar = 0;
public $npc = 2;
public $text;
//[ 1, "헌제",1002, 1, null, 17, 13, 61, 0, 170, 250, "안전", null, "산 넘어 산이로구나..."],
@@ -211,8 +212,8 @@ class NPC{
$db->insert('general',[
'npcid'=>$npcID,
'npc'=>2,
'npc_org'=>2,
'npc'=>$this->npc,
'npc_org'=>$this->npc,
'affinity'=>$affinity,
'name'=>$name,
'picture'=>$picturePath,