Some jumping, open DF for duties
authorLiza Carvelli <liza@carvel.li>
Sat, 1 Jun 2024 12:30:20 +0000 (14:30 +0200)
committerLiza Carvelli <liza@carvel.li>
Sat, 1 Jun 2024 12:30:20 +0000 (14:30 +0200)
45 files changed:
Questionable/Controller/MovementController.cs
Questionable/Controller/QuestController.cs
Questionable/GameFunctions.cs
Questionable/Model/V1/Converter/InteractionTypeConverter.cs
Questionable/Model/V1/EInteractionType.cs
Questionable/Model/V1/JumpDestination.cs [new file with mode: 0644]
Questionable/Model/V1/QuestStep.cs
Questionable/QuestPaths/Endwalker/MSQ/A-Thavnair1-Labyrinthos1/4377_In the Dark of the Tower.json
Questionable/QuestPaths/Endwalker/MSQ/B-Garlemald/4395_Gateway of the Gods.json
Questionable/QuestPaths/Endwalker/MSQ/B-Garlemald/4398_The Martyr.json
Questionable/QuestPaths/Endwalker/MSQ/D-Thavnair2/4409_Skies Aflame.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4425_Their Greatest Contribution.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4426_Aether to Aether.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4427_A Sentimental Gift.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4429_Travelers at the Crossroads.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4430_A Past Not Yet Come to Pass.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4432_Worthy of His Back.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4433_A Flower upon Your Return.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4436_Follow Wander Stumble Listen.json
Questionable/QuestPaths/Endwalker/MSQ/E-Elpis/4437_Caging the Messenger.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4440_Outside Help.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4442_No Job Too Small.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4445_Sage Council.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4446_Hither and Yarns.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4447_Once Forged.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4448_Bonds of Adamantite.json
Questionable/QuestPaths/Endwalker/MSQ/F-Labyrinthos2/4449_Her Children One and All.json
Questionable/QuestPaths/Endwalker/MSQ/G-UltimaThule/4464_Endwalker.json
Questionable/QuestPaths/Endwalker/MSQ/H-6.1/4529_Alzadaals Legacy.json
Questionable/QuestPaths/Endwalker/MSQ/I-6.2/4592_In Search of Azdaja.json
Questionable/QuestPaths/Endwalker/MSQ/I-6.2/4597_The Wind Rises.json
Questionable/QuestPaths/Endwalker/MSQ/J-6.3/4674_King of the Mountain.json
Questionable/QuestPaths/Endwalker/MSQ/J-6.3/4677_Desires Untold.json
Questionable/QuestPaths/Endwalker/MSQ/K-6.4/4736_Going Haam.json
Questionable/QuestPaths/Endwalker/MSQ/K-6.4/4742_Abyssal Dark.json
Questionable/QuestPaths/Endwalker/MSQ/L-6.5/4748_Down in the Dark.json
Questionable/QuestPaths/Shadowbringers/MSQ/F-Tempest/3654_Shadowbringers.json
Questionable/QuestPaths/Shadowbringers/MSQ/G-5.1/3674_A Grand Adventure.json
Questionable/QuestPaths/Shadowbringers/MSQ/H-5.2/3769_Beneath the Surface.json
Questionable/QuestPaths/Shadowbringers/MSQ/I-5.3/3777_The Converging Light.json
Questionable/QuestPaths/Shadowbringers/MSQ/I-5.3/3778_Hope's Confluence.json
Questionable/QuestPaths/Shadowbringers/MSQ/J-5.4/4011_Like Master, Like Pupil.json
Questionable/QuestPaths/Shadowbringers/MSQ/K-5.5/4062_The Flames of War.json
Questionable/QuestSchema/schema_v1.json
Questionable/QuestionablePlugin.cs

index 492b643b549eecb0ffad75f4a6eaf64ceb3baa06..3d88a3f548fd39e2e14cdfc7f8766c786fb31f24 100644 (file)
@@ -75,7 +75,6 @@ internal sealed class MovementController : IDisposable
                         start = end;
                     }
 
