From 4e504e9679a8059e86d0cc2e8df587da1c922d32 Mon Sep 17 00:00:00 2001 From: Hide_D Date: Thu, 11 May 2023 02:46:18 +0900 Subject: [PATCH] =?UTF-8?q?game:=20=EC=84=B1=EB=B2=BD=EC=9D=B4=20=EC=84=A0?= =?UTF-8?q?=EC=A0=9C=EA=B3=B5=EA=B2=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/sammo/DummyGeneral.php | 12 ++++++++++++ hwe/sammo/GameUnitConstBase.php | 2 +- hwe/sammo/WarUnitCity.php | 1 + 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/hwe/sammo/DummyGeneral.php b/hwe/sammo/DummyGeneral.php index 6d01d40f..9e6acb2d 100644 --- a/hwe/sammo/DummyGeneral.php +++ b/hwe/sammo/DummyGeneral.php @@ -37,13 +37,25 @@ class DummyGeneral extends General } } + public function setCrewType(GameUnitDetail $crewType){ + $this->crewType = $crewType; + } + public function getBattleInitSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller { + //crewType에만 반응하자 + if($this->crewType !== null){ + return $this->crewType->getBattleInitSkillTriggerList($unit); + } return new WarUnitTriggerCaller(); } public function getBattlePhaseSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller { + //crewType에만 반응하자 + if($this->crewType !== null){ + return $this->crewType->getBattlePhaseSkillTriggerList($unit); + } return new WarUnitTriggerCaller(); } diff --git a/hwe/sammo/GameUnitConstBase.php b/hwe/sammo/GameUnitConstBase.php index 762161ab..4c316aee 100644 --- a/hwe/sammo/GameUnitConstBase.php +++ b/hwe/sammo/GameUnitConstBase.php @@ -41,7 +41,7 @@ class GameUnitConstBase{ [],//성벽은 공격할 수 없다. [self::T_FOOTMAN=>1.2], ['성벽입니다.','생성할 수 없습니다.'], - null, null, null + null, ['che_선제사격시도', 'che_선제사격발동'], null ], [ diff --git a/hwe/sammo/WarUnitCity.php b/hwe/sammo/WarUnitCity.php index d3f1d513..df4a7fa2 100644 --- a/hwe/sammo/WarUnitCity.php +++ b/hwe/sammo/WarUnitCity.php @@ -25,6 +25,7 @@ class WarUnitCity extends WarUnit{ $this->logger = $general->getLogger(); $this->crewType = GameUnitConst::byID(GameUnitConst::CREWTYPE_CASTLE); + $general->setCrewType($this->crewType); $this->hp = $this->getCityVar('def') * 10;