mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-27 10:42:25 +02:00
added makeContact to the physical part of shell side arm
This commit is contained in:
parent
5db3074e2c
commit
4539416af9
@ -4612,11 +4612,13 @@ export class ShellSideArmCategoryAttr extends VariableMoveCategoryAttr {
|
||||
const predictedPhysDmg = target.getBaseDamage(user, move, MoveCategory.PHYSICAL, true, true);
|
||||
const predictedSpecDmg = target.getBaseDamage(user, move, MoveCategory.SPECIAL, true, true);
|
||||
|
||||
if (predictedPhysDmg > predictedSpecDmg) {
|
||||
category.value = MoveCategory.PHYSICAL;
|
||||
return true;
|
||||
} else if (predictedPhysDmg === predictedSpecDmg && user.randSeedInt(2) === 0) {
|
||||
const shouldUsePhysical =
|
||||
predictedPhysDmg > predictedSpecDmg ||
|
||||
(predictedPhysDmg === predictedSpecDmg && user.randSeedInt(2) === 0);
|
||||
|
||||
if (shouldUsePhysical) {
|
||||
category.value = MoveCategory.PHYSICAL;
|
||||
move.makesContact();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user