-                    _pluginLog.Information($"Distance: {actualDistance}");
                     unsafe
                     {
                         // 70 is ~10 seconds of sprint
@@ -119,8 +118,9 @@ internal sealed class MovementController : IDisposable
                     {
                         if (AetheryteConverter.IsLargeAetheryte((EAetheryteLocation)Destination.DataId))
                         {
-                            // TODO verify this
-                            if (Math.Abs(localPlayerPosition.Y - gameObject.Position.Y) < 2.95f)
+                            // TODO verify the first part of this, is there any aetheryte like that?
+                            if (localPlayerPosition.Y - gameObject.Position.Y < 2.95f &&
+                                localPlayerPosition.Y - gameObject.Position.Y > -0.9f)
                                 Stop();
                         }
                         else
index f1f804800cd56a5972c17e33c9ba664649a203b0..ac87704d670cb56367feaa41a96909e775339aca 100644 (file)
@@ -27,6 +27,7 @@ internal sealed class QuestController
     private readonly IPluginLog _pluginLog;
     private readonly ICondition _condition;
     private readonly IChatGui _chatGui;
+    private readonly IFramework _framework;
     private readonly AetheryteData _aetheryteData;
     private readonly LifestreamIpc _lifestreamIpc;
     private readonly TerritoryData _territoryData;
@@ -34,7 +35,7 @@ internal sealed class QuestController
 
     public QuestController(DalamudPluginInterface pluginInterface, IDataManager dataManager, IClientState clientState,
         GameFunctions gameFunctions, MovementController movementController, IPluginLog pluginLog, ICondition condition,
-        IChatGui chatGui, AetheryteData aetheryteData, LifestreamIpc lifestreamIpc)
+        IChatGui chatGui, IFramework framework, AetheryteData aetheryteData, LifestreamIpc lifestreamIpc)
     {
         _pluginInterface = pluginInterface;
         _dataManager = dataManager;
@@ -44,6 +45,7 @@ internal sealed class QuestController
         _pluginLog = pluginLog;
         _condition = condition;
         _chatGui = chatGui;
+        _framework = framework;
         _aetheryteData = aetheryteData;
         _lifestreamIpc = lifestreamIpc;
         _territoryData = new TerritoryData(dataManager);
@@ -358,7 +360,13 @@ internal sealed class QuestController
 
         if (step.TargetTerritoryId == _clientState.TerritoryType)
         {
-            _pluginLog.Information("Skipping any movement");
+            _pluginLog.Information("Zone transition, skipping movement");
+        }
+        else if (step.InteractionType == EInteractionType.Jump && step.JumpDestination != null &&
+                 (_clientState.LocalPlayer!.Position - step.JumpDestination.Position).Length() <=
+                 (step.JumpDestination.StopDistance ?? 1f))
+        {
+            _pluginLog.Information("We're at the jump destination, skipping movement");
         }
         else if (step.Position != null)
         {
@@ -582,7 +590,9 @@ internal sealed class QuestController
                 break;
 
             case EInteractionType.Duty:
-                // TODO open duty finder
+                if (step.ContentFinderConditionId != null)
+                    _gameFunctions.OpenDutyFinder(step.ContentFinderConditionId.Value);
+
                 break;
 
             case EInteractionType.SinglePlayerDuty:
@@ -591,9 +601,24 @@ internal sealed class QuestController
                 break;
 
             case EInteractionType.Jump:
-                // TODO implement somehow??
+                if (step.JumpDestination != null && !_condition[ConditionFlag.Jumping])
+                {
+                    float stopDistance = step.JumpDestination.StopDistance ?? 1f;
+                    if ((_clientState.LocalPlayer!.Position - step.JumpDestination.Position).Length() <= stopDistance)
+                        IncreaseStepCount();
+                    else
+                    {
+                        _movementController.NavigateTo(EMovementType.Quest, step.DataId,
+                            [step.JumpDestination.Position],
+                            false, step.JumpDestination.StopDistance ?? stopDistance);
+                        _framework.RunOnTick(() => ActionManager.Instance()->UseAction(ActionType.GeneralAction, 2),
+                            TimeSpan.FromSeconds(step.JumpDestination.DelaySeconds ?? 0.5f));
+                    }
+                }
+
                 break;
 
+            case EInteractionType.ShouldBeAJump:
             case EInteractionType.Instruction:
                 // Need to manually forward
                 break;
index 58c2d87dbf431eeee5540c336cc20a986e2bac7e..8255a7924651b5d7a2fd0c7a37ec68d51cb82dfc 100644 (file)
@@ -42,6 +42,7 @@ internal sealed unsafe class GameFunctions
     private readonly delegate* unmanaged<Utf8String*, int, IntPtr, void> _sanitiseString;
     private readonly ReadOnlyDictionary<ushort, byte> _territoryToAetherCurrentCompFlgSet;
     private readonly ReadOnlyDictionary<EEmote, string> _emoteCommands;
+    private readonly ReadOnlyDictionary<uint, ushort> _contentFinderConditionToContentId;
 
     private readonly IObjectTable _objectTable;
     private readonly ITargetManager _targetManager;
@@ -74,6 +75,10 @@ internal sealed unsafe class GameFunctions
             .Where(x => x.Command != null && x.Command.StartsWith('/'))
             .ToDictionary(x => (EEmote)x.RowId, x => x.Command!)
             .AsReadOnly();
+        _contentFinderConditionToContentId = dataManager.GetExcelSheet<ContentFinderCondition>()
+            .Where(x => x.RowId > 0 && x.Content > 0)
+            .ToDictionary(x => x.RowId, x => x.Content)
+            .AsReadOnly();
     }
 
     // FIXME
@@ -364,7 +369,7 @@ internal sealed unsafe class GameFunctions
         if (gameObject != null)
         {
             var position = (FFXIVClientStructs.FFXIV.Common.Math.Vector3)gameObject.Position;
-            ActionManager.Instance()->UseActionLocation(ActionType.KeyItem, itemId, gameObject.ObjectId, &position);
+            ActionManager.Instance()->UseActionLocation(ActionType.KeyItem, itemId, location: &position);
         }
     }
 
@@ -417,4 +422,17 @@ internal sealed unsafe class GameFunctions
 
         return false;
     }
