ProfileCtrl.cs 39 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048
  1. using System;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using Edit;
  5. using I2.Loc;
  6. using MaidStatus;
  7. using MaidStatus.CsvData;
  8. using UnityEngine;
  9. using Yotogis;
  10. public class ProfileCtrl : MonoBehaviour
  11. {
  12. private bool m_enabledInput
  13. {
  14. get
  15. {
  16. return BaseMgr<ProfileMgr>.Instance.m_enabledInput;
  17. }
  18. }
  19. private bool m_enabledPersonalityInput
  20. {
  21. get
  22. {
  23. return BaseMgr<ProfileMgr>.Instance.m_enabledPersonalityInput;
  24. }
  25. }
  26. public void Init(GameObject goProfilePanel, Status status)
  27. {
  28. this.m_goProfilePanel = goProfilePanel;
  29. this.m_maidStatus = status;
  30. this.m_lContractType = UTY.GetChildObject(this.m_goProfilePanel, "ContractType/OutputField", false).GetComponent<UILabel>();
  31. GameObject childObject = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Name/FirstName", false);
  32. this.m_inFirstName = childObject.GetComponent<UIInput>();
  33. this.m_clFirstName = childObject.GetComponent<BoxCollider>();
  34. EventDelegate.Add(this.m_inFirstName.onChange, new EventDelegate.Callback(BaseMgr<ProfileMgr>.Instance.OnChangeFirstName));
  35. GameObject childObject2 = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Name/LastName", false);
  36. this.m_inLastName = childObject2.GetComponent<UIInput>();
  37. this.m_clLastName = childObject2.GetComponent<BoxCollider>();
  38. EventDelegate.Add(this.m_inLastName.onChange, new EventDelegate.Callback(BaseMgr<ProfileMgr>.Instance.OnChangeLastName));
  39. this.m_buFirstName = UTY.GetChildObject(childObject, "Random", false).GetComponent<UIButton>();
  40. EventDelegate.Add(this.m_buFirstName.onClick, delegate()
  41. {
  42. this.m_inFirstName.RemoveFocus();
  43. this.m_inFirstName.value = MaidRandomName.GetFirstName();
  44. });
  45. this.m_buLastName = UTY.GetChildObject(childObject2, "Random", false).GetComponent<UIButton>();
  46. EventDelegate.Add(this.m_buLastName.onClick, delegate()
  47. {
  48. this.m_inLastName.RemoveFocus();
  49. this.m_inLastName.value = MaidRandomName.GetLastName();
  50. });
  51. this.m_lMaidClassName = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Type", false).GetComponent<UILabel>();
  52. this.m_lMaidClassLevel = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Level", false).GetComponent<UILabel>();
  53. this.m_lMaidClassExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/Exp", false).GetComponent<UILabel>();
  54. this.m_lMaidClassRequiredExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/MaidClass/RequiredExp", false).GetComponent<UILabel>();
  55. this.m_lYotogiClassName = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Type", false).GetComponent<UILabel>();
  56. this.m_lYotogiClassLevel = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Level", false).GetComponent<UILabel>();
  57. this.m_lYotogiClassExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/Exp", false).GetComponent<UILabel>();
  58. this.m_lYotogiClassRequiredExp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiClass/RequiredExp", false).GetComponent<UILabel>();
  59. this.m_lRelation = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Relation", false).GetComponent<UILabel>();
  60. this.m_lConditionText = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/ConditionText", false).GetComponent<UILabel>();
  61. this.m_lYotogiPlayCount = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/OthersPlayCount", false).GetComponent<UILabel>();
  62. this.m_lOthersPlayCount = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/YotogiPlayCount", false).GetComponent<UILabel>();
  63. this.m_lHp = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Hp", false).GetComponent<UILabel>();
  64. this.m_lLikability = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Likability", false).GetComponent<UILabel>();
  65. this.m_lMind = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Mind", false).GetComponent<UILabel>();
  66. this.m_lReception = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Reception", false).GetComponent<UILabel>();
  67. this.m_lCare = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/Care", false).GetComponent<UILabel>();
  68. this.m_lStudyRate = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/StudyRate", false).GetComponent<UILabel>();
  69. this.m_lTeachRate = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/ProfileBase/TeachRate", false).GetComponent<UILabel>();
  70. GameObject childObject3 = UTY.GetChildObject(this.m_goProfilePanel, "CharacterInfo/Personal/PopupList", false);
  71. this.m_pPersonal = childObject3.GetComponent<UIPopupList>();
  72. this.m_lPersonal = UTY.GetChildObject(childObject3, "LabelParent/Label", false).GetComponent<UILabel>();
  73. bool flag = GameMain.Instance.CharacterMgr.status.GetFlag("オープニング終了") == 1;
  74. List<Personal.Data> allDatas = Personal.GetAllDatas(true);
  75. List<Personal.Data> list = new List<Personal.Data>();
  76. foreach (Personal.Data data in allDatas)
  77. {
  78. string a = data.uniqueName.ToLower();
  79. if (data.oldPersonal)
  80. {
  81. if (a == "pure" || a == "cool" || a == "pride")
  82. {
  83. if (GameMain.Instance.CharacterMgr.status.isAvailableTransfer)
  84. {
  85. list.Add(data);
  86. }
  87. }
  88. else if (flag)
  89. {
  90. if (data.single)
  91. {
  92. list.Add(data);
  93. }
  94. else if (!string.IsNullOrEmpty(GameMain.Instance.CMSystem.CM3D2Path) && data.compatible)
  95. {
  96. list.Add(data);
  97. }
  98. }
  99. }
  100. else
  101. {
  102. list.Add(data);
  103. }
  104. }
  105. this.m_pPersonal.items.Clear();
  106. this.m_pPersonal.isLocalized = true;
  107. ProfileCtrl.m_dicPersonal = new Dictionary<string, Personal.Data>();
  108. foreach (Personal.Data data2 in list)
  109. {
  110. string termName = data2.termName;
  111. this.m_pPersonal.items.Add(termName);
  112. ProfileCtrl.m_dicPersonal.Add(termName, data2);
  113. }
  114. EventDelegate.Add(this.m_pPersonal.onChange, delegate()
  115. {
  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 enumerator3 = Enum.GetValues(typeof(ProfileMgr.UpperButtonType)).GetEnumerator();
  194. try
  195. {
  196. while (enumerator3.MoveNext())
  197. {
  198. object obj = enumerator3.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 = (enumerator3 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.GetComponent<Localize>().SetTerm(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.gameObject.GetComponent<Localize>().SetTerm(selectedJobClass.data.termName);
  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.GetComponent<Localize>().SetTerm(this.GetCondition(this.m_maidStatus.relation));
  355. this.m_lConditionText.GetComponent<Localize>().SetTerm(this.m_maidStatus.conditionTermText);
  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. foreach (KeyValuePair<string, Personal.Data> keyValuePair in ProfileCtrl.m_dicPersonal)
  377. {
  378. if (this.m_maidStatus.personal.uniqueName == keyValuePair.Value.uniqueName)
  379. {
  380. this.m_pPersonal.value = keyValuePair.Key;
  381. break;
  382. }
  383. }
  384. this.m_pSexualExperience.value = this.GetSelectOptionNameFromSexualExpe(this.m_maidStatus.seikeiken);
  385. this.m_lProfileComment.text = string.Empty;
  386. this.m_inFreeComment.value = this.m_maidStatus.freeComment;
  387. }
  388. public void SetLastName(string inputText)
  389. {
  390. this.m_maidStatus.lastName = this.AdjustStrLengthIfOver(inputText, 8);
  391. }
  392. public void SetFirstName(string inputText)
  393. {
  394. this.m_maidStatus.firstName = this.AdjustStrLengthIfOver(inputText, 8);
  395. }
  396. public void SetFreeCommnet(string inputText)
  397. {
  398. this.m_maidStatus.freeComment = this.AdjustStrLengthIfOver(inputText, 304);
  399. }
  400. public void SetPersonal(string selectValue)
  401. {
  402. Personal.Data personal;
  403. if (ProfileCtrl.m_dicPersonal.TryGetValue(selectValue, out personal))
  404. {
  405. this.m_maidStatus.SetPersonal(personal);
  406. Debug.Log(string.Concat(new object[]
  407. {
  408. "保存された性格:",
  409. this.m_maidStatus.personal,
  410. " = ",
  411. selectValue
  412. }));
  413. }
  414. }
  415. public void SetSexualExperience(string selectValue)
  416. {
  417. Seikeiken[] array = new Seikeiken[]
  418. {
  419. Seikeiken.No_No,
  420. Seikeiken.Yes_No,
  421. Seikeiken.No_Yes,
  422. Seikeiken.Yes_Yes
  423. };
  424. foreach (Seikeiken seikeiken in array)
  425. {
  426. if (EnumConvert.GetTerm(seikeiken) == selectValue)
  427. {
  428. Seikeiken initSeikeiken = Seikeiken.No_No;
  429. if (ProfileCtrl.m_dicSexualExperience.TryGetValue(EnumConvert.GetString(seikeiken), out initSeikeiken))
  430. {
  431. this.m_maidStatus.seikeiken = (this.m_maidStatus.initSeikeiken = initSeikeiken);
  432. }
  433. break;
  434. }
  435. }
  436. }
  437. private string GetSelectOptionNameFromSexualExpe(Seikeiken sexualExperience)
  438. {
  439. foreach (KeyValuePair<string, Seikeiken> keyValuePair in ProfileCtrl.m_dicSexualExperience)
  440. {
  441. if (keyValuePair.Value == sexualExperience)
  442. {
  443. return EnumConvert.GetTerm(keyValuePair.Value);
  444. }
  445. }
  446. return null;
  447. }
  448. private string GetContractType(Contract contractType)
  449. {
  450. return EnumConvert.GetTerm(contractType);
  451. }
  452. private string GetCondition(Relation relation)
  453. {
  454. return EnumConvert.GetTerm(relation);
  455. }
  456. private string AdjustStrLengthIfOver(string str, int length)
  457. {
  458. if (str.Length > length)
  459. {
  460. str = str.Substring(length);
  461. Debug.LogError(string.Format("入力された文字数が最大文字数を超えています。入力文字={0}, 最大文字数={1}", str, length));
  462. }
  463. return str;
  464. }
  465. private int AdjustIntIfOverRange(int value, int minNumber, int maxNumber)
  466. {
  467. if (value < minNumber)
  468. {
  469. value = minNumber;
  470. Debug.LogError(string.Format("入力された値が許容される最小値より小さいです。入力値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  471. }
  472. else if (value > maxNumber)
  473. {
  474. value = maxNumber;
  475. Debug.LogError(string.Format("入力された値が許容される最大値より大きいです。入力値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  476. }
  477. return value;
  478. }
  479. private void CheckValueRange(int value, int minNumber, int maxNumber)
  480. {
  481. if (value < minNumber || value > maxNumber)
  482. {
  483. Debug.LogError(string.Format("値が不適切です。値={0}, 許容される値の範囲[{1}-{2}]", value, minNumber, maxNumber));
  484. }
  485. }
  486. private bool CheckValueLength(string value, int length)
  487. {
  488. if (value.Length <= length)
  489. {
  490. return true;
  491. }
  492. Debug.LogError(string.Format("値の桁数が不適切です。値={0}, 許容される値の最大桁数={1}", value, length));
  493. return false;
  494. }
  495. public void ChangeCommentTab(string clickTab)
  496. {
  497. if (clickTab == ProfileMgr.CommentTab.ProfileTab.ToString())
  498. {
  499. this.m_bProfileTab.defaultColor = this.activeColor;
  500. this.m_bFreeTab.defaultColor = this.inActiveColor;
  501. this.m_goProfileComment.SetActive(true);
  502. this.m_goFreeComment.SetActive(false);
  503. this.m_goProfileTabSelector.SetActive(true);
  504. this.m_goFreeTabSelector.SetActive(false);
  505. }
  506. else if (clickTab == ProfileMgr.CommentTab.FreeTab.ToString())
  507. {
  508. this.m_bProfileTab.defaultColor = this.inActiveColor;
  509. this.m_bFreeTab.defaultColor = this.activeColor;
  510. this.m_goProfileComment.SetActive(false);
  511. this.m_goFreeComment.SetActive(true);
  512. this.m_goProfileTabSelector.SetActive(false);
  513. this.m_goFreeTabSelector.SetActive(true);
  514. }
  515. }
  516. private bool NotExist<K, V>(Dictionary<K, V> dic)
  517. {
  518. return dic == null || dic.Count == 0;
  519. }
  520. public void CreateMaidSkillViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  521. {
  522. this.m_dicProfileLabel = dicProfileLabel;
  523. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.MaidSkill, this.m_goMaidSkillParent);
  524. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.MaidSkill);
  525. this.AdjustTargetPosition(this.m_goMaidSkillParent, this.m_maidSkillScrollView);
  526. }
  527. public void CreateCharacterViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  528. {
  529. this.m_dicProfileLabel = dicProfileLabel;
  530. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.Character, this.m_goCharacterParent);
  531. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.Character);
  532. this.AdjustTargetPosition(this.m_goCharacterParent, this.m_characterScrollView);
  533. }
  534. public void CreatePropensityViewer(Dictionary<string, ProfileCtrl.ProfileLabelUnit> dicProfileLabel)
  535. {
  536. this.m_dicProfileLabel = dicProfileLabel;
  537. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.Propensity, this.m_goPropensityParent);
  538. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.Propensity);
  539. this.AdjustTargetPosition(this.m_goPropensityParent, this.m_propensityScrollView);
  540. }
  541. public void CreateYotogiSkill(Dictionary<string, ProfileCtrl.ProfileYotogiSkillUnit> dicYotogiSkill)
  542. {
  543. this.m_dicYotogiSkill = dicYotogiSkill;
  544. this.CreateProfileItemInViewer(ProfileMgr.UpperButtonType.YotogiSkill, this.m_goYotogiSkillParent);
  545. this.SetActiveViewerAndButton(ProfileMgr.UpperButtonType.YotogiSkill);
  546. this.AdjustTargetPosition(this.m_goYotogiSkillParent, this.m_yotogiSkillScrollView);
  547. }
  548. private void CreateProfileItemInViewer(ProfileMgr.UpperButtonType btnType, GameObject goParent)
  549. {
  550. this.ClearExistChildGameObject(goParent);
  551. GameObject gameObject = null;
  552. switch (btnType)
  553. {
  554. case ProfileMgr.UpperButtonType.MaidSkill:
  555. case ProfileMgr.UpperButtonType.Character:
  556. case ProfileMgr.UpperButtonType.Propensity:
  557. {
  558. gameObject = this.GetPrefabs(this.m_goProfileLabelUnitPrefab, "SceneEdit/Profile/Prefab/ProfileLabelUnit");
  559. List<ProfileCtrl.ProfileLabelUnit> list = new List<ProfileCtrl.ProfileLabelUnit>();
  560. foreach (KeyValuePair<string, ProfileCtrl.ProfileLabelUnit> keyValuePair in this.m_dicProfileLabel)
  561. {
  562. list.Add(keyValuePair.Value);
  563. }
  564. list.Sort((ProfileCtrl.ProfileLabelUnit a, ProfileCtrl.ProfileLabelUnit b) => int.Parse(a.m_id) - int.Parse(b.m_id));
  565. for (int i = 0; i < list.Count; i++)
  566. {
  567. GameObject gameObject2 = UnityEngine.Object.Instantiate<GameObject>(gameObject);
  568. this.SetTransformInfo(gameObject2, goParent);
  569. UILabel component = UTY.GetChildObject(gameObject2, "Parameter", false).GetComponent<UILabel>();
  570. component.text = list[i].m_parameter;
  571. Localize localize = component.gameObject.AddComponent<Localize>();
  572. if (btnType == ProfileMgr.UpperButtonType.Character)
  573. {
  574. localize.SetTerm("MaidStatus/性癖タイプ/" + list[i].m_parameter);
  575. }
  576. else if (btnType == ProfileMgr.UpperButtonType.Propensity)
  577. {
  578. localize.SetTerm("MaidStatus/性癖タイプ/" + list[i].m_parameter);
  579. }
  580. }
  581. this.m_goProfileLabelUnitPrefab = gameObject;
  582. break;
  583. }
  584. case ProfileMgr.UpperButtonType.YotogiSkill:
  585. gameObject = this.GetPrefabs(this.m_goYotogiSkillUnitPrefab, "SceneEdit/Profile/Prefab/YotogiSkillUnit");
  586. foreach (KeyValuePair<string, ProfileCtrl.ProfileYotogiSkillUnit> keyValuePair2 in this.m_dicYotogiSkill)
  587. {
  588. GameObject gameObject3 = UnityEngine.Object.Instantiate<GameObject>(gameObject);
  589. this.SetTransformInfo(gameObject3, goParent);
  590. UILabel component2 = UTY.GetChildObject(gameObject3, "Number/Value", false).GetComponent<UILabel>();
  591. component2.text = keyValuePair2.Value.m_number;
  592. UILabel component3 = UTY.GetChildObject(gameObject3, "SkillName/Value", false).GetComponent<UILabel>();
  593. component3.text = keyValuePair2.Value.m_skillName;
  594. UISprite component4 = UTY.GetChildObject(gameObject3, "LevelOfAchievement/Icon", false).GetComponent<UISprite>();
  595. component4.spriteName = this.m_dicSpriteName[keyValuePair2.Value.m_levelOfAchievement];
  596. }
  597. this.m_goYotogiSkillUnitPrefab = gameObject;
  598. break;
  599. }
  600. }
  601. private void SetTransformInfo(GameObject copyPrefabs, GameObject goParent)
  602. {
  603. copyPrefabs.transform.parent = goParent.transform;
  604. copyPrefabs.transform.localScale = Vector3.one;
  605. copyPrefabs.transform.localPosition = Vector3.zero;
  606. copyPrefabs.transform.rotation = Quaternion.identity;
  607. }
  608. private GameObject GetPrefabs(GameObject prefabs, string prefabsPath)
  609. {
  610. if (prefabs == null)
  611. {
  612. prefabs = (Resources.Load(prefabsPath) as GameObject);
  613. if (prefabs == null)
  614. {
  615. Debug.LogError(string.Format("ロードされるプレハブが見つかりませんでした。パス={0}", prefabsPath));
  616. }
  617. }
  618. return prefabs;
  619. }
  620. private void AdjustTargetPosition(GameObject go, UIScrollView scrollView)
  621. {
  622. go.GetComponent<UIGrid>().Reposition();
  623. scrollView.ResetPosition();
  624. }
  625. private void AdjustTargetPositionGridAndTable(GameObject goGrid, GameObject goTable, UIScrollView scrollView)
  626. {
  627. goGrid.GetComponent<UIGrid>().Reposition();
  628. goTable.GetComponent<UITable>().Reposition();
  629. scrollView.ResetPosition();
  630. }
  631. private void ClearExistChildGameObject(GameObject parent)
  632. {
  633. IEnumerator enumerator = parent.transform.GetEnumerator();
  634. try
  635. {
  636. while (enumerator.MoveNext())
  637. {
  638. object obj = enumerator.Current;
  639. Transform transform = (Transform)obj;
  640. UnityEngine.Object.Destroy(transform.gameObject);
  641. }
  642. }
  643. finally
  644. {
  645. IDisposable disposable;
  646. if ((disposable = (enumerator as IDisposable)) != null)
  647. {
  648. disposable.Dispose();
  649. }
  650. }
  651. parent.transform.DetachChildren();
  652. }
  653. private int ToPercent(int number)
  654. {
  655. return (int)Math.Floor((double)(number / 10));
  656. }
  657. public void OnDisable()
  658. {
  659. if (!this.m_bInited)
  660. {
  661. return;
  662. }
  663. this.SetFirstName(this.m_inFirstName.value);
  664. this.SetLastName(this.m_inLastName.value);
  665. this.SetFreeCommnet(this.m_inFreeComment.value);
  666. }
  667. public void UpdateProfileData(bool updateYotogiSkill)
  668. {
  669. if (this.m_enabledInput)
  670. {
  671. this.m_maidStatus.mainChara = !this.m_enabledPersonalityInput;
  672. foreach (int featureId in this.m_maidStatus.features.GetKeyArray())
  673. {
  674. this.m_maidStatus.RemoveFeature(featureId);
  675. }
  676. List<Feature.Data> allDatas = Feature.GetAllDatas(true);
  677. foreach (Personal.Data.LearnFeature learnFeature in this.m_maidStatus.personal.acquisitionFeatureList)
  678. {
  679. if (learnFeature.isLearnPossible(this.m_maidStatus))
  680. {
  681. this.m_maidStatus.AddFeature(learnFeature.feature);
  682. }
  683. }
  684. AbstractClassData.ClassType classTypeFlags = AbstractClassData.ClassType.Share | AbstractClassData.ClassType.New | AbstractClassData.ClassType.Old;
  685. this.m_maidStatus.yotogiClass.Clear();
  686. foreach (YotogiClass.Data data in this.m_maidStatus.yotogiClass.GetLearnPossibleClassDatas(false, classTypeFlags))
  687. {
  688. if (GameMain.Instance.CharacterMgr.status.IsYotogiClassOpenFlag(data.id))
  689. {
  690. this.m_maidStatus.yotogiClass.Add(data.id, false, true);
  691. }
  692. }
  693. int id = this.m_maidStatus.selectedJobClass.data.id;
  694. HashSet<int> hashSet = new HashSet<int>();
  695. foreach (KeyValuePair<int, ClassData<JobClass.Data>> keyValuePair in this.m_maidStatus.jobClass.GetAllDatas())
  696. {
  697. hashSet.Add(keyValuePair.Key);
  698. }
  699. HashSet<int> hashSet2 = new HashSet<int>();
  700. foreach (JobClass.Data data2 in this.m_maidStatus.jobClass.GetLearnPossibleClassDatas(false, classTypeFlags))
  701. {
  702. if (GameMain.Instance.CharacterMgr.status.IsJobClassOpenFlag(data2.id))
  703. {
  704. hashSet2.Add(data2.id);
  705. }
  706. }
  707. HashSet<int> hashSet3 = new HashSet<int>();
  708. foreach (int item in hashSet)
  709. {
  710. if (!hashSet2.Contains(item))
  711. {
  712. hashSet3.Add(item);
  713. }
  714. }
  715. HashSet<int> hashSet4 = new HashSet<int>();
  716. foreach (int item2 in hashSet2)
  717. {
  718. if (!hashSet.Contains(item2))
  719. {
  720. hashSet4.Add(item2);
  721. }
  722. }
  723. foreach (int id2 in hashSet3)
  724. {
  725. this.m_maidStatus.jobClass.Remove(id2, true);
  726. }
  727. int num = -1;
  728. foreach (int num2 in hashSet4)
  729. {
  730. this.m_maidStatus.jobClass.Add(num2, false, true);
  731. num = ((num >= num2) ? num : num2);
  732. }
  733. if (num != -1)
  734. {
  735. this.m_maidStatus.ChangeJobClass(num);
  736. }
  737. if (updateYotogiSkill)
  738. {
  739. this.m_maidStatus.yotogiSkill.Clear();
  740. List<Skill.Data> learnPossibleSkills = Skill.GetLearnPossibleSkills(this.m_maidStatus);
  741. foreach (Skill.Data data3 in learnPossibleSkills)
  742. {
  743. this.m_maidStatus.yotogiSkill.Add(data3.id);
  744. }
  745. }
  746. this.m_maidStatus.UpdateClassBonusStatus();
  747. this.m_maidStatus.sexPlayNumberOfPeople = MaidProfile.UpdateInitPlayNumber(this.m_maidStatus.maid);
  748. }
  749. this.m_maidStatus.UpdateBodyParam();
  750. this.m_maidStatus.profileComment = MaidProfile.Create(this.m_maidStatus.maid, !this.m_enabledInput);
  751. }
  752. private Status m_maidStatus;
  753. private ProfileCtrl.ProfileAttribute m_profileAttribute;
  754. private GameObject m_goProfilePanel;
  755. private GameObject m_goProfileComment;
  756. private GameObject m_goFreeComment;
  757. private GameObject m_goProfileTabSelector;
  758. private GameObject m_goFreeTabSelector;
  759. private GameObject m_goProfileLabelUnitPrefab;
  760. private GameObject m_goYotogiSkillUnitPrefab;
  761. private GameObject m_goMaidPointTitleAndFrame;
  762. private GameObject m_goMaidSkillParent;
  763. private GameObject m_goCharacterParent;
  764. private GameObject m_goPropensityParent;
  765. private GameObject m_goYotogiSkillParent;
  766. private GameObject m_goErogenousZoneParent;
  767. private GameObject m_goMaidSkillViewer;
  768. private GameObject m_goCharacterViewer;
  769. private GameObject m_goPropensityViewer;
  770. private GameObject m_goYotogiSkillViewer;
  771. private GameObject m_goPersonalSelectorIcon;
  772. private GameObject m_goSexualExperienceSelectorIcon;
  773. private UIScrollView m_maidSkillScrollView;
  774. private UIScrollView m_characterScrollView;
  775. private UIScrollView m_propensityScrollView;
  776. private UIScrollView m_yotogiSkillScrollView;
  777. private UIScrollView m_attributeScrollView;
  778. private UILabel m_lContractType;
  779. private UILabel m_lMaidClassName;
  780. private UILabel m_lMaidClassLevel;
  781. private UILabel m_lMaidClassExp;
  782. private UILabel m_lMaidClassRequiredExp;
  783. private UILabel m_lYotogiClassName;
  784. private UILabel m_lYotogiClassLevel;
  785. private UILabel m_lYotogiClassExp;
  786. private UILabel m_lYotogiClassRequiredExp;
  787. private UILabel m_lHeight;
  788. private UILabel m_lWeight;
  789. private UILabel m_lBust;
  790. private UILabel m_lCup;
  791. private UILabel m_lWaist;
  792. private UILabel m_lHip;
  793. private UILabel m_lRelation;
  794. private UILabel m_lConditionText;
  795. private UILabel m_lYotogiPlayCount;
  796. private UILabel m_lOthersPlayCount;
  797. private UILabel m_lHp;
  798. private UILabel m_lLikability;
  799. private UILabel m_lMind;
  800. private UILabel m_lReception;
  801. private UILabel m_lCare;
  802. private UILabel m_lStudyRate;
  803. private UILabel m_lTeachRate;
  804. private UILabel m_lCooking;
  805. private UILabel m_lDance;
  806. private UILabel m_lVocal;
  807. private UILabel m_lLovely;
  808. private UILabel m_lElegance;
  809. private UILabel m_lCharm;
  810. private UILabel m_lInran;
  811. private UILabel m_lMValue;
  812. private UILabel m_lHentai;
  813. private UILabel m_lHousi;
  814. private UILabel m_lMaidPoint;
  815. private UILabel m_lProfileComment;
  816. private UIInput m_inFreeComment;
  817. private UIInput m_inFirstName;
  818. private UIInput m_inLastName;
  819. private UIButton m_buFirstName;
  820. private UIButton m_buLastName;
  821. private UIPopupList m_pPersonal;
  822. private UILabel m_lPersonal;
  823. private UIPopupList m_pSexualExperience;
  824. private UIButton m_bProfileTab;
  825. private UIButton m_bFreeTab;
  826. private BoxCollider m_clFirstName;
  827. private BoxCollider m_clLastName;
  828. private BoxCollider m_clPersonal;
  829. private BoxCollider m_clSexualExperience;
  830. private static Dictionary<string, Personal.Data> m_dicPersonal;
  831. private static Dictionary<string, Seikeiken> m_dicSexualExperience;
  832. private Dictionary<ProfileMgr.UpperButtonType, GameObject> m_dicSubViewer;
  833. private Dictionary<ProfileMgr.UpperButtonType, ProfileCtrl.UpperButton> m_dicUpperBtn;
  834. private Dictionary<string, ProfileCtrl.ProfileLabelUnit> m_dicProfileLabel;
  835. private Dictionary<string, ProfileCtrl.ProfileYotogiSkillUnit> m_dicYotogiSkill;
  836. private Dictionary<ProfileCtrl.LevelOfAchievement, string> m_dicSpriteName;
  837. private bool m_bInited;
  838. private Color activeColor;
  839. private Color inActiveColor;
  840. private const int MAX_NAME_LENGTH = 8;
  841. private const int MAX_FREE_COMMENT_LENGTH = 304;
  842. private const int MAX_EROGENOUSZONE_UNIT = 7;
  843. private const int MAX_ATTRIBUTE_UNIT = 10;
  844. private const int DENOMINATOR = 10;
  845. private const string MAID_SKILL_UNIT_PARENT_PATH = "SubWindows/MaidSkillViewer/Contents/MaidSkillUnitParent";
  846. private const string CHARACTER_UNIT_PARENT_PATH = "SubWindows/CharacterViewer/Contents/CharacterUnitParent";
  847. private const string PROPENSITY_UNIT_PARENT_PATH = "SubWindows/PropensityViewer/Contents/CharacterUnitParent";
  848. private const string YOTOGI_SKILL_UNIT_PARENT_PATH = "SubWindows/YotogiSkillViewer/Contents/YotogiSkillUnitParent";
  849. private const string ATTRIBUTE_UNIT_PARENT_PATH = "SubWindows/AttributeViewer/Contents/Attribute/AttributeUnitParent";
  850. private const string EROGENOUS_ZONE_UNIT_PARENT_PATH = "SubWindows/AttributeViewer/Contents/ErogenousZone/ErogenousZoneParent";
  851. private const string PROFILE_LABEL_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/ProfileLabelUnit";
  852. private const string PROFILE_YOTOGI_SKILL_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/YotogiSkillUnit";
  853. private const string PROFILE_ATTRIBUTE_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/AttributeUnit";
  854. private const string PROFILE_EROGENOUS_ZONE_UNIT_PREFAB_PATH = "SceneEdit/Profile/Prefab/ErogenousZoneUnit";
  855. private float initMaidPointUIPosX;
  856. public enum LevelOfAchievement
  857. {
  858. level_1,
  859. level_2,
  860. level_3,
  861. level_4
  862. }
  863. private class UpperButton
  864. {
  865. public ProfileMgr.UpperButtonType m_name;
  866. public GameObject m_goSelectCursor;
  867. public UIButton m_btnButton;
  868. }
  869. public class ProfileLabelUnit
  870. {
  871. public string m_id;
  872. public string m_parameter;
  873. }
  874. public class ProfileYotogiSkillUnit
  875. {
  876. public string m_id;
  877. public string m_number;
  878. public string m_skillName;
  879. public ProfileCtrl.LevelOfAchievement m_levelOfAchievement;
  880. }
  881. public class ProfileAttribute
  882. {
  883. public ProfileAttribute()
  884. {
  885. this.m_listAttributeUnitName = new List<string>();
  886. }
  887. public List<string> m_listAttributeUnitName;
  888. }
  889. public class ErogenousZoneUnit
  890. {
  891. public string m_category;
  892. public int m_PercentNumber;
  893. }
  894. }