Skip to content

Commit

Permalink
Merge pull request #1098 from wowsims/feature/mage-p3
Browse files Browse the repository at this point in the history
Update Arcane P3
  • Loading branch information
1337LutZ authored Oct 16, 2024
2 parents e2b7ad5 + 0cda3d4 commit 940b8e1
Show file tree
Hide file tree
Showing 10 changed files with 1,154 additions and 1,154 deletions.
1,108 changes: 554 additions & 554 deletions sim/mage/arcane/TestArcane.results

Large diffs are not rendered by default.

1,094 changes: 547 additions & 547 deletions sim/mage/fire/TestFire.results

Large diffs are not rendered by default.

8 changes: 3 additions & 5 deletions sim/mage/items.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ var ItemSetFirehawkRobesOfConflagration = core.NewItemSet(core.ItemSet{
// Your spells have an increased chance to trigger Brain Freeze or Hot Streak.
// In addition, Arcane Power decreases the cost of your damaging spells by 10% instead of increasing their cost.
4: func(agent core.Agent) {
// Arcane Power Cost reduction implemented in:
// talents_arcane.go#278

mage := agent.(MageAgent).GetMage()

core.MakePermanent(mage.RegisterAura(core.Aura{
Expand All @@ -68,11 +71,6 @@ var ItemSetFirehawkRobesOfConflagration = core.NewItemSet(core.ItemSet{
},
}))

mage.OnSpellRegistered(func(spell *core.Spell) {
if spell.ClassSpellMask == MageSpellArcanePower {
mage.arcanePowerCostMod.UpdateFloatValue(-0.1)
}
})
},
},
})
Expand Down
3 changes: 1 addition & 2 deletions sim/mage/mage.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ type Mage struct {
SummonWaterElemental *core.Spell
IcyVeins *core.Spell

arcanePowerGCDmod *core.SpellMod
arcanePowerCostMod *core.SpellMod
arcanePowerGCDmod *core.SpellMod

arcaneMissilesProcAura *core.Aura
arcanePotencyAura *core.Aura
Expand Down
2 changes: 1 addition & 1 deletion sim/mage/mirror_image_t12.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func (mi *T12MirrorImage) registerFireballSpell() {
ThreatMultiplier: 1,

ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
baseDamage := sim.Roll(6490, 7543)
baseDamage := sim.RollWithLabel(6490, 7543, "T12 Mirror Image Fireball")
result := spell.CalcDamage(sim, target, baseDamage, spell.OutcomeMagicHitAndCrit)
spell.WaitTravelTime(sim, func(sim *core.Simulation) {
spell.DealDamage(sim, result)
Expand Down
8 changes: 4 additions & 4 deletions sim/mage/talents_arcane.go
Original file line number Diff line number Diff line change
Expand Up @@ -282,9 +282,9 @@ func (mage *Mage) registerArcanePowerCD() {

actionID := core.ActionID{SpellID: 12042}

mage.arcanePowerCostMod = mage.AddDynamicMod(core.SpellModConfig{
arcanePowerCostMod := mage.AddDynamicMod(core.SpellModConfig{
ClassMask: MageSpellsAllDamaging,
FloatValue: 0.1,
FloatValue: core.TernaryFloat64(mage.HasSetBonus(ItemSetFirehawkRobesOfConflagration, 4), -0.1, 0.2),
Kind: core.SpellMod_PowerCost_Pct,
})

Expand All @@ -302,14 +302,14 @@ func (mage *Mage) registerArcanePowerCD() {
if mage.arcanePowerGCDmod != nil {
mage.arcanePowerGCDmod.Activate()
}
mage.arcanePowerCostMod.Activate()
arcanePowerCostMod.Activate()
arcanePowerDmgMod.Activate()
},
OnExpire: func(_ *core.Aura, sim *core.Simulation) {
if mage.arcanePowerGCDmod != nil {
mage.arcanePowerGCDmod.Deactivate()
}
mage.arcanePowerCostMod.Deactivate()
arcanePowerCostMod.Deactivate()
arcanePowerDmgMod.Deactivate()
if mage.t13ProcAura != nil {
mage.t13ProcAura.Deactivate(sim)
Expand Down
12 changes: 6 additions & 6 deletions ui/mage/arcane/gear_sets/p1.gear.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
{
"items": [
{ "id": 60237, "enchant": 4207, "gems": [68780, 52217], "reforging": 144 },
{ "id": 60237, "enchant": 4207, "gems": [68780, 52217], "reforging": 151 },
{ "id": 69882, "randomSuffix": -114 },
{ "id": 65213, "enchant": 4200, "gems": [52207], "reforging": 154 },
{ "id": 60232, "enchant": 4115, "gems": [52205], "reforging": 151 },
{ "id": 60232, "enchant": 4096, "gems": [52205], "reforging": 151 },
{ "id": 65212, "enchant": 4102, "gems": [52207, 52217], "reforging": 151 },
{ "id": 65138, "enchant": 4257, "gems": [0], "reforging": 151 },
{ "id": 65209, "enchant": 4068, "gems": [52207, 0], "reforging": 165 },
{ "id": 65209, "enchant": 4068, "gems": [52207, 0], "reforging": 144 },
{ "id": 65376, "randomSuffix": -230, "gems": [52208, 52207], "reforging": 151 },
{ "id": 65211, "enchant": 4112, "gems": [52208, 52207], "reforging": 154 },
{ "id": 65069, "enchant": 4104, "gems": [52207], "reforging": 151 },
{ "id": 65373, "randomSuffix": -114 },
{ "id": 65123, "reforging": 151 },
{ "id": 65373, "randomSuffix": -114, "enchant": 4080 },
{ "id": 65123, "enchant": 4080, "reforging": 151 },
{ "id": 65105 },
{ "id": 65053, "reforging": 144 },
{ "id": 68132, "randomSuffix": -114, "enchant": 4097 },
{ "id": 65133, "enchant": 4091, "reforging": 154 },
{ "id": 59460, "reforging": 137 }
{ "id": 59460 }
]
}
26 changes: 13 additions & 13 deletions ui/mage/arcane/gear_sets/p3.gear.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
{
"items": [
{ "id": 71508, "enchant": 4207, "gems": [68780, 52207], "reforging": 165 },
{ "id": 71472, "gems": [52207], "reforging": 151 },
{ "id": 71511, "enchant": 4200, "gems": [52207], "reforging": 144 },
{ "id": 71434, "enchant": 4115, "reforging": 144 },
{ "id": 71510, "enchant": 4102, "gems": [52207, 52207], "reforging": 154 },
{ "id": 71471, "enchant": 4257, "gems": [0], "reforging": 144 },
{ "id": 71614, "enchant": 4068, "gems": [52207, 0], "reforging": 144 },
{ "id": 71613, "gems": [52207, 52207], "reforging": 165 },
{ "id": 71508, "enchant": 4207, "gems": [68780, 52207], "reforging": 151 },
{ "id": 71472, "gems": [52207], "reforging": 165 },
{ "id": 71511, "enchant": 4200, "gems": [52205], "reforging": 144 },
{ "id": 71434, "enchant": 4096, "reforging": 144 },
{ "id": 71510, "enchant": 4102, "gems": [52205, 52217], "reforging": 154 },
{ "id": 71471, "enchant": 4257, "gems": [0], "reforging": 151 },
{ "id": 71614, "enchant": 4107, "gems": [52207, 0], "reforging": 144 },
{ "id": 71613, "gems": [52207, 52217], "reforging": 151 },
{ "id": 71509, "enchant": 4112, "gems": [52207, 52207], "reforging": 144 },
{ "id": 71447, "enchant": 4104, "gems": [52207], "reforging": 144 },
{ "id": 71217, "gems": [52207], "reforging": 154 },
{ "id": 71449, "reforging": 144 },
{ "id": 71447, "enchant": 4092, "gems": [52205], "reforging": 144 },
{ "id": 71217, "enchant": 4080, "gems": [52207], "reforging": 154 },
{ "id": 71449, "enchant": 4080, "reforging": 144 },
{ "id": 65105 },
{ "id": 69110 },
{ "id": 62047, "reforging": 165 },
{ "id": 71086, "enchant": 4097, "gems": [52207, 52207, 52207], "reforging": 154 },
{},
{ "id": 71575, "reforging": 140 }
{ "id": 71575 }
]
}
12 changes: 6 additions & 6 deletions ui/mage/arcane/presets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ export const ARCANE_ROTATION_PRESET_DEFAULT = PresetUtils.makePresetAPLRotation(
export const P1_EP_PRESET = PresetUtils.makePresetEpWeights(
'Default',
Stats.fromMap({
[Stat.StatIntellect]: 1.76,
[Stat.StatIntellect]: 1.8,
[Stat.StatSpellPower]: 1,
[Stat.StatHitRating]: 1.31,
[Stat.StatCritRating]: 0.53,
[Stat.StatHasteRating]: 0.91,
[Stat.StatMasteryRating]: 0.57,
[Stat.StatHitRating]: 1.52,
[Stat.StatCritRating]: 0.65,
[Stat.StatHasteRating]: 0.70,
[Stat.StatMasteryRating]: 0.67,
}),
);

Expand Down Expand Up @@ -93,5 +93,5 @@ export const DefaultDebuffs = Debuffs.create({
export const OtherDefaults = {
distanceFromTarget: 20,
profession1: Profession.Engineering,
profession2: Profession.Tailoring,
profession2: Profession.Enchanting,
};
35 changes: 19 additions & 16 deletions ui/mage/arcane/sim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,8 @@ const SPEC_CONFIG = registerSpecConfig(Spec.SpecArcaneMage, {
epReferenceStat: Stat.StatSpellPower,
// Which stats to display in the Character Stats section, at the bottom of the left-hand sidebar.
displayStats: UnitStat.createDisplayStatArray(
[
Stat.StatHealth,
Stat.StatMana,
Stat.StatStamina,
Stat.StatIntellect,
Stat.StatSpellPower,
Stat.StatMasteryRating,
],
[
PseudoStat.PseudoStatSpellHitPercent,
PseudoStat.PseudoStatSpellCritPercent,
PseudoStat.PseudoStatSpellHastePercent,
],
[Stat.StatHealth, Stat.StatMana, Stat.StatStamina, Stat.StatIntellect, Stat.StatSpellPower, Stat.StatMasteryRating],
[PseudoStat.PseudoStatSpellHitPercent, PseudoStat.PseudoStatSpellCritPercent, PseudoStat.PseudoStatSpellHastePercent],
),
modifyDisplayStats: (player: Player<Spec.SpecArcaneMage>) => {
return sharedMageDisplayStatsModifiers(player);
Expand All @@ -56,11 +45,11 @@ const SPEC_CONFIG = registerSpecConfig(Spec.SpecArcaneMage, {
// Sources:
// https://www.icy-veins.com/cataclysm-classic/arcane-mage-pve-stat-priority
// https://www.wowhead.com/cata/guide/classes/mage/arcane/dps-stat-priority-attributes-pve
const breakpoints = [2497 / Mechanics.HASTE_RATING_PER_HASTE_PERCENT];
const breakpoints = [23.14];
const hasteSoftCapConfig = StatCap.fromPseudoStat(PseudoStat.PseudoStatSpellHastePercent, {
breakpoints,
capType: StatCapType.TypeSoftCap,
postCapEPs: [0.56 * Mechanics.HASTE_RATING_PER_HASTE_PERCENT],
postCapEPs: [0.48 * Mechanics.HASTE_RATING_PER_HASTE_PERCENT],
});

return [hasteSoftCapConfig];
Expand Down Expand Up @@ -222,7 +211,21 @@ export class ArcaneMageSimUI extends IndividualSimUI<Spec.SpecArcaneMage> {
super(parentElem, player, SPEC_CONFIG);

player.sim.waitForInit().then(() => {
new ReforgeOptimizer(this);
new ReforgeOptimizer(this, {
updateSoftCaps: softCaps => {
const gear = player.getGear();
const hasT114P = gear.getItemSetCount("Firelord's Vestments") >= 4;

if (hasT114P) {
const softCapToModify = softCaps.find(sc => sc.unitStat.equalsPseudoStat(PseudoStat.PseudoStatSpellHastePercent));
if (softCapToModify) {
softCapToModify.breakpoints[0] = 17.48;
}
}

return softCaps;
},
});
});
}
}

0 comments on commit 940b8e1

Please sign in to comment.