+
+    public void OpenDutyFinder(uint contentFinderConditionId)
+    {
+        if (_contentFinderConditionToContentId.TryGetValue(contentFinderConditionId, out ushort contentId))
+        {
+            if (UIState.IsInstanceContentUnlocked(contentId))
+                AgentContentsFinder.Instance()->OpenRegularDuty(contentFinderConditionId);
+            else
+                _pluginLog.Error($"Trying to access a locked duty (cf: {contentFinderConditionId}, content: {contentId})");
+        }
+        else
+            _pluginLog.Error($"Could not find content for content finder condition (cf: {contentFinderConditionId})");
+    }
 }
index c5aa932c9105d766318b96da9cf886cee390da54..fcd2228b2b9298e3f7e48e233fcf583eab64adb0 100644 (file)
@@ -19,7 +19,8 @@ public sealed class InteractionTypeConverter() : EnumConverter<EInteractionType>
         { EInteractionType.WaitForManualProgress, "WaitForManualProgress" },
         { EInteractionType.Duty, "Duty" },
         { EInteractionType.SinglePlayerDuty, "SinglePlayerDuty" },
-        { EInteractionType.Jump, "ShouldBeAJump" },
+        { EInteractionType.Jump, "Jump" },
+        { EInteractionType.ShouldBeAJump, "ShouldBeAJump" },
         { EInteractionType.Instruction, "Instruction" },
     };
 }
index 9ee2a4557631fd60e9001a6fe86064ec2b4ed656..f0ca8a32584711474eb550f5631852ac6e92b8ef 100644 (file)
@@ -19,9 +19,13 @@ public enum EInteractionType
     WaitForManualProgress,
     Duty,
     SinglePlayerDuty,
-
     Jump,
 
+    /// <summary>
+    /// Needs to be adjusted for coords etc. in the quest data.
+    /// </summary>
+    ShouldBeAJump,
+
     /// <summary>
     /// Needs to be manually continued.
     /// </summary>
diff --git a/Questionable/Model/V1/JumpDestination.cs b/Questionable/Model/V1/JumpDestination.cs
new file mode 100644 (file)
index 0000000..e6a709e
--- /dev/null
@@ -0,0 +1,14 @@
+using System.Numerics;
+using System.Text.Json.Serialization;
+using Questionable.Model.V1.Converter;
+
+namespace Questionable.Model.V1;
+
+public sealed class JumpDestination
+{
+    [JsonConverter(typeof(VectorConverter))]
+    public Vector3 Position { get; set; }
+
+    public float? StopDistance { get; set; }
+    public float? DelaySeconds { get; set; }
+}
index 58a84226eb81564e2be31cae852bc29dc445bd40..1ab58e52faab68d056fd90d8d1f1350a4abca96f 100644 (file)
@@ -38,6 +38,8 @@ public class QuestStep
     public EEnemySpawnType? EnemySpawnType { get; set; }
 
     public IList<uint> KillEnemyDataIds { get; set; } = new List<uint>();
+    public JumpDestination? JumpDestination { get; set; }
+    public uint? ContentFinderConditionId { get; set; }
 
     public IList<ESkipCondition> SkipIf { get; set; } = new List<ESkipCondition>();
 }
index 234cbad90fb53dbd6a5c17c198c8214d9c488718..2750142d5252d1fb3d6cb460d56b77a3a3db55aa 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2011959,
-          "Position": {
-            "X": -636.4081,
-            "Y": -0.015319824,
-            "Z": -663.81323
-          },
           "TerritoryId": 957,
           "InteractionType": "Duty",
-          "Comment": "The Tower of Zot"
+          "ContentFinderConditionId": 783
         }
       ]
     },
index 0307961d49f9a823fa68f26808f389e4036c10b3..1562483500cb968e096cc0ec9680766c2cac6d50 100644 (file)
       "Sequence": 4,
       "Steps": [
         {
-          "DataId": 2012113,
-          "Position": {
-            "X": -525.8717,
-            "Y": -190.02063,
-            "Z": -676.875
-          },
           "TerritoryId": 958,
           "InteractionType": "Duty",
-          "Comment": "The Tower of Babil"
+          "ContentFinderConditionId": 785
         }
       ]
     },
index 09aca30a56fc436384c723b1a854e6837b224ad7..2c87907830ea9e688b8da66f8df9c60b82932a28 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2012122,
-          "Position": {
-            "X": 99.96179,
-            "Y": -0.015319824,
-            "Z": 103.227295
-          },
           "TerritoryId": 1028,
           "InteractionType": "Duty",
+          "ContentFinderConditionId": 802,
           "Comment": "The Dark Inside"
         }
       ]
index e903c04a1fdf0b80a0e25f5a7bcebe0723c16d3f..9156095435457c4bc2b48b6f1672ea8e8c3a5e7f 100644 (file)
       "Sequence": 4,
       "Steps": [
         {
-          "DataId": 2012228,
-          "Position": {
-            "X": 205.82886,
-            "Y": 1.7547607,
-            "Z": 761.50134
-          },
           "TerritoryId": 957,
           "InteractionType": "Duty",
-          "Comment": "Vanaspati"
+          "ContentFinderConditionId": 789
         }
       ]
     },
