generalSource 폐기

This commit is contained in:
2018-10-17 16:01:38 +09:00
parent dbcfe6fc6e
commit 1004e5a8bd
14 changed files with 67 additions and 91 deletions
+4 -4
View File
@@ -504,9 +504,9 @@ class General implements iAction{
return $caller;
}
static public function createGeneralObjFromDB(int $generalID, ?array $column=null, bool $fullConstruct=true):self{
static public function createGeneralObjFromDB(int $generalID, ?array $column=null, int $constructMode=2):self{
$db = DB::db();
if($fullConstruct){
if($constructMode > 0){
$gameStor = KVStorage::getStorage($db, 'game_env');
[$year, $month] = $gameStor->getValuesAsArray(['year', 'month']);
}
@@ -533,7 +533,7 @@ class General implements iAction{
if($column === null){
$column = $fullColumn;
}
else if($fullConstruct){
else if($constructMode > 1){
$column = array_unique(array_merge($defaultEventColumn, $column));
}
else{
@@ -545,7 +545,7 @@ class General implements iAction{
throw new \InvalidArgumentException("generalID에 해당하는 장수가 없음: {$generalID}");
}
$general = new static($rawGeneral, null, $year, $month, $fullConstruct);
$general = new static($rawGeneral, null, $year, $month, $constructMode > 1);
return $general;
}