diff --git a/hwe/func_converter.php b/hwe/func_converter.php index fc4a0d06..a688bc75 100644 --- a/hwe/func_converter.php +++ b/hwe/func_converter.php @@ -346,7 +346,7 @@ function getActionCrewTypeClass(?string $type){ throw new \InvalidArgumentException("{$type}은 올바른 병종 효과가 아님"); } -function buildActionCrewTypeClass(?string $type):BaseSpecial{ +function buildActionCrewTypeClass(?string $type):iAction{ static $cache = []; if($type === null){ $type = 'None'; diff --git a/hwe/sammo/GameUnitDetail.php b/hwe/sammo/GameUnitDetail.php index 134d3f64..d2cf3958 100644 --- a/hwe/sammo/GameUnitDetail.php +++ b/hwe/sammo/GameUnitDetail.php @@ -69,7 +69,9 @@ class GameUnitDetail implements iAction $this->info = $info; $this->initSkillTrigger = $initSkillTrigger; $this->phaseSkillTrigger = $phaseSkillTrigger; - $this->iActionList = array_map('buildActionCrewTypeClass', $iActionList ?? []); + $this->iActionList = array_map(function($rawAction){ + return buildActionCrewTypeClass($rawAction); + }, $iActionList ?? []); } public function getInfo(): string