forked from awgil/ffxiv_bossmod
-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1a5277c
commit 9aa809c
Showing
18 changed files
with
407 additions
and
164 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 11 additions & 11 deletions
22
BossMod/Modules/Dawntrail/Extreme/Ex1Valigarmanda/ThunderPlatform.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
BossMod/Modules/Dawntrail/Trial/T01Valigarmanda/ArcaneLightning.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
namespace BossMod.Dawntrail.Trial.T01Valigarmanda; | ||
|
||
class ArcaneLightning(BossModule module) : Components.GenericAOEs(module) | ||
{ | ||
private static readonly AOEShapeRect rect = new(50, 2.5f); | ||
public readonly List<AOEInstance> AOEs = []; | ||
|
||
public override IEnumerable<AOEInstance> ActiveAOEs(int slot, Actor actor) => AOEs; | ||
|
||
public override void OnActorCreated(Actor actor) | ||
{ | ||
if ((OID)actor.OID == OID.ArcaneSphere1) | ||
AOEs.Add(new(rect, actor.Position, actor.Rotation, WorldState.FutureTime(8.6f))); | ||
} | ||
|
||
public override void OnCastFinished(Actor caster, ActorCastInfo spell) | ||
{ | ||
if ((AID)spell.Action.ID == AID.ArcaneLightning) | ||
AOEs.Clear(); | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
BossMod/Modules/Dawntrail/Trial/T01Valigarmanda/ChillingCataclysm.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
namespace BossMod.Dawntrail.Trial.T01Valigarmanda; | ||
|
||
class ChillingCataclysm(BossModule module) : Components.GenericAOEs(module) | ||
{ | ||
public readonly List<AOEInstance> AOEs = []; | ||
|
||
private static readonly AOEShapeCross _shape = new(40, 2.5f); | ||
|
||
public override IEnumerable<AOEInstance> ActiveAOEs(int slot, Actor actor) => AOEs; | ||
|
||
public override void OnActorCreated(Actor actor) | ||
{ | ||
if ((OID)actor.OID == OID.ArcaneSphere2) | ||
{ | ||
AOEs.Add(new(_shape, actor.Position, -0.003f.Degrees(), WorldState.FutureTime(7.1f))); | ||
AOEs.Add(new(_shape, actor.Position, 44.998f.Degrees(), WorldState.FutureTime(7.1f))); | ||
} | ||
} | ||
|
||
public override void OnCastFinished(Actor caster, ActorCastInfo spell) | ||
{ | ||
if ((AID)spell.Action.ID == AID.ChillingCataclysm) | ||
AOEs.Clear(); | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
BossMod/Modules/Dawntrail/Trial/T01Valigarmanda/NorthernCross.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
namespace BossMod.Dawntrail.Trial.T01Valigarmanda; | ||
|
||
class NorthernCross(BossModule module) : Components.GenericAOEs(module) | ||
{ | ||
public AOEInstance? _aoe; | ||
private static readonly AOEShapeRect _shape = new(25, 30); | ||
|
||
public override IEnumerable<AOEInstance> ActiveAOEs(int slot, Actor actor) => Utils.ZeroOrOne(_aoe); | ||
|
||
public override void OnEventEnvControl(byte index, uint state) | ||
{ | ||
if (index != 0x02) | ||
return; | ||
var offset = state switch | ||
{ | ||
0x00200010 => -90.Degrees(), | ||
0x00020001 => 90.Degrees(), | ||
_ => default | ||
}; | ||
if (offset != default) | ||
_aoe = new(_shape, Arena.Center, -126.875f.Degrees() + offset, WorldState.FutureTime(9.2f)); | ||
} | ||
|
||
public override void OnEventCast(Actor caster, ActorCastEvent spell) | ||
{ | ||
if ((AID)spell.Action.ID is AID.NorthernCross1 or AID.NorthernCross2) | ||
_aoe = null; | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
BossMod/Modules/Dawntrail/Trial/T01Valigarmanda/Ruinfall.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
namespace BossMod.Dawntrail.Trial.T01Valigarmanda; | ||
|
||
class RuinfallAOE(BossModule module) : Components.SelfTargetedAOEs(module, ActionID.MakeSpell(AID.RuinfallAOE), new AOEShapeCircle(6)); | ||
|
||
class RuinfallKB(BossModule module) : Components.KnockbackFromCastTarget(module, ActionID.MakeSpell(AID.RuinfallKB), 21, stopAfterWall: true, kind: Kind.DirForward) | ||
{ | ||
public override void AddAIHints(int slot, Actor actor, PartyRolesConfig.Assignment assignment, AIHints hints) | ||
{ | ||
var source = Sources(slot, actor).FirstOrDefault(); | ||
if (source != default && actor.Role != Role.Tank) | ||
{ | ||
hints.AddForbiddenZone(ShapeDistance.InvertedRect(Module.PrimaryActor.Position, new Angle(), 1, 0, 20), source.Activation); | ||
} | ||
} | ||
} | ||
|
||
class RuinfallTower(BossModule module) : Components.CastTowers(module, ActionID.MakeSpell(AID.RuinfallTower), 6, 2, 2) | ||
{ | ||
public override void Update() | ||
{ | ||
if (Towers.Count == 0) | ||
return; | ||
var forbidden = Raid.WithSlot().WhereActor(p => p.Role != Role.Tank).Mask(); | ||
foreach (ref var t in Towers.AsSpan()) | ||
t.ForbiddenSoakers = forbidden; | ||
} | ||
|
||
public override void AddAIHints(int slot, Actor actor, PartyRolesConfig.Assignment assignment, AIHints hints) | ||
{ | ||
base.AddAIHints(slot, actor, assignment, hints); | ||
if (Towers.Count > 0 && Towers.Any(x => x.IsInside(actor) && (Towers.FirstOrDefault().Activation - WorldState.CurrentTime).TotalSeconds < 5)) | ||
hints.ActionsToExecute.Push(ActionID.MakeSpell(ClassShared.AID.ArmsLength), actor, ActionQueue.Priority.High); | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
BossMod/Modules/Dawntrail/Trial/T01Valigarmanda/StranglingCoilSlitheringStrike.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
namespace BossMod.Dawntrail.Trial.T01Valigarmanda; | ||
|
||
class StranglingCoilSusurrantBreath(BossModule module) : Components.GenericAOEs(module) | ||
{ | ||
private static readonly AOEShapeDonut donut = new(8, 30); | ||
private static readonly AOEShapeCone cone = new(50, 40.Degrees()); | ||
private readonly ArcaneLightning aoe = module.FindComponent<ArcaneLightning>()!; | ||
private AOEInstance? _aoe; | ||
|
||
public override IEnumerable<AOEInstance> ActiveAOEs(int slot, Actor actor) => aoe.AOEs.Count == 0 ? Utils.ZeroOrOne(_aoe) : ([]); | ||
|
||
public override void OnCastStarted(Actor caster, ActorCastInfo spell) | ||
{ | ||
if ((AID)spell.Action.ID == AID.StranglingCoil) | ||
_aoe = new(donut, Arena.Center, default, Module.CastFinishAt(spell)); | ||
else if ((AID)spell.Action.ID == AID.SusurrantBreath) | ||
_aoe = new(cone, new(100, 75), default, Module.CastFinishAt(spell)); | ||
} | ||
|
||
public override void OnCastFinished(Actor caster, ActorCastInfo spell) | ||
{ | ||
if ((AID)spell.Action.ID is AID.StranglingCoil or AID.SusurrantBreath) | ||
_aoe = null; | ||
} | ||
} |
Oops, something went wrong.