index 40923502cf81a0590327191f54e94b0b85e29309..2f4167231dc89cb8e874b5c0a336427a1cdf22a2 100644 (file)
         },
         {
           "Position": {
-            "X": 346.73517,
-            "Y": -15.572778,
-            "Z": -105.96149
+            "X": 475.2184,
+            "Y": -17.473314,
+            "Z": 47.986946
           },
           "TerritoryId": 961,
-          "InteractionType": "WalkTo",
-          "Comment": "Needs manual jumping"
+          "InteractionType": "Jump",
+          "JumpDestination": {
+            "Position": {
+              "X": 477.34882,
+              "Y": -16.407324,
+              "Z": 43.802086
+            },
+            "DelaySeconds": 0.25
+          }
         },
         {
           "DataId": 1040052,
@@ -78,6 +85,7 @@
             "Y": -14.757837,
             "Z": -115.15985
           },
+          "StopDistance": 7,
           "TerritoryId": 961,
           "InteractionType": "Interact"
         }
           "StopDistance": 0.5,
           "TerritoryId": 961,
           "InteractionType": "WalkTo",
+          "Mount": true,
           "DisableNavmesh": true
         },
         {
       "Sequence": 6,
       "Steps": [
         {
+          "Position": {
+            "X": -55.662647,
+            "Y": -16.696985,
+            "Z": -81.29199
+          },
+          "StopDistance": 0.25,
+          "TerritoryId": 961,
+          "InteractionType": "Jump",
+          "JumpDestination": {
+            "Position": {
+              "X": -58.75509,
+              "Y": -15.402463,
+              "Z": -83.133934
+            }
+          },
+          "DisableNavmesh": true
+        },
+        {
+          "Position": {
+            "X": -64.19198,
+            "Y": -15.332472,
+            "Z": -84.65695
+          },
+          "StopDistance": 0.25,
           "TerritoryId": 961,
           "InteractionType": "Emote",
-          "Emote": "wave",
-          "Comment": "Need to jump manually"
+          "Emote": "wave"
         }
       ]
     },
index d265bac388efa61df1008663f6feac473f8aca08..5352451d551f6ffaa2ac2b1c4902ae7fdb13b998 100644 (file)
             "Y": -26.995626,
             "Z": 543.8281
           },
+          "StopDistance": 0.5,
           "TerritoryId": 961,
-          "InteractionType": "WalkTo"
-        },
-        {
-          "Position": {
-            "X": -137.80992,
-            "Y": -26.995626,
-            "Z": 543.8281
-          },
-          "TerritoryId": 961,
-          "InteractionType": "ShouldBeAJump",
-          "Comment": "Jump on Ledge"
+          "InteractionType": "Jump",
+          "JumpDestination": {
+            "Position": {
+              "X": -144.54877,
+              "Y": -26.230347,
+              "Z": 551.5067
+            }
+          }
         },
         {
           "DataId": 2012023,
@@ -59,6 +57,7 @@
           },
           "TerritoryId": 961,
           "InteractionType": "WalkTo",
+          "Mount": true,
           "DisableNavmesh": true
         },
         {
index 796271742dba4c2079fd4f4ef60e9f7d8ae8ea08..610cb853e24be70f34f220315169115b0a0f8da7 100644 (file)
@@ -45,7 +45,8 @@
             "Z": 546.50183
           },
           "TerritoryId": 961,
-          "InteractionType": "Interact"
+          "InteractionType": "Interact",
+          "$.1": "QuestVariables if done first: 1 0 0 0 0 128"
         },
         {
           "DataId": 2012136,
             "Z": 432.59787
           },
           "TerritoryId": 961,
-          "InteractionType": "WalkTo"
+          "InteractionType": "WalkTo",
+          "Mount": true
         },
         {
           "DataId": 2012021,
index afb984dbe3f7403b1b0412d4ba99d1bc85b4ee4d..52d650dfdc12a973b7d94506c46f8872f81235a2 100644 (file)
@@ -29,7 +29,8 @@
             "Z": 236.07227
           },
           "TerritoryId": 961,
