muffin v7.38.8
This commit is contained in:
parent
5e2d8f648b
commit
3e10cbbbf2
51 changed files with 2585 additions and 1972 deletions
|
|
@ -3,6 +3,7 @@ using System.Collections.Generic;
|
|||
using System.Numerics;
|
||||
using System.Runtime.InteropServices;
|
||||
using Dalamud.Game.ClientState.Conditions;
|
||||
using Dalamud.Game.ClientState.Objects.Types;
|
||||
using Dalamud.Game.Text.SeStringHandling;
|
||||
using Dalamud.Plugin.Services;
|
||||
using LLib;
|
||||
|
|
@ -28,6 +29,8 @@ internal sealed class MoveExecutor : TaskExecutor<MoveTask>, IToastAware, ITaskE
|
|||
|
||||
private readonly IClientState _clientState;
|
||||
|
||||
private readonly IObjectTable _objectTable;
|
||||
|
||||
private readonly ICondition _condition;
|
||||
|
||||
private readonly Questionable.Controller.Steps.Common.Mount.MountEvaluator _mountEvaluator;
|
||||
|
|
@ -46,12 +49,13 @@ internal sealed class MoveExecutor : TaskExecutor<MoveTask>, IToastAware, ITaskE
|
|||
|
||||
private (Questionable.Controller.Steps.Common.Mount.MountExecutor Executor, Questionable.Controller.Steps.Common.Mount.MountTask Task)? _mountDuringMovement;
|
||||
|
||||
public MoveExecutor(MovementController movementController, GameFunctions gameFunctions, ILogger<MoveExecutor> logger, IClientState clientState, ICondition condition, IDataManager dataManager, Questionable.Controller.Steps.Common.Mount.MountEvaluator mountEvaluator, IServiceProvider serviceProvider)
|
||||
public MoveExecutor(MovementController movementController, GameFunctions gameFunctions, ILogger<MoveExecutor> logger, IClientState clientState, IObjectTable objectTable, ICondition condition, IDataManager dataManager, Questionable.Controller.Steps.Common.Mount.MountEvaluator mountEvaluator, IServiceProvider serviceProvider)
|
||||
{
|
||||
_movementController = movementController;
|
||||
_gameFunctions = gameFunctions;
|
||||
_logger = logger;
|
||||
_clientState = clientState;
|
||||
_objectTable = objectTable;
|
||||
_condition = condition;
|
||||
_serviceProvider = serviceProvider;
|
||||
_mountEvaluator = mountEvaluator;
|
||||
|
|
@ -95,7 +99,7 @@ internal sealed class MoveExecutor : TaskExecutor<MoveTask>, IToastAware, ITaskE
|
|||
_canRestart = base.Task.RestartNavigation;
|
||||
_destination = base.Task.Destination;
|
||||
float num = base.Task.StopDistance ?? 3f;
|
||||
Vector3? vector = _clientState.LocalPlayer?.Position;
|
||||
Vector3? vector = _objectTable[0]?.Position;
|
||||
float num2 = ((!vector.HasValue) ? float.MaxValue : Vector3.Distance(vector.Value, _destination));
|
||||
if (num2 > num)
|
||||
{
|
||||
|
|
@ -170,7 +174,8 @@ internal sealed class MoveExecutor : TaskExecutor<MoveTask>, IToastAware, ITaskE
|
|||
{
|
||||
return ETaskResult.StillRunning;
|
||||
}
|
||||
if (_canRestart && Vector3.Distance(_clientState.LocalPlayer.Position, _destination) > (base.Task.StopDistance ?? 3f) + 5f)
|
||||
IGameObject gameObject = _objectTable[0];
|
||||
if (_canRestart && gameObject != null && Vector3.Distance(gameObject.Position, _destination) > (base.Task.StopDistance ?? 3f) + 5f)
|
||||
{
|
||||
_canRestart = false;
|
||||
if (_clientState.TerritoryType == base.Task.TerritoryId)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue