protected override uint Invoke(uint actionID, uint lastComboMove, float comboTime, byte level) { if (actionID == (IsEnabled(CustomComboPreset.MonkDragonKickComboSnakeOption) ? MNK.TwinSnakes : MNK.DragonKick)) { var gauge = new MyMNKGauge(GetJobGauge <MNKGauge>()); if (CurrentTarget is null && CanUseAction(MNK.Anatman) && IsEnabled(CustomComboPreset.MonkDragonKickAnatmanFeature)) { return(MNK.Anatman); } if (IsEnabled(CustomComboPreset.MonkDragonClapFeature) && (!InMeleeRange() || CurrentTarget?.ObjectKind == Dalamud.Game.ClientState.Objects.Enums.ObjectKind.Player) && CanUseAction(MNK.Thunderclap)) { return(MNK.Thunderclap); } if ((HasEffect(MNK.Buffs.PerfectBalance) || HasEffect(MNK.Buffs.FormlessFist)) && IsEnabled(CustomComboPreset.MonkDragonKickComboSnakeOption)) { return(MNK.TwinSnakes); } if (IsEnabled(CustomComboPreset.MonkDragonKickBalanceFeature)) { if (!gauge.BeastChakra.Contains(BeastChakra.NONE) && CanUseAction(OriginalHook(MNK.MasterfulBlitz))) { return(OriginalHook(MNK.MasterfulBlitz)); } } if (IsEnabled(CustomComboPreset.MonkDragonKickCombo)) { if (HasEffect(MNK.Buffs.OpoOpoForm) || HasEffect(MNK.Buffs.FormlessFist) || HasEffect(MNK.Buffs.PerfectBalance)) { if (IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature)) { if (HasEffect(MNK.Buffs.LeadenFist)) { return(MNK.Bootshine); } } return(MNK.DragonKick); } if (HasEffect(MNK.Buffs.RaptorForm)) { return(MNK.TwinSnakes); } if (HasEffect(MNK.Buffs.CoeurlForm)) { return(MNK.Demolish); } return(MNK.DragonKick); } } return(actionID); }
protected override uint Invoke(uint actionID, uint lastComboMove, float comboTime, byte level) { if (actionID == (IsEnabled(CustomComboPreset.MonkAoEComboFormOption) ? MNK.FormShift : MNK.FourPointFury)) { Status?pb = FindEffect(MNK.Buffs.PerfectBalance); var gauge = new MyMNKGauge(GetJobGauge <MNKGauge>()); if (HasEffect(MNK.Buffs.PerfectBalance)) { switch (pb?.StackCount) { case 3: return(MNK.FourPointFury); case 2: if (!gauge.BeastChakra.Contains(BeastChakra.RAPTOR)) { return(MNK.FourPointFury); } return(MNK.Rockbreaker); case 1: if (gauge.BeastChakra.Contains(BeastChakra.OPOOPO) && !gauge.BeastChakra.Contains(BeastChakra.RAPTOR)) { return(MNK.FourPointFury); } if (!gauge.BeastChakra.Contains(BeastChakra.COEURL)) { return(MNK.Rockbreaker); } return(OriginalHook(MNK.ArmOfTheDestroyer)); } } if (HasEffect(MNK.Buffs.FormlessFist)) { return(MNK.FourPointFury); } } if (actionID == (IsEnabled(CustomComboPreset.MonkAoEComboBlitzOption) ? PLD.TotalEclipse : MNK.MasterfulBlitz)) { if (IsEnabled(CustomComboPreset.MonkAoEMeditationFeature) && OriginalHook(MNK.Meditation) != MNK.Meditation && CanUseAction(OriginalHook(MNK.HowlingFist)) && CurrentTarget is not null && HasCondition(ConditionFlag.InCombat) && GetCooldown(MNK.Bootshine).CooldownRemaining >= 0.5) { return(OriginalHook(MNK.HowlingFist)); } if (OriginalHook(MNK.MasterfulBlitz) != MNK.MasterfulBlitz && CanUseAction(OriginalHook(MNK.MasterfulBlitz)) && !IsEnabled(CustomComboPreset.MonkAoEComboBlitzOption)) { return(OriginalHook(MNK.MasterfulBlitz)); } if (HasEffect(MNK.Buffs.PerfectBalance) || HasEffect(MNK.Buffs.FormlessFist)) { if (level >= MNK.Levels.ShadowOfTheDestroyer) { return(OriginalHook(MNK.ArmOfTheDestroyer)); } return(MNK.Rockbreaker); } if (HasEffect(MNK.Buffs.OpoOpoForm)) { return(OriginalHook(MNK.ArmOfTheDestroyer)); } if (HasEffect(MNK.Buffs.RaptorForm) && CanUseAction(MNK.FourPointFury)) { return(MNK.FourPointFury); } if (HasEffect(MNK.Buffs.CoeurlForm) && CanUseAction(MNK.Rockbreaker)) { return(MNK.Rockbreaker); } return(OriginalHook(MNK.ArmOfTheDestroyer)); } return(actionID); }
protected override uint Invoke(uint actionID, uint lastComboMove, float comboTime, byte level) { if (OriginalHook(MNK.MasterfulBlitz) != MNK.MasterfulBlitz && CanUseAction(OriginalHook(MNK.MasterfulBlitz)) && actionID == MNK.PerfectBalance && IsEnabled(CustomComboPreset.MonkPerfectBalanceFeature) && !HasEffect(MNK.Buffs.FormlessFist)) { return(OriginalHook(MNK.MasterfulBlitz)); } if (IsEnabled(CustomComboPreset.MonkDragonClapFeature) && actionID == MNK.TrueStrike && (!InMeleeRange() || CurrentTarget?.ObjectKind == Dalamud.Game.ClientState.Objects.Enums.ObjectKind.Player) && CanUseAction(MNK.Thunderclap)) { return(MNK.Thunderclap); } if (CurrentTarget is null && CanUseAction(MNK.Anatman) && actionID == MNK.TrueStrike && IsEnabled(CustomComboPreset.MonkDragonKickAnatmanFeature)) { return(MNK.Anatman); } if (!HasEffect(MNK.Buffs.PerfectBalance) && !HasEffect(MNK.Buffs.FormlessFist) && (actionID == MNK.TrueStrike || (actionID == MNK.TwinSnakes && !IsEnabled(CustomComboPreset.MonkSTComboTwinSnakeOption)))) { if (HasEffect(MNK.Buffs.OpoOpoForm)) { if (IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature)) { return(HasEffect(MNK.Buffs.LeadenFist) || level < MNK.Levels.DragonKick ? MNK.Bootshine : MNK.DragonKick); } return(actionID == MNK.TrueStrike ? MNK.Bootshine : MNK.DragonKick); } if (HasEffect(MNK.Buffs.RaptorForm)) { if (level < MNK.Levels.TrueStrike) { return(MNK.Bootshine); } return(actionID == MNK.TrueStrike ? MNK.TrueStrike : MNK.TwinSnakes); } if (HasEffect(MNK.Buffs.CoeurlForm)) { if (level < MNK.Levels.SnapPunch) { return(MNK.Bootshine); } return(actionID == MNK.TrueStrike ? MNK.SnapPunch : MNK.Demolish); } if (IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature)) { return(level >= MNK.Levels.DragonKick ? MNK.DragonKick : MNK.Bootshine); } return(actionID == MNK.TrueStrike ? MNK.Bootshine : MNK.DragonKick); } if (HasEffect(MNK.Buffs.PerfectBalance) && actionID != MNK.FormShift) { Status?pb = FindEffect(MNK.Buffs.PerfectBalance); if (actionID == MNK.TwinSnakes && IsEnabled(CustomComboPreset.MonkSTComboTwinSnakeOption)) { return(actionID); } var gauge = new MyMNKGauge(GetJobGauge <MNKGauge>()); if (actionID == MNK.PerfectBalance || (actionID == MNK.TrueStrike && IsEnabled(CustomComboPreset.MonkSTComboDragonKickOption))) { return(HasEffect(MNK.Buffs.LeadenFist) && IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature) ? MNK.Bootshine : MNK.DragonKick); } if (level < MNK.Levels.MasterfulBlitz) { return(actionID == MNK.TrueStrike ? MNK.Demolish : MNK.TwinSnakes); } switch (pb?.StackCount) { case 3: return(actionID == MNK.TrueStrike ? MNK.Demolish : MNK.TwinSnakes); case 2: if (gauge.BeastChakra.Contains(BeastChakra.RAPTOR)) { return(actionID == MNK.TrueStrike ? MNK.SnapPunch : MNK.Demolish); } if (IsEnabled(CustomComboPreset.MonkSTComboDoubleSolarOption) && gauge.BeastChakra.Contains(BeastChakra.OPOOPO)) { return(actionID == MNK.TrueStrike ? MNK.SnapPunch : MNK.Demolish); } return(actionID == MNK.TrueStrike ? MNK.TrueStrike : MNK.TwinSnakes); case 1: if (!gauge.BeastChakra.Contains(BeastChakra.RAPTOR)) { return(actionID == MNK.TrueStrike ? MNK.TrueStrike : MNK.TwinSnakes); } if (gauge.BeastChakra.Contains(BeastChakra.RAPTOR) && gauge.BeastChakra.Contains(BeastChakra.COEURL) && IsEnabled(CustomComboPreset.MonkSTComboOpoOpoOption)) { return(HasEffect(MNK.Buffs.LeadenFist) && IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature) ? MNK.Bootshine : MNK.DragonKick); } return(actionID == MNK.TrueStrike ? MNK.SnapPunch : MNK.Demolish); } } if (HasEffect(MNK.Buffs.PerfectBalance) && actionID == MNK.FormShift && !IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature)) { return(MNK.Bootshine); } if (HasEffect(MNK.Buffs.FormlessFist)) { switch (actionID) { case MNK.TrueStrike: return(HasEffect(MNK.Buffs.LeadenFist) && IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature) ? MNK.Bootshine : MNK.DragonKick); case MNK.PerfectBalance: return((CurrentTarget is not null && !GCDClipCheck()) || !IsEnabled(CustomComboPreset.MonkSTComboDemolishOption) ? MNK.Demolish : actionID); case MNK.FormShift: if (!IsEnabled(CustomComboPreset.MonkAoEComboFormOption)) { if (!IsEnabled(CustomComboPreset.MonkDragonKickBootshineFeature)) { return(MNK.Bootshine); } if (!IsEnabled(CustomComboPreset.MonkSTComboFormOption)) { return(MNK.SnapPunch); } } break; } } return(actionID); }