-          "InteractionType": "Interact"
+          "InteractionType": "Interact",
+          "AetheryteShortcut": "Elpis - Anagnorisis"
         }
       ]
     },
     {
       "Sequence": 4,
       "Steps": [
+        {
+          "DataId": 2012029,
+          "Position": {
+            "X": -255.54291,
+            "Y": 143.05322,
+            "Z": -36.972656
+          },
+          "TerritoryId": 961,
+          "InteractionType": "AttuneAetherCurrent",
+          "AetherCurrentId": 2818383
+        },
         {
           "DataId": 2012146,
           "Position": {
index 456d071673008735376dd825bd19babf78e0fe10..cd21f0d6216cdfe6522a58bfd315a45a2422e919 100644 (file)
             "Z": -197.54811
           },
           "TerritoryId": 961,
-          "InteractionType": "WalkTo"
+          "InteractionType": "WalkTo",
+          "Mount": true
         },
         {
           "DataId": 1040117,
index e248c409d60179fb707dff506edbfaf887c203f0..eed67db3de9db5c4ca82a410847cb9ded05283bb 100644 (file)
     {
       "Sequence": 1,
       "Steps": [
-        {
-          "DataId": 2012029,
-          "Position": {
-            "X": -255.54291,
-            "Y": 143.05322,
-            "Z": -36.972656
-          },
-          "TerritoryId": 961,
-          "InteractionType": "AttuneAetherCurrent",
-          "AetherCurrentId": 2818383
-        },
         {
           "Position": {
             "X": -297.88638,
index b170af586e6b4dd1770fe608a0283564fe921d33..efbe4c0be1815325cf4b9fec422672aadca47400 100644 (file)
@@ -96,7 +96,7 @@
             "Y": 294.93375,
             "Z": -559.62463
           },
-          "StopDistance": 5,
+          "StopDistance": 6,
           "TerritoryId": 961,
           "InteractionType": "Interact"
         }
index d5d0a8ba9a4db0ad94966cb15ab84d6f462c7354..e23cd4693dcf3aa1e6c2ac9bc965becdd677d99d 100644 (file)
@@ -44,6 +44,7 @@
           },
           "TerritoryId": 961,
           "InteractionType": "WalkTo",
+          "Mount": true,
           "DisableNavmesh": true
         },
         {
index cf34ff892e9b70df243453f3d57b2b379a71bcf0..05cb70065737d0174b5814b787e5bad00a582b01 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2012172,
-          "Position": {
-            "X": -412.49713,
-            "Y": 329.9458,
-            "Z": -765.80457
-          },
-          "StopDistance": 4,
           "TerritoryId": 961,
           "InteractionType": "Duty",
-          "Comment": "Ktisis Hyperborea"
+          "ContentFinderConditionId": 787
         }
       ]
     },
index 1f68f6276b45381336509b6795f1b14852e97899..85a5a8c38a7439733db5d7c1a0fe6170762408bc 100644 (file)
@@ -45,8 +45,9 @@
           },
           "TerritoryId": 962,
           "InteractionType": "Interact",
+          "AetheryteShortcut": "Old Sharlayan",
           "AethernetShortcut": [
-            "[Old Sharlayan] Scholar's Harbor",
+            "[Old Sharlayan] Aetheryte Plaza",
             "[Old Sharlayan] The Baldesion Annex"
           ]
         }
index 2de34634ccff792f4a50497ecf9077deb2640b2f..a0b68026fa3d5a8b3a1d05e62dc016dd2468771d 100644 (file)
@@ -28,8 +28,7 @@
             "Z": 457.04776
           },
           "TerritoryId": 956,
-          "InteractionType": "WalkTo",
-          "Comment": "TODO verify this is correct, there was an aether current prior to this"
+          "InteractionType": "WalkTo"
         },
         {
           "DataId": 2011989,
index 0ebd791c4acb3de803eb871e6e4c8344b35cb0ec..df8d99a99c2de17ee1a31b3799e6f7d3eb9ff6b5 100644 (file)
             "Y": -28.723352,
             "Z": -42.992764
           },
+          "StopDistance": 0.75,
           "TerritoryId": 956,
           "InteractionType": "WalkTo",
-          "AetheryteShortcut": "Labyrinthos - Sharlayan Hamlet"
+          "AetheryteShortcut": "Labyrinthos - Sharlayan Hamlet",
+          "Mount": true
         },
         {
           "DataId": 1039687,
@@ -70,6 +72,7 @@
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Distracted Researcher",
+          "$.0": "[1]",
           "$.1": "QuestVariables if done first: 1 0 0 0 2 0"
         },
         {
@@ -82,6 +85,7 @@
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Hyperventilating Engineer",
+          "$.0": "[2]",
           "$.1": "QuestVariables if done after [1]: 2 0 0 0 130 0"
         },
         {
@@ -94,6 +98,7 @@
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Harried Aetherologist",
+          "$.0": "[3]",
           "$.1": "QuestVariables if done after [2]: 3 0 0 0 138 0"
         },
         {
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Grimacing Naturalist",
+          "$.0": "[4]",
           "$.1": "QuestVariables if done after [3]: 4 0 0 0 142 0"
         },
         {
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Ponderous Mathematician",
+          "$.0": "[5]",
           "$.1": "QuestVariables if done after [4]: 5 0 0 0 206 0"
         },
         {
           "InteractionType": "Interact",
           "Comment": "Despondent Engineer",
           "Mount": true,
+          "$.0": "[6]",
           "$.1": "QuestVariables if done after [5]: 6 0 0 0 238 0"
         },
         {
           "TerritoryId": 956,
           "InteractionType": "Interact",
           "Comment": "Skeptical Researcher",
+          "Mount": true,
+          "$.0": "[7]",
           "$.1": "QuestVariables if done after [6]: 7 0 0 0 239 0"
         },
         {
           },
           "TerritoryId": 956,
           "InteractionType": "Interact",
-          "Comment": "Anxious Engineer"
+          "Comment": "Anxious Engineer",
+          "$.0": "[8]",
+          "$.2": "QuestVariables if done first: 1 0 0 0 16 0"
         }
       ]
     },
