nation_env 수정, $connect 일부 제거

This commit is contained in:
2020-05-06 01:53:00 +09:00
parent 562c69307e
commit e0c908d88f
26 changed files with 416 additions and 811 deletions
+2 -6
View File
@@ -79,13 +79,9 @@ if ($gencount >= $admin['maxgeneral']) {
$nationList = $db->query('SELECT nation,`name`,color,scout FROM nation');
shuffle($nationList);
$nationList = Util::convertArrayToDict($nationList, 'nation');
$nationStor = KVStorage::getStorage($db, 'nation_env');
//NOTE: join 안할것임
$scoutMsgs = $nationStor->getValues(array_map(function($nationID){
return "nation_scout_msg_{$nationID}";
}, array_keys($nationList)));
foreach($scoutMsgs as $nationIDPack=>$scoutMsg){
$nationID = Util::toInt(Util::array_last(explode('_', $nationIDPack)));
$scoutMsgs = KVStorage::getValuesFromInterNamespace($db, 'nation_env', 'scout_msg');
foreach($scoutMsgs as $nationID=>$scoutMsg){
$nationList[$nationID]['scoutmsg'] = $scoutMsg;
}