123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165 |
- using System;
- using PlayerStatus;
- namespace BackupParamAccessor
- {
- public static class BackupParamAccessor
- {
- public static void BackupParam(int? slotId, SCENE_ID sceneId_f)
- {
- if (slotId == null)
- {
- for (int i = 0; i < 40; i++)
- {
- BackupParamAccessor.BackupParam(new int?(i), sceneId_f);
- }
- }
- int num = (slotId == null) ? 0 : slotId.Value;
- string str = sceneId_f.ToString();
- Params @params = new Params();
- Maid scheduleSlot = GameMain.Instance.CharacterMgr.status.GetScheduleSlot(num);
- if (scheduleSlot != null)
- {
- @params.salon_cleanliness = 0;
- @params.salon_gorgeous = 0;
- @params.salon_evaluation = GameMain.Instance.CharacterMgr.status.clubEvaluation;
- @params.money = GameMain.Instance.CharacterMgr.status.money;
- @params.clubEvaluation = GameMain.Instance.CharacterMgr.status.clubEvaluation;
- @params.clubMoney = (int)GameMain.Instance.CharacterMgr.status.money;
- @params.evaluation = scheduleSlot.status.evaluation;
- @params.sales = scheduleSlot.status.sales;
- @params.study_rate = scheduleSlot.status.studyRate;
- @params.reception = scheduleSlot.status.reception;
- @params.care = scheduleSlot.status.care;
- @params.lovely = scheduleSlot.status.lovely;
- @params.elegance = scheduleSlot.status.elegance;
- @params.charm = scheduleSlot.status.charm;
- @params.teach_rate = scheduleSlot.status.teachRate;
- @params.cooking = scheduleSlot.status.cooking;
- @params.vocal = scheduleSlot.status.vocal;
- @params.dance = scheduleSlot.status.dance;
- @params.appealPoint = scheduleSlot.status.appealPoint;
- @params.inyoku = scheduleSlot.status.inyoku;
- @params.m_value = scheduleSlot.status.mvalue;
- @params.hentai = scheduleSlot.status.hentai;
- @params.housi = scheduleSlot.status.housi;
- if (scheduleSlot.status.selectedJobClass != null)
- {
- @params.maidClassLv = scheduleSlot.status.selectedJobClass.level;
- @params.maidClassExp = scheduleSlot.status.selectedJobClass.expSystem.GetTotalExp();
- }
- if (scheduleSlot.status.selectedYotogiClass != null)
- {
- @params.yotogiClassLv = scheduleSlot.status.selectedYotogiClass.level;
- @params.yotogiClassExp = scheduleSlot.status.selectedYotogiClass.expSystem.GetTotalExp();
- }
- @params.yotogi_play_count = scheduleSlot.status.playCountYotogi;
- @params.others_play_count = scheduleSlot.status.playCountNightWork;
- @params.likability = scheduleSlot.status.likability;
- }
- BackupParamAccessor.slots = GameMain.Instance.CharacterMgr.status.scheduleSlot;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_clubMoney"] = @params.clubMoney;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_clubEvaluation"] = @params.clubEvaluation;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_salon_cleanliness"] = @params.salon_cleanliness;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_salon_gorgeous"] = @params.salon_gorgeous;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_salon_evaluation"] = @params.salon_evaluation;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_money_top0"] = @params.money_top0;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_money_top10"] = @params.money_top10;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_evaluation"] = @params.evaluation;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_sales_top0"] = @params.sales_top0;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_sales_top10"] = @params.sales_top10;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_study_rate"] = @params.study_rate;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_reception"] = @params.reception;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_care"] = @params.care;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_lovely"] = @params.lovely;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_elegance"] = @params.elegance;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_charm"] = @params.charm;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_teach_rate"] = @params.teach_rate;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_cooking"] = @params.cooking;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_vocal"] = @params.vocal;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_dance"] = @params.dance;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_appealPoint"] = @params.appealPoint;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_inyoku"] = @params.inyoku;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_m_value"] = @params.m_value;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_hentai"] = @params.hentai;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_housi"] = @params.housi;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_maidClassLv"] = @params.maidClassLv;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_maidClassExp"] = @params.maidClassExp;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_yotogiClassLv"] = @params.yotogiClassLv;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_yotogiClassExp"] = @params.yotogiClassExp;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_yotogi_play_count"] = @params.yotogi_play_count;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_others_play_count"] = @params.others_play_count;
- BackupParamAccessor.slots[num].backup_status_dic[str + "_likability"] = @params.likability;
- }
- public static void Clear(int? slotId = null)
- {
- if (slotId == null)
- {
- for (int i = 0; i < 40; i++)
- {
- BackupParamAccessor.Clear(new int?(i));
- }
- }
- int num = (slotId == null) ? 0 : slotId.Value;
- BackupParamAccessor.slots[num].backup_status_dic.Clear();
- }
- public static Params GetBackupParams(int slotId, SCENE_ID sceneId)
- {
- return new Params
- {
- clubMoney = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "clubMoney"),
- clubEvaluation = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "clubEvaluation"),
- salon_cleanliness = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "salon_cleanliness"),
- salon_gorgeous = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "salon_gorgeous"),
- salon_evaluation = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "salon_evaluation"),
- money_top0 = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "money_top0"),
- money_top10 = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "money_top10"),
- evaluation = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "evaluation"),
- sales_top0 = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "sales_top0"),
- sales_top10 = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "sales_top10"),
- study_rate = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "study_rate"),
- teach_rate = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "teach_rate"),
- reception = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "reception"),
- care = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "care"),
- lovely = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "lovely"),
- elegance = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "elegance"),
- charm = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "charm"),
- cooking = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "cooking"),
- vocal = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "vocal"),
- dance = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "dance"),
- appealPoint = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "appealPoint"),
- inyoku = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "inyoku"),
- m_value = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "m_value"),
- hentai = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "hentai"),
- housi = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "housi"),
- maidClassLv = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "maidClassLv"),
- maidClassExp = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "maidClassExp"),
- yotogiClassLv = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "yotogiClassLv"),
- yotogiClassExp = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "yotogiClassExp"),
- yotogi_play_count = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "yotogi_play_count"),
- others_play_count = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "others_play_count"),
- likability = BackupParamAccessor.GetBackupParamsParts(slotId, sceneId, "likability")
- };
- }
- public static int GetBackupParamsParts(int slotId, SCENE_ID sceneId_f, string name)
- {
- BackupParamAccessor.slots = GameMain.Instance.CharacterMgr.status.scheduleSlot;
- string str = sceneId_f.ToString();
- if (BackupParamAccessor.slots[slotId].backup_status_dic.ContainsKey(str + "_" + name))
- {
- return BackupParamAccessor.slots[slotId].backup_status_dic[str + "_" + name];
- }
- return 0;
- }
- public static bool YotogiPlayed(int slotId, SCENE_ID baseId)
- {
- return (BackupParamAccessor.GetBackupParams(slotId, baseId + 1) - BackupParamAccessor.GetBackupParams(slotId, baseId - 1)).yotogi_play_count > 0;
- }
- public static ScheduleData[] slots = GameMain.Instance.CharacterMgr.status.scheduleSlot;
- }
- }
|