51 lines
1,020 B
C#
51 lines
1,020 B
C#
using Dalamud.Game.ClientState.Objects.Types;
|
|
using Questionable.Functions;
|
|
using Questionable.Model.Questing;
|
|
|
|
namespace Questionable.Controller.CombatModules;
|
|
|
|
internal sealed class Mount147Module : ICombatModule
|
|
{
|
|
public const ushort MountId = 147;
|
|
|
|
private readonly EAction[] _actions = new EAction[1] { EAction.Trample };
|
|
|
|
private readonly GameFunctions _gameFunctions;
|
|
|
|
public Mount147Module(GameFunctions gameFunctions)
|
|
{
|
|
_gameFunctions = gameFunctions;
|
|
}
|
|
|
|
public bool CanHandleFight(CombatController.CombatData combatData)
|
|
{
|
|
return _gameFunctions.GetMountId() == 147;
|
|
}
|
|
|
|
public bool Start(CombatController.CombatData combatData)
|
|
{
|
|
return true;
|
|
}
|
|
|
|
public bool Stop()
|
|
{
|
|
return true;
|
|
}
|
|
|
|
public void Update(IGameObject gameObject)
|
|
{
|
|
EAction[] actions = _actions;
|
|
foreach (EAction action in actions)
|
|
{
|
|
if (_gameFunctions.UseAction(gameObject, action, checkCanUse: false))
|
|
{
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
public bool CanAttack(IBattleNpc target)
|
|
{
|
|
return target.BaseId == 8593;
|
|
}
|
|
}
|