Naadam
authorLiza Carvelli <liza@carvel.li>
Wed, 12 Mar 2025 19:13:04 +0000 (20:13 +0100)
committerLiza Carvelli <liza@carvel.li>
Wed, 12 Mar 2025 19:13:04 +0000 (20:13 +0100)
QuestPaths/4.x - Stormblood/MSQ/A3.2-Yanxia 1/2498_The Time between the Seconds.json
QuestPaths/4.x - Stormblood/MSQ/A4-Azim Steppe/2509_The Labors of Magnai.json
QuestPaths/4.x - Stormblood/MSQ/A4-Azim Steppe/2515_Naadam.json
QuestPaths/4.x - Stormblood/MSQ/A5-Yanxia 2/2523_On the Eve of Destiny.json
Questionable/Controller/QuestController.cs
Questionable/Controller/Steps/Interactions/SinglePlayerDuty.cs
Questionable/Functions/GameFunctions.cs

index 95052575e512914de0e5121d6970d1d71f07561c..c240b4c3e8a10074429587a076c071a553c24a0c 100644 (file)
           },
           "StopDistance": 7,
           "TerritoryId": 614,
-          "InteractionType": "SinglePlayerDuty"
+          "InteractionType": "SinglePlayerDuty",
+          "SinglePlayerDutyOptions": {
+            "Enabled": true,
+            "TestedBossModVersion": "0.1.0.1"
+          }
         }
       ]
     },
index 7c762d512e78fe3e1a1c623c589d194fd7d7d823..2f56c5ffefe836335e0e3a985543beceb92ab7fa 100644 (file)
             "Z": 23.111439
           },
           "TerritoryId": 622,
-          "InteractionType": "Dive",
+          "InteractionType": "WalkTo",
           "DisableNavmesh": true
         },
+        {
+          "Position": {
+            "X": 65.04901,
+            "Y": 1.9869974,
+            "Z": 23.111439
+          },
+          "TerritoryId": 622,
+          "InteractionType": "Dive",
+          "DelaySecondsAtStart": 2
+        },
         {
           "DataId": 2008252,
           "Position": {
index a37bb51789642affff0b9195fa16a88a91f6de03..8fdeef6cdf57025ae30162c3689e171cb875b457 100644 (file)
@@ -55,7 +55,6 @@
               "Answer": "TEXT_STMBDA416_02515_A1_000_103"
             }
           ],
-          "$": "QW: 0 0    0 0    0 0 -> QW: 17 0    0 0    0 32",
           "CompletionQuestVariablesFlags": [
             null,
             null,
@@ -81,7 +80,6 @@
               "Answer": "TEXT_STMBDA416_02515_A1_120_070"
             }
           ],
-          "$": "QW: 17 0    0 0    0 32 -> QW: 33 0    16 0    0 96",
           "CompletionQuestVariablesFlags": [
             null,
             null,
           },
           "TerritoryId": 622,
           "InteractionType": "Interact",
-          "$": "QW: 33 0    16 0    0 96 -> QW: 49 16    16 0    0 112",
           "CompletionQuestVariablesFlags": [
             null,
             null,
             "Z": -508.20172
           },
           "TerritoryId": 622,
-          "InteractionType": "SinglePlayerDuty"
+          "InteractionType": "SinglePlayerDuty",
+          "SinglePlayerDutyOptions": {
+            "Enabled": true,
+            "TestedBossModVersion": "0.1.0.1"
+          }
         }
       ]
     },
