전특 대 개편

This commit is contained in:
2020-07-15 02:33:21 +09:00
parent 7c95a483df
commit dc000cecf1
45 changed files with 1637 additions and 1422 deletions
@@ -1,31 +1,31 @@
<?php
namespace sammo\WarUnitTrigger;
use sammo\BaseWarUnitTrigger;
use sammo\WarUnitGeneral;
use sammo\WarUnitCity;
use sammo\WarUnit;
use sammo\GameUnitDetail;
use sammo\Util;
use sammo\ObjectTrigger;
class che_전투치료시도 extends BaseWarUnitTrigger{
protected $priority = ObjectTrigger::PRIORITY_PRE + 300;
protected function actionWar(WarUnit $self, WarUnit $oppose, array &$selfEnv, array &$opposeEnv):bool{
assert($self instanceof WarUnitGeneral, 'General만 발동 가능');
if($self->hasActivatedSkill('치료')){
return true;
}
if($self->hasActivatedSkill('치료불가')){
return true;
}
if(!Util::randBool(1/5)){
return true;
}
$self->activateSkill('치료');
return true;
}
<?php
namespace sammo\WarUnitTrigger;
use sammo\BaseWarUnitTrigger;
use sammo\WarUnitGeneral;
use sammo\WarUnitCity;
use sammo\WarUnit;
use sammo\GameUnitDetail;
use sammo\Util;
use sammo\ObjectTrigger;
class che_전투치료시도 extends BaseWarUnitTrigger{
protected $priority = ObjectTrigger::PRIORITY_PRE + 300;
protected function actionWar(WarUnit $self, WarUnit $oppose, array &$selfEnv, array &$opposeEnv):bool{
assert($self instanceof WarUnitGeneral, 'General만 발동 가능');
if($self->hasActivatedSkill('치료')){
return true;
}
if($self->hasActivatedSkill('치료불가')){
return true;
}
if(!Util::randBool(0.4)){
return true;
}
$self->activateSkill('치료');
return true;
}
}