Commit 7befebe3 authored by Melledy's avatar Melledy
Browse files

Add quest ids to handbook

parent 5d4f2452
...@@ -19,6 +19,7 @@ import emu.grasscutter.command.Command; ...@@ -19,6 +19,7 @@ import emu.grasscutter.command.Command;
import emu.grasscutter.command.CommandMap; import emu.grasscutter.command.CommandMap;
import emu.grasscutter.data.GameData; import emu.grasscutter.data.GameData;
import emu.grasscutter.data.ResourceLoader; import emu.grasscutter.data.ResourceLoader;
import emu.grasscutter.data.custom.QuestConfig;
import emu.grasscutter.data.def.AvatarData; import emu.grasscutter.data.def.AvatarData;
import emu.grasscutter.data.def.ItemData; import emu.grasscutter.data.def.ItemData;
import emu.grasscutter.data.def.MonsterData; import emu.grasscutter.data.def.MonsterData;
...@@ -88,7 +89,7 @@ public final class Tools { ...@@ -88,7 +89,7 @@ public final class Tools {
final class ToolsWithLanguageOption { final class ToolsWithLanguageOption {
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
public static void createGmHandbook(String language) throws Exception { public static void createGmHandbook(String language) throws Exception {
ResourceLoader.loadResources(); ResourceLoader.loadAll();
Map<Long, String> map; Map<Long, String> map;
try (InputStreamReader fileReader = new InputStreamReader(new FileInputStream(Utils.toFilePath(RESOURCE("TextMap/TextMap"+language+".json"))), StandardCharsets.UTF_8)) { try (InputStreamReader fileReader = new InputStreamReader(new FileInputStream(Utils.toFilePath(RESOURCE("TextMap/TextMap"+language+".json"))), StandardCharsets.UTF_8)) {
...@@ -148,6 +149,15 @@ final class ToolsWithLanguageOption { ...@@ -148,6 +149,15 @@ final class ToolsWithLanguageOption {
writer.println(data.getId() + " : " + data.getScriptData()); writer.println(data.getId() + " : " + data.getScriptData());
} }
writer.println("// Quests");
list = new ArrayList<>(GameData.getQuestConfigs().keySet());
Collections.sort(list);
for (Integer id : list) {
QuestConfig data = GameData.getQuestConfigs().get(id);
writer.println(data.getId() + " : " + map.get(data.getMainQuest().getTitleTextMapHash()));
}
writer.println(); writer.println();
writer.println("// Monsters"); writer.println("// Monsters");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment