버그 수정
This commit is contained in:
@@ -422,6 +422,16 @@ class General implements iAction{
|
||||
return $this->getStatValue('intel', $withInjury, $withIActionObj, $withStatAdjust, $useFloor);
|
||||
}
|
||||
|
||||
function getDex(GameUnitDetail $crewType){
|
||||
$armType = $crewType->armType;
|
||||
|
||||
if($armType == GameUnitConst::T_CASTLE){
|
||||
$armType = GameUnitConst::T_SIEGE;
|
||||
}
|
||||
|
||||
return $this->getVar("dex{$armType}");
|
||||
}
|
||||
|
||||
function addDex(GameUnitDetail $crewType, float $exp, bool $affectTrainAtmos=false){
|
||||
$armType = $crewType->armType;
|
||||
|
||||
|
||||
@@ -238,14 +238,14 @@ class WarUnit{
|
||||
$warPower /= $oppose->getComputedTrain();
|
||||
|
||||
if($this instanceof WarUnitGeneral){
|
||||
$genDexAtt = getGenDex($this->getRaw(), $this->getCrewType()->id);
|
||||
$genDexAtt = $general->getDex($this->getCrewType());
|
||||
}
|
||||
else{
|
||||
$genDexAtt = ($this->cityRate - 60) * 7200;
|
||||
}
|
||||
|
||||
if($this instanceof WarUnitGeneral){
|
||||
$oppDexDef = getGenDex($oppose->getRaw(), $this->getCrewType()->id);
|
||||
$oppDexDef = $opposeGeneral->getDex($this->getCrewType());
|
||||
}
|
||||
else{
|
||||
$oppDexDef = ($this->cityRate - 60) * 7200;
|
||||
|
||||
Reference in New Issue
Block a user