Skip to content

Commit

Permalink
Merge pull request wowsims#3854 from wowsims/apl
Browse files Browse the repository at this point in the history
Merge mage simple presets into 1
  • Loading branch information
jimmyt857 authored Oct 9, 2023
2 parents 7b38c4a + 17c043d commit 32cbb37
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 58 deletions.
68 changes: 17 additions & 51 deletions ui/mage/presets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,14 +109,16 @@ export const FrostTalents = {
}),
};

export const DefaultFireRotation = MageRotation.create({
export const DefaultSimpleRotation = MageRotation.create({
only3ArcaneBlastStacksBelowManaPercent: 0.15,
blastWithoutMissileBarrageAboveManaPercent: 0.2,
missileBarrageBelowManaPercent: 0,
useArcaneBarrage: false,

primaryFireSpell: PrimaryFireSpell.Fireball,
maintainImprovedScorch: false,
});

export const DefaultFFBRotation = MageRotation.create({
primaryFireSpell: PrimaryFireSpell.FrostfireBolt,
maintainImprovedScorch: false,
useIceLance: false,
});

export const DefaultFFBOptions = MageOptions.create({
Expand All @@ -137,9 +139,6 @@ export const DefaultFireConsumes = Consumes.create({
prepopPotion: Potions.PotionOfSpeed,
});

export const DefaultFrostRotation = MageRotation.create({
});

export const DefaultFrostOptions = MageOptions.create({
armor: ArmorType.MoltenArmor,
focusMagicTarget: UnitReference.create(),
Expand All @@ -153,12 +152,6 @@ export const DefaultFrostConsumes = Consumes.create({
food: Food.FoodFishFeast,
});

export const DefaultArcaneRotation = MageRotation.create({
only3ArcaneBlastStacksBelowManaPercent: 0.15,
blastWithoutMissileBarrageAboveManaPercent: 0.2,
missileBarrageBelowManaPercent: 0,
});

export const DefaultArcaneOptions = MageOptions.create({
armor: ArmorType.MoltenArmor,
focusMagicPercentUptime: 99,
Expand All @@ -178,14 +171,13 @@ export const OtherDefaults = {
profession2: Profession.Tailoring,
};

export const ARCANE_ROTATION_PRESET_SIMPLE = {
name: 'Simple Arcane',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 0,
export const ROTATION_PRESET_SIMPLE = {
name: 'Simple Default',
rotation: SavedRotation.create({
rotation: {
type: APLRotation_Type.TypeSimple,
simple: {
specRotationJson: MageRotation.toJsonString(DefaultArcaneRotation),
specRotationJson: MageRotation.toJsonString(DefaultSimpleRotation),
},
},
}),
Expand All @@ -195,29 +187,16 @@ export const ARCANE_ROTATION_PRESET_DEFAULT = {
name: 'Arcane',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 0,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultArcaneRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(ArcaneApl))
}),
}

export const FIRE_ROTATION_PRESET_SIMPLE = {
name: 'Simple Fire',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 1,
rotation: SavedRotation.create({
rotation: {
type: APLRotation_Type.TypeSimple,
simple: {
specRotationJson: MageRotation.toJsonString(DefaultFireRotation),
},
},
}),
}

export const FIRE_ROTATION_PRESET_DEFAULT = {
name: 'Fire',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 1,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFireRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(FireApl)),
}),
}
Expand All @@ -226,29 +205,16 @@ export const FROSTFIRE_ROTATION_PRESET_DEFAULT = {
name: 'Frostfire',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 1,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFFBRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(FrostFireApl)),
}),
}

export const FROST_ROTATION_PRESET_SIMPLE = {
name: 'Simple Frost',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 2,
rotation: SavedRotation.create({
rotation: {
type: APLRotation_Type.TypeSimple,
simple: {
specRotationJson: MageRotation.toJsonString(DefaultFrostRotation),
},
},
}),
}

export const FROST_ROTATION_PRESET_DEFAULT = {
name: 'Frost',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 2,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFrostRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(FrostApl)),
}),
}
Expand All @@ -257,7 +223,7 @@ export const ARCANE_ROTATION_PRESET_AOE = {
name: 'Arcane AOE',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 0,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFrostRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(ArcaneAoeApl)),
}),
}
Expand All @@ -266,7 +232,7 @@ export const FIRE_ROTATION_PRESET_AOE = {
name: 'Fire AOE',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 1,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFrostRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(FireAoeApl)),
}),
}
Expand All @@ -275,7 +241,7 @@ export const FROST_ROTATION_PRESET_AOE = {
name: 'Frost AOE',
enableWhen: (player: Player<Spec.SpecMage>) => player.getTalentTree() == 2,
rotation: SavedRotation.create({
specRotationOptionsJson: MageRotation.toJsonString(DefaultFrostRotation),
specRotationOptionsJson: MageRotation.toJsonString(MageRotation.create()),
rotation: APLRotation.fromJsonString(JSON.stringify(FrostAoeApl)),
}),
}
Expand Down
6 changes: 2 additions & 4 deletions ui/mage/sim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export class MageSimUI extends IndividualSimUI<Spec.SpecMage> {
// Default consumes settings.
consumes: Presets.DefaultFireConsumes,
// Default rotation settings.
rotation: Presets.DefaultFireRotation,
rotation: Presets.DefaultSimpleRotation,
// Default talents.
talents: Presets.Phase3FireTalents.data,
// Default spec-specific settings.
Expand Down Expand Up @@ -145,9 +145,7 @@ export class MageSimUI extends IndividualSimUI<Spec.SpecMage> {
presets: {
// Preset rotations that the user can quickly select.
rotations: [
Presets.ARCANE_ROTATION_PRESET_SIMPLE,
Presets.FIRE_ROTATION_PRESET_SIMPLE,
Presets.FROST_ROTATION_PRESET_SIMPLE,
Presets.ROTATION_PRESET_SIMPLE,
Presets.ARCANE_ROTATION_PRESET_DEFAULT,
Presets.FIRE_ROTATION_PRESET_DEFAULT,
Presets.FROSTFIRE_ROTATION_PRESET_DEFAULT,
Expand Down
6 changes: 3 additions & 3 deletions ui/raid/presets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ export const playerPresets: Array<PresetSpecSettings<any>> = [
},
{
spec: Spec.SpecMage,
rotation: MagePresets.DefaultArcaneRotation,
rotation: MagePresets.DefaultSimpleRotation,
talents: MagePresets.ArcaneTalents.data,
specOptions: MagePresets.DefaultArcaneOptions,
consumes: MagePresets.DefaultArcaneConsumes,
Expand Down Expand Up @@ -446,7 +446,7 @@ export const playerPresets: Array<PresetSpecSettings<any>> = [
},
{
spec: Spec.SpecMage,
rotation: MagePresets.DefaultFireRotation,
rotation: MagePresets.DefaultSimpleRotation,
talents: MagePresets.FireTalents.data,
specOptions: MagePresets.DefaultFireOptions,
consumes: MagePresets.DefaultFireConsumes,
Expand Down Expand Up @@ -475,7 +475,7 @@ export const playerPresets: Array<PresetSpecSettings<any>> = [
},
{
spec: Spec.SpecMage,
rotation: MagePresets.DefaultFFBRotation,
rotation: MagePresets.DefaultSimpleRotation,
talents: MagePresets.FrostfireTalents.data,
specOptions: MagePresets.DefaultFFBOptions,
consumes: MagePresets.DefaultFireConsumes,
Expand Down

0 comments on commit 32cbb37

Please sign in to comment.