index 5350174a8d9c8533752c3bb854f1484605f9d1c3..71d619bd73b8c5005f207627c72b7a32c867fd37 100644 (file)
     {
       "Sequence": 255,
       "Steps": [
+        {
+          "Position": {
+            "X": 175.34885,
+            "Y": 5.16971,
+            "Z": -419.04416
+          },
+          "TerritoryId": 614,
+          "InteractionType": "WalkTo",
+          "Fly": true
+        },
         {
           "DataId": 1020519,
           "Position": {
           },
           "TerritoryId": 614,
           "InteractionType": "CompleteQuest",
-          "Fly": true,
           "DialogueChoices": [
             {
               "Type": "List",
index 404a83349aa122524815d45e840d1f7d12a3113c..0df9e8d9109617b39be8e62712028c10705498a8 100644 (file)
@@ -209,7 +209,7 @@ internal sealed class QuestController : MiniTaskController<QuestController>
         {
             if (_condition[ConditionFlag.Unconscious] &&
                 _condition[ConditionFlag.SufferingStatusAffliction63] &&
-                _clientState.TerritoryType == SinglePlayerDuty.LahabreaTerritoryId)
+                _clientState.TerritoryType == SinglePlayerDuty.SpecialTerritories.Lahabrea)
             {
                 // ignore, we're in the lahabrea fight
             }
index 264d812824ddf7573c1a60f2c64c16883e77e0d4..c356c2872ce212ec6b310c500b00bf28864549f2 100644 (file)
@@ -1,6 +1,7 @@
 using System;
 using System.Collections.Generic;
 using System.Linq;
+using System.Numerics;
 using Dalamud.Game.ClientState.Conditions;
 using Dalamud.Game.ClientState.Objects;
 using Dalamud.Game.ClientState.Objects.Types;
@@ -19,10 +20,11 @@ namespace Questionable.Controller.Steps.Interactions;
 
 internal static class SinglePlayerDuty
 {
-    private static class SpecialTerritories
+    internal static class SpecialTerritories
     {
         public const ushort Lahabrea = 1052;
         public const ushort ItsProbablyATrap = 665;
+        public const ushort Naadam = 688;
     }
 
     internal sealed class Factory(
@@ -43,7 +45,7 @@ internal static class SinglePlayerDuty
                     throw new TaskException("Failed to get content finder condition for solo instance");
 
                 yield return new StartSinglePlayerDuty(cfcData.ContentFinderConditionId);
-                yield return new EnableAi();
+                yield return new EnableAi(cfcData.TerritoryId == SpecialTerritories.Naadam);
                 if (cfcData.TerritoryId == SpecialTerritories.Lahabrea)
                 {
                     yield return new SetTarget(14643);
@@ -56,12 +58,27 @@ internal static class SinglePlayerDuty
                         "Wait(resurrection)");
                     yield return new EnableAi();
                 }
-                else if (cfcData.TerritoryId == SpecialTerritories.ItsProbablyATrap)
+                else if (cfcData.TerritoryId is SpecialTerritories.ItsProbablyATrap)
                 {
                     yield return new WaitCondition.Task(() => DutyActionsAvailable() || clientState.TerritoryType != SpecialTerritories.ItsProbablyATrap,
                         "Wait(Phase 2)");
                     yield return new EnableAi(true);
                 }
+                else if (cfcData.TerritoryId is SpecialTerritories.Naadam)
+                {
+                    yield return new WaitCondition.Task(
+                        () =>
+                        {
+                            if (clientState.TerritoryType != SpecialTerritories.Naadam)
+                                return true;
+
+                            var pos = clientState.LocalPlayer?.Position ?? default;
+                            return (new Vector3(352.01f, -1.45f, 288.59f) - pos).Length() < 10f;
+                        },
+                        "Wait(moving to Ovoo)");
+                    yield return new Mount.UnmountTask();
+                    yield return new EnableAi();
+                }
 
                 yield return new WaitSinglePlayerDuty(cfcData.ContentFinderConditionId);
                 yield return new DisableAi();
index 658913733da62bd6f36d79cb6631508fe9d226f7..1516b57dae9ec30c3d7c76b851b30381efa58e99 100644 (file)
@@ -438,7 +438,7 @@ internal sealed unsafe class GameFunctions
 
         if (_condition[ConditionFlag.Unconscious] &&
             _condition[ConditionFlag.SufferingStatusAffliction63] &&
-            _clientState.TerritoryType == SinglePlayerDuty.LahabreaTerritoryId)
+            _clientState.TerritoryType == SinglePlayerDuty.SpecialTerritories.Lahabrea)
             return false; // needed to process the tasks
 
         return _condition[ConditionFlag.Occupied] || _condition[ConditionFlag.Occupied30] ||