mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-12-17 09:25:06 +01:00
Handle Unlocking of Waypoints and Statues (#1608)
Original commits: * Add necessary protos for scene point/area unlocking. * Rename PlayerOpenStateManager to PlayerProgressManager and move data to Player. * Handle unlocking of waypoints. * Add primo rewards for waypoint unlock. * Statue unlocking. * Add statue quest on player login. * I forgor to add an unlock command. * Give EXP as reward, fire quest trigger, make EXP UI show up.
This commit is contained in:
@@ -112,6 +112,7 @@ public class GameData {
|
||||
@Getter private static final Int2ObjectMap<ChapterData> chapterDataMap = new Int2ObjectOpenHashMap<>();
|
||||
@Getter private static final Int2ObjectMap<TriggerExcelConfigData> triggerExcelConfigDataMap = new Int2ObjectOpenHashMap<>();
|
||||
@Getter private static final Map<String,ScriptSceneData> scriptSceneDataMap = new HashMap<>();
|
||||
@Getter private static final Map<Integer, List<Integer>> scenePointsPerScene = new HashMap<>();
|
||||
|
||||
@Getter private static final Int2ObjectMap<OpenStateData> openStateDataMap = new Int2ObjectOpenHashMap<>();
|
||||
|
||||
|
||||
@@ -142,7 +142,8 @@ public class ResourceLoader {
|
||||
|
||||
List<ScenePointEntry> scenePointList = new ArrayList<>();
|
||||
for (File file : Objects.requireNonNull(folder.listFiles())) {
|
||||
ScenePointConfig config; Integer sceneId;
|
||||
ScenePointConfig config;
|
||||
Integer sceneId;
|
||||
|
||||
Matcher matcher = pattern.matcher(file.getName());
|
||||
if (matcher.find()) {
|
||||
@@ -173,8 +174,10 @@ public class ResourceLoader {
|
||||
pointData.updateDailyDungeon();
|
||||
}
|
||||
|
||||
GameData.getScenePointsPerScene().put(sceneId, new ArrayList<>());
|
||||
for (ScenePointEntry entry : scenePointList) {
|
||||
GameData.getScenePointEntries().put(entry.getName(), entry);
|
||||
GameData.getScenePointsPerScene().get(sceneId).add(entry.getPointData().getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -66,5 +66,11 @@ public class MainQuestData {
|
||||
public static class TalkData {
|
||||
private int id;
|
||||
private String heroTalk;
|
||||
|
||||
public TalkData() {}
|
||||
public TalkData(int id, String heroTalk) {
|
||||
this.id = id;
|
||||
this.heroTalk = heroTalk;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user