From a596dc746e98275296538753aa8e7a5e48451c7d Mon Sep 17 00:00:00 2001 From: Andrew Gilewsky Date: Sat, 24 Feb 2024 23:02:47 +0000 Subject: [PATCH] Dhog's fucking condition 70. --- vnavmesh/Movement/OverrideMovement.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vnavmesh/Movement/OverrideMovement.cs b/vnavmesh/Movement/OverrideMovement.cs index e505fbf..f537e68 100644 --- a/vnavmesh/Movement/OverrideMovement.cs +++ b/vnavmesh/Movement/OverrideMovement.cs @@ -68,7 +68,8 @@ private void RMIWalkDetour(void* self, float* sumLeft, float* sumForward, float* { _rmiWalkHook.Original(self, sumLeft, sumForward, sumTurnLeft, haveBackwardOrStrafe, a6, bAdditiveUnk); // TODO: we really need to introduce some extra checks that PlayerMoveController::readInput does - sometimes it skips reading input, and returning something non-zero breaks stuff... - if (bAdditiveUnk == 0 && (IgnoreUserInput || *sumLeft == 0 && *sumForward == 0) && DirectionToDestination(false) is var relDir && relDir != null) + bool movementAllowed = bAdditiveUnk == 0 && !Service.Condition[Dalamud.Game.ClientState.Conditions.ConditionFlag.BeingMoved]; + if (movementAllowed && (IgnoreUserInput || *sumLeft == 0 && *sumForward == 0) && DirectionToDestination(false) is var relDir && relDir != null) { var dir = relDir.Value.h.ToDirection(); *sumLeft = dir.X;