diff --git a/hwe/func.php b/hwe/func.php index f4bc2637..bc6ab735 100644 --- a/hwe/func.php +++ b/hwe/func.php @@ -585,19 +585,19 @@ function generalInfo(General $generalObj) $injury = $generalObj->getVar('injury'); if ($injury > 60) { - $color = ""; + $color = ""; $injury = "위독"; } elseif ($injury > 40) { - $color = ""; + $color = ""; $injury = "심각"; } elseif ($injury > 20) { - $color = ""; + $color = ""; $injury = "중상"; } elseif ($injury > 0) { - $color = ""; + $color = ""; $injury = "경상"; } else { - $color = ""; + $color = ""; $injury = "건강"; } @@ -660,17 +660,17 @@ function generalInfo(General $generalObj) echo " - + - + - + - + diff --git a/hwe/sammo/ActionItem/che_의술_청낭서.php b/hwe/sammo/ActionItem/che_의술_청낭서.php index a7ee22ea..5d09286e 100644 --- a/hwe/sammo/ActionItem/che_의술_청낭서.php +++ b/hwe/sammo/ActionItem/che_의술_청낭서.php @@ -20,7 +20,6 @@ class che_의술_청낭서 extends \sammo\BaseItem{ public function getPreTurnExecuteTriggerList(General $general):?GeneralTriggerCaller{ return new GeneralTriggerCaller( - new GeneralTrigger\che_아이템치료($general), new GeneralTrigger\che_도시치료($general) ); } diff --git a/hwe/sammo/ActionItem/che_의술_태평청령.php b/hwe/sammo/ActionItem/che_의술_태평청령.php index d8036a54..16ef926f 100644 --- a/hwe/sammo/ActionItem/che_의술_태평청령.php +++ b/hwe/sammo/ActionItem/che_의술_태평청령.php @@ -20,7 +20,6 @@ class che_의술_태평청령 extends \sammo\BaseItem{ public function getPreTurnExecuteTriggerList(General $general):?GeneralTriggerCaller{ return new GeneralTriggerCaller( - new GeneralTrigger\che_아이템치료($general), new GeneralTrigger\che_도시치료($general) ); } diff --git a/hwe/sammo/Command/General/che_하야.php b/hwe/sammo/Command/General/che_하야.php index 293c790d..79eb3405 100644 --- a/hwe/sammo/Command/General/che_하야.php +++ b/hwe/sammo/Command/General/che_하야.php @@ -83,6 +83,7 @@ class che_하야 extends Command\GeneralCommand{ $general->setVar('dedication', $general->getVar('dedication') * (1 - 0.1 * $general->getVar('betray'))); $general->addDedication(0, false); $general->increaseVarWithLimit('betray', 1, null, GameConst::$maxBetrayCnt); + $general->setVar('permission', 'normal'); $newGold = Util::valueFit($general->getVar('gold'), null, GameConst::$defaultGold); $newRice = Util::valueFit($general->getVar('rice'), null, GameConst::$defaultRice); diff --git a/hwe/sammo/Event/Action/CreateManyNPC.php b/hwe/sammo/Event/Action/CreateManyNPC.php index 1a0e32d9..b22a8795 100644 --- a/hwe/sammo/Event/Action/CreateManyNPC.php +++ b/hwe/sammo/Event/Action/CreateManyNPC.php @@ -7,7 +7,6 @@ class CreateManyNPC extends \sammo\Event\Action{ protected $npcCount; protected $avgGen; public function __construct($npcCount = 200){ - \sammo\LogText('ctc',$npcCount); $this->npcCount = $npcCount; } diff --git a/hwe/sammo/General.php b/hwe/sammo/General.php index 7bb94601..f73d5177 100644 --- a/hwe/sammo/General.php +++ b/hwe/sammo/General.php @@ -756,9 +756,6 @@ class General implements iAction{ if(!$iObj){ continue; } - if($caller->isEmpty()){ - continue; - } /** @var iAction $iObj */ $caller->merge($iObj->getPreTurnExecuteTriggerList($general)); } diff --git a/hwe/sammo/GeneralTrigger/che_도시치료.php b/hwe/sammo/GeneralTrigger/che_도시치료.php index b1fe14ee..0d3bfd44 100644 --- a/hwe/sammo/GeneralTrigger/che_도시치료.php +++ b/hwe/sammo/GeneralTrigger/che_도시치료.php @@ -8,7 +8,7 @@ use sammo\Util; use sammo\JosaUtil; class che_도시치료 extends BaseGeneralTrigger{ - protected $priority = 10000; + protected $priority = 10010; public function action(?array $env=null, $arg=null):?array{ diff --git a/hwe/sammo/GeneralTrigger/che_부상경감.php b/hwe/sammo/GeneralTrigger/che_부상경감.php index c3a426ba..74a019dd 100644 --- a/hwe/sammo/GeneralTrigger/che_부상경감.php +++ b/hwe/sammo/GeneralTrigger/che_부상경감.php @@ -8,7 +8,7 @@ use sammo\Util; use sammo\JosaUtil; class che_부상경감 extends BaseGeneralTrigger{ - protected $priority = 30010; + protected $priority = 10000; public function action(?array $env=null, $arg=null):?array{ diff --git a/hwe/sammo/GeneralTrigger/che_아이템치료.php b/hwe/sammo/GeneralTrigger/che_아이템치료.php index df679055..9970a133 100644 --- a/hwe/sammo/GeneralTrigger/che_아이템치료.php +++ b/hwe/sammo/GeneralTrigger/che_아이템치료.php @@ -15,7 +15,7 @@ class che_아이템치료 extends BaseGeneralTrigger{ /** @var \sammo\General $general */ $general = $this->object; - if($general->getVar('injury') > 0){ + if($general->getVar('injury') >= 10){ $general->updateVar('injury', 0); $general->activateSkill('pre.부상경감', 'pre.치료'); $itemObj = $general->getItem(); diff --git a/hwe/sammo/ObjectTrigger.php b/hwe/sammo/ObjectTrigger.php index 32bef848..ad3754f7 100644 --- a/hwe/sammo/ObjectTrigger.php +++ b/hwe/sammo/ObjectTrigger.php @@ -9,6 +9,7 @@ abstract class ObjectTrigger{ const PRIORITY_POST = 40000; const PRIORITY_FINAL = 50000; + /** @var int 낮을 수록 우선순위가 높다. */ protected $priority; protected $object = null; diff --git a/hwe/sammo/TriggerCaller.php b/hwe/sammo/TriggerCaller.php index ab2650f1..7207eab5 100644 --- a/hwe/sammo/TriggerCaller.php +++ b/hwe/sammo/TriggerCaller.php @@ -94,7 +94,7 @@ abstract class TriggerCaller{ $iterLhs->next(); continue; } - if($iterRhs->key() > $iterLhs->key()){ + if($iterRhs->key() < $iterLhs->key()){ $newTriggerList[$iterRhs->key()] = $iterRhs->current(); $iterRhs->next(); continue;
 {$generalObj->getName()} 【 {$officerLevelText} | {$call} | {$color}{$injury} 】 " . $generalObj->getTurnTime($generalObj::TURNTIME_HMS) . "{$generalObj->getName()} 【 {$officerLevelText} | {$call} | {$color}{$injury} 】 " . $generalObj->getTurnTime($generalObj::TURNTIME_HMS) . "
통솔 {$color}{$leadership}{$lbonus}  {$color}{$leadership}{$lbonus}  " . bar(expStatus($generalObj->getVar('leadership_exp')), 20) . " 무력 {$color}{$strength}  {$color}{$strength}  " . bar(expStatus($generalObj->getVar('strength_exp')), 20) . " 지력 {$color}{$intel}  {$color}{$intel}  " . bar(expStatus($generalObj->getVar('intel_exp')), 20) . "