ProfileCtrl.cs 38 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019
  1. using System;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using Edit;
  5. using MaidStatus;
  6. using MaidStatus.CsvData;
  7. using UnityEngine;
  8. using Yotogis;
  9. public class ProfileCtrl : MonoBehaviour
  10. {
  11. private bool m_enabledInput
  12. {
  13. get
  14. {
  15. return BaseMgr<ProfileMgr>.Instance.m_enabledInput;
  16. }
  17. }
  18. private bool m_enabledPersonalityInput
  19. {
  20. get
  21. {
  22. return BaseMgr<ProfileMgr>.Instance.m_enabledPersonalityInput;
  23. }
  24. }
  25. public void Init(GameObject goProfilePanel, Status status)
  26. {
  27. this.m_goProfilePanel = goProfilePanel;
  28. this.m_maidStatus = status;
  29. this.m_lContractType = UTY.GetChildObject(this.m_goProfilePanel, "ContractType/OutputField", false).GetComponent<UILabel>();
  30. GameObject childObject = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Name/FirstName", false);
  31. this.m_inFirstName = childObject.GetComponent<UIInput>();
  32. this.m_clFirstName = childObject.GetComponent<BoxCollider>();
  33. EventDelegate.Add(this.m_inFirstName.onChange, new EventDelegate.Callback(BaseMgr<ProfileMgr>.Instance.OnChangeFirstName));
  34. GameObject childObject2 = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Name/LastName", false);
  35. this.m_inLastName = childObject2.GetComponent<UIInput>();
  36. this.m_clLastName = childObject2.GetComponent<BoxCollider>();
  37. EventDelegate.Add(this.m_inLastName.onChange, new EventDelegate.Callback(BaseMgr<ProfileMgr>.Instance.OnChangeLastName));
  38. this.m_buFirstName = UTY.GetChildObject(childObject, "Random", false).GetComponent<UIButton>();
  39. EventDelegate.Add(this.m_buFirstName.onClick, delegate
  40. {
  41. this.m_inFirstName.RemoveFocus();
  42. this.m_inFirstName.value = MaidRandomName.GetFirstName();
  43. });
  44. this.m_buLastName = UTY.GetChildObject(childObject2, "Random", false).GetComponent<UIButton>();
  45. EventDelegate.Add(this.m_buLastName.onClick, delegate
  46. {
  47. this.m_inLastName.RemoveFocus();
  48. this.m_inLastName.value = MaidRandomName.GetLastName();
  49. });
  50. this.m_lMaidClassName = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Type", false).GetComponent<UILabel>();
  51. this.m_lMaidClassLevel = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Level", false).GetComponent<UILabel>();
  52. this.m_lMaidClassExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Exp", false).GetComponent<UILabel>();
  53. this.m_lMaidClassRequiredExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/RequiredExp", false).GetComponent<UILabel>();
  54. this.m_lYotogiClassName = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Type", false).GetComponent<UILabel>();
  55. this.m_lYotogiClassLevel = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Level", false).GetComponent<UILabel>();
  56. this.m_lYotogiClassExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Exp", false).GetComponent<UILabel>();
  57. this.m_lYotogiClassRequiredExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/RequiredExp", false).GetComponent<UILabel>();
  58. this.m_lRelation = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Relation", false).GetComponent<UILabel>();
  59. this.m_lConditionText = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/ConditionText", false).GetComponent<UILabel>();
  60. this.m_lYotogiPlayCount = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/OthersPlayCount", false).GetComponent<UILabel>();
  61. this.m_lOthersPlayCount = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiPlayCount", false).GetComponent<UILabel>();
  62. this.m_lHp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Hp", false).GetComponent<UILabel>();
  63. this.m_lLikability = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Likability", false).GetComponent<UILabel>();
  64. this.m_lMind = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Mind", false).GetComponent<UILabel>();
  65. this.m_lReception = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Reception", false).GetComponent<UILabel>();
  66. this.m_lCare = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Care", false).GetComponent<UILabel>();
  67. this.m_lStudyRate = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StudyRate", false).GetComponent<UILabel>();
  68. this.m_lTeachRate = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/TeachRate", false).GetComponent<UILabel>();
  69. GameObject childObject3 = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Personal/PopupList", false);
  70. this.m_pPersonal = childObject3.GetComponent<UIPopupList>();
  71. this.m_lPersonal = UTY.GetChildObject(childObject3, "LabelParent/Label", false).GetComponent<UILabel>();
  72. bool flag = GameMain.Instance.CharacterMgr.status.GetFlag("オープニング終了") == 1;
  73. List<Personal.Data> allDatas = Personal.GetAllDatas(true);
  74. List<Personal.Data> list = new List<Personal.Data>();
  75. foreach (Personal.Data data in allDatas)
  76. {
  77. string a = data.uniqueName.ToLower();
  78. if (data.oldPersonal)
  79. {
  80. if (a == "pure" || a == "cool" || a == "pride")
  81. {
  82. if (GameMain.Instance.CharacterMgr.status.isAvailableTransfer)
  83. {
  84. list.Add(data);
  85. }
  86. }
  87. else if (flag)
  88. {
  89. if (data.single)
  90. {
  91. list.Add(data);
  92. }
  93. else if (!string.IsNullOrEmpty(GameMain.Instance.CMSystem.CM3D2Path) && data.compatible)
  94. {
  95. list.Add(data);
  96. }
  97. }
  98. }
  99. else
  100. {
  101. list.Add(data);
  102. }
  103. }
  104. this.m_pPersonal.items.Clear();
  105. foreach (Personal.Data data2 in list)
  106. {
  107. this.m_pPersonal.items.Add(data2.drawName);
  108. }
  109. EventDelegate.Add(this.m_pPersonal.onChange, delegate
  110. {
  111. });
  112. ProfileCtrl.m_dicPersonal = new Dictionary<string, Personal.Data>();
  113. foreach (Personal.Data data3 in list)
  114. {
  115. ProfileCtrl.m_dicPersonal.Add(data3.drawName, data3);
  116. }
  117. this.m_clPersonal = childObject3.GetComponent<BoxCollider>();
  118. this.m_goPersonalSelectorIcon = UTY.GetChildObject(childObject3, "Symbol", false);
  119. GameObject childObject4 = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/SexualExperience/PopupList", false);
  120. this.m_pSexualExperience = childObject4.GetComponent<UIPopupList>();
  121. ProfileCtrl.m_dicSexualExperience = new Dictionary<string, Seikeiken>();
  122. for (int i = 0; i < Enum.GetValues(typeof(Seikeiken)).Length; i++)
  123. {
  124. Seikeiken seikeiken = (Seikeiken)i;
  125. ProfileCtrl.m_dicSexualExperience.Add(EnumConvert.GetString(seikeiken), seikeiken);
  126. }
  127. this.m_clSexualExperience = childObject4.GetComponent<BoxCollider>();
  128. this.m_goSexualExperienceSelectorIcon = UTY.GetChildObject(childObject4, "Symbol", false);
  129. this.m_lHeight = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Height", false).GetComponent<UILabel>();
  130. this.m_lWeight = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Weight", false).GetComponent<UILabel>();
  131. this.m_lBust = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Bust/Bust", false).GetComponent<UILabel>();
  132. this.m_lCup = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Bust/Cup", false).GetComponent<UILabel>();
  133. this.m_lWaist = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Waist", false).GetComponent<UILabel>();
  134. this.m_lHip = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Body/Hip", false).GetComponent<UILabel>();
  135. this.m_lCooking = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Cooking/Box", false).GetComponent<UILabel>();
  136. this.m_lDance = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Dance/Box", false).GetComponent<UILabel>();
  137. this.m_lVocal = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Vocal/Box", false).GetComponent<UILabel>();
  138. this.m_lLovely = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Lovely/Box", false).GetComponent<UILabel>();
  139. this.m_lElegance = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Elegance/Box", false).GetComponent<UILabel>();
  140. this.m_lCharm = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Charm/Box", false).GetComponent<UILabel>();
  141. this.m_lInran = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Inran/Box", false).GetComponent<UILabel>();
  142. this.m_lMValue = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/MValue/Box", false).GetComponent<UILabel>();
  143. this.m_lHentai = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Hentai/Box", false).GetComponent<UILabel>();
  144. this.m_lHousi = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/Housi/Box", false).GetComponent<UILabel>();
  145. this.m_lMaidPoint = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/MaidPoint", false).GetComponent<UILabel>();
  146. this.m_goMaidPointTitleAndFrame = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StatusPoints/MaidPoint/MaidPointTitleAndFrame", false);
  147. this.initMaidPointUIPosX = this.m_goMaidPointTitleAndFrame.transform.parent.localPosition.x;
  148. this.m_inFreeComment = UTY.GetChildObject(this.m_goProfilePanel, "Comment/FreeCommentWindow/FreeComment", false).GetComponent<UIInput>();
  149. EventDelegate.Add(this.m_inFreeComment.onChange, new EventDelegate.Callback(BaseMgr<ProfileMgr>.Instance.OnChangeFreeComment));
  150. this.m_lProfileComment = UTY.GetChildObject(this.m_goProfilePanel, "Comment/ProfileCommentWindow/ProfileComment", false).GetComponent<UILabel>();
  151. this.m_goProfileComment = UTY.GetChildObject(this.m_goProfilePanel, "Comment/ProfileCommentWindow/ProfileComment", false);
  152. this.m_goFreeComment = UTY.GetChildObject(this.m_goProfilePanel, "Comment/FreeCommentWindow/FreeComment", false);
  153. GameObject childObject5 = UTY.GetChildObject(this.m_goProfilePanel, "Comment/ProfileCommentWindow/ProfileTab", false);
  154. this.m_bProfileTab = childObject5.GetComponent<UIButton>();
  155. this.m_goProfileTabSelector = UTY.GetChildObject(childObject5, "SelectCursor", false);
  156. GameObject childObject6 = UTY.GetChildObject(this.m_goProfilePanel, "Comment/FreeCommentWindow/FreeTab", false);
  157. this.m_bFreeTab = childObject6.GetComponent<UIButton>();
  158. this.m_goFreeTabSelector = UTY.GetChildObject(childObject6, "SelectCursor", false);
  159. this.activeColor = new Color(this.m_bProfileTab.defaultColor.r, this.m_bProfileTab.defaultColor.g, this.m_bProfileTab.defaultColor.b, 1f);
  160. this.inActiveColor = this.m_bProfileTab.defaultColor;
  161. this.m_goMaidSkillParent = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/MaidSkillViewer/Contents/MaidSkillUnitParent", false);
  162. this.m_goMaidSkillViewer = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/MaidSkillViewer", false);
  163. this.m_maidSkillScrollView = UTY.GetChildObject(this.m_goMaidSkillViewer, "Contents", false).GetComponent<UIScrollView>();
  164. this.m_goCharacterParent = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/CharacterViewer/Contents/CharacterUnitParent", false);
  165. this.m_goCharacterViewer = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/CharacterViewer", false);
  166. this.m_characterScrollView = UTY.GetChildObject(this.m_goCharacterViewer, "Contents", false).GetComponent<UIScrollView>();
  167. this.m_goPropensityParent = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/PropensityViewer/Contents/CharacterUnitParent", false);
  168. this.m_goPropensityViewer = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/PropensityViewer", false);
  169. this.m_propensityScrollView = UTY.GetChildObject(this.m_goPropensityViewer, "Contents", false).GetComponent<UIScrollView>();
  170. this.m_goYotogiSkillParent = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/YotogiSkillViewer/Contents/YotogiSkillUnitParent", false);
  171. this.m_goYotogiSkillViewer = UTY.GetChildObject(this.m_goProfilePanel, "SubWindows/YotogiSkillViewer", false);
  172. this.m_yotogiSkillScrollView = UTY.GetChildObject(this.m_goYotogiSkillViewer, "Contents", false).GetComponent<UIScrollView>();
  173. this.m_dicSpriteName = new Dictionary<ProfileCtrl.LevelOfAchievement, string>
  174. {
  175. {
  176. ProfileCtrl.LevelOfAchievement.level_1,
  177. "cm3d2_edit_profile_yotogiskill_sign_batu"
  178. },
  179. {
  180. ProfileCtrl.LevelOfAchievement.level_2,
  181. "cm3d2_edit_profile_yotogiskill_sign_sankaku"
  182. },
  183. {
  184. ProfileCtrl.LevelOfAchievement.level_3,
  185. "cm3d2_edit_profile_yotogiskill_sign_maru"
  186. },
  187. {
  188. ProfileCtrl.LevelOfAchievement.level_4,
  189. "cm3d2_edit_profile_yotogiskill_sign_nijumaru"
  190. }
  191. };
  192. this.m_dicUpperBtn = new Dictionary<ProfileMgr.UpperButtonType, ProfileCtrl.UpperButton>();
  193. IEnumerator enumerator4 = Enum.GetValues(typeof(ProfileMgr.UpperButtonType)).GetEnumerator();
  194. try
  195. {
  196. while (enumerator4.MoveNext())
  197. {
  198. object obj = enumerator4.Current;
  199. ProfileMgr.UpperButtonType upperButtonType = (ProfileMgr.UpperButtonType)obj;
  200. if (upperButtonType != ProfileMgr.UpperButtonType.None)
  201. {
  202. GameObject childObject7 = UTY.GetChildObject(this.m_goProfilePanel, "UpperButton/" + upperButtonType.ToString(), false);
  203. UIButton component = childObject7.GetComponent<UIButton>();
  204. GameObject childObject8 = UTY.GetChildObject(childObject7, "SelectCursor", false);
  205. childObject8.SetActive(false);
  206. ProfileCtrl.UpperButton upperButton = new ProfileCtrl.UpperButton();
  207. upperButton.m_btnButton = component;
  208. upperButton.m_name = upperButtonType;
  209. upperButton.m_goSelectCursor = childObject8;
  210. this.m_dicUpperBtn.Add(upperButton.m_name, upperButton);
  211. }
  212. }
  213. }
  214. finally
  215. {
  216. IDisposable disposable;
  217. if ((disposable = (enumerator4 as IDisposable)) != null)
  218. {
  219. disposable.Dispose();
  220. }
  221. }
  222. this.m_dicSubViewer = new Dictionary<ProfileMgr.UpperButtonType, GameObject>
  223. {
  224. {
  225. ProfileMgr.UpperButtonType.MaidSkill,
  226. this.m_goMaidSkillViewer
  227. },
  228. {
  229. ProfileMgr.UpperButtonType.YotogiSkill,
  230. this.m_goYotogiSkillViewer
  231. },
  232. {
  233. ProfileMgr.UpperButtonType.Character,
  234. this.m_goCharacterViewer
  235. },
  236. {
  237. ProfileMgr.UpperButtonType.Propensity,
  238. this.m_goPropensityViewer
  239. }
  240. };
  241. this.initCommentWindow();
  242. this.LoadMaidParamData();
  243. this.SetEnableInput(this.m_enabledInput, this.m_enabledPersonalityInput);
  244. this.m_bInited = true;
  245. }
  246. private void SetEnableInput(bool enabledInput, bool enabledPersonalityInput)
  247. {
  248. this.m_inFirstName.enabled = enabledInput;
  249. this.m_inLastName.enabled = enabledInput;
  250. this.m_clFirstName.enabled = enabledInput;
  251. this.m_clLastName.enabled = enabledInput;
  252. this.m_buFirstName.gameObject.SetActive(enabledInput);
  253. this.m_buLastName.gameObject.SetActive(enabledInput);
  254. this.m_pPersonal.enabled = enabledPersonalityInput;
  255. this.m_clPersonal.enabled = enabledPersonalityInput;
  256. this.m_goPersonalSelectorIcon.SetActive(enabledPersonalityInput);
  257. this.m_pSexualExperience.enabled = enabledInput;
  258. this.m_clSexualExperience.enabled = enabledInput;
  259. this.m_goSexualExperienceSelectorIcon.SetActive(enabledInput);
  260. if (enabledInput)
  261. {
  262. this.m_lMaidPoint.alpha = 1f;
  263. this.m_goMaidPointTitleAndFrame.SetActive(true);
  264. }
  265. else
  266. {
  267. this.m_lMaidPoint.alpha = 0f;
  268. this.m_goMaidPointTitleAndFrame.SetActive(false);
  269. }
  270. }
  271. public void SetActiveViewerAndButton(ProfileMgr.UpperButtonType btn)
  272. {
  273. this.SetActiveViewer(btn);
  274. this.SetActiveButton(btn);
  275. }
  276. public void SetActiveViewer(ProfileMgr.UpperButtonType btn)
  277. {
  278. Vector3 localPosition = this.m_goMaidPointTitleAndFrame.transform.parent.localPosition;
  279. this.m_goMaidPointTitleAndFrame.transform.parent.localPosition = new Vector3(this.initMaidPointUIPosX, localPosition.y, localPosition.z);
  280. foreach (ProfileMgr.UpperButtonType upperButtonType in this.m_dicSubViewer.Keys)
  281. {
  282. if (btn == upperButtonType)
  283. {
  284. GameObject gameObject = this.m_dicSubViewer[upperButtonType];
  285. gameObject.SetActive(true);
  286. localPosition = this.m_goMaidPointTitleAndFrame.transform.parent.localPosition;
  287. this.m_goMaidPointTitleAndFrame.transform.parent.localPosition = new Vector3(-270f, localPosition.y, localPosition.z);
  288. }
  289. else
  290. {
  291. GameObject gameObject2 = this.m_dicSubViewer[upperButtonType];
  292. gameObject2.SetActive(false);
  293. }
  294. }
  295. }
  296. private void SetActiveButton(ProfileMgr.UpperButtonType btn)
  297. {
  298. foreach (ProfileMgr.UpperButtonType upperButtonType in this.m_dicUpperBtn.Keys)
  299. {
  300. ProfileCtrl.UpperButton upperButton;
  301. if (this.m_dicUpperBtn.TryGetValue(upperButtonType, out upperButton))
  302. {
  303. if (btn == upperButtonType)
  304. {
  305. upperButton.m_btnButton.defaultColor = this.activeColor;
  306. upperButton.m_goSelectCursor.SetActive(true);
  307. }
  308. else
  309. {
  310. upperButton.m_btnButton.defaultColor = this.inActiveColor;
  311. upperButton.m_goSelectCursor.SetActive(false);
  312. }
  313. }
  314. }
  315. ProfileMgr.currentActiveBtn = btn;
  316. }
  317. private void initCommentWindow()
  318. {
  319. this.m_goProfileComment.SetActive(true);
  320. this.m_goFreeComment.SetActive(false);
  321. this.m_goProfileTabSelector.SetActive(true);
  322. this.m_goFreeTabSelector.SetActive(false);
  323. this.m_bProfileTab.defaultColor = this.activeColor;
  324. this.m_bFreeTab.defaultColor = this.inActiveColor;
  325. }
  326. public void LoadMaidParamData()
  327. {
  328. this.UpdateProfileData(false);
  329. this.m_lContractType.text = this.GetContractType(this.m_maidStatus.contract);
  330. this.m_inLastName.value = this.m_maidStatus.lastName;
  331. this.m_inFirstName.value = this.m_maidStatus.firstName;
  332. ClassData<JobClass.Data> selectedJobClass = this.m_maidStatus.selectedJobClass;
  333. if (selectedJobClass != null)
  334. {
  335. this.m_lMaidClassName.text = selectedJobClass.data.drawName;
  336. this.m_lMaidClassLevel.text = selectedJobClass.level.ToString();
  337. this.m_lMaidClassExp.text = selectedJobClass.cur_exp.ToString();
  338. this.m_lMaidClassRequiredExp.text = selectedJobClass.next_exp.ToString();
  339. }
  340. ClassData<YotogiClass.Data> selectedYotogiClass = this.m_maidStatus.selectedYotogiClass;
  341. if (selectedYotogiClass != null)
  342. {
  343. this.m_lYotogiClassName.text = selectedYotogiClass.data.drawName;
  344. this.m_lYotogiClassLevel.text = selectedYotogiClass.level.ToString();
  345. this.m_lYotogiClassExp.text = selectedYotogiClass.cur_exp.ToString();
  346. this.m_lYotogiClassRequiredExp.text = selectedYotogiClass.next_exp.ToString();
  347. }
  348. this.m_lHeight.text = this.m_maidStatus.body.height.ToString();
  349. this.m_lWeight.text = this.m_maidStatus.body.weight.ToString();
  350. this.m_lBust.text = this.m_maidStatus.body.bust.ToString();
  351. this.m_lWaist.text = this.m_maidStatus.body.waist.ToString();
  352. this.m_lHip.text = this.m_maidStatus.body.hip.ToString();
  353. this.m_lCup.text = this.m_maidStatus.body.cup;
  354. this.m_lRelation.text = this.GetCondition(this.m_maidStatus.relation);
  355. this.m_lConditionText.text = this.m_maidStatus.conditionText;
  356. this.m_lYotogiPlayCount.text = this.m_maidStatus.playCountYotogi.ToString();
  357. this.m_lOthersPlayCount.text = this.m_maidStatus.playCountNightWork.ToString();
  358. this.m_lHp.text = this.m_maidStatus.maxHp.ToString();
  359. this.m_lLikability.text = this.m_maidStatus.likability.ToString();
  360. this.m_lMind.text = this.m_maidStatus.maxMind.ToString();
  361. this.m_lReception.text = this.m_maidStatus.reception.ToString();
  362. this.m_lCare.text = this.m_maidStatus.care.ToString();
  363. this.m_lStudyRate.text = this.ToPercent(this.m_maidStatus.studyRate).ToString();
  364. this.m_lTeachRate.text = this.ToPercent(this.m_maidStatus.teachRate).ToString();
  365. this.m_lCooking.text = this.m_maidStatus.cooking.ToString();
  366. this.m_lDance.text = this.m_maidStatus.dance.ToString();
  367. this.m_lVocal.text = this.m_maidStatus.vocal.ToString();
  368. this.m_lLovely.text = this.m_maidStatus.lovely.ToString();
  369. this.m_lElegance.text = this.m_maidStatus.elegance.ToString();
  370. this.m_lCharm.text = this.m_maidStatus.charm.ToString();
  371. this.m_lInran.text = this.m_maidStatus.inyoku.ToString();
  372. this.m_lMValue.text = this.m_maidStatus.mvalue.ToString();
  373. this.m_lHentai.text = this.m_maidStatus.hentai.ToString();
  374. this.m_lHousi.text = this.m_maidStatus.housi.ToString();
  375. this.m_lMaidPoint.text = SceneEdit.Instance.maidPoint.ToString();
  376. string drawName = this.m_maidStatus.personal.drawName;
  377. this.m_pPersonal.value = drawName;
  378. this.m_pSexualExperience.value = this.GetSelectOptionNameFromSexualExpe(this.m_maidStatus.seikeiken);
  379. this.m_lProfileComment.text = this.m_maidStatus.profileComment;
  380. this.m_inFreeComment.value = this.m_maidStatus.freeComment;
  381. }
  382. public void SetLastName(string inputText)
  383. {
  384. this.m_maidStatus.lastName = this.AdjustStrLengthIfOver(inputText, 8);
  385. }
  386. public void SetFirstName(string inputText)
  387. {
  388. this.m_maidStatus.firstName = this.AdjustStrLengthIfOver(inputText, 8);
  389. }
  390. public void SetFreeCommnet(string inputText)
  391. {
  392. this.m_maidStatus.freeComment = this.AdjustStrLengthIfOver(inputText, 304);
  393. }
  394. public void SetPersonal(string selectValue)
  395. {
  396. Personal.Data personal;
  397. if (ProfileCtrl.m_dicPersonal.TryGetValue(selectValue, out personal))
  398. {
  399. this.m_maidStatus.SetPersonal(personal);
  400. Debug.Log(string.Concat(new object[]
  401. {
  402. "保存された性格:",
  403. this.m_maidStatus.personal,
  404. " = ",
  405. selectValue
  406. }));
  407. }
  408. }
  409. public void SetSexualExperience(string selectValue)
  410. {
  411. Seikeiken initSeikeiken;
  412. if (ProfileCtrl.m_dicSexualExperience.TryGetValue(selectValue, out initSeikeiken))
  413. {
  414. this.m_maidStatus.seikeiken = (this.m_maidStatus.initSeikeiken = initSeikeiken);
  415. }
  416. }
  417. private string GetSelectOptionNameFromSexualExpe(Seikeiken sexualExperience)
  418. {
  419. foreach (KeyValuePair<string, Seikeiken> keyValuePair in ProfileCtrl.m_dicSexualExperience)
  420. {
  421. if (keyValuePair.Value == sexualExperience)
  422. {
  423. return keyValuePair.Key;
  424. }
  425. }
  426. return null;
  427. }
  428. private string GetContractType(Contract contractType)
  429. {
  430. return EnumConvert.GetString(contractType);
  431. }
  432. private string GetCondition(Relation relation)
  433. {
  434. return EnumConvert.GetString(relation);
  435. }
  436. private string AdjustStrLengthIfOver(string str, int length)
  437. {
  438. if (str.Length > length)
  439. {
  440. str = str.Substring(length);
  441. Debug.LogError(string.Format("入力された文字数が最大文字数を超えています。入力文字={0}, 最大文字数={1}", str, length));
  442. }
  443. return str;
  444. }
  445. private int AdjustIntIfOverRange(int value, int minNumber, int maxNumber)
  446. {
  447. if (value < minNumber)
  448. {
  449. value = minNumber;
  450. Debug.LogError(string.Format("入力された値が許容される最小値より小さいです。入力値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  451. }
  452. else if (value > maxNumber)
  453. {
  454. value = maxNumber;
  455. Debug.LogError(string.Format("入力された値が許容される最大値より大きいです。入力値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  456. }
  457. return value;
  458. }
  459. private void CheckValueRange(int value, int minNumber, int maxNumber)
  460. {
  461. if (value < minNumber || value > maxNumber)
  462. {
  463. Debug.LogError(string.Format("値が不適切です。値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  464. }
  465. }
  466. private bool CheckValueLength(string value, int length)
  467. {
  468. if (value.Length <= length)
  469. {
  470. return true;
  471. }
  472. Debug.LogError(string.Format("値の桁数が不適切です。値={0}, 許容される値の最大桁数={1}", value, length));
  473. return false;
  474. }
  475. public void ChangeCommentTab(string clickTab)
  476. {
  477. if (clickTab == ProfileMgr.CommentTab.ProfileTab.ToString())
  478. {
  479. this.m_bProfileTab.defaultColor = this.activeColor;
  480. this.m_bFreeTab.defaultColor = this.inActiveColor;
  481. this.m_goProfileComment.SetActive(true);
  482. this.m_goFreeComment.SetActive(false);
  483. this.m_goProfileTabSelector.SetActive(true);
  484. this.m_goFreeTabSelector.SetActive(false);
  485. }
  486. else if (clickTab == ProfileMgr.CommentTab.FreeTab.ToString())
  487. {
  488. this.m_bProfileTab.defaultColor = this.inActiveColor;
  489. this.m_bFreeTab.defaultColor = this.activeColor;
  490. this.m_goProfileComment.SetActive(false);
  491. this.m_goFreeComment.SetActive(true);
  492. this.m_goProfileTabSelector.SetActive(false);
  493. this.m_goFreeTabSelector.SetActive(true);
  494. }
  495. }
  496. private bool NotExist<K, V>(Dictionary<K, V> dic)
  497. {
  498. return dic == null || dic.Count == 0;
  499. }
  500. public void CreateMaidSkillViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  501. {
  502. this.m_dicProfileLabel = dicProfileLabel;
  503. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.MaidSkill, this.m_goMaidSkillParent);
  504. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.MaidSkill);
  505. this.AdjustTargetPosition(this.m_goMaidSkillParent, this.m_maidSkillScrollView);
  506. }
  507. public void CreateCharacterViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  508. {
  509. this.m_dicProfileLabel = dicProfileLabel;
  510. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.Character, this.m_goCharacterParent);
  511. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.Character);
  512. this.AdjustTargetPosition(this.m_goCharacterParent, this.m_characterScrollView);
  513. }
  514. public void CreatePropensityViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  515. {
  516. this.m_dicProfileLabel = dicProfileLabel;
  517. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.Propensity, this.m_goPropensityParent);
  518. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.Propensity);
  519. this.AdjustTargetPosition(this.m_goPropensityParent, this.m_propensityScrollView);
  520. }
  521. public void CreateYotogiSkill(Dictionary<string, ProfileCtrl.ProfileYotogiSkillUnit> dicYotogiSkill)
  522. {
  523. this.m_dicYotogiSkill = dicYotogiSkill;
  524. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.YotogiSkill, this.m_goYotogiSkillParent);
  525. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.YotogiSkill);
  526. this.AdjustTargetPosition(this.m_goYotogiSkillParent, this.m_yotogiSkillScrollView);
  527. }
  528. private void CreateProfileItemInViewer(ProfileMgr.UpperButtonType btnType, GameObject goParent)
  529. {
  530. this.ClearExistChildGameObject(goParent);
  531. GameObject gameObject = null;
  532. switch (btnType)
  533. {
  534. case ProfileMgr.UpperButtonType.MaidSkill:
  535. case ProfileMgr.UpperButtonType.Character:
  536. case ProfileMgr.UpperButtonType.Propensity:
  537. {
  538. gameObject = this.GetPrefabs(this.m_goProfileLabelUnitPrefab, "SceneEdit/Profile/Prefab/ProfileLabelUnit");
  539. List<ProfileCtrl.ProfileLabelUnit> list = new List<ProfileCtrl.ProfileLabelUnit>();
  540. foreach (KeyValuePair<string, ProfileCtrl.ProfileLabelUnit> keyValuePair in this.m_dicProfileLabel)
  541. {
  542. list.Add(keyValuePair.Value);
  543. }
  544. list.Sort((ProfileCtrl.ProfileLabelUnit a, ProfileCtrl.ProfileLabelUnit b) => int.Parse(a.m_id) - int.Parse(b.m_id));
  545. for (int i = 0; i < list.Count; i++)
  546. {
  547. GameObject gameObject2 = UnityEngine.Object.Instantiate<GameObject>(gameObject);
  548. this.SetTransformInfo(gameObject2, goParent);
  549. UILabel component = UTY.GetChildObject(gameObject2, "Parameter", false).GetComponent<UILabel>();
  550. component.text = list[i].m_parameter;
  551. }
  552. this.m_goProfileLabelUnitPrefab = gameObject;
  553. break;
  554. }
  555. case ProfileMgr.UpperButtonType.YotogiSkill:
  556. gameObject = this.GetPrefabs(this.m_goYotogiSkillUnitPrefab, "SceneEdit/Profile/Prefab/YotogiSkillUnit");
  557. foreach (KeyValuePair<string, ProfileCtrl.ProfileYotogiSkillUnit> keyValuePair2 in this.m_dicYotogiSkill)
  558. {
  559. GameObject gameObject3 = UnityEngine.Object.Instantiate<GameObject>(gameObject);
  560. this.SetTransformInfo(gameObject3, goParent);
  561. UILabel component2 = UTY.GetChildObject(gameObject3, "Number/Value", false).GetComponent<UILabel>();
  562. component2.text = keyValuePair2.Value.m_number;
  563. UILabel component3 = UTY.GetChildObject(gameObject3, "SkillName/Value", false).GetComponent<UILabel>();
  564. component3.text = keyValuePair2.Value.m_skillName;
  565. UISprite component4 = UTY.GetChildObject(gameObject3, "LevelOfAchievement/Icon", false).GetComponent<UISprite>();
  566. component4.spriteName = this.m_dicSpriteName[keyValuePair2.Value.m_levelOfAchievement];
  567. }
  568. this.m_goYotogiSkillUnitPrefab = gameObject;
  569. break;
  570. }
  571. }
  572. private void SetTransformInfo(GameObject copyPrefabs, GameObject goParent)
  573. {
  574. copyPrefabs.transform.parent = goParent.transform;
  575. copyPrefabs.transform.localScale = Vector3.one;
  576. copyPrefabs.transform.localPosition = Vector3.zero;
  577. copyPrefabs.transform.rotation = Quaternion.identity;
  578. }
  579. private GameObject GetPrefabs(GameObject prefabs, string prefabsPath)
  580. {
  581. if (prefabs == null)
  582. {
  583. prefabs = (Resources.Load(prefabsPath) as GameObject);
  584. if (prefabs == null)
  585. {
  586. Debug.LogError(string.Format("ロードされるプレハブが見つかりませんでした。パス={0}", prefabsPath));
  587. }
  588. }
  589. return prefabs;
  590. }
  591. private void AdjustTargetPosition(GameObject go, UIScrollView scrollView)
  592. {
  593. go.GetComponent<UIGrid>().Reposition();
  594. scrollView.ResetPosition();
  595. }
  596. private void AdjustTargetPositionGridAndTable(GameObject goGrid, GameObject goTable, UIScrollView scrollView)
  597. {
  598. goGrid.GetComponent<UIGrid>().Reposition();
  599. goTable.GetComponent<UITable>().Reposition();
  600. scrollView.ResetPosition();
  601. }
  602. private void ClearExistChildGameObject(GameObject parent)
  603. {
  604. IEnumerator enumerator = parent.transform.GetEnumerator();
  605. try
  606. {
  607. while (enumerator.MoveNext())
  608. {
  609. object obj = enumerator.Current;
  610. Transform transform = (Transform)obj;
  611. UnityEngine.Object.Destroy(transform.gameObject);
  612. }
  613. }
  614. finally
  615. {
  616. IDisposable disposable;
  617. if ((disposable = (enumerator as IDisposable)) != null)
  618. {
  619. disposable.Dispose();
  620. }
  621. }
  622. parent.transform.DetachChildren();
  623. }
  624. private int ToPercent(int number)
  625. {
  626. return (int)Math.Floor((double)(number / 10));
  627. }
  628. public void OnDisable()
  629. {
  630. if (!this.m_bInited)
  631. {
  632. return;
  633. }
  634. this.SetFirstName(this.m_inFirstName.value);
  635. this.SetLastName(this.m_inLastName.value);
  636. this.SetFreeCommnet(this.m_inFreeComment.value);
  637. }
  638. public void UpdateProfileData(bool updateYotogiSkill)
  639. {
  640. if (this.m_enabledInput)
  641. {
  642. this.m_maidStatus.mainChara = !this.m_enabledPersonalityInput;
  643. foreach (int featureId in this.m_maidStatus.features.GetKeyArray())
  644. {
  645. this.m_maidStatus.RemoveFeature(featureId);
  646. }
  647. List<Feature.Data> allDatas = Feature.GetAllDatas(true);
  648. foreach (Personal.Data.LearnFeature learnFeature in this.m_maidStatus.personal.acquisitionFeatureList)
  649. {
  650. if (learnFeature.isLearnPossible(this.m_maidStatus))
  651. {
  652. this.m_maidStatus.AddFeature(learnFeature.feature);
  653. }
  654. }
  655. AbstractClassData.ClassType classTypeFlags = AbstractClassData.ClassType.Share | AbstractClassData.ClassType.New | AbstractClassData.ClassType.Old;
  656. this.m_maidStatus.yotogiClass.Clear();
  657. foreach (YotogiClass.Data data in this.m_maidStatus.yotogiClass.GetLearnPossibleClassDatas(false, classTypeFlags))
  658. {
  659. if (GameMain.Instance.CharacterMgr.status.IsYotogiClassOpenFlag(data.id))
  660. {
  661. this.m_maidStatus.yotogiClass.Add(data.id, false, true);
  662. }
  663. }
  664. int id = this.m_maidStatus.selectedJobClass.data.id;
  665. HashSet<int> hashSet = new HashSet<int>();
  666. foreach (KeyValuePair<int, ClassData<JobClass.Data>> keyValuePair in this.m_maidStatus.jobClass.GetAllDatas())
  667. {
  668. hashSet.Add(keyValuePair.Key);
  669. }
  670. HashSet<int> hashSet2 = new HashSet<int>();
  671. foreach (JobClass.Data data2 in this.m_maidStatus.jobClass.GetLearnPossibleClassDatas(false, classTypeFlags))
  672. {
  673. if (GameMain.Instance.CharacterMgr.status.IsJobClassOpenFlag(data2.id))
  674. {
  675. hashSet2.Add(data2.id);
  676. }
  677. }
  678. HashSet<int> hashSet3 = new HashSet<int>();
  679. foreach (int item in hashSet)
  680. {
  681. if (!hashSet2.Contains(item))
  682. {
  683. hashSet3.Add(item);
  684. }
  685. }
  686. HashSet<int> hashSet4 = new HashSet<int>();
  687. foreach (int item2 in hashSet2)
  688. {
  689. if (!hashSet.Contains(item2))
  690. {
  691. hashSet4.Add(item2);
  692. }
  693. }
  694. foreach (int id2 in hashSet3)
  695. {
  696. this.m_maidStatus.jobClass.Remove(id2, true);
  697. }
  698. int num = -1;
  699. foreach (int num2 in hashSet4)
  700. {
  701. this.m_maidStatus.jobClass.Add(num2, false, true);
  702. num = ((num >= num2) ? num : num2);
  703. }
  704. if (num != -1)
  705. {
  706. this.m_maidStatus.ChangeJobClass(num);
  707. }
  708. if (updateYotogiSkill)
  709. {
  710. this.m_maidStatus.yotogiSkill.Clear();
  711. List<Skill.Data> learnPossibleSkills = Skill.GetLearnPossibleSkills(this.m_maidStatus);
  712. foreach (Skill.Data data3 in learnPossibleSkills)
  713. {
  714. this.m_maidStatus.yotogiSkill.Add(data3.id);
  715. }
  716. }
  717. this.m_maidStatus.UpdateClassBonusStatus();
  718. this.m_maidStatus.sexPlayNumberOfPeople = MaidProfile.UpdateInitPlayNumber(this.m_maidStatus.maid);
  719. }
  720. this.m_maidStatus.UpdateBodyParam();
  721. this.m_maidStatus.profileComment = MaidProfile.Create(this.m_maidStatus.maid, !this.m_enabledInput);
  722. }
  723. private Status m_maidStatus;
  724. private ProfileCtrl.ProfileAttribute m_profileAttribute;
  725. private GameObject m_goProfilePanel;
  726. private GameObject m_goProfileComment;
  727. private GameObject m_goFreeComment;
  728. private GameObject m_goProfileTabSelector;
  729. private GameObject m_goFreeTabSelector;
  730. private GameObject m_goProfileLabelUnitPrefab;
  731. private GameObject m_goYotogiSkillUnitPrefab;
  732. private GameObject m_goMaidPointTitleAndFrame;
  733. private GameObject m_goMaidSkillParent;
  734. private GameObject m_goCharacterParent;
  735. private GameObject m_goPropensityParent;
  736. private GameObject m_goYotogiSkillParent;
  737. private GameObject m_goErogenousZoneParent;
  738. private GameObject m_goMaidSkillViewer;
  739. private GameObject m_goCharacterViewer;
  740. private GameObject m_goPropensityViewer;
  741. private GameObject m_goYotogiSkillViewer;
  742. private GameObject m_goPersonalSelectorIcon;
  743. private GameObject m_goSexualExperienceSelectorIcon;
  744. private UIScrollView m_maidSkillScrollView;
  745. private UIScrollView m_characterScrollView;
  746. private UIScrollView m_propensityScrollView;
  747. private UIScrollView m_yotogiSkillScrollView;
  748. private UIScrollView m_attributeScrollView;
  749. private UILabel m_lContractType;
  750. private UILabel m_lMaidClassName;
  751. private UILabel m_lMaidClassLevel;
  752. private UILabel m_lMaidClassExp;
  753. private UILabel m_lMaidClassRequiredExp;
  754. private UILabel m_lYotogiClassName;
  755. private UILabel m_lYotogiClassLevel;
  756. private UILabel m_lYotogiClassExp;
  757. private UILabel m_lYotogiClassRequiredExp;
  758. private UILabel m_lHeight;
  759. private UILabel m_lWeight;
  760. private UILabel m_lBust;
  761. private UILabel m_lCup;
  762. private UILabel m_lWaist;
  763. private UILabel m_lHip;
  764. private UILabel m_lRelation;
  765. private UILabel m_lConditionText;
  766. private UILabel m_lYotogiPlayCount;
  767. private UILabel m_lOthersPlayCount;
  768. private UILabel m_lHp;
  769. private UILabel m_lLikability;
  770. private UILabel m_lMind;
  771. private UILabel m_lReception;
  772. private UILabel m_lCare;
  773. private UILabel m_lStudyRate;
  774. private UILabel m_lTeachRate;
  775. private UILabel m_lCooking;
  776. private UILabel m_lDance;
  777. private UILabel m_lVocal;
  778. private UILabel m_lLovely;
  779. private UILabel m_lElegance;
  780. private UILabel m_lCharm;
  781. private UILabel m_lInran;
  782. private UILabel m_lMValue;
  783. private UILabel m_lHentai;
  784. private UILabel m_lHousi;
  785. private UILabel m_lMaidPoint;
  786. private UILabel m_lProfileComment;
  787. private UIInput m_inFreeComment;
  788. private UIInput m_inFirstName;
  789. private UIInput m_inLastName;
  790. private UIButton m_buFirstName;
  791. private UIButton m_buLastName;
  792. private UIPopupList m_pPersonal;
  793. private UILabel m_lPersonal;
  794. private UIPopupList m_pSexualExperience;
  795. private UIButton m_bProfileTab;
  796. private UIButton m_bFreeTab;
  797. private BoxCollider m_clFirstName;
  798. private BoxCollider m_clLastName;
  799. private BoxCollider m_clPersonal;
  800. private BoxCollider m_clSexualExperience;
  801. private static Dictionary<string, Personal.Data> m_dicPersonal;
  802. private static Dictionary<string, Seikeiken> m_dicSexualExperience;
  803. private Dictionary<ProfileMgr.UpperButtonType, GameObject> m_dicSubViewer;
  804. private Dictionary<ProfileMgr.UpperButtonType, ProfileCtrl.UpperButton> m_dicUpperBtn;
  805. private Dictionary<string, ProfileCtrl.ProfileLabelUnit> m_dicProfileLabel;
  806. private Dictionary<string, ProfileCtrl.ProfileYotogiSkillUnit> m_dicYotogiSkill;
  807. private Dictionary<ProfileCtrl.LevelOfAchievement, string> m_dicSpriteName;
  808. private bool m_bInited;
  809. private Color activeColor;
  810. private Color inActiveColor;
  811. private const int MAX_NAME_LENGTH = 8;
  812. private const int MAX_FREE_COMMENT_LENGTH = 304;
  813. private const int MAX_EROGENOUSZONE_UNIT = 7;
  814. private const int MAX_ATTRIBUTE_UNIT = 10;
  815. private const int DENOMINATOR = 10;
  816. private const string MAID_SKILL_UNIT_PARENT_PATH = "SubWindows/MaidSkillViewer/Contents/MaidSkillUnitParent";
  817. private const string CHARACTER_UNIT_PARENT_PATH = "SubWindows/CharacterViewer/Contents/CharacterUnitParent";
  818. private const string PROPENSITY_UNIT_PARENT_PATH = "SubWindows/PropensityViewer/Contents/CharacterUnitParent";
  819. private const string YOTOGI_SKILL_UNIT_PARENT_PATH = "SubWindows/YotogiSkillViewer/Contents/YotogiSkillUnitParent";
  820. private const string ATTRIBUTE_UNIT_PARENT_PATH = "SubWindows/AttributeViewer/Contents/Attribute/AttributeUnitParent";
  821. private const string EROGENOUS_ZONE_UNIT_PARENT_PATH = "SubWindows/AttributeViewer/Contents/ErogenousZone/ErogenousZoneParent";
  822. private const string PROFILE_LABEL_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/ProfileLabelUnit";
  823. private const string PROFILE_YOTOGI_SKILL_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/YotogiSkillUnit";
  824. private const string PROFILE_ATTRIBUTE_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/AttributeUnit";
  825. private const string PROFILE_EROGENOUS_ZONE_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/ErogenousZoneUnit";
  826. private float initMaidPointUIPosX;
  827. public enum LevelOfAchievement
  828. {
  829. level_1,
  830. level_2,
  831. level_3,
  832. level_4
  833. }
  834. private class UpperButton
  835. {
  836. public ProfileMgr.UpperButtonType m_name;
  837. public GameObject m_goSelectCursor;
  838. public UIButton m_btnButton;
  839. }
  840. public class ProfileLabelUnit
  841. {
  842. public string m_id;
  843. public string m_parameter;
  844. }
  845. public class ProfileYotogiSkillUnit
  846. {
  847. public string m_id;
  848. public string m_number;
  849. public string m_skillName;
  850. public ProfileCtrl.LevelOfAchievement m_levelOfAchievement;
  851. }
  852. public class ProfileAttribute
  853. {
  854. public ProfileAttribute()
  855. {
  856. this.m_listAttributeUnitName = new List<string>();
  857. }
  858. public List<string> m_listAttributeUnitName;
  859. }
  860. public class ErogenousZoneUnit
  861. {
  862. public string m_category;
  863. public int m_PercentNumber;
  864. }
  865. }