setReadOnly();
$db = DB::db();
if (!$isChiefTurn && !in_array($commandType, Util::array_flatten(GameConst::$availableGeneralCommand))) {
die_redirect();
}
if ($isChiefTurn && !in_array($commandType, Util::array_flatten(GameConst::$availableChiefCommand))) {
die_redirect();
}
$gameStor = KVStorage::getStorage($db, 'game_env')->turnOnCache();
$env = $gameStor->getAll();
$general = General::createGeneralObjFromDB($session->generalID);
if (!$isChiefTurn) {
$commandObj = buildGeneralCommandClass($commandType, $general, $env);
} else {
if ($general->getVar('officer_level') < 5) {
die_redirect();
}
$commandObj = buildNationCommandClass($commandType, $general, $env, new LastTurn());
}
if ($commandObj->isArgValid()) {
//인자가 필요없는 타입의 경우 processing에서 '전혀' 처리하지 않음!
die_redirect();
}
if (!$commandObj->hasPermissionToReserve()) {
die_redirect();
}
?>
= $commandObj->getName() ?>
= WebUtil::printJS('../d_shared/common_path.js') ?>
= WebUtil::printJS('d_shared/base_map.js') ?>
= WebUtil::printCSS('../d_shared/common.css') ?>
= WebUtil::printStaticValues([
'staticValues' => [
'serverNick' => DB::prefix(),
'serverID' => UniqueConst::$serverID,
'commandName' => $commandObj->getName(),
'turnList' => $turnList,
'currentCity' => $general->getCityID(),
'currentNation' => $general->getNationID(),
'entryInfo' => [$isChiefTurn?'Nation':'General', $commandType],
'mapName' => GameConst::$mapName,
'unitSet' => GameConst::$unitSet,
],
'commandName' => $commandObj->getName(),
'turnList' => $turnList,
'currentCity' => $general->getCityID(),
'currentNation' => $general->getNationID(),
'entryInfo' => [$isChiefTurn?'Nation':'General', $commandType],
])?>
= WebUtil::printStaticValues($commandObj->exportJSVars(), false) ?>
= WebUtil::printDist('vue', ['v_processing'], true) ?>