master #3

Open
cacahuetes wants to merge 640 commits from liza/Questionable:master into cacahuetes-ShB-Healer
13 changed files with 934 additions and 18 deletions
Showing only changes of commit db43fec431 - Show all commits

2
LLib

@ -1 +1 @@
Subproject commit 538329a1e80acbcd09e28bd6dd459c35b5563c0a
Subproject commit 70b0bef2459898a70f7b34b4d196bbaeb72397b1

View File

@ -0,0 +1,126 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1047679,
"Position": {
"X": -165.36206,
"Y": -14.999356,
"Z": 203.93677
},
"TerritoryId": 1185,
"InteractionType": "AcceptQuest",
"AetheryteShortcut": "Tuliyollal",
"AethernetShortcut": [
"[Tuliyollal] Aetheryte Plaza",
"[Tuliyollal] The For'ard Cabins"
]
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 1046521,
"Position": {
"X": -46.616333,
"Y": -17.97287,
"Z": 180.3158
},
"StopDistance": 5,
"TerritoryId": 1185,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 2,
"Steps": [
{
"DataId": 2014470,
"Position": {
"X": -32.700073,
"Y": -17.47168,
"Z": 184.9851
},
"TerritoryId": 1185,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 1047501,
"Position": {
"X": -189.80707,
"Y": 120.74999,
"Z": -367.14734
},
"TerritoryId": 1185,
"InteractionType": "Interact",
"AethernetShortcut": [
"[Tuliyollal] Bayside Bevy Marketplace",
"[Tuliyollal] Vollok Shoonsa"
],
"DialogueChoices": [
{
"Type": "YesNo",
"Prompt": "TEXT_KINGMG101_05244_SYSTEM_000_301",
"Yes": true
}
]
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1048083,
"Position": {
"X": 302.05237,
"Y": 51.199978,
"Z": 205.0354
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AetheryteShortcut": "Solution Nine",
"AethernetShortcut": [
"[Solution Nine] Aetheryte Plaza",
"[Solution Nine] Neon Stein"
],
"TargetTerritoryId": 1207,
"SkipConditions": {
"AetheryteShortcutIf": {
"InTerritory": [
1207
]
},
"StepIf": {
"InTerritory": [
1207
]
}
}
},
{
"DataId": 1052185,
"Position": {
"X": -4.837158,
"Y": -3.632158E-08,
"Z": 5.996765
},
"TerritoryId": 1207,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,74 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052185,
"Position": {
"X": -4.837158,
"Y": -3.632158E-08,
"Z": 5.996765
},
"TerritoryId": 1207,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 2014102,
"Position": {
"X": -0.015319824,
"Y": 0.99176025,
"Z": 16.03717
},
"TerritoryId": 1207,
"InteractionType": "Interact",
"TargetTerritoryId": 1186,
"SkipConditions": {
"StepIf": {
"InTerritory": [
1186
]
}
}
},
{
"DataId": 1052191,
"Position": {
"X": 20.248657,
"Y": 38.0566,
"Z": -388.90674
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AethernetShortcut": [
"[Solution Nine] Neon Stein",
"[Solution Nine] Resolution"
]
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1052198,
"Position": {
"X": -303.2426,
"Y": 9.519508,
"Z": 51.80432
},
"StopDistance": 5,
"TerritoryId": 1186,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,146 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052202,
"Position": {
"X": -305.83655,
"Y": 9.519508,
"Z": 53.147095
},
"StopDistance": 5,
"TerritoryId": 1186,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 1052205,
"Position": {
"X": -257.0382,
"Y": 30,
"Z": -569.05475
},
"TerritoryId": 1191,
"InteractionType": "Interact",
"AetheryteShortcut": "Heritage Found - The Outskirts"
},
{
"DataId": 1052204,
"Position": {
"X": -158.25134,
"Y": 25.984516,
"Z": -521.90436
},
"TerritoryId": 1191,
"InteractionType": "Interact",
"Fly": true
},
{
"DataId": 1052206,
"Position": {
"X": -137.86536,
"Y": 35,
"Z": -568.29175
},
"TerritoryId": 1191,
"InteractionType": "Interact",
"Fly": true
}
]
},
{
"Sequence": 2,
"Steps": [
{
"DataId": 1048083,
"Position": {
"X": 302.05237,
"Y": 51.199978,
"Z": 205.0354
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AetheryteShortcut": "Solution Nine",
"AethernetShortcut": [
"[Solution Nine] Aetheryte Plaza",
"[Solution Nine] Neon Stein"
],
"TargetTerritoryId": 1207,
"SkipConditions": {
"AetheryteShortcutIf": {
"InTerritory": [
1207
]
},
"StepIf": {
"InTerritory": [
1207
]
}
}
},
{
"DataId": 1048161,
"Position": {
"X": -5.874817,
"Y": -3.6188258E-08,
"Z": 6.8512573
},
"TerritoryId": 1207,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 1052207,
"Position": {
"X": -609.3385,
"Y": -3.3580189,
"Z": -504.5701
},
"TerritoryId": 1191,
"InteractionType": "Interact",
"AetheryteShortcut": "Heritage Found - The Outskirts",
"Fly": true
}
]
},
{
"Sequence": 4,
"Steps": [
{
"TerritoryId": 1191,
"InteractionType": "Duty",
"ContentFinderConditionId": 1008
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1052213,
"Position": {
"X": 117.02136,
"Y": 12.5,
"Z": -67.826416
},
"StopDistance": 6,
"TerritoryId": 1254,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,126 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052217,
"Position": {
"X": 118.242065,
"Y": 12.5,
"Z": -69.0166
},
"StopDistance": 6,
"TerritoryId": 1254,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 2014471,
"Position": {
"X": 39.32251,
"Y": 13.260071,
"Z": 51.865356
},
"TerritoryId": 1254,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 2,
"Steps": [
{
"DataId": 2014472,
"Position": {
"X": 101.8844,
"Y": 12.588623,
"Z": 130.44934
},
"TerritoryId": 1254,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 2014473,
"Position": {
"X": 39.597046,
"Y": 13.260071,
"Z": 53.45227
},
"TerritoryId": 1254,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 4,
"Steps": [
{
"DataId": 1052227,
"Position": {
"X": -581.2009,
"Y": -1.7638817,
"Z": -505.45514
},
"StopDistance": 5,
"TerritoryId": 1191,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1048083,
"Position": {
"X": 302.05237,
"Y": 51.199978,
"Z": 205.0354
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AetheryteShortcut": "Solution Nine",
"AethernetShortcut": [
"[Solution Nine] Aetheryte Plaza",
"[Solution Nine] Neon Stein"
],
"TargetTerritoryId": 1207,
"SkipConditions": {
"AetheryteShortcutIf": {
"InTerritory": [
1207
]
},
"StepIf": {
"InTerritory": [
1207
]
}
}
},
{
"DataId": 1048161,
"Position": {
"X": -5.874817,
"Y": -3.6188258E-08,
"Z": 6.8512573
},
"TerritoryId": 1207,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,202 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052233,
"Position": {
"X": -0.80877686,
"Y": -4.1909516E-08,
"Z": 6.42395
},
"StopDistance": 5,
"TerritoryId": 1207,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"Position": {
"X": -363.22934,
"Y": 20.162338,
"Z": -90.19407
},
"TerritoryId": 1190,
"InteractionType": "WalkTo",
"AetheryteShortcut": "Shaaloani - Sheshenewezi Springs"
},
{
"DataId": 1051495,
"Position": {
"X": -365.28577,
"Y": 20.14268,
"Z": -88.51758
},
"StopDistance": 5,
"TerritoryId": 1190,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 2,
"Steps": [
{
"Position": {
"X": 302.1455,
"Y": -15.629961,
"Z": -516.2348
},
"TerritoryId": 1190,
"InteractionType": "WalkTo",
"AetheryteShortcut": "Shaaloani - Mehwahhetsoan",
"Fly": true
},
{
"DataId": 1046988,
"Position": {
"X": 302.96777,
"Y": -15.629961,
"Z": -514.6716
},
"TerritoryId": 1190,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 1051013,
"Position": {
"X": 303.79175,
"Y": -15.629962,
"Z": -516.25854
},
"TerritoryId": 1190,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 4,
"Steps": [
{
"DataId": 1052247,
"Position": {
"X": 224.96375,
"Y": -16.329428,
"Z": -527.6417
},
"TerritoryId": 1190,
"InteractionType": "Interact",
"Fly": true,
"DialogueChoices": [
{
"Type": "List",
"Prompt": "TEXT_KINGMG105_05248_Q2_000_000",
"Answer": "TEXT_KINGMG105_05248_A2_000_002"
}
],
"CompletionQuestVariablesFlags": [
null,
null,
null,
null,
null,
16
]
},
{
"DataId": 1052245,
"Position": {
"X": 276.78333,
"Y": -16.53927,
"Z": -562.7985
},
"TerritoryId": 1190,
"InteractionType": "Interact",
"Fly": true,
"CompletionQuestVariablesFlags": [
null,
null,
null,
null,
null,
32
]
},
{
"DataId": 1052243,
"Position": {
"X": 332.26514,
"Y": -14.986355,
"Z": -558.95325
},
"TerritoryId": 1190,
"InteractionType": "Interact",
"Fly": true,
"CompletionQuestVariablesFlags": [
null,
null,
null,
null,
null,
128
]
},
{
"DataId": 1052239,
"Position": {
"X": 354.57385,
"Y": -17.082237,
"Z": -452.5063
},
"TerritoryId": 1190,
"InteractionType": "Interact",
"Fly": true,
"CompletionQuestVariablesFlags": [
null,
null,
null,
null,
null,
64
]
}
]
},
{
"Sequence": 255,
"Steps": [
{
"Position": {
"X": 302.1455,
"Y": -15.629961,
"Z": -516.2348
},
"TerritoryId": 1190,
"InteractionType": "WalkTo",
"Fly": true
},
{
"DataId": 1051013,
"Position": {
"X": 303.79175,
"Y": -15.629962,
"Z": -516.25854
},
"TerritoryId": 1190,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,94 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052248,
"Position": {
"X": 293.93445,
"Y": -16.71379,
"Z": -528.70984
},
"TerritoryId": 1190,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 1052248,
"Position": {
"X": 293.93445,
"Y": -16.71379,
"Z": -528.70984
},
"TerritoryId": 1190,
"InteractionType": "SinglePlayerDuty"
}
]
},
{
"Sequence": 2,
"Steps": []
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 1052252,
"Position": {
"X": 299.15308,
"Y": -15.629961,
"Z": -518.4253
},
"StopDistance": 5,
"TerritoryId": 1190,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 4,
"Steps": [
{
"DataId": 1052255,
"Position": {
"X": -123.91852,
"Y": 16.187744,
"Z": -296.80328
},
"TerritoryId": 1190,
"InteractionType": "Interact",
"Fly": true,
"DialogueChoices": [
{
"Type": "YesNo",
"Prompt": "TEXT_KINGMG106_05249_SYSTEM_000_402",
"Yes": true
}
]
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1052259,
"Position": {
"X": -171.03839,
"Y": 15.75679,
"Z": -372.45752
},
"TerritoryId": 1190,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,126 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1052261,
"Position": {
"X": -172.25916,
"Y": 15.73959,
"Z": -376.1197
},
"TerritoryId": 1190,
"InteractionType": "AcceptQuest"
}
]
},
{
"Sequence": 1,
"Steps": [
{
"DataId": 1048083,
"Position": {
"X": 302.05237,
"Y": 51.199978,
"Z": 205.0354
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AetheryteShortcut": "Solution Nine",
"AethernetShortcut": [
"[Solution Nine] Aetheryte Plaza",
"[Solution Nine] Neon Stein"
],
"TargetTerritoryId": 1207,
"SkipConditions": {
"AetheryteShortcutIf": {
"InTerritory": [
1207
]
},
"StepIf": {
"InTerritory": [
1207
]
}
}
},
{
"DataId": 1052521,
"Position": {
"X": -1.8463745,
"Y": -3.4458935E-08,
"Z": 5.8441772
},
"TerritoryId": 1207,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 2,
"Steps": [
{
"DataId": 1052269,
"Position": {
"X": -2.456726,
"Y": -7.2107476E-08,
"Z": 8.987488
},
"TerritoryId": 1207,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 3,
"Steps": [
{
"DataId": 1052271,
"Position": {
"X": -0.41204834,
"Y": -3.9115548E-08,
"Z": 6.240906
},
"TerritoryId": 1207,
"InteractionType": "Interact"
}
]
},
{
"Sequence": 4,
"Steps": [
{
"DataId": 1052272,
"Position": {
"X": 0.19836426,
"Y": 0.00054359436,
"Z": -94.98743
},
"TerritoryId": 1186,
"InteractionType": "Interact",
"AetheryteShortcut": "Solution Nine"
}
]
},
{
"Sequence": 255,
"Steps": [
{
"DataId": 1052267,
"Position": {
"X": -3.7080078,
"Y": -7.4505806E-08,
"Z": 9.170593
},
"StopDistance": 7,
"TerritoryId": 1207,
"InteractionType": "CompleteQuest"
}
]
}
]
}

View File

@ -0,0 +1,21 @@
{
"$schema": "https://git.carvel.li/liza/Questionable/raw/branch/master/QuestPaths/quest-v1.json",
"Author": "liza",
"QuestSequence": [
{
"Sequence": 0,
"Steps": [
{
"DataId": 1048548,
"Position": {
"X": -109.48352,
"Y": -15,
"Z": 185.04602
},
"TerritoryId": 1185,
"InteractionType": "AcceptQuest"
}
]
}
]
}

View File

@ -2,7 +2,6 @@
using System.Linq;
using Dalamud.Plugin.Services;
using Lumina.Excel.Sheets;
using Microsoft.Extensions.Logging;
using Questionable.Model;
using Questionable.Model.Questing;
@ -10,20 +9,12 @@ namespace Questionable.Data;
internal sealed class JournalData
{
public JournalData(IDataManager dataManager, QuestData questData, ILogger<JournalData> logger)
public JournalData(IDataManager dataManager, QuestData questData)
{
var genres = dataManager.GetExcelSheet<JournalGenre>()
.Where(x => x.RowId > 0 && x.Icon > 0)
.Select(x => new Genre(x, questData.GetAllByJournalGenre(x.RowId)))
.ToList();
foreach (var genre in genres)
{
logger.LogInformation("Genre {GenreId}: {GenreName} has {QuestCount} quests",
genre.Id, genre.Name, genre.QuestCount);
}
logger.LogInformation("Genre count: {GenreCount}", genres.Count);
var quest = questData.GetQuestInfo(new QuestId(5193));
logger.LogInformation("Q: {N}, {A}, {B}", quest.Name, quest.JournalGenre, quest.IssuerDataId);
var limsaStart = dataManager.GetExcelSheet<QuestRedo>().GetRow(1);
var gridaniaStart = dataManager.GetExcelSheet<QuestRedo>().GetRow(2);

View File

@ -12,6 +12,7 @@ public readonly unsafe struct QuestEx(ExcelPage page, uint offset, uint row) : I
public Quest Original { get; } = new(page, offset, row);
public readonly ReadOnlySeString Id => page.ReadString(offset + 2420, offset);
public RowRef IssuerStart => RowRef.GetFirstValidRowOrUntyped(page.Module, page.ReadUInt32(offset + 2456), [typeof(EObjName), typeof(ENpcResident)], 882056187, page.Language);
public RowRef<Level> IssuerLocation => new(page.Module, page.ReadUInt32(offset + 2460), page.Language);
public RowRef<JournalGenre> JournalGenre => new(page.Module, page.ReadUInt32(offset + 2468), page.Language);

View File

@ -3,10 +3,13 @@ using System.Linq;
using Dalamud.Plugin.Services;
using Dalamud.Utility;
using LLib;
using Lumina.Excel;
using Lumina.Excel.Exceptions;
using Lumina.Excel.Sheets;
using Lumina.Text;
using Lumina.Text.ReadOnly;
using Microsoft.Extensions.Logging;
using Questionable.Data.Sheets;
using Questionable.Model;
using Quest = Questionable.Model.Quest;
using GimmickYesNo = Lumina.Excel.Sheets.GimmickYesNo;
@ -38,7 +41,7 @@ internal sealed class ExcelFunctions
if (currentQuest != null && excelSheetName == null)
{
var questRow =
_dataManager.GetExcelSheet<Lumina.Excel.Sheets.Quest>().GetRowOrDefault((uint)currentQuest.Id.Value +
_dataManager.GetExcelSheet<QuestEx>().GetRowOrDefault((uint)currentQuest.Id.Value +
0x10000);
if (questRow == null)
{
@ -46,13 +49,20 @@ internal sealed class ExcelFunctions
return null;
}
excelSheetName = $"quest/{(currentQuest.Id.Value / 100):000}/{questRow.Value.RowId}";
excelSheetName = $"quest/{(currentQuest.Id.Value / 100):000}/{questRow.Value.Id}";
}
ArgumentNullException.ThrowIfNull(excelSheetName);
var excelSheet = _dataManager.GetExcelSheet<QuestDialogueText>(name: excelSheetName);
return excelSheet.Cast<QuestDialogueText?>()
.FirstOrDefault(x => x!.Value.Key == key)?.Value;
try
{
var excelSheet = _dataManager.GetExcelSheet<QuestDialogueText>(name: excelSheetName);
return excelSheet.Cast<QuestDialogueText?>()
.FirstOrDefault(x => x!.Value.Key == key)?.Value;
}
catch (SheetNotFoundException e)
{
throw new SheetNotFoundException($"Sheet '{excelSheetName}' not found", e);
}
}
public StringOrRegex GetDialogueTextByRowId(string? excelSheet, uint rowId, bool isRegex)

View File

@ -64,10 +64,9 @@ internal sealed unsafe class GameFunctions
_territoryToAetherCurrentCompFlgSet = dataManager.GetExcelSheet<TerritoryType>()
.Where(x => x.RowId > 0)
.Where(x => x.Unknown3 > 0)
.Where(x => x.Unknown4 > 0)
.ToDictionary(x => (ushort)x.RowId, x => x.Unknown4)
.AsReadOnly();
_territoryToAetherCurrentCompFlgSet = new Dictionary<ushort, byte>().AsReadOnly();
_contentFinderConditionToContentId = dataManager.GetExcelSheet<ContentFinderCondition>()
.Where(x => x.RowId > 0 && x.Content.RowId > 0)
.ToDictionary(x => x.RowId, x => x.Content.RowId)