Update Healer Man server
This commit is contained in:
1 parent
fdb6739f8d
commit
f90ba7d989
41 files changed
+1671
-118
No files matched your search
+35
-4
@@ -4626,6 +4626,14 @@ export const useCombatStore = create<CombatState>((set, get) => ({
|
||||
? abilityAtLevel(catalogAbility, state.level, learnedTalentRank)
|
||||
: null;
|
||||
const activePlayerAuras = aurasForEntity(state.auras, PLAYER_AURA_ENTITY_ID);
|
||||
const innerFocusAura = activePlayerAuras.find((aura) => (
|
||||
aura.definition.utilityTags?.includes("next-heal-free-critical")
|
||||
));
|
||||
const consumesInnerFocus = Boolean(
|
||||
innerFocusAura
|
||||
&& ability?.name !== "Inner Focus"
|
||||
&& ability?.effects.some((effect) => effect.kind === "heal"),
|
||||
);
|
||||
const hasRuneWakerState = (tag: string) => activePlayerAuras.some((aura) => aura.definition.utilityTags?.includes(tag));
|
||||
const holyAuraFriendly = Boolean(
|
||||
ability?.source === "runewaker"
|
||||
@@ -4640,9 +4648,21 @@ export const useCombatStore = create<CombatState>((set, get) => ({
|
||||
? completingCast.targetId && state.mobs[completingCast.targetId] ? "hostile" : "friendly"
|
||||
: state.selectedFriendlyActorId || party.selectedMemberId || party.selfSelected ? "friendly" : "hostile"
|
||||
: ability?.target;
|
||||
const modifiers = state.talentModifiers;
|
||||
const resourceCost = ability ? talentAdjustedResourceCost(ability, modifiers) : 0;
|
||||
const costs = ability ? resolvedAbilityCosts(ability, modifiers, state) : [];
|
||||
const modifiers: readonly TalentModifier[] = consumesInnerFocus ? [
|
||||
...state.talentModifiers,
|
||||
{
|
||||
kind: "critical-chance-percent",
|
||||
amount: 25,
|
||||
unit: "percent",
|
||||
scope: "your healing spells",
|
||||
sourceTalentId: "talent-348:active",
|
||||
sourceTalentName: "Inner Focus",
|
||||
rank: 1,
|
||||
description: "The next direct or area heal costs no resource and gains 25 percentage points of critical chance.",
|
||||
},
|
||||
] : state.talentModifiers;
|
||||
const resourceCost = ability && !consumesInnerFocus ? talentAdjustedResourceCost(ability, modifiers) : 0;
|
||||
const costs = ability && !consumesInnerFocus ? resolvedAbilityCosts(ability, modifiers, state) : [];
|
||||
const costsToSpend = completingCast?.mode === "channel" ? [] : costs;
|
||||
const targeting = ability ? targetingRulesForAbility(ability) : null;
|
||||
const spellSchool = ability ? ability.castRules?.school ?? abilityDamageSchool(state.classId, ability) : "physical";
|
||||
@@ -4959,6 +4979,9 @@ export const useCombatStore = create<CombatState>((set, get) => ({
|
||||
raceId: state.raceId,
|
||||
secondaryClassId: state.secondaryClassId,
|
||||
};
|
||||
if (consumesInnerFocus && innerFocusAura) {
|
||||
work.auras = work.auras.filter((aura) => aura.instanceId !== innerFocusAura.instanceId);
|
||||
}
|
||||
const castThreatSource = playerThreatSource(state, ability.id);
|
||||
|
||||
if (targeting?.shape === "ground" && groundPosition) {
|
||||
@@ -5194,7 +5217,15 @@ export const useCombatStore = create<CombatState>((set, get) => ({
|
||||
playerCharacterStats(state.classId, state.level, state.gearStats, state.raceId, state.secondaryClassId, modifiers),
|
||||
aurasForEntity(work.auras, PLAYER_AURA_ENTITY_ID),
|
||||
);
|
||||
const criticalChance = Math.max(0, casterStats.spellCritPercent / 100);
|
||||
const criticalChance = Math.max(0, (
|
||||
casterStats.spellCritPercent
|
||||
+ applyTalentModifierValue(
|
||||
0,
|
||||
modifiers,
|
||||
"critical-chance-percent",
|
||||
abilityTalentContext(ability),
|
||||
)
|
||||
) / 100);
|
||||
let directHealing = 0;
|
||||
healingTargetIds = [...healingRecipientIds(effect, PLAYER_AURA_ENTITY_ID, targetId, work.actors,
|
||||
id => friendlyPosition(id) ?? getMobPosition(id), healingTargetIds, combatHasLineOfSight, now)];
|
||||
|
||||
Reference in new issue
Block a user