forked from aly/qstbak
muffin v7.4.18
This commit is contained in:
parent
53aa9fdee8
commit
f82b9ce2a2
50 changed files with 142364 additions and 230361 deletions
|
|
@ -0,0 +1,104 @@
|
|||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://github.com/WigglyMuffin/Questionable/raw/refs/heads/main/SeasonalDutyPaths/seasonaldutydefinition-v1.json",
|
||||
"title": "Seasonal Duty Definition V1",
|
||||
"description": "A seasonal duty farming definition",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"$schema": {
|
||||
"type": "string"
|
||||
},
|
||||
"Name": {
|
||||
"description": "Display name of the seasonal duty",
|
||||
"type": "string"
|
||||
},
|
||||
"TerritoryId": {
|
||||
"description": "Territory ID where the NPC is located",
|
||||
"type": "integer",
|
||||
"minimum": 1
|
||||
},
|
||||
"Aetheryte": {
|
||||
"description": "Nearest aetheryte for teleporting",
|
||||
"$ref": "https://github.com/WigglyMuffin/Questionable/raw/refs/heads/main/Questionable.Model/common-aetheryte.json"
|
||||
},
|
||||
"AethernetShortcut": {
|
||||
"description": "Aethernet shortcut to use after teleporting",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"minItems": 2,
|
||||
"maxItems": 2
|
||||
},
|
||||
"NpcDataId": {
|
||||
"description": "Data ID of the NPC to interact with",
|
||||
"type": "integer",
|
||||
"minimum": 1
|
||||
},
|
||||
"NpcPosition": {
|
||||
"description": "Position of the NPC",
|
||||
"$ref": "https://github.com/WigglyMuffin/Questionable/raw/refs/heads/main/Questionable.Model/common-vector3.json"
|
||||
},
|
||||
"DialogueChoices": {
|
||||
"description": "Dialogue choices when interacting with the NPC to enter the duty",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"DutyTerritoryId": {
|
||||
"description": "Territory ID of the duty instance",
|
||||
"type": "integer",
|
||||
"minimum": 1
|
||||
},
|
||||
"DataIds": {
|
||||
"description": "Data IDs of objects to interact with inside the duty",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "integer",
|
||||
"minimum": 1
|
||||
},
|
||||
"minItems": 1
|
||||
},
|
||||
"WaypointPositions": {
|
||||
"description": "Waypoint positions to navigate through inside the duty",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "https://github.com/WigglyMuffin/Questionable/raw/refs/heads/main/Questionable.Model/common-vector3.json"
|
||||
}
|
||||
},
|
||||
"Action": {
|
||||
"description": "Action to perform on each object",
|
||||
"type": "string"
|
||||
},
|
||||
"StopDistance": {
|
||||
"description": "Distance at which to stop and perform the action",
|
||||
"type": "number",
|
||||
"minimum": 0
|
||||
},
|
||||
"RequiredQuestId": {
|
||||
"description": "Quest ID that must be completed before this duty can be farmed",
|
||||
"type": "integer",
|
||||
"minimum": 1
|
||||
},
|
||||
"EventExpiry": {
|
||||
"description": "Date and time (in UTC) when the seasonal event ends",
|
||||
"format": "date-time",
|
||||
"type": [
|
||||
"string",
|
||||
"null"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"$schema",
|
||||
"Name",
|
||||
"TerritoryId",
|
||||
"NpcDataId",
|
||||
"NpcPosition",
|
||||
"DutyTerritoryId",
|
||||
"DataIds",
|
||||
"Action"
|
||||
],
|
||||
"additionalProperties": false
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Numerics;
|
||||
using System.Runtime.InteropServices;
|
||||
using Questionable.Model.Common;
|
||||
using Questionable.Model.Questing;
|
||||
|
||||
namespace Questionable.SeasonalDutyPaths;
|
||||
|
||||
public static class AssemblySeasonalDutyDefinitionLoader
|
||||
{
|
||||
private static Dictionary<ushort, SeasonalDutyDefinition>? _definitions;
|
||||
|
||||
public static Stream SeasonalDutyDefinitionSchema => typeof(AssemblySeasonalDutyDefinitionLoader).Assembly.GetManifestResourceStream("Questionable.SeasonalDutyPaths.SeasonalDutyDefinitionSchema");
|
||||
|
||||
public static IReadOnlyDictionary<ushort, SeasonalDutyDefinition> GetDefinitions()
|
||||
{
|
||||
if (_definitions == null)
|
||||
{
|
||||
_definitions = new Dictionary<ushort, SeasonalDutyDefinition>();
|
||||
LoadDefinitions();
|
||||
}
|
||||
return _definitions ?? throw new InvalidOperationException("seasonal duty definition data is not initialized");
|
||||
}
|
||||
|
||||
private static void AddDefinition(ushort id, SeasonalDutyDefinition definition)
|
||||
{
|
||||
_definitions[id] = definition;
|
||||
}
|
||||
|
||||
private static void LoadDefinitions()
|
||||
{
|
||||
LoadDefinition0();
|
||||
}
|
||||
|
||||
private static void LoadDefinition0()
|
||||
{
|
||||
SeasonalDutyDefinition obj = new SeasonalDutyDefinition
|
||||
{
|
||||
Name = "Hatching-tide (2026)",
|
||||
TerritoryId = 133,
|
||||
Aetheryte = EAetheryteLocation.Gridania,
|
||||
AethernetShortcut = new AethernetShortcut
|
||||
{
|
||||
From = EAetheryteLocation.Gridania,
|
||||
To = EAetheryteLocation.GridaniaAmphitheatre
|
||||
},
|
||||
NpcDataId = 1056067u,
|
||||
NpcPosition = new Vector3(-54.551025f, 6.851239f, -110.948364f)
|
||||
};
|
||||
int num = 1;
|
||||
List<DialogueChoice> list = new List<DialogueChoice>(num);
|
||||
CollectionsMarshal.SetCount(list, num);
|
||||
CollectionsMarshal.AsSpan(list)[0] = new DialogueChoice
|
||||
{
|
||||
Type = EDialogChoiceType.List,
|
||||
ExcelSheet = "custom/009/FesEst2026Entrance_00960",
|
||||
Prompt = new ExcelRef("TEXT_FESEST2026ENTRANCE_00960_Q1_000_000"),
|
||||
Answer = new ExcelRef("TEXT_FESEST2026ENTRANCE_00960_A1_000_001"),
|
||||
PromptIsRegularExpression = true
|
||||
};
|
||||
obj.DialogueChoices = list;
|
||||
obj.DutyTerritoryId = 1336;
|
||||
num = 8;
|
||||
List<uint> list2 = new List<uint>(num);
|
||||
CollectionsMarshal.SetCount(list2, num);
|
||||
Span<uint> span = CollectionsMarshal.AsSpan(list2);
|
||||
span[0] = 2015072u;
|
||||
span[1] = 2015073u;
|
||||
span[2] = 2015074u;
|
||||
span[3] = 2015075u;
|
||||
span[4] = 2015076u;
|
||||
span[5] = 2015077u;
|
||||
span[6] = 2015078u;
|
||||
span[7] = 2015079u;
|
||||
obj.DataIds = list2;
|
||||
num = 9;
|
||||
List<Vector3> list3 = new List<Vector3>(num);
|
||||
CollectionsMarshal.SetCount(list3, num);
|
||||
Span<Vector3> span2 = CollectionsMarshal.AsSpan(list3);
|
||||
span2[0] = new Vector3(-700.0023f, -0.15729797f, -721.67926f);
|
||||
span2[1] = new Vector3(-700.1704f, -0.0301615f, 77.54147f);
|
||||
span2[2] = new Vector3(-699.9926f, -0.021064043f, 877.55304f);
|
||||
span2[3] = new Vector3(99.99213f, -0.100738764f, -721.9226f);
|
||||
span2[4] = new Vector3(99.92716f, 4.7683716E-07f, 77.599335f);
|
||||
span2[5] = new Vector3(100.40486f, 0.20596194f, 877.50397f);
|
||||
span2[6] = new Vector3(899.93384f, 0.03615737f, -722.4109f);
|
||||
span2[7] = new Vector3(900.052f, 0.23717809f, 77.897415f);
|
||||
span2[8] = new Vector3(900.26733f, -0.30200624f, 877.5144f);
|
||||
obj.WaypointPositions = list3;
|
||||
obj.Action = EAction.PruningPirouette;
|
||||
obj.RequiredQuestId = (ushort)5425;
|
||||
obj.EventExpiry = new DateTime(2026, 4, 6, 14, 59, 0, DateTimeKind.Utc);
|
||||
AddDefinition(1, obj);
|
||||
}
|
||||
}
|
||||
24
SeasonalDutyPaths/SeasonalDutyPaths.csproj
Normal file
24
SeasonalDutyPaths/SeasonalDutyPaths.csproj
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<AssemblyName>SeasonalDutyPaths</AssemblyName>
|
||||
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
||||
<TargetFramework>netcoreapp1.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<LangVersion>12.0</LangVersion>
|
||||
<AllowUnsafeBlocks>True</AllowUnsafeBlocks>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<RootNamespace />
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<None Remove="Questionable.SeasonalDutyPaths.SeasonalDutyDefinitionSchema" />
|
||||
<EmbeddedResource Include="Questionable.SeasonalDutyPaths.SeasonalDutyDefinitionSchema" LogicalName="Questionable.SeasonalDutyPaths.SeasonalDutyDefinitionSchema" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Questionable.Model">
|
||||
<HintPath>..\..\Questionable.Model.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
Loading…
Add table
Add a link
Reference in a new issue