index 618c5c3e40b9f8eb1c54bb338710c7f3940ed94f..8c59e5d1b853edcf41dc0876c6eaa8e65d6b84bf 100644 (file)
@@ -40,6 +40,7 @@
           },
           "TerritoryId": 956,
           "InteractionType": "WalkTo",
+          "Mount": true,
           "DisableNavmesh": true
         },
         {
index 55f6c7b8778ff2b1dd2f4efe1b897d04318f5b3c..90dcf6acb699ba39ab7e1a12fa4619ecdbf517e2 100644 (file)
         },
         {
           "Position": {
-            "X": -118.62926,
-            "Y": -22.071072,
-            "Z": 681.35846
+            "X": -120.48093,
+            "Y": -21.96263,
+            "Z": 685.2332
           },
           "TerritoryId": 956,
-          "InteractionType": "ShouldBeAJump",
+          "InteractionType": "Jump",
           "DisableNavmesh": true,
-          "Comment": "Navmesh can't jump"
+          "JumpDestination": {
+            "Position": {
+              "X": -124.55376,
+              "Y": -19.659834,
+              "Z": 686.864
+            },
+            "StopDistance": 0.5,
+            "DelaySeconds": 0.25
+          }
         },
         {
           "DataId": 2011986,
           },
           "TerritoryId": 956,
           "InteractionType": "AttuneAetherCurrent",
-          "AetherCurrentId": 2818317
+          "AetherCurrentId": 2818317,
+          "DisableNavmesh": true
         },
         {
           "Position": {
           },
           "TerritoryId": 956,
           "InteractionType": "WalkTo",
+          "Mount": true,
           "DisableNavmesh": true
         },
         {
index ae59c625383b95f3da4fb200b0f023d105a2182c..c319c430c564877660fcadea763bbc1721c7935f 100644 (file)
@@ -28,7 +28,8 @@
           },
           "AetheryteShortcut": "Labyrinthos - Sharlayan Hamlet",
           "TerritoryId": 956,
-          "InteractionType": "WalkTo"
+          "InteractionType": "WalkTo",
+          "Mount": true
         },
         {
           "DataId": 2012226,
@@ -98,6 +99,7 @@
             "Y": -191.11913,
             "Z": 301.71655
           },
+          "StopDistance": 7,
           "TerritoryId": 956,
           "InteractionType": "Interact"
         }
             "Z": 301.63266
           },
           "TerritoryId": 956,
-          "InteractionType": "Interact"
+          "InteractionType": "Interact",
+          "Comment": "TODO Should cancel navmesh if condition is [OccupiedInCutsceneEvent OR BetweenAreas]; then verify next marker distance"
         }
       ]
     },
index 169601d43512e5522e29015ced2bc930bfaca3e9..9598331dc2c4b3b8004a27f8f7769bc20ea6138a 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2012742,
-          "Position": {
-            "X": -238.26965,
-            "Y": -221.51526,
-            "Z": 341.29846
-          },
           "TerritoryId": 956,
           "InteractionType": "Duty",
-          "Comment": "Aitiascope"
+          "ContentFinderConditionId": 786
         }
       ]
     },
       "Sequence": 4,
       "Steps": [
         {
-          "DataId": 2012230,
-          "Position": {
-            "X": 99.95956,
-            "Y": -2.384186E-07,
-            "Z": 99.85896
-          },
           "TerritoryId": 1030,
-          "InteractionType": "Interact"
+          "InteractionType": "Duty",
+          "ContentFinderConditionId": 790
         }
       ]
     },
index acf28e3ab5d0dad4795f42fe129167ea7c8023d4..02a9dae404c7f9b4b181d76218a3be50a9767ce1 100644 (file)
       "Sequence": 1,
       "Steps": [
         {
-          "DataId": 2012370,
-          "Position": {
-            "X": -3.1281738,
-            "Y": 637.07935,
-            "Z": -9.079163
-          },
           "TerritoryId": 960,
           "InteractionType": "Duty",
-          "Comment": "The Dead Ends"
+          "ContentFinderConditionId": 792
         }
       ]
     },
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2012371,
-          "Position": {
-            "X": 100,
-            "Y": 0,
-            "Z": 106
-          },
-          "StopDistance": 5,
           "TerritoryId": 1029,
           "InteractionType": "Duty",
-          "Comment": "The Final Day"
+          "ContentFinderConditionId": 796
         }
       ]
     },
index 953db32dcc36995290ffc2e9fd31665c5f89daf6..b83f9e85f4ca92a8c463c75c36b5db7a65d3e6cd 100644 (file)
       "Sequence": 1,
       "Steps": [
         {
-          "DataId": 2012839,
-          "Position": {
-            "X": -269.55066,
-            "Y": 0.10675049,
-            "Z": 610.65076
-          },
           "TerritoryId": 957,
           "InteractionType": "Duty",
-          "Comment": "Alzadaal's Legacy"
+          "ContentFinderConditionId": 844
         }
       ]
     },
