private static void ImportEventSettings() { //Reset Settings _achievementSettings = new BibaAchievementSettings(); _specialSceneSettings = new BibaSpecialSceneSettings(); _pointEventSettings = new BibaPointEventSettings(); //Import Data ImportEventType(); ImportParameterType(); ImportEventSheet(COMMON_WORKSHEET_NAME); ImportEventSheet(BibaContentConstants.CI_GAME_ID, true); //Save Settings HelperMethods.WriteConstStringFile(BIBAGAME_NAMESPACE, typeof(BibaPointEvents).Name, _pointEventSettings.BibaPointSettings.Select(setting => setting.Id).ToList(), POINTEVENTS_CONSTANTS_FILEPATH); var jsonDataService = new JSONDataService(); jsonDataService.WriteToDisk <BibaAchievementSettings>(_achievementSettings, BibaEditorConstants.GetContentOutputPath(BibaContentConstants.ACHIEVEMENT_SETTINGS_FILE)); jsonDataService.WriteToDisk <BibaSpecialSceneSettings>(_specialSceneSettings, BibaEditorConstants.GetContentOutputPath(BibaContentConstants.SPECIAL_SCENE_SETTINGS_FILE)); jsonDataService.WriteToDisk <BibaPointEventSettings>(_pointEventSettings, BibaEditorConstants.GetContentOutputPath(BibaContentConstants.POINTEVENT_SETTINGS_FILE)); AssetDatabase.SaveAssets(); AssetDatabase.Refresh(); }
public static void CreateAchievementSettings() { _achievementSettings = new BibaAchievementSettings(); ImportBasicAchievementSettings(); ImportSeasonalAchievementSettings(); var jsonDataService = new JSONDataService(); jsonDataService.WriteToDisk <BibaAchievementSettings>(_achievementSettings, BibaEditorConstants.GetContentOutputPath(BibaContentConstants.ACHIEVEMENT_SETTINGS_FILE)); AssetDatabase.Refresh(); }