game: 성벽이 선제공격
This commit is contained in:
@@ -37,13 +37,25 @@ class DummyGeneral extends General
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function setCrewType(GameUnitDetail $crewType){
|
||||||
|
$this->crewType = $crewType;
|
||||||
|
}
|
||||||
|
|
||||||
public function getBattleInitSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller
|
public function getBattleInitSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller
|
||||||
{
|
{
|
||||||
|
//crewType에만 반응하자
|
||||||
|
if($this->crewType !== null){
|
||||||
|
return $this->crewType->getBattleInitSkillTriggerList($unit);
|
||||||
|
}
|
||||||
return new WarUnitTriggerCaller();
|
return new WarUnitTriggerCaller();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getBattlePhaseSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller
|
public function getBattlePhaseSkillTriggerList(WarUnit $unit): ?WarUnitTriggerCaller
|
||||||
{
|
{
|
||||||
|
//crewType에만 반응하자
|
||||||
|
if($this->crewType !== null){
|
||||||
|
return $this->crewType->getBattlePhaseSkillTriggerList($unit);
|
||||||
|
}
|
||||||
return new WarUnitTriggerCaller();
|
return new WarUnitTriggerCaller();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ class GameUnitConstBase{
|
|||||||
[],//성벽은 공격할 수 없다.
|
[],//성벽은 공격할 수 없다.
|
||||||
[self::T_FOOTMAN=>1.2],
|
[self::T_FOOTMAN=>1.2],
|
||||||
['성벽입니다.','생성할 수 없습니다.'],
|
['성벽입니다.','생성할 수 없습니다.'],
|
||||||
null, null, null
|
null, ['che_선제사격시도', 'che_선제사격발동'], null
|
||||||
],
|
],
|
||||||
|
|
||||||
[
|
[
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ class WarUnitCity extends WarUnit{
|
|||||||
|
|
||||||
$this->logger = $general->getLogger();
|
$this->logger = $general->getLogger();
|
||||||
$this->crewType = GameUnitConst::byID(GameUnitConst::CREWTYPE_CASTLE);
|
$this->crewType = GameUnitConst::byID(GameUnitConst::CREWTYPE_CASTLE);
|
||||||
|
$general->setCrewType($this->crewType);
|
||||||
|
|
||||||
$this->hp = $this->getCityVar('def') * 10;
|
$this->hp = $this->getCityVar('def') * 10;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user