Fix codegen
This commit is contained in:
parent
8c808c8fde
commit
8bd62a3b88
@ -141,7 +141,7 @@ public class QuestSourceGenerator : ISourceGenerator
|
|||||||
Token(SyntaxKind
|
Token(SyntaxKind
|
||||||
.UShortKeyword)),
|
.UShortKeyword)),
|
||||||
Token(SyntaxKind.CommaToken),
|
Token(SyntaxKind.CommaToken),
|
||||||
IdentifierName("QuestData")
|
IdentifierName("QuestRoot")
|
||||||
}))))
|
}))))
|
||||||
.WithVariables(
|
.WithVariables(
|
||||||
SingletonSeparatedList(
|
SingletonSeparatedList(
|
||||||
@ -169,7 +169,7 @@ public class QuestSourceGenerator : ISourceGenerator
|
|||||||
SyntaxKind
|
SyntaxKind
|
||||||
.CommaToken),
|
.CommaToken),
|
||||||
IdentifierName(
|
IdentifierName(
|
||||||
"QuestData")
|
"QuestRoot")
|
||||||
}))))
|
}))))
|
||||||
.WithArgumentList(
|
.WithArgumentList(
|
||||||
ArgumentList())
|
ArgumentList())
|
||||||
|
@ -6,6 +6,6 @@ namespace Questionable.QuestPaths;
|
|||||||
|
|
||||||
public static partial class AssemblyQuestLoader
|
public static partial class AssemblyQuestLoader
|
||||||
{
|
{
|
||||||
public static IReadOnlyDictionary<ushort, QuestData> GetQuests() => Quests;
|
public static IReadOnlyDictionary<ushort, QuestRoot> GetQuests() => Quests;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -37,13 +37,13 @@ internal sealed class QuestRegistry
|
|||||||
#if RELEASE
|
#if RELEASE
|
||||||
_logger.LogInformation("Loading quests from assembly");
|
_logger.LogInformation("Loading quests from assembly");
|
||||||
|
|
||||||
foreach ((ushort questId, QuestData questData) in QuestPaths.AssemblyQuestLoader.GetQuests())
|
foreach ((ushort questId, QuestRoot questRoot) in QuestPaths.AssemblyQuestLoader.GetQuests())
|
||||||
{
|
{
|
||||||
Quest quest = new()
|
Quest quest = new()
|
||||||
{
|
{
|
||||||
QuestId = questId,
|
QuestId = questId,
|
||||||
Name = string.Empty,
|
Root = questRoot,
|
||||||
Data = questData,
|
Info = _questData.GetQuestInfo(questId),
|
||||||
};
|
};
|
||||||
_quests[questId] = quest;
|
_quests[questId] = quest;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user