index 7fa88e01f08329b62d355a5545e7ecd0bdff3e4e..f2d2e9c8239622766ad020e6e9e8ca1ec1c601c6 100644 (file)
       "Sequence": 4,
       "Steps": [
         {
-          "DataId": 2013041,
-          "Position": {
-            "X": 110.06323,
-            "Y": -350.02673,
-            "Z": -89.463684
-          },
           "TerritoryId": 1056,
           "InteractionType": "Duty",
-          "Comment": "Fell Court of Troia"
+          "ContentFinderConditionId": 869
         }
       ]
     },
index 8079e7eb833b222997bcb8fa94469bad0caf3670..31d40549a08b83df0ffcd979e3dc2b5e641bce89 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2013052,
-          "Position": {
-            "X": 99.77076,
-            "Y": -19,
-            "Z": 176.985
-          },
-          "StopDistance": 5,
           "TerritoryId": 1092,
           "InteractionType": "Duty",
-          "Comment": "Storm's Crown"
+          "ContentFinderConditionId": 870
         }
       ]
     },
index 827a244529e722d6765038bd64091a39e3ca5931..dede7fd146877117f02baa8abff75d1822947502 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2013225,
-          "Position": {
-            "X": 469.16907,
-            "Y": -18.204102,
-            "Z": 717.7081
-          },
           "TerritoryId": 958,
-          "StopDistance": 5,
           "InteractionType": "Duty",
-          "Comment": "Lapis Manalis"
+          "Comment": "Lapis Manalis",
+          "ContentFinderConditionId": 896
         }
       ]
     },
index f05b314c07a456922f5e2089dc58fe49287828c7..054454e8e8dfdef0b2048f1858986baefb29106e 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2013240,
-          "Position": {
-            "X": 657.3739,
-            "Y": -180.7837,
-            "Z": 45.63965
-          },
           "TerritoryId": 1125,
           "InteractionType": "Duty",
-          "Comment": "Mount Ordeals"
+          "ContentFinderConditionId": 886
         }
       ]
     },
index 8b14d592e0ef1fa53f15b21285f9e1f33bc9060b..5d447b3e96d48f1f77a94af88c04ae2a1ce7e399 100644 (file)
       "Sequence": 7,
       "Steps": [
         {
-          "DataId": 2013359,
-          "Position": {
-            "X": 134.667,
-            "Y": -16.147,
-            "Z": 238.0937
-          },
           "TerritoryId": 962,
           "InteractionType": "Duty",
-          "Comment": "The Aetherfont"
+          "ContentFinderConditionId": 822
         }
       ]
     },
index 1ec272a4c0dffbf26cc8e9248fc336fba625100a..756b43428824f2acd08a9c408ba4b24c087a8f81 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2013364,
-          "Position": {
-            "X": 99.99231,
-            "Y": 0.015197754,
-            "Z": 101.823364
-          },
           "TerritoryId": 1159,
           "InteractionType": "Duty",
-          "Comment": "The Voidcast Dais"
+          "ContentFinderConditionId": 949
         }
       ]
     },
index 6a6e37e2990011e793a739e640850f682453d09e..998db8667be192065ba1c7234442fda36aca919a 100644 (file)
       "Sequence": 1,
       "Steps": [
         {
-          "DataId": 2013410,
-          "Position": {
-            "X": 24.338135,
-            "Y": 56.65674,
-            "Z": 439.96326
-          },
           "TerritoryId": 1162,
           "InteractionType": "Duty",
-          "Comment": "The Lunar Subterrane"
+          "ContentFinderConditionId": 823
         }
       ]
     },
       "Sequence": 5,
       "Steps": [
         {
-          "DataId": 2013411,
-          "Position": {
-            "X": 100.0275,
-            "Y": 0,
-            "Z": 106.3549
-          },
           "TerritoryId": 1181,
           "InteractionType": "Duty",
-          "Comment": "The Abyssal Fracture"
+          "ContentFinderConditionId": 964
         }
       ]
     },
index aff07c45737fb8d9fe185b7da60d45a749e1f8f1..b99724314dceec6cd99257dcf73d1af4c451f8b3 100644 (file)
@@ -7,16 +7,9 @@
       "Sequence": 7,
       "Steps": [
         {
-          "DataId": 2010235,
-          "Position": {
-            "X": -426.9627,
-            "Y": -229.08374,
-            "Z": 858.09106
-          },
-          "StopDistance": 5,
           "TerritoryId": 818,
           "InteractionType": "Duty",
-          "Comment": "Amaurot"
+          "ContentFinderConditionId": 652
         }
       ]
     },
       "Sequence": 9,
       "Steps": [
         {
-          "DataId": 2010236,
-          "Position": {
-            "X": 100.0382,
-            "Y": 4.768372E-07,
-            "Z": 106.0076
-          },
-          "StopDistance": 5,
           "TerritoryId": 881,
           "InteractionType": "Duty",
-          "Comment": "The Dying Gasp"
+          "ContentFinderConditionId": 687
         }
       ]
     },
index ec57c56e6f110ed66907aec1501c81d8827bf08a..1da111e1c31fe96fdc934dfb4a7f9e19e8bd5267 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2010808,
-          "Position": {
-            "X": -123.55237,
-            "Y": -0.7172241,
-            "Z": 647.6997
-          },
           "TerritoryId": 813,
           "InteractionType": "Duty",
-          "Comment": "Grand Cosmos"
+          "ContentFinderConditionId": 692
         }
       ]
     },
