ScriptManager.cs 97 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142
  1. using System;
  2. using System.Collections.Generic;
  3. using System.IO;
  4. using System.Runtime.CompilerServices;
  5. using System.Text;
  6. using Kasizuki;
  7. using MaidStatus;
  8. using MaidStatus.CsvData;
  9. using MaidStatus.Old;
  10. using PlayerStatus;
  11. using Schedule;
  12. using UnityEngine;
  13. using wf;
  14. public class ScriptManager : IDisposable
  15. {
  16. public static string ReplaceCharaName(string text)
  17. {
  18. if (string.IsNullOrEmpty(text))
  19. {
  20. return text;
  21. }
  22. string[] array = new string[]
  23. {
  24. "[HF]",
  25. "[HF1]",
  26. "[HF2]",
  27. "[HF3]",
  28. "[HF4]"
  29. };
  30. string[] array2 = new string[]
  31. {
  32. "[HL]",
  33. "[HL1]",
  34. "[HL2]",
  35. "[HL3]",
  36. "[HL4]"
  37. };
  38. string[] array3 = new string[]
  39. {
  40. "[HLF]",
  41. "[HLF1]",
  42. "[HLF2]",
  43. "[HLF3]",
  44. "[HLF4]"
  45. };
  46. for (int i = 0; i < array.Length; i++)
  47. {
  48. for (int j = 0; j < 2; j++)
  49. {
  50. string text2 = (j != 0) ? "[HF]" : "[hf]";
  51. string text3 = (j != 0) ? array[i].ToUpper() : array[i].ToLower();
  52. if (0 <= text.IndexOf(text3))
  53. {
  54. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(i);
  55. if (maid != null)
  56. {
  57. if (text3 != text2)
  58. {
  59. text = text.Replace(text3, text2);
  60. }
  61. text = text.Replace(text2, (!maid.status.isFirstNameCall) ? maid.status.lastName : maid.status.firstName);
  62. }
  63. }
  64. text2 = ((j != 0) ? "[HL]" : "[hl]");
  65. text3 = ((j != 0) ? array2[i].ToUpper() : array2[i].ToLower());
  66. if (0 <= text.IndexOf(text3))
  67. {
  68. Maid maid2 = GameMain.Instance.CharacterMgr.GetMaid(i);
  69. if (maid2 != null)
  70. {
  71. if (text3 != text2)
  72. {
  73. text = text.Replace(text3, text2);
  74. }
  75. text = text.Replace(text2, maid2.status.lastName);
  76. }
  77. }
  78. text2 = ((j != 0) ? "[HLF]" : "[hlf]");
  79. text3 = ((j != 0) ? array3[i].ToUpper() : array3[i].ToLower());
  80. if (0 <= text.IndexOf(text3))
  81. {
  82. Maid maid3 = GameMain.Instance.CharacterMgr.GetMaid(i);
  83. if (maid3 != null)
  84. {
  85. if (text3 != text2)
  86. {
  87. text = text.Replace(text3, text2);
  88. }
  89. text = text.Replace(text2, maid3.status.fullNameJpStyle);
  90. }
  91. }
  92. }
  93. }
  94. if (0 <= text.IndexOf("[SF]"))
  95. {
  96. text = text.Replace("[SF]", GameMain.Instance.CharacterMgr.status.playerName);
  97. }
  98. if (0 <= text.IndexOf("[sf]"))
  99. {
  100. text = text.Replace("[sf]", GameMain.Instance.CharacterMgr.status.playerName);
  101. }
  102. return text;
  103. }
  104. public static string ReplaceCharaName(Maid maid, string text)
  105. {
  106. if (text == null)
  107. {
  108. return string.Empty;
  109. }
  110. if (maid == null)
  111. {
  112. maid = GameMain.Instance.CharacterMgr.GetMaid(0);
  113. }
  114. if (maid == null)
  115. {
  116. return text;
  117. }
  118. if (0 <= text.IndexOf("[HF]"))
  119. {
  120. if (maid.status.isFirstNameCall)
  121. {
  122. text = text.Replace("[HF]", maid.status.firstName);
  123. }
  124. else
  125. {
  126. text = text.Replace("[HF]", maid.status.lastName);
  127. }
  128. }
  129. if (0 <= text.IndexOf("[HL]"))
  130. {
  131. text = text.Replace("[HL]", maid.status.lastName);
  132. }
  133. if (0 <= text.IndexOf("[SF]"))
  134. {
  135. text = text.Replace("[SF]", GameMain.Instance.CharacterMgr.status.playerName);
  136. }
  137. return text;
  138. }
  139. public static string ReplacePersonal(Maid maid, string text)
  140. {
  141. return ScriptManager.ReplacePersonal(new Maid[]
  142. {
  143. maid
  144. }, text);
  145. }
  146. public static string ReplacePersonal(Maid[] maid_array, string text)
  147. {
  148. if (string.IsNullOrEmpty(text))
  149. {
  150. return string.Empty;
  151. }
  152. Maid maid = null;
  153. string oldValue = string.Empty;
  154. if (0 <= text.IndexOf("?4"))
  155. {
  156. maid = maid_array[4];
  157. oldValue = "?4";
  158. }
  159. else if (0 <= text.IndexOf("?3"))
  160. {
  161. maid = maid_array[3];
  162. oldValue = "?3";
  163. }
  164. else if (0 <= text.IndexOf("?2"))
  165. {
  166. maid = maid_array[2];
  167. oldValue = "?2";
  168. }
  169. else if (0 <= text.IndexOf("?1"))
  170. {
  171. maid = maid_array[1];
  172. oldValue = "?1";
  173. }
  174. else if (0 <= text.IndexOf("?0"))
  175. {
  176. maid = maid_array[0];
  177. oldValue = "?0";
  178. }
  179. else if (0 <= text.IndexOf("?"))
  180. {
  181. maid = maid_array[0];
  182. oldValue = "?";
  183. }
  184. if (maid == null)
  185. {
  186. return text;
  187. }
  188. if (maid.status.subCharaData == null)
  189. {
  190. text = text.Replace(oldValue, maid.status.personal.replaceText);
  191. }
  192. else
  193. {
  194. text = text.Replace(oldValue, maid.status.subCharaData.replaceText);
  195. }
  196. return text;
  197. }
  198. public void Initialize()
  199. {
  200. this.is_motion_blend = true;
  201. GameObject gameObject = GameObject.Find("SystemUI Root/Manager_SystemUI/MessageWindowMgr");
  202. NDebug.Assert(gameObject != null, "MessageWindowMgrが見つかりません");
  203. this.message_mgr_ = gameObject.GetComponent<MessageWindowMgr>();
  204. NDebug.Assert(this.message_mgr_ != null, "コンポーネント:MessageWindowMgrが見つかりません");
  205. this.tjs_ = TJSScript.Create(this.file_system);
  206. this.tjs_.AddFunction("GetMaidMPN", new TJSScript.FunctionCallBack(this.TJSFuncGetMaidMPN));
  207. this.tjs_.AddFunction("GetMenuFileNameFromMaidMPN", new TJSScript.FunctionCallBack(this.TJSFuncGetMenuFileNameFromMaidMPN));
  208. this.tjs_.AddFunction("SetMaidFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetMaidFlag));
  209. this.tjs_.AddFunction("SetManFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetManFlag));
  210. this.tjs_.AddFunction("SetTmpFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetTmpFlag));
  211. this.tjs_.AddFunction("GetMaidFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetMaidFlag));
  212. this.tjs_.AddFunction("GetManFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetManFlag));
  213. this.tjs_.AddFunction("GetTmpFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetTmpFlag));
  214. this.tjs_.AddFunction("SetSystemFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetSystemFlag));
  215. this.tjs_.AddFunction("GetSystemFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetSystemFlag));
  216. this.tjs_.AddFunction("GetMaidStatus", new TJSScript.FunctionCallBack(this.TJSFuncGetMaidStatus));
  217. this.tjs_.AddFunction("SetMainCharaFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetMainCharaFlag));
  218. this.tjs_.AddFunction("IsSeikantai", new TJSScript.FunctionCallBack(this.OldTJSFuncConIsSeikantai));
  219. this.tjs_.AddFunction("CreateNewMaid", new TJSScript.FunctionCallBack(this.TJSFuncCreateNewMaid));
  220. this.tjs_.AddFunction("PresetLoad", new TJSScript.FunctionCallBack(this.TJSFuncPresetLoad));
  221. this.tjs_.AddFunction("PresetLoadNPC", new TJSScript.FunctionCallBack(this.TJSFuncPresetLoadNPC));
  222. this.tjs_.AddFunction("AddMaidStatus", new TJSScript.FunctionCallBack(this.TJSFuncAddMaidStatus));
  223. this.tjs_.AddFunction("IsMaidFeature", new TJSScript.FunctionCallBack(this.TJSFuncIsMaidFeature));
  224. this.tjs_.AddFunction("IsMaidPropensity", new TJSScript.FunctionCallBack(this.TJSFuncIsMaidPropensity));
  225. this.tjs_.AddFunction("GetYotogiSkillLevel", new TJSScript.FunctionCallBack(this.TJSFuncGetYotogiSkillLevel));
  226. this.tjs_.AddFunction("IsYotogiSkill", new TJSScript.FunctionCallBack(this.TJSFuncIsYotogiSkill));
  227. this.tjs_.AddFunction("GetStockMaidCount", new TJSScript.FunctionCallBack(this.TJSFuncGetStockMaidCount));
  228. this.tjs_.AddFunction("SetSalonGrade", new TJSScript.FunctionCallBack(this.TJSFuncSetSalonGrade));
  229. this.tjs_.AddFunction("GetSalonGrade", new TJSScript.FunctionCallBack(this.TJSFuncGetSalonGrade));
  230. this.tjs_.AddFunction("GetClubEvaluation", new TJSScript.FunctionCallBack(this.TJSFuncGetClubEvaluation));
  231. this.tjs_.AddFunction("SetClubGauge", new TJSScript.FunctionCallBack(this.TJSFuncSetClubGauge));
  232. this.tjs_.AddFunction("GetClubGauge", new TJSScript.FunctionCallBack(this.TJSFuncGetClubGauge));
  233. this.tjs_.AddFunction("GetBGName", new TJSScript.FunctionCallBack(this.TJSFuncGetBGName));
  234. this.tjs_.AddFunction("IsItemParam", new TJSScript.FunctionCallBack(this.TJSFuncIsItemParam));
  235. this.tjs_.AddFunction("IsItemSlot", new TJSScript.FunctionCallBack(this.TJSFuncIsItemSlot));
  236. this.tjs_.AddFunction("IsMaidClass", new TJSScript.FunctionCallBack(this.OldTJSFuncIsMaidClass));
  237. this.tjs_.AddFunction("GetMaidClassLevel", new TJSScript.FunctionCallBack(this.OldTJSFuncGetMaidClassLevel));
  238. this.tjs_.AddFunction("IsJobMaid", new TJSScript.FunctionCallBack(this.TJSFuncIsJobMaid));
  239. this.tjs_.AddFunction("GetJobMaidLevel", new TJSScript.FunctionCallBack(this.TJSFuncGetJobMaidLevel));
  240. this.tjs_.AddFunction("IsYotogiClass", new TJSScript.FunctionCallBack(this.TJSFuncIsYotogiClass));
  241. this.tjs_.AddFunction("GetYotogiClassLevel", new TJSScript.FunctionCallBack(this.TJSFuncGetYotogiClassLevel));
  242. this.tjs_.AddFunction("GetNoonScuccessLevel", new TJSScript.FunctionCallBack(this.TJSFuncGetNoonScuccessLevel));
  243. this.tjs_.AddFunction("IsMaid", new TJSScript.FunctionCallBack(this.TJSFuncIsMaid));
  244. this.tjs_.AddFunction("IsOldPersonal", new TJSScript.FunctionCallBack(this.TJSFuncIsOldPersonal));
  245. this.tjs_.AddFunction("GetSalonLoan", new TJSScript.FunctionCallBack(this.TJSFuncConGetSalonLoan));
  246. this.tjs_.AddFunction("GetPhase", new TJSScript.FunctionCallBack(this.TJSFuncConGetPhase));
  247. this.tjs_.AddFunction("GetDay", new TJSScript.FunctionCallBack(this.TJSFuncGetDay));
  248. this.tjs_.AddFunction("CreateStockMaidLoopData", new TJSScript.FunctionCallBack(this.TJSFuncCreateStockMaidLoopData));
  249. this.tjs_.AddFunction("CreateCompetitiveShowLoopData", new TJSScript.FunctionCallBack(this.TJSFuncCreateCompetitiveShowLoopData));
  250. this.tjs_.AddFunction("GetCompetitiveShowLoopCount", new TJSScript.FunctionCallBack(this.TJSFuncGetCompetitiveShowLoopCount));
  251. this.tjs_.AddFunction("SetActiveSlotFromStockMaidLoopData", new TJSScript.FunctionCallBack(this.TJSFuncSetActiveSlotFromStockMaidLoopData));
  252. this.tjs_.AddFunction("SetMaidCondition", new TJSScript.FunctionCallBack(this.TJSFuncSetMaidCondition));
  253. this.tjs_.AddFunction("SetSeikeikenFront", new TJSScript.FunctionCallBack(this.TJSFuncSetSeikeikenFront));
  254. this.tjs_.AddFunction("SetSeikeikenBack", new TJSScript.FunctionCallBack(this.TJSFuncSetSeikeikenBack));
  255. this.tjs_.AddFunction("SetInitSeikeiken", new TJSScript.FunctionCallBack(this.TJSFuncSetInitSeikeiken));
  256. this.tjs_.AddFunction("SetNewItem", new TJSScript.FunctionCallBack(this.TJSFuncSetNewItem));
  257. this.tjs_.AddFunction("IsGameInShopItemPurchased", new TJSScript.FunctionCallBack(this.TJSFuncIsGameInShopItemPurchased));
  258. this.tjs_.AddFunction("SetContractType", new TJSScript.FunctionCallBack(this.TJSFuncSetContractType));
  259. this.tjs_.AddFunction("SetFeature", new TJSScript.FunctionCallBack(this.TJSFuncSetFeature));
  260. this.tjs_.AddFunction("SetPropensity", new TJSScript.FunctionCallBack(this.TJSFuncSetPropensity));
  261. this.tjs_.AddFunction("SetSexualParam", new TJSScript.FunctionCallBack(this.TJSFuncComSetSexualParam));
  262. this.tjs_.AddFunction("SetNewTrophy", new TJSScript.FunctionCallBack(this.TJSFuncSetNewTrophy));
  263. this.tjs_.AddFunction("CheckTrophyContractType", new TJSScript.FunctionCallBack(this.TJSFuncCheckTrophyContractType));
  264. this.tjs_.AddFunction("SetYotogiSelectStageName", new TJSScript.FunctionCallBack(this.TJSFuncSetYotogiSelectStageName));
  265. this.tjs_.AddFunction("GetYotogiSelectStageName", new TJSScript.FunctionCallBack(this.TJSFuncGetYotogiSelectStageName));
  266. this.tjs_.AddFunction("ClearCallStack", new TJSScript.FunctionCallBack(this.TJSFuncClearCallStack));
  267. this.tjs_.AddFunction("IsCommunicationChara", new TJSScript.FunctionCallBack(this.OldTJSFuncIsCommunicationChara));
  268. this.tjs_.AddFunction("SetCommunicationChara", new TJSScript.FunctionCallBack(this.TJSFuncSetCommunicationChara));
  269. this.tjs_.AddFunction("SetRandomCommuChara", new TJSScript.FunctionCallBack(this.TJSFuncSetRandomCommuChara));
  270. this.tjs_.AddFunction("CreateYotogiCharaList", new TJSScript.FunctionCallBack(this.TJSFuncCreateYotogiCharaList));
  271. this.tjs_.AddFunction("CreateNewYotogiCharaList", new TJSScript.FunctionCallBack(this.TJSFuncCreateNewYotogiCharaList));
  272. this.tjs_.AddFunction("CreateNewYotogiHaremPairCharaList", new TJSScript.FunctionCallBack(this.TJSFuncCreateNewYotogiHaremPairCharaList));
  273. this.tjs_.AddFunction("CreateVipCharaList", new TJSScript.FunctionCallBack(this.TJSFuncCreateVipCharaList));
  274. this.tjs_.AddFunction("CreateFacilityCharaList", new TJSScript.FunctionCallBack(this.TJSFuncCreateFacilityCharaList));
  275. this.tjs_.AddFunction("IsReceptionChara", new TJSScript.FunctionCallBack(this.TJSFuncIsReceptionChara));
  276. this.tjs_.AddFunction("SetRandomReceptionChara", new TJSScript.FunctionCallBack(this.TJSFuncSetRandomReceptionChara));
  277. this.tjs_.AddFunction("IsSelectChara", new TJSScript.FunctionCallBack(this.TJSFuncIsSelectChara));
  278. this.tjs_.AddFunction("GetDateYear", new TJSScript.FunctionCallBack(this.TJSFuncGetDateYear));
  279. this.tjs_.AddFunction("GetDateMonth", new TJSScript.FunctionCallBack(this.TJSFuncGetDateMonth));
  280. this.tjs_.AddFunction("GetDateDay", new TJSScript.FunctionCallBack(this.TJSFuncGetDateDay));
  281. this.tjs_.AddFunction("UpdateMaidRanking", new TJSScript.FunctionCallBack(this.TJSFuncUpdateMaidRanking));
  282. this.tjs_.AddFunction("ResetMaidRanking", new TJSScript.FunctionCallBack(this.TJSFuncResetMaidRanking));
  283. this.tjs_.AddFunction("SetMaidRanking1st", new TJSScript.FunctionCallBack(this.TJSFuncSetMaidRanking1st));
  284. this.tjs_.AddFunction("IsAvailableRanking", new TJSScript.FunctionCallBack(this.TJSFuncIsAvailableRanking));
  285. this.tjs_.AddFunction("IsMVPEvent", new TJSScript.FunctionCallBack(this.TJSFuncIsMVPEvent));
  286. this.tjs_.AddFunction("IsYotogiSubCharaSelect", new TJSScript.FunctionCallBack(this.TJSFuncIsYotogiSubCharaSelect));
  287. this.tjs_.AddFunction("GetYotogiSkillSpecialType", new TJSScript.FunctionCallBack(this.TJSFuncGetYotogiSkillSpecialType));
  288. this.tjs_.AddFunction("IsSelectedYotogiSkill", new TJSScript.FunctionCallBack(this.TJSFuncIsSelectedYotogiSkill));
  289. this.tjs_.AddFunction("IsExistentFile", new TJSScript.FunctionCallBack(this.TJSFuncIsExistentFile));
  290. this.tjs_.AddFunction("IsExistentFileLegacy", new TJSScript.FunctionCallBack(this.TJSFuncIsExistentFileLegacy));
  291. this.tjs_.AddFunction("CheckClearVIP", new TJSScript.FunctionCallBack(this.TJSFuncCheckClearVIP));
  292. this.tjs_.AddFunction("IsCBLVersion", new TJSScript.FunctionCallBack(this.TJSFuncIsCBLVersion));
  293. this.tjs_.AddFunction("GetRentalNPCName", new TJSScript.FunctionCallBack(this.OldTJSFuncGetRentalNPCName));
  294. this.tjs_.AddFunction("IsMarriage", new TJSScript.FunctionCallBack(this.OldTJSFuncIsMarriage));
  295. this.tjs_.AddFunction("IsNewWifeFlag", new TJSScript.FunctionCallBack(this.OldTJSFuncIsNewWifeFlag));
  296. this.tjs_.AddFunction("IsPluginPack", new TJSScript.FunctionCallBack(this.TJSFuncIsPluginPack));
  297. this.tjs_.AddFunction("AddShopLineup", new TJSScript.FunctionCallBack(this.TJSFuncAddShopLineup));
  298. this.tjs_.AddFunction("SetEventItemFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetEventItemFlag));
  299. this.tjs_.AddFunction("IsEventItemFlag", new TJSScript.FunctionCallBack(this.TJSFuncIsEventItemFlag));
  300. this.tjs_.AddFunction("GetVRMode", new TJSScript.FunctionCallBack(this.TJSFuncGetVRMode));
  301. this.tjs_.AddFunction("IsVRMode", new TJSScript.FunctionCallBack(this.TJSFuncIsVRMode));
  302. this.tjs_.AddFunction("SetDanceData", new TJSScript.FunctionCallBack(this.TJSFuncSetDanceData));
  303. this.tjs_.AddFunction("GetEventAdded", new TJSScript.FunctionCallBack(this.TJSFuncGetEventAdded));
  304. this.tjs_.AddFunction("GetLockNTRPlayFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetLockNTRPlayFlag));
  305. this.tjs_.AddFunction("GetLockUserDraftMaid", new TJSScript.FunctionCallBack(this.TJSFuncGetLockUserDraftMaid));
  306. this.tjs_.AddFunction("IsComPlayer", new TJSScript.FunctionCallBack(this.TJSFuncIsComPlayer));
  307. this.tjs_.AddFunction("SetPlayerMoney", new TJSScript.FunctionCallBack(this.TJSFuncSetPlayerMoney));
  308. this.tjs_.AddFunction("GetPlayerMoney", new TJSScript.FunctionCallBack(this.TJSFuncGetPlayerMoney));
  309. this.tjs_.AddFunction("SetMaidLeader", new TJSScript.FunctionCallBack(this.TJSFuncSetMaidLeader));
  310. this.tjs_.AddFunction("SetMaidCostumeFacility", new TJSScript.FunctionCallBack(this.TJSFuncSetMaidCostumeFacility));
  311. this.tjs_.AddFunction("ResetMaidCostumeFacility", new TJSScript.FunctionCallBack(this.TJSFuncResetMaidCostumeFacility));
  312. this.tjs_.AddFunction("CallTitleBar", new TJSScript.FunctionCallBack(this.TJSFuncCallTitleBar));
  313. this.tjs_.AddFunction("SetCompatibilityMode", new TJSScript.FunctionCallBack(this.TJSFuncSetCompatibilityMode));
  314. this.tjs.AddFunction("IsBuildingFacility", new TJSScript.FunctionCallBack(this.TJSFuncIsBuildingFacility));
  315. this.tjs.AddFunction("IsBuildingFacilityUpward", new TJSScript.FunctionCallBack(this.TJSFuncIsBuildingFacilityUpward));
  316. this.tjs.AddFunction("CheckDanceType", new TJSScript.FunctionCallBack(this.TJSCheckDanceType));
  317. this.tjs.AddFunction("SetMusicRelease", new TJSScript.FunctionCallBack(this.TJSSetMusicRelease));
  318. this.tjs.AddFunction("GetChallengeRank", new TJSScript.FunctionCallBack(this.TJSGetChallengeRank));
  319. this.tjs.AddFunction("SetVsSetting", new TJSScript.FunctionCallBack(this.TJSSetVsSetting));
  320. this.tjs.AddFunction("NeedDanceResult", new TJSScript.FunctionCallBack(this.TJSNeedDanceResult));
  321. this.tjs.AddFunction("BjDayFirst", new TJSScript.FunctionCallBack(this.TJSBjDayFirst));
  322. this.tjs.AddFunction("CasinoShopBuy", new TJSScript.FunctionCallBack(this.TJSCasinoShopBuy));
  323. this.tjs.AddFunction("SetEventEndFlag", new TJSScript.FunctionCallBack(this.TJSSetEventEndFlag));
  324. this.tjs_.AddFunction("IsKasizukiGuest", new TJSScript.FunctionCallBack(this.TJSFuncIsKasizukiGuest));
  325. this.tjs_.AddFunction("GetKasizukiSelectRoomName", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiSelectRoomName));
  326. this.tjs_.AddFunction("GetKasizukiMaidLikability", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiMaidLikability));
  327. this.tjs_.AddFunction("GetKasizukiMaidLikabilityName", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiMaidLikabilityName));
  328. this.tjs_.AddFunction("GetKasizukiMaidWorkCount", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiMaidWorkCount));
  329. this.tjs_.AddFunction("GetKasizukiMaidWorkCountName", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiMaidWorkCountName));
  330. this.tjs_.AddFunction("GetKasizukiSystemFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiSystemFlag));
  331. this.tjs_.AddFunction("SetKasizukiSystemFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetKasizukiSystemFlag));
  332. this.tjs_.AddFunction("AddKasizukiSystemFlag", new TJSScript.FunctionCallBack(this.TJSFuncAddKasizukiSystemFlag));
  333. this.tjs_.AddFunction("SetKasizukiPassFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetKasizukiPassFlag));
  334. this.tjs_.AddFunction("GetKasizukiMaidFlag", new TJSScript.FunctionCallBack(this.TJSFuncGetKasizukiMaidFlag));
  335. this.tjs_.AddFunction("SetKasizukiMaidFlag", new TJSScript.FunctionCallBack(this.TJSFuncSetKasizukiMaidFlag));
  336. this.tjs_.AddFunction("IsKasizukiCorrectSenarioFlag", new TJSScript.FunctionCallBack(this.TJSFuncIsKasizukiCorrectSenarioFlag));
  337. this.tjs_.AddFunction("IsVRKaraokeMode", new TJSScript.FunctionCallBack(this.TJSFuncIsVRKaraokeMode));
  338. this.tjs_.AddFunction("GetRemainingDanceTime", new TJSScript.FunctionCallBack(this.TJSFuncGetRemainingDanceTime));
  339. this.tjs.AddFunction("GetYotogiCommandClickCount", new TJSScript.FunctionCallBack(this.TJSFuncGetYotogiCommandClickCount));
  340. MotionKagManager motionKagManager = new MotionKagManager(this.tjs_, this);
  341. motionKagManager.Initialize();
  342. motionKagManager.SetSloatNo(0);
  343. this.kag_mot_dic_.Add(0, motionKagManager);
  344. this.adv_kag_ = new ADVKagManager(this.tjs_, this, this.message_mgr_);
  345. this.adv_kag_.Initialize();
  346. this.adv_kag_.kag.SetOnReturnFunction(new KagScript.OnReturnCallBack(this.OnReturnEvent));
  347. this.adv_kag_.kag.SetOnRReturnFunction(new KagScript.OnScenarioLoadCallBack(this.OnRReturnEvent));
  348. this.yotogi_kag_ = new YotogiKagManager(this.tjs_, this);
  349. this.yotogi_kag_.Initialize();
  350. this.tmp_kag_ = new BaseKagManager(this.tjs_, this);
  351. this.tmp_kag_.Initialize();
  352. using (AFileBase afileBase = this.file_system.FileOpen("startup.tjs"))
  353. {
  354. this.tjs_.ExecScript(afileBase);
  355. }
  356. }
  357. ~ScriptManager()
  358. {
  359. this.Dispose(false);
  360. }
  361. public void ClearCallStack()
  362. {
  363. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  364. {
  365. keyValuePair.Value.kag.ClearCallStack();
  366. }
  367. this.adv_kag_.kag.ClearCallStack();
  368. this.yotogi_kag_.kag.ClearCallStack();
  369. this.tmp_kag_.kag.ClearCallStack();
  370. }
  371. public void Update()
  372. {
  373. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  374. {
  375. keyValuePair.Value.Update();
  376. }
  377. this.adv_kag_.Update();
  378. this.yotogi_kag_.Update();
  379. this.tmp_kag_.Update();
  380. }
  381. public void ExecScript(string exec_str, ref TJSVariant result)
  382. {
  383. this.tjs_.ExecScript(exec_str, ref result);
  384. }
  385. public void ExecScript(string exec_str)
  386. {
  387. this.tjs_.ExecScript(exec_str);
  388. }
  389. public void ExecScriptFile(string file_name, ref TJSVariant result)
  390. {
  391. using (AFileBase afileBase = this.file_system.FileOpen(file_name))
  392. {
  393. NDebug.Assert(afileBase.IsValid(), "not found file.\n" + file_name);
  394. this.tjs_.ExecScript(afileBase, ref result);
  395. }
  396. }
  397. public void ExecScriptFile(string file_name)
  398. {
  399. using (AFileBase afileBase = this.file_system.FileOpen(file_name))
  400. {
  401. NDebug.Assert(afileBase.IsValid(), "not found file.\n" + file_name);
  402. this.tjs_.ExecScript(afileBase);
  403. }
  404. }
  405. public void EvalScript(string eval_str, TJSVariant result)
  406. {
  407. this.tjs_.EvalScript(eval_str, result);
  408. }
  409. public void EvalScript(string eval_str)
  410. {
  411. this.tjs_.EvalScript(eval_str);
  412. }
  413. public void EvalScriptFile(string file_name, TJSVariant result)
  414. {
  415. using (AFileBase afileBase = this.file_system.FileOpen(file_name))
  416. {
  417. NDebug.Assert(afileBase.IsValid(), "not found file.\n" + file_name);
  418. this.tjs_.EvalScript(afileBase, result);
  419. }
  420. }
  421. public void EvalScriptFile(string file_name)
  422. {
  423. using (AFileBase afileBase = this.file_system.FileOpen(file_name))
  424. {
  425. NDebug.Assert(afileBase.IsValid(), "not found file.\n" + file_name);
  426. this.tjs_.EvalScript(afileBase);
  427. }
  428. }
  429. public void LoadAdvScenarioScript(string file_name, string label_name = "")
  430. {
  431. this.adv_kag_.enabled = true;
  432. this.adv_kag_.LoadScriptFile(file_name, label_name);
  433. }
  434. public void LoadYotogiScript(string file_name, string label_name = "")
  435. {
  436. this.yotogi_kag_.enabled = true;
  437. this.yotogi_kag_.LoadScriptFile(file_name, string.Empty);
  438. this.yotogi_kag_.Exec();
  439. }
  440. public void LoadTempScript(string file_name, string label_name = "")
  441. {
  442. this.tmp_kag_.enabled = true;
  443. this.tmp_kag_.LoadScriptFile(file_name, label_name);
  444. }
  445. public void LoadMotionScript(int sloat, bool is_next, string file_name, string label_name = "", string maid_guid = "", string man_guid = "", bool face_fix = false, bool valid_pos = true)
  446. {
  447. if (!string.IsNullOrEmpty(maid_guid))
  448. {
  449. Maid x = null;
  450. for (int i = 0; i < GameMain.Instance.CharacterMgr.GetMaidCount(); i++)
  451. {
  452. Maid maid3 = GameMain.Instance.CharacterMgr.GetMaid(i);
  453. if (maid3 != null && maid3.status.guid == maid_guid)
  454. {
  455. x = maid3;
  456. break;
  457. }
  458. }
  459. if (x == null)
  460. {
  461. return;
  462. }
  463. }
  464. if (!string.IsNullOrEmpty(man_guid))
  465. {
  466. Maid x2 = null;
  467. for (int j = 0; j < GameMain.Instance.CharacterMgr.GetManCount(); j++)
  468. {
  469. Maid man = GameMain.Instance.CharacterMgr.GetMan(j);
  470. if (man != null && man.status.guid == man_guid)
  471. {
  472. x2 = man;
  473. break;
  474. }
  475. }
  476. if (x2 == null)
  477. {
  478. return;
  479. }
  480. }
  481. this.is_motion_all_prop_seq = false;
  482. this.motion_all_prop_seq_maid = null;
  483. MotionKagManager motionKagManager2;
  484. if (!this.kag_mot_dic_.ContainsKey(sloat))
  485. {
  486. MotionKagManager motionKagManager = new MotionKagManager(this.tjs_, this);
  487. motionKagManager.Initialize();
  488. motionKagManager.SetSloatNo(sloat);
  489. motionKagManager.kag.SetFileSystem(this.file_system);
  490. this.kag_mot_dic_.Add(sloat, motionKagManager);
  491. motionKagManager2 = motionKagManager;
  492. }
  493. else
  494. {
  495. motionKagManager2 = this.kag_mot_dic_[sloat];
  496. }
  497. Maid mainMaid = motionKagManager2.SetMainMaid(maid_guid);
  498. Maid maid2 = motionKagManager2.SetMainMan(man_guid);
  499. if (mainMaid == null && maid2 != null)
  500. {
  501. mainMaid = maid2;
  502. }
  503. motionKagManager2.valid_pos = valid_pos;
  504. motionKagManager2.enabled = true;
  505. motionKagManager2.ExecForcWaitEvent();
  506. motionKagManager2.LoadScriptFile(file_name, label_name);
  507. motionKagManager2.SetNextMotion(is_next);
  508. motionKagManager2.SetFaceFix(face_fix);
  509. Vector3 b = Vector3.zero;
  510. if (mainMaid != null)
  511. {
  512. b = mainMaid.transform.position;
  513. }
  514. motionKagManager2.Exec();
  515. if (mainMaid != null && motionKagManager2.maidOffsetSetList.Find((Maid maid) => maid == mainMaid) != null)
  516. {
  517. Vector3 b2 = mainMaid.transform.position - b;
  518. Quaternion rotation = mainMaid.transform.rotation;
  519. for (int k = 0; k < motionKagManager2.maidOffsetSetList.Count; k++)
  520. {
  521. motionKagManager2.maidOffsetSetList[k].transform.rotation = rotation;
  522. motionKagManager2.maidOffsetSetList[k].transform.position -= b2;
  523. }
  524. }
  525. }
  526. public void StopMotionScript()
  527. {
  528. this.ClearForcExecWaitEvent();
  529. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  530. {
  531. keyValuePair.Value.ClearMotion();
  532. keyValuePair.Value.enabled = false;
  533. }
  534. }
  535. public void ClearForcExecWaitEvent()
  536. {
  537. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  538. {
  539. keyValuePair.Value.ClearForcExecWaitEvent();
  540. }
  541. }
  542. private void TJSFuncGetMaidMPN(TJSVariantRef[] param, TJSVariantRef result)
  543. {
  544. NDebug.Assert(2 == param.Length, "GetMaidMPN args count error.");
  545. if (result == null)
  546. {
  547. return;
  548. }
  549. TJSVariantRef.Type[] array = new TJSVariantRef.Type[]
  550. {
  551. TJSVariantRef.Type.tvtInteger,
  552. TJSVariantRef.Type.tvtString
  553. };
  554. for (int i = 0; i < param.Length; i++)
  555. {
  556. NDebug.Assert(param[i].type == array[i], "TJSFuncGetMaidProp args[" + i + "] type error.");
  557. }
  558. int nMaidNo = param[0].AsInteger();
  559. string text = param[1].AsString();
  560. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  561. MPN mpn = (MPN)Enum.Parse(typeof(MPN), text);
  562. MaidProp prop = maid.GetProp(mpn);
  563. NDebug.Assert(prop != null, "[" + text + "] 指定MPNが不正です。");
  564. if (prop.type == 3)
  565. {
  566. result.SetString(prop.name);
  567. }
  568. else
  569. {
  570. result.SetInteger(prop.value);
  571. }
  572. }
  573. private void TJSFuncGetMenuFileNameFromMaidMPN(TJSVariantRef[] param, TJSVariantRef result)
  574. {
  575. NDebug.Assert(2 == param.Length, "GetMenuFileNameFromMaidMPN args count error.");
  576. if (result == null)
  577. {
  578. return;
  579. }
  580. TJSVariantRef.Type[] array = new TJSVariantRef.Type[]
  581. {
  582. TJSVariantRef.Type.tvtInteger,
  583. TJSVariantRef.Type.tvtString
  584. };
  585. for (int i = 0; i < param.Length; i++)
  586. {
  587. NDebug.Assert(param[i].type == array[i], "TJSFuncGetMaidProp args[" + i + "] type error.");
  588. }
  589. int nMaidNo = param[0].AsInteger();
  590. string text = param[1].AsString();
  591. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  592. MPN mpn = (MPN)Enum.Parse(typeof(MPN), text);
  593. MaidProp prop = maid.GetProp(mpn);
  594. NDebug.Assert(prop != null, "[" + text + "] 指定MPNが不正です。");
  595. if (prop.type == 3)
  596. {
  597. result.SetString(prop.strFileName.ToLower());
  598. }
  599. else
  600. {
  601. result.SetString(string.Empty);
  602. }
  603. }
  604. private void TJSFuncSetMaidFlag(TJSVariantRef[] param, TJSVariantRef result)
  605. {
  606. NDebug.Assert(param.Length == 2 || 3 == param.Length, "SetMaidFlag args count error.");
  607. int nMaidNo = 0;
  608. string flagName = string.Empty;
  609. int num;
  610. if (param.Length == 3)
  611. {
  612. nMaidNo = param[0].AsInteger();
  613. flagName = param[1].AsString();
  614. num = param[2].AsInteger();
  615. }
  616. else
  617. {
  618. flagName = param[0].AsString();
  619. num = param[1].AsInteger();
  620. }
  621. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  622. if (this.compatibilityMode || this.tjsLegacyMode)
  623. {
  624. maid.status.OldStatus.SetFlag(flagName, num);
  625. }
  626. else
  627. {
  628. maid.status.SetFlag(flagName, num);
  629. }
  630. if (result != null)
  631. {
  632. result.SetInteger(num);
  633. }
  634. }
  635. private void TJSFuncSetManFlag(TJSVariantRef[] param, TJSVariantRef result)
  636. {
  637. NDebug.Assert(param.Length == 2 || 3 == param.Length, "SetManFlag args count error.");
  638. string flagName = string.Empty;
  639. int value;
  640. if (param.Length == 3)
  641. {
  642. int num = param[0].AsInteger();
  643. flagName = param[1].AsString();
  644. value = param[2].AsInteger();
  645. }
  646. else
  647. {
  648. flagName = param[0].AsString();
  649. value = param[1].AsInteger();
  650. }
  651. if (!this.compatibilityMode)
  652. {
  653. GameMain.Instance.CharacterMgr.status.SetFlag(flagName, value);
  654. }
  655. }
  656. private void TJSFuncSetTmpFlag(TJSVariantRef[] param, TJSVariantRef result)
  657. {
  658. NDebug.Assert(2 == param.Length, "SetTmpFlag args count error.");
  659. string flag_name = string.Empty;
  660. flag_name = param[0].AsString();
  661. int num = param[1].AsInteger();
  662. GameMain.Instance.CMSystem.SetTmpGenericFlag(flag_name, num);
  663. if (result != null)
  664. {
  665. result.SetInteger(num);
  666. }
  667. }
  668. private void TJSFuncGetMaidFlag(TJSVariantRef[] param, TJSVariantRef result)
  669. {
  670. NDebug.Assert(param.Length == 1 || param.Length == 2 || 3 == param.Length, "GetMaidFlag args count error.");
  671. if (result == null)
  672. {
  673. return;
  674. }
  675. int nMaidNo = 0;
  676. string flagName = string.Empty;
  677. bool flag = false;
  678. if (param.Length == 3)
  679. {
  680. nMaidNo = param[0].AsInteger();
  681. flagName = param[1].AsString();
  682. if (param[2].AsBool())
  683. {
  684. flag = true;
  685. }
  686. }
  687. else if (param.Length == 2)
  688. {
  689. nMaidNo = param[0].AsInteger();
  690. flagName = param[1].AsString();
  691. }
  692. else
  693. {
  694. flagName = param[0].AsString();
  695. }
  696. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  697. if ((this.compatibilityMode || this.tjsLegacyMode) && !flag)
  698. {
  699. result.SetInteger(maid.status.OldStatus.GetFlag(flagName));
  700. }
  701. else
  702. {
  703. result.SetInteger(maid.status.GetFlag(flagName));
  704. }
  705. }
  706. private void TJSFuncGetManFlag(TJSVariantRef[] param, TJSVariantRef result)
  707. {
  708. NDebug.Assert(param.Length == 1 || 2 == param.Length, "GetManFlag args count error.");
  709. if (result == null)
  710. {
  711. return;
  712. }
  713. string flagName = string.Empty;
  714. if (param.Length == 2)
  715. {
  716. int num = param[0].AsInteger();
  717. flagName = param[1].AsString();
  718. }
  719. else
  720. {
  721. flagName = param[0].AsString();
  722. }
  723. result.SetInteger(GameMain.Instance.CharacterMgr.status.GetFlag(flagName));
  724. }
  725. private void TJSFuncGetTmpFlag(TJSVariantRef[] param, TJSVariantRef result)
  726. {
  727. NDebug.Assert(1 == param.Length, "GetTmpFlag args count error.");
  728. if (result == null)
  729. {
  730. return;
  731. }
  732. string flag_name = param[0].AsString();
  733. result.SetInteger(GameMain.Instance.CMSystem.GetTmpGenericFlag(flag_name));
  734. }
  735. private void TJSFuncSetSystemFlag(TJSVariantRef[] param, TJSVariantRef result)
  736. {
  737. NDebug.Assert(2 == param.Length, "SetSystemFlag args count error.");
  738. string f_strKey = string.Empty;
  739. f_strKey = param[0].AsString();
  740. int integer = param[1].AsInteger();
  741. GameMain.Instance.CMSystem.SetSystemVers(f_strKey, integer.ToString());
  742. if (result != null)
  743. {
  744. result.SetInteger(integer);
  745. }
  746. }
  747. private void TJSFuncGetSystemFlag(TJSVariantRef[] param, TJSVariantRef result)
  748. {
  749. NDebug.Assert(1 == param.Length, "GetSystemFlag args count error.");
  750. if (result == null)
  751. {
  752. return;
  753. }
  754. string f_strKey = param[0].AsString();
  755. string text = GameMain.Instance.CMSystem.GetSystemVers(f_strKey);
  756. if (string.IsNullOrEmpty(text))
  757. {
  758. text = "0";
  759. }
  760. result.SetInteger(int.Parse(text));
  761. }
  762. private void TJSFuncGetMaidStatus(TJSVariantRef[] tjs_param, TJSVariantRef result)
  763. {
  764. NDebug.Assert(2 == tjs_param.Length, "GetMaidStatus args count error.");
  765. if (result == null)
  766. {
  767. return;
  768. }
  769. int nMaidNo = tjs_param[0].AsInteger();
  770. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  771. MaidStatus.Status status = maid.status;
  772. string a = tjs_param[1].AsString();
  773. bool flag = this.compatibilityMode || this.tjsLegacyMode;
  774. if (flag && a == "状態")
  775. {
  776. a = "旧関係";
  777. }
  778. if (a == "性経験")
  779. {
  780. result.SetString(EnumConvert.GetString(status.seikeiken));
  781. }
  782. else if (a == "初期性経験")
  783. {
  784. result.SetString(EnumConvert.GetString(status.initSeikeiken));
  785. }
  786. else if (a == "性格")
  787. {
  788. result.SetString(status.personal.drawName);
  789. }
  790. else if (a == "契約タイプ")
  791. {
  792. result.SetString(EnumConvert.GetString(status.contract));
  793. }
  794. else if (a == "ヒロインタイプ")
  795. {
  796. result.SetString(EnumConvert.GetString(status.heroineType));
  797. }
  798. else if (a == "サブメイドユニークネーム")
  799. {
  800. if (status.subCharaData != null)
  801. {
  802. result.SetString(status.subCharaData.uniqueName);
  803. }
  804. else
  805. {
  806. result.SetString(string.Empty);
  807. }
  808. }
  809. else if (a == "ジョブメイド")
  810. {
  811. result.SetString(status.selectedJobClass.data.uniqueName);
  812. }
  813. else if (a == "夜伽クラス")
  814. {
  815. if (status.selectedJobClass.data.classType == AbstractClassData.ClassType.New)
  816. {
  817. result.SetString("Debut");
  818. }
  819. else
  820. {
  821. result.SetString(status.selectedYotogiClass.data.drawName);
  822. }
  823. }
  824. else if (a == "関係")
  825. {
  826. result.SetString(EnumConvert.GetString(status.relation));
  827. }
  828. else if (a == "旧関係")
  829. {
  830. if (status.OldStatus != null)
  831. {
  832. result.SetString(EnumConvert.GetString(status.OldStatus.relation));
  833. }
  834. else
  835. {
  836. result.SetString(EnumConvert.GetString(status.relation));
  837. }
  838. }
  839. else if (a == "カップ")
  840. {
  841. result.SetString(status.body.cup);
  842. }
  843. else if (a == "苗字")
  844. {
  845. result.SetString(status.lastName);
  846. }
  847. else if (a == "名前")
  848. {
  849. result.SetString(status.firstName);
  850. }
  851. else if (a == "身長")
  852. {
  853. result.SetInteger(status.body.height);
  854. }
  855. else if (a == "夜伽プレイ回数")
  856. {
  857. result.SetInteger(status.playCountYotogi);
  858. }
  859. else if (a == "接客プレイ回数")
  860. {
  861. result.SetInteger(status.playCountNightWork);
  862. }
  863. else if (a == "興奮値")
  864. {
  865. result.SetInteger(status.currentExcite);
  866. }
  867. else if (a == "好感度")
  868. {
  869. result.SetInteger(status.likability);
  870. if (flag && 300 <= status.likability)
  871. {
  872. result.SetInteger(299);
  873. }
  874. }
  875. else if (a == "習得率")
  876. {
  877. result.SetInteger(status.studyRate);
  878. }
  879. else if (a == "接待")
  880. {
  881. result.SetInteger(status.reception);
  882. }
  883. else if (a == "お世話")
  884. {
  885. result.SetInteger(status.care);
  886. }
  887. else if (a == "可憐")
  888. {
  889. result.SetInteger(status.lovely);
  890. }
  891. else if (a == "淫欲")
  892. {
  893. result.SetInteger(status.inyoku);
  894. }
  895. else if (a == "気品")
  896. {
  897. result.SetInteger(status.elegance);
  898. }
  899. else if (a == "M性")
  900. {
  901. result.SetInteger(status.mvalue);
  902. }
  903. else if (a == "魅惑")
  904. {
  905. result.SetInteger(status.charm);
  906. }
  907. else if (a == "変態")
  908. {
  909. result.SetInteger(status.hentai);
  910. }
  911. else if (a == "奉仕")
  912. {
  913. result.SetInteger(status.housi);
  914. }
  915. else if (a == "料理")
  916. {
  917. result.SetInteger(status.cooking);
  918. }
  919. else if (a == "ボーカル")
  920. {
  921. result.SetInteger(status.vocal);
  922. }
  923. else if (a == "ダンス")
  924. {
  925. result.SetInteger(status.dance);
  926. }
  927. else if (a == "アピール")
  928. {
  929. result.SetInteger(status.appealPoint);
  930. }
  931. else if (a == "指導")
  932. {
  933. result.SetInteger(status.teachRate);
  934. }
  935. else if (a == "経験人数")
  936. {
  937. result.SetInteger(status.sexPlayNumberOfPeople);
  938. }
  939. else if (a == "昼仕事ID")
  940. {
  941. result.SetInteger(status.noonWorkId);
  942. }
  943. else if (a == "夜仕事ID")
  944. {
  945. result.SetInteger(status.nightWorkId);
  946. }
  947. else if (a == "昼仕事レベル")
  948. {
  949. if (!status.workDatas.ContainsKey(status.noonWorkId))
  950. {
  951. result.SetInteger(1);
  952. }
  953. else
  954. {
  955. result.SetInteger(status.workDatas.Get(status.noonWorkId).level);
  956. }
  957. }
  958. else if (a == "夜仕事レベル")
  959. {
  960. if (!status.workDatas.ContainsKey(status.nightWorkId))
  961. {
  962. result.SetInteger(1);
  963. }
  964. else
  965. {
  966. result.SetInteger(status.workDatas.Get(status.nightWorkId).level);
  967. }
  968. }
  969. else if (a == "夜伽クラスレベル")
  970. {
  971. result.SetInteger(status.selectedYotogiClass.level);
  972. }
  973. else if (a == "ジョブメイドレベル")
  974. {
  975. result.SetInteger(status.selectedJobClass.level);
  976. }
  977. else if (flag)
  978. {
  979. if (a == "レンタルメイド")
  980. {
  981. result.SetInteger(0);
  982. }
  983. else if (a == "雇用中")
  984. {
  985. result.SetInteger(1);
  986. }
  987. else if (a == "特殊状態")
  988. {
  989. result.SetString(EnumConvert.GetString(status.OldStatus.condition));
  990. }
  991. else if (a == "欲求不満")
  992. {
  993. result.SetInteger(status.OldStatus.frustration);
  994. }
  995. else if (a == "淫乱ギャップ値")
  996. {
  997. result.SetInteger(status.inranGap);
  998. }
  999. else if (a == "M性ギャップ値")
  1000. {
  1001. result.SetInteger(status.mValueGap);
  1002. }
  1003. else if (a == "変態ギャップ値")
  1004. {
  1005. result.SetInteger(status.hentaiGap);
  1006. }
  1007. else if (a == "メイドクラス")
  1008. {
  1009. if (status.selectedJobClass.data.classType == AbstractClassData.ClassType.Old)
  1010. {
  1011. result.SetString(status.selectedJobClass.data.drawName);
  1012. }
  1013. else
  1014. {
  1015. result.SetString("ノービスメイド");
  1016. }
  1017. }
  1018. }
  1019. }
  1020. private void TJSFuncSetMainCharaFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1021. {
  1022. NDebug.Assert(2 == tjs_param.Length, "SetMainCharaFlag args count error.");
  1023. int nMaidNo = tjs_param[0].AsInteger();
  1024. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1025. if (maid == null)
  1026. {
  1027. Debug.LogError("SetMainCharaFlag error\nメイド[" + nMaidNo.ToString() + "]にはメイドはいません");
  1028. }
  1029. else
  1030. {
  1031. maid.status.mainChara = tjs_param[1].AsBool();
  1032. }
  1033. }
  1034. private void OldTJSFuncConIsSeikantai(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1035. {
  1036. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@IsSeikantaiがよばれました");
  1037. NDebug.Assert(2 == tjs_param.Length, "IsSeikantai args count error.");
  1038. if (result == null)
  1039. {
  1040. return;
  1041. }
  1042. int nMaidNo = tjs_param[0].AsInteger();
  1043. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1044. MaidStatus.Old.Status oldStatus = maid.status.OldStatus;
  1045. string text = tjs_param[1].AsString();
  1046. int num = 1000;
  1047. if (text == "口")
  1048. {
  1049. result.SetBool(num <= oldStatus.sexual.mouth);
  1050. }
  1051. else if (text == "喉")
  1052. {
  1053. result.SetBool(num <= oldStatus.sexual.throat);
  1054. }
  1055. else if (text == "乳首")
  1056. {
  1057. result.SetBool(num <= oldStatus.sexual.nipple);
  1058. }
  1059. else if (text == "前穴")
  1060. {
  1061. result.SetBool(num <= oldStatus.sexual.front);
  1062. }
  1063. else if (text == "後穴")
  1064. {
  1065. result.SetBool(num <= oldStatus.sexual.back);
  1066. }
  1067. else if (text == "クリ")
  1068. {
  1069. result.SetBool(num <= oldStatus.sexual.curi);
  1070. }
  1071. else
  1072. {
  1073. NDebug.Assert("IsSeikantai error.\n" + text, false);
  1074. }
  1075. }
  1076. private void TJSFuncCreateNewMaid(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1077. {
  1078. NDebug.Assert(1 == tjs_param.Length, "CreateNewMaid args count error.");
  1079. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1080. Maid maid = null;
  1081. string text = tjs_param[0].AsString();
  1082. if (!MaidStatus.Personal.Contains(text))
  1083. {
  1084. NDebug.Assert(SubMaid.Contains(text), "CreateNewMaidの指定名が間違っています[" + text + "]");
  1085. SubMaid.Data data = SubMaid.GetData(text);
  1086. GameMain.Instance.ScriptMgr.StopMotionScript();
  1087. bool flag = false;
  1088. for (int i = 0; i < GameMain.Instance.CharacterMgr.GetStockMaidCount(); i++)
  1089. {
  1090. Maid stockMaid = GameMain.Instance.CharacterMgr.GetStockMaid(i);
  1091. if (stockMaid != null && stockMaid.status.heroineType == HeroineType.Sub && stockMaid.status.subCharaData.id == data.id)
  1092. {
  1093. flag = true;
  1094. break;
  1095. }
  1096. }
  1097. if (!flag)
  1098. {
  1099. maid = characterMgr.AddStockMaid();
  1100. data.ApplyStatus(maid.status, characterMgr.status.lockUserDraftMaid);
  1101. data.ApplyPreset(maid, characterMgr.status.lockUserDraftMaid);
  1102. }
  1103. }
  1104. else
  1105. {
  1106. NDebug.Assert(MaidStatus.Personal.IsEnabled(text), "CreateNewMaidで指定された対象名[" + text + "]は有効状態ではありません");
  1107. MaidStatus.Personal.Data data2 = MaidStatus.Personal.GetData(text);
  1108. GameMain.Instance.ScriptMgr.StopMotionScript();
  1109. maid = characterMgr.AddStockMaid();
  1110. maid.status.SetPersonal(data2);
  1111. }
  1112. if (maid != null)
  1113. {
  1114. characterMgr.SetActiveMaid(maid, 0);
  1115. maid.Visible = true;
  1116. maid.AllProcPropSeqStart();
  1117. }
  1118. }
  1119. private void TJSFuncPresetLoad(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1120. {
  1121. NDebug.Assert(2 == tjs_param.Length, "PresetLoad args count error.");
  1122. int nMaidNo = tjs_param[0].AsInteger();
  1123. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1124. if (maid == null)
  1125. {
  1126. NDebug.Assert("PresetLoad\nmaid null.", false);
  1127. return;
  1128. }
  1129. byte[] array = null;
  1130. string text = tjs_param[1].AsString();
  1131. if (text == "pre_maid_secretary")
  1132. {
  1133. CharacterMgr.Preset f_prest = GameMain.Instance.CharacterMgr.PresetLoadFromResources(text);
  1134. GameMain.Instance.CharacterMgr.PresetSet(maid, f_prest);
  1135. }
  1136. else
  1137. {
  1138. if (this.file_system.IsExistentFile(text + ".preset"))
  1139. {
  1140. using (AFileBase afileBase = GameUty.FileOpen(text + ".preset", null))
  1141. {
  1142. if (afileBase != null && afileBase.IsValid())
  1143. {
  1144. array = afileBase.ReadAll();
  1145. }
  1146. }
  1147. }
  1148. if (array == null)
  1149. {
  1150. NDebug.Assert("PresetLoad\n[" + text + "] file not fund.", false);
  1151. return;
  1152. }
  1153. using (BinaryReader binaryReader = new BinaryReader(new MemoryStream(array), Encoding.UTF8))
  1154. {
  1155. CharacterMgr.Preset f_prest2 = GameMain.Instance.CharacterMgr.PresetLoad(binaryReader, text);
  1156. GameMain.Instance.CharacterMgr.PresetSet(maid, f_prest2);
  1157. }
  1158. array = null;
  1159. }
  1160. }
  1161. private void TJSFuncPresetLoadNPC(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1162. {
  1163. NDebug.Assert("未実装TJS関数[PresetLoadNPC]が呼ばれました", false);
  1164. }
  1165. private void TJSFuncAddMaidStatus(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1166. {
  1167. NDebug.Assert(3 == tjs_param.Length, "AddMaidStatus args count error.");
  1168. int nMaidNo = tjs_param[0].AsInteger();
  1169. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1170. MaidStatus.Status status = maid.status;
  1171. string a = tjs_param[1].AsString();
  1172. int num = tjs_param[2].AsInteger();
  1173. Action<int> action = null;
  1174. if (a == "夜伽プレイ回数")
  1175. {
  1176. maid.status.playCountNightWork += num;
  1177. }
  1178. else if (a == "接客プレイ回数")
  1179. {
  1180. maid.status.playCountNightWork += num;
  1181. }
  1182. else if (a == "好感度")
  1183. {
  1184. maid.status.likability += num;
  1185. }
  1186. else if (a == "習得率")
  1187. {
  1188. maid.status.studyRate += num;
  1189. }
  1190. else if (a == "接待")
  1191. {
  1192. maid.status.baseReception += num;
  1193. }
  1194. else if (a == "お世話")
  1195. {
  1196. maid.status.baseCare += num;
  1197. }
  1198. else if (a == "可憐")
  1199. {
  1200. maid.status.baseLovely += num;
  1201. }
  1202. else if (a == "気品")
  1203. {
  1204. maid.status.baseElegance += num;
  1205. }
  1206. else if (a == "魅惑")
  1207. {
  1208. maid.status.baseCharm += num;
  1209. }
  1210. else if (a == "淫欲")
  1211. {
  1212. maid.status.baseInyoku += num;
  1213. }
  1214. else if (a == "M性")
  1215. {
  1216. maid.status.baseMvalue += num;
  1217. }
  1218. else if (a == "変態")
  1219. {
  1220. maid.status.baseHentai += num;
  1221. }
  1222. else if (a == "奉仕")
  1223. {
  1224. maid.status.baseHousi += num;
  1225. }
  1226. else if (a == "指導")
  1227. {
  1228. maid.status.baseTeachRate += num;
  1229. }
  1230. else if (a == "経験人数")
  1231. {
  1232. maid.status.sexPlayNumberOfPeople += num;
  1233. }
  1234. if (action != null)
  1235. {
  1236. action(num);
  1237. }
  1238. }
  1239. private void TJSFuncIsMaidFeature(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1240. {
  1241. NDebug.Assert(2 == tjs_param.Length, "IsMaidFeature args count error.");
  1242. if (result == null)
  1243. {
  1244. return;
  1245. }
  1246. int nMaidNo = tjs_param[0].AsInteger();
  1247. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1248. MaidStatus.Status status = maid.status;
  1249. string uniqueName = tjs_param[1].AsString();
  1250. Feature.Data data = Feature.GetData(uniqueName);
  1251. result.SetInteger(Convert.ToInt32(status.features.ContainsKey(data.id)));
  1252. }
  1253. private void TJSFuncIsMaidPropensity(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1254. {
  1255. NDebug.Assert(2 == tjs_param.Length, "IsMaidPropensity args count error.");
  1256. if (result == null)
  1257. {
  1258. return;
  1259. }
  1260. int nMaidNo = tjs_param[0].AsInteger();
  1261. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1262. MaidStatus.Status status = maid.status;
  1263. string uniqueName = tjs_param[1].AsString();
  1264. Propensity.Data data = Propensity.GetData(uniqueName);
  1265. result.SetInteger(Convert.ToInt32(status.propensitys.ContainsKey(data.id)));
  1266. }
  1267. private void TJSFuncGetYotogiSkillLevel(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1268. {
  1269. NDebug.Assert(2 == tjs_param.Length, "GetYotogiSkillLevel args count error.");
  1270. if (result == null)
  1271. {
  1272. return;
  1273. }
  1274. int nMaidNo = tjs_param[0].AsInteger();
  1275. int skillId = tjs_param[1].AsInteger();
  1276. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1277. MaidStatus.Status status = maid.status;
  1278. result.SetInteger(0);
  1279. if (status.yotogiSkill.Contains(skillId))
  1280. {
  1281. YotogiSkillData yotogiSkillData = status.yotogiSkill.Get(skillId);
  1282. result.SetInteger(yotogiSkillData.level);
  1283. }
  1284. }
  1285. private void TJSFuncIsYotogiSkill(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1286. {
  1287. NDebug.Assert(2 == tjs_param.Length, "IsYotogiSkill args count error.");
  1288. if (result == null)
  1289. {
  1290. return;
  1291. }
  1292. int nMaidNo = tjs_param[0].AsInteger();
  1293. int skillId = tjs_param[1].AsInteger();
  1294. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1295. result.SetBool(maid.status.yotogiSkill.Contains(skillId));
  1296. }
  1297. private void TJSFuncGetStockMaidCount(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1298. {
  1299. if (result == null)
  1300. {
  1301. return;
  1302. }
  1303. result.SetInteger(GameMain.Instance.CharacterMgr.GetStockMaidCount());
  1304. }
  1305. private void TJSFuncSetSalonGrade(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1306. {
  1307. NDebug.Assert(1 == tjs_param.Length, "SetSalonGrade args count error.");
  1308. GameMain.Instance.CharacterMgr.status.clubGrade = tjs_param[0].AsInteger();
  1309. }
  1310. private void TJSFuncGetSalonGrade(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1311. {
  1312. if (result == null)
  1313. {
  1314. return;
  1315. }
  1316. result.SetInteger(GameMain.Instance.CharacterMgr.status.clubGrade);
  1317. }
  1318. private void TJSFuncGetClubEvaluation(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1319. {
  1320. if (result == null)
  1321. {
  1322. return;
  1323. }
  1324. result.SetInteger(GameMain.Instance.CharacterMgr.status.clubEvaluation);
  1325. }
  1326. private void TJSFuncSetClubGauge(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1327. {
  1328. NDebug.Assert(1 == tjs_param.Length, "SetClubGauge args count error.");
  1329. GameMain.Instance.CharacterMgr.status.clubGauge = tjs_param[0].AsInteger();
  1330. }
  1331. private void TJSFuncGetClubGauge(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1332. {
  1333. if (result == null)
  1334. {
  1335. return;
  1336. }
  1337. result.SetInteger(GameMain.Instance.CharacterMgr.status.clubGauge);
  1338. }
  1339. private void TJSFuncGetBGName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1340. {
  1341. if (result == null)
  1342. {
  1343. return;
  1344. }
  1345. result.SetString(GameMain.Instance.BgMgr.GetBGName());
  1346. }
  1347. private void TJSFuncIsItemParam(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1348. {
  1349. if (result == null)
  1350. {
  1351. return;
  1352. }
  1353. NDebug.Assert(2 == tjs_param.Length, "IsItemParam args count error.");
  1354. if (result == null)
  1355. {
  1356. return;
  1357. }
  1358. int nMaidNo = tjs_param[0].AsInteger();
  1359. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1360. string f_strTag = tjs_param[1].AsString();
  1361. result.SetInteger(Convert.ToInt32(!string.IsNullOrEmpty(maid.body0.GetPartsParam(f_strTag))));
  1362. }
  1363. private void TJSFuncIsItemSlot(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1364. {
  1365. if (result == null)
  1366. {
  1367. return;
  1368. }
  1369. NDebug.Assert(2 == tjs_param.Length, "IsItemSlot args count error.");
  1370. if (result == null)
  1371. {
  1372. return;
  1373. }
  1374. int nMaidNo = tjs_param[0].AsInteger();
  1375. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1376. string text = tjs_param[1].AsString();
  1377. TBody.SlotID f_eSlot = TBody.SlotID.wear;
  1378. try
  1379. {
  1380. f_eSlot = (TBody.SlotID)Enum.Parse(typeof(TBody.SlotID), text);
  1381. }
  1382. catch
  1383. {
  1384. NDebug.Assert("Parse error.[TBody.SlotID]\n" + text, false);
  1385. }
  1386. result.SetBool(maid.body0.GetSlotLoaded(f_eSlot));
  1387. }
  1388. private void OldTJSFuncIsMaidClass(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1389. {
  1390. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@IsMaidClassがよばれました");
  1391. this.TJSFuncIsJobMaid(tjs_param, result);
  1392. }
  1393. private void TJSFuncIsJobMaid(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1394. {
  1395. if (result == null)
  1396. {
  1397. return;
  1398. }
  1399. NDebug.Assert(tjs_param.Length == 2, "IsJobMaid args count error.");
  1400. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger && tjs_param[1].type == TJSVariantRef.Type.tvtString, "error.");
  1401. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(tjs_param[0].AsInteger());
  1402. string uniqueName = tjs_param[1].AsString();
  1403. JobClass.Data data = JobClass.GetData(uniqueName);
  1404. if (maid.status.jobClass.Contains(data.id))
  1405. {
  1406. result.SetInteger(1);
  1407. }
  1408. else
  1409. {
  1410. result.SetInteger(0);
  1411. }
  1412. }
  1413. private void OldTJSFuncGetMaidClassLevel(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1414. {
  1415. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@GetMaidClassLevelがよばれました");
  1416. this.TJSFuncGetJobMaidLevel(tjs_param, result);
  1417. }
  1418. private void TJSFuncGetJobMaidLevel(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1419. {
  1420. if (result == null)
  1421. {
  1422. return;
  1423. }
  1424. NDebug.Assert(tjs_param.Length == 2, "GetJobMaidLevel args count error.");
  1425. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger && tjs_param[1].type == TJSVariantRef.Type.tvtString, "error.");
  1426. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(tjs_param[0].AsInteger());
  1427. string uniqueName = tjs_param[1].AsString();
  1428. JobClass.Data data = JobClass.GetData(uniqueName);
  1429. if (maid.status.jobClass.Contains(data.id))
  1430. {
  1431. result.SetInteger(maid.status.jobClass.Get(data.id).level);
  1432. }
  1433. else
  1434. {
  1435. result.SetInteger(0);
  1436. }
  1437. }
  1438. private void TJSFuncIsYotogiClass(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1439. {
  1440. if (result == null)
  1441. {
  1442. return;
  1443. }
  1444. NDebug.Assert(tjs_param.Length == 2, "IsYotogiClass args count error.");
  1445. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger && tjs_param[1].type == TJSVariantRef.Type.tvtString, "error.");
  1446. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(tjs_param[0].AsInteger());
  1447. string uniqueName = tjs_param[1].AsString();
  1448. YotogiClass.Data data = YotogiClass.GetData(uniqueName);
  1449. if (maid.status.yotogiClass.Contains(data.id))
  1450. {
  1451. result.SetInteger(1);
  1452. }
  1453. else
  1454. {
  1455. result.SetInteger(0);
  1456. }
  1457. }
  1458. private void TJSFuncGetYotogiClassLevel(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1459. {
  1460. if (result == null)
  1461. {
  1462. return;
  1463. }
  1464. NDebug.Assert(tjs_param.Length == 2, "GetYotogiClassLevel args count error.");
  1465. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger && tjs_param[1].type == TJSVariantRef.Type.tvtString, "error.");
  1466. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(tjs_param[0].AsInteger());
  1467. string uniqueName = tjs_param[1].AsString();
  1468. YotogiClass.Data data = YotogiClass.GetData(uniqueName);
  1469. if (maid.status.yotogiClass.Contains(data.id))
  1470. {
  1471. result.SetInteger(maid.status.yotogiClass.Get(data.id).level);
  1472. }
  1473. else
  1474. {
  1475. result.SetInteger(0);
  1476. }
  1477. }
  1478. private void TJSFuncGetNoonScuccessLevel(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1479. {
  1480. if (result == null)
  1481. {
  1482. return;
  1483. }
  1484. NDebug.Assert(tjs_param.Length == 1, "TJSFuncGetNoonScuccessLevel args count error.");
  1485. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger, "error.");
  1486. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1487. Maid maid = characterMgr.GetMaid(tjs_param[0].AsInteger());
  1488. ScheduleData[] scheduleSlot = characterMgr.status.scheduleSlot;
  1489. int integer = -1;
  1490. for (int i = 0; i < scheduleSlot.Length; i++)
  1491. {
  1492. if (scheduleSlot[i] != null)
  1493. {
  1494. if (scheduleSlot[i].maid_guid == maid.status.guid)
  1495. {
  1496. integer = (int)scheduleSlot[i].noon_success_level;
  1497. break;
  1498. }
  1499. }
  1500. }
  1501. result.SetInteger(integer);
  1502. }
  1503. private void TJSFuncIsMaid(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1504. {
  1505. if (result == null)
  1506. {
  1507. return;
  1508. }
  1509. NDebug.Assert(tjs_param.Length == 1, "IsMaid args count error.");
  1510. NDebug.Assert(tjs_param[0].type == TJSVariantRef.Type.tvtInteger, "error.");
  1511. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1512. Maid maid = characterMgr.GetMaid(tjs_param[0].AsInteger());
  1513. result.SetBool(maid != null);
  1514. }
  1515. private void TJSFuncIsOldPersonal(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1516. {
  1517. if (result == null)
  1518. {
  1519. return;
  1520. }
  1521. NDebug.Assert(tjs_param.Length == 1, "IsOldPersonal args count error.");
  1522. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1523. Maid maid = characterMgr.GetMaid(tjs_param[0].AsInteger());
  1524. if (maid == null)
  1525. {
  1526. result.SetBool(false);
  1527. }
  1528. else
  1529. {
  1530. result.SetBool(maid.status.personal.oldPersonal);
  1531. }
  1532. }
  1533. public void TJSFuncConGetSalonLoan(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1534. {
  1535. if (result == null)
  1536. {
  1537. return;
  1538. }
  1539. result.SetInteger(0);
  1540. }
  1541. public void TJSFuncConGetPhase(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1542. {
  1543. if (result == null)
  1544. {
  1545. return;
  1546. }
  1547. result.SetInteger(2);
  1548. }
  1549. public void TJSFuncGetDay(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1550. {
  1551. if (result == null)
  1552. {
  1553. return;
  1554. }
  1555. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  1556. result.SetInteger(status.days);
  1557. }
  1558. public void TJSFuncCreateStockMaidLoopData(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1559. {
  1560. this.stock_maid_loop_list.Clear();
  1561. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1562. for (int i = 0; i < characterMgr.GetStockMaidCount(); i++)
  1563. {
  1564. this.stock_maid_loop_list.Add(characterMgr.GetStockMaid(i));
  1565. }
  1566. List<Maid> list = this.stock_maid_loop_list;
  1567. if (ScriptManager.<>f__mg$cache0 == null)
  1568. {
  1569. ScriptManager.<>f__mg$cache0 = new Comparison<Maid>(CharacterSelectManager.SortMaidStandard);
  1570. }
  1571. list.Sort(ScriptManager.<>f__mg$cache0);
  1572. if (result != null)
  1573. {
  1574. result.SetInteger(this.stock_maid_loop_list.Count);
  1575. }
  1576. }
  1577. public void TJSFuncCreateCompetitiveShowLoopData(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1578. {
  1579. this.stock_maid_loop_list.Clear();
  1580. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1581. if (CompetitiveShowMgr.is_effect_ones)
  1582. {
  1583. for (int i = 0; i < CompetitiveShowMgr.check_maid_list.Count; i++)
  1584. {
  1585. this.stock_maid_loop_list.Add(CompetitiveShowMgr.check_maid_list[i]);
  1586. }
  1587. }
  1588. else if (0 < CompetitiveShowMgr.check_maid_list.Count)
  1589. {
  1590. this.stock_maid_loop_list.Add(CompetitiveShowMgr.check_maid_list[0]);
  1591. CompetitiveShowMgr.check_maid_list.RemoveAt(0);
  1592. }
  1593. if (result != null)
  1594. {
  1595. result.SetInteger(this.stock_maid_loop_list.Count);
  1596. }
  1597. }
  1598. public void TJSFuncGetCompetitiveShowLoopCount(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1599. {
  1600. if (result != null)
  1601. {
  1602. result.SetInteger(CompetitiveShowMgr.check_maid_list.Count);
  1603. }
  1604. }
  1605. public void TJSFuncSetActiveSlotFromStockMaidLoopData(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1606. {
  1607. GameMain.Instance.ScriptMgr.StopMotionScript();
  1608. NDebug.Assert(tjs_param.Length == 1, "SetActiveSlotFromStockMaidLoopData args count error.");
  1609. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1610. Maid maid = this.stock_maid_loop_list[tjs_param[0].AsInteger()];
  1611. maid.Visible = false;
  1612. characterMgr.SetActiveMaid(maid, 0);
  1613. }
  1614. private void TJSFuncClearCallStack(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1615. {
  1616. this.ClearCallStack();
  1617. }
  1618. private void OldTJSFuncIsCommunicationChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1619. {
  1620. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@IsCommunicationCharaeがよばれました");
  1621. if (result == null)
  1622. {
  1623. return;
  1624. }
  1625. result.SetBool(false);
  1626. result.SetBool(0 < ScheduleAPI.CanCommunicationMaids(GameMain.Instance.CharacterMgr.status.isDaytime).Count);
  1627. }
  1628. private void TJSFuncSetCommunicationChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1629. {
  1630. bool isDaytime = GameMain.Instance.CharacterMgr.status.isDaytime;
  1631. Maid communicationMaid = ScheduleAPI.GetCommunicationMaid(isDaytime);
  1632. if (communicationMaid == null)
  1633. {
  1634. if (result != null)
  1635. {
  1636. result.SetBool(false);
  1637. }
  1638. return;
  1639. }
  1640. GameMain.Instance.CharacterMgr.SetActiveMaid(communicationMaid, 0);
  1641. communicationMaid.Visible = true;
  1642. ScheduleCSVData.ScheduleBase schedule = ScheduleAPI.GetSchedule(communicationMaid, isDaytime);
  1643. if (schedule.type == ScheduleTaskCtrl.TaskType.Training)
  1644. {
  1645. ScheduleCSVData.Training training = (ScheduleCSVData.Training)schedule;
  1646. if (training.trainingType == ScheduleCSVData.TrainingType.Trainee)
  1647. {
  1648. Maid maid;
  1649. if (isDaytime)
  1650. {
  1651. maid = ScheduleAPI.GetNoonTrainerMaid();
  1652. }
  1653. else
  1654. {
  1655. maid = ScheduleAPI.GetNightTrainerMaid();
  1656. }
  1657. if (maid != null)
  1658. {
  1659. GameMain.Instance.CharacterMgr.SetActiveMaid(maid, 1);
  1660. maid.Visible = true;
  1661. }
  1662. }
  1663. if (training.trainingType == ScheduleCSVData.TrainingType.Trainer)
  1664. {
  1665. Maid maid2;
  1666. if (isDaytime)
  1667. {
  1668. maid2 = ScheduleAPI.GetNoonTraineeMaid();
  1669. }
  1670. else
  1671. {
  1672. maid2 = ScheduleAPI.GetNightTraineeMaid();
  1673. }
  1674. if (maid2 != null)
  1675. {
  1676. GameMain.Instance.CharacterMgr.SetActiveMaid(maid2, 1);
  1677. maid2.Visible = true;
  1678. }
  1679. }
  1680. }
  1681. if (result != null)
  1682. {
  1683. result.SetBool(true);
  1684. }
  1685. }
  1686. private void TJSFuncSetRandomCommuChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1687. {
  1688. GameMain.Instance.ScriptMgr.StopMotionScript();
  1689. Maid[] array = ScheduleAPI.CanCommunicationMaids(GameMain.Instance.CharacterMgr.status.isDaytime).ToArray();
  1690. if (array.Length == 0)
  1691. {
  1692. GameMain.Instance.CharacterMgr.DeactivateMaid(0);
  1693. return;
  1694. }
  1695. Maid maid = array[UnityEngine.Random.Range(0, array.Length)];
  1696. NDebug.Assert(maid != null, "SetRandomCommuChara()\n選択されたメイドが空です");
  1697. GameMain.Instance.CharacterMgr.SetActiveMaid(maid, 0);
  1698. maid.Visible = true;
  1699. }
  1700. private void TJSFuncCreateYotogiCharaList(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1701. {
  1702. SceneCharacterSelect.CreateYotogiCharaList();
  1703. }
  1704. private void TJSFuncCreateNewYotogiCharaList(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1705. {
  1706. SceneCharacterSelect.CreateNewYotogiCharaList();
  1707. }
  1708. private void TJSFuncCreateNewYotogiHaremPairCharaList(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1709. {
  1710. SceneCharacterSelect.CreateNewYotogiHaremPairCharaList();
  1711. }
  1712. private void TJSFuncCreateVipCharaList(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1713. {
  1714. SceneCharacterSelect.CreateVipCharaList();
  1715. }
  1716. private void TJSFuncCreateFacilityCharaList(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1717. {
  1718. SceneCharacterSelect.CreateFacilityCharaList();
  1719. }
  1720. private void TJSFuncIsReceptionChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1721. {
  1722. if (result == null)
  1723. {
  1724. return;
  1725. }
  1726. result.SetBool(0 < ScheduleAPI.GetEntertainMaids().Count);
  1727. }
  1728. private void TJSFuncSetRandomReceptionChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1729. {
  1730. GameMain.Instance.ScriptMgr.StopMotionScript();
  1731. Maid[] array = ScheduleAPI.GetEntertainMaids().ToArray();
  1732. NDebug.Assert(0 < array.Length, "SetRandomReceptionChara()\nメイドリストが空です");
  1733. Maid maid = array[UnityEngine.Random.Range(0, array.Length)];
  1734. NDebug.Assert(maid != null, "SetRandomReceptionChara()\n選択されたメイドが空です");
  1735. GameMain.Instance.CharacterMgr.SetActiveMaid(maid, 0);
  1736. maid.Visible = true;
  1737. }
  1738. private void TJSFuncIsSelectChara(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1739. {
  1740. if (result == null)
  1741. {
  1742. return;
  1743. }
  1744. result.SetBool(SceneCharacterSelect.IsSelectChara());
  1745. }
  1746. private void TJSFuncGetDateYear(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1747. {
  1748. if (result == null)
  1749. {
  1750. return;
  1751. }
  1752. result.SetInteger(DateTime.Now.Year);
  1753. }
  1754. private void TJSFuncGetDateMonth(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1755. {
  1756. if (result == null)
  1757. {
  1758. return;
  1759. }
  1760. result.SetInteger(DateTime.Now.Month);
  1761. }
  1762. private void TJSFuncGetDateDay(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1763. {
  1764. if (result == null)
  1765. {
  1766. return;
  1767. }
  1768. result.SetInteger(DateTime.Now.Day);
  1769. }
  1770. private void TJSFuncUpdateMaidRanking(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1771. {
  1772. Maid.UpdateMaidRanking();
  1773. }
  1774. private void TJSFuncResetMaidRanking(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1775. {
  1776. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1777. for (int i = 0; i < characterMgr.GetStockMaidCount(); i++)
  1778. {
  1779. Maid stockMaid = characterMgr.GetStockMaid(i);
  1780. if (stockMaid != null)
  1781. {
  1782. stockMaid.status.popularRank = 0;
  1783. stockMaid.status.evaluation = 0;
  1784. stockMaid.status.sales = 0L;
  1785. }
  1786. }
  1787. characterMgr.status.SetFlag("__ランキング日数", 0);
  1788. }
  1789. private void TJSFuncSetMaidRanking1st(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1790. {
  1791. GameMain.Instance.ScriptMgr.StopMotionScript();
  1792. Maid maid = null;
  1793. for (int i = 0; i < GameMain.Instance.CharacterMgr.GetStockMaidCount(); i++)
  1794. {
  1795. maid = GameMain.Instance.CharacterMgr.GetStockMaid(i);
  1796. if (!(maid == null))
  1797. {
  1798. if (maid.status.popularRank == 1)
  1799. {
  1800. break;
  1801. }
  1802. }
  1803. }
  1804. if (maid == null)
  1805. {
  1806. maid = GameMain.Instance.CharacterMgr.GetStockMaid(0);
  1807. }
  1808. GameMain.Instance.CharacterMgr.SetActiveMaid(maid, 0);
  1809. maid.Visible = true;
  1810. }
  1811. private void TJSFuncIsAvailableRanking(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1812. {
  1813. if (result == null)
  1814. {
  1815. return;
  1816. }
  1817. result.SetBool(GameMain.Instance.CharacterMgr.status.isAvailableRanking);
  1818. }
  1819. private void TJSFuncIsYotogiSubCharaSelect(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1820. {
  1821. if (result == null)
  1822. {
  1823. return;
  1824. }
  1825. result.SetBool(false);
  1826. GameObject gameObject = GameObject.Find("UI Root/YotogiManager");
  1827. if (gameObject == null)
  1828. {
  1829. return;
  1830. }
  1831. if (this.compatibilityMode || this.tjsLegacyMode)
  1832. {
  1833. YotogiOldManager component = gameObject.GetComponent<YotogiOldManager>();
  1834. if (component == null)
  1835. {
  1836. return;
  1837. }
  1838. result.SetBool(component.IsCallShouldSubCharaSelect());
  1839. }
  1840. else
  1841. {
  1842. YotogiManager component2 = gameObject.GetComponent<YotogiManager>();
  1843. if (component2 == null)
  1844. {
  1845. return;
  1846. }
  1847. result.SetBool(component2.IsCallShouldSubCharaSelect());
  1848. }
  1849. }
  1850. private void TJSFuncGetYotogiSkillSpecialType(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1851. {
  1852. GameObject gameObject = GameObject.Find("UI Root/YotogiManager");
  1853. if (result == null || gameObject == null)
  1854. {
  1855. return;
  1856. }
  1857. YotogiManager component = gameObject.GetComponent<YotogiManager>();
  1858. if (component == null || component.play_skill_array == null || component.play_skill_array.Length == 0)
  1859. {
  1860. return;
  1861. }
  1862. result.SetString(component.play_skill_array[0].skill_pair.base_data.specialConditionType.ToString());
  1863. }
  1864. private void TJSFuncIsSelectedYotogiSkill(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1865. {
  1866. NDebug.Assert(tjs_param.Length == 1, "IsSelectedYotogiSkill args count error.");
  1867. GameObject gameObject = GameObject.Find("UI Root/YotogiManager");
  1868. if (result == null || gameObject == null)
  1869. {
  1870. return;
  1871. }
  1872. YotogiManager component = gameObject.GetComponent<YotogiManager>();
  1873. if (component == null || component.play_skill_array == null || component.play_skill_array.Length == 0)
  1874. {
  1875. return;
  1876. }
  1877. result.SetBool(false);
  1878. int num = tjs_param[0].AsInteger();
  1879. foreach (YotogiManager.PlayingSkillData playingSkillData in component.play_skill_array)
  1880. {
  1881. if (playingSkillData != null && playingSkillData.skill_pair != null && playingSkillData.skill_pair.skill_data != null)
  1882. {
  1883. if (playingSkillData.skill_pair.skill_data.data.id == num)
  1884. {
  1885. result.SetBool(true);
  1886. break;
  1887. }
  1888. }
  1889. }
  1890. }
  1891. private void TJSFuncIsExistentFile(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1892. {
  1893. if (result == null)
  1894. {
  1895. return;
  1896. }
  1897. if (this.compatibilityMode)
  1898. {
  1899. result.SetBool(false);
  1900. }
  1901. else
  1902. {
  1903. NDebug.Assert(1 == tjs_param.Length, "TJSFuncIsExistentFile args count error.");
  1904. result.SetBool(this.file_system.IsExistentFile(tjs_param[0].AsString()));
  1905. }
  1906. }
  1907. private void TJSFuncIsExistentFileLegacy(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1908. {
  1909. if (result == null)
  1910. {
  1911. return;
  1912. }
  1913. NDebug.Assert(1 == tjs_param.Length, "IsExistentFileLegacy args count error.");
  1914. result.SetBool(GameUty.FileSystemOld.IsExistentFile(tjs_param[0].AsString()));
  1915. }
  1916. private void TJSFuncCheckClearVIP(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1917. {
  1918. if (result == null)
  1919. {
  1920. return;
  1921. }
  1922. NDebug.Assert(1 == tjs_param.Length, "CheckClearVIP args count error.");
  1923. int key = tjs_param[0].AsInteger();
  1924. ReadOnlyDictionary<int, NightWorkState> night_works_state_dic = GameMain.Instance.CharacterMgr.status.night_works_state_dic;
  1925. bool @bool = false;
  1926. if (night_works_state_dic.ContainsKey(key) && night_works_state_dic[key].finish)
  1927. {
  1928. @bool = true;
  1929. }
  1930. result.SetBool(@bool);
  1931. }
  1932. private void TJSFuncIsCBLVersion(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1933. {
  1934. if (result == null)
  1935. {
  1936. return;
  1937. }
  1938. result.SetBool(false);
  1939. }
  1940. private void OldTJSFuncGetRentalNPCName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1941. {
  1942. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@GetRentalNPCNameがよばれました");
  1943. if (result == null)
  1944. {
  1945. return;
  1946. }
  1947. result.SetString(string.Empty);
  1948. }
  1949. private void OldTJSFuncIsMarriage(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1950. {
  1951. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@IsMarriageがよばれました");
  1952. if (result == null)
  1953. {
  1954. return;
  1955. }
  1956. NDebug.Assert(1 == tjs_param.Length, "TJSFuncIsMarriage args count error.");
  1957. int nMaidNo = tjs_param[0].AsInteger();
  1958. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1959. if (maid != null && maid.status.OldStatus != null)
  1960. {
  1961. result.SetBool(maid.status.OldStatus.isMarriage);
  1962. }
  1963. else
  1964. {
  1965. result.SetBool(false);
  1966. }
  1967. }
  1968. private void OldTJSFuncIsNewWifeFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1969. {
  1970. NDebug.Assert(this.compatibilityMode || this.tjsLegacyMode, "互換モードではないの、互換モード用関数@IsNewWifeFlagがよばれました");
  1971. if (result == null)
  1972. {
  1973. return;
  1974. }
  1975. NDebug.Assert(1 == tjs_param.Length, "TJSFuncIsMarriage args count error.");
  1976. int nMaidNo = tjs_param[0].AsInteger();
  1977. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  1978. if (maid != null && maid.status.OldStatus != null)
  1979. {
  1980. result.SetBool(maid.status.OldStatus.isNewWife);
  1981. }
  1982. else
  1983. {
  1984. result.SetBool(false);
  1985. }
  1986. }
  1987. private void TJSFuncIsMVPEvent(TJSVariantRef[] tjs_param, TJSVariantRef result)
  1988. {
  1989. if (result == null)
  1990. {
  1991. return;
  1992. }
  1993. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  1994. if (!status.isAvailableRanking)
  1995. {
  1996. result.SetBool(false);
  1997. }
  1998. else if (status.GetFlag("__ランキング日数") % 7 == 0)
  1999. {
  2000. bool @bool = false;
  2001. for (int i = 0; i < GameMain.Instance.CharacterMgr.GetStockMaidCount(); i++)
  2002. {
  2003. Maid stockMaid = GameMain.Instance.CharacterMgr.GetStockMaid(i);
  2004. if (!(stockMaid == null))
  2005. {
  2006. if (stockMaid.status.popularRank == 1)
  2007. {
  2008. @bool = true;
  2009. break;
  2010. }
  2011. }
  2012. }
  2013. result.SetBool(@bool);
  2014. }
  2015. else
  2016. {
  2017. result.SetBool(false);
  2018. }
  2019. }
  2020. private void TJSFuncSetMaidCondition(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2021. {
  2022. NDebug.Assert(2 == tjs_param.Length, "SetMaidCondition args count error.");
  2023. int nMaidNo = tjs_param[0].AsInteger();
  2024. string a = tjs_param[1].AsString();
  2025. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2026. if (this.compatibilityMode || this.tjsLegacyMode)
  2027. {
  2028. if (a == "緊張")
  2029. {
  2030. maid.status.OldStatus.relation = MaidStatus.Old.Relation.Tonus;
  2031. }
  2032. else if (a == "お近づき")
  2033. {
  2034. maid.status.OldStatus.relation = MaidStatus.Old.Relation.Contact;
  2035. }
  2036. else if (a == "信頼")
  2037. {
  2038. maid.status.OldStatus.relation = MaidStatus.Old.Relation.Trust;
  2039. }
  2040. else if (a == "恋人")
  2041. {
  2042. maid.status.OldStatus.relation = MaidStatus.Old.Relation.Lover;
  2043. }
  2044. else if (a == "愛奴")
  2045. {
  2046. maid.status.OldStatus.relation = MaidStatus.Old.Relation.Slave;
  2047. }
  2048. else if (a == "酔い")
  2049. {
  2050. maid.status.OldStatus.condition = Condition.Drunk;
  2051. }
  2052. else if (a == "お仕置き")
  2053. {
  2054. maid.status.OldStatus.condition = Condition.Osioki;
  2055. }
  2056. else if (a == "酔い解除" || a == "お仕置き解除")
  2057. {
  2058. maid.status.OldStatus.condition = Condition.Null;
  2059. }
  2060. }
  2061. else if (a == "お近づき")
  2062. {
  2063. maid.status.relation = MaidStatus.Relation.Contact;
  2064. }
  2065. else if (a == "信頼")
  2066. {
  2067. maid.status.relation = MaidStatus.Relation.Trust;
  2068. }
  2069. else if (a == "恋人")
  2070. {
  2071. maid.status.relation = MaidStatus.Relation.Lover;
  2072. }
  2073. }
  2074. private void TJSFuncSetSeikeikenFront(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2075. {
  2076. NDebug.Assert(2 == tjs_param.Length, "SetSeikeikenFront args count error.");
  2077. int num = tjs_param[0].AsInteger();
  2078. bool seikeikenFront = tjs_param[1].AsBool();
  2079. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(num);
  2080. Seikeiken seikeiken = maid.status.seikeiken;
  2081. maid.status.SetSeikeikenFront(seikeikenFront);
  2082. if (num == 0 && maid.status.seikeiken != seikeiken)
  2083. {
  2084. if ((this.compatibilityMode || this.tjsLegacyMode) && YotogiOldManager.instans != null)
  2085. {
  2086. YotogiOldManager.instans.OnChangeSeikeiken();
  2087. }
  2088. else if (YotogiManager.instans != null)
  2089. {
  2090. YotogiManager.instans.OnChangeSeikeiken();
  2091. }
  2092. }
  2093. }
  2094. private void TJSFuncSetSeikeikenBack(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2095. {
  2096. NDebug.Assert(2 == tjs_param.Length, "SetSeikeikenBack args count error.");
  2097. int nMaidNo = tjs_param[0].AsInteger();
  2098. bool seikeikenBack = tjs_param[1].AsBool();
  2099. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2100. maid.status.SetSeikeikenBack(seikeikenBack);
  2101. }
  2102. private void TJSFuncSetInitSeikeiken(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2103. {
  2104. NDebug.Assert(2 == tjs_param.Length, "SetInitSeikeiken args count error.");
  2105. int nMaidNo = tjs_param[0].AsInteger();
  2106. string text = tjs_param[1].AsString();
  2107. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2108. try
  2109. {
  2110. Seikeiken initSeikeiken = (Seikeiken)Enum.Parse(typeof(Seikeiken), text);
  2111. maid.status.initSeikeiken = initSeikeiken;
  2112. }
  2113. catch (ArgumentException)
  2114. {
  2115. Debug.Log("MaidStatus.Seikeiken\nenum parse error.[" + text + "]");
  2116. }
  2117. }
  2118. private void TJSFuncSetNewItem(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2119. {
  2120. NDebug.Assert(1 == tjs_param.Length, "SetNewItem args count error.");
  2121. if (this.compatibilityMode || this.tjsLegacyMode)
  2122. {
  2123. return;
  2124. }
  2125. string itemName = tjs_param[0].AsString();
  2126. GameMain.Instance.CharacterMgr.status.AddHavePartsItem(itemName);
  2127. }
  2128. private void TJSFuncIsGameInShopItemPurchased(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2129. {
  2130. NDebug.Assert(1 == tjs_param.Length, "IsGameInShopItemPurchased args count error.");
  2131. if (result == null)
  2132. {
  2133. return;
  2134. }
  2135. int num = tjs_param[0].AsInteger();
  2136. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  2137. if (!status.IsShopLineupItem(num))
  2138. {
  2139. result.SetBool(false);
  2140. }
  2141. result.SetBool(status.shopLineups.Get(num) == ShopItemStatus.Purchased);
  2142. }
  2143. private void TJSFuncSetContractType(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2144. {
  2145. NDebug.Assert(2 == tjs_param.Length, "SetContractType args count error.");
  2146. int nMaidNo = tjs_param[0].AsInteger();
  2147. string text = tjs_param[1].AsString();
  2148. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2149. if (text == "育成中")
  2150. {
  2151. maid.status.contract = Contract.Trainee;
  2152. }
  2153. else if (text == "フリー")
  2154. {
  2155. maid.status.contract = Contract.Free;
  2156. }
  2157. else if (text == "専属")
  2158. {
  2159. maid.status.contract = Contract.Exclusive;
  2160. }
  2161. else
  2162. {
  2163. NDebug.Assert(text + "は不正です", false);
  2164. }
  2165. }
  2166. private void TJSFuncSetFeature(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2167. {
  2168. NDebug.Assert(3 == tjs_param.Length, "SetFeature args count error.");
  2169. int nMaidNo = tjs_param[0].AsInteger();
  2170. string uniqueName = tjs_param[1].AsString();
  2171. bool flag = tjs_param[2].AsBool();
  2172. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2173. Feature.Data data = Feature.GetData(uniqueName);
  2174. maid.status.AddFeature(data);
  2175. }
  2176. private void TJSFuncSetPropensity(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2177. {
  2178. NDebug.Assert(3 == tjs_param.Length, "SetPropensity args count error.");
  2179. int nMaidNo = tjs_param[0].AsInteger();
  2180. string uniqueName = tjs_param[1].AsString();
  2181. bool flag = tjs_param[2].AsBool();
  2182. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2183. Propensity.Data data = Propensity.GetData(uniqueName);
  2184. maid.status.AddPropensity(data);
  2185. }
  2186. private void TJSFuncComSetSexualParam(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2187. {
  2188. }
  2189. private void TJSFuncSetNewTrophy(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2190. {
  2191. if (this.compatibilityMode || this.tjsLegacyMode)
  2192. {
  2193. return;
  2194. }
  2195. NDebug.Assert(1 == tjs_param.Length, "SetNewTrophy args count error.");
  2196. int trophyId = tjs_param[0].AsInteger();
  2197. GameMain.Instance.CharacterMgr.status.AddHaveTrophy(trophyId);
  2198. }
  2199. private void TJSFuncCheckTrophyContractType(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2200. {
  2201. if (this.compatibilityMode || this.tjsLegacyMode)
  2202. {
  2203. return;
  2204. }
  2205. GameMain.Instance.CharacterMgr.status.CheckTrophyContractTypeAndrelation();
  2206. }
  2207. private void TJSFuncSetYotogiSelectStageName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2208. {
  2209. NDebug.Assert(1 == tjs_param.Length, "SetYotogiSelectStageName args count error.");
  2210. this.debug_yotogi_stage_ = tjs_param[0].AsString();
  2211. }
  2212. private void TJSFuncGetYotogiSelectStageName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2213. {
  2214. if (result == null)
  2215. {
  2216. return;
  2217. }
  2218. if (this.compatibilityMode || this.tjsLegacyMode)
  2219. {
  2220. result.SetString(YotogiOldStageSelectManager.StageName);
  2221. }
  2222. else
  2223. {
  2224. result.SetString(YotogiStageSelectManager.SelectedStage.uniqueName);
  2225. }
  2226. }
  2227. public void TJSFuncIsPluginPack(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2228. {
  2229. if (result == null)
  2230. {
  2231. return;
  2232. }
  2233. NDebug.Assert(1 == tjs_param.Length, "IsPluginPack args count error.");
  2234. if (this.compatibilityMode)
  2235. {
  2236. result.SetBool(false);
  2237. }
  2238. else
  2239. {
  2240. string text = tjs_param[0].AsString();
  2241. if (!PluginData.Contains(text))
  2242. {
  2243. Debug.LogError("IsPluginPackで指定された[" + text + "]は設定されていないプラグイン名です");
  2244. }
  2245. result.SetBool(PluginData.IsEnabled(text));
  2246. }
  2247. }
  2248. public void TJSFuncAddShopLineup(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2249. {
  2250. NDebug.Assert(1 == tjs_param.Length, "TJSFuncAddShopLineup args count error.");
  2251. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  2252. int num = tjs_param[0].AsInteger();
  2253. if (!status.shopLineups.ContainsKey(num))
  2254. {
  2255. status.AddShopLineup(num);
  2256. }
  2257. }
  2258. public void TJSFuncSetEventItemFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2259. {
  2260. NDebug.Assert(2 == tjs_param.Length, "SetEventItemFlag args count error.");
  2261. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  2262. bool flag = tjs_param[1].AsInteger() != 0;
  2263. if (flag)
  2264. {
  2265. status.AddHaveItem(tjs_param[0].AsString());
  2266. }
  2267. else
  2268. {
  2269. status.RemoveHaveItem(tjs_param[0].AsString());
  2270. }
  2271. }
  2272. public void TJSFuncIsEventItemFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2273. {
  2274. if (result == null)
  2275. {
  2276. NDebug.Assert("error IsEventItemFlag", false);
  2277. }
  2278. NDebug.Assert(1 == tjs_param.Length, "IsEventItemFlag args count error.");
  2279. PlayerStatus.Status status = GameMain.Instance.CharacterMgr.status;
  2280. result.SetBool(status.IsHaveItem(tjs_param[0].AsString()));
  2281. }
  2282. public void TJSFuncGetVRMode(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2283. {
  2284. if (result == null)
  2285. {
  2286. NDebug.Assert("error GetVRMode", false);
  2287. }
  2288. result.SetInteger((int)GameMain.Instance.VRDeviceTypeID);
  2289. }
  2290. public void TJSFuncIsVRMode(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2291. {
  2292. if (result == null)
  2293. {
  2294. NDebug.Assert("error IsVRMode", false);
  2295. }
  2296. result.SetInteger((!GameMain.Instance.VRMode) ? 0 : 1);
  2297. }
  2298. public void TJSFuncSetDanceData(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2299. {
  2300. NDebug.Assert(1 == tjs_param.Length, "TJSFuncAddShopLineup args count error.");
  2301. string bgm_file_name = tjs_param[0].AsString();
  2302. DanceMain.SelectDanceData = new DanceData
  2303. {
  2304. bgm_file_name = bgm_file_name,
  2305. preset_name = new List<string>(),
  2306. preset_name =
  2307. {
  2308. string.Empty
  2309. }
  2310. };
  2311. DanceMain.KaraokeMode = true;
  2312. RhythmAction_Mgr.KaraokeRecet();
  2313. GameMain.Instance.CMSystem.SetTmpGenericFlag("ダンスOVRカメラタイプ", 0);
  2314. }
  2315. public void TJSFuncGetEventAdded(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2316. {
  2317. if (result == null)
  2318. {
  2319. NDebug.Assert("error GetEventAdded", false);
  2320. }
  2321. result.SetBool(GameMain.Instance.ScenarioSelectMgr.IsEventAdded());
  2322. }
  2323. public void TJSFuncGetLockNTRPlayFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2324. {
  2325. if (result == null)
  2326. {
  2327. NDebug.Assert("error GetLockNTRPlayFlag", false);
  2328. }
  2329. result.SetBool(GameMain.Instance.CharacterMgr.status.lockNTRPlay);
  2330. }
  2331. public void TJSFuncGetLockUserDraftMaid(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2332. {
  2333. if (result == null)
  2334. {
  2335. NDebug.Assert("error GetLockUserDraftMaid", false);
  2336. }
  2337. result.SetBool(GameMain.Instance.CharacterMgr.status.lockUserDraftMaid);
  2338. }
  2339. public void TJSFuncIsComPlayer(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2340. {
  2341. if (result == null)
  2342. {
  2343. NDebug.Assert("error IsComPlayer", false);
  2344. }
  2345. result.SetBool(!GameMain.Instance.CharacterMgr.status.isOldPlayer);
  2346. }
  2347. public void TJSFuncSetPlayerMoney(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2348. {
  2349. NDebug.Assert(1 == tjs_param.Length, "SetPlayerMoney args count error.");
  2350. int num = tjs_param[0].AsInteger();
  2351. GameMain.Instance.CharacterMgr.status.money = (long)num;
  2352. }
  2353. public void TJSFuncGetPlayerMoney(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2354. {
  2355. if (result == null)
  2356. {
  2357. NDebug.Assert("error GetPlayerMoney", false);
  2358. }
  2359. int integer = (2147483647L >= GameMain.Instance.CharacterMgr.status.money) ? ((int)GameMain.Instance.CharacterMgr.status.money) : int.MaxValue;
  2360. result.SetInteger(integer);
  2361. }
  2362. public void TJSFuncSetMaidLeader(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2363. {
  2364. NDebug.Assert(2 == tjs_param.Length, "SetMaidLeader args count error.");
  2365. int nMaidNo = tjs_param[0].AsInteger();
  2366. bool leader = tjs_param[1].AsBool();
  2367. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(nMaidNo);
  2368. if (maid != null)
  2369. {
  2370. maid.status.leader = leader;
  2371. }
  2372. }
  2373. public void TJSFuncSetMaidCostumeFacility(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2374. {
  2375. NDebug.Assert(1 == tjs_param.Length, "UpdateMaidCostumeFacility args count error.");
  2376. int num = tjs_param[0].AsInteger();
  2377. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(num);
  2378. NDebug.Assert(maid != null, string.Format("UpdateMaidCostumeFacility()\nメイド[{0}]番が見つかりませんでした。", num));
  2379. ScheduleMgr.ScheduleTime scheduleTime = (!GameMain.Instance.CharacterMgr.status.isDaytime) ? ScheduleMgr.ScheduleTime.Night : ScheduleMgr.ScheduleTime.DayTime;
  2380. Facility maidAssignedFacility = GameMain.Instance.FacilityMgr.GetMaidAssignedFacility(maid, scheduleTime);
  2381. if (maidAssignedFacility != null)
  2382. {
  2383. Facility.CostumeType typeCostume = maidAssignedFacility.typeCostume;
  2384. if (typeCostume == Facility.CostumeType.Edit)
  2385. {
  2386. maidAssignedFacility.UpdateMaidCostumeToEditCostume(maid, false);
  2387. }
  2388. else if (typeCostume == Facility.CostumeType.Default)
  2389. {
  2390. maidAssignedFacility.UpdateMaidCostumeToDefaultCostume(maid);
  2391. }
  2392. else if (typeCostume == Facility.CostumeType.Heroine)
  2393. {
  2394. MPN[] facilityCostumeEnableMPN = FacilityDataTable.GetFacilityCostumeEnableMPN();
  2395. for (int i = 0; i < facilityCostumeEnableMPN.Length; i++)
  2396. {
  2397. maid.ResetProp(facilityCostumeEnableMPN[i], false);
  2398. }
  2399. }
  2400. }
  2401. else
  2402. {
  2403. NDebug.Warning(string.Format("UpdateMaidCostumeFacility()\nメイド[{0}]番は、現在施設の仕事を持っていません。", num));
  2404. Debug.LogWarningFormat("UpdateMaidCostumeFacility()\nメイド[{0}]番は、現在施設の仕事を持っていません。", new object[]
  2405. {
  2406. num
  2407. });
  2408. }
  2409. }
  2410. public void TJSFuncResetMaidCostumeFacility(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2411. {
  2412. NDebug.Assert(1 == tjs_param.Length, "UpdateMaidCostumeFacility args count error.");
  2413. int num = tjs_param[0].AsInteger();
  2414. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(num);
  2415. NDebug.Assert(maid != null, string.Format("UpdateMaidCostumeFacility()\nメイド[{0}]番が見つかりませんでした。", num));
  2416. MPN[] facilityCostumeEnableMPN = FacilityDataTable.GetFacilityCostumeEnableMPN();
  2417. for (int i = 0; i < facilityCostumeEnableMPN.Length; i++)
  2418. {
  2419. maid.ResetProp(facilityCostumeEnableMPN[i], false);
  2420. }
  2421. }
  2422. public void TJSFuncCallTitleBar(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2423. {
  2424. NDebug.Assert(1 == tjs_param.Length, "CallTitleBar args count error.");
  2425. GameObject gameObject = GameObject.Find("__SceneADV__");
  2426. if (gameObject == null)
  2427. {
  2428. return;
  2429. }
  2430. SceneADV component = gameObject.GetComponent<SceneADV>();
  2431. component.CallTitleBar(tjs_param[0].AsString());
  2432. }
  2433. public void TJSFuncSetCompatibilityMode(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2434. {
  2435. NDebug.Assert(1 == tjs_param.Length, "SetCompatibilityMode args count error.");
  2436. this.compatibilityMode = tjs_param[0].AsBool();
  2437. Debug.Log("スクリプトモード変更 : 互換モード[" + ((!this.compatibilityMode) ? "×]" : "〇]"));
  2438. KagScript kag = this.adv_kag.kag;
  2439. this.compatibilityCallStackDepth = kag.callStackDepth;
  2440. this.compatibilityRCallStackDepth = kag.r_callStackDepth;
  2441. }
  2442. public void TJSFuncIsBuildingFacility(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2443. {
  2444. NDebug.Assert(result != null, "error IsBuildingFacility");
  2445. NDebug.Assert(1 == tjs_param.Length, "IsBuildingFacility args count error.");
  2446. string text = tjs_param[0].AsString();
  2447. FacilityDataTable.FacilityDefaultData facilityDefaultData = FacilityDataTable.GetFacilityDefaultData(text, false);
  2448. NDebug.Assert(facilityDefaultData != null, string.Format("{0} は存在しない情報です", text));
  2449. if (!facilityDefaultData.isEnableData)
  2450. {
  2451. Debug.Log(text + " は有効ではありません");
  2452. result.SetBool(false);
  2453. }
  2454. else
  2455. {
  2456. result.SetBool(GameMain.Instance.FacilityMgr.IsExistTypeFacility(facilityDefaultData.ID));
  2457. }
  2458. }
  2459. public void TJSFuncIsBuildingFacilityUpward(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2460. {
  2461. NDebug.Assert(result != null, "error IsBuildingFacilityUpward");
  2462. NDebug.Assert(1 == tjs_param.Length, "IsBuildingFacilityUpward args count error.");
  2463. string text = tjs_param[0].AsString();
  2464. FacilityDataTable.FacilityDefaultData facilityDefaultData = FacilityDataTable.GetFacilityDefaultData(text, false);
  2465. NDebug.Assert(facilityDefaultData != null, string.Format("{0} は存在しない情報です", text));
  2466. if (!facilityDefaultData.isEnableData)
  2467. {
  2468. Debug.Log(text + " は有効ではありません");
  2469. result.SetBool(false);
  2470. }
  2471. if (facilityDefaultData.isExistUpwardFacility)
  2472. {
  2473. result.SetBool(GameMain.Instance.FacilityMgr.IsExistTypeFacility(facilityDefaultData.upwardFacility.ID));
  2474. }
  2475. else
  2476. {
  2477. result.SetBool(false);
  2478. }
  2479. }
  2480. public void TJSCheckDanceType(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2481. {
  2482. NDebug.Assert(tjs_param.Length != 0, "CheckDanceType:引数が何も指定されてません");
  2483. bool flag = false;
  2484. foreach (TJSVariantRef tjsvariantRef in tjs_param)
  2485. {
  2486. flag |= (RhythmAction_Mgr.NowDance == (RhythmAction_Mgr.DanceType)Enum.Parse(typeof(RhythmAction_Mgr.DanceType), tjsvariantRef.AsString()));
  2487. }
  2488. result.SetBool(flag);
  2489. }
  2490. public void TJSSetMusicRelease(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2491. {
  2492. NDebug.Assert(tjs_param.Length == 1, "SetMusicRelease:指定できる引数は1つまでです");
  2493. VsDanceDataMgr.Instance.MusicRelese(tjs_param[0].AsInteger());
  2494. }
  2495. public void TJSSetVsSetting(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2496. {
  2497. NDebug.Assert(tjs_param.Length == 1, "SetVsSetting:指定できる引数は1つまでです");
  2498. VsDanceDataMgr.Instance.SelectSetting(tjs_param[0].AsInteger());
  2499. }
  2500. public void TJSNeedDanceResult(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2501. {
  2502. bool flag = true;
  2503. flag &= (RhythmAction_Mgr.NowDance != RhythmAction_Mgr.DanceType.VS_Skip);
  2504. flag &= (RhythmAction_Mgr.NowDance != RhythmAction_Mgr.DanceType.Touch);
  2505. flag &= (RhythmAction_Mgr.NowDance != RhythmAction_Mgr.DanceType.View);
  2506. flag &= (RhythmAction_Mgr.NowDance != RhythmAction_Mgr.DanceType.Encore);
  2507. result.SetBool(flag);
  2508. }
  2509. public void TJSGetChallengeRank(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2510. {
  2511. NDebug.Assert(tjs_param.Length > 0, "GetChallengeRank:引数が指定されてません");
  2512. bool flag = false;
  2513. foreach (TJSVariantRef tjsvariantRef in tjs_param)
  2514. {
  2515. flag |= (tjsvariantRef.AsString() == Result_Display.GetData("Rank"));
  2516. }
  2517. result.SetBool(flag);
  2518. }
  2519. public void TJSBjDayFirst(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2520. {
  2521. int days = GameMain.Instance.CharacterMgr.status.days;
  2522. int flag = GameMain.Instance.CharacterMgr.status.GetFlag("BJ最終プレイ日");
  2523. bool @bool = days != flag;
  2524. foreach (TJSVariantRef tjsvariantRef in tjs_param)
  2525. {
  2526. if (tjsvariantRef.AsString() == "ブラックジャック終了")
  2527. {
  2528. GameMain.Instance.CharacterMgr.status.SetFlag("BJ最終プレイ日", days);
  2529. break;
  2530. }
  2531. }
  2532. result.SetBool(@bool);
  2533. }
  2534. public void TJSCasinoShopBuy(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2535. {
  2536. NDebug.Assert(tjs_param.Length != 0, "CasinoShopBuy:引数が指定されてません");
  2537. bool flag = false;
  2538. foreach (TJSVariantRef tjsvariantRef in tjs_param)
  2539. {
  2540. int num = tjsvariantRef.AsInteger();
  2541. flag = false;
  2542. foreach (CasinoShopItem casinoShopItem in CasinoDataMgr.Instance.GetShopItem())
  2543. {
  2544. if (casinoShopItem.ID == num && casinoShopItem.IsSoldOut)
  2545. {
  2546. flag = true;
  2547. break;
  2548. }
  2549. }
  2550. if (!flag)
  2551. {
  2552. break;
  2553. }
  2554. }
  2555. result.SetBool(flag);
  2556. }
  2557. public void TJSSetEventEndFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2558. {
  2559. NDebug.Assert(tjs_param.Length == 3, "SetEventEndFlag:引数が3つ必要です");
  2560. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(tjs_param[0].AsInteger());
  2561. if (!maid)
  2562. {
  2563. maid = GameMain.Instance.CharacterMgr.GetStockMaid(tjs_param[0].AsInteger());
  2564. if (!maid)
  2565. {
  2566. return;
  2567. }
  2568. }
  2569. if (!GameMain.Instance.ScenarioSelectMgr.ExistScenario(tjs_param[1].AsInteger()))
  2570. {
  2571. Debug.LogErrorFormat("選択シナリオ:{0}は存在しません", new object[]
  2572. {
  2573. tjs_param[1].AsInteger()
  2574. });
  2575. return;
  2576. }
  2577. maid.status.SetEventEndFlag(tjs_param[1].AsInteger(), tjs_param[2].AsBool());
  2578. }
  2579. public void TJSFuncIsKasizukiGuest(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2580. {
  2581. if (result == null)
  2582. {
  2583. NDebug.Assert("error IsKasizukiGuest", false);
  2584. }
  2585. ManDataType nowManType = (ManDataType)GameMain.Instance.KasizukiMgr.GetNowManType();
  2586. result.SetBool(nowManType != ManDataType.主人公);
  2587. }
  2588. public void TJSFuncGetKasizukiSelectRoomName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2589. {
  2590. if (result == null)
  2591. {
  2592. NDebug.Assert("error GetKasizukiSelectRoomName", false);
  2593. }
  2594. RoomData.Data data = RoomData.GetData(GameMain.Instance.KasizukiMgr.GetSystemData<int>(SystemDataType.選択部屋));
  2595. result.SetString(data.uniqueName);
  2596. }
  2597. public void TJSFuncGetKasizukiMaidLikability(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2598. {
  2599. if (result == null)
  2600. {
  2601. NDebug.Assert("error GetKasizukiMaidLikability", false);
  2602. }
  2603. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2604. ManDataType nowManType = (ManDataType)kasizukiMgr.GetNowManType();
  2605. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(0);
  2606. int integer = -1;
  2607. if (nowManType == ManDataType.主人公)
  2608. {
  2609. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F本編, true);
  2610. }
  2611. else if (nowManType == ManDataType.傅き男1)
  2612. {
  2613. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男1, true);
  2614. }
  2615. else if (nowManType == ManDataType.傅き男2)
  2616. {
  2617. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男2, true);
  2618. }
  2619. else if (nowManType == ManDataType.傅き男3)
  2620. {
  2621. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男3, true);
  2622. }
  2623. else if (nowManType == ManDataType.傅き男4)
  2624. {
  2625. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男4, true);
  2626. }
  2627. else if (nowManType == ManDataType.傅き男5)
  2628. {
  2629. integer = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男5, true);
  2630. }
  2631. result.SetInteger(integer);
  2632. }
  2633. public void TJSFuncGetKasizukiMaidLikabilityName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2634. {
  2635. if (result == null)
  2636. {
  2637. NDebug.Assert("error GetKasizukiMaidLikabilityName", false);
  2638. }
  2639. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2640. ManDataType nowManType = (ManDataType)kasizukiMgr.GetNowManType();
  2641. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(0);
  2642. int likability = -1;
  2643. if (nowManType == ManDataType.主人公)
  2644. {
  2645. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F本編, true);
  2646. }
  2647. else if (nowManType == ManDataType.傅き男1)
  2648. {
  2649. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男1, true);
  2650. }
  2651. else if (nowManType == ManDataType.傅き男2)
  2652. {
  2653. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男2, true);
  2654. }
  2655. else if (nowManType == ManDataType.傅き男3)
  2656. {
  2657. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男3, true);
  2658. }
  2659. else if (nowManType == ManDataType.傅き男4)
  2660. {
  2661. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男4, true);
  2662. }
  2663. else if (nowManType == ManDataType.傅き男5)
  2664. {
  2665. likability = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.好感度\uFF3F傅き男5, true);
  2666. }
  2667. string likabilityName = LikabilityReplace.GetLikabilityName(likability);
  2668. result.SetString(likabilityName);
  2669. }
  2670. public void TJSFuncGetKasizukiMaidWorkCount(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2671. {
  2672. if (result == null)
  2673. {
  2674. NDebug.Assert("error GetKasizukiMaidWorkCount", false);
  2675. }
  2676. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2677. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(0);
  2678. int maidData = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.仕事回数, true);
  2679. result.SetInteger(maidData);
  2680. }
  2681. public void TJSFuncGetKasizukiMaidWorkCountName(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2682. {
  2683. if (result == null)
  2684. {
  2685. NDebug.Assert("error GetKasizukiMaidWorkCountName", false);
  2686. }
  2687. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2688. Maid maid = GameMain.Instance.CharacterMgr.GetMaid(0);
  2689. int maidData = kasizukiMgr.GetMaidData<int>(maid, MaidDataType.仕事回数, true);
  2690. string workCountName = WorkCountReplace.GetWorkCountName(maidData);
  2691. result.SetString(workCountName);
  2692. }
  2693. public void TJSFuncGetKasizukiSystemFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2694. {
  2695. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2696. kasizukiMgr.TJSFuncGetKasizukiSystemFlag(tjs_param, result);
  2697. }
  2698. public void TJSFuncSetKasizukiSystemFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2699. {
  2700. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2701. kasizukiMgr.TJSFuncSetKasizukiSystemFlag(tjs_param, result);
  2702. }
  2703. public void TJSFuncAddKasizukiSystemFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2704. {
  2705. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2706. kasizukiMgr.TJSFuncAddKasizukiSystemFlag(tjs_param, result);
  2707. }
  2708. public void TJSFuncSetKasizukiPassFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2709. {
  2710. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2711. kasizukiMgr.TJSFuncSetKasizukiPassFlag(tjs_param, result);
  2712. }
  2713. public void TJSFuncGetKasizukiMaidFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2714. {
  2715. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2716. kasizukiMgr.TJSFuncGetKasizukiMaidFlag(tjs_param, result);
  2717. }
  2718. public void TJSFuncSetKasizukiMaidFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2719. {
  2720. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2721. kasizukiMgr.TJSFuncSetKasizukiMaidFlag(tjs_param, result);
  2722. }
  2723. public void TJSFuncIsKasizukiCorrectSenarioFlag(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2724. {
  2725. KasizukiManager kasizukiMgr = GameMain.Instance.KasizukiMgr;
  2726. kasizukiMgr.TJSFuncIsKasizukiCorrectSenarioFlag(tjs_param, result);
  2727. }
  2728. public void TJSFuncIsVRKaraokeMode(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2729. {
  2730. if (result == null)
  2731. {
  2732. NDebug.Assert("error IsVRKaraokeMode", false);
  2733. }
  2734. result.SetInteger((!SceneVRCommunication.Instance.KaraokeMode) ? 0 : 1);
  2735. }
  2736. public void TJSFuncGetRemainingDanceTime(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2737. {
  2738. if (result == null)
  2739. {
  2740. NDebug.Assert("error GetRemainingDanceTime", false);
  2741. }
  2742. float num;
  2743. if (RhythmAction_Mgr.Instance != null)
  2744. {
  2745. num = RhythmAction_Mgr.Instance.RemainingTime;
  2746. }
  2747. else
  2748. {
  2749. string message = "リズムアクションマネージャのインスタンスが見つかりません。-1を返します。";
  2750. Debug.LogWarning(message);
  2751. num = -0.001f;
  2752. }
  2753. result.SetInteger(Mathf.RoundToInt(num * 1000f));
  2754. }
  2755. public void TJSFuncGetYotogiCommandClickCount(TJSVariantRef[] tjs_param, TJSVariantRef result)
  2756. {
  2757. if (result == null)
  2758. {
  2759. NDebug.Assert("error GetYotogiCommandClickCount", false);
  2760. }
  2761. NDebug.Assert(tjs_param.Length == 2, "GetYotogiCommandClickCount:引数が2つ必要です");
  2762. string text = tjs_param[0].AsString();
  2763. bool flag = tjs_param[1].AsBool();
  2764. result.SetInteger(0);
  2765. if (YotogiManager.instans == null || YotogiManager.instans.play_mgr == null || string.IsNullOrEmpty(text))
  2766. {
  2767. return;
  2768. }
  2769. Dictionary<string, int> dictionary = (!flag) ? YotogiManager.instans.play_mgr.commandClickCountSingle : YotogiManager.instans.play_mgr.commandClickCountTotal;
  2770. int integer = 0;
  2771. dictionary.TryGetValue(text, out integer);
  2772. result.SetInteger(integer);
  2773. }
  2774. public void OnReturnEvent(string fileName, int line)
  2775. {
  2776. if (this.compatibilityMode)
  2777. {
  2778. KagScript kag = this.adv_kag.kag;
  2779. int num = kag.callStackDepth - 1;
  2780. int r_callStackDepth = kag.r_callStackDepth;
  2781. if (this.compatibilityCallStackDepth == num && this.compatibilityRCallStackDepth == r_callStackDepth)
  2782. {
  2783. this.compatibilityMode = false;
  2784. }
  2785. }
  2786. }
  2787. public void OnRReturnEvent(string fileName, string labelName)
  2788. {
  2789. if (this.compatibilityMode)
  2790. {
  2791. KagScript kag = this.adv_kag.kag;
  2792. int callStackDepth = kag.callStackDepth;
  2793. int num = kag.r_callStackDepth - 1;
  2794. if (this.compatibilityCallStackDepth == callStackDepth && this.compatibilityRCallStackDepth == num)
  2795. {
  2796. this.compatibilityMode = false;
  2797. }
  2798. }
  2799. }
  2800. public void Dispose()
  2801. {
  2802. this.Dispose(true);
  2803. GC.SuppressFinalize(this);
  2804. }
  2805. protected void Dispose(bool is_release_managed_code)
  2806. {
  2807. if (this.is_disposed_)
  2808. {
  2809. return;
  2810. }
  2811. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  2812. {
  2813. keyValuePair.Value.Dispose();
  2814. }
  2815. this.kag_mot_dic_.Clear();
  2816. if (this.adv_kag_ != null)
  2817. {
  2818. this.adv_kag_.Dispose();
  2819. }
  2820. if (this.yotogi_kag_ != null)
  2821. {
  2822. this.yotogi_kag_.Dispose();
  2823. }
  2824. if (this.tmp_kag_ != null)
  2825. {
  2826. this.tmp_kag_.Dispose();
  2827. }
  2828. if (this.tjs_ != null)
  2829. {
  2830. this.tjs_.Dispose();
  2831. }
  2832. this.is_disposed_ = true;
  2833. }
  2834. public void Serialize(BinaryWriter binary)
  2835. {
  2836. binary.Write("CM3D2_SCRIPT");
  2837. binary.Write(1200);
  2838. this.adv_kag_.Serialize(binary);
  2839. }
  2840. public void Deserialize(BinaryReader binary)
  2841. {
  2842. this.compatibilityMode = false;
  2843. string a = binary.ReadString();
  2844. NDebug.Assert(a == "CM3D2_SCRIPT", "SCRIPTのヘッダーが不正です。");
  2845. int num = binary.ReadInt32();
  2846. this.adv_kag_.Deserialize(binary);
  2847. this.yotogi_kag_.Dispose();
  2848. this.yotogi_kag_ = new YotogiKagManager(this.tjs_, this);
  2849. this.yotogi_kag_.Initialize();
  2850. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  2851. {
  2852. keyValuePair.Value.Dispose();
  2853. }
  2854. this.kag_mot_dic_.Clear();
  2855. MotionKagManager motionKagManager = new MotionKagManager(this.tjs_, this);
  2856. motionKagManager.Initialize();
  2857. motionKagManager.SetSloatNo(0);
  2858. this.kag_mot_dic_.Add(0, motionKagManager);
  2859. this.ExecScript("global.tf = new Dictionary();");
  2860. SubtitleMovieManager.DestroyGlobalInstance();
  2861. }
  2862. public bool compatibilityMode
  2863. {
  2864. get
  2865. {
  2866. return this.compatibilityMode_;
  2867. }
  2868. set
  2869. {
  2870. this.compatibilityMode_ = value;
  2871. if (this.adv_kag_ != null && this.adv_kag_.kag != null)
  2872. {
  2873. this.adv_kag_.kag.SetFileSystem(this.file_system);
  2874. }
  2875. foreach (KeyValuePair<int, MotionKagManager> keyValuePair in this.kag_mot_dic_)
  2876. {
  2877. keyValuePair.Value.kag.SetFileSystem(this.file_system);
  2878. }
  2879. if (this.yotogi_kag_ != null && this.yotogi_kag_.kag != null)
  2880. {
  2881. this.yotogi_kag_.kag.SetFileSystem(this.file_system);
  2882. }
  2883. if (GameMain.Instance.SoundMgr != null)
  2884. {
  2885. GameMain.Instance.SoundMgr.compatibilityMode = value;
  2886. }
  2887. this.StopMotionScript();
  2888. }
  2889. }
  2890. public bool tjsLegacyMode
  2891. {
  2892. get
  2893. {
  2894. return DailyMgr.IsLegacy;
  2895. }
  2896. }
  2897. public bool is_motion_all_prop_seq { get; set; }
  2898. public Maid motion_all_prop_seq_maid { get; set; }
  2899. public bool is_motion_blend { get; set; }
  2900. public TJSScript tjs
  2901. {
  2902. get
  2903. {
  2904. return this.tjs_;
  2905. }
  2906. }
  2907. public ADVKagManager adv_kag
  2908. {
  2909. get
  2910. {
  2911. return this.adv_kag_;
  2912. }
  2913. }
  2914. public YotogiKagManager yotogi_kag
  2915. {
  2916. get
  2917. {
  2918. return this.yotogi_kag_;
  2919. }
  2920. }
  2921. public BaseKagManager tmp_kag
  2922. {
  2923. get
  2924. {
  2925. return this.tmp_kag_;
  2926. }
  2927. }
  2928. public Dictionary<int, MotionKagManager> kag_mot_dic
  2929. {
  2930. get
  2931. {
  2932. return this.kag_mot_dic_;
  2933. }
  2934. }
  2935. public AFileSystemBase file_system
  2936. {
  2937. get
  2938. {
  2939. return (!this.compatibilityMode) ? GameUty.FileSystem : GameUty.FileSystemOld;
  2940. }
  2941. }
  2942. private TJSScript tjs_;
  2943. private Dictionary<int, MotionKagManager> kag_mot_dic_ = new Dictionary<int, MotionKagManager>();
  2944. private ADVKagManager adv_kag_;
  2945. private YotogiKagManager yotogi_kag_;
  2946. private BaseKagManager tmp_kag_;
  2947. private MessageWindowMgr message_mgr_;
  2948. private bool is_disposed_;
  2949. private string debug_yotogi_stage_;
  2950. private bool compatibilityMode_;
  2951. private List<Maid> stock_maid_loop_list = new List<Maid>();
  2952. private int compatibilityCallStackDepth;
  2953. private int compatibilityRCallStackDepth;
  2954. [CompilerGenerated]
  2955. private static Comparison<Maid> <>f__mg$cache0;
  2956. }