진짜로 삭턴 버그 수정
This commit is contained in:
+5
-8
@@ -1619,9 +1619,8 @@ function checkTurn() {
|
|||||||
PreprocessCommand($general['no']);
|
PreprocessCommand($general['no']);
|
||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processAI');
|
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processAI');
|
||||||
$reduce_turn = false;
|
$reduce_turn = false;
|
||||||
if(($general['npc'] >= 2 || ($autorun_user['limit_minutes']??false)) && DecodeCommand($general['turn0'])[0] == 0) {
|
if($general['npc'] >= 2 || ($autorun_user['limit_minutes']??false)) {
|
||||||
processAI($general['no']);
|
processAI($general['no'], $reduce_turn);
|
||||||
$reduce_turn = true;
|
|
||||||
} // npc AI 처리
|
} // npc AI 처리
|
||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processCommand');
|
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processCommand');
|
||||||
processCommand($general['no'], $reduce_turn);
|
processCommand($general['no'], $reduce_turn);
|
||||||
@@ -1739,11 +1738,9 @@ function checkTurn() {
|
|||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', PreprocessCommand');
|
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', PreprocessCommand');
|
||||||
PreprocessCommand($general['no']);
|
PreprocessCommand($general['no']);
|
||||||
$reduce_turn = false;
|
$reduce_turn = false;
|
||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processAI');
|
if($general['npc'] >= 2 || ($autorun_user['limit_minutes']??false)) {
|
||||||
if($general['npc'] >= 2 || ($autorun_user['limit_minutes']??false)) {
|
processAI($general['no'], $reduce_turn);
|
||||||
processAI($general['no']);
|
}
|
||||||
$reduce_turn = true;
|
|
||||||
} // npc AI 처리
|
|
||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processCommand');
|
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', processCommand');
|
||||||
processCommand($general['no'], $reduce_turn);
|
processCommand($general['no'], $reduce_turn);
|
||||||
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', updateCommand');
|
//if(STEP_LOG) pushStepLog(date('Y-m-d H:i:s').', updateCommand');
|
||||||
|
|||||||
+3
-1
@@ -260,7 +260,7 @@ function SetCrew($no, $nationID, $personal, $gold, $leader, $genType, $tech, $de
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
function processAI($no) {
|
function processAI($no, &$reduce_turn) {
|
||||||
$db = DB::db();
|
$db = DB::db();
|
||||||
$gameStor = KVStorage::getStorage($db, 'game_env');
|
$gameStor = KVStorage::getStorage($db, 'game_env');
|
||||||
$connect=$db->get();
|
$connect=$db->get();
|
||||||
@@ -339,6 +339,8 @@ function processAI($no) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$reduce_turn = true;
|
||||||
|
|
||||||
$allowedAction = new AIAllowedAction($general['npc'], $autorun_user['options']??[]);
|
$allowedAction = new AIAllowedAction($general['npc'], $autorun_user['options']??[]);
|
||||||
|
|
||||||
$query = "select city,region,nation,level,path,rate,gen1,gen2,gen3,pop,supply,front from city where city='{$general['city']}'";
|
$query = "select city,region,nation,level,path,rate,gen1,gen2,gen3,pop,supply,front from city where city='{$general['city']}'";
|
||||||
|
|||||||
Reference in New Issue
Block a user