index 4965aee3c051576a9366b5617f9d37355e23f8e3..555ec6a0419d486d67e045a971957390fb69fca2 100644 (file)
       "Sequence": 2,
       "Steps": [
         {
-          "DataId": 2010952,
-          "Position": {
-            "X": -539.0652,
-            "Y": 63.97181,
-            "Z": 738.8608
-          },
-          "StopDistance": 5,
           "TerritoryId": 814,
           "InteractionType": "Duty",
-          "Comment": "Anamnesis Anyder"
+          "ContentFinderConditionId": 714
         }
       ]
     }
index 566d98b3fd82f40a62bb33b5adda6e791893b024..7d1d4e19fe1e265d3ed09272f36a27df0ca3890f 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2011101,
-          "Position": {
-            "X": 60.04639,
-            "Y": 82.82986,
-            "Z": 1.940211
-          },
           "TerritoryId": 820,
           "InteractionType": "Duty",
-          "Comment": "The Heroes' Gauntlet"
+          "ContentFinderConditionId": 737
         }
       ]
     },
index 67efa3eb85bcc27e18081b389ac145f4825cc05a..0c53c5ee9b5bf11c20c43d42252ce7632ef22b7b 100644 (file)
       "Sequence": 1,
       "Steps": [
         {
-          "DataId": 2011103,
-          "Position": {
-            "X": 100,
-            "Y": 4.208088E-05,
-            "Z": 112.5434
-          },
-          "StopDistance": 5,
           "TerritoryId": 931,
           "InteractionType": "Duty",
-          "Comment": "The Seat of Sacrifice"
+          "ContentFinderConditionId": 738
         }
       ]
     },
index 192c55041eca87764ea2aad994a1a1d7f3bdc2c9..a2effa72e4318b54ef66957d167fb1a1352d0bfc 100644 (file)
       "Sequence": 4,
       "Steps": [
         {
-          "DataId": 2011334,
-          "Position": {
-            "X": 384.32886,
-            "Y": 75.48633,
-            "Z": -218.00574
-          },
           "TerritoryId": 399,
           "InteractionType": "Duty",
-          "Comment": "Matoya's Relict"
+          "ContentFinderConditionId": 746
         }
       ]
     },
index 5d8ceac14ce727693e4091c2735b7752cc2ac7cb..5c03ea946c85f97cdb0fb4d72208d665492749ce 100644 (file)
       "Sequence": 3,
       "Steps": [
         {
-          "DataId": 2011521,
-          "Position": {
-            "X": -24.368713,
-            "Y": 83.17688,
-            "Z": 12.893799
-          },
           "TerritoryId": 130,
           "InteractionType": "Duty",
-          "Comment": "Paglth'an"
+          "ContentFinderConditionId": 777
         }
       ]
     },
index 27d30856c91fd26842dc251622c99caef71b20e2..c63791afa0ed7fbc26e897239357ebf7dc8bb1a7 100644 (file)
                     "WaitForManualProgress",
                     "Duty",
                     "SinglePlayerDuty",
+                    "Jump",
                     "ShouldBeAJump",
                     "Instruction"
                   ]
                   "description": "The Item to use",
                   "exclusiveMinimum": 0
                 },
+                "JumpDestination": {
+                  "type": "object",
+                  "properties": {
+                    "Position": {
+                      "type": "object",
+                      "description": "Position to try reaching after the jump",
+                      "properties": {
+                        "X": {
+                          "type": "number"
+                        },
+                        "Y": {
+                          "type": "number"
+                        },
+                        "Z": {
+                          "type": "number"
+                        }
+                      },
+                      "required": [
+                        "X",
+                        "Y",
+                        "Z"
+                      ]
+                    },
+                    "StopDistance": {
+                      "type": [
+                        "number",
+                        "null"
+                      ],
+                      "description": "Set if pathfinding should stop closer or further away from the default stop distance",
+                      "exclusiveMinimum": 0
+                    },
+                    "DelaySeconds": {
+                      "type": [
+                        "number",
+                        "null"
+                      ]
+                    }
+                  },
+                  "required": [
+                    "Position"
+                  ]
+                },
+                "ContentFinderConditionId": {
+                  "type": "number",
+                  "exclusiveMinimum": 0
+                },
                 "SkipIf": {
                   "type": "array",
                   "description": "TODO Not implemented",
index 0d19dfe905f83dab0439c96d9a16c97ceab86201..ccb22e365332e71b28d4f59463fb552cff2c8f47 100644 (file)
@@ -53,7 +53,7 @@ public sealed class QuestionablePlugin : IDalamudPlugin
         _movementController =
             new MovementController(navmeshIpc, clientState, _gameFunctions, condition, pluginLog);
         _questController = new QuestController(pluginInterface, dataManager, _clientState, _gameFunctions,
-            _movementController, pluginLog, condition, chatGui, aetheryteData, lifestreamIpc);
+            _movementController, pluginLog, condition, chatGui, framework, aetheryteData, lifestreamIpc);
         _windowSystem.AddWindow(new DebugWindow(_movementController, _questController, _gameFunctions, clientState,
             targetManager));