MultipleMaids.Gui.cs 405 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964
  1. using ExIni;
  2. using MyRoomCustom;
  3. using System;
  4. using System.Collections;
  5. using System.Collections.Generic;
  6. using System.IO;
  7. using System.Linq;
  8. using System.Text;
  9. using UnityEngine;
  10. using UnityEngine.Rendering;
  11. using Object = UnityEngine.Object;
  12. namespace CM3D2.MultipleMaids.Plugin
  13. {
  14. public partial class MultipleMaids
  15. {
  16. public void OnGUI()
  17. {
  18. for (int index1 = 0; index1 < maidCnt; ++index1)
  19. {
  20. if (isPoseIti[index1])
  21. {
  22. Maid maid = maidArray[index1];
  23. isPoseIti[index1] = false;
  24. maid.transform.position = poseIti[index1];
  25. Vector3 eulerAngles = maid.transform.eulerAngles;
  26. for (int index2 = 0; index2 < 10; ++index2)
  27. {
  28. Transform transform1 = maid.transform;
  29. Vector3 position1 = maid.transform.position;
  30. Vector3 right = Vector3.right;
  31. Quaternion rotation = maid.transform.rotation;
  32. double num1 = -rotation.eulerAngles.x;
  33. transform1.RotateAround(position1, right, (float)num1);
  34. Transform transform2 = maid.transform;
  35. Vector3 position2 = maid.transform.position;
  36. Vector3 forward = Vector3.forward;
  37. rotation = maid.transform.rotation;
  38. double num2 = -rotation.eulerAngles.z;
  39. transform2.RotateAround(position2, forward, (float)num2);
  40. }
  41. Transform transform = CMT.SearchObjName(maid.body0.m_Bones.transform, "Bip01", true);
  42. transform.position = new Vector3(poseIti[index1].x, transform.position.y, poseIti[index1].z);
  43. maid.transform.eulerAngles = eulerAngles;
  44. }
  45. }
  46. GUIStyle style = GUI.skin.box;
  47. style.fontSize = GetPix(11);
  48. style.alignment = TextAnchor.UpperRight;
  49. if (isGuiInit || screenSize != new Vector2(Screen.width, Screen.height))
  50. {
  51. screenSize = new Vector2(Screen.width, Screen.height);
  52. isGuiInit = false;
  53. rectWin2.width = Screen.width * 0.4f;
  54. rectWin2.height = Screen.height * 0.15f;
  55. rectWin2.x = (float)(Screen.width / 2.0 - rectWin2.width / 2.0);
  56. rectWin2.y = sceneLevel != 5
  57. ? Screen.height - rectWin2.height
  58. : Screen.height * 0.94f - rectWin2.height;
  59. rectWin.width = GetPix(kankyoFlg || kankyo2Flg ? 220 : 180);
  60. rectWin.height = Screen.height * 0.9f;
  61. rectWin.x = Screen.width - rectWin.width;
  62. rectWin.y = GetPix(65);
  63. }
  64. if (bGuiMessage)
  65. {
  66. rectWin2.width = Screen.width * 0.4f;
  67. rectWin2.height = Screen.height * 0.15f;
  68. rectWin2.x = Mathf.Clamp(rectWin2.x, -rectWin2.width + GetPix(20), Screen.width - GetPix(20));
  69. rectWin2.y = Mathf.Clamp(rectWin2.y, -rectWin2.height + GetPix(20), Screen.height - GetPix(20));
  70. rectWin2 = GUI.Window(130, rectWin2, MessageWindow, "", style);
  71. }
  72. if (bGui)
  73. {
  74. rectWin.x = Mathf.Clamp(rectWin.x, 0, Screen.width - rectWin.width);
  75. rectWin.y = Mathf.Clamp(rectWin.y, -rectWin.height + GetPix(20), Screen.height - GetPix(20));
  76. rectWin.height = Screen.height * 0.9f;
  77. rectWin.width = GetPix(kankyoFlg || kankyo2Flg ? 220 : 180);
  78. if (sceneLevel == 5 || sceneLevel == 14)
  79. rectWin.height *= 0.85f;
  80. comboBoxControl.height = rectWin.height;
  81. faceCombo.height = rectWin.height;
  82. poseCombo.height = rectWin.height;
  83. poseGroupCombo.height = rectWin.height;
  84. itemCombo.height = rectWin.height;
  85. bgmCombo.height = rectWin.height;
  86. itemCombo2.height = rectWin.height;
  87. bgCombo2.height = rectWin.height;
  88. kankyoCombo.height = rectWin.height;
  89. bgCombo.height = rectWin.height;
  90. slotCombo.height = rectWin.height;
  91. doguCombo.height = rectWin.height;
  92. parCombo.height = rectWin.height;
  93. lightCombo.height = rectWin.height;
  94. GameMain.Instance.MainCamera.SetControl(true);
  95. if (!sceneFlg && !faceFlg && !poseFlg && !kankyoFlg && !kankyo2Flg && !isF6 && okFlg)
  96. {
  97. rectWin = GUI.Window(129, rectWin, MaidCallWindow, "", style);
  98. }
  99. else if (sceneFlg)
  100. {
  101. rectWin = GUI.Window(129, rectWin, SaveSceneWindow, "", style);
  102. Rect rect = default;
  103. dispNo = 0;
  104. for (int index = 0; index < 10; ++index)
  105. {
  106. rect = new Rect(0.0f, 0.0f, GetPix(170), GetPix(36));
  107. rect.x = rectWin.x;
  108. rect.y = rectWin.y - saveSceneScrollPos.y + GetPix(64 + 50 * index);
  109. if (rect.Contains(new Vector2(Input.mousePosition.x, Screen.height - Input.mousePosition.y)))
  110. {
  111. dispNo = index + 1;
  112. break;
  113. }
  114. }
  115. if (saveScene2 > 0)
  116. {
  117. dispNo = 0;
  118. }
  119. if (dispNo == 0)
  120. {
  121. texture2D = null;
  122. dispNoOld = 0;
  123. }
  124. else if (dispNo != dispNoOld)
  125. {
  126. dispNoOld = dispNo;
  127. texture2D = null;
  128. try
  129. {
  130. IniKey iniKey = Preferences["scene"]["ss" + (page * 10 + dispNo)];
  131. if (iniKey.Value != null && iniKey.Value != "")
  132. {
  133. byte[] data = Convert.FromBase64String(iniKey.Value);
  134. texture2D = new Texture2D(1, 1, TextureFormat.ARGB32, false);
  135. texture2D.LoadImage(data);
  136. }
  137. }
  138. catch { }
  139. }
  140. if (texture2D != null)
  141. {
  142. if (waku == null)
  143. {
  144. waku = MakeTex(2, 2, new Color(1f, 1f, 1f, 1f));
  145. waku2 = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.4f));
  146. }
  147. Rect position1 = new Rect(rect.x - texture2D.width - GetPix(18),
  148. rect.y - texture2D.height / 2 + GetPix(12),
  149. texture2D.width + GetPix(12),
  150. texture2D.height + GetPix(12));
  151. Rect position2 = new Rect(rect.x - texture2D.width - GetPix(12),
  152. rect.y - texture2D.height / 2 + GetPix(18),
  153. texture2D.width,
  154. texture2D.height);
  155. Rect position3 = new Rect(rect.x - texture2D.width - GetPix(16),
  156. rect.y - texture2D.height / 2 + GetPix(14),
  157. texture2D.width + GetPix(12),
  158. texture2D.height + GetPix(12));
  159. if (position1.y + (double)position1.height > Screen.height)
  160. {
  161. float num = position3.y + position3.height - Screen.height;
  162. position1.y -= num;
  163. position2.y -= num;
  164. position3.y -= num;
  165. }
  166. if (position1.y < 0)
  167. {
  168. position3.y -= position1.y;
  169. position2.y -= position1.y;
  170. position1.y -= position1.y;
  171. }
  172. if (rect.x + rect.width / 2 <= Screen.width / 2)
  173. {
  174. float offset = texture2D.width + rect.width + GetPix(24);
  175. position1.x += offset;
  176. position2.x += offset;
  177. position3.x += offset;
  178. }
  179. GUI.DrawTexture(position3, waku2);
  180. GUI.DrawTexture(position1, waku);
  181. GUI.DrawTexture(position2, texture2D);
  182. }
  183. }
  184. else if (kankyoFlg)
  185. {
  186. if (!yotogiFlg && sceneLevel != 3 && sceneLevel != 5
  187. && rectWin.Contains(Event.current.mousePosition)
  188. && Input.GetMouseButtonDown(0))
  189. {
  190. Input.ResetInputAxes();
  191. }
  192. rectWin = GUI.Window(129, rectWin, BGSelectWindow, "", style);
  193. }
  194. else if (kankyo2Flg)
  195. {
  196. if (!yotogiFlg && sceneLevel != 3 && sceneLevel != 5
  197. && rectWin.Contains(Event.current.mousePosition)
  198. && Input.GetMouseButtonDown(0))
  199. {
  200. Input.ResetInputAxes();
  201. }
  202. rectWin = GUI.Window(129, rectWin, BGSelectWindow2, "", style);
  203. }
  204. else if (poseFlg)
  205. {
  206. if (!yotogiFlg && sceneLevel != 3 && sceneLevel != 5
  207. && rectWin.Contains(Event.current.mousePosition)
  208. && Input.GetMouseButtonDown(0))
  209. {
  210. Input.ResetInputAxes();
  211. }
  212. rectWin = GUI.Window(129, rectWin, PoseWindow, "", style);
  213. }
  214. else // implies faceFlg == true
  215. {
  216. if (!yotogiFlg && sceneLevel != 3 && sceneLevel != 5
  217. && rectWin.Contains(Event.current.mousePosition)
  218. && Input.GetMouseButtonDown(0))
  219. {
  220. Input.ResetInputAxes();
  221. }
  222. rectWin = GUI.Window(129, rectWin, FaceWindow, "", style);
  223. }
  224. }
  225. }
  226. private void SaveSceneWindow(int winID)
  227. {
  228. GUIStyle style1 = "label";
  229. style1.fontSize = GetPix(12);
  230. style1.alignment = TextAnchor.UpperLeft;
  231. GUIStyle style2 = "button";
  232. style2.fontSize = GetPix(12);
  233. style2.alignment = TextAnchor.MiddleCenter;
  234. GUI.Label(new Rect(GetPix(50), GetPix(6), GetPix(100), GetPix(25)),
  235. "シーン管理",
  236. style1);
  237. if (GUI.Button(new Rect(GetPix(135), GetPix(3), GetPix(23), GetPix(23)),
  238. "→",
  239. style2))
  240. {
  241. faceFlg = false;
  242. poseFlg = false;
  243. sceneFlg = false;
  244. kankyoFlg = true;
  245. kankyo2Flg = false;
  246. bGui = true;
  247. copyIndex = 0;
  248. }
  249. if (GUI.Button(new Rect(GetPix(25), GetPix(31), GetPix(23), GetPix(23)),
  250. "<",
  251. style2))
  252. {
  253. saveSceneScrollPos.y = 0.0f;
  254. --page;
  255. if (page < 0)
  256. {
  257. page = maxPage - 1;
  258. }
  259. for (int index = 0; index < 10; ++index)
  260. {
  261. date[index] = "未保存";
  262. ninzu[index] = "";
  263. IniKey iniKey = Preferences["scene"]["s" + (page * 10 + index + 1)];
  264. if (iniKey.Value != null && iniKey.Value.ToString() != "")
  265. {
  266. string[] strArray1 = iniKey.Value.Split('_');
  267. if (strArray1.Length >= 2)
  268. {
  269. string[] strArray2 = strArray1[0].Split(',');
  270. date[index] = strArray2[0];
  271. ninzu[index] = strArray2[1] + "人";
  272. }
  273. }
  274. }
  275. }
  276. if (GUI.Button(new Rect(GetPix(115), GetPix(31), GetPix(23), GetPix(23)),
  277. ">",
  278. style2))
  279. {
  280. saveSceneScrollPos.y = 0.0f;
  281. ++page;
  282. if (page >= maxPage)
  283. {
  284. page = 0;
  285. }
  286. for (int index = 0; index < 10; ++index)
  287. {
  288. date[index] = "未保存";
  289. ninzu[index] = "";
  290. IniKey iniKey = Preferences["scene"]["s" + (page * 10 + index + 1)];
  291. if (iniKey.Value != null && iniKey.Value.ToString() != "")
  292. {
  293. string[] strArray1 = iniKey.Value.Split('_');
  294. if (strArray1.Length >= 2)
  295. {
  296. string[] strArray2 = strArray1[0].Split(',');
  297. date[index] = strArray2[0];
  298. ninzu[index] = strArray2[1] + "人";
  299. }
  300. }
  301. }
  302. }
  303. GUI.Label(new Rect(GetPix(60), GetPix(32), GetPix(100), GetPix(25)),
  304. (page * 10 + 1).ToString() + " ~ " + (page * 10 + 10),
  305. style1);
  306. if (saveScene2 > 0 && string.IsNullOrEmpty(thum_byte_to_base64_) && File.Exists(thum_file_path_))
  307. {
  308. try
  309. {
  310. Texture2D tex = new Texture2D(1, 1, TextureFormat.ARGB32, false);
  311. tex.LoadImage(File.ReadAllBytes(thum_file_path_));
  312. float num2 = tex.width / (float)tex.height;
  313. Vector2 vector2 = new Vector2(480f, 270f);
  314. int newWidth = tex.width;
  315. int newHeight = tex.height;
  316. if (vector2.x < (double)tex.width && vector2.y < (double)tex.height)
  317. {
  318. newWidth = (int)vector2.x;
  319. newHeight = Mathf.RoundToInt(newWidth / num2);
  320. if (vector2.y < (double)newHeight)
  321. {
  322. newHeight = (int)vector2.y;
  323. newWidth = Mathf.RoundToInt(newHeight * num2);
  324. }
  325. }
  326. else if (vector2.x < (double)tex.width)
  327. {
  328. newWidth = (int)vector2.x;
  329. newHeight = Mathf.RoundToInt(newWidth / num2);
  330. }
  331. else if (vector2.y < (double)tex.height)
  332. {
  333. newHeight = (int)vector2.y;
  334. newWidth = Mathf.RoundToInt(newHeight * num2);
  335. }
  336. TextureScale.Bilinear(tex, newWidth, newHeight);
  337. thum_byte_to_base64_ = Convert.ToBase64String(tex.EncodeToPNG());
  338. DestroyImmediate(tex);
  339. Preferences["scene"]["ss" + saveScene2].Value = thum_byte_to_base64_;
  340. SaveConfig();
  341. thum_file_path_ = "";
  342. saveScene2 = 0;
  343. }
  344. catch { }
  345. }
  346. int offsetTop = GetPix(31) + GetPix(23) + GetPix(5);
  347. int UIHeight = GetPix(500);
  348. Rect saveSceneScrollRect = new Rect(0, offsetTop, rectWin.width, rectWin.height - offsetTop);
  349. Rect saveSceneScrollView = new Rect(0, 0, rectWin.width - 20, UIHeight);
  350. saveSceneScrollPos = GUI.BeginScrollView(saveSceneScrollRect, saveSceneScrollPos, saveSceneScrollView);
  351. int saveSlotOffset = 50;
  352. for (int index = 0; index < 10; ++index)
  353. {
  354. GUI.Label(new Rect(GetPix(5),
  355. GetPix(saveSlotOffset * index),
  356. GetPix(25),
  357. GetPix(25)),
  358. string.Concat(page * 10 + index + 1),
  359. style1);
  360. GUI.Label(new Rect(GetPix(25),
  361. GetPix(saveSlotOffset * index),
  362. GetPix(100),
  363. GetPix(25)),
  364. date[index],
  365. style1);
  366. GUI.Label(new Rect(GetPix(130),
  367. GetPix(saveSlotOffset * index),
  368. GetPix(100),
  369. GetPix(25)),
  370. ninzu[index],
  371. style1);
  372. if (GUI.Button(new Rect(GetPix(20),
  373. GetPix(18 + saveSlotOffset * index),
  374. GetPix(50),
  375. GetPix(20)),
  376. "保存",
  377. style2))
  378. {
  379. saveScene = page * 10 + index + 1;
  380. saveScene2 = saveScene;
  381. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  382. isScreen2 = true;
  383. if (!isMessage)
  384. {
  385. ui_cam_hide_list_.Clear();
  386. foreach (UICamera uiCamera in NGUITools.FindActive<UICamera>())
  387. {
  388. if (uiCamera.GetComponent<Camera>().enabled)
  389. {
  390. uiCamera.GetComponent<Camera>().enabled = false;
  391. ui_cam_hide_list_.Add(uiCamera);
  392. }
  393. }
  394. }
  395. else
  396. {
  397. editUI = GameObject.Find("/UI Root/Camera");
  398. if (editUI != null)
  399. {
  400. editUI.SetActive(false);
  401. }
  402. if (GameMain.Instance.CMSystem.ViewFps)
  403. {
  404. UTY.GetChildObject(GameMain.Instance.gameObject, "SystemUI Root/FpsCounter", false).SetActive(false);
  405. }
  406. GameObject childObject1 = UTY.GetChildObject(GameMain.Instance.gameObject, "SystemUI Root/SystemDialog", false);
  407. GameObject childObject2 = UTY.GetChildObject(GameMain.Instance.gameObject, "SystemUI Root/SystemShortcut", false);
  408. childObject1.SetActive(false);
  409. childObject2.SetActive(false);
  410. }
  411. isGui = bGui;
  412. bGui = false;
  413. try
  414. {
  415. thum_byte_to_base64_ = string.Empty;
  416. thum_file_path_ = Path.Combine(Path.GetTempPath(), "cm3d2_" + Guid.NewGuid().ToString() + ".png");
  417. GameMain.Instance.MainCamera.ScreenShot(thum_file_path_, 1, true);
  418. }
  419. catch { }
  420. }
  421. if (date[index] != "未保存" && GUI.Button(new Rect(GetPix(100),
  422. GetPix(18 + saveSlotOffset * index),
  423. GetPix(50),
  424. GetPix(20)),
  425. "読込",
  426. style2))
  427. {
  428. loadScene = page * 10 + index + 1;
  429. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  430. }
  431. }
  432. GUI.EndScrollView();
  433. GUI.DragWindow();
  434. }
  435. private void BGSelectWindow2(int winID)
  436. {
  437. GUIStyle guiStyle1 = "label";
  438. guiStyle1.fontSize = GetPix(12);
  439. guiStyle1.alignment = TextAnchor.UpperLeft;
  440. GUIStyle style1 = "label";
  441. style1.fontSize = GetPix(11);
  442. style1.alignment = TextAnchor.UpperLeft;
  443. GUIStyle style2 = "button";
  444. style2.fontSize = GetPix(20);
  445. GUIStyle buttonStyle = "button";
  446. buttonStyle.fontSize = GetPix(14);
  447. buttonStyle.alignment = TextAnchor.MiddleLeft;
  448. GUIStyle guiStyle2 = "button";
  449. guiStyle2.fontSize = GetPix(12);
  450. guiStyle2.alignment = TextAnchor.MiddleLeft;
  451. GUIStyle style3 = new GUIStyle("toggle")
  452. {
  453. fontSize = GetPix(13)
  454. };
  455. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  456. Maid maid = maidArray[selectMaidIndex];
  457. if (!kankyo2InitFlg)
  458. {
  459. listStyle2.normal.textColor = Color.white;
  460. listStyle2.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  461. listStyle2.onHover.background = listStyle2.hover.background = new Texture2D(2, 2);
  462. listStyle2.padding.left = listStyle2.padding.right = listStyle2.padding.top = listStyle2.padding.bottom = GetPix(0);
  463. listStyle2.fontSize = GetPix(11);
  464. listStyle3.normal.textColor = Color.white;
  465. listStyle3.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  466. listStyle3.onHover.background = listStyle3.hover.background = new Texture2D(2, 2);
  467. listStyle3.padding.left = listStyle3.padding.right = listStyle3.padding.top = GetPix(0);
  468. listStyle3.padding.bottom = GetPix(0);
  469. listStyle3.fontSize = GetPix(14);
  470. bgCombo2.selectedItemIndex = bgIndexB;
  471. bgCombo2List = new GUIContent[bgArray.Length];
  472. for (int index = 0; index < bgArray.Length; ++index)
  473. {
  474. bgCombo2List[index] = bgUiNames.TryGetValue(bgArray[index], out string name)
  475. ? new GUIContent(name)
  476. : new GUIContent(bgArray[index]);
  477. }
  478. slotCombo.selectedItemIndex = 0;
  479. slotComboList = slotArray.Select(s => slotUiNames.TryGetValue(s, out string name) ? name : s).Select(s => new GUIContent(s)).ToArray();
  480. itemCombo2.selectedItemIndex = 0;
  481. itemCombo2List = itemBArray.Select(s => itemComboUiName.TryGetValue(s, out string name) ? name : s)
  482. .Select(s => new GUIContent(s)).ToArray();
  483. kankyoCombo.selectedItemIndex = 0;
  484. kankyoComboList = new GUIContent[kankyoMax];
  485. for (int index = 0; index < kankyoMax; ++index)
  486. {
  487. IniKey iniKey = Preferences["kankyo"]["kankyo" + (index + 1)];
  488. kankyoComboList[index] = new GUIContent(iniKey.Value);
  489. }
  490. kankyo2InitFlg = true;
  491. }
  492. listStyle3.padding.top = GetPix(1);
  493. listStyle3.padding.bottom = GetPix(0);
  494. listStyle3.fontSize = GetPix(13);
  495. if (poseCombo.isClickedComboButton)
  496. {
  497. GUI.enabled = false;
  498. }
  499. if (poseGroupCombo.isClickedComboButton)
  500. {
  501. GUI.enabled = false;
  502. }
  503. if (sceneLevel == 3 || sceneLevel == 5 || isF6)
  504. {
  505. if (!isF6)
  506. {
  507. bool flag = true;
  508. if (faceFlg || poseFlg || sceneFlg || kankyoFlg || kankyo2Flg)
  509. {
  510. flag = false;
  511. }
  512. if (GUI.Toggle(new Rect(GetPix(2),
  513. GetPix(2),
  514. GetPix(39),
  515. GetPix(20)),
  516. flag,
  517. "配置",
  518. style3))
  519. {
  520. faceFlg = false;
  521. poseFlg = false;
  522. sceneFlg = false;
  523. kankyoFlg = false;
  524. kankyo2Flg = false;
  525. bGui = true;
  526. }
  527. }
  528. if (!yotogiFlg && GUI.Toggle(new Rect(GetPix(42),
  529. GetPix(2),
  530. GetPix(39),
  531. GetPix(20)),
  532. poseFlg,
  533. "操作",
  534. style3))
  535. {
  536. poseFlg = true;
  537. faceFlg = false;
  538. sceneFlg = false;
  539. kankyoFlg = false;
  540. kankyo2Flg = false;
  541. }
  542. if (GUI.Toggle(new Rect(GetPix(82), GetPix(2), GetPix(39), GetPix(20)),
  543. faceFlg,
  544. "表情",
  545. style3))
  546. {
  547. faceFlg = true;
  548. poseFlg = false;
  549. sceneFlg = false;
  550. kankyoFlg = false;
  551. kankyo2Flg = false;
  552. if (!faceFlg2)
  553. {
  554. isFaceInit = true;
  555. faceFlg2 = true;
  556. maidArray[selectMaidIndex].boMabataki = false;
  557. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  558. }
  559. isFaceInit = true;
  560. }
  561. if (GUI.Toggle(new Rect(GetPix(122), GetPix(2), GetPix(39), GetPix(20)),
  562. kankyoFlg,
  563. "環境",
  564. style3))
  565. {
  566. poseFlg = false;
  567. faceFlg = false;
  568. sceneFlg = false;
  569. kankyoFlg = true;
  570. kankyo2Flg = false;
  571. }
  572. if (GUI.Toggle(new Rect(GetPix(162), GetPix(2), GetPix(39), GetPix(20)),
  573. kankyo2Flg,
  574. "環2",
  575. style3))
  576. {
  577. poseFlg = false;
  578. faceFlg = false;
  579. sceneFlg = false;
  580. kankyoFlg = false;
  581. kankyo2Flg = true;
  582. }
  583. if (!line1)
  584. {
  585. line1 = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.3f));
  586. line2 = MakeTex(2, 2, new Color(0.7f, 0.7f, 0.7f, 0.6f));
  587. }
  588. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(200), 2f), line1);
  589. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(200), 1f), line2);
  590. }
  591. if (isDanceStop)
  592. {
  593. isStop[selectMaidIndex] = true;
  594. isDanceStop = false;
  595. }
  596. if (kankyoCombo.isClickedComboButton || slotCombo.isClickedComboButton
  597. || itemCombo2.isClickedComboButton || bgCombo2.isClickedComboButton)
  598. {
  599. GUI.enabled = false;
  600. }
  601. if (!modItemsOnly)
  602. {
  603. bool previousGUIState = GUI.enabled;
  604. GUI.enabled = slotIndex > 1;
  605. modItemsToggle = GUI.Toggle(new Rect(GetPix(156),
  606. GetPix(115),
  607. GetPix(50),
  608. GetPix(20)),
  609. modItemsToggle,
  610. "Mods",
  611. style3
  612. );
  613. GUI.enabled = previousGUIState;
  614. }
  615. int iconSize = GetPix(45);
  616. Rect position1;
  617. Rect viewRect;
  618. int bg2ItemCount = slotIndex == 1 ?
  619. creativeSortList.Count :
  620. (!modItemsOnly && modItemsToggle) ?
  621. numberOfModItems : sortList.Count;
  622. if (sceneLevel != 5)
  623. {
  624. position1 = new Rect(GetPix(7),
  625. GetPix(138),
  626. GetPix(44) * 4 + GetPix(20),
  627. rectWin.height - GetPix(148));
  628. viewRect = new Rect(0.0f,
  629. 0.0f,
  630. position1.width * 0.845f,
  631. Mathf.Ceil(bg2ItemCount / 4f) * iconSize + GetPix(10));
  632. }
  633. else
  634. {
  635. position1 = new Rect(GetPix(7),
  636. GetPix(138),
  637. GetPix(44) * 4 + GetPix(20),
  638. rectWin.height - GetPix(148));
  639. viewRect = new Rect(0.0f,
  640. 0.0f,
  641. position1.width * 0.845f,
  642. Mathf.Ceil(bg2ItemCount / 4f) * iconSize + GetPix(10));
  643. }
  644. bg2ScrollPos = GUI.BeginScrollView(position1, bg2ScrollPos, viewRect);
  645. int bg2Index = 0;
  646. List<SortItem> bg2List = slotIndex == 1 ? creativeSortList : sortList;
  647. foreach (SortItem sortItem in bg2List)
  648. {
  649. if (slotIndex > 1 && modItemsToggle && !sortItem.isMod)
  650. {
  651. continue;
  652. }
  653. Rect position2 = new Rect(
  654. bg2Index % 4 * iconSize,
  655. bg2Index / 4 * iconSize,
  656. iconSize,
  657. iconSize
  658. );
  659. if (GUI.Button(position2, ""))
  660. {
  661. GameObject gameObject = null;
  662. if (slotIndex > 1)
  663. {
  664. string menu = sortItem.menu;
  665. byte[] modBuf = null;
  666. bool ready = true;
  667. if (sortItem.isOfficialMod)
  668. {
  669. menu = sortItem.baseMenu;
  670. using (FileStream fileStream = new FileStream(sortItem.menu, FileMode.Open))
  671. {
  672. if (fileStream == null)
  673. {
  674. ready = false;
  675. }
  676. else
  677. {
  678. modBuf = new byte[fileStream.Length];
  679. fileStream.Read(modBuf, 0, (int)fileStream.Length);
  680. }
  681. }
  682. }
  683. byte[] menuBuf = null;
  684. using (AFileBase afileBase = GameUty.FileOpen(menu, null))
  685. {
  686. if (ready = afileBase.IsValid())
  687. {
  688. menuBuf = afileBase.ReadAll();
  689. }
  690. }
  691. if (ready)
  692. {
  693. string[] meshInfo = ProcScriptBin(menuBuf);
  694. gameObject = ImportCM2.LoadSkinMesh_R(meshInfo[0], meshInfo, 1);
  695. gameObject.name = menu;
  696. if (sortItem.isOfficialMod)
  697. {
  698. gameObject.name += $"#{Path.GetFileName(sortItem.menu)}";
  699. ProcModScriptBin(modBuf, gameObject);
  700. }
  701. }
  702. }
  703. else
  704. {
  705. // My Room Custom content
  706. PlacementData.Data data = PlacementData.GetData(int.Parse(sortItem.menu));
  707. gameObject = Instantiate(data.GetPrefab());
  708. gameObject.name = $"creative_{sortItem.baseMenu}";
  709. }
  710. if (gameObject != null)
  711. {
  712. doguBObject.Add(gameObject);
  713. gameObject.transform.position = new Vector3(0, 0, 0.4f);
  714. doguCnt = doguBObject.Count - 1;
  715. gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  716. gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
  717. gDogu[doguCnt].layer = 8;
  718. gDogu[doguCnt].GetComponent<Renderer>().enabled = false;
  719. gDogu[doguCnt].SetActive(false);
  720. gDogu[doguCnt].transform.position = gameObject.transform.position;
  721. mDogu[doguCnt] = gDogu[doguCnt].AddComponent<MouseDrag6>();
  722. mDogu[doguCnt].isScale = false;
  723. mDogu[doguCnt].obj = gDogu[doguCnt];
  724. mDogu[doguCnt].maid = gameObject;
  725. mDogu[doguCnt].angles = gameObject.transform.eulerAngles;
  726. gDogu[doguCnt].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  727. mDogu[doguCnt].ido = 1;
  728. }
  729. }
  730. GUI.DrawTexture(position2, sortItem.tex);
  731. bg2Index++;
  732. }
  733. GUI.EndScrollView();
  734. GUI.enabled = true;
  735. GUI.Label(new Rect(GetPix(3), GetPix(108), GetPix(100), GetPix(25)),
  736. "服装",
  737. style1);
  738. style1.fontSize = GetPix(9);
  739. GUI.Label(new Rect(GetPix(3), GetPix(119), GetPix(100), GetPix(25)),
  740. "アクセサリ",
  741. style1);
  742. style1.fontSize = GetPix(11);
  743. GUI.Label(new Rect(GetPix(3), GetPix(58), GetPix(100), GetPix(25)),
  744. "アイテム",
  745. style1);
  746. GUI.Label(new Rect(GetPix(3), GetPix(86), GetPix(100), GetPix(24)),
  747. "背景(小)",
  748. style1);
  749. if (kankyoCombo.isClickedComboButton || itemCombo2.isClickedComboButton || bgCombo2.isClickedComboButton)
  750. {
  751. GUI.enabled = false;
  752. }
  753. int num1 =
  754. slotCombo.List(new Rect(GetPix(51),
  755. GetPix(111),
  756. GetPix(100),
  757. GetPix(23)),
  758. slotComboList[slotIndex].text,
  759. slotComboList,
  760. buttonStyle,
  761. "box",
  762. listStyle3);
  763. GUI.enabled = true;
  764. if (kankyoCombo.isClickedComboButton || itemCombo2.isClickedComboButton)
  765. {
  766. GUI.enabled = false;
  767. }
  768. bgIndexB =
  769. bgCombo2.List(new Rect(GetPix(51),
  770. GetPix(83),
  771. GetPix(100),
  772. GetPix(23)),
  773. bgCombo2List[bgIndexB].text,
  774. bgCombo2List,
  775. buttonStyle,
  776. "box",
  777. listStyle3);
  778. if (GUI.Button(new Rect(GetPix(156), GetPix(83), GetPix(38), GetPix(23)),
  779. "追加",
  780. style2))
  781. {
  782. Object original = GameMain.Instance.BgMgr.CreateAssetBundle(bgArray[bgIndexB]);
  783. if (original == null)
  784. {
  785. original = Resources.Load("BG/" + bgArray[bgIndexB]);
  786. }
  787. GameObject gameObject = Instantiate(original) as GameObject;
  788. doguBObject.Add(gameObject);
  789. gameObject.name = "BG_" + bgArray[bgIndexB];
  790. Vector3 zero1 = Vector3.zero;
  791. Vector3 zero2 = Vector3.zero;
  792. zero1.z = 0.4f;
  793. gameObject.transform.localScale = new Vector3(0.1f, 0.1f, 0.1f);
  794. gameObject.transform.localPosition = zero1;
  795. gameObject.transform.localRotation = Quaternion.Euler(zero2);
  796. doguCnt = doguBObject.Count - 1;
  797. gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  798. gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
  799. gDogu[doguCnt].layer = 8;
  800. gDogu[doguCnt].GetComponent<Renderer>().enabled = false;
  801. gDogu[doguCnt].SetActive(false);
  802. gDogu[doguCnt].transform.position = gameObject.transform.position;
  803. mDogu[doguCnt] = gDogu[doguCnt].AddComponent<MouseDrag6>();
  804. mDogu[doguCnt].isScale = false;
  805. mDogu[doguCnt].obj = gDogu[doguCnt];
  806. mDogu[doguCnt].maid = gameObject;
  807. mDogu[doguCnt].angles = gameObject.transform.eulerAngles;
  808. gDogu[doguCnt].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  809. mDogu[doguCnt].ido = 1;
  810. }
  811. GUI.enabled = true;
  812. if (kankyoCombo.isClickedComboButton)
  813. {
  814. GUI.enabled = false;
  815. }
  816. itemIndexB =
  817. itemCombo2.List(new Rect(GetPix(51),
  818. GetPix(55),
  819. GetPix(100),
  820. GetPix(23)),
  821. itemCombo2List[itemIndexB].text,
  822. itemCombo2List,
  823. buttonStyle,
  824. "box",
  825. listStyle3);
  826. if (GUI.Button(new Rect(GetPix(156), GetPix(55), GetPix(38), GetPix(23)),
  827. "追加",
  828. style2))
  829. {
  830. string str = itemBArray[itemIndexB].Split(',')[1];
  831. byte[] f_byBuf = null;
  832. using (AFileBase afileBase = GameUty.FileOpen(str, null))
  833. {
  834. NDebug.Assert(afileBase.IsValid(), "メニューファイルが存在しません。 :" + str);
  835. if (f_byBuf == null || f_byBuf.Length < afileBase.GetSize())
  836. {
  837. f_byBuf = new byte[afileBase.GetSize()];
  838. }
  839. afileBase.Read(ref f_byBuf, afileBase.GetSize());
  840. }
  841. string[] filename2 = ProcScriptBin(f_byBuf);
  842. GameObject gameObject = ImportCM2.LoadSkinMesh_R(filename2[0], filename2, 1);
  843. doguBObject.Add(gameObject);
  844. gameObject.name = str;
  845. Vector3 zero1 = Vector3.zero;
  846. Vector3 zero2 = Vector3.zero;
  847. zero1.z = 0.4f;
  848. switch (itemIndexB)
  849. {
  850. case 0:
  851. zero2.z = 90f;
  852. zero1.y = 0.04f;
  853. goto case 19;
  854. case 1:
  855. zero2.z = 90f;
  856. goto case 19;
  857. case 4:
  858. zero2.x = 90f;
  859. goto case 19;
  860. case 19:
  861. case 20:
  862. case 21:
  863. case 22:
  864. case 23:
  865. switch (gameObject.name)
  866. {
  867. case "HandItemL_Etoile_Saucer_I_.menu":
  868. case "HandItemL_Karte_I_.menu":
  869. case "HandItemL_Katuramuki_Daikon_I_.menu":
  870. case "HandItemR_BeerBottle(cap_off)_I_.menu":
  871. case "HandItemR_BeerBottle(cap_on)_I_.menu":
  872. case "HandItemR_BeerGlass_I_.menu":
  873. case "HandItemR_Etoile_Teacup_I_.menu":
  874. case "HandItemR_Jyouro_I_.menu":
  875. case "HandItemR_Ketchup_I_.menu":
  876. case "HandItemR_Kobin_I_.menu":
  877. case "HandItemR_MelonSoda_I_.menu":
  878. case "HandItemR_MilkBottle(cap_off)_I_.menu":
  879. case "HandItemR_MilkBottle(cap_on)_I_.menu":
  880. case "HandItemR_Mugcup_I_.menu":
  881. case "HandItemR_Natumikan_I_.menu":
  882. case "HandItemR_Nei_Heartful_I_.menu":
  883. case "HandItemR_Ochoko_I_.menu":
  884. case "HandItemR_Shaker_I_.menu":
  885. case "HandItemR_SmartPhone_I_.menu":
  886. case "HandItemR_Suika_I_.menu":
  887. case "HandItemR_Tomato_I_.menu":
  888. case "HandItemR_TropicalGlass_I_.menu":
  889. case "HandItemR_cocktail_blue_I_.menu":
  890. case "HandItemR_cocktail_red_I_.menu":
  891. case "HandItemR_cocktail_yellow_I_.menu":
  892. case "HandItemR_smoothie_green_I_.menu":
  893. case "HandItemR_smoothie_red_I_.menu":
  894. zero2.x = 0.0f;
  895. zero2.z = 90f;
  896. break;
  897. case "HandItemL_Karaoke_Mike_I_.menu":
  898. case "HandItemR_Crops_Suika_I_.menu":
  899. case "HandItemR_Curry_I_.menu":
  900. case "HandItemR_DVD1_I_.menu":
  901. case "HandItemR_DVD2_I_.menu":
  902. case "HandItemR_DVD3_I_.menu":
  903. case "HandItemR_DVD4_I_.menu":
  904. case "HandItemR_DVD5_I_.menu":
  905. case "HandItemR_Folk_I_.menu":
  906. case "HandItemR_Hanabi_I_.menu":
  907. case "HandItemR_Kushiyaki_I_.menu":
  908. case "HandItemR_Ninjin_I_.menu":
  909. case "HandItemR_Omurice1_I_.menu":
  910. case "HandItemR_Omurice2_I_.menu":
  911. case "HandItemR_Omurice3_I_.menu":
  912. case "HandItemR_Pasta_I_.menu":
  913. case "HandItemR_Satumaimo_I_.menu":
  914. case "HandItemR_Scoop_I_.menu":
  915. case "HandItemR_Senkouhanabi_I_.menu":
  916. case "HandItemR_Shell_I_.menu":
  917. case "HandItemR_Spoon_Curry_I_.menu":
  918. case "HandItemR_Spoon_Omurice_I_.menu":
  919. case "HandItemR_Tomorokoshi_I_.menu":
  920. case "HandItemR_Tomorokoshi_yaki_I_.menu":
  921. case "HandItemR_Uchiwa_I_.menu":
  922. zero2.z = 90f;
  923. break;
  924. }
  925. gameObject.transform.localPosition = zero1;
  926. gameObject.transform.localRotation = Quaternion.Euler(zero2);
  927. doguCnt = doguBObject.Count - 1;
  928. gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  929. gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
  930. gDogu[doguCnt].layer = 8;
  931. gDogu[doguCnt].GetComponent<Renderer>().enabled = false;
  932. gDogu[doguCnt].SetActive(false);
  933. gDogu[doguCnt].transform.position = gameObject.transform.position;
  934. mDogu[doguCnt] = gDogu[doguCnt].AddComponent<MouseDrag6>();
  935. mDogu[doguCnt].isScale = false;
  936. mDogu[doguCnt].obj = gDogu[doguCnt];
  937. mDogu[doguCnt].maid = gameObject;
  938. mDogu[doguCnt].angles = gameObject.transform.eulerAngles;
  939. gDogu[doguCnt].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  940. mDogu[doguCnt].ido = 1;
  941. break;
  942. case 25:
  943. zero2.z = 90f;
  944. goto case 19;
  945. case 26:
  946. zero2.z = 90f;
  947. goto case 19;
  948. case 27:
  949. zero2.z = 90f;
  950. goto case 19;
  951. default:
  952. zero2.x = -90f;
  953. goto case 19;
  954. }
  955. }
  956. GUI.enabled = true;
  957. if (nameFlg)
  958. {
  959. inName2 = GUI.TextField(new Rect(GetPix(5),
  960. GetPix(27),
  961. GetPix(100),
  962. GetPix(20)),
  963. inName2);
  964. if (GUI.Button(new Rect(GetPix(110),
  965. GetPix(27),
  966. GetPix(35),
  967. GetPix(20)),
  968. "更新",
  969. style2))
  970. {
  971. nameFlg = false;
  972. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  973. Preferences["kankyo"]["kankyo" + (kankyoCombo.selectedItemIndex + 1)].Value = inName2;
  974. SaveConfig();
  975. kankyoComboList = new GUIContent[kankyoMax];
  976. for (int index = 0; index < kankyoMax; ++index)
  977. {
  978. IniKey iniKey = Preferences["kankyo"]["kankyo" + (index + 1)];
  979. kankyoComboList[index] = new GUIContent(iniKey.Value);
  980. }
  981. }
  982. }
  983. else
  984. {
  985. if (GUI.Button(new Rect(GetPix(180),
  986. GetPix(27),
  987. GetPix(24),
  988. GetPix(20)),
  989. "名",
  990. style2))
  991. {
  992. nameFlg = true;
  993. inName2 = kankyoComboList[kankyoIndex].text;
  994. }
  995. kankyoIndex =
  996. kankyoCombo.List(new Rect(GetPix(4),
  997. GetPix(27),
  998. GetPix(91),
  999. GetPix(23)),
  1000. kankyoComboList[kankyoIndex].text,
  1001. kankyoComboList,
  1002. buttonStyle,
  1003. "box",
  1004. listStyle3);
  1005. if (GUI.Button(new Rect(GetPix(100),
  1006. GetPix(27),
  1007. GetPix(35),
  1008. GetPix(20)),
  1009. "保存",
  1010. style2))
  1011. {
  1012. saveScene = 10000 + kankyoIndex;
  1013. saveScene2 = saveScene;
  1014. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  1015. try
  1016. {
  1017. thum_byte_to_base64_ = string.Empty;
  1018. thum_file_path_ = Path.Combine(Path.GetTempPath(), "cm3d2_" + Guid.NewGuid().ToString() + ".png");
  1019. GameMain.Instance.MainCamera.ScreenShot(thum_file_path_, 1, false);
  1020. }
  1021. catch { }
  1022. }
  1023. GUI.enabled = false;
  1024. IniKey iniKey = Preferences["scene"]["s" + (10000 + kankyoIndex)];
  1025. if (iniKey.Value != null && iniKey.Value.ToString() != "")
  1026. {
  1027. GUI.enabled = true;
  1028. }
  1029. if (GUI.Button(new Rect(GetPix(140),
  1030. GetPix(27),
  1031. GetPix(35),
  1032. GetPix(20)),
  1033. "読込",
  1034. style2))
  1035. {
  1036. loadScene = 10000 + kankyoIndex;
  1037. kankyoLoadFlg = true;
  1038. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  1039. }
  1040. }
  1041. GUI.enabled = true;
  1042. GUI.DragWindow();
  1043. if (num1 == slotIndex)
  1044. {
  1045. return;
  1046. }
  1047. numberOfModItems = 0;
  1048. slotIndex = num1;
  1049. sortList.Clear();
  1050. bg2ScrollPos = new Vector2(0.0f, 0.0f);
  1051. if (slotIndex == 0)
  1052. {
  1053. return;
  1054. }
  1055. else if (slotIndex == 1)
  1056. {
  1057. if (creativeSortList.Count == 0)
  1058. {
  1059. PlacementData.CreateData();
  1060. List<PlacementData.Data> creativeData = PlacementData.GetAllDatas(false);
  1061. creativeData = creativeData.OrderBy(data => data.categoryID).ThenBy(data => data.ID).ToList();
  1062. creativeSortList = new List<SortItem>(creativeData.Count);
  1063. foreach (var data in creativeData)
  1064. {
  1065. string asset = !string.IsNullOrEmpty(data.resourceName) ? data.resourceName : data.assetName;
  1066. SortItem item = new SortItem()
  1067. {
  1068. menu = data.ID.ToString(),
  1069. baseMenu = asset,
  1070. isCreative = true,
  1071. tex = data.GetThumbnail() as Texture2D
  1072. };
  1073. creativeSortList.Add(item);
  1074. }
  1075. }
  1076. }
  1077. else
  1078. {
  1079. if (itemDataList.Count == 0)
  1080. {
  1081. if (GameUty.MenuFiles?.Length > 0)
  1082. {
  1083. HashSet<string> modMenus = null;
  1084. if (!modItemsOnly) modMenus = new HashSet<string>(GameUty.ModOnlysMenuFiles);
  1085. string[] menuFiles = modItemsOnly ? GameUty.ModOnlysMenuFiles : GameUty.MenuFiles;
  1086. foreach (string menuFile in menuFiles)
  1087. {
  1088. ItemData item = new ItemData()
  1089. {
  1090. menu = menuFile,
  1091. isMod = modItemsOnly || modMenus.Contains(menuFile)
  1092. };
  1093. if (ParseMenuFile(menuFile, item)) itemDataList.Add(item);
  1094. }
  1095. }
  1096. else
  1097. {
  1098. if (!modItemsOnly)
  1099. {
  1100. for (int i = 0; i < GameMain.Instance.MenuDataBase.GetDataSize(); i++)
  1101. {
  1102. ItemData item = new ItemData();
  1103. if (ParseNativeMenuFile(i, item)) itemDataList.Add(item);
  1104. }
  1105. }
  1106. foreach (string modMenuFile in GameUty.ModOnlysMenuFiles)
  1107. {
  1108. ItemData item = new ItemData()
  1109. {
  1110. menu = modMenuFile,
  1111. isMod = true
  1112. };
  1113. if (ParseMenuFile(modMenuFile, item)) itemDataList.Add(item);
  1114. }
  1115. }
  1116. foreach (string modFile in Menu.GetModFiles())
  1117. {
  1118. ItemData item = new ItemData()
  1119. {
  1120. isMod = true,
  1121. isOfficialMod = true,
  1122. menu = modFile,
  1123. priority = 1000
  1124. };
  1125. if (ParseModMenuFile(modFile, item)) itemDataList.Add(item);
  1126. }
  1127. }
  1128. foreach (ItemData itemData in itemDataList)
  1129. {
  1130. if (itemData.category == slotArray[slotIndex])
  1131. {
  1132. sortList.Add(new SortItem()
  1133. {
  1134. category = itemData.category,
  1135. priority = itemData.priority,
  1136. name = itemData.name,
  1137. icon = itemData.icon,
  1138. menu = itemData.menu,
  1139. tex = itemData.tex,
  1140. isMod = itemData.isMod,
  1141. isOfficialMod = itemData.isOfficialMod,
  1142. baseMenu = itemData.baseItem
  1143. });
  1144. }
  1145. }
  1146. IOrderedEnumerable<SortItem> sortedItemList = sortList
  1147. .OrderBy(item => item.priority)
  1148. .ThenBy(item => item.name);
  1149. List<SortItem> sortItemList = new List<SortItem>();
  1150. string previousMenu = "";
  1151. foreach (SortItem item in sortedItemList)
  1152. {
  1153. try
  1154. {
  1155. if (item.menu != previousMenu)
  1156. {
  1157. if (!modItemsOnly && item.isMod) numberOfModItems++;
  1158. if (item.tex == null)
  1159. {
  1160. byte[] data = ImportCM.LoadTexture(GameUty.FileSystem, item.icon, false).data;
  1161. Texture2D texture2D = new Texture2D(50, 50, TextureFormat.RGB565, false);
  1162. texture2D.LoadImage(data);
  1163. item.tex = texture2D;
  1164. }
  1165. previousMenu = item.menu;
  1166. sortItemList.Add(item);
  1167. }
  1168. }
  1169. catch { }
  1170. }
  1171. sortList = sortItemList;
  1172. }
  1173. }
  1174. private void BGSelectWindow(int winID)
  1175. {
  1176. GUIStyle guistyle = "label";
  1177. guistyle.fontSize = GetPix(12);
  1178. guistyle.alignment = TextAnchor.UpperLeft;
  1179. GUIStyle guistyle2 = "label";
  1180. guistyle2.fontSize = GetPix(11);
  1181. guistyle2.alignment = TextAnchor.UpperLeft;
  1182. GUIStyle guistyle3 = "button";
  1183. guistyle3.fontSize = GetPix(20);
  1184. GUIStyle guistyle4 = "button";
  1185. guistyle4.fontSize = GetPix(14);
  1186. guistyle4.alignment = TextAnchor.MiddleLeft;
  1187. GUIStyle guistyle5 = "button";
  1188. guistyle5.fontSize = GetPix(12);
  1189. guistyle5.alignment = TextAnchor.MiddleLeft;
  1190. GUIStyle guistyle6 = new GUIStyle("toggle")
  1191. {
  1192. fontSize = GetPix(13)
  1193. };
  1194. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  1195. Maid maid = maidArray[selectMaidIndex];
  1196. if (!kankyoInitFlg)
  1197. {
  1198. listStyle2.normal.textColor = Color.white;
  1199. listStyle2.normal.background = MakeTex(2, 2, new Color(0f, 0f, 0f, 0.5f));
  1200. listStyle2.onHover.background = listStyle2.hover.background = new Texture2D(2, 2);
  1201. RectOffset padding = listStyle2.padding;
  1202. RectOffset padding2 = listStyle2.padding;
  1203. RectOffset padding3 = listStyle2.padding;
  1204. int num = listStyle2.padding.bottom = GetPix(0);
  1205. num = padding3.top = num;
  1206. num = padding2.right = num;
  1207. padding.left = num;
  1208. listStyle2.fontSize = GetPix(11);
  1209. listStyle3.normal.textColor = Color.white;
  1210. listStyle3.normal.background = MakeTex(2, 2, new Color(0f, 0f, 0f, 0.5f));
  1211. listStyle3.onHover.background = listStyle3.hover.background = new Texture2D(2, 2);
  1212. RectOffset padding4 = listStyle3.padding;
  1213. RectOffset padding5 = listStyle3.padding;
  1214. num = listStyle3.padding.top = GetPix(0);
  1215. num = padding5.right = num;
  1216. padding4.left = num;
  1217. listStyle3.padding.bottom = GetPix(0);
  1218. listStyle3.fontSize = GetPix(12);
  1219. bgmCombo.selectedItemIndex = bgmIndex;
  1220. if (sceneLevel == 5)
  1221. {
  1222. bgmCombo.selectedItemIndex = 2;
  1223. }
  1224. bgmComboList = bgmArray.Select(s => dancesDict.TryGetValue(s, out string name) ? name : s).Select(s => new GUIContent(s)).ToArray();
  1225. bgCombo.selectedItemIndex = bgIndex;
  1226. bgComboList = new GUIContent[bgArray.Length];
  1227. for (int j = 0; j < bgArray.Length; j++)
  1228. {
  1229. // Dicts merged during init
  1230. if (bgDict.TryGetValue(bgArray[j], out string name))
  1231. {
  1232. bgComboList[j] = new GUIContent(name);
  1233. }
  1234. else
  1235. {
  1236. bgComboList[j] = new GUIContent(bgArray[j]);
  1237. }
  1238. }
  1239. doguCombo.selectedItemIndex = 0;
  1240. doguComboList = new GUIContent[doguBArray.Length];
  1241. for (int j = 0; j < doguComboList.Length; j++)
  1242. {
  1243. // Dicts merged during init
  1244. if (doguUiNames.TryGetValue(doguBArray[j], out string name))
  1245. {
  1246. doguComboList[j] = new GUIContent(name);
  1247. }
  1248. else
  1249. {
  1250. doguComboList[j] = new GUIContent(doguBArray[j]);
  1251. }
  1252. }
  1253. parCombo.selectedItemIndex = 0;
  1254. parComboList = parArray.Select(s => parUiDict.TryGetValue(s, out string name) ? name : s).Select(s => new GUIContent(s)).ToArray();
  1255. lightCombo.selectedItemIndex = 0;
  1256. lightList = new List<GameObject>
  1257. {
  1258. GameMain.Instance.MainLight.gameObject
  1259. };
  1260. lightComboList = new GUIContent[lightList.Count];
  1261. for (int i = 0; i < lightList.Count; i++)
  1262. {
  1263. if (i == 0)
  1264. {
  1265. lightComboList[i] = new GUIContent("メイン");
  1266. }
  1267. else
  1268. {
  1269. lightComboList[i] = new GUIContent("追加" + i);
  1270. }
  1271. }
  1272. kankyoInitFlg = true;
  1273. }
  1274. listStyle3.padding.top = GetPix(1);
  1275. listStyle3.padding.bottom = GetPix(0);
  1276. listStyle3.fontSize = GetPix(12);
  1277. if (poseCombo.isClickedComboButton)
  1278. {
  1279. GUI.enabled = false;
  1280. }
  1281. if (poseGroupCombo.isClickedComboButton)
  1282. {
  1283. GUI.enabled = false;
  1284. }
  1285. if (sceneLevel == 3 || sceneLevel == 5 || isF6)
  1286. {
  1287. if (!isF6)
  1288. {
  1289. bool value = true;
  1290. if (faceFlg || poseFlg || sceneFlg || kankyoFlg || kankyo2Flg)
  1291. {
  1292. value = false;
  1293. }
  1294. if (GUI.Toggle(new Rect(GetPix(2),
  1295. GetPix(2),
  1296. GetPix(39),
  1297. GetPix(20)),
  1298. value,
  1299. "配置",
  1300. guistyle6))
  1301. {
  1302. faceFlg = false;
  1303. poseFlg = false;
  1304. sceneFlg = false;
  1305. kankyoFlg = false;
  1306. kankyo2Flg = false;
  1307. bGui = true;
  1308. }
  1309. }
  1310. if (!yotogiFlg)
  1311. {
  1312. if (GUI.Toggle(new Rect(GetPix(42),
  1313. GetPix(2),
  1314. GetPix(39),
  1315. GetPix(20)),
  1316. poseFlg,
  1317. "操作",
  1318. guistyle6))
  1319. {
  1320. poseFlg = true;
  1321. faceFlg = false;
  1322. sceneFlg = false;
  1323. kankyoFlg = false;
  1324. kankyo2Flg = false;
  1325. }
  1326. }
  1327. if (GUI.Toggle(new Rect(GetPix(82), GetPix(2), GetPix(39), GetPix(20)),
  1328. faceFlg,
  1329. "表情",
  1330. guistyle6))
  1331. {
  1332. faceFlg = true;
  1333. poseFlg = false;
  1334. sceneFlg = false;
  1335. kankyoFlg = false;
  1336. kankyo2Flg = false;
  1337. if (!faceFlg2)
  1338. {
  1339. isFaceInit = true;
  1340. faceFlg2 = true;
  1341. maidArray[selectMaidIndex].boMabataki = false;
  1342. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  1343. }
  1344. isFaceInit = true;
  1345. }
  1346. if (GUI.Toggle(new Rect(GetPix(122), GetPix(2), GetPix(39), GetPix(20)),
  1347. kankyoFlg,
  1348. "環境",
  1349. guistyle6))
  1350. {
  1351. poseFlg = false;
  1352. faceFlg = false;
  1353. sceneFlg = false;
  1354. kankyoFlg = true;
  1355. kankyo2Flg = false;
  1356. }
  1357. if (GUI.Toggle(new Rect(GetPix(162), GetPix(2), GetPix(39), GetPix(20)),
  1358. kankyo2Flg,
  1359. "環2",
  1360. guistyle6))
  1361. {
  1362. poseFlg = false;
  1363. faceFlg = false;
  1364. sceneFlg = false;
  1365. kankyoFlg = false;
  1366. kankyo2Flg = true;
  1367. }
  1368. if (!line1)
  1369. {
  1370. line1 = MakeTex(2, 2, new Color(0f, 0f, 0f, 0.3f));
  1371. line2 = MakeTex(2, 2, new Color(0.7f, 0.7f, 0.7f, 0.6f));
  1372. }
  1373. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(200), 2f), line1);
  1374. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(200), 1f), line2);
  1375. }
  1376. if (isDanceStop)
  1377. {
  1378. isStop[selectMaidIndex] = true;
  1379. isDanceStop = false;
  1380. }
  1381. yotogiFlg = false;
  1382. if (sceneLevel == 14)
  1383. {
  1384. if (GameObject.Find("/UI Root/YotogiPlayPanel/CommandViewer/SkillViewer/MaskGroup/SkillGroup/CommandParent/CommandUnit"))
  1385. {
  1386. yotogiFlg = true;
  1387. }
  1388. }
  1389. if (!isF6)
  1390. {
  1391. if (GUI.Button(new Rect(GetPix(157),
  1392. GetPix(32),
  1393. GetPix(46),
  1394. GetPix(35)),
  1395. "シーン\n 管 理",
  1396. guistyle3))
  1397. {
  1398. sceneFlg = true;
  1399. faceFlg = false;
  1400. poseFlg = false;
  1401. kankyoFlg = false;
  1402. kankyo2Flg = false;
  1403. bGui = true;
  1404. for (int i = 0; i < 10; i++)
  1405. {
  1406. date[i] = "未保存";
  1407. ninzu[i] = "";
  1408. IniKey iniKey = Preferences["scene"]["s" + (page * 10 + i + 1)];
  1409. if (iniKey.Value != null && iniKey.Value.ToString() != "")
  1410. {
  1411. string[] array = iniKey.Value.Split(new char[] { '_' });
  1412. if (array.Length >= 2)
  1413. {
  1414. string[] array2 = array[0].Split(new char[] { ',' });
  1415. date[i] = array2[0];
  1416. ninzu[i] = array2[1] + "人";
  1417. }
  1418. }
  1419. }
  1420. }
  1421. }
  1422. if (doguCombo.isClickedComboButton || parCombo.isClickedComboButton || bgCombo.isClickedComboButton
  1423. || bgmCombo.isClickedComboButton || lightCombo.isClickedComboButton)
  1424. {
  1425. GUI.enabled = false;
  1426. }
  1427. int num2 = -1;
  1428. if (lightIndex[selectLightIndex] == 0)
  1429. {
  1430. isIdx1 = true;
  1431. }
  1432. if (lightIndex[selectLightIndex] == 1)
  1433. {
  1434. isIdx2 = true;
  1435. }
  1436. if (lightIndex[selectLightIndex] == 2)
  1437. {
  1438. isIdx3 = true;
  1439. }
  1440. if (lightIndex[selectLightIndex] == 3)
  1441. {
  1442. isIdx4 = true;
  1443. }
  1444. int offsetTop = GetPix(80);
  1445. int UIHeight = GetPix(550);
  1446. Rect BGWindowScrollRect = new Rect(0, offsetTop, rectWin.width, rectWin.height - offsetTop);
  1447. Rect BGWindowScrollView = new Rect(0, offsetTop, rectWin.width - 20, UIHeight);
  1448. bgScrollPos = GUI.BeginScrollView(BGWindowScrollRect, bgScrollPos, BGWindowScrollView);
  1449. if (GUI.Toggle(new Rect(GetPix(5), GetPix(215), GetPix(45), GetPix(20)),
  1450. isIdx1,
  1451. "通常",
  1452. guistyle6))
  1453. {
  1454. if (lightIndex[selectLightIndex] != 0)
  1455. {
  1456. isIdx1 = true;
  1457. isIdx2 = false;
  1458. isIdx3 = false;
  1459. isIdx4 = false;
  1460. num2 = 0;
  1461. }
  1462. }
  1463. if (GUI.Toggle(new Rect(GetPix(50), GetPix(215), GetPix(45), GetPix(20)),
  1464. isIdx2,
  1465. "Spot",
  1466. guistyle6))
  1467. {
  1468. if (lightIndex[selectLightIndex] != 1)
  1469. {
  1470. isIdx1 = false;
  1471. isIdx2 = true;
  1472. isIdx3 = false;
  1473. isIdx4 = false;
  1474. num2 = 1;
  1475. }
  1476. }
  1477. if (GUI.Toggle(new Rect(GetPix(99), GetPix(215), GetPix(45), GetPix(20)),
  1478. isIdx3,
  1479. "Point",
  1480. guistyle6))
  1481. {
  1482. if (lightIndex[selectLightIndex] != 2)
  1483. {
  1484. isIdx1 = false;
  1485. isIdx2 = false;
  1486. isIdx3 = true;
  1487. isIdx4 = false;
  1488. num2 = 2;
  1489. }
  1490. }
  1491. if (selectLightIndex == 0)
  1492. {
  1493. if (GUI.Toggle(new Rect(GetPix(150),
  1494. GetPix(215),
  1495. GetPix(45),
  1496. GetPix(20)),
  1497. isIdx4,
  1498. "単色",
  1499. guistyle6))
  1500. {
  1501. if (lightIndex[selectLightIndex] != 3)
  1502. {
  1503. isIdx1 = false;
  1504. isIdx2 = false;
  1505. isIdx3 = false;
  1506. isIdx4 = true;
  1507. num2 = 3;
  1508. }
  1509. }
  1510. }
  1511. else if (GUI.Toggle(new Rect(GetPix(150),
  1512. GetPix(215),
  1513. GetPix(45),
  1514. GetPix(20)),
  1515. isIdx4,
  1516. "無効",
  1517. guistyle6))
  1518. {
  1519. if (lightIndex[selectLightIndex] != 3)
  1520. {
  1521. isIdx1 = false;
  1522. isIdx2 = false;
  1523. isIdx3 = false;
  1524. isIdx4 = true;
  1525. num2 = 3;
  1526. }
  1527. }
  1528. if (num2 >= 0)
  1529. {
  1530. lightIndex[selectLightIndex] = num2;
  1531. if (selectLightIndex == 0)
  1532. {
  1533. GameMain.Instance.MainLight.Reset();
  1534. GameMain.Instance.MainLight.SetIntensity(0.95f);
  1535. GameMain.Instance.MainLight.GetComponent<Light>().spotAngle = 50f;
  1536. GameMain.Instance.MainLight.GetComponent<Light>().range = 10f;
  1537. GameMain.Instance.MainLight.gameObject.transform.position = new Vector3(0f, 2f, 0f);
  1538. if (lightIndex[selectLightIndex] == 0)
  1539. {
  1540. GameMain.Instance.MainLight.GetComponent<Light>().type = LightType.Directional;
  1541. bgObject.SetActive(true);
  1542. mainCamera.GetComponent<Camera>().backgroundColor = new Color(0f, 0f, 0f);
  1543. }
  1544. else if (lightIndex[selectLightIndex] == 1)
  1545. {
  1546. GameMain.Instance.MainLight.transform.eulerAngles += Vector3.right * 40f;
  1547. GameMain.Instance.MainLight.GetComponent<Light>().type = LightType.Spot;
  1548. bgObject.SetActive(true);
  1549. mainCamera.GetComponent<Camera>().backgroundColor = new Color(0f, 0f, 0f);
  1550. }
  1551. else if (lightIndex[selectLightIndex] == 2)
  1552. {
  1553. GameMain.Instance.MainLight.GetComponent<Light>().type = LightType.Point;
  1554. bgObject.SetActive(true);
  1555. mainCamera.GetComponent<Camera>().backgroundColor = new Color(0f, 0f, 0f);
  1556. }
  1557. else if (lightIndex[selectLightIndex] == 3)
  1558. {
  1559. GameMain.Instance.MainLight.GetComponent<Light>().type = LightType.Directional;
  1560. mainCamera.GetComponent<Camera>().backgroundColor = new Color(lightColorR[0], lightColorG[0], lightColorB[0]);
  1561. bgObject.SetActive(false);
  1562. }
  1563. }
  1564. else
  1565. {
  1566. lightList[selectLightIndex].SetActive(true);
  1567. if (lightIndex[selectLightIndex] == 0)
  1568. {
  1569. lightList[selectLightIndex].GetComponent<Light>().type = LightType.Directional;
  1570. }
  1571. else if (lightIndex[selectLightIndex] == 1)
  1572. {
  1573. lightList[selectLightIndex].transform.eulerAngles += Vector3.right * 40f;
  1574. lightList[selectLightIndex].GetComponent<Light>().type = LightType.Spot;
  1575. }
  1576. else if (lightIndex[selectLightIndex] == 2)
  1577. {
  1578. lightList[selectLightIndex].GetComponent<Light>().type = LightType.Point;
  1579. }
  1580. else if (lightIndex[selectLightIndex] == 3)
  1581. {
  1582. lightList[selectLightIndex].GetComponent<Light>().type = LightType.Directional;
  1583. lightList[selectLightIndex].SetActive(false);
  1584. }
  1585. }
  1586. lightColorR[selectLightIndex] = 1f;
  1587. lightColorG[selectLightIndex] = 1f;
  1588. lightColorB[selectLightIndex] = 1f;
  1589. lightX[selectLightIndex] = 40f;
  1590. lightY[selectLightIndex] = 180f;
  1591. lightAkarusa[selectLightIndex] = 0.95f;
  1592. lightKage[selectLightIndex] = 0.098f;
  1593. lightRange[selectLightIndex] = 50f;
  1594. if (lightIndex[selectLightIndex] == 1)
  1595. {
  1596. lightX[selectLightIndex] = 90f;
  1597. }
  1598. }
  1599. GUI.Label(new Rect(GetPix(10), GetPix(138), GetPix(100), GetPix(25)),
  1600. "キューブ表示",
  1601. guistyle2);
  1602. guistyle6.fontSize = GetPix(12);
  1603. isCube2 = GUI.Toggle(new Rect(GetPix(5),
  1604. GetPix(153),
  1605. GetPix(55),
  1606. GetPix(20)),
  1607. isCube2,
  1608. "大道具(",
  1609. guistyle6);
  1610. if (!isF6)
  1611. {
  1612. isCube = GUI.Toggle(new Rect(GetPix(102),
  1613. GetPix(153),
  1614. GetPix(54),
  1615. GetPix(20)),
  1616. isCube,
  1617. "メイド",
  1618. guistyle6);
  1619. }
  1620. bool flag = GUI.Toggle(new Rect(GetPix(160),
  1621. GetPix(153),
  1622. GetPix(44),
  1623. GetPix(20)),
  1624. isCube3,
  1625. "背景",
  1626. guistyle6);
  1627. guistyle6.fontSize = GetPix(13);
  1628. bool flag2 = GUI.Toggle(new Rect(GetPix(61),
  1629. GetPix(153),
  1630. GetPix(38),
  1631. GetPix(20)),
  1632. isCubeS,
  1633. "小)",
  1634. guistyle6);
  1635. if (isCubeS != flag2)
  1636. {
  1637. isCubeS = flag2;
  1638. if (isCubeS)
  1639. {
  1640. cubeSize = 0.05f;
  1641. }
  1642. else
  1643. {
  1644. cubeSize = 0.12f;
  1645. }
  1646. for (int i = 0; i < doguBObject.Count; i++)
  1647. {
  1648. gDogu[i].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  1649. }
  1650. }
  1651. if (isCube3 != flag)
  1652. {
  1653. isCube3 = flag;
  1654. if (gBg == null)
  1655. {
  1656. gBg = GameObject.CreatePrimitive(PrimitiveType.Cube);
  1657. gBg.GetComponent<Renderer>().material = m_material;
  1658. gBg.layer = 8;
  1659. gBg.GetComponent<Renderer>().enabled = false;
  1660. gBg.SetActive(false);
  1661. gBg.transform.position = bgObject.transform.position;
  1662. mBg = gBg.AddComponent<MouseDrag6>();
  1663. mBg.obj = gBg;
  1664. mBg.maid = bgObject;
  1665. mBg.angles = bg.eulerAngles;
  1666. gBg.transform.localScale = new Vector3(0.12f, 0.12f, 0.12f);
  1667. mBg.ido = 1;
  1668. mBg.isScale = false;
  1669. }
  1670. if (isCube3)
  1671. {
  1672. gBg.SetActive(true);
  1673. }
  1674. else
  1675. {
  1676. gBg.SetActive(false);
  1677. }
  1678. }
  1679. int num3 = 0;
  1680. if (lightIndex[selectLightIndex] == 0 || lightIndex[selectLightIndex] == 1
  1681. || (selectLightIndex == 0 && lightIndex[selectLightIndex] == 3))
  1682. {
  1683. GUI.Label(new Rect(GetPix(10), GetPix(237), GetPix(100), GetPix(25)),
  1684. "向きX",
  1685. guistyle2);
  1686. lightX[selectLightIndex] =
  1687. GUI.HorizontalSlider(new Rect(GetPix(8),
  1688. GetPix(251),
  1689. GetPix(192),
  1690. GetPix(20)),
  1691. lightX[selectLightIndex],
  1692. 220f,
  1693. -140f);
  1694. GUI.Label(new Rect(GetPix(10), GetPix(261), GetPix(100), GetPix(25)),
  1695. "向きY",
  1696. guistyle2);
  1697. lightY[selectLightIndex] =
  1698. GUI.HorizontalSlider(new Rect(GetPix(8),
  1699. GetPix(275),
  1700. GetPix(192),
  1701. GetPix(20)),
  1702. lightY[selectLightIndex],
  1703. 0f,
  1704. 360f);
  1705. }
  1706. else
  1707. {
  1708. num3 = 50;
  1709. }
  1710. if (lightIndex[selectLightIndex] != 3 || selectLightIndex <= 0)
  1711. {
  1712. GUI.Label(new Rect(GetPix(10),
  1713. GetPix(285 - num3),
  1714. GetPix(100),
  1715. GetPix(25)),
  1716. "明るさ",
  1717. guistyle2);
  1718. lightAkarusa[selectLightIndex] =
  1719. GUI.HorizontalSlider(new Rect(GetPix(8),
  1720. GetPix(299 - num3),
  1721. GetPix(192),
  1722. GetPix(20)),
  1723. lightAkarusa[selectLightIndex],
  1724. 0f,
  1725. 1.9f);
  1726. if (lightIndex[selectLightIndex] == 0 || lightIndex[selectLightIndex] == 3)
  1727. {
  1728. if (selectLightIndex == 0)
  1729. {
  1730. GUI.Label(new Rect(GetPix(10),
  1731. GetPix(309 - num3),
  1732. GetPix(100),
  1733. GetPix(25)),
  1734. "影",
  1735. guistyle2);
  1736. lightKage[selectLightIndex] =
  1737. GUI.HorizontalSlider(new Rect(GetPix(8),
  1738. GetPix(323 - num3),
  1739. GetPix(192),
  1740. GetPix(20)),
  1741. lightKage[selectLightIndex],
  1742. 0f,
  1743. 1f);
  1744. }
  1745. else
  1746. {
  1747. num3 = 25;
  1748. }
  1749. }
  1750. else if (lightIndex[selectLightIndex] == 1 || lightIndex[selectLightIndex] == 2)
  1751. {
  1752. GUI.Label(new Rect(GetPix(10),
  1753. GetPix(311 - num3),
  1754. GetPix(100),
  1755. GetPix(25)),
  1756. "範囲",
  1757. guistyle2);
  1758. lightRange[selectLightIndex] =
  1759. GUI.HorizontalSlider(new Rect(GetPix(8),
  1760. GetPix(325 - num3),
  1761. GetPix(192),
  1762. GetPix(20)),
  1763. lightRange[selectLightIndex],
  1764. 0f,
  1765. 150f);
  1766. }
  1767. else
  1768. {
  1769. num3 = 75;
  1770. }
  1771. GUI.Label(new Rect(GetPix(10),
  1772. GetPix(333 - num3),
  1773. GetPix(100),
  1774. GetPix(25)),
  1775. "赤",
  1776. guistyle2);
  1777. lightColorR[selectLightIndex] =
  1778. GUI.HorizontalSlider(new Rect(GetPix(8),
  1779. GetPix(347 - num3),
  1780. GetPix(92),
  1781. GetPix(20)),
  1782. lightColorR[selectLightIndex],
  1783. 0f,
  1784. 1f);
  1785. GUI.Label(new Rect(GetPix(108),
  1786. GetPix(333 - num3),
  1787. GetPix(100),
  1788. GetPix(25)),
  1789. "緑",
  1790. guistyle2);
  1791. lightColorG[selectLightIndex] =
  1792. GUI.HorizontalSlider(new Rect(GetPix(108),
  1793. GetPix(347 - num3),
  1794. GetPix(92),
  1795. GetPix(20)),
  1796. lightColorG[selectLightIndex],
  1797. 0f,
  1798. 1f);
  1799. GUI.Label(new Rect(GetPix(10),
  1800. GetPix(357 - num3),
  1801. GetPix(100),
  1802. GetPix(25)),
  1803. "青",
  1804. guistyle2);
  1805. lightColorB[selectLightIndex] =
  1806. GUI.HorizontalSlider(new Rect(GetPix(8),
  1807. GetPix(371 - num3),
  1808. GetPix(92),
  1809. GetPix(20)),
  1810. lightColorB[selectLightIndex],
  1811. 0f,
  1812. 1f);
  1813. }
  1814. if (GUI.Toggle(new Rect(GetPix(5), GetPix(391), GetPix(67), GetPix(20)),
  1815. isBloomS,
  1816. "ブルーム",
  1817. guistyle6))
  1818. {
  1819. isBloomS = true;
  1820. isDepthS = false;
  1821. isBlurS = false;
  1822. isFogS = false;
  1823. }
  1824. if (isBloomS)
  1825. {
  1826. isBloom = GUI.Toggle(new Rect(GetPix(8),
  1827. GetPix(412),
  1828. GetPix(40),
  1829. GetPix(20)),
  1830. isBloom,
  1831. "有効",
  1832. guistyle6);
  1833. if (!isBloom)
  1834. {
  1835. GUI.enabled = false;
  1836. }
  1837. GUI.Label(new Rect(GetPix(10), GetPix(430), GetPix(100), GetPix(25)),
  1838. "強さ",
  1839. guistyle2);
  1840. bloom1 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1841. GetPix(445),
  1842. GetPix(92),
  1843. GetPix(20)),
  1844. bloom1,
  1845. 0f,
  1846. 5.7f);
  1847. GUI.Label(new Rect(GetPix(110), GetPix(430), GetPix(100), GetPix(25)),
  1848. "広さ",
  1849. guistyle2);
  1850. bloom2 = GUI.HorizontalSlider(new Rect(GetPix(108),
  1851. GetPix(445),
  1852. GetPix(92),
  1853. GetPix(20)),
  1854. bloom2,
  1855. 0f,
  1856. 15f);
  1857. GUI.Label(new Rect(GetPix(10), GetPix(455), GetPix(100), GetPix(25)),
  1858. "赤",
  1859. guistyle2);
  1860. bloom3 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1861. GetPix(470),
  1862. GetPix(92),
  1863. GetPix(20)),
  1864. bloom3,
  1865. 0f,
  1866. 0.5f);
  1867. GUI.Label(new Rect(GetPix(110), GetPix(455), GetPix(100), GetPix(25)),
  1868. "緑",
  1869. guistyle2);
  1870. bloom4 = GUI.HorizontalSlider(new Rect(GetPix(108),
  1871. GetPix(470),
  1872. GetPix(92),
  1873. GetPix(20)),
  1874. bloom4,
  1875. 0f,
  1876. 0.5f);
  1877. GUI.Label(new Rect(GetPix(10), GetPix(480), GetPix(100), GetPix(25)),
  1878. "青",
  1879. guistyle2);
  1880. bloom5 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1881. GetPix(495),
  1882. GetPix(92),
  1883. GetPix(20)),
  1884. bloom5,
  1885. 0f,
  1886. 0.5f);
  1887. isBloomA = GUI.Toggle(new Rect(GetPix(110),
  1888. GetPix(491),
  1889. GetPix(50),
  1890. GetPix(20)),
  1891. isBloomA,
  1892. "HDR",
  1893. guistyle6);
  1894. if (!doguCombo.isClickedComboButton && !parCombo.isClickedComboButton && !bgCombo.isClickedComboButton
  1895. && !bgmCombo.isClickedComboButton)
  1896. {
  1897. GUI.enabled = true;
  1898. }
  1899. }
  1900. if (GUI.Toggle(new Rect(GetPix(73), GetPix(391), GetPix(40), GetPix(20)),
  1901. isDepthS,
  1902. "深度",
  1903. guistyle6))
  1904. {
  1905. isBloomS = false;
  1906. isDepthS = true;
  1907. isBlurS = false;
  1908. isFogS = false;
  1909. }
  1910. if (isDepthS)
  1911. {
  1912. isDepth = GUI.Toggle(new Rect(GetPix(8),
  1913. GetPix(412),
  1914. GetPix(40),
  1915. GetPix(20)),
  1916. isDepth,
  1917. "有効",
  1918. guistyle6);
  1919. if (!isDepth)
  1920. {
  1921. GUI.enabled = false;
  1922. }
  1923. GUI.Label(new Rect(GetPix(10), GetPix(430), GetPix(100), GetPix(25)),
  1924. "焦点距離",
  1925. guistyle2);
  1926. depth1 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1927. GetPix(445),
  1928. GetPix(192),
  1929. GetPix(20)),
  1930. depth1,
  1931. 0f,
  1932. 10f);
  1933. GUI.Label(new Rect(GetPix(10), GetPix(455), GetPix(100), GetPix(25)),
  1934. "焦点領域サイズ",
  1935. guistyle2);
  1936. depth2 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1937. GetPix(470),
  1938. GetPix(92),
  1939. GetPix(20)),
  1940. depth2,
  1941. 0f,
  1942. 2f);
  1943. GUI.Label(new Rect(GetPix(110), GetPix(455), GetPix(100), GetPix(25)),
  1944. "カメラ絞り",
  1945. guistyle2);
  1946. depth3 = GUI.HorizontalSlider(new Rect(GetPix(108),
  1947. GetPix(470),
  1948. GetPix(92),
  1949. GetPix(20)),
  1950. depth3,
  1951. 0f,
  1952. 60f);
  1953. GUI.Label(new Rect(GetPix(10), GetPix(480), GetPix(100), GetPix(25)),
  1954. "ブレ",
  1955. guistyle2);
  1956. depth4 = GUI.HorizontalSlider(new Rect(GetPix(8),
  1957. GetPix(495),
  1958. GetPix(92),
  1959. GetPix(20)),
  1960. depth4,
  1961. 0f,
  1962. 10f);
  1963. isDepthA = GUI.Toggle(new Rect(GetPix(110),
  1964. GetPix(491),
  1965. GetPix(100),
  1966. GetPix(20)),
  1967. isDepthA,
  1968. "深度表示",
  1969. guistyle6);
  1970. if (!doguCombo.isClickedComboButton && !parCombo.isClickedComboButton && !bgCombo.isClickedComboButton
  1971. && !bgmCombo.isClickedComboButton)
  1972. {
  1973. GUI.enabled = true;
  1974. }
  1975. }
  1976. if (GUI.Toggle(new Rect(GetPix(114), GetPix(391), GetPix(40), GetPix(20)),
  1977. isBlurS,
  1978. "光学",
  1979. guistyle6))
  1980. {
  1981. isBloomS = false;
  1982. isDepthS = false;
  1983. isBlurS = true;
  1984. isFogS = false;
  1985. }
  1986. if (isBlurS)
  1987. {
  1988. isBlur = GUI.Toggle(new Rect(GetPix(8),
  1989. GetPix(412),
  1990. GetPix(40),
  1991. GetPix(20)),
  1992. isBlur,
  1993. "有効",
  1994. guistyle6);
  1995. if (!isBlur)
  1996. {
  1997. GUI.enabled = false;
  1998. }
  1999. GUI.Label(new Rect(GetPix(10), GetPix(430), GetPix(100), GetPix(25)),
  2000. "強さ",
  2001. guistyle2);
  2002. blur1 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2003. GetPix(445),
  2004. GetPix(92),
  2005. GetPix(20)),
  2006. blur1,
  2007. -40f,
  2008. 70f);
  2009. GUI.Label(new Rect(GetPix(108), GetPix(430), GetPix(100), GetPix(25)),
  2010. "ブラー",
  2011. guistyle2);
  2012. blur2 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2013. GetPix(445),
  2014. GetPix(92),
  2015. GetPix(20)),
  2016. blur2,
  2017. 0f,
  2018. 5f);
  2019. GUI.Label(new Rect(GetPix(10), GetPix(455), GetPix(100), GetPix(25)),
  2020. "ブレ",
  2021. guistyle2);
  2022. blur3 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2023. GetPix(470),
  2024. GetPix(92),
  2025. GetPix(20)),
  2026. blur3,
  2027. 0f,
  2028. 40f);
  2029. GUI.Label(new Rect(GetPix(108), GetPix(455), GetPix(100), GetPix(25)),
  2030. "色収差",
  2031. guistyle2);
  2032. blur4 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2033. GetPix(470),
  2034. GetPix(92),
  2035. GetPix(20)),
  2036. blur4,
  2037. -30f,
  2038. 30f);
  2039. if (!doguCombo.isClickedComboButton && !parCombo.isClickedComboButton && !bgCombo.isClickedComboButton
  2040. && !bgmCombo.isClickedComboButton)
  2041. {
  2042. GUI.enabled = true;
  2043. }
  2044. }
  2045. if (GUI.Toggle(new Rect(GetPix(155), GetPix(391), GetPix(60), GetPix(20)),
  2046. isFogS,
  2047. "フォグ",
  2048. guistyle6))
  2049. {
  2050. isBloomS = false;
  2051. isDepthS = false;
  2052. isBlurS = false;
  2053. isFogS = true;
  2054. }
  2055. if (isFogS)
  2056. {
  2057. isFog = GUI.Toggle(new Rect(GetPix(8),
  2058. GetPix(412),
  2059. GetPix(40),
  2060. GetPix(20)),
  2061. isFog,
  2062. "有効",
  2063. guistyle6);
  2064. if (!isFog)
  2065. {
  2066. GUI.enabled = false;
  2067. }
  2068. GUI.Label(new Rect(GetPix(110), GetPix(406), GetPix(100), GetPix(24)),
  2069. "発生距離",
  2070. guistyle2);
  2071. fog1 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2072. GetPix(420),
  2073. GetPix(92),
  2074. GetPix(20)),
  2075. fog1,
  2076. 0f,
  2077. 30f);
  2078. GUI.Label(new Rect(GetPix(10), GetPix(430), GetPix(100), GetPix(25)),
  2079. "密度",
  2080. guistyle2);
  2081. fog2 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2082. GetPix(445),
  2083. GetPix(92),
  2084. GetPix(20)),
  2085. fog2,
  2086. 0f,
  2087. 10f);
  2088. GUI.Label(new Rect(GetPix(110), GetPix(430), GetPix(100), GetPix(25)),
  2089. "強度",
  2090. guistyle2);
  2091. fog3 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2092. GetPix(445),
  2093. GetPix(92),
  2094. GetPix(20)),
  2095. fog3,
  2096. -5f,
  2097. 20f);
  2098. GUI.Label(new Rect(GetPix(10), GetPix(455), GetPix(100), GetPix(25)),
  2099. "高さ",
  2100. guistyle2);
  2101. fog4 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2102. GetPix(470),
  2103. GetPix(92),
  2104. GetPix(20)),
  2105. fog4,
  2106. -10f,
  2107. 10f);
  2108. GUI.Label(new Rect(GetPix(110), GetPix(455), GetPix(100), GetPix(25)),
  2109. "赤",
  2110. guistyle2);
  2111. fog5 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2112. GetPix(470),
  2113. GetPix(92),
  2114. GetPix(20)),
  2115. fog5,
  2116. 0f,
  2117. 1f);
  2118. GUI.Label(new Rect(GetPix(10), GetPix(480), GetPix(100), GetPix(25)),
  2119. "緑",
  2120. guistyle2);
  2121. fog6 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2122. GetPix(495),
  2123. GetPix(92),
  2124. GetPix(20)),
  2125. fog6,
  2126. 0f,
  2127. 1f);
  2128. GUI.Label(new Rect(GetPix(110), GetPix(480), GetPix(100), GetPix(25)),
  2129. "青",
  2130. guistyle2);
  2131. fog7 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2132. GetPix(495),
  2133. GetPix(92),
  2134. GetPix(20)),
  2135. fog7,
  2136. 0f,
  2137. 1f);
  2138. if (!doguCombo.isClickedComboButton && !parCombo.isClickedComboButton && !bgCombo.isClickedComboButton
  2139. && !bgmCombo.isClickedComboButton)
  2140. {
  2141. GUI.enabled = true;
  2142. }
  2143. }
  2144. isSepian = GUI.Toggle(new Rect(GetPix(5),
  2145. GetPix(515),
  2146. GetPix(80),
  2147. GetPix(20)),
  2148. isSepian,
  2149. "セピア",
  2150. guistyle6);
  2151. GUI.Label(new Rect(GetPix(108), GetPix(512), GetPix(100), GetPix(25)),
  2152. "ぼかし",
  2153. guistyle2);
  2154. bokashi = GUI.HorizontalSlider(new Rect(GetPix(108),
  2155. GetPix(527),
  2156. GetPix(92),
  2157. GetPix(20)),
  2158. bokashi,
  2159. 0f,
  2160. 18f);
  2161. if (GUI.Toggle(new Rect(GetPix(5), GetPix(545), GetPix(80), GetPix(20)),
  2162. isHairSetting,
  2163. "髪の設定",
  2164. guistyle6))
  2165. {
  2166. isHairSetting = true;
  2167. isSkirtSetting = false;
  2168. }
  2169. if (isHairSetting)
  2170. {
  2171. bool flag3 = GUI.Toggle(new Rect(GetPix(5),
  2172. GetPix(566),
  2173. GetPix(40),
  2174. GetPix(20)),
  2175. isKamiyure,
  2176. "有効",
  2177. guistyle6);
  2178. if (isKamiyure != flag3)
  2179. {
  2180. isKamiyure = flag3;
  2181. if (isKamiyure)
  2182. {
  2183. Preferences["config"]["hair_setting"].Value = "true";
  2184. Preferences["config"]["hair_radius"].Value = kamiyure4.ToString();
  2185. Preferences["config"]["hair_elasticity"].Value = kamiyure3.ToString();
  2186. Preferences["config"]["hair_damping"].Value = kamiyure2.ToString();
  2187. SaveConfig();
  2188. }
  2189. else
  2190. {
  2191. Preferences["config"]["hair_setting"].Value = "false";
  2192. SaveConfig();
  2193. for (int j = 0; j < maidCnt; j++)
  2194. {
  2195. for (int k = 0; k < maidArray[j].body0.goSlot.Count; k++)
  2196. {
  2197. if (k >= 3 && k <= 6)
  2198. {
  2199. if (maidArray[j].body0.goSlot[k].obj != null)
  2200. {
  2201. DynamicBone component = maidArray[j].body0.goSlot[k].obj.GetComponent<DynamicBone>();
  2202. if (component != null)
  2203. {
  2204. component.m_Damping = 0.6f;
  2205. component.m_Elasticity = 1f;
  2206. if (k == 5)
  2207. {
  2208. component.m_Elasticity = 0.05f;
  2209. }
  2210. component.m_Radius = 0.02f;
  2211. component.UpdateParameters();
  2212. }
  2213. }
  2214. }
  2215. }
  2216. }
  2217. }
  2218. }
  2219. if (!isKamiyure)
  2220. {
  2221. GUI.enabled = false;
  2222. }
  2223. GUI.Label(new Rect(GetPix(108), GetPix(565), GetPix(100), GetPix(25)),
  2224. "当たり判定半径",
  2225. guistyle2);
  2226. float num4 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2227. GetPix(579),
  2228. GetPix(92),
  2229. GetPix(20)),
  2230. kamiyure4,
  2231. 0f,
  2232. 0.04f);
  2233. if (kamiyure4 != num4)
  2234. {
  2235. kamiyure4 = num4;
  2236. Preferences["config"]["hair_radius"].Value = kamiyure4.ToString();
  2237. SaveConfig();
  2238. }
  2239. GUI.Label(new Rect(GetPix(108), GetPix(590), GetPix(100), GetPix(25)),
  2240. "減衰率",
  2241. guistyle2);
  2242. float num5 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2243. GetPix(604),
  2244. GetPix(92),
  2245. GetPix(20)),
  2246. kamiyure2,
  2247. 0.2f,
  2248. 1f);
  2249. if (kamiyure2 != num5)
  2250. {
  2251. kamiyure2 = num5;
  2252. Preferences["config"]["hair_damping"].Value = kamiyure2.ToString();
  2253. SaveConfig();
  2254. }
  2255. GUI.Label(new Rect(GetPix(10), GetPix(590), GetPix(100), GetPix(25)),
  2256. "復元率",
  2257. guistyle2);
  2258. float num6 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2259. GetPix(604),
  2260. GetPix(92),
  2261. GetPix(20)),
  2262. kamiyure3,
  2263. 0f,
  2264. 2f);
  2265. if (kamiyure3 != num6)
  2266. {
  2267. kamiyure3 = num6;
  2268. Preferences["config"]["hair_elasticity"].Value = kamiyure3.ToString();
  2269. SaveConfig();
  2270. }
  2271. GUI.enabled = true;
  2272. }
  2273. if (GUI.Toggle(new Rect(GetPix(105), GetPix(545), GetPix(100), GetPix(20)),
  2274. isSkirtSetting,
  2275. "スカート設定",
  2276. guistyle6))
  2277. {
  2278. isHairSetting = false;
  2279. isSkirtSetting = true;
  2280. }
  2281. if (isSkirtSetting)
  2282. {
  2283. bool flag4 = GUI.Toggle(new Rect(GetPix(5),
  2284. GetPix(566),
  2285. GetPix(40),
  2286. GetPix(20)),
  2287. isSkirtyure,
  2288. "有効",
  2289. guistyle6);
  2290. if (isSkirtyure != flag4)
  2291. {
  2292. isSkirtyure = flag4;
  2293. if (isSkirtyure)
  2294. {
  2295. Preferences["config"]["skirt_setting"].Value = "true";
  2296. Preferences["config"]["skirt_radius"].Value = skirtyure4.ToString();
  2297. Preferences["config"]["skirt_elasticity"].Value = skirtyure3.ToString();
  2298. Preferences["config"]["skirt_damping"].Value = skirtyure2.ToString();
  2299. SaveConfig();
  2300. }
  2301. else
  2302. {
  2303. Preferences["config"]["skirt_setting"].Value = "false";
  2304. SaveConfig();
  2305. for (int j = 0; j < maidCnt; j++)
  2306. {
  2307. for (int k = 0; k < maidArray[j].body0.goSlot.Count; k++)
  2308. {
  2309. if (maidArray[j].body0.goSlot[k].obj != null)
  2310. {
  2311. DynamicSkirtBone fieldValue =
  2312. GetFieldValue<BoneHair3, DynamicSkirtBone>(maidArray[j].body0.goSlot[k].bonehair3,
  2313. "m_SkirtBone");
  2314. if (fieldValue != null)
  2315. {
  2316. fieldValue.m_fPanierForce = 0.05f;
  2317. fieldValue.m_fPanierForceDistanceThreshold = 0.1f;
  2318. fieldValue.m_fRegDefaultRadius = 0.1f;
  2319. }
  2320. }
  2321. }
  2322. }
  2323. }
  2324. }
  2325. if (!isSkirtyure)
  2326. {
  2327. GUI.enabled = false;
  2328. }
  2329. GUI.Label(new Rect(GetPix(108), GetPix(565), GetPix(100), GetPix(25)),
  2330. "足側カプセル半径",
  2331. guistyle2);
  2332. float num4 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2333. GetPix(579),
  2334. GetPix(92),
  2335. GetPix(20)),
  2336. skirtyure4,
  2337. 0f,
  2338. 0.2f);
  2339. if (skirtyure4 != num4)
  2340. {
  2341. skirtyure4 = num4;
  2342. Preferences["config"]["skirt_radius"].Value = skirtyure4.ToString();
  2343. SaveConfig();
  2344. }
  2345. GUI.Label(new Rect(GetPix(108), GetPix(590), GetPix(100), GetPix(25)),
  2346. "足との距離パニエ力",
  2347. guistyle2);
  2348. float num5 = GUI.HorizontalSlider(new Rect(GetPix(108),
  2349. GetPix(604),
  2350. GetPix(92),
  2351. GetPix(20)),
  2352. skirtyure2,
  2353. 0f,
  2354. 0.2f);
  2355. if (skirtyure2 != num5)
  2356. {
  2357. skirtyure2 = num5;
  2358. Preferences["config"]["skirt_damping"].Value = skirtyure2.ToString();
  2359. SaveConfig();
  2360. }
  2361. GUI.Label(new Rect(GetPix(10), GetPix(590), GetPix(100), GetPix(25)),
  2362. "パニエ力",
  2363. guistyle2);
  2364. float num6 = GUI.HorizontalSlider(new Rect(GetPix(8),
  2365. GetPix(604),
  2366. GetPix(92),
  2367. GetPix(20)),
  2368. skirtyure3,
  2369. 0f,
  2370. 0.1f);
  2371. if (skirtyure3 != num6)
  2372. {
  2373. skirtyure3 = num6;
  2374. Preferences["config"]["skirt_elasticity"].Value = skirtyure3.ToString();
  2375. SaveConfig();
  2376. }
  2377. GUI.enabled = true;
  2378. }
  2379. GUI.enabled = true;
  2380. GUI.DrawTexture(new Rect(GetPix(5), GetPix(389), GetPix(195), 2f), line1);
  2381. GUI.DrawTexture(new Rect(GetPix(5), GetPix(389), GetPix(195), 1f), line2);
  2382. if (doguCombo.isClickedComboButton || parCombo.isClickedComboButton || bgCombo.isClickedComboButton
  2383. || bgmCombo.isClickedComboButton)
  2384. {
  2385. GUI.enabled = false;
  2386. }
  2387. GUI.DrawTexture(new Rect(GetPix(5), GetPix(176), GetPix(195), 2f), line1);
  2388. GUI.DrawTexture(new Rect(GetPix(5), GetPix(176), GetPix(195), 1f), line2);
  2389. GUI.Label(new Rect(GetPix(8), GetPix(187), GetPix(100), GetPix(25)),
  2390. "照明",
  2391. guistyle2);
  2392. listStyle3.padding.top = GetPix(3);
  2393. listStyle3.padding.bottom = GetPix(2);
  2394. listStyle3.fontSize = GetPix(13);
  2395. int num7 = lightCombo.List(new Rect(GetPix(34),
  2396. GetPix(185),
  2397. GetPix(78),
  2398. GetPix(23)),
  2399. lightComboList[selectLightIndex].text,
  2400. lightComboList,
  2401. guistyle4,
  2402. "box",
  2403. listStyle3);
  2404. if (num7 != selectLightIndex)
  2405. {
  2406. selectLightIndex = num7;
  2407. isIdx1 = false;
  2408. isIdx2 = false;
  2409. isIdx3 = false;
  2410. isIdx4 = false;
  2411. }
  2412. if (GUI.Button(new Rect(GetPix(115), GetPix(185), GetPix(35), GetPix(23)),
  2413. "追加",
  2414. guistyle3))
  2415. {
  2416. GameObject gameObject = new GameObject("Light");
  2417. gameObject.AddComponent<Light>();
  2418. lightList.Add(gameObject);
  2419. lightColorR.Add(1f);
  2420. lightColorG.Add(1f);
  2421. lightColorB.Add(1f);
  2422. lightIndex.Add(0);
  2423. lightX.Add(40f);
  2424. lightY.Add(180f);
  2425. lightAkarusa.Add(0.95f);
  2426. lightKage.Add(0.098f);
  2427. lightRange.Add(50f);
  2428. gameObject.transform.position = GameMain.Instance.MainLight.transform.position;
  2429. selectLightIndex = lightList.Count - 1;
  2430. lightComboList = new GUIContent[lightList.Count];
  2431. for (int i = 0; i < lightList.Count; i++)
  2432. {
  2433. if (i == 0)
  2434. {
  2435. lightComboList[i] = new GUIContent("メイン");
  2436. }
  2437. else
  2438. {
  2439. lightComboList[i] = new GUIContent("追加" + i);
  2440. }
  2441. }
  2442. lightCombo.selectedItemIndex = selectLightIndex;
  2443. gameObject.GetComponent<Light>().intensity = 0.95f;
  2444. gameObject.GetComponent<Light>().spotAngle = 50f;
  2445. gameObject.GetComponent<Light>().range = 10f;
  2446. gameObject.GetComponent<Light>().type = LightType.Directional;
  2447. gameObject.GetComponent<Light>().color = new Color(0.5f, 1f, 0f);
  2448. if (gLight[selectLightIndex] == null)
  2449. {
  2450. gLight[selectLightIndex] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  2451. Material material = new Material(Shader.Find("Transparent/Diffuse"))
  2452. {
  2453. color = new Color(0.5f, 0.5f, 1f, 0.8f)
  2454. };
  2455. gLight[selectLightIndex].GetComponent<Renderer>().material = material;
  2456. gLight[selectLightIndex].layer = 8;
  2457. gLight[selectLightIndex].GetComponent<Renderer>().enabled = false;
  2458. gLight[selectLightIndex].SetActive(false);
  2459. gLight[selectLightIndex].transform.position = gameObject.transform.position;
  2460. mLight[selectLightIndex] = gLight[selectLightIndex].AddComponent<MouseDrag6>();
  2461. mLight[selectLightIndex].obj = gLight[selectLightIndex];
  2462. mLight[selectLightIndex].maid = gameObject.gameObject;
  2463. mLight[selectLightIndex].angles = gameObject.gameObject.transform.eulerAngles;
  2464. gLight[selectLightIndex].transform.localScale = new Vector3(0.12f, 0.12f, 0.12f);
  2465. mLight[selectLightIndex].ido = 1;
  2466. mLight[selectLightIndex].isScale = false;
  2467. }
  2468. }
  2469. if (GUI.Button(new Rect(GetPix(153), GetPix(185), GetPix(23), GetPix(23)),
  2470. "R",
  2471. guistyle3))
  2472. {
  2473. for (int i = 1; i < lightList.Count; i++)
  2474. {
  2475. Destroy(lightList[i]);
  2476. }
  2477. lightIndex = new List<int>
  2478. {
  2479. 0
  2480. };
  2481. lightColorR = new List<float>
  2482. {
  2483. 1f
  2484. };
  2485. lightColorG = new List<float>
  2486. {
  2487. 1f
  2488. };
  2489. lightColorB = new List<float>
  2490. {
  2491. 1f
  2492. };
  2493. lightX = new List<float>
  2494. {
  2495. 40f
  2496. };
  2497. lightY = new List<float>
  2498. {
  2499. 180f
  2500. };
  2501. lightAkarusa = new List<float>
  2502. {
  2503. 0.95f
  2504. };
  2505. lightKage = new List<float>
  2506. {
  2507. 0.098f
  2508. };
  2509. lightRange = new List<float>
  2510. {
  2511. 50f
  2512. };
  2513. lightCombo.selectedItemIndex = 0;
  2514. lightList = new List<GameObject>
  2515. {
  2516. GameMain.Instance.MainLight.gameObject
  2517. };
  2518. lightComboList = new GUIContent[lightList.Count];
  2519. for (int i = 0; i < lightList.Count; i++)
  2520. {
  2521. if (i == 0)
  2522. {
  2523. lightComboList[i] = new GUIContent("メイン");
  2524. }
  2525. else
  2526. {
  2527. lightComboList[i] = new GUIContent("追加" + i);
  2528. }
  2529. }
  2530. selectLightIndex = 0;
  2531. GameMain.Instance.MainLight.Reset();
  2532. GameMain.Instance.MainLight.SetIntensity(0.95f);
  2533. GameMain.Instance.MainLight.GetComponent<Light>().spotAngle = 50f;
  2534. GameMain.Instance.MainLight.GetComponent<Light>().range = 10f;
  2535. GameMain.Instance.MainLight.gameObject.transform.position = new Vector3(0f, 2f, 0f);
  2536. GameMain.Instance.MainLight.GetComponent<Light>().type = LightType.Directional;
  2537. bgObject.SetActive(true);
  2538. mainCamera.GetComponent<Camera>().backgroundColor = new Color(0f, 0f, 0f);
  2539. isIdx1 = false;
  2540. isIdx2 = false;
  2541. isIdx3 = false;
  2542. isIdx4 = false;
  2543. }
  2544. GUI.enabled = true;
  2545. if (doguCombo.isClickedComboButton || bgCombo.isClickedComboButton || bgmCombo.isClickedComboButton)
  2546. {
  2547. GUI.enabled = false;
  2548. }
  2549. listStyle3.padding.top = GetPix(0);
  2550. listStyle3.padding.bottom = GetPix(0);
  2551. listStyle3.fontSize = GetPix(12);
  2552. GUI.Label(new Rect(GetPix(8), GetPix(116), GetPix(150), GetPix(25)),
  2553. "大道具2",
  2554. guistyle2);
  2555. parIndex = parCombo.List(new Rect(GetPix(51),
  2556. GetPix(113),
  2557. GetPix(100),
  2558. GetPix(23)),
  2559. parComboList[parIndex].text,
  2560. parComboList,
  2561. guistyle4,
  2562. "box",
  2563. listStyle3);
  2564. if (GUI.Button(new Rect(GetPix(156), GetPix(113), GetPix(38), GetPix(23)),
  2565. "追加",
  2566. guistyle3))
  2567. {
  2568. GameObject gameObject2 = null;
  2569. bool flag5 = false;
  2570. bool flag6 = false;
  2571. if (parArray[parIndex].Contains("#"))
  2572. {
  2573. string[] array3 = parArray[parIndex].Split(new char[] { '#' });
  2574. gameObject2 = GameMain.Instance.BgMgr.CreateAssetBundle(array3[1]);
  2575. if (gameObject2 != null)
  2576. {
  2577. gameObject2 = Instantiate(gameObject2);
  2578. MeshRenderer[] componentsInChildren = gameObject2.GetComponentsInChildren<MeshRenderer>();
  2579. for (int k = 0; k < componentsInChildren.Length; k++)
  2580. {
  2581. if (componentsInChildren[k] != null)
  2582. {
  2583. componentsInChildren[k].shadowCastingMode = ShadowCastingMode.Off;
  2584. }
  2585. }
  2586. }
  2587. flag5 = true;
  2588. if (!parArray[parIndex].Contains("Odogu_"))
  2589. {
  2590. flag6 = true;
  2591. }
  2592. doguBObject.Add(gameObject2);
  2593. }
  2594. else if (!parArray[parIndex].StartsWith("mirror") && parArray[parIndex].IndexOf(":") < 0)
  2595. {
  2596. Object @object = Resources.Load("Prefab/" + parArray[parIndex]);
  2597. gameObject2 = Instantiate(@object) as GameObject;
  2598. doguBObject.Add(gameObject2);
  2599. }
  2600. else if (parArray[parIndex].StartsWith("mirror"))
  2601. {
  2602. Material material2 = new Material(Shader.Find("Mirror"));
  2603. GameObject gameObject3 = GameObject.CreatePrimitive(PrimitiveType.Plane);
  2604. gameObject3.GetComponent<Renderer>().material = material2;
  2605. gameObject3.AddComponent<MirrorReflection2>();
  2606. MirrorReflection2 component2 = gameObject3.GetComponent<MirrorReflection2>();
  2607. component2.m_TextureSize = 2048;
  2608. component2.m_ClipPlaneOffset = 0.07f;
  2609. gameObject3.GetComponent<Renderer>().enabled = true;
  2610. gameObject2 = gameObject3;
  2611. doguBObject.Add(gameObject2);
  2612. }
  2613. else
  2614. {
  2615. string[] array3 = parArray[parIndex].Split(new char[] { ':' });
  2616. Object @object = GameMain.Instance.BgMgr.CreateAssetBundle(array3[0]);
  2617. if (@object == null)
  2618. {
  2619. @object = Resources.Load("BG/" + array3[0]);
  2620. }
  2621. GameObject gameObject4 = Instantiate(@object) as GameObject;
  2622. int num8 = 0;
  2623. int.TryParse(array3[1], out int num9);
  2624. foreach (object obj in gameObject4.transform)
  2625. {
  2626. Transform transform = (Transform)obj;
  2627. if (num9 == num8)
  2628. {
  2629. gameObject2 = transform.gameObject;
  2630. break;
  2631. }
  2632. num8++;
  2633. }
  2634. doguBObject.Add(gameObject2);
  2635. gameObject2.transform.parent = null;
  2636. Destroy(gameObject4);
  2637. gameObject4.SetActive(false);
  2638. }
  2639. gameObject2.name = parArray[parIndex];
  2640. Vector3 zero = Vector3.zero;
  2641. Vector3 zero2 = Vector3.zero;
  2642. switch (parIndex)
  2643. {
  2644. case 0:
  2645. zero.z = -0.6f;
  2646. zero.y = 0.96f;
  2647. zero2.z = 180f;
  2648. zero2.x = -90f;
  2649. gameObject2.transform.localScale = new Vector3(0.2f, 0.4f, 0.2f);
  2650. break;
  2651. case 1:
  2652. zero.z = -0.6f;
  2653. zero.y = 0.96f;
  2654. zero2.z = 180f;
  2655. zero2.x = -90f;
  2656. gameObject2.transform.localScale = new Vector3(0.1f, 0.4f, 0.2f);
  2657. break;
  2658. case 2:
  2659. zero.z = -0.6f;
  2660. zero.y = 0.85f;
  2661. zero2.z = 180f;
  2662. zero2.x = -90f;
  2663. gameObject2.transform.localScale = new Vector3(0.03f, 0.18f, 0.124f);
  2664. break;
  2665. case 3:
  2666. case 4:
  2667. case 5:
  2668. case 6:
  2669. case 7:
  2670. case 8:
  2671. case 9:
  2672. case 10:
  2673. case 11:
  2674. case 12:
  2675. case 13:
  2676. case 14:
  2677. case 15:
  2678. case 16:
  2679. case 17:
  2680. zero.z = 0.5f;
  2681. zero2.x = -90f;
  2682. break;
  2683. }
  2684. if (flag5)
  2685. {
  2686. zero.z = 0.4f;
  2687. if (flag6)
  2688. {
  2689. zero2.x = -90f;
  2690. }
  2691. }
  2692. if (gameObject2.name == "Salon_Entrance:3" || gameObject2.name == "Salon_Entrance:4"
  2693. || gameObject2.name == "Salon_Entrance:1"
  2694. || gameObject2.name == "Salon_Entrance:2"
  2695. || gameObject2.name == "Salon_Entrance:0" || gameObject2.name == "Shitsumu:23"
  2696. || gameObject2.name == "Shitsumu_Night:23")
  2697. {
  2698. zero.z = 0.5f;
  2699. zero2.x = -90f;
  2700. }
  2701. if (gameObject2.name == "Pool:26")
  2702. {
  2703. zero.z = 0.5f;
  2704. zero2.x = -90f;
  2705. zero2.z = 90f;
  2706. zero.y = 0.15f;
  2707. }
  2708. if (gameObject2.name == "Particle/pstarY_act2")
  2709. {
  2710. zero2.y = 90f;
  2711. }
  2712. gameObject2.transform.localPosition = zero;
  2713. gameObject2.transform.localRotation = Quaternion.Euler(zero2);
  2714. doguCnt = doguBObject.Count - 1;
  2715. gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  2716. gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
  2717. gDogu[doguCnt].layer = 8;
  2718. gDogu[doguCnt].GetComponent<Renderer>().enabled = false;
  2719. gDogu[doguCnt].SetActive(false);
  2720. gDogu[doguCnt].transform.position = gameObject2.transform.position;
  2721. mDogu[doguCnt] = gDogu[doguCnt].AddComponent<MouseDrag6>();
  2722. mDogu[doguCnt].obj = gDogu[doguCnt];
  2723. mDogu[doguCnt].maid = gameObject2;
  2724. mDogu[doguCnt].angles = gameObject2.transform.eulerAngles;
  2725. gDogu[doguCnt].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  2726. mDogu[doguCnt].ido = 1;
  2727. mDogu[doguCnt].isScale = false;
  2728. if (gameObject2.name == "Particle/pLineY")
  2729. {
  2730. mDogu[doguCnt].count = 180;
  2731. gameObject2.transform.localScale = new Vector3(3f, 3f, 3f);
  2732. }
  2733. if (gameObject2.name == "Particle/pLineP02")
  2734. {
  2735. mDogu[doguCnt].count = 115;
  2736. gameObject2.transform.localScale = new Vector3(3f, 3f, 3f);
  2737. }
  2738. if (gameObject2.name == "Particle/pLine_act2")
  2739. {
  2740. mDogu[doguCnt].count = 90;
  2741. gameObject2.transform.localScale = new Vector3(3f, 3f, 3f);
  2742. }
  2743. if (gameObject2.name == "Particle/pHeart01")
  2744. {
  2745. mDogu[doguCnt].count = 77;
  2746. }
  2747. if (parIndex < 3)
  2748. {
  2749. mDogu[doguCnt].isScale = true;
  2750. mDogu[doguCnt].isScale2 = true;
  2751. mDogu[doguCnt].scale2 = gameObject2.transform.localScale;
  2752. if (parIndex == 0)
  2753. {
  2754. mDogu[doguCnt].scale = new Vector3(gameObject2.transform.localScale.x * 5f,
  2755. gameObject2.transform.localScale.y * 5f,
  2756. gameObject2.transform.localScale.z * 5f);
  2757. }
  2758. if (parIndex == 1)
  2759. {
  2760. mDogu[doguCnt].scale = new Vector3(gameObject2.transform.localScale.x * 10f,
  2761. gameObject2.transform.localScale.y * 10f,
  2762. gameObject2.transform.localScale.z * 10f);
  2763. }
  2764. if (parIndex == 2)
  2765. {
  2766. mDogu[doguCnt].scale = new Vector3(gameObject2.transform.localScale.x * 33f,
  2767. gameObject2.transform.localScale.y * 33f,
  2768. gameObject2.transform.localScale.z * 33f);
  2769. }
  2770. }
  2771. if (gameObject2.GetComponent<Collider>() != null)
  2772. {
  2773. gameObject2.GetComponent<Collider>().enabled = false;
  2774. }
  2775. }
  2776. GUI.enabled = true;
  2777. if (bgCombo.isClickedComboButton || bgmCombo.isClickedComboButton)
  2778. {
  2779. GUI.enabled = false;
  2780. }
  2781. GUI.Label(new Rect(GetPix(8), GetPix(88), GetPix(100), GetPix(25)),
  2782. "大道具1",
  2783. guistyle2);
  2784. doguBIndex =
  2785. doguCombo.List(new Rect(GetPix(51),
  2786. GetPix(85),
  2787. GetPix(100),
  2788. GetPix(23)),
  2789. doguComboList[doguBIndex].text,
  2790. doguComboList,
  2791. guistyle4,
  2792. "box",
  2793. listStyle3);
  2794. if (GUI.Button(new Rect(GetPix(156), GetPix(85), GetPix(38), GetPix(23)),
  2795. "追加",
  2796. guistyle3))
  2797. {
  2798. GameObject gameObject2 = null;
  2799. if (doguDict.TryGetValue(doguBArray[doguBIndex], out PhotoBGObjectData objResult))
  2800. {
  2801. if (!string.IsNullOrEmpty(objResult.create_prefab_name))
  2802. {
  2803. Object tmpObj = Resources.Load("Prefab/" + objResult.create_prefab_name);
  2804. if (tmpObj == null)
  2805. {
  2806. gameObject2 = null;
  2807. }
  2808. else
  2809. {
  2810. gameObject2 = Instantiate(tmpObj) as GameObject;
  2811. }
  2812. }
  2813. else if (!string.IsNullOrEmpty(objResult.create_asset_bundle_name))
  2814. {
  2815. GameObject gameObject3 = GameMain.Instance.BgMgr.CreateAssetBundle(objResult.create_asset_bundle_name);
  2816. if (gameObject3 == null)
  2817. {
  2818. gameObject2 = null;
  2819. }
  2820. else
  2821. {
  2822. gameObject2 = Instantiate(gameObject3);
  2823. }
  2824. }
  2825. else if (!string.IsNullOrEmpty(objResult.direct_file))
  2826. {
  2827. BasePhotoCustomObject basePhotoCustomObject =
  2828. BasePhotoCustomObject.InstantiateFromFile(transform.gameObject, objResult.direct_file);
  2829. gameObject2 = basePhotoCustomObject.gameObject;
  2830. }
  2831. if (gameObject2 != null)
  2832. {
  2833. doguBObject.Add(gameObject2);
  2834. }
  2835. }
  2836. else if (!doguBArray[doguBIndex].StartsWith("mirror"))
  2837. {
  2838. Object @object;
  2839. if (doguBArray[doguBIndex].StartsWith("BG"))
  2840. {
  2841. string text2 = doguBArray[doguBIndex].Replace("BG", "");
  2842. @object = GameMain.Instance.BgMgr.CreateAssetBundle(text2);
  2843. if (@object == null)
  2844. {
  2845. @object = Resources.Load("BG/" + text2);
  2846. }
  2847. }
  2848. else
  2849. {
  2850. @object = Resources.Load("Prefab/" + doguBArray[doguBIndex]);
  2851. }
  2852. gameObject2 = Instantiate(@object) as GameObject;
  2853. doguBObject.Add(gameObject2);
  2854. }
  2855. else
  2856. {
  2857. Material material2 = new Material(Shader.Find("Mirror"));
  2858. GameObject gameObject3 = GameObject.CreatePrimitive(PrimitiveType.Plane);
  2859. gameObject3.transform.localScale = new Vector3(0.3f, 1f, 0.3f);
  2860. gameObject3.GetComponent<Renderer>().material = material2;
  2861. gameObject3.AddComponent<MirrorReflection2>();
  2862. MirrorReflection2 component2 = gameObject3.GetComponent<MirrorReflection2>();
  2863. component2.m_TextureSize = 2048;
  2864. component2.m_ClipPlaneOffset = 0f;
  2865. gameObject3.GetComponent<Renderer>().enabled = true;
  2866. gameObject2 = gameObject3;
  2867. doguBObject.Add(gameObject2);
  2868. }
  2869. gameObject2.name = doguBArray[doguBIndex];
  2870. Vector3 zero = Vector3.zero;
  2871. Vector3 zero2 = Vector3.zero;
  2872. string text = gameObject2.name;
  2873. switch (text)
  2874. {
  2875. case "Odogu_XmasTreeMini_photo_ver":
  2876. zero.z = 0.6f;
  2877. gameObject2.transform.localScale = new Vector3(4.5f, 4.5f, 4.5f);
  2878. foreach (object obj2 in gameObject2.transform)
  2879. {
  2880. Transform transform2 = (Transform)obj2;
  2881. if (transform2.GetComponent<Collider>() != null)
  2882. {
  2883. transform2.GetComponent<Collider>().enabled = false;
  2884. }
  2885. }
  2886. goto IL_A0BF;
  2887. case "Odogu_KadomatsuMini_photo_ver":
  2888. zero.z = 0.6f;
  2889. gameObject2.transform.localScale = new Vector3(3.5f, 3.5f, 3.5f);
  2890. foreach (object obj3 in gameObject2.transform)
  2891. {
  2892. Transform transform2 = (Transform)obj3;
  2893. if (transform2.GetComponent<Collider>() != null)
  2894. {
  2895. transform2.GetComponent<Collider>().enabled = false;
  2896. }
  2897. }
  2898. goto IL_A0BF;
  2899. case "Odogu_ClassRoomDesk":
  2900. zero.z = 0.5f;
  2901. zero2.x = -90f;
  2902. goto IL_A0BF;
  2903. case "Odogu_SimpleTable":
  2904. zero.z = 0.5f;
  2905. zero2.x = -90f;
  2906. goto IL_A0BF;
  2907. case "Odogu_DildoBox":
  2908. zero.z = 0.5f;
  2909. zero2.x = -90f;
  2910. goto IL_A0BF;
  2911. case "PlayAreaOut":
  2912. zero.z = 0.5f;
  2913. zero.y = 0.2f;
  2914. goto IL_A0BF;
  2915. case "Odogu_Dresser_photo_ver":
  2916. GameObject.Find("Prim.00000000").GetComponent<Collider>().enabled = false;
  2917. GameObject.Find("Prim.00000001").GetComponent<Collider>().enabled = false;
  2918. GameObject.Find("Prim.00000002").GetComponent<Collider>().enabled = false;
  2919. GameObject.Find("Prim.00000004").GetComponent<Collider>().enabled = false;
  2920. goto IL_A0BF;
  2921. case "BGodogu_bbqgrill":
  2922. case "BGodogu_bucket":
  2923. case "BGodogu_coolerbox":
  2924. case "BGodogu_game_darts":
  2925. case "BGodogu_game_dartsboard":
  2926. case "BGodogu_nabe_huta":
  2927. case "BGodogu_nabe_water":
  2928. case "BGodogu_natumikan":
  2929. case "BGodogu_rb_chair":
  2930. case "BGodogu_rb_duck":
  2931. case "BGodogu_rb_obon":
  2932. case "BGodogu_rb_tokkuri":
  2933. case "BGodogu_saracorn":
  2934. case "BGodogu_saraimo":
  2935. case "BGodogu_saratomato":
  2936. case "BGodogu_sunanoshiro":
  2937. case "BGodogu_sunanoyama":
  2938. case "BGodogu_tsutsuhanabi":
  2939. case "BGodogu_ukiwa":
  2940. case "BGodogu_vf_crops_corn":
  2941. case "BGodogu_vf_crops_gekkabijin":
  2942. case "BGodogu_vf_crops_gekkabijinflower":
  2943. case "BGodogu_vf_crops_himawari":
  2944. case "BGodogu_vf_crops_natsumikan":
  2945. case "BGodogu_vf_crops_suika":
  2946. case "BGodogu_vf_crops_zakuro":
  2947. case "BGodogu_villa_table":
  2948. case "BGodogu_villa_tvrimocon":
  2949. case "BGodogu_villabr_sideboard":
  2950. case "BGOdogu_Game_Nei_USB":
  2951. case "BGOdogu_Game_Wanage":
  2952. case "BGOdogu_Game_Wa":
  2953. case "BGodogu_pafe":
  2954. case "BGodogu_furaidopoteto":
  2955. case "BGodogu_karaoketable":
  2956. case "BGodogu_omuriceh":
  2957. case "BGodogu_omuricekao1":
  2958. case "BGodogu_omuricekao2":
  2959. case "BGodogu_omuriceoppai":
  2960. case "BGodogu_kakigori":
  2961. case "BGodogu_pretzel_sara":
  2962. case "BGodogu_karaoke_box":
  2963. case "Odogu_StandMike":
  2964. case "Odogu_StandMikeBase":
  2965. case "Odogu_HeroineChair_muku":
  2966. case "Odogu_HeroineChair_mazime":
  2967. case "Odogu_HeroineChair_rindere":
  2968. case "Odogu_HeroineChair_tsumdere":
  2969. case "Odogu_HeroineChair_cooldere":
  2970. case "Odogu_HeroineChair_junshin":
  2971. case "Odogu_TabletPC":
  2972. case "Odogu_Styluspen_black":
  2973. case "Odogu_Styluspen_white":
  2974. case "Odogu_Styluspen_red":
  2975. case "Odogu_Styluspen_blue":
  2976. case "Odogu_Styluspen_yellow":
  2977. case "Odogu_Styluspen_green":
  2978. case "Odogu_Omurice1":
  2979. case "Odogu_Omurice3":
  2980. case "Odogu_OmuriceH":
  2981. case "Odogu_OmuriceKao1":
  2982. case "Odogu_OmuriceKao2":
  2983. case "Odogu_OmuriceOppai":
  2984. case "Odogu_AcquaPazza":
  2985. case "Odogu_Sandwich":
  2986. case "Odogu_vichyssoise":
  2987. case "Odogu_BirthdayCake":
  2988. case "Odogu_Shortcake":
  2989. case "Odogu_MontBlanc":
  2990. case "Odogu_Pafe":
  2991. case "Odogu_Smoothie_Red":
  2992. case "Odogu_Smoothie_Green":
  2993. case "Odogu_Cocktail_Red":
  2994. case "Odogu_Cocktail_Blue":
  2995. case "Odogu_Cocktail_Yellow":
  2996. case "Odogu_Coffiecup":
  2997. case "Odogu_WineBottle(cap_off)":
  2998. case "Odogu_WineBottle(cap_on)":
  2999. case "Odogu_Jyouro":
  3000. case "Odogu_Planter_Red":
  3001. case "Odogu_Planter_Lightblue":
  3002. case "Odogu_MariGold":
  3003. case "Odogu_CasinoChip_10":
  3004. case "Odogu_CasinoChip_100":
  3005. case "Odogu_CasinoChip_1000":
  3006. case "Odogu_CardShooter":
  3007. case "Odogu_CardsDeck":
  3008. case "Odogu_Card_s1":
  3009. case "Odogu_Card_s2":
  3010. case "Odogu_Card_s3":
  3011. case "Odogu_Card_s4":
  3012. case "Odogu_Card_s5":
  3013. case "Odogu_Card_s6":
  3014. case "Odogu_Card_s7":
  3015. case "Odogu_Card_s8":
  3016. case "Odogu_Card_s9":
  3017. case "Odogu_Card_s10":
  3018. case "Odogu_Card_s11":
  3019. case "Odogu_Card_s12":
  3020. case "Odogu_Card_s13":
  3021. case "Odogu_Card_h1":
  3022. case "Odogu_Card_h2":
  3023. case "Odogu_Card_h3":
  3024. case "Odogu_Card_h4":
  3025. case "Odogu_Card_h5":
  3026. case "Odogu_Card_h6":
  3027. case "Odogu_Card_h7":
  3028. case "Odogu_Card_h8":
  3029. case "Odogu_Card_h9":
  3030. case "Odogu_Card_h10":
  3031. case "Odogu_Card_h11":
  3032. case "Odogu_Card_h12":
  3033. case "Odogu_Card_h13":
  3034. case "Odogu_Card_d1":
  3035. case "Odogu_Card_d2":
  3036. case "Odogu_Card_d3":
  3037. case "Odogu_Card_d4":
  3038. case "Odogu_Card_d5":
  3039. case "Odogu_Card_d6":
  3040. case "Odogu_Card_d7":
  3041. case "Odogu_Card_d8":
  3042. case "Odogu_Card_d9":
  3043. case "Odogu_Card_d10":
  3044. case "Odogu_Card_d11":
  3045. case "Odogu_Card_d12":
  3046. case "Odogu_Card_d13":
  3047. case "Odogu_Card_c1":
  3048. case "Odogu_Card_c2":
  3049. case "Odogu_Card_c3":
  3050. case "Odogu_Card_c4":
  3051. case "Odogu_Card_c5":
  3052. case "Odogu_Card_c6":
  3053. case "Odogu_Card_c7":
  3054. case "Odogu_Card_c8":
  3055. case "Odogu_Card_c9":
  3056. case "Odogu_Card_c10":
  3057. case "Odogu_Card_c11":
  3058. case "Odogu_Card_c12":
  3059. case "Odogu_Card_c13":
  3060. case "Odogu_Card_joker":
  3061. zero.z = 0.5f;
  3062. zero2.x = -90f;
  3063. goto IL_A0BF;
  3064. }
  3065. zero.z = 0.5f;
  3066. if (gameObject2.name.StartsWith("Odogu_"))
  3067. {
  3068. foreach (object obj4 in gameObject2.transform)
  3069. {
  3070. Transform transform2 = (Transform)obj4;
  3071. if (transform2.GetComponent<Collider>() != null)
  3072. {
  3073. transform2.GetComponent<Collider>().enabled = false;
  3074. }
  3075. }
  3076. }
  3077. else if (gameObject2.GetComponent<Collider>() != null)
  3078. {
  3079. gameObject2.GetComponent<Collider>().enabled = false;
  3080. }
  3081. IL_A0BF:
  3082. gameObject2.transform.localPosition = zero;
  3083. gameObject2.transform.localRotation = Quaternion.Euler(zero2);
  3084. doguCnt = doguBObject.Count - 1;
  3085. gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
  3086. gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
  3087. gDogu[doguCnt].layer = 8;
  3088. gDogu[doguCnt].GetComponent<Renderer>().enabled = false;
  3089. gDogu[doguCnt].SetActive(false);
  3090. gDogu[doguCnt].transform.position = gameObject2.transform.position;
  3091. mDogu[doguCnt] = gDogu[doguCnt].AddComponent<MouseDrag6>();
  3092. mDogu[doguCnt].isScale = false;
  3093. mDogu[doguCnt].obj = gDogu[doguCnt];
  3094. mDogu[doguCnt].maid = gameObject2;
  3095. mDogu[doguCnt].angles = gameObject2.transform.eulerAngles;
  3096. gDogu[doguCnt].transform.localScale = new Vector3(cubeSize, cubeSize, cubeSize);
  3097. mDogu[doguCnt].ido = 1;
  3098. if (doguBIndex == 6 || doguBIndex == 7)
  3099. {
  3100. mDogu[doguCnt].isScale2 = true;
  3101. mDogu[doguCnt].scale2 = gameObject2.transform.localScale;
  3102. }
  3103. }
  3104. GUI.EndScrollView();
  3105. GUI.enabled = true;
  3106. if (bgmCombo.isClickedComboButton)
  3107. {
  3108. GUI.enabled = false;
  3109. }
  3110. listStyle3.padding.top = GetPix(1);
  3111. listStyle3.padding.bottom = GetPix(0);
  3112. listStyle3.fontSize = GetPix(12);
  3113. int num10 = bgCombo.List(new Rect(GetPix(31),
  3114. GetPix(53),
  3115. GetPix(95),
  3116. GetPix(23)),
  3117. bgComboList[bgIndex].text,
  3118. bgComboList,
  3119. guistyle4,
  3120. "box",
  3121. listStyle3);
  3122. if (GUI.Button(new Rect(GetPix(5), GetPix(53), GetPix(23), GetPix(23)),
  3123. "<",
  3124. guistyle3))
  3125. {
  3126. num10--;
  3127. if (num10 <= -1)
  3128. {
  3129. num10 = bgArray.Length - 1;
  3130. }
  3131. }
  3132. if (GUI.Button(new Rect(GetPix(129), GetPix(53), GetPix(23), GetPix(23)),
  3133. ">",
  3134. guistyle3))
  3135. {
  3136. num10++;
  3137. if (num10 == bgArray.Length)
  3138. {
  3139. num10 = 0;
  3140. }
  3141. }
  3142. if (bgIndex != num10)
  3143. {
  3144. bgIndex = num10;
  3145. bg.localScale = new Vector3(1f, 1f, 1f);
  3146. if (bgArray[bgIndex].Length == 36)
  3147. {
  3148. GameMain.Instance.BgMgr.ChangeBgMyRoom(bgArray[bgIndex]);
  3149. }
  3150. else
  3151. {
  3152. GameMain.Instance.BgMgr.ChangeBg(bgArray[bgIndex]);
  3153. }
  3154. bgCombo.selectedItemIndex = bgIndex;
  3155. if (bgArray[bgIndex] == "karaokeroom")
  3156. {
  3157. bg.transform.position = bgObject.transform.position;
  3158. Vector3 zero = Vector3.zero;
  3159. Vector3 zero2 = Vector3.zero;
  3160. zero2.y = 90f;
  3161. zero.z = 4f;
  3162. zero.x = 1f;
  3163. bg.transform.localPosition = zero;
  3164. bg.transform.localRotation = Quaternion.Euler(zero2);
  3165. }
  3166. }
  3167. GUI.enabled = true;
  3168. int num11 = bgmCombo.List(new Rect(GetPix(31),
  3169. GetPix(25),
  3170. GetPix(95),
  3171. GetPix(23)),
  3172. bgmComboList[bgmIndex].text,
  3173. bgmComboList,
  3174. guistyle4,
  3175. "box",
  3176. listStyle3);
  3177. if (GUI.Button(new Rect(GetPix(5), GetPix(25), GetPix(23), GetPix(23)),
  3178. "<",
  3179. guistyle3))
  3180. {
  3181. num11--;
  3182. if (num11 <= -1)
  3183. {
  3184. num11 = bgmArray.Length - 1;
  3185. }
  3186. }
  3187. if (GUI.Button(new Rect(GetPix(129), GetPix(25), GetPix(23), GetPix(23)),
  3188. ">",
  3189. guistyle3))
  3190. {
  3191. num11++;
  3192. if (num11 == bgmArray.Length)
  3193. {
  3194. num11 = 0;
  3195. }
  3196. }
  3197. if (bgmIndex != num11)
  3198. {
  3199. bgmIndex = num11;
  3200. GameMain.Instance.SoundMgr.PlayBGM(bgmArray[bgmIndex] + ".ogg", 0f, true);
  3201. bgmCombo.selectedItemIndex = bgmIndex;
  3202. }
  3203. GUI.DragWindow();
  3204. if (bgmCombo.isClickedComboButton)
  3205. {
  3206. GUI.enabled = false;
  3207. }
  3208. }
  3209. private void PoseWindow(int winID)
  3210. {
  3211. GUIStyle style1 = "label";
  3212. style1.fontSize = GetPix(12);
  3213. style1.alignment = TextAnchor.UpperLeft;
  3214. GUIStyle style2 = "label";
  3215. style2.fontSize = GetPix(11);
  3216. style2.alignment = TextAnchor.UpperLeft;
  3217. GUIStyle style3 = "button";
  3218. style3.fontSize = GetPix(20);
  3219. GUIStyle buttonStyle1 = "button";
  3220. buttonStyle1.fontSize = GetPix(14);
  3221. buttonStyle1.alignment = TextAnchor.MiddleLeft;
  3222. GUIStyle buttonStyle2 = "button";
  3223. buttonStyle2.fontSize = GetPix(12);
  3224. buttonStyle2.alignment = TextAnchor.MiddleLeft;
  3225. GUIStyle style4 = new GUIStyle("toggle")
  3226. {
  3227. fontSize = GetPix(13)
  3228. };
  3229. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  3230. Maid maid = maidArray[selectMaidIndex];
  3231. if (!poseInitFlg)
  3232. {
  3233. listStyle2.normal.textColor = Color.white;
  3234. listStyle2.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  3235. listStyle2.onHover.background = listStyle2.hover.background = new Texture2D(2, 2);
  3236. listStyle2.padding.left = listStyle2.padding.right = listStyle2.padding.top = listStyle2.padding.bottom = GetPix(0);
  3237. listStyle2.fontSize = GetPix(12);
  3238. listStyle3.normal.textColor = Color.white;
  3239. listStyle3.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  3240. listStyle3.onHover.background = listStyle3.hover.background = new Texture2D(2, 2);
  3241. listStyle3.padding.left = listStyle3.padding.right = listStyle3.padding.top = GetPix(1);
  3242. listStyle3.padding.bottom = GetPix(0);
  3243. listStyle3.fontSize = GetPix(12);
  3244. listStyle4.normal.textColor = Color.white;
  3245. listStyle4.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  3246. listStyle4.onHover.background = listStyle4.hover.background = new Texture2D(2, 2);
  3247. listStyle4.padding.left = listStyle4.padding.right = listStyle4.padding.top = 3;
  3248. listStyle4.padding.bottom = 3;
  3249. listStyle4.fontSize = GetPix(13);
  3250. poseCombo.selectedItemIndex = 0;
  3251. int group = (int)groupList[0];
  3252. poseComboList = new GUIContent[group];
  3253. for (int index = 0; index < group; ++index)
  3254. {
  3255. poseComboList[index] = new GUIContent((index + 1).ToString() + ":" + poseArray[index]);
  3256. }
  3257. poseGroupCombo.selectedItemIndex = 0;
  3258. poseGroupComboList = new GUIContent[poseGroupArray.Length + 1];
  3259. poseGroupComboList[0] = new GUIContent("1:通常");
  3260. for (int index = 0; index < poseGroupArray.Length; ++index)
  3261. {
  3262. if (poseGroupArray[index] == "maid_dressroom01")
  3263. {
  3264. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":立ち");
  3265. }
  3266. if (poseGroupArray[index] == "tennis_kamae_f")
  3267. {
  3268. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":中腰");
  3269. }
  3270. if (poseGroupArray[index] == "senakanagasi_f")
  3271. {
  3272. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":膝をつく");
  3273. }
  3274. if (poseGroupArray[index] == "work_hansei")
  3275. {
  3276. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":座り");
  3277. }
  3278. if (poseGroupArray[index] == "inu_taiki_f")
  3279. {
  3280. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":四つん這い");
  3281. }
  3282. if (poseGroupArray[index] == "syagami_pose_f")
  3283. {
  3284. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":床座り");
  3285. }
  3286. if (poseGroupArray[index] == "densyasuwari_taiki_f")
  3287. {
  3288. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":椅子座り");
  3289. }
  3290. if (poseGroupArray[index] == "work_kaiwa")
  3291. {
  3292. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":ソファー座り");
  3293. }
  3294. if (poseGroupArray[index] == "dance_cm3d2_001_f1,14.14")
  3295. {
  3296. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":ドキドキ☆Fallin' Love");
  3297. }
  3298. if (poseGroupArray[index] == "dance_cm3d_001_f1,39.25")
  3299. {
  3300. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":entrance to you");
  3301. }
  3302. if (poseGroupArray[index] == "dance_cm3d_002_end_f1,50.71")
  3303. {
  3304. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":scarlet leap");
  3305. }
  3306. if (poseGroupArray[index] == "dance_cm3d2_002_smt_f,7.76,")
  3307. {
  3308. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":stellar my tears");
  3309. }
  3310. if (poseGroupArray[index] == "dance_cm3d_003_sp2_f1,90.15")
  3311. {
  3312. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":rhythmix to you");
  3313. }
  3314. if (poseGroupArray[index] == "dance_cm3d2_003_hs_f1,0.01,")
  3315. {
  3316. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":happy!happy!スキャンダル!!");
  3317. }
  3318. if (poseGroupArray[index] == "dance_cm3d_004_kano_f1,124.93")
  3319. {
  3320. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":Can Know Two Close");
  3321. }
  3322. if (poseGroupArray[index] == "dance_cm3d2_004_sse_f1,0.01")
  3323. {
  3324. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":sweet sweet everyday");
  3325. }
  3326. if (poseGroupArray[index] == "turusi_sex_in_taiki_f")
  3327. {
  3328. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":拘束");
  3329. }
  3330. if (poseGroupArray[index] == "rosyutu_pose01_f")
  3331. {
  3332. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":エロ");
  3333. }
  3334. if (poseGroupArray[index] == "rosyutu_aruki_f_once_,1.37")
  3335. {
  3336. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":歩き");
  3337. }
  3338. if (poseGroupArray[index] == "stand_desk1")
  3339. {
  3340. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":その他");
  3341. }
  3342. if (poseGroupArray[index] == poseArray5[0])
  3343. {
  3344. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":ダンスMC");
  3345. }
  3346. if (poseGroupArray[index] == poseArray6[0])
  3347. {
  3348. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":ダンス");
  3349. }
  3350. if (existPose && strS != "")
  3351. {
  3352. if (index == poseGroupArray.Length - 4)
  3353. {
  3354. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":通常2");
  3355. }
  3356. if (index == poseGroupArray.Length - 3)
  3357. {
  3358. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":エロ2");
  3359. }
  3360. if (index == poseGroupArray.Length - 2)
  3361. {
  3362. poseGroupComboList[index + 1] = new GUIContent("98:撮影モード");
  3363. }
  3364. if (index == poseGroupArray.Length - 1)
  3365. {
  3366. poseGroupComboList[index + 1] = new GUIContent("99:登録ポーズ");
  3367. }
  3368. }
  3369. else if (existPose && strS == "")
  3370. {
  3371. if (index == poseGroupArray.Length - 3)
  3372. {
  3373. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":通常2");
  3374. }
  3375. if (index == poseGroupArray.Length - 2)
  3376. {
  3377. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":エロ2");
  3378. }
  3379. if (index == poseGroupArray.Length - 1)
  3380. {
  3381. poseGroupComboList[index + 1] = new GUIContent("99:登録ポーズ");
  3382. }
  3383. }
  3384. else if (!existPose && strS != "")
  3385. {
  3386. if (index == poseGroupArray.Length - 3)
  3387. {
  3388. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":通常2");
  3389. }
  3390. if (index == poseGroupArray.Length - 2)
  3391. {
  3392. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":エロ2");
  3393. }
  3394. if (index == poseGroupArray.Length - 1)
  3395. {
  3396. poseGroupComboList[index + 1] = new GUIContent("98:撮影モード");
  3397. }
  3398. }
  3399. else
  3400. {
  3401. if (index == poseGroupArray.Length - 2)
  3402. {
  3403. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":通常2");
  3404. }
  3405. if (index == poseGroupArray.Length - 1)
  3406. {
  3407. poseGroupComboList[index + 1] = new GUIContent((index + 2).ToString() + ":エロ2");
  3408. }
  3409. }
  3410. }
  3411. poseInitFlg = true;
  3412. itemCombo.selectedItemIndex = 0;
  3413. int length = itemArray.Length;
  3414. itemComboList = new GUIContent[length - 1];
  3415. for (int index = 0; index < length; ++index)
  3416. {
  3417. if (index == 0)
  3418. {
  3419. itemComboList[index] = new GUIContent("アイテム無し");
  3420. }
  3421. else
  3422. {
  3423. switch (itemArray[index])
  3424. {
  3425. case "handitem,HandItemR_WineGlass_I_.menu":
  3426. itemComboList[index] = new GUIContent(index.ToString() + ":ワイングラス");
  3427. break;
  3428. case "handitem,HandItemR_WineBottle_I_.menu":
  3429. itemComboList[index] = new GUIContent(index.ToString() + ":ワインボトル");
  3430. break;
  3431. case "handitem,handitemr_racket_I_.menu":
  3432. itemComboList[index] = new GUIContent(index.ToString() + ":ラケット");
  3433. break;
  3434. case "handitem,HandItemR_Hataki_I_.menu":
  3435. itemComboList[index] = new GUIContent(index.ToString() + ":ハタキ");
  3436. break;
  3437. case "handitem,HandItemR_Mop_I_.menu":
  3438. itemComboList[index] = new GUIContent(index.ToString() + ":モップ");
  3439. break;
  3440. case "handitem,HandItemR_Houki_I_.menu":
  3441. itemComboList[index] = new GUIContent(index.ToString() + ":ほうき");
  3442. break;
  3443. case "handitem,HandItemR_Zoukin2_I_.menu":
  3444. itemComboList[index] = new GUIContent(index.ToString() + ":雑巾");
  3445. break;
  3446. case "handitem,HandItemR_Chu-B_Lip_I_.menu":
  3447. itemComboList[index] = new GUIContent(index.ToString() + ":Chu-B Lip");
  3448. break;
  3449. case "handitem,HandItemR_Mimikaki_I_.menu":
  3450. itemComboList[index] = new GUIContent(index.ToString() + ":耳かき");
  3451. break;
  3452. case "handitem,HandItemR_Pen_I_.menu":
  3453. itemComboList[index] = new GUIContent(index.ToString() + ":ペン");
  3454. break;
  3455. case "handitem,HandItemR_Otama_I_.menu":
  3456. itemComboList[index] = new GUIContent(index.ToString() + ":おたま");
  3457. break;
  3458. case "handitem,HandItemR_Houchou_I_.menu":
  3459. itemComboList[index] = new GUIContent(index.ToString() + ":包丁");
  3460. break;
  3461. case "handitem,HandItemR_Book_I_.menu":
  3462. itemComboList[index] = new GUIContent(index.ToString() + ":本");
  3463. break;
  3464. case "handitem,HandItemR_Puff_I_.menu":
  3465. itemComboList[index] = new GUIContent(index.ToString() + ":パフ");
  3466. break;
  3467. case "handitem,HandItemR_Rip_I_.menu":
  3468. itemComboList[index] = new GUIContent(index.ToString() + ":リップ");
  3469. break;
  3470. case "handitem,HandItemD_Shisyuu_Hari_I_.menu":
  3471. itemComboList[index] = new GUIContent(index.ToString() + ":刺繍");
  3472. break;
  3473. case "handitem,HandItemD_Sara_Sponge_I_.menu":
  3474. itemComboList[index] = new GUIContent(index.ToString() + ":皿・スポンジ");
  3475. break;
  3476. case "kousoku_upper,KousokuU_TekaseOne_I_.menu":
  3477. itemComboList[index] = new GUIContent(index.ToString() + ":手枷1");
  3478. break;
  3479. case "kousoku_upper,KousokuU_TekaseTwo_I_.menu":
  3480. itemComboList[index] = new GUIContent(index.ToString() + ":手枷2");
  3481. break;
  3482. case "kousoku_lower,KousokuL_AshikaseUp_I_.menu":
  3483. itemComboList[index] = new GUIContent(index.ToString() + ":足枷");
  3484. break;
  3485. case "handitem,HandItemR_Usuba_Houchou_I_.menu":
  3486. itemComboList[index] = new GUIContent(index.ToString() + "薄刃包丁");
  3487. break;
  3488. case "handitem,HandItemR_Chusyaki_I_.menu":
  3489. itemComboList[index] = new GUIContent(index.ToString() + "注射器");
  3490. break;
  3491. case "handitem,HandItemR_Nei_Heartful_I_.menu":
  3492. itemComboList[index] = new GUIContent(index.ToString() + "ハートフルねい人形");
  3493. break;
  3494. case "handitem,HandItemR_Shaker_I_.menu":
  3495. itemComboList[index] = new GUIContent(index.ToString() + "シェイカー");
  3496. break;
  3497. case "handitem,HandItemR_SmartPhone_I_.menu":
  3498. itemComboList[index] = new GUIContent(index.ToString() + "スマートフォン");
  3499. break;
  3500. case "kousoku_upper,KousokuU_Ushirode_I_.menu":
  3501. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":後ろ手拘束具");
  3502. break;
  3503. case "kousoku_upper,KousokuU_SMRoom_Haritsuke_I_.menu":
  3504. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":磔台・手枷足枷");
  3505. break;
  3506. case "kousoku_upper,KousokuU_SMRoom2_Haritsuke_I_.menu":
  3507. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":磔台・手枷足枷2");
  3508. break;
  3509. case "handitem,HandItemL_Dance_Hataki_I_.menu":
  3510. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ダンスハタキ");
  3511. break;
  3512. case "handitem,HandItemL_Dance_Mop_I_.menu":
  3513. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ダンスモップ");
  3514. break;
  3515. case "handitem,HandItemL_Dance_Zoukin_I_.menu":
  3516. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ダンス雑巾");
  3517. break;
  3518. case "handitem,HandItemL_Kozara_I_.menu":
  3519. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":小皿");
  3520. break;
  3521. case "handitem,HandItemR_Teacup_I_.menu":
  3522. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ティーカップ");
  3523. break;
  3524. case "handitem,HandItemL_Teasaucer_I_.menu":
  3525. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ティーソーサー");
  3526. break;
  3527. case "handitem,HandItemR_Wholecake_I_.menu":
  3528. itemComboList[index - 1] = new GUIContent("ホールケーキ");
  3529. break;
  3530. case "handitem,HandItemR_Menu_I_.menu":
  3531. itemComboList[index - 1] = new GUIContent("メニュー表");
  3532. break;
  3533. case "handitem,HandItemR_Vibe_I_.menu":
  3534. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":バイブ");
  3535. break;
  3536. case "handitem,HandItemR_VibePink_I_.menu":
  3537. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":ピンクバイブ");
  3538. break;
  3539. case "handitem,HandItemR_VibeBig_I_.menu":
  3540. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":太バイブ");
  3541. break;
  3542. case "handitem,HandItemR_AnalVibe_I_.menu":
  3543. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":アナルバイブ");
  3544. break;
  3545. case "handitem,HandItemH_SoutouVibe_I_.menu":
  3546. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":前:双頭バイブ");
  3547. break;
  3548. case "accvag,accVag_Vibe_I_.menu":
  3549. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":前:バイブ");
  3550. break;
  3551. case "accvag,accVag_VibeBig_I_.menu":
  3552. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":前:太バイブ");
  3553. break;
  3554. case "accvag,accVag_VibePink_I_.menu":
  3555. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":前:ピンクバイブ");
  3556. break;
  3557. case "accanl,accAnl_AnalVibe_I_.menu":
  3558. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":後:アナルバイブ");
  3559. break;
  3560. case "accanl,accAnl_Photo_NomalVibe_I_.menu":
  3561. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":後:バイブ");
  3562. break;
  3563. case "accanl,accAnl_Photo_VibeBig_I_.menu":
  3564. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":後:太バイブ");
  3565. break;
  3566. case "accanl,accAnl_Photo_VibePink_I_.menu":
  3567. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":後:ピンクバイブ");
  3568. break;
  3569. case "handitem,HandItemL_Etoile_Saucer_I_.menu":
  3570. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + "ティーソーサー");
  3571. break;
  3572. case "handitem,HandItemR_Etoile_Teacup_I_.menu":
  3573. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + "ティーカップ");
  3574. break;
  3575. case "handitem,HandItemL_Katuramuki_Daikon_I_.menu":
  3576. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + "桂むき大根");
  3577. break;
  3578. case "handitem,HandItemL_Karte_I_.menu":
  3579. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + "カルテ");
  3580. break;
  3581. case "handitem,HandItemL_Cracker_I_.menu":
  3582. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + "クラッカー");
  3583. break;
  3584. }
  3585. if (index == 12)
  3586. {
  3587. itemComboList[index] = new GUIContent(index.ToString() + ":手枷・足枷");
  3588. }
  3589. if (index == 13)
  3590. {
  3591. itemComboList[index] = new GUIContent(index.ToString() + ":手枷・足枷(下)");
  3592. }
  3593. if (index == 24)
  3594. {
  3595. itemComboList[index - 1] = new GUIContent((index - 1).ToString() + ":カップ&ソーサー");
  3596. }
  3597. }
  3598. }
  3599. }
  3600. if (poseCombo.isClickedComboButton)
  3601. {
  3602. GUI.enabled = false;
  3603. }
  3604. if (poseGroupCombo.isClickedComboButton)
  3605. {
  3606. GUI.enabled = false;
  3607. }
  3608. if (sceneLevel == 3 || sceneLevel == 5 || isF6)
  3609. {
  3610. if (!isF6)
  3611. {
  3612. bool flag = true;
  3613. if (faceFlg || poseFlg || sceneFlg || kankyoFlg || kankyo2Flg)
  3614. {
  3615. flag = false;
  3616. }
  3617. if (GUI.Toggle(new Rect(GetPix(2),
  3618. GetPix(2),
  3619. GetPix(39),
  3620. GetPix(20)),
  3621. flag,
  3622. "配置",
  3623. style4))
  3624. {
  3625. faceFlg = false;
  3626. poseFlg = false;
  3627. sceneFlg = false;
  3628. kankyoFlg = false;
  3629. kankyo2Flg = false;
  3630. bGui = true;
  3631. }
  3632. }
  3633. if (!yotogiFlg && GUI.Toggle(new Rect(GetPix(41),
  3634. GetPix(2),
  3635. GetPix(39),
  3636. GetPix(20)),
  3637. poseFlg,
  3638. "操作",
  3639. style4))
  3640. {
  3641. poseFlg = true;
  3642. faceFlg = false;
  3643. sceneFlg = false;
  3644. kankyoFlg = false;
  3645. kankyo2Flg = false;
  3646. }
  3647. if (GUI.Toggle(new Rect(GetPix(80), GetPix(2), GetPix(39), GetPix(20)),
  3648. faceFlg,
  3649. "表情",
  3650. style4))
  3651. {
  3652. faceFlg = true;
  3653. poseFlg = false;
  3654. sceneFlg = false;
  3655. kankyoFlg = false;
  3656. kankyo2Flg = false;
  3657. if (!faceFlg2)
  3658. {
  3659. isFaceInit = true;
  3660. faceFlg2 = true;
  3661. maidArray[selectMaidIndex].boMabataki = false;
  3662. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  3663. }
  3664. isFaceInit = true;
  3665. }
  3666. if (GUI.Toggle(new Rect(GetPix(119), GetPix(2), GetPix(39), GetPix(20)),
  3667. kankyoFlg,
  3668. "環境",
  3669. style4))
  3670. {
  3671. poseFlg = false;
  3672. faceFlg = false;
  3673. sceneFlg = false;
  3674. kankyoFlg = true;
  3675. kankyo2Flg = false;
  3676. }
  3677. if (!line1)
  3678. {
  3679. line1 = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.3f));
  3680. line2 = MakeTex(2, 2, new Color(0.7f, 0.7f, 0.7f, 0.6f));
  3681. }
  3682. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 2f), line1);
  3683. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 1f), line2);
  3684. style1.fontSize = GetPix(13);
  3685. style1.alignment = TextAnchor.MiddleCenter;
  3686. GUI.Label(new Rect(GetPix(125), GetPix(25), GetPix(40), GetPix(25)),
  3687. string.Concat(selectMaidIndex + 1),
  3688. style1);
  3689. style1.fontSize = GetPix(11);
  3690. style1.alignment = TextAnchor.UpperLeft;
  3691. }
  3692. if (sceneLevel > 0)
  3693. {
  3694. int selectMaidIndex = this.selectMaidIndex;
  3695. if (sceneLevel == 3 || sceneLevel == 5 && (isF7 || maidCnt > 1))
  3696. {
  3697. if (GUI.Button(new Rect(GetPix(5),
  3698. GetPix(53),
  3699. GetPix(23),
  3700. GetPix(32)),
  3701. "<",
  3702. style3))
  3703. {
  3704. --this.selectMaidIndex;
  3705. if (this.selectMaidIndex < 0)
  3706. {
  3707. this.selectMaidIndex = selectList.Count - 1;
  3708. }
  3709. isPoseInit = true;
  3710. poseFlg = true;
  3711. copyIndex = 0;
  3712. poseCombo.selectedItemIndex = poseIndex[this.selectMaidIndex];
  3713. faceCombo.selectedItemIndex = faceIndex[this.selectMaidIndex];
  3714. }
  3715. if (GUI.Button(new Rect(GetPix(135),
  3716. GetPix(53),
  3717. GetPix(23),
  3718. GetPix(32)),
  3719. ">",
  3720. style3))
  3721. {
  3722. ++this.selectMaidIndex;
  3723. if (selectList.Count <= this.selectMaidIndex)
  3724. {
  3725. this.selectMaidIndex = 0;
  3726. }
  3727. isPoseInit = true;
  3728. poseFlg = true;
  3729. copyIndex = 0;
  3730. poseCombo.selectedItemIndex = poseIndex[this.selectMaidIndex];
  3731. faceCombo.selectedItemIndex = faceIndex[this.selectMaidIndex];
  3732. }
  3733. }
  3734. if (maidArray[this.selectMaidIndex].GetThumIcon())
  3735. {
  3736. GUI.DrawTexture(new Rect(GetPix(30),
  3737. GetPix(25),
  3738. GetPix(60),
  3739. GetPix(60)),
  3740. maidArray[this.selectMaidIndex].GetThumIcon());
  3741. }
  3742. GUI.Label(new Rect(GetPix(90), GetPix(50), GetPix(140), GetPix(210)),
  3743. maidArray[this.selectMaidIndex].status.lastName + "\n" + maidArray[this.selectMaidIndex].status.firstName,
  3744. style1);
  3745. }
  3746. if (!isF6)
  3747. {
  3748. if (isDanceStop)
  3749. {
  3750. isStop[selectMaidIndex] = true;
  3751. isDanceStop = false;
  3752. }
  3753. if (sceneLevel == 5 && maidCnt > 1)
  3754. {
  3755. bool flag = false;
  3756. if (selectMaidIndex == isEditNo)
  3757. {
  3758. flag = true;
  3759. }
  3760. isEdit[selectMaidIndex] =
  3761. GUI.Toggle(new Rect(GetPix(5),
  3762. GetPix(25),
  3763. GetPix(50),
  3764. GetPix(16)),
  3765. flag,
  3766. "Edit",
  3767. style4);
  3768. if (isEdit[selectMaidIndex] && selectMaidIndex != isEditNo)
  3769. {
  3770. isEditNo = selectMaidIndex;
  3771. for (int index = 0; index < maidCnt; ++index)
  3772. {
  3773. if (index != isEditNo)
  3774. {
  3775. isEdit[index] = false;
  3776. }
  3777. }
  3778. SceneEdit component = GameObject.Find("__SceneEdit__").GetComponent<SceneEdit>();
  3779. SetFieldValue<SceneEdit, Maid>(component, "m_maid", maidArray[selectMaidIndex]);
  3780. component.PartsTypeCamera(MPN.stkg);
  3781. editSelectMaid = maidArray[selectMaidIndex];
  3782. if (selectList[selectMaidIndex] != null && goSlot[(int)selectList[selectMaidIndex]] != null)
  3783. {
  3784. maidArray[selectMaidIndex].body0.goSlot =
  3785. new List<TBodySkin>(goSlot[(int)selectList[selectMaidIndex]]);
  3786. for (int index = 0; index < bodyHit[(int)selectList[selectMaidIndex]].Count; ++index)
  3787. {
  3788. maidArray[selectMaidIndex].body0.goSlot[index].bonehair.bodyhit =
  3789. bodyHit[(int)selectList[selectMaidIndex]][index];
  3790. }
  3791. }
  3792. }
  3793. }
  3794. GUI.enabled = !poseGroupCombo.isClickedComboButton;
  3795. if (isLock[selectMaidIndex])
  3796. {
  3797. GUI.enabled = false;
  3798. }
  3799. int result;
  3800. Transform transform;
  3801. if (GUI.Button(new Rect(GetPix(5), GetPix(125), GetPix(23), GetPix(23)),
  3802. "<",
  3803. style3))
  3804. {
  3805. --poseIndex[selectMaidIndex];
  3806. if (poseGroupIndex > 0)
  3807. {
  3808. if ((int)groupList[poseGroupIndex - 1] > poseIndex[selectMaidIndex])
  3809. {
  3810. poseIndex[selectMaidIndex] = poseGroupIndex < groupList.Count
  3811. ? (int)groupList[poseGroupIndex] - 1
  3812. : poseArray.Length - 1;
  3813. }
  3814. }
  3815. else if (poseIndex[selectMaidIndex] < 0)
  3816. {
  3817. poseIndex[selectMaidIndex] = (int)groupList[poseGroupIndex] - 1;
  3818. }
  3819. isPoseInit = true;
  3820. poseCombo.selectedItemIndex = poseGroupIndex <= 0
  3821. ? poseIndex[selectMaidIndex]
  3822. : poseIndex[selectMaidIndex] - (int)groupList[poseGroupIndex - 1];
  3823. if (!isLock[selectMaidIndex] && maid && maid.Visible)
  3824. {
  3825. string[] strArray = poseArray[poseIndex[selectMaidIndex]].Split(',');
  3826. isStop[selectMaidIndex] = false;
  3827. poseCount[selectMaidIndex] = 20;
  3828. if (strArray[0].Contains("_momi") || strArray[0].Contains("paizuri_"))
  3829. {
  3830. maid.body0.MuneYureL(0.0f);
  3831. maid.body0.MuneYureR(0.0f);
  3832. }
  3833. else
  3834. {
  3835. maid.body0.MuneYureL(1f);
  3836. maid.body0.MuneYureR(1f);
  3837. }
  3838. if (strArray[0].Contains("MultipleMaidsPose"))
  3839. {
  3840. string path = strArray[0].Split('/')[1];
  3841. byte[] numArray = new byte[0];
  3842. try
  3843. {
  3844. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  3845. {
  3846. numArray = new byte[fileStream.Length];
  3847. fileStream.Read(numArray, 0, numArray.Length);
  3848. }
  3849. }
  3850. catch { }
  3851. if (0 < numArray.Length)
  3852. {
  3853. long hashCode = Path.GetFileName(path).GetHashCode();
  3854. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  3855. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  3856. {
  3857. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL, Maid.AutoTwist.WristR,
  3858. Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  3859. };
  3860. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  3861. {
  3862. maid.SetAutoTwist(f_eType, true);
  3863. }
  3864. }
  3865. }
  3866. else if (strArray[0].StartsWith("p") && int.TryParse(strArray[0].Substring(1), out result))
  3867. {
  3868. loadPose[selectMaidIndex] = strArray[0];
  3869. }
  3870. else if (!strArray[0].StartsWith("dance_"))
  3871. {
  3872. maidArray[selectMaidIndex].CrossFade(strArray[0] + ".anm", false, true, false, 0.0f, 1f);
  3873. }
  3874. else
  3875. {
  3876. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray[0] + ".anm"))
  3877. {
  3878. maid.body0.LoadAnime(strArray[0] + ".anm", GameUty.FileSystem, strArray[0] + ".anm", false, false);
  3879. }
  3880. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray[0] + ".anm");
  3881. }
  3882. if (strArray.Length > 1)
  3883. {
  3884. maid.body0.m_Bones.GetComponent<Animation>()[strArray[0] + ".anm"].time = float.Parse(strArray[1]);
  3885. isDanceStop = true;
  3886. if (strArray.Length > 2)
  3887. {
  3888. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  3889. isPoseIti[selectMaidIndex] = true;
  3890. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  3891. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  3892. }
  3893. }
  3894. }
  3895. }
  3896. if (GUI.Button(new Rect(GetPix(135),
  3897. GetPix(125),
  3898. GetPix(23),
  3899. GetPix(23)),
  3900. ">",
  3901. style3))
  3902. {
  3903. ++poseIndex[selectMaidIndex];
  3904. if (poseIndex[selectMaidIndex] > (int)groupList[groupList.Count - 1])
  3905. {
  3906. if (poseIndex[selectMaidIndex] >= poseArray.Length)
  3907. {
  3908. poseIndex[selectMaidIndex] = (int)groupList[poseGroupIndex - 1];
  3909. }
  3910. }
  3911. else if (poseIndex[selectMaidIndex] >= (int)groupList[poseGroupIndex])
  3912. {
  3913. poseIndex[selectMaidIndex] = poseGroupIndex <= 0 ? 0 : (int)groupList[poseGroupIndex - 1];
  3914. }
  3915. isPoseInit = true;
  3916. poseCombo.selectedItemIndex = poseGroupIndex <= 0
  3917. ? poseIndex[selectMaidIndex]
  3918. : poseIndex[selectMaidIndex] - (int)groupList[poseGroupIndex - 1];
  3919. if (!isLock[selectMaidIndex] && maid && maid.Visible)
  3920. {
  3921. string[] strArray = poseArray[poseIndex[selectMaidIndex]].Split(',');
  3922. isStop[selectMaidIndex] = false;
  3923. poseCount[selectMaidIndex] = 20;
  3924. if (strArray[0].Contains("_momi") || strArray[0].Contains("paizuri_"))
  3925. {
  3926. maid.body0.MuneYureL(0.0f);
  3927. maid.body0.MuneYureR(0.0f);
  3928. }
  3929. else
  3930. {
  3931. maid.body0.MuneYureL(1f);
  3932. maid.body0.MuneYureR(1f);
  3933. }
  3934. if (strArray[0].Contains("MultipleMaidsPose"))
  3935. {
  3936. string path = strArray[0].Split('/')[1];
  3937. byte[] numArray = new byte[0];
  3938. try
  3939. {
  3940. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  3941. {
  3942. numArray = new byte[fileStream.Length];
  3943. fileStream.Read(numArray, 0, numArray.Length);
  3944. }
  3945. }
  3946. catch { }
  3947. if (0 < numArray.Length)
  3948. {
  3949. long hashCode = Path.GetFileName(path).GetHashCode();
  3950. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  3951. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  3952. {
  3953. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL, Maid.AutoTwist.WristR,
  3954. Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  3955. };
  3956. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  3957. {
  3958. maid.SetAutoTwist(f_eType, true);
  3959. }
  3960. }
  3961. }
  3962. else if (strArray[0].StartsWith("p") && int.TryParse(strArray[0].Substring(1), out result))
  3963. {
  3964. loadPose[selectMaidIndex] = strArray[0];
  3965. }
  3966. else if (!strArray[0].StartsWith("dance_"))
  3967. {
  3968. maidArray[selectMaidIndex].CrossFade(strArray[0] + ".anm", false, true, false, 0.0f, 1f);
  3969. }
  3970. else
  3971. {
  3972. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray[0] + ".anm"))
  3973. {
  3974. maid.body0.LoadAnime(strArray[0] + ".anm", GameUty.FileSystem, strArray[0] + ".anm", false, false);
  3975. }
  3976. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray[0] + ".anm");
  3977. }
  3978. if (strArray.Length > 1)
  3979. {
  3980. maid.body0.m_Bones.GetComponent<Animation>()[strArray[0] + ".anm"].time = float.Parse(strArray[1]);
  3981. isDanceStop = true;
  3982. if (strArray.Length > 2)
  3983. {
  3984. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  3985. isPoseIti[selectMaidIndex] = true;
  3986. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  3987. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  3988. }
  3989. }
  3990. }
  3991. }
  3992. GUI.enabled = true;
  3993. int index1 = -1;
  3994. for (int index2 = 0; index2 < groupList.Count; ++index2)
  3995. {
  3996. if (poseIndex[selectMaidIndex] < (int)groupList[index2])
  3997. {
  3998. index1 = index2;
  3999. break;
  4000. }
  4001. }
  4002. int length1 = (int)groupList[0];
  4003. int num1 = 0;
  4004. if (index1 > 0)
  4005. {
  4006. length1 = (int)groupList[index1] - (int)groupList[index1 - 1];
  4007. num1 = (int)groupList[index1 - 1];
  4008. }
  4009. if (index1 < 0)
  4010. {
  4011. index1 = groupList.Count;
  4012. length1 = poseArray.Length - (int)groupList[index1 - 1];
  4013. num1 = (int)groupList[index1 - 1];
  4014. }
  4015. if (poseGroupCombo.selectedItemIndex != index1)
  4016. {
  4017. poseComboList = new GUIContent[length1];
  4018. int index2 = 0;
  4019. for (int index3 = num1; index3 < num1 + length1; ++index3)
  4020. {
  4021. bool flag = false;
  4022. foreach (IniKey key in Preferences["pose"].Keys)
  4023. {
  4024. if (poseArray[index3] == key.Key)
  4025. {
  4026. IniKey iniKey = Preferences["pose"][key.Key];
  4027. if (iniKey.Value != null && iniKey.Value.ToString() != "" && iniKey.Value.ToString() != "del")
  4028. {
  4029. poseComboList[index2] =
  4030. new GUIContent((index2 + 1).ToString() + ":" + iniKey.Value.Split('_')[0]
  4031. + "                    " + key.Key);
  4032. flag = true;
  4033. }
  4034. }
  4035. }
  4036. if (!flag)
  4037. {
  4038. poseComboList[index2] = new GUIContent((index2 + 1).ToString() + ":" + poseArray[index3]);
  4039. }
  4040. ++index2;
  4041. }
  4042. poseGroupCombo.selectedItemIndex = index1;
  4043. poseGroupIndex = index1;
  4044. poseCombo.selectedItemIndex = 0;
  4045. }
  4046. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton;
  4047. isLook[selectMaidIndex] =
  4048. GUI.Toggle(new Rect(GetPix(8),
  4049. GetPix(155),
  4050. GetPix(65),
  4051. GetPix(16)),
  4052. isLook[selectMaidIndex],
  4053. "顔の向き",
  4054. style4);
  4055. isPoseEdit = GUI.Toggle(new Rect(GetPix(86),
  4056. GetPix(155),
  4057. GetPix(90),
  4058. GetPix(16)),
  4059. isPoseEdit,
  4060. "ポーズ登録",
  4061. style4);
  4062. if (isPoseEdit)
  4063. {
  4064. inName3 = GUI.TextField(new Rect(GetPix(5),
  4065. GetPix(180),
  4066. GetPix(100),
  4067. GetPix(20)),
  4068. inName3);
  4069. if (GUI.Button(new Rect(GetPix(107),
  4070. GetPix(180),
  4071. GetPix(35),
  4072. GetPix(20)),
  4073. "追加",
  4074. style3))
  4075. {
  4076. isSavePose = true;
  4077. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  4078. existPose = true;
  4079. GUI.FocusControl("");
  4080. }
  4081. if (poseGroupComboList[poseGroupCombo.selectedItemIndex].text != "99:登録ポーズ")
  4082. {
  4083. GUI.enabled = false;
  4084. }
  4085. if (GUI.Button(new Rect(GetPix(144),
  4086. GetPix(180),
  4087. GetPix(24),
  4088. GetPix(20)),
  4089. "削",
  4090. style3))
  4091. {
  4092. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  4093. List<string> stringList1 = new List<string>();
  4094. stringList1.AddRange(poseArray);
  4095. if (poseComboList[poseCombo.selectedItemIndex].text.Contains("MultipleMaidsPose"))
  4096. {
  4097. string pose = poseArray[poseIndex[selectMaidIndex]];
  4098. stringList1.Remove(pose);
  4099. string path = poseArray[poseIndex[selectMaidIndex]].Split('/')[1].Replace("                    ", "");
  4100. if (File.Exists(path))
  4101. {
  4102. File.Delete(path);
  4103. }
  4104. }
  4105. else
  4106. {
  4107. string[] strArray = poseComboList[poseCombo.selectedItemIndex].text.Split('p');
  4108. string str = strArray[strArray.Length - 1];
  4109. IniKey iniKey = Preferences["pose"]["p" + str];
  4110. if (iniKey.Value != "" || iniKey.Value != "del")
  4111. {
  4112. Preferences["pose"]["p" + str].Value = "del";
  4113. SaveConfig();
  4114. }
  4115. stringList1.Remove("p" + str);
  4116. }
  4117. GUI.FocusControl("");
  4118. poseArray = stringList1.ToArray();
  4119. int index2 = -1;
  4120. for (int index3 = 0; index3 < groupList.Count; ++index3)
  4121. {
  4122. if (poseIndex[selectMaidIndex] < (int)groupList[index3])
  4123. {
  4124. index2 = index3;
  4125. break;
  4126. }
  4127. }
  4128. int length2 = (int)groupList[0];
  4129. int num2 = 0;
  4130. if (index2 > 0)
  4131. {
  4132. length2 = (int)groupList[index2] - (int)groupList[index2 - 1];
  4133. num2 = (int)groupList[index2 - 1];
  4134. }
  4135. if (index2 < 0)
  4136. {
  4137. index2 = groupList.Count;
  4138. length2 = poseArray.Length - (int)groupList[index2 - 1];
  4139. num2 = (int)groupList[index2 - 1];
  4140. }
  4141. poseComboList = new GUIContent[length2];
  4142. int index4 = 0;
  4143. bool existEdit = false;
  4144. for (int index3 = num2; index3 < num2 + length2; ++index3)
  4145. {
  4146. bool flag = false;
  4147. foreach (IniKey key in Preferences["pose"].Keys)
  4148. {
  4149. if (poseArray[index3] == key.Key)
  4150. {
  4151. IniKey iniKey = Preferences["pose"][key.Key];
  4152. if (iniKey.Value != null && iniKey.Value.ToString() != "" && iniKey.Value.ToString() != "del")
  4153. {
  4154. poseComboList[index4] =
  4155. new GUIContent((index4 + 1).ToString() + ":" + iniKey.Value.Split('_')[0]
  4156. + "                    " + key.Key);
  4157. flag = true;
  4158. existEdit = true;
  4159. }
  4160. }
  4161. }
  4162. if (!flag)
  4163. {
  4164. poseComboList[index4] = new GUIContent((index4 + 1).ToString() + ":" + poseArray[index3]);
  4165. }
  4166. ++index4;
  4167. }
  4168. ((Action<string, List<string>>)((path, result_list) =>
  4169. {
  4170. string[] files = Directory.GetFiles(path);
  4171. countS = 0;
  4172. for (int index = 0; index < files.Length; ++index)
  4173. {
  4174. if (Path.GetExtension(files[index]) == ".anm")
  4175. {
  4176. existEdit = true;
  4177. break;
  4178. }
  4179. }
  4180. }))(Path.GetFullPath(".\\") + "Mod\\MultipleMaidsPose", new List<string>());
  4181. if (!existEdit)
  4182. {
  4183. poseIniStr = "";
  4184. List<string> stringList2 = new List<string>(50 + poseGroupArray2.Length);
  4185. stringList2.AddRange(poseGroupArray2);
  4186. stringList2.AddRange(poseGroupArrayVP);
  4187. stringList2.AddRange(poseGroupArrayFB);
  4188. stringList2.AddRange(poseGroupArray3);
  4189. stringList2.Add(poseArray5[0]);
  4190. stringList2.Add(poseArray6[0]);
  4191. stringList2.Add(strList2[0]);
  4192. stringList2.Add(strListE2[0]);
  4193. existPose = false;
  4194. poseGroupArray = stringList2.ToArray();
  4195. groupList = new ArrayList();
  4196. for (int index3 = 0; index3 < poseArray.Length; ++index3)
  4197. {
  4198. for (int index5 = 0; index5 < poseGroupArray.Length; ++index5)
  4199. {
  4200. if (poseGroupArray[index5] == poseArray[index3])
  4201. {
  4202. groupList.Add(index3);
  4203. if (poseGroupArray[index5] == strList2[0])
  4204. {
  4205. sPoseCount = index3;
  4206. }
  4207. }
  4208. }
  4209. }
  4210. poseIndex[selectMaidIndex] = 0;
  4211. poseGroupComboList = new GUIContent[poseGroupArray.Length + 1];
  4212. poseGroupComboList[0] = new GUIContent("1:通常");
  4213. for (int index3 = 0; index3 < poseGroupArray.Length; ++index3)
  4214. {
  4215. if (poseGroupArray[index3] == "maid_dressroom01")
  4216. {
  4217. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":立ち");
  4218. }
  4219. if (poseGroupArray[index3] == "tennis_kamae_f")
  4220. {
  4221. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":中腰");
  4222. }
  4223. if (poseGroupArray[index3] == "senakanagasi_f")
  4224. {
  4225. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":膝をつく");
  4226. }
  4227. if (poseGroupArray[index3] == "work_hansei")
  4228. {
  4229. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":座り");
  4230. }
  4231. if (poseGroupArray[index3] == "inu_taiki_f")
  4232. {
  4233. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":四つん這い");
  4234. }
  4235. if (poseGroupArray[index3] == "syagami_pose_f")
  4236. {
  4237. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":床座り");
  4238. }
  4239. if (poseGroupArray[index3] == "densyasuwari_taiki_f")
  4240. {
  4241. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":椅子座り");
  4242. }
  4243. if (poseGroupArray[index3] == "work_kaiwa")
  4244. {
  4245. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":ソファー座り");
  4246. }
  4247. if (poseGroupArray[index3] == "dance_cm3d2_001_f1,14.14")
  4248. {
  4249. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":ドキドキ☆Fallin' Love");
  4250. }
  4251. if (poseGroupArray[index3] == "dance_cm3d_001_f1,39.25")
  4252. {
  4253. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":entrance to you");
  4254. }
  4255. if (poseGroupArray[index3] == "dance_cm3d_002_end_f1,50.71")
  4256. {
  4257. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":scarlet leap");
  4258. }
  4259. if (poseGroupArray[index3] == "dance_cm3d2_002_smt_f,7.76,")
  4260. {
  4261. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":stellar my tears");
  4262. }
  4263. if (poseGroupArray[index3] == "dance_cm3d_003_sp2_f1,90.15")
  4264. {
  4265. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":rhythmix to you");
  4266. }
  4267. if (poseGroupArray[index3] == "dance_cm3d2_003_hs_f1,0.01,")
  4268. {
  4269. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":happy!happy!スキャンダル!!");
  4270. }
  4271. if (poseGroupArray[index3] == "dance_cm3d_004_kano_f1,124.93")
  4272. {
  4273. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":Can Know Two Close");
  4274. }
  4275. if (poseGroupArray[index3] == "dance_cm3d2_004_sse_f1,0.01")
  4276. {
  4277. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":sweet sweet everyday");
  4278. }
  4279. if (poseGroupArray[index3] == "turusi_sex_in_taiki_f")
  4280. {
  4281. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":拘束");
  4282. }
  4283. if (poseGroupArray[index3] == "rosyutu_pose01_f")
  4284. {
  4285. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":エロ");
  4286. }
  4287. if (poseGroupArray[index3] == "rosyutu_aruki_f_once_,1.37")
  4288. {
  4289. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":歩き");
  4290. }
  4291. if (poseGroupArray[index3] == "stand_desk1")
  4292. {
  4293. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":その他");
  4294. }
  4295. if (poseGroupArray[index3] == poseArray5[0])
  4296. {
  4297. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":ダンスMC");
  4298. }
  4299. if (poseGroupArray[index3] == poseArray6[0])
  4300. {
  4301. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":ダンス");
  4302. }
  4303. if (index3 == poseGroupArray.Length - 2)
  4304. {
  4305. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":通常2");
  4306. }
  4307. if (index3 == poseGroupArray.Length - 1)
  4308. {
  4309. poseGroupComboList[index3 + 1] = new GUIContent((index3 + 2).ToString() + ":エロ2");
  4310. }
  4311. }
  4312. }
  4313. else
  4314. {
  4315. poseGroupCombo.selectedItemIndex = index2;
  4316. poseGroupIndex = index2;
  4317. poseCombo.selectedItemIndex = 0;
  4318. poseIndex[selectMaidIndex] = (int)groupList[groupList.Count - 1];
  4319. if (poseArray.Length <= poseIndex[selectMaidIndex])
  4320. {
  4321. --poseIndex[selectMaidIndex];
  4322. }
  4323. }
  4324. }
  4325. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton;
  4326. }
  4327. else
  4328. {
  4329. if (!isLook[selectMaidIndex])
  4330. {
  4331. GUI.enabled = false;
  4332. }
  4333. GUI.Label(new Rect(GetPix(8), GetPix(175), GetPix(100), GetPix(25)),
  4334. "顔の向きX",
  4335. style2);
  4336. lookX[selectMaidIndex] =
  4337. GUI.HorizontalSlider(new Rect(GetPix(8),
  4338. GetPix(191),
  4339. GetPix(70),
  4340. GetPix(20)),
  4341. lookX[selectMaidIndex],
  4342. -0.6f,
  4343. 0.6f);
  4344. GUI.Label(new Rect(GetPix(88),
  4345. GetPix(175),
  4346. GetPix(100),
  4347. GetPix(25)),
  4348. "顔の向きY",
  4349. style2);
  4350. lookY[selectMaidIndex] =
  4351. GUI.HorizontalSlider(new Rect(GetPix(88),
  4352. GetPix(191),
  4353. GetPix(70),
  4354. GetPix(20)),
  4355. lookY[selectMaidIndex],
  4356. 0.5f,
  4357. -0.55f);
  4358. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton;
  4359. }
  4360. int index6 = poseGroupIndex <= 0
  4361. ? poseIndex[selectMaidIndex]
  4362. : poseIndex[selectMaidIndex] - (int)groupList[poseGroupIndex - 1];
  4363. string[] strArray1;
  4364. if (GUI.Button(new Rect(GetPix(5), GetPix(215), GetPix(23), GetPix(23)),
  4365. "<",
  4366. style3))
  4367. {
  4368. --itemIndex[selectMaidIndex];
  4369. if (itemIndex[selectMaidIndex] <= -1)
  4370. {
  4371. itemIndex[selectMaidIndex] = itemArray.Length - 2;
  4372. }
  4373. strArray1 = new string[2];
  4374. string[] strArray2 = itemArray[itemIndex[selectMaidIndex]].Split(',');
  4375. if (itemIndex[selectMaidIndex] > 13)
  4376. {
  4377. strArray2 = itemArray[itemIndex[selectMaidIndex] + 1].Split(',');
  4378. }
  4379. maid.DelProp(MPN.handitem, true);
  4380. maid.DelProp(MPN.accvag, true);
  4381. maid.DelProp(MPN.accanl, true);
  4382. bool flag = false;
  4383. if (itemIndex[selectMaidIndex] == 12 || itemIndex[selectMaidIndex] == 13 || itemIndex[selectMaidIndex] == 23)
  4384. {
  4385. flag = true;
  4386. }
  4387. if (!flag)
  4388. {
  4389. maid.DelProp(MPN.kousoku_upper, true);
  4390. maid.DelProp(MPN.kousoku_lower, true);
  4391. }
  4392. if (strArray2[0] != "")
  4393. {
  4394. maid.SetProp(strArray2[0], strArray2[1], 0, true, false);
  4395. }
  4396. if (itemIndex[selectMaidIndex] == 12)
  4397. {
  4398. string[] strArray3 = itemArray[itemIndex[selectMaidIndex] - 1].Split(',');
  4399. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4400. }
  4401. if (itemIndex[selectMaidIndex] == 13)
  4402. {
  4403. string[] strArray3 = itemArray[itemIndex[selectMaidIndex] + 1].Split(',');
  4404. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4405. }
  4406. if (itemIndex[selectMaidIndex] == 23)
  4407. {
  4408. string[] strArray3 = itemArray[itemIndex[selectMaidIndex]].Split(',');
  4409. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4410. cafeFlg[selectMaidIndex] = true;
  4411. }
  4412. maid.AllProcPropSeqStart();
  4413. itemCombo.selectedItemIndex = itemIndex[selectMaidIndex];
  4414. }
  4415. if (GUI.Button(new Rect(GetPix(135),
  4416. GetPix(215),
  4417. GetPix(23),
  4418. GetPix(23)),
  4419. ">",
  4420. style3))
  4421. {
  4422. ++itemIndex[selectMaidIndex];
  4423. if (itemIndex[selectMaidIndex] >= itemArray.Length - 1)
  4424. {
  4425. itemIndex[selectMaidIndex] = 0;
  4426. }
  4427. strArray1 = new string[2];
  4428. string[] strArray2 = itemArray[itemIndex[selectMaidIndex]].Split(',');
  4429. if (itemIndex[selectMaidIndex] > 13)
  4430. {
  4431. strArray2 = itemArray[itemIndex[selectMaidIndex] + 1].Split(',');
  4432. }
  4433. maid.DelProp(MPN.handitem, true);
  4434. maid.DelProp(MPN.accvag, true);
  4435. maid.DelProp(MPN.accanl, true);
  4436. bool flag = false;
  4437. if (itemIndex[selectMaidIndex] == 12 || itemIndex[selectMaidIndex] == 13)
  4438. {
  4439. flag = true;
  4440. }
  4441. if (!flag)
  4442. {
  4443. maid.DelProp(MPN.kousoku_upper, true);
  4444. maid.DelProp(MPN.kousoku_lower, true);
  4445. }
  4446. if (strArray2[0] != "")
  4447. {
  4448. maid.SetProp(strArray2[0], strArray2[1], 0, true, false);
  4449. }
  4450. if (itemIndex[selectMaidIndex] == 12)
  4451. {
  4452. string[] strArray3 = itemArray[itemIndex[selectMaidIndex] - 1].Split(',');
  4453. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4454. }
  4455. if (itemIndex[selectMaidIndex] == 13)
  4456. {
  4457. string[] strArray3 = itemArray[itemIndex[selectMaidIndex] + 1].Split(',');
  4458. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4459. }
  4460. if (itemIndex[selectMaidIndex] == 23)
  4461. {
  4462. string[] strArray3 = itemArray[itemIndex[selectMaidIndex]].Split(',');
  4463. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  4464. cafeFlg[selectMaidIndex] = true;
  4465. }
  4466. maid.AllProcPropSeqStart();
  4467. itemCombo.selectedItemIndex = itemIndex[selectMaidIndex];
  4468. }
  4469. if (itemCombo.isClickedComboButton)
  4470. {
  4471. GUI.enabled = false;
  4472. }
  4473. int offsetTop = GetPix(240);
  4474. int UIHeight = GetPix(330);
  4475. Rect poseWindowScrollRect = new Rect(0, offsetTop, rectWin.width, rectWin.height - offsetTop);
  4476. Rect poseWindowScrollView = new Rect(0, offsetTop, rectWin.width - 20, UIHeight);
  4477. poseScrollPos = GUI.BeginScrollView(poseWindowScrollRect, poseScrollPos, poseWindowScrollView);
  4478. isWear = GUI.Toggle(new Rect(GetPix(5),
  4479. GetPix(248),
  4480. GetPix(70),
  4481. GetPix(20)),
  4482. isWear,
  4483. "トップス",
  4484. style4);
  4485. isSkirt = GUI.Toggle(new Rect(GetPix(90),
  4486. GetPix(248),
  4487. GetPix(70),
  4488. GetPix(20)),
  4489. isSkirt,
  4490. "ボトムス",
  4491. style4);
  4492. isBra = GUI.Toggle(new Rect(GetPix(5),
  4493. GetPix(273),
  4494. GetPix(80),
  4495. GetPix(20)),
  4496. isBra,
  4497. "ブラジャー",
  4498. style4);
  4499. isPanz = GUI.Toggle(new Rect(GetPix(90),
  4500. GetPix(273),
  4501. GetPix(60),
  4502. GetPix(20)),
  4503. isPanz,
  4504. "パンツ",
  4505. style4);
  4506. isHeadset = GUI.Toggle(new Rect(GetPix(5),
  4507. GetPix(298),
  4508. GetPix(70),
  4509. GetPix(20)),
  4510. isHeadset,
  4511. "ヘッド",
  4512. style4);
  4513. isMegane = GUI.Toggle(new Rect(GetPix(95),
  4514. GetPix(298),
  4515. GetPix(70),
  4516. GetPix(20)),
  4517. isMegane,
  4518. "メガネ",
  4519. style4);
  4520. isAccUde = GUI.Toggle(new Rect(GetPix(5),
  4521. GetPix(323),
  4522. GetPix(40),
  4523. GetPix(20)),
  4524. isAccUde,
  4525. "腕",
  4526. style4);
  4527. isGlove = GUI.Toggle(new Rect(GetPix(50),
  4528. GetPix(323),
  4529. GetPix(40),
  4530. GetPix(20)),
  4531. isGlove,
  4532. "手袋",
  4533. style4);
  4534. isAccSenaka = GUI.Toggle(new Rect(GetPix(95),
  4535. GetPix(323),
  4536. GetPix(40),
  4537. GetPix(20)),
  4538. isAccSenaka,
  4539. "背中",
  4540. style4);
  4541. isStkg = GUI.Toggle(new Rect(GetPix(5),
  4542. GetPix(348),
  4543. GetPix(40),
  4544. GetPix(20)),
  4545. isStkg,
  4546. "靴下",
  4547. style4);
  4548. isShoes = GUI.Toggle(new Rect(GetPix(50),
  4549. GetPix(348),
  4550. GetPix(40),
  4551. GetPix(20)),
  4552. isShoes,
  4553. "靴",
  4554. style4);
  4555. isMaid = GUI.Toggle(new Rect(GetPix(95),
  4556. GetPix(348),
  4557. GetPix(70),
  4558. GetPix(20)),
  4559. isMaid,
  4560. "メイド",
  4561. style4);
  4562. mekure1[selectMaidIndex] =
  4563. GUI.Toggle(new Rect(GetPix(5),
  4564. GetPix(373),
  4565. GetPix(62),
  4566. GetPix(20)),
  4567. mekure1[selectMaidIndex],
  4568. "めくれ前",
  4569. style4);
  4570. mekure2[selectMaidIndex] =
  4571. GUI.Toggle(new Rect(GetPix(67),
  4572. GetPix(373),
  4573. GetPix(40),
  4574. GetPix(20)),
  4575. mekure2[selectMaidIndex],
  4576. "後ろ",
  4577. style4);
  4578. zurasi[selectMaidIndex] =
  4579. GUI.Toggle(new Rect(GetPix(105),
  4580. GetPix(373),
  4581. GetPix(50),
  4582. GetPix(20)),
  4583. zurasi[selectMaidIndex],
  4584. "ずらし",
  4585. style4);
  4586. voice1[selectMaidIndex] =
  4587. GUI.Toggle(new Rect(GetPix(5),
  4588. GetPix(530),
  4589. GetPix(70),
  4590. GetPix(20)),
  4591. zFlg[selectMaidIndex],
  4592. "ボイス",
  4593. style4);
  4594. voice2[selectMaidIndex] =
  4595. GUI.Toggle(new Rect(GetPix(70),
  4596. GetPix(530),
  4597. GetPix(70),
  4598. GetPix(20)),
  4599. xFlg[selectMaidIndex],
  4600. "Hボイス",
  4601. style4);
  4602. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton && !itemCombo.isClickedComboButton;
  4603. GUI.DrawTexture(new Rect(GetPix(5), GetPix(402), GetPix(160), 2f), line1);
  4604. GUI.DrawTexture(new Rect(GetPix(5), GetPix(402), GetPix(160), 1f), line2);
  4605. isIK[selectMaidIndex] =
  4606. GUI.Toggle(new Rect(GetPix(5),
  4607. GetPix(411),
  4608. GetPix(30),
  4609. GetPix(20)),
  4610. isIK[selectMaidIndex],
  4611. "IK",
  4612. style4);
  4613. if (!isLock[selectMaidIndex])
  4614. {
  4615. GUI.enabled = false;
  4616. }
  4617. isLock[selectMaidIndex] =
  4618. GUI.Toggle(new Rect(GetPix(45),
  4619. GetPix(411),
  4620. GetPix(40),
  4621. GetPix(20)),
  4622. isLock[selectMaidIndex],
  4623. "解除",
  4624. style4);
  4625. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton && !itemCombo.isClickedComboButton;
  4626. if (!isIK[selectMaidIndex])
  4627. {
  4628. GUI.enabled = false;
  4629. }
  4630. isBone[selectMaidIndex] =
  4631. GUI.Toggle(new Rect(GetPix(100),
  4632. GetPix(411),
  4633. GetPix(60),
  4634. GetPix(20)),
  4635. isBone[selectMaidIndex],
  4636. "ボーン",
  4637. style4);
  4638. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton;
  4639. if (isBone[selectMaidIndex] != isBoneN[selectMaidIndex])
  4640. {
  4641. isBoneN[selectMaidIndex] = isBone[selectMaidIndex];
  4642. isChange[selectMaidIndex] = true;
  4643. }
  4644. if (!isLock[selectMaidIndex] && unLockFlg != isLock[selectMaidIndex])
  4645. {
  4646. string[] strArray2 = poseArray[poseIndex[selectMaidIndex]].Split(',');
  4647. isStop[selectMaidIndex] = false;
  4648. poseCount[selectMaidIndex] = 20;
  4649. if (strArray2[0].Contains("_momi") || strArray2[0].Contains("paizuri_"))
  4650. {
  4651. maid.body0.MuneYureL(0.0f);
  4652. maid.body0.MuneYureR(0.0f);
  4653. }
  4654. else
  4655. {
  4656. maid.body0.MuneYureL(1f);
  4657. maid.body0.MuneYureR(1f);
  4658. }
  4659. if (strArray2[0].Contains("MultipleMaidsPose"))
  4660. {
  4661. string path = strArray2[0].Split('/')[1];
  4662. byte[] numArray = new byte[0];
  4663. try
  4664. {
  4665. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  4666. {
  4667. numArray = new byte[fileStream.Length];
  4668. fileStream.Read(numArray, 0, numArray.Length);
  4669. }
  4670. }
  4671. catch { }
  4672. if (0 < numArray.Length)
  4673. {
  4674. long hashCode = Path.GetFileName(path).GetHashCode();
  4675. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  4676. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  4677. {
  4678. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL, Maid.AutoTwist.WristR,
  4679. Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  4680. };
  4681. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  4682. {
  4683. maid.SetAutoTwist(f_eType, true);
  4684. }
  4685. }
  4686. }
  4687. else if (strArray2[0].StartsWith("p") && int.TryParse(strArray2[0].Substring(1), out result))
  4688. {
  4689. loadPose[selectMaidIndex] = strArray2[0];
  4690. }
  4691. else if (!strArray2[0].StartsWith("dance_"))
  4692. {
  4693. maidArray[selectMaidIndex].CrossFade(strArray2[0] + ".anm", false, true, false, 0.0f, 1f);
  4694. }
  4695. else
  4696. {
  4697. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray2[0] + ".anm"))
  4698. {
  4699. maid.body0.LoadAnime(strArray2[0] + ".anm", GameUty.FileSystem, strArray2[0] + ".anm", false, false);
  4700. }
  4701. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray2[0] + ".anm");
  4702. }
  4703. if (strArray2.Length > 1)
  4704. {
  4705. maid.body0.m_Bones.GetComponent<Animation>()[strArray2[0] + ".anm"].time = float.Parse(strArray2[1]);
  4706. isDanceStop = true;
  4707. if (strArray2.Length > 2)
  4708. {
  4709. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  4710. isPoseIti[selectMaidIndex] = true;
  4711. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  4712. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  4713. }
  4714. }
  4715. mHandL[selectMaidIndex].initFlg = false;
  4716. mHandR[selectMaidIndex].initFlg = false;
  4717. mFootL[selectMaidIndex].initFlg = false;
  4718. mFootR[selectMaidIndex].initFlg = false;
  4719. pHandL[selectMaidIndex] = 0;
  4720. pHandR[selectMaidIndex] = 0;
  4721. hanten[selectMaidIndex] = false;
  4722. hantenn[selectMaidIndex] = false;
  4723. muneIKL[selectMaidIndex] = false;
  4724. muneIKR[selectMaidIndex] = false;
  4725. maid.body0.jbMuneL.enabled = true;
  4726. maid.body0.jbMuneR.enabled = true;
  4727. if (!GameMain.Instance.VRMode)
  4728. {
  4729. maidArray[selectMaidIndex].body0.quaDefEyeL.eulerAngles = eyeL[(int)selectList[selectMaidIndex]];
  4730. maidArray[selectMaidIndex].body0.quaDefEyeR.eulerAngles = eyeR[(int)selectList[selectMaidIndex]];
  4731. }
  4732. }
  4733. unLockFlg = isLock[selectMaidIndex];
  4734. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton && !itemCombo.isClickedComboButton;
  4735. if (!isIK[selectMaidIndex])
  4736. {
  4737. GUI.enabled = false;
  4738. }
  4739. hanten[selectMaidIndex] =
  4740. GUI.Toggle(new Rect(GetPix(5),
  4741. GetPix(479),
  4742. GetPix(70),
  4743. GetPix(20)),
  4744. hanten[selectMaidIndex],
  4745. "左右反転",
  4746. style4);
  4747. bool flag1 = GUI.Toggle(new Rect(GetPix(80),
  4748. GetPix(479),
  4749. GetPix(100),
  4750. GetPix(20)),
  4751. kotei[selectMaidIndex],
  4752. "スカート固定",
  4753. style4);
  4754. if (kotei[selectMaidIndex] != flag1)
  4755. {
  4756. kotei[selectMaidIndex] = flag1;
  4757. if (flag1)
  4758. {
  4759. SkirtListArray[selectMaidIndex] = new DynamicSkirtBone[100];
  4760. for (int index2 = 0; index2 < maid.body0.goSlot.Count; ++index2)
  4761. {
  4762. DynamicSkirtBone fieldValue =
  4763. GetFieldValue<BoneHair3, DynamicSkirtBone>(maid.body0.goSlot[index2].bonehair3, "m_SkirtBone");
  4764. SkirtListArray[selectMaidIndex][index2] = fieldValue;
  4765. SetFieldValue<BoneHair3, DynamicSkirtBone>(maid.body0.goSlot[index2].bonehair3,
  4766. "m_SkirtBone",
  4767. null);
  4768. }
  4769. }
  4770. else
  4771. {
  4772. for (int index2 = 0; index2 < maid.body0.goSlot.Count; ++index2)
  4773. {
  4774. SetFieldValue<BoneHair3, DynamicSkirtBone>(maid.body0.goSlot[index2].bonehair3,
  4775. "m_SkirtBone",
  4776. SkirtListArray[selectMaidIndex][index2]);
  4777. }
  4778. }
  4779. }
  4780. GUI.Label(new Rect(GetPix(29), GetPix(433), GetPix(100), GetPix(25)),
  4781. "右手",
  4782. style1);
  4783. GUI.Label(new Rect(GetPix(109), GetPix(433), GetPix(100), GetPix(25)),
  4784. "左手",
  4785. style1);
  4786. string text = "未選択";
  4787. if (copyIndex > 0)
  4788. {
  4789. text = copyIndex.ToString() + ":" + maidArray[copyIndex - 1].status.firstName;
  4790. }
  4791. if (maidCnt <= 1)
  4792. {
  4793. GUI.enabled = false;
  4794. }
  4795. GUI.Label(new Rect(GetPix(8), GetPix(505), GetPix(100), GetPix(25)),
  4796. "コピー",
  4797. style1);
  4798. GUI.Label(new Rect(GetPix(70), GetPix(505), GetPix(100), GetPix(25)),
  4799. text,
  4800. style1);
  4801. GUI.enabled = !poseCombo.isClickedComboButton && !poseGroupCombo.isClickedComboButton && !itemCombo.isClickedComboButton
  4802. && isIK[selectMaidIndex];
  4803. style1.fontSize = GetPix(13);
  4804. style1.alignment = TextAnchor.UpperCenter;
  4805. GUI.Label(new Rect(GetPix(-10), GetPix(449), GetPix(100), GetPix(25)),
  4806. pHandR[selectMaidIndex].ToString(),
  4807. style1);
  4808. GUI.Label(new Rect(GetPix(70), GetPix(449), GetPix(100), GetPix(25)),
  4809. pHandL[selectMaidIndex].ToString(),
  4810. style1);
  4811. style1.fontSize = GetPix(11);
  4812. style1.alignment = TextAnchor.UpperLeft;
  4813. if (GUI.Button(new Rect(GetPix(5), GetPix(448), GetPix(23), GetPix(23)),
  4814. "<",
  4815. style3))
  4816. {
  4817. --pHandR[selectMaidIndex];
  4818. if (pHandR[selectMaidIndex] < 1)
  4819. {
  4820. pHandR[selectMaidIndex] = fingerRArray.GetLength(0);
  4821. }
  4822. for (int index2 = 0; index2 < 20; ++index2)
  4823. {
  4824. string[] strArray2 = fingerRArray[pHandR[selectMaidIndex] - 1, index2].Split(',');
  4825. Finger[selectMaidIndex, index2 + 20].localEulerAngles =
  4826. new Vector3(float.Parse(strArray2[0]), float.Parse(strArray2[1]), float.Parse(strArray2[2]));
  4827. }
  4828. isStop[selectMaidIndex] = true;
  4829. isLock[selectMaidIndex] = true;
  4830. for (int index2 = 0; index2 < 10; ++index2)
  4831. {
  4832. if ((index2 == 0 || index2 == 5) && mFinger[selectMaidIndex, index2 * 3])
  4833. {
  4834. mFinger[selectMaidIndex, index2 * 3].reset = true;
  4835. }
  4836. }
  4837. }
  4838. if (GUI.Button(new Rect(GetPix(55),
  4839. GetPix(448),
  4840. GetPix(23),
  4841. GetPix(23)),
  4842. ">",
  4843. style3))
  4844. {
  4845. ++pHandR[selectMaidIndex];
  4846. if (pHandR[selectMaidIndex] > fingerRArray.GetLength(0))
  4847. {
  4848. pHandR[selectMaidIndex] = 1;
  4849. }
  4850. for (int index2 = 0; index2 < 20; ++index2)
  4851. {
  4852. string[] strArray2 = fingerRArray[pHandR[selectMaidIndex] - 1, index2].Split(',');
  4853. Finger[selectMaidIndex, index2 + 20].localEulerAngles =
  4854. new Vector3(float.Parse(strArray2[0]), float.Parse(strArray2[1]), float.Parse(strArray2[2]));
  4855. }
  4856. isStop[selectMaidIndex] = true;
  4857. isLock[selectMaidIndex] = true;
  4858. for (int index2 = 0; index2 < 10; ++index2)
  4859. {
  4860. if ((index2 == 0 || index2 == 5) && mFinger[selectMaidIndex, index2 * 3])
  4861. {
  4862. mFinger[selectMaidIndex, index2 * 3].reset = true;
  4863. }
  4864. }
  4865. }
  4866. if (GUI.Button(new Rect(GetPix(85),
  4867. GetPix(448),
  4868. GetPix(23),
  4869. GetPix(23)),
  4870. "<",
  4871. style3))
  4872. {
  4873. --pHandL[selectMaidIndex];
  4874. if (pHandL[selectMaidIndex] < 1)
  4875. {
  4876. pHandL[selectMaidIndex] = fingerLArray.GetLength(0);
  4877. }
  4878. for (int index2 = 0; index2 < 20; ++index2)
  4879. {
  4880. string[] strArray2 = fingerLArray[pHandL[selectMaidIndex] - 1, index2].Split(',');
  4881. Finger[selectMaidIndex, index2].localEulerAngles =
  4882. new Vector3(float.Parse(strArray2[0]), float.Parse(strArray2[1]), float.Parse(strArray2[2]));
  4883. }
  4884. isStop[selectMaidIndex] = true;
  4885. isLock[selectMaidIndex] = true;
  4886. }
  4887. if (GUI.Button(new Rect(GetPix(135),
  4888. GetPix(448),
  4889. GetPix(23),
  4890. GetPix(23)),
  4891. ">",
  4892. style3))
  4893. {
  4894. ++pHandL[selectMaidIndex];
  4895. if (pHandL[selectMaidIndex] > fingerRArray.GetLength(0))
  4896. {
  4897. pHandL[selectMaidIndex] = 1;
  4898. }
  4899. for (int index2 = 0; index2 < 20; ++index2)
  4900. {
  4901. string[] strArray2 = fingerLArray[pHandL[selectMaidIndex] - 1, index2].Split(',');
  4902. Finger[selectMaidIndex, index2].localEulerAngles =
  4903. new Vector3(float.Parse(strArray2[0]), float.Parse(strArray2[1]), float.Parse(strArray2[2]));
  4904. }
  4905. isStop[selectMaidIndex] = true;
  4906. isLock[selectMaidIndex] = true;
  4907. }
  4908. if (maidCnt <= 1)
  4909. {
  4910. GUI.enabled = false;
  4911. }
  4912. if (GUI.Button(new Rect(GetPix(45),
  4913. GetPix(504),
  4914. GetPix(22),
  4915. GetPix(20)),
  4916. ">",
  4917. style3))
  4918. {
  4919. ++copyIndex;
  4920. if (copyIndex - 1 == selectMaidIndex)
  4921. {
  4922. ++copyIndex;
  4923. }
  4924. if (copyIndex > maidCnt)
  4925. {
  4926. copyIndex = 0;
  4927. }
  4928. }
  4929. if (isCopy)
  4930. {
  4931. isCopy = false;
  4932. CopyIK2(maidArray[selectMaidIndex], selectMaidIndex, maidArray[copyIndex - 1], copyIndex - 1);
  4933. }
  4934. if (copyIndex == 0)
  4935. {
  4936. GUI.enabled = false;
  4937. }
  4938. if (GUI.Button(new Rect(GetPix(123),
  4939. GetPix(504),
  4940. GetPix(35),
  4941. GetPix(20)),
  4942. "決定",
  4943. style3))
  4944. {
  4945. CopyIK(maidArray[selectMaidIndex], selectMaidIndex, maidArray[copyIndex - 1], copyIndex - 1);
  4946. isCopy = true;
  4947. pHandL[selectMaidIndex] = pHandL[copyIndex - 1];
  4948. pHandR[selectMaidIndex] = pHandR[copyIndex - 1];
  4949. hanten[selectMaidIndex] = hanten[copyIndex - 1];
  4950. hantenn[selectMaidIndex] = hantenn[copyIndex - 1];
  4951. }
  4952. GUI.enabled = true;
  4953. if (poseCombo.isClickedComboButton || poseGroupCombo.isClickedComboButton)
  4954. {
  4955. GUI.enabled = false;
  4956. }
  4957. GUI.EndScrollView();
  4958. itemIndex2[selectMaidIndex] =
  4959. itemCombo.List(new Rect(GetPix(35),
  4960. GetPix(215),
  4961. GetPix(95),
  4962. GetPix(23)),
  4963. itemComboList[itemIndex[selectMaidIndex]].text,
  4964. itemComboList,
  4965. buttonStyle1,
  4966. "box",
  4967. listStyle3);
  4968. GUI.enabled = true;
  4969. if (poseGroupCombo.isClickedComboButton || isLock[selectMaidIndex])
  4970. {
  4971. GUI.enabled = false;
  4972. }
  4973. poseCombo.List(new Rect(GetPix(35),
  4974. GetPix(125),
  4975. GetPix(95),
  4976. GetPix(23)),
  4977. poseComboList[index6].text,
  4978. poseComboList,
  4979. buttonStyle1,
  4980. "box",
  4981. listStyle2);
  4982. if (!isLock[selectMaidIndex])
  4983. {
  4984. GUI.enabled = true;
  4985. }
  4986. int index7 = -1;
  4987. for (int index2 = 0; index2 < groupList.Count; ++index2)
  4988. {
  4989. if (poseIndex[selectMaidIndex] < (int)groupList[index2])
  4990. {
  4991. index7 = index2;
  4992. break;
  4993. }
  4994. }
  4995. if (index7 < 0)
  4996. {
  4997. index7 = groupList.Count;
  4998. }
  4999. if (GUI.Button(new Rect(GetPix(5), GetPix(95), GetPix(23), GetPix(23)),
  5000. "<",
  5001. style3))
  5002. {
  5003. isPoseInit = true;
  5004. if (!isLock[selectMaidIndex])
  5005. {
  5006. for (int index2 = 0; index2 < groupList.Count; ++index2)
  5007. {
  5008. if (index2 == 0 && poseIndex[selectMaidIndex] <= (int)groupList[index2])
  5009. {
  5010. poseIndex[selectMaidIndex] = poseIndex[selectMaidIndex] != 0 ? 0 : (int)groupList[groupList.Count - 1];
  5011. break;
  5012. }
  5013. if (index2 > 0 && poseIndex[selectMaidIndex] > (int)groupList[index2 - 1]
  5014. && poseIndex[selectMaidIndex] <= (int)groupList[index2])
  5015. {
  5016. poseIndex[selectMaidIndex] = (int)groupList[index2 - 1];
  5017. break;
  5018. }
  5019. }
  5020. if (poseIndex[selectMaidIndex] > (int)groupList[groupList.Count - 1])
  5021. {
  5022. poseIndex[selectMaidIndex] = (int)groupList[groupList.Count - 1];
  5023. }
  5024. if (maid && maid.Visible)
  5025. {
  5026. string[] strArray2 = poseArray[poseIndex[selectMaidIndex]].Split(',');
  5027. isStop[selectMaidIndex] = false;
  5028. poseCount[selectMaidIndex] = 20;
  5029. if (strArray2[0].Contains("_momi") || strArray2[0].Contains("paizuri_"))
  5030. {
  5031. maid.body0.MuneYureL(0.0f);
  5032. maid.body0.MuneYureR(0.0f);
  5033. }
  5034. else
  5035. {
  5036. maid.body0.MuneYureL(1f);
  5037. maid.body0.MuneYureR(1f);
  5038. }
  5039. if (strArray2[0].Contains("MultipleMaidsPose"))
  5040. {
  5041. string path = strArray2[0].Split('/')[1];
  5042. byte[] numArray = new byte[0];
  5043. try
  5044. {
  5045. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  5046. {
  5047. numArray = new byte[fileStream.Length];
  5048. fileStream.Read(numArray, 0, numArray.Length);
  5049. }
  5050. }
  5051. catch { }
  5052. if (0 < numArray.Length)
  5053. {
  5054. long hashCode = Path.GetFileName(path).GetHashCode();
  5055. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  5056. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  5057. {
  5058. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL,
  5059. Maid.AutoTwist.WristR, Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  5060. };
  5061. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  5062. {
  5063. maid.SetAutoTwist(f_eType, true);
  5064. }
  5065. }
  5066. }
  5067. else if (strArray2[0].StartsWith("p") && int.TryParse(strArray2[0].Substring(1), out result))
  5068. {
  5069. loadPose[selectMaidIndex] = strArray2[0];
  5070. }
  5071. else if (!strArray2[0].StartsWith("dance_"))
  5072. {
  5073. maidArray[selectMaidIndex].CrossFade(strArray2[0] + ".anm", false, true, false, 0.0f, 1f);
  5074. }
  5075. else
  5076. {
  5077. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray2[0] + ".anm"))
  5078. {
  5079. maid.body0.LoadAnime(strArray2[0] + ".anm", GameUty.FileSystem, strArray2[0] + ".anm", false, false);
  5080. }
  5081. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray2[0] + ".anm");
  5082. }
  5083. if (strArray2.Length > 1)
  5084. {
  5085. maid.body0.m_Bones.GetComponent<Animation>()[strArray2[0] + ".anm"].time = float.Parse(strArray2[1]);
  5086. isDanceStop = true;
  5087. if (strArray2.Length > 2)
  5088. {
  5089. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  5090. isPoseIti[selectMaidIndex] = true;
  5091. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  5092. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  5093. }
  5094. }
  5095. }
  5096. }
  5097. int index3 = -1;
  5098. for (int index2 = 0; index2 < groupList.Count; ++index2)
  5099. {
  5100. if (poseIndex[selectMaidIndex] < (int)groupList[index2])
  5101. {
  5102. index3 = index2;
  5103. break;
  5104. }
  5105. }
  5106. int length2 = (int)groupList[0];
  5107. int num2 = 0;
  5108. if (index3 > 0)
  5109. {
  5110. length2 = (int)groupList[index3] - (int)groupList[index3 - 1];
  5111. num2 = (int)groupList[index3 - 1];
  5112. }
  5113. if (index3 < 0)
  5114. {
  5115. index3 = groupList.Count;
  5116. length2 = poseArray.Length - (int)groupList[index3 - 1];
  5117. num2 = (int)groupList[index3 - 1];
  5118. }
  5119. poseComboList = new GUIContent[length2];
  5120. int index4 = 0;
  5121. for (int index2 = num2; index2 < num2 + length2; ++index2)
  5122. {
  5123. bool flag2 = false;
  5124. foreach (IniKey key in Preferences["pose"].Keys)
  5125. {
  5126. if (poseArray[index2] == key.Key)
  5127. {
  5128. IniKey iniKey = Preferences["pose"][key.Key];
  5129. if (iniKey.Value != null && iniKey.Value.ToString() != "" && iniKey.Value.ToString() != "del")
  5130. {
  5131. poseComboList[index4] =
  5132. new GUIContent((index4 + 1).ToString() + ":" + iniKey.Value.Split('_')[0]
  5133. + "                    " + key.Key);
  5134. flag2 = true;
  5135. }
  5136. }
  5137. }
  5138. if (!flag2)
  5139. {
  5140. poseComboList[index4] = new GUIContent((index4 + 1).ToString() + ":" + poseArray[index2]);
  5141. }
  5142. ++index4;
  5143. }
  5144. poseCombo.scrollPos = new Vector2(0.0f, 0.0f);
  5145. poseGroupCombo.selectedItemIndex = index3;
  5146. poseCombo.selectedItemIndex = 0;
  5147. }
  5148. if (GUI.Button(new Rect(GetPix(135),
  5149. GetPix(95),
  5150. GetPix(23),
  5151. GetPix(23)),
  5152. ">",
  5153. style3))
  5154. {
  5155. isPoseInit = true;
  5156. if (!isLock[selectMaidIndex])
  5157. {
  5158. int num2 = poseIndex[selectMaidIndex];
  5159. for (int index2 = 0; index2 < groupList.Count; ++index2)
  5160. {
  5161. if (poseIndex[selectMaidIndex] < (int)groupList[index2])
  5162. {
  5163. poseIndex[selectMaidIndex] = (int)groupList[index2];
  5164. break;
  5165. }
  5166. }
  5167. if (num2 == poseIndex[selectMaidIndex] && poseIndex[selectMaidIndex] >= (int)groupList[groupList.Count - 1])
  5168. {
  5169. poseIndex[selectMaidIndex] = 0;
  5170. }
  5171. if (maid && maid.Visible)
  5172. {
  5173. string[] strArray2 = poseArray[poseIndex[selectMaidIndex]].Split(',');
  5174. isStop[selectMaidIndex] = false;
  5175. poseCount[selectMaidIndex] = 20;
  5176. if (strArray2[0].Contains("_momi") || strArray2[0].Contains("paizuri_"))
  5177. {
  5178. maid.body0.MuneYureL(0.0f);
  5179. maid.body0.MuneYureR(0.0f);
  5180. }
  5181. else
  5182. {
  5183. maid.body0.MuneYureL(1f);
  5184. maid.body0.MuneYureR(1f);
  5185. }
  5186. if (strArray2[0].Contains("MultipleMaidsPose"))
  5187. {
  5188. string path = strArray2[0].Split('/')[1];
  5189. byte[] numArray = new byte[0];
  5190. try
  5191. {
  5192. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  5193. {
  5194. numArray = new byte[fileStream.Length];
  5195. fileStream.Read(numArray, 0, numArray.Length);
  5196. }
  5197. }
  5198. catch { }
  5199. if (0 < numArray.Length)
  5200. {
  5201. long hashCode = Path.GetFileName(path).GetHashCode();
  5202. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  5203. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  5204. {
  5205. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL,
  5206. Maid.AutoTwist.WristR, Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  5207. };
  5208. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  5209. {
  5210. maid.SetAutoTwist(f_eType, true);
  5211. }
  5212. }
  5213. }
  5214. else if (strArray2[0].StartsWith("p") && int.TryParse(strArray2[0].Substring(1), out result))
  5215. {
  5216. loadPose[selectMaidIndex] = strArray2[0];
  5217. }
  5218. else if (!strArray2[0].StartsWith("dance_"))
  5219. {
  5220. maidArray[selectMaidIndex].CrossFade(strArray2[0] + ".anm", false, true, false, 0.0f, 1f);
  5221. }
  5222. else
  5223. {
  5224. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray2[0] + ".anm"))
  5225. {
  5226. maid.body0.LoadAnime(strArray2[0] + ".anm", GameUty.FileSystem, strArray2[0] + ".anm", false, false);
  5227. }
  5228. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray2[0] + ".anm");
  5229. }
  5230. if (strArray2.Length > 1)
  5231. {
  5232. maid.body0.m_Bones.GetComponent<Animation>()[strArray2[0] + ".anm"].time = float.Parse(strArray2[1]);
  5233. isDanceStop = true;
  5234. if (strArray2.Length > 2)
  5235. {
  5236. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  5237. isPoseIti[selectMaidIndex] = true;
  5238. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  5239. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  5240. }
  5241. }
  5242. }
  5243. }
  5244. int index3 = -1;
  5245. for (int index2 = 0; index2 < groupList.Count; ++index2)
  5246. {
  5247. if (poseIndex[selectMaidIndex] < (int)groupList[index2])
  5248. {
  5249. index3 = index2;
  5250. break;
  5251. }
  5252. }
  5253. int length2 = (int)groupList[0];
  5254. int num3 = 0;
  5255. if (index3 > 0)
  5256. {
  5257. length2 = (int)groupList[index3] - (int)groupList[index3 - 1];
  5258. num3 = (int)groupList[index3 - 1];
  5259. }
  5260. if (index3 < 0)
  5261. {
  5262. index3 = groupList.Count;
  5263. length2 = poseArray.Length - (int)groupList[index3 - 1];
  5264. num3 = (int)groupList[index3 - 1];
  5265. }
  5266. poseComboList = new GUIContent[length2];
  5267. int index4 = 0;
  5268. for (int index2 = num3; index2 < num3 + length2; ++index2)
  5269. {
  5270. bool flag2 = false;
  5271. foreach (IniKey key in Preferences["pose"].Keys)
  5272. {
  5273. if (poseArray[index2] == key.Key)
  5274. {
  5275. IniKey iniKey = Preferences["pose"][key.Key];
  5276. if (iniKey.Value != null && iniKey.Value.ToString() != "" && iniKey.Value.ToString() != "del")
  5277. {
  5278. poseComboList[index4] =
  5279. new GUIContent((index4 + 1).ToString() + ":" + iniKey.Value.Split('_')[0]
  5280. + "                    " + key.Key);
  5281. flag2 = true;
  5282. }
  5283. }
  5284. }
  5285. if (!flag2)
  5286. {
  5287. poseComboList[index4] = new GUIContent((index4 + 1).ToString() + ":" + poseArray[index2]);
  5288. }
  5289. ++index4;
  5290. }
  5291. poseCombo.scrollPos = new Vector2(0.0f, 0.0f);
  5292. poseGroupCombo.selectedItemIndex = index3;
  5293. poseCombo.selectedItemIndex = 0;
  5294. }
  5295. poseGroupIndex =
  5296. poseGroupCombo.List(new Rect(GetPix(35),
  5297. GetPix(95),
  5298. GetPix(95),
  5299. GetPix(23)),
  5300. poseGroupComboList[index7].text,
  5301. poseGroupComboList,
  5302. buttonStyle2,
  5303. "box",
  5304. listStyle4);
  5305. if (poseGroupCombo.isClickedComboButton)
  5306. {
  5307. isCombo2 = true;
  5308. }
  5309. else if (isCombo2)
  5310. {
  5311. isCombo2 = false;
  5312. isPoseInit = true;
  5313. poseIndex[selectMaidIndex] = poseGroupIndex <= 0 ? 0 : (int)groupList[poseGroupIndex - 1];
  5314. if (!isLock[selectMaidIndex] && maid && maid.Visible)
  5315. {
  5316. string[] strArray2 = poseArray[poseIndex[selectMaidIndex]].Split(',');
  5317. isStop[selectMaidIndex] = false;
  5318. poseCount[selectMaidIndex] = 20;
  5319. if (strArray2[0].Contains("_momi") || strArray2[0].Contains("paizuri_"))
  5320. {
  5321. maid.body0.MuneYureL(0.0f);
  5322. maid.body0.MuneYureR(0.0f);
  5323. }
  5324. else
  5325. {
  5326. maid.body0.MuneYureL(1f);
  5327. maid.body0.MuneYureR(1f);
  5328. }
  5329. if (strArray2[0].Contains("MultipleMaidsPose"))
  5330. {
  5331. string path = strArray2[0].Split('/')[1];
  5332. byte[] numArray = new byte[0];
  5333. try
  5334. {
  5335. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  5336. {
  5337. numArray = new byte[fileStream.Length];
  5338. fileStream.Read(numArray, 0, numArray.Length);
  5339. }
  5340. }
  5341. catch { }
  5342. if (0 < numArray.Length)
  5343. {
  5344. long hashCode = Path.GetFileName(path).GetHashCode();
  5345. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  5346. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  5347. {
  5348. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL, Maid.AutoTwist.WristR,
  5349. Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  5350. };
  5351. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  5352. {
  5353. maid.SetAutoTwist(f_eType, true);
  5354. }
  5355. }
  5356. }
  5357. else if (strArray2[0].StartsWith("p") && int.TryParse(strArray2[0].Substring(1), out result))
  5358. {
  5359. loadPose[selectMaidIndex] = strArray2[0];
  5360. }
  5361. else if (!strArray2[0].StartsWith("dance_"))
  5362. {
  5363. maidArray[selectMaidIndex].CrossFade(strArray2[0] + ".anm", false, true, false, 0.0f, 1f);
  5364. }
  5365. else
  5366. {
  5367. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray2[0] + ".anm"))
  5368. {
  5369. maid.body0.LoadAnime(strArray2[0] + ".anm", GameUty.FileSystem, strArray2[0] + ".anm", false, false);
  5370. }
  5371. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray2[0] + ".anm");
  5372. }
  5373. if (strArray2.Length > 1)
  5374. {
  5375. maid.body0.m_Bones.GetComponent<Animation>()[strArray2[0] + ".anm"].time = float.Parse(strArray2[1]);
  5376. isDanceStop = true;
  5377. if (strArray2.Length > 2)
  5378. {
  5379. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  5380. isPoseIti[selectMaidIndex] = true;
  5381. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  5382. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  5383. }
  5384. }
  5385. }
  5386. int index2 = -1;
  5387. for (int index3 = 0; index3 < groupList.Count; ++index3)
  5388. {
  5389. if (poseIndex[selectMaidIndex] < (int)groupList[index3])
  5390. {
  5391. index2 = index3;
  5392. break;
  5393. }
  5394. }
  5395. int length2 = (int)groupList[0];
  5396. int num2 = 0;
  5397. if (index2 > 0)
  5398. {
  5399. length2 = (int)groupList[index2] - (int)groupList[index2 - 1];
  5400. num2 = (int)groupList[index2 - 1];
  5401. }
  5402. if (index2 < 0)
  5403. {
  5404. index2 = groupList.Count;
  5405. length2 = poseArray.Length - (int)groupList[index2 - 1];
  5406. num2 = (int)groupList[index2 - 1];
  5407. }
  5408. poseComboList = new GUIContent[length2];
  5409. int index4 = 0;
  5410. for (int index3 = num2; index3 < num2 + length2; ++index3)
  5411. {
  5412. bool flag2 = false;
  5413. foreach (IniKey key in Preferences["pose"].Keys)
  5414. {
  5415. if (poseArray[index3] == key.Key)
  5416. {
  5417. IniKey iniKey = Preferences["pose"][key.Key];
  5418. if (iniKey.Value != null && iniKey.Value.ToString() != "" && iniKey.Value.ToString() != "del")
  5419. {
  5420. poseComboList[index4] =
  5421. new GUIContent((index4 + 1).ToString() + ":" + iniKey.Value.Split('_')[0]
  5422. + "                    " + key.Key);
  5423. flag2 = true;
  5424. }
  5425. }
  5426. }
  5427. if (!flag2)
  5428. {
  5429. poseComboList[index4] = new GUIContent((index4 + 1).ToString() + ":" + poseArray[index3]);
  5430. }
  5431. ++index4;
  5432. }
  5433. poseCombo.scrollPos = new Vector2(0.0f, 0.0f);
  5434. poseGroupCombo.selectedItemIndex = index2;
  5435. poseCombo.selectedItemIndex = 0;
  5436. }
  5437. if (poseCombo.isClickedComboButton)
  5438. {
  5439. isCombo = true;
  5440. }
  5441. else if (isCombo)
  5442. {
  5443. isCombo = false;
  5444. isPoseInit = true;
  5445. poseIndex[selectMaidIndex] = poseGroupIndex <= 0
  5446. ? poseCombo.selectedItemIndex
  5447. : (int)groupList[poseGroupIndex - 1] + poseCombo.selectedItemIndex;
  5448. if (poseIndex[selectMaidIndex] == poseArray.Length)
  5449. {
  5450. poseIndex[selectMaidIndex] = 0;
  5451. }
  5452. if (!isLock[selectMaidIndex] && maid && maid.Visible)
  5453. {
  5454. string[] strArray2 = poseArray[poseIndex[selectMaidIndex]].Split(',');
  5455. isStop[selectMaidIndex] = false;
  5456. poseCount[selectMaidIndex] = 20;
  5457. if (strArray2[0].Contains("_momi") || strArray2[0].Contains("paizuri_"))
  5458. {
  5459. maid.body0.MuneYureL(0.0f);
  5460. maid.body0.MuneYureR(0.0f);
  5461. }
  5462. else
  5463. {
  5464. maid.body0.MuneYureL(1f);
  5465. maid.body0.MuneYureR(1f);
  5466. }
  5467. if (strArray2[0].Contains("MultipleMaidsPose"))
  5468. {
  5469. string path = strArray2[0].Split('/')[1];
  5470. byte[] numArray = new byte[0];
  5471. try
  5472. {
  5473. using (FileStream fileStream = new FileStream(path, FileMode.Open, FileAccess.Read))
  5474. {
  5475. numArray = new byte[fileStream.Length];
  5476. fileStream.Read(numArray, 0, numArray.Length);
  5477. }
  5478. }
  5479. catch { }
  5480. if (0 < numArray.Length)
  5481. {
  5482. long hashCode = Path.GetFileName(path).GetHashCode();
  5483. maid.body0.CrossFade(hashCode.ToString(), numArray, false, false, false, 0.0f, 1f);
  5484. Maid.AutoTwist[] autoTwistArray = new Maid.AutoTwist[6]
  5485. {
  5486. Maid.AutoTwist.ShoulderL, Maid.AutoTwist.ShoulderR, Maid.AutoTwist.WristL, Maid.AutoTwist.WristR,
  5487. Maid.AutoTwist.ThighL, Maid.AutoTwist.ThighR
  5488. };
  5489. foreach (Maid.AutoTwist f_eType in autoTwistArray)
  5490. {
  5491. maid.SetAutoTwist(f_eType, true);
  5492. }
  5493. }
  5494. }
  5495. else if (strArray2[0].StartsWith("p") && int.TryParse(strArray2[0].Substring(1), out result))
  5496. {
  5497. loadPose[selectMaidIndex] = strArray2[0];
  5498. }
  5499. else if (!strArray2[0].StartsWith("dance_"))
  5500. {
  5501. maidArray[selectMaidIndex].CrossFade(strArray2[0] + ".anm", false, true, false, 0.0f, 1f);
  5502. }
  5503. else
  5504. {
  5505. if (!maid.body0.m_Bones.GetComponent<Animation>().GetClip(strArray2[0] + ".anm"))
  5506. {
  5507. maid.body0.LoadAnime(strArray2[0] + ".anm", GameUty.FileSystem, strArray2[0] + ".anm", false, false);
  5508. }
  5509. maid.body0.m_Bones.GetComponent<Animation>().Play(strArray2[0] + ".anm");
  5510. }
  5511. if (strArray2.Length > 1)
  5512. {
  5513. maid.body0.m_Bones.GetComponent<Animation>()[strArray2[0] + ".anm"].time = float.Parse(strArray2[1]);
  5514. isDanceStop = true;
  5515. if (strArray2.Length > 2)
  5516. {
  5517. transform = CMT.SearchObjName(maidArray[selectMaidIndex].body0.m_Bones.transform, "Bip01", true);
  5518. isPoseIti[selectMaidIndex] = true;
  5519. poseIti[selectMaidIndex] = maidArray[selectMaidIndex].transform.position;
  5520. maidArray[selectMaidIndex].transform.position = new Vector3(100f, 100f, 100f);
  5521. }
  5522. }
  5523. }
  5524. }
  5525. if (itemCombo.isClickedComboButton)
  5526. {
  5527. isCombo3 = true;
  5528. }
  5529. else if (isCombo3)
  5530. {
  5531. isCombo3 = false;
  5532. strArray1 = new string[2];
  5533. string[] strArray2 = itemArray[itemIndex2[selectMaidIndex]].Split(',');
  5534. if (itemIndex2[selectMaidIndex] > 13)
  5535. {
  5536. strArray2 = itemArray[itemIndex2[selectMaidIndex] + 1].Split(',');
  5537. }
  5538. maid.DelProp(MPN.handitem, true);
  5539. bool flag2 = false;
  5540. if (itemIndex2[selectMaidIndex] == 0)
  5541. {
  5542. maid.DelProp(MPN.accvag, true);
  5543. maid.DelProp(MPN.accanl, true);
  5544. }
  5545. if (itemIndex2[selectMaidIndex] == 12 || itemIndex2[selectMaidIndex] == 13)
  5546. {
  5547. flag2 = true;
  5548. }
  5549. if (!flag2)
  5550. {
  5551. maid.DelProp(MPN.kousoku_upper, true);
  5552. maid.DelProp(MPN.kousoku_lower, true);
  5553. }
  5554. if (strArray2[0] != "")
  5555. {
  5556. maid.SetProp(strArray2[0], strArray2[1], 0, true, false);
  5557. }
  5558. if (itemIndex2[selectMaidIndex] == 12)
  5559. {
  5560. string[] strArray3 = itemArray[itemIndex2[selectMaidIndex] - 1].Split(',');
  5561. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  5562. }
  5563. if (itemIndex2[selectMaidIndex] == 13)
  5564. {
  5565. string[] strArray3 = itemArray[itemIndex2[selectMaidIndex] + 1].Split(',');
  5566. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  5567. }
  5568. if (itemIndex2[selectMaidIndex] == 23)
  5569. {
  5570. string[] strArray3 = itemArray[itemIndex2[selectMaidIndex]].Split(',');
  5571. maid.SetProp(strArray3[0], strArray3[1], 0, true, false);
  5572. cafeFlg[selectMaidIndex] = true;
  5573. }
  5574. maid.AllProcPropSeqStart();
  5575. itemCombo.selectedItemIndex = itemIndex2[selectMaidIndex];
  5576. itemIndex[selectMaidIndex] = itemIndex2[selectMaidIndex];
  5577. }
  5578. }
  5579. else
  5580. {
  5581. isWear = GUI.Toggle(new Rect(GetPix(5),
  5582. GetPix(98),
  5583. GetPix(70),
  5584. GetPix(20)),
  5585. isWear,
  5586. "トップス",
  5587. style4);
  5588. isSkirt = GUI.Toggle(new Rect(GetPix(90),
  5589. GetPix(98),
  5590. GetPix(70),
  5591. GetPix(20)),
  5592. isSkirt,
  5593. "ボトムス",
  5594. style4);
  5595. isBra = GUI.Toggle(new Rect(GetPix(5),
  5596. GetPix(123),
  5597. GetPix(80),
  5598. GetPix(20)),
  5599. isBra,
  5600. "ブラジャー",
  5601. style4);
  5602. isPanz = GUI.Toggle(new Rect(GetPix(90),
  5603. GetPix(123),
  5604. GetPix(60),
  5605. GetPix(20)),
  5606. isPanz,
  5607. "パンツ",
  5608. style4);
  5609. isHeadset = GUI.Toggle(new Rect(GetPix(5),
  5610. GetPix(148),
  5611. GetPix(70),
  5612. GetPix(20)),
  5613. isHeadset,
  5614. "ヘッド",
  5615. style4);
  5616. isMegane = GUI.Toggle(new Rect(GetPix(90),
  5617. GetPix(148),
  5618. GetPix(70),
  5619. GetPix(20)),
  5620. isMegane,
  5621. "メガネ",
  5622. style4);
  5623. isAccUde = GUI.Toggle(new Rect(GetPix(5),
  5624. GetPix(173),
  5625. GetPix(40),
  5626. GetPix(20)),
  5627. isAccUde,
  5628. "腕",
  5629. style4);
  5630. isGlove = GUI.Toggle(new Rect(GetPix(45),
  5631. GetPix(173),
  5632. GetPix(40),
  5633. GetPix(20)),
  5634. isGlove,
  5635. "手袋",
  5636. style4);
  5637. isAccSenaka = GUI.Toggle(new Rect(GetPix(97),
  5638. GetPix(173),
  5639. GetPix(40),
  5640. GetPix(20)),
  5641. isAccSenaka,
  5642. "背中",
  5643. style4);
  5644. isStkg = GUI.Toggle(new Rect(GetPix(5),
  5645. GetPix(198),
  5646. GetPix(70),
  5647. GetPix(20)),
  5648. isStkg,
  5649. "ソックス",
  5650. style4);
  5651. isShoes = GUI.Toggle(new Rect(GetPix(90),
  5652. GetPix(198),
  5653. GetPix(70),
  5654. GetPix(20)),
  5655. isShoes,
  5656. "シューズ",
  5657. style4);
  5658. mekure1[selectMaidIndex] =
  5659. GUI.Toggle(new Rect(GetPix(5),
  5660. GetPix(223),
  5661. GetPix(62),
  5662. GetPix(20)),
  5663. mekure1[selectMaidIndex],
  5664. "めくれ前",
  5665. style4);
  5666. mekure2[selectMaidIndex] =
  5667. GUI.Toggle(new Rect(GetPix(67),
  5668. GetPix(223),
  5669. GetPix(40),
  5670. GetPix(20)),
  5671. mekure2[selectMaidIndex],
  5672. "後ろ",
  5673. style4);
  5674. zurasi[selectMaidIndex] =
  5675. GUI.Toggle(new Rect(GetPix(105),
  5676. GetPix(223),
  5677. GetPix(50),
  5678. GetPix(20)),
  5679. zurasi[selectMaidIndex],
  5680. "ずらし",
  5681. style4);
  5682. }
  5683. bool state = GUI.enabled;
  5684. GUI.enabled = true;
  5685. GUI.DragWindow();
  5686. GUI.enabled = state;
  5687. }
  5688. private void FaceWindow(int winID)
  5689. {
  5690. GUIStyle style1 = "label";
  5691. style1.fontSize = GetPix(12);
  5692. style1.alignment = TextAnchor.UpperLeft;
  5693. GUIStyle style2 = "label";
  5694. style2.fontSize = GetPix(11);
  5695. style2.alignment = TextAnchor.UpperLeft;
  5696. GUIStyle style3 = "button";
  5697. style3.fontSize = GetPix(20);
  5698. GUIStyle buttonStyle = "button";
  5699. buttonStyle.fontSize = GetPix(12);
  5700. buttonStyle.alignment = TextAnchor.MiddleLeft;
  5701. GUIStyle style4 = new GUIStyle("toggle")
  5702. {
  5703. fontSize = GetPix(13)
  5704. };
  5705. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  5706. if (!faceInitFlg)
  5707. {
  5708. listStyle2.normal.textColor = Color.white;
  5709. listStyle2.normal.background = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.5f));
  5710. listStyle2.onHover.background = listStyle2.hover.background = new Texture2D(2, 2);
  5711. listStyle2.padding.left = listStyle2.padding.right = listStyle2.padding.top = listStyle2.padding.bottom = GetPix(0);
  5712. listStyle2.fontSize = GetPix(12);
  5713. faceCombo.selectedItemIndex = 0;
  5714. List<string> stringList = new List<string>(300);
  5715. stringList.AddRange(faceArray);
  5716. for (int index = 1; index < 300; ++index)
  5717. {
  5718. IniKey iniKey = Preferences["face"]["f" + index];
  5719. if (iniKey.Value != null)
  5720. {
  5721. string[] strArray = iniKey.Value.Split(':');
  5722. if (strArray.Length > 1)
  5723. {
  5724. stringList.Add(strArray[0] + "               :" + index + ":" + strArray[1]);
  5725. }
  5726. }
  5727. else
  5728. {
  5729. break;
  5730. }
  5731. }
  5732. faceCombo.selectedItemIndex = 0;
  5733. faceComboList = new GUIContent[stringList.ToArray().Length];
  5734. for (int index = 0; index < stringList.ToArray().Length; ++index)
  5735. {
  5736. faceComboList[index] = new GUIContent(stringList.ToArray()[index]);
  5737. }
  5738. faceInitFlg = true;
  5739. }
  5740. if (faceCombo.isClickedComboButton)
  5741. {
  5742. GUI.enabled = false;
  5743. }
  5744. if (sceneLevel == 3 || sceneLevel == 5 || isF6)
  5745. {
  5746. if (!isF6)
  5747. {
  5748. bool flag = true;
  5749. if (faceFlg || poseFlg || sceneFlg || kankyoFlg || kankyo2Flg)
  5750. {
  5751. flag = false;
  5752. }
  5753. if (GUI.Toggle(new Rect(GetPix(2),
  5754. GetPix(2),
  5755. GetPix(39),
  5756. GetPix(20)),
  5757. flag,
  5758. "配置",
  5759. style4))
  5760. {
  5761. faceFlg = false;
  5762. poseFlg = false;
  5763. sceneFlg = false;
  5764. kankyoFlg = false;
  5765. kankyo2Flg = false;
  5766. bGui = true;
  5767. }
  5768. }
  5769. if (!yotogiFlg && GUI.Toggle(new Rect(GetPix(41),
  5770. GetPix(2),
  5771. GetPix(39),
  5772. GetPix(20)),
  5773. poseFlg,
  5774. "操作",
  5775. style4))
  5776. {
  5777. poseFlg = true;
  5778. faceFlg = false;
  5779. sceneFlg = false;
  5780. kankyoFlg = false;
  5781. kankyo2Flg = false;
  5782. }
  5783. if (GUI.Toggle(new Rect(GetPix(80), GetPix(2), GetPix(39), GetPix(20)),
  5784. faceFlg,
  5785. "表情",
  5786. style4))
  5787. {
  5788. faceFlg = true;
  5789. poseFlg = false;
  5790. sceneFlg = false;
  5791. kankyoFlg = false;
  5792. kankyo2Flg = false;
  5793. if (!faceFlg2)
  5794. {
  5795. isFaceInit = true;
  5796. faceFlg2 = true;
  5797. maidArray[selectMaidIndex].boMabataki = false;
  5798. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  5799. }
  5800. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  5801. }
  5802. if (GUI.Toggle(new Rect(GetPix(119), GetPix(2), GetPix(39), GetPix(20)),
  5803. kankyoFlg,
  5804. "環境",
  5805. style4))
  5806. {
  5807. poseFlg = false;
  5808. faceFlg = false;
  5809. sceneFlg = false;
  5810. kankyoFlg = true;
  5811. kankyo2Flg = false;
  5812. }
  5813. if (!line1)
  5814. {
  5815. line1 = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.3f));
  5816. line2 = MakeTex(2, 2, new Color(0.7f, 0.7f, 0.7f, 0.6f));
  5817. }
  5818. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 2f), line1);
  5819. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 1f), line2);
  5820. style1.fontSize = GetPix(13);
  5821. style1.alignment = TextAnchor.MiddleCenter;
  5822. GUI.Label(new Rect(GetPix(125), GetPix(25), GetPix(40), GetPix(25)),
  5823. string.Concat(selectMaidIndex + 1),
  5824. style1);
  5825. style1.fontSize = GetPix(11);
  5826. style1.alignment = TextAnchor.UpperLeft;
  5827. }
  5828. if (sceneLevel > 0)
  5829. {
  5830. int selectMaidIndex = this.selectMaidIndex;
  5831. if (sceneLevel == 3 || sceneLevel == 5 && (isF7 || maidCnt > 1))
  5832. {
  5833. if (GUI.Button(new Rect(GetPix(5),
  5834. GetPix(53),
  5835. GetPix(23),
  5836. GetPix(32)),
  5837. "<",
  5838. style3))
  5839. {
  5840. --this.selectMaidIndex;
  5841. if (this.selectMaidIndex < 0)
  5842. {
  5843. this.selectMaidIndex = selectList.Count - 1;
  5844. }
  5845. isFaceInit = true;
  5846. faceFlg = true;
  5847. copyIndex = 0;
  5848. faceCombo.selectedItemIndex = faceIndex[this.selectMaidIndex];
  5849. }
  5850. if (GUI.Button(new Rect(GetPix(135),
  5851. GetPix(53),
  5852. GetPix(23),
  5853. GetPix(32)),
  5854. ">",
  5855. style3))
  5856. {
  5857. ++this.selectMaidIndex;
  5858. if (selectList.Count <= this.selectMaidIndex)
  5859. {
  5860. this.selectMaidIndex = 0;
  5861. }
  5862. isFaceInit = true;
  5863. faceFlg = true;
  5864. copyIndex = 0;
  5865. faceCombo.selectedItemIndex = faceIndex[this.selectMaidIndex];
  5866. }
  5867. }
  5868. if (maidArray[this.selectMaidIndex].GetThumIcon())
  5869. {
  5870. GUI.DrawTexture(new Rect(GetPix(30),
  5871. GetPix(25),
  5872. GetPix(60),
  5873. GetPix(60)),
  5874. maidArray[this.selectMaidIndex].GetThumIcon());
  5875. }
  5876. GUI.Label(new Rect(GetPix(90), GetPix(50), GetPix(140), GetPix(210)),
  5877. maidArray[this.selectMaidIndex].status.lastName + "\n" + maidArray[this.selectMaidIndex].status.firstName,
  5878. style1);
  5879. if (isFace[selectMaidIndex])
  5880. {
  5881. if (GUI.Button(new Rect(GetPix(5),
  5882. GetPix(25),
  5883. GetPix(23),
  5884. GetPix(23)),
  5885. "有",
  5886. style3))
  5887. {
  5888. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  5889. maidArray[selectMaidIndex].boMabataki = false;
  5890. isFace[selectMaidIndex] = false;
  5891. }
  5892. maidArray[selectMaidIndex].boMabataki = false;
  5893. }
  5894. else
  5895. {
  5896. if (GUI.Button(new Rect(GetPix(5),
  5897. GetPix(25),
  5898. GetPix(23),
  5899. GetPix(23)),
  5900. "無",
  5901. style3))
  5902. {
  5903. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  5904. maidArray[selectMaidIndex].boMabataki = false;
  5905. morph.EyeMabataki = 0.0f;
  5906. isFaceInit = true;
  5907. isFace[selectMaidIndex] = true;
  5908. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  5909. }
  5910. GUI.enabled = false;
  5911. maidArray[selectMaidIndex].boMabataki = true;
  5912. }
  5913. }
  5914. if (GUI.Button(new Rect(GetPix(5), GetPix(95), GetPix(23), GetPix(23)),
  5915. "<",
  5916. style3))
  5917. {
  5918. --faceIndex[selectMaidIndex];
  5919. if (faceIndex[selectMaidIndex] <= -1)
  5920. {
  5921. faceIndex[selectMaidIndex] = faceComboList.Length - 1;
  5922. }
  5923. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  5924. maidArray[selectMaidIndex].boMabataki = false;
  5925. morph.EyeMabataki = 0.0f;
  5926. if (faceIndex[selectMaidIndex] < faceArray.Length)
  5927. {
  5928. morph.MulBlendValues(faceArray[faceIndex[selectMaidIndex]], 1f);
  5929. }
  5930. else
  5931. {
  5932. float[] fieldValue1 = GetFieldValue<TMorph, float[]>(morph, "BlendValues");
  5933. float[] fieldValue2 = GetFieldValue<TMorph, float[]>(morph, "BlendValuesBackup");
  5934. if (!isVR)
  5935. {
  5936. maidArray[selectMaidIndex].boMabataki = false;
  5937. }
  5938. string[] strArray = faceComboList[faceIndex[selectMaidIndex]].text.Split(':')[2].Split(',');
  5939. fieldValue2[(int)morph.hash["eyeclose"]] = float.Parse(strArray[0]);
  5940. fieldValue2[(int)morph.hash["eyeclose2"]] = float.Parse(strArray[1]);
  5941. fieldValue2[(int)morph.hash["eyeclose3"]] = float.Parse(strArray[2]);
  5942. fieldValue2[(int)morph.hash["eyeclose6"]] = float.Parse(strArray[3]);
  5943. fieldValue1[(int)morph.hash["hitomih"]] = float.Parse(strArray[4]);
  5944. fieldValue1[(int)morph.hash["hitomis"]] = float.Parse(strArray[5]);
  5945. fieldValue1[(int)morph.hash["mayuha"]] = float.Parse(strArray[6]);
  5946. fieldValue1[(int)morph.hash["mayuup"]] = float.Parse(strArray[7]);
  5947. fieldValue1[(int)morph.hash["mayuv"]] = float.Parse(strArray[8]);
  5948. fieldValue1[(int)morph.hash["mayuvhalf"]] = float.Parse(strArray[9]);
  5949. fieldValue1[(int)morph.hash["moutha"]] = float.Parse(strArray[10]);
  5950. fieldValue1[(int)morph.hash["mouths"]] = float.Parse(strArray[11]);
  5951. fieldValue1[(int)morph.hash["mouthdw"]] = float.Parse(strArray[12]);
  5952. fieldValue1[(int)morph.hash["mouthup"]] = float.Parse(strArray[13]);
  5953. fieldValue1[(int)morph.hash["tangout"]] = float.Parse(strArray[14]);
  5954. fieldValue1[(int)morph.hash["tangup"]] = float.Parse(strArray[15]);
  5955. fieldValue1[(int)morph.hash["eyebig"]] = float.Parse(strArray[16]);
  5956. fieldValue2[(int)morph.hash["eyeclose5"]] = float.Parse(strArray[17]);
  5957. fieldValue1[(int)morph.hash["mayuw"]] = float.Parse(strArray[18]);
  5958. fieldValue1[(int)morph.hash["mouthhe"]] = float.Parse(strArray[19]);
  5959. fieldValue1[(int)morph.hash["mouthc"]] = float.Parse(strArray[20]);
  5960. fieldValue1[(int)morph.hash["mouthi"]] = float.Parse(strArray[21]);
  5961. fieldValue1[(int)morph.hash["mouthuphalf"]] = float.Parse(strArray[22]) + 0.01f;
  5962. try
  5963. {
  5964. fieldValue1[(int)morph.hash["tangopen"]] = float.Parse(strArray[23]);
  5965. }
  5966. catch { }
  5967. if (float.Parse(strArray[24]) == 1.0)
  5968. {
  5969. fieldValue1[(int)morph.hash["namida"]] = 1f;
  5970. }
  5971. else
  5972. {
  5973. fieldValue1[(int)morph.hash["namida"]] = 0.0f;
  5974. }
  5975. if (float.Parse(strArray[25]) == 1.0)
  5976. {
  5977. fieldValue1[(int)morph.hash["tear1"]] = 1f;
  5978. }
  5979. else
  5980. {
  5981. fieldValue1[(int)morph.hash["tear1"]] = 0.0f;
  5982. }
  5983. if (float.Parse(strArray[26]) == 1.0)
  5984. {
  5985. fieldValue1[(int)morph.hash["tear2"]] = 1f;
  5986. }
  5987. else
  5988. {
  5989. fieldValue1[(int)morph.hash["tear2"]] = 0.0f;
  5990. }
  5991. if (float.Parse(strArray[27]) == 1.0)
  5992. {
  5993. fieldValue1[(int)morph.hash["tear3"]] = 1f;
  5994. }
  5995. else
  5996. {
  5997. fieldValue1[(int)morph.hash["tear3"]] = 0.0f;
  5998. }
  5999. if (float.Parse(strArray[28]) == 1.0)
  6000. {
  6001. fieldValue1[(int)morph.hash["shock"]] = 1f;
  6002. }
  6003. else
  6004. {
  6005. fieldValue1[(int)morph.hash["shock"]] = 0.0f;
  6006. }
  6007. if (float.Parse(strArray[29]) == 1.0)
  6008. {
  6009. fieldValue1[(int)morph.hash["yodare"]] = 1f;
  6010. }
  6011. else
  6012. {
  6013. fieldValue1[(int)morph.hash["yodare"]] = 0.0f;
  6014. }
  6015. if (float.Parse(strArray[30]) == 1.0)
  6016. {
  6017. fieldValue1[(int)morph.hash["hoho"]] = 0.5f;
  6018. }
  6019. else
  6020. {
  6021. fieldValue1[(int)morph.hash["hoho"]] = 0.0f;
  6022. }
  6023. if (float.Parse(strArray[31]) == 1.0)
  6024. {
  6025. fieldValue1[(int)morph.hash["hoho2"]] = 0.5f;
  6026. }
  6027. else
  6028. {
  6029. fieldValue1[(int)morph.hash["hoho2"]] = 0.0f;
  6030. }
  6031. if (float.Parse(strArray[32]) == 1.0)
  6032. {
  6033. fieldValue1[(int)morph.hash["hohos"]] = 1f;
  6034. }
  6035. else
  6036. {
  6037. fieldValue1[(int)morph.hash["hohos"]] = 0.0f;
  6038. }
  6039. if (float.Parse(strArray[33]) == 1.0)
  6040. {
  6041. fieldValue1[(int)morph.hash["hohol"]] = 1f;
  6042. }
  6043. else
  6044. {
  6045. fieldValue1[(int)morph.hash["hohol"]] = 0.0f;
  6046. }
  6047. if (float.Parse(strArray[34]) == 1.0)
  6048. {
  6049. fieldValue1[(int)morph.hash["toothoff"]] = 1f;
  6050. }
  6051. else
  6052. {
  6053. fieldValue1[(int)morph.hash["toothoff"]] = 0.0f;
  6054. }
  6055. if (strArray.Length > 35)
  6056. {
  6057. morph.boNoseFook = float.Parse(strArray[35]) == 1.0;
  6058. }
  6059. }
  6060. maidArray[selectMaidIndex].body0.Face.morph.FixBlendValues_Face();
  6061. isFaceInit = true;
  6062. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  6063. }
  6064. if (GUI.Button(new Rect(GetPix(135), GetPix(95), GetPix(23), GetPix(23)),
  6065. ">",
  6066. style3))
  6067. {
  6068. ++faceIndex[selectMaidIndex];
  6069. if (faceIndex[selectMaidIndex] == faceComboList.Length)
  6070. {
  6071. faceIndex[selectMaidIndex] = 0;
  6072. }
  6073. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  6074. maidArray[selectMaidIndex].boMabataki = false;
  6075. morph.EyeMabataki = 0.0f;
  6076. if (faceIndex[selectMaidIndex] < faceArray.Length)
  6077. {
  6078. morph.MulBlendValues(faceArray[faceIndex[selectMaidIndex]], 1f);
  6079. }
  6080. else
  6081. {
  6082. float[] fieldValue1 = GetFieldValue<TMorph, float[]>(morph, "BlendValues");
  6083. float[] fieldValue2 = GetFieldValue<TMorph, float[]>(morph, "BlendValuesBackup");
  6084. if (!isVR)
  6085. {
  6086. maidArray[selectMaidIndex].boMabataki = false;
  6087. }
  6088. string[] strArray = faceComboList[faceIndex[selectMaidIndex]].text.Split(':')[2].Split(',');
  6089. fieldValue2[(int)morph.hash["eyeclose"]] = float.Parse(strArray[0]);
  6090. fieldValue2[(int)morph.hash["eyeclose2"]] = float.Parse(strArray[1]);
  6091. fieldValue2[(int)morph.hash["eyeclose3"]] = float.Parse(strArray[2]);
  6092. fieldValue2[(int)morph.hash["eyeclose6"]] = float.Parse(strArray[3]);
  6093. fieldValue1[(int)morph.hash["hitomih"]] = float.Parse(strArray[4]);
  6094. fieldValue1[(int)morph.hash["hitomis"]] = float.Parse(strArray[5]);
  6095. fieldValue1[(int)morph.hash["mayuha"]] = float.Parse(strArray[6]);
  6096. fieldValue1[(int)morph.hash["mayuup"]] = float.Parse(strArray[7]);
  6097. fieldValue1[(int)morph.hash["mayuv"]] = float.Parse(strArray[8]);
  6098. fieldValue1[(int)morph.hash["mayuvhalf"]] = float.Parse(strArray[9]);
  6099. fieldValue1[(int)morph.hash["moutha"]] = float.Parse(strArray[10]);
  6100. fieldValue1[(int)morph.hash["mouths"]] = float.Parse(strArray[11]);
  6101. fieldValue1[(int)morph.hash["mouthdw"]] = float.Parse(strArray[12]);
  6102. fieldValue1[(int)morph.hash["mouthup"]] = float.Parse(strArray[13]);
  6103. fieldValue1[(int)morph.hash["tangout"]] = float.Parse(strArray[14]);
  6104. fieldValue1[(int)morph.hash["tangup"]] = float.Parse(strArray[15]);
  6105. fieldValue1[(int)morph.hash["eyebig"]] = float.Parse(strArray[16]);
  6106. fieldValue2[(int)morph.hash["eyeclose5"]] = float.Parse(strArray[17]);
  6107. fieldValue1[(int)morph.hash["mayuw"]] = float.Parse(strArray[18]);
  6108. fieldValue1[(int)morph.hash["mouthhe"]] = float.Parse(strArray[19]);
  6109. fieldValue1[(int)morph.hash["mouthc"]] = float.Parse(strArray[20]);
  6110. fieldValue1[(int)morph.hash["mouthi"]] = float.Parse(strArray[21]);
  6111. fieldValue1[(int)morph.hash["mouthuphalf"]] = float.Parse(strArray[22]) + 0.01f;
  6112. try
  6113. {
  6114. fieldValue1[(int)morph.hash["tangopen"]] = float.Parse(strArray[23]);
  6115. }
  6116. catch { }
  6117. if (float.Parse(strArray[24]) == 1.0)
  6118. {
  6119. fieldValue1[(int)morph.hash["namida"]] = 1f;
  6120. }
  6121. else
  6122. {
  6123. fieldValue1[(int)morph.hash["namida"]] = 0.0f;
  6124. }
  6125. if (float.Parse(strArray[25]) == 1.0)
  6126. {
  6127. fieldValue1[(int)morph.hash["tear1"]] = 1f;
  6128. }
  6129. else
  6130. {
  6131. fieldValue1[(int)morph.hash["tear1"]] = 0.0f;
  6132. }
  6133. if (float.Parse(strArray[26]) == 1.0)
  6134. {
  6135. fieldValue1[(int)morph.hash["tear2"]] = 1f;
  6136. }
  6137. else
  6138. {
  6139. fieldValue1[(int)morph.hash["tear2"]] = 0.0f;
  6140. }
  6141. if (float.Parse(strArray[27]) == 1.0)
  6142. {
  6143. fieldValue1[(int)morph.hash["tear3"]] = 1f;
  6144. }
  6145. else
  6146. {
  6147. fieldValue1[(int)morph.hash["tear3"]] = 0.0f;
  6148. }
  6149. if (float.Parse(strArray[28]) == 1.0)
  6150. {
  6151. fieldValue1[(int)morph.hash["shock"]] = 1f;
  6152. }
  6153. else
  6154. {
  6155. fieldValue1[(int)morph.hash["shock"]] = 0.0f;
  6156. }
  6157. if (float.Parse(strArray[29]) == 1.0)
  6158. {
  6159. fieldValue1[(int)morph.hash["yodare"]] = 1f;
  6160. }
  6161. else
  6162. {
  6163. fieldValue1[(int)morph.hash["yodare"]] = 0.0f;
  6164. }
  6165. if (float.Parse(strArray[30]) == 1.0)
  6166. {
  6167. fieldValue1[(int)morph.hash["hoho"]] = 0.5f;
  6168. }
  6169. else
  6170. {
  6171. fieldValue1[(int)morph.hash["hoho"]] = 0.0f;
  6172. }
  6173. if (float.Parse(strArray[31]) == 1.0)
  6174. {
  6175. fieldValue1[(int)morph.hash["hoho2"]] = 0.5f;
  6176. }
  6177. else
  6178. {
  6179. fieldValue1[(int)morph.hash["hoho2"]] = 0.0f;
  6180. }
  6181. if (float.Parse(strArray[32]) == 1.0)
  6182. {
  6183. fieldValue1[(int)morph.hash["hohos"]] = 1f;
  6184. }
  6185. else
  6186. {
  6187. fieldValue1[(int)morph.hash["hohos"]] = 0.0f;
  6188. }
  6189. if (float.Parse(strArray[33]) == 1.0)
  6190. {
  6191. fieldValue1[(int)morph.hash["hohol"]] = 1f;
  6192. }
  6193. else
  6194. {
  6195. fieldValue1[(int)morph.hash["hohol"]] = 0.0f;
  6196. }
  6197. if (float.Parse(strArray[34]) == 1.0)
  6198. {
  6199. fieldValue1[(int)morph.hash["toothoff"]] = 1f;
  6200. }
  6201. else
  6202. {
  6203. fieldValue1[(int)morph.hash["toothoff"]] = 0.0f;
  6204. }
  6205. if (strArray.Length > 35)
  6206. {
  6207. morph.boNoseFook = float.Parse(strArray[35]) == 1.0;
  6208. }
  6209. }
  6210. maidArray[selectMaidIndex].body0.Face.morph.FixBlendValues_Face();
  6211. isFaceInit = true;
  6212. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  6213. }
  6214. int offsetTop = GetPix(120);
  6215. int UIHeight = GetPix(510);
  6216. Rect faceWindowScrollRect = new Rect(0, offsetTop, rectWin.width, rectWin.height - offsetTop);
  6217. Rect faceWindowScrollView = new Rect(0, 0, rectWin.width - 20, UIHeight);
  6218. faceScrollPos = GUI.BeginScrollView(faceWindowScrollRect, faceScrollPos, faceWindowScrollView);
  6219. #region face sliders
  6220. int sliderWidth = GetPix(70);
  6221. int sliderHeight = GetPix(20);
  6222. int labelWidth = GetPix(100);
  6223. int labelHeight = GetPix(25);
  6224. int sliderLeft = 8;
  6225. int sliderRight = 88;
  6226. int labelPosition = 0;
  6227. int sliderPosition = 15;
  6228. int sliderOffset = 28;
  6229. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition),
  6230. labelWidth, labelHeight),
  6231. "目の開閉",
  6232. style2);
  6233. eyeclose = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6234. GetPix(sliderPosition),
  6235. sliderWidth, sliderHeight),
  6236. eyeclose,
  6237. 0.0f,
  6238. 1f);
  6239. GUI.Label(new Rect(GetPix(sliderRight), GetPix(labelPosition),
  6240. labelWidth, labelHeight),
  6241. "にっこり",
  6242. style2);
  6243. eyeclose2 = GUI.HorizontalSlider(new Rect(GetPix(sliderRight),
  6244. GetPix(sliderPosition),
  6245. sliderWidth, sliderHeight),
  6246. eyeclose2,
  6247. 0.0f,
  6248. 1f);
  6249. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset),
  6250. labelWidth, labelHeight),
  6251. "ジト目",
  6252. style2);
  6253. eyeclose3 = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6254. GetPix(sliderPosition + sliderOffset),
  6255. sliderWidth, sliderHeight),
  6256. eyeclose3,
  6257. 0.0f,
  6258. 1f);
  6259. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset),
  6260. labelWidth, labelHeight),
  6261. "見開く",
  6262. style2);
  6263. eyebig = GUI.HorizontalSlider(new Rect(GetPix(88),
  6264. GetPix(sliderPosition + sliderOffset),
  6265. sliderWidth, sliderHeight),
  6266. eyebig,
  6267. 0.0f,
  6268. 1f);
  6269. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 2),
  6270. labelWidth, labelHeight),
  6271. "ウインク1",
  6272. style2);
  6273. eyeclose6 = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6274. GetPix(sliderPosition + sliderOffset * 2),
  6275. sliderWidth, sliderHeight),
  6276. eyeclose6,
  6277. 0.0f,
  6278. 1f);
  6279. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 2),
  6280. labelWidth, labelHeight),
  6281. "ウインク2",
  6282. style2);
  6283. eyeclose5 = GUI.HorizontalSlider(new Rect(GetPix(88),
  6284. GetPix(sliderPosition + sliderOffset * 2),
  6285. sliderWidth, sliderHeight),
  6286. eyeclose5,
  6287. 0.0f,
  6288. 1f);
  6289. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 3),
  6290. labelWidth, labelHeight),
  6291. "ハイライト",
  6292. style2);
  6293. hitomih = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6294. GetPix(sliderPosition + sliderOffset * 3),
  6295. sliderWidth, sliderHeight),
  6296. hitomih,
  6297. 0.0f,
  6298. 2f);
  6299. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 3),
  6300. labelWidth, labelHeight),
  6301. "瞳サイズ",
  6302. style2);
  6303. hitomis = GUI.HorizontalSlider(new Rect(GetPix(88),
  6304. GetPix(sliderPosition + sliderOffset * 3),
  6305. sliderWidth, sliderHeight),
  6306. hitomis,
  6307. 0.0f,
  6308. 1f);
  6309. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 4),
  6310. labelWidth, labelHeight),
  6311. "眉角度1",
  6312. style2);
  6313. mayuha = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6314. GetPix(sliderPosition + sliderOffset * 4),
  6315. sliderWidth, sliderHeight),
  6316. mayuha,
  6317. 0.0f,
  6318. 1f);
  6319. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 4),
  6320. labelWidth, labelHeight),
  6321. "眉角度2",
  6322. style2);
  6323. mayuw = GUI.HorizontalSlider(new Rect(GetPix(88),
  6324. GetPix(sliderPosition + sliderOffset * 4),
  6325. sliderWidth, sliderHeight),
  6326. mayuw,
  6327. 0.0f,
  6328. 1f);
  6329. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 5),
  6330. labelWidth, labelHeight),
  6331. "眉上げ",
  6332. style2);
  6333. mayuup = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6334. GetPix(sliderPosition + sliderOffset * 5),
  6335. sliderWidth, sliderHeight),
  6336. mayuup,
  6337. 0.0f,
  6338. 0.8f);
  6339. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 5),
  6340. labelWidth, labelHeight),
  6341. "眉下げ1",
  6342. style2);
  6343. mayuv = GUI.HorizontalSlider(new Rect(GetPix(88),
  6344. GetPix(sliderPosition + sliderOffset * 5),
  6345. sliderWidth, sliderHeight),
  6346. mayuv,
  6347. 0.0f,
  6348. 0.8f);
  6349. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 6),
  6350. labelWidth, labelHeight),
  6351. "眉下げ2",
  6352. style2);
  6353. mayuvhalf = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6354. GetPix(sliderPosition + sliderOffset * 6),
  6355. sliderWidth, sliderHeight),
  6356. mayuvhalf,
  6357. 0.0f,
  6358. 0.9f);
  6359. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 7),
  6360. labelWidth, labelHeight),
  6361. "口開け1",
  6362. style2);
  6363. moutha = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6364. GetPix(sliderPosition + sliderOffset * 7),
  6365. sliderWidth, sliderHeight),
  6366. moutha,
  6367. 0.0f,
  6368. 1f);
  6369. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 7),
  6370. labelWidth, labelHeight),
  6371. "口開け2",
  6372. style2);
  6373. mouths = GUI.HorizontalSlider(new Rect(GetPix(88),
  6374. GetPix(sliderPosition + sliderOffset * 7),
  6375. sliderWidth, sliderHeight),
  6376. mouths,
  6377. 0.0f,
  6378. 0.9f);
  6379. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 8),
  6380. labelWidth, labelHeight),
  6381. "口幅狭く",
  6382. style2);
  6383. mouthc = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6384. GetPix(sliderPosition + sliderOffset * 8),
  6385. sliderWidth, sliderHeight),
  6386. mouthc,
  6387. 0.0f,
  6388. 1f);
  6389. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 8),
  6390. labelWidth, labelHeight),
  6391. "口幅広く",
  6392. style2);
  6393. mouthi = GUI.HorizontalSlider(new Rect(GetPix(88),
  6394. GetPix(sliderPosition + sliderOffset * 8),
  6395. sliderWidth, sliderHeight),
  6396. mouthi,
  6397. 0.0f,
  6398. 1f);
  6399. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 9),
  6400. labelWidth, labelHeight),
  6401. "口角上げ",
  6402. style2);
  6403. mouthup = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6404. GetPix(sliderPosition + sliderOffset * 9),
  6405. sliderWidth, sliderHeight),
  6406. mouthup,
  6407. 0.0f,
  6408. 1.4f);
  6409. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 9),
  6410. labelWidth, labelHeight),
  6411. "口角下げ",
  6412. style2);
  6413. mouthdw = GUI.HorizontalSlider(new Rect(GetPix(88),
  6414. GetPix(sliderPosition + sliderOffset * 9),
  6415. sliderWidth, sliderHeight),
  6416. mouthdw,
  6417. 0.0f,
  6418. 1f);
  6419. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 10),
  6420. labelWidth, labelHeight),
  6421. "口中央上げ",
  6422. style2);
  6423. mouthhe = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6424. GetPix(sliderPosition + sliderOffset * 10),
  6425. sliderWidth, sliderHeight),
  6426. mouthhe,
  6427. 0.0f,
  6428. 1f);
  6429. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 10),
  6430. labelWidth, labelHeight),
  6431. "左口角上げ",
  6432. style2);
  6433. mouthuphalf = GUI.HorizontalSlider(new Rect(GetPix(88),
  6434. GetPix(sliderPosition + sliderOffset * 10),
  6435. sliderWidth, sliderHeight),
  6436. mouthuphalf,
  6437. 0.0f,
  6438. 2f);
  6439. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 11),
  6440. labelWidth, labelHeight),
  6441. "舌出し",
  6442. style2);
  6443. tangout = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6444. GetPix(sliderPosition + sliderOffset * 11),
  6445. sliderWidth, sliderHeight),
  6446. tangout,
  6447. 0.0f,
  6448. 1f);
  6449. GUI.Label(new Rect(GetPix(88), GetPix(labelPosition + sliderOffset * 11),
  6450. labelWidth, labelHeight),
  6451. "舌上げ",
  6452. style2);
  6453. tangup = GUI.HorizontalSlider(new Rect(GetPix(88),
  6454. GetPix(sliderPosition + sliderOffset * 11),
  6455. sliderWidth, sliderHeight),
  6456. tangup,
  6457. 0.0f,
  6458. 0.7f);
  6459. GUI.Label(new Rect(GetPix(sliderLeft), GetPix(labelPosition + sliderOffset * 12),
  6460. labelWidth, labelHeight),
  6461. "舌根上げ",
  6462. style2);
  6463. tangopen = GUI.HorizontalSlider(new Rect(GetPix(sliderLeft),
  6464. GetPix(sliderPosition + sliderOffset * 12),
  6465. sliderWidth, sliderHeight),
  6466. tangopen,
  6467. 0.0f,
  6468. 1f);
  6469. #endregion
  6470. #region face toggles
  6471. int togglePositionX = 5;
  6472. int togglePositionY = 370;
  6473. int toggleOffsetX = 55;
  6474. int toggleOffsetY = 22;
  6475. int toggleWidth = GetPix(55);
  6476. int toggleHeight = GetPix(16);
  6477. isHoho2 = GUI.Toggle(new Rect(GetPix(togglePositionX),
  6478. GetPix(togglePositionY),
  6479. toggleWidth, toggleHeight),
  6480. isHoho2,
  6481. "赤面",
  6482. style4);
  6483. isShock = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 1),
  6484. GetPix(togglePositionY),
  6485. toggleWidth, toggleHeight),
  6486. isShock,
  6487. "ショック",
  6488. style4);
  6489. isNosefook = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 2),
  6490. GetPix(togglePositionY),
  6491. toggleWidth, toggleHeight),
  6492. isNosefook,
  6493. "鼻フック",
  6494. style4);
  6495. isNamida = GUI.Toggle(new Rect(GetPix(togglePositionX),
  6496. GetPix(togglePositionY + toggleOffsetY * 1),
  6497. toggleWidth, toggleHeight),
  6498. isNamida,
  6499. "涙",
  6500. style4);
  6501. isYodare = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 1),
  6502. GetPix(togglePositionY + toggleOffsetY * 1),
  6503. toggleWidth, toggleHeight),
  6504. isYodare,
  6505. "涎",
  6506. style4);
  6507. isToothoff = !GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 2),
  6508. GetPix(togglePositionY + toggleOffsetY * 1),
  6509. toggleWidth, toggleHeight),
  6510. !isToothoff,
  6511. "歯",
  6512. style4);
  6513. isTear1 = GUI.Toggle(new Rect(GetPix(togglePositionX),
  6514. GetPix(togglePositionY + toggleOffsetY * 2),
  6515. toggleWidth, toggleHeight),
  6516. isTear1,
  6517. "涙1",
  6518. style4);
  6519. isTear2 = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 1),
  6520. GetPix(togglePositionY + toggleOffsetY * 2),
  6521. toggleWidth, toggleHeight),
  6522. isTear2,
  6523. "涙2",
  6524. style4);
  6525. isTear3 = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 2),
  6526. GetPix(togglePositionY + toggleOffsetY * 2),
  6527. toggleWidth, toggleHeight),
  6528. isTear3,
  6529. "涙3",
  6530. style4);
  6531. isHohos = GUI.Toggle(new Rect(GetPix(togglePositionX),
  6532. GetPix(togglePositionY + toggleOffsetY * 3),
  6533. toggleWidth, toggleHeight),
  6534. isHohos,
  6535. "頬1",
  6536. style4);
  6537. isHoho = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 1),
  6538. GetPix(togglePositionY + toggleOffsetY * 3),
  6539. toggleWidth, toggleHeight),
  6540. isHoho,
  6541. "頬2",
  6542. style4);
  6543. isHohol = GUI.Toggle(new Rect(GetPix(togglePositionX + toggleOffsetX * 2),
  6544. GetPix(togglePositionY + toggleOffsetY * 3),
  6545. toggleWidth, toggleHeight),
  6546. isHohol,
  6547. "頬3",
  6548. style4);
  6549. #endregion
  6550. int faceSaveToggleY = togglePositionY + toggleOffsetY * 4;
  6551. int faceSaveInputY = faceSaveToggleY + 20;
  6552. isFaceEdit = GUI.Toggle(new Rect(GetPix(5),
  6553. GetPix(faceSaveToggleY),
  6554. toggleWidth, toggleHeight),
  6555. isFaceEdit,
  6556. "登録",
  6557. style4);
  6558. if (isFaceEdit)
  6559. {
  6560. inName4 = GUI.TextField(new Rect(GetPix(5),
  6561. GetPix(faceSaveInputY),
  6562. GetPix(100),
  6563. GetPix(20)),
  6564. inName4);
  6565. if (GUI.Button(new Rect(GetPix(107),
  6566. GetPix(faceSaveInputY),
  6567. GetPix(35),
  6568. GetPix(20)),
  6569. "追加",
  6570. style3))
  6571. {
  6572. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  6573. GUI.FocusControl("");
  6574. int num2 = 1;
  6575. for (int index = 1; index < 1000; ++index)
  6576. {
  6577. if (Preferences["face"]["f" + index].Value == null)
  6578. {
  6579. num2 = index;
  6580. break;
  6581. }
  6582. }
  6583. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  6584. float[] fieldValue1 = GetFieldValue<TMorph, float[]>(morph, "BlendValues");
  6585. float[] fieldValue2 = GetFieldValue<TMorph, float[]>(morph, "BlendValuesBackup");
  6586. string str1 = inName4 + ":" + fieldValue2[(int)morph.hash["eyeclose"]] + ","
  6587. + fieldValue2[(int)morph.hash["eyeclose2"]] + ","
  6588. + fieldValue2[(int)morph.hash["eyeclose3"]] + ","
  6589. + fieldValue2[(int)morph.hash["eyeclose6"]] + ","
  6590. + fieldValue1[(int)morph.hash["hitomih"]] + ","
  6591. + fieldValue1[(int)morph.hash["hitomis"]] + ","
  6592. + fieldValue1[(int)morph.hash["mayuha"]] + ","
  6593. + fieldValue1[(int)morph.hash["mayuup"]] + ","
  6594. + fieldValue1[(int)morph.hash["mayuv"]] + ","
  6595. + fieldValue1[(int)morph.hash["mayuvhalf"]] + ","
  6596. + fieldValue1[(int)morph.hash["moutha"]] + ","
  6597. + fieldValue1[(int)morph.hash["mouths"]] + ","
  6598. + fieldValue1[(int)morph.hash["mouthdw"]] + ","
  6599. + fieldValue1[(int)morph.hash["mouthup"]] + ","
  6600. + fieldValue1[(int)morph.hash["tangout"]] + ","
  6601. + fieldValue1[(int)morph.hash["tangup"]] + ","
  6602. + fieldValue1[(int)morph.hash["eyebig"]] + ","
  6603. + fieldValue2[(int)morph.hash["eyeclose5"]] + ","
  6604. + fieldValue1[(int)morph.hash["mayuw"]] + ","
  6605. + fieldValue1[(int)morph.hash["mouthhe"]] + ","
  6606. + fieldValue1[(int)morph.hash["mouthc"]] + ","
  6607. + fieldValue1[(int)morph.hash["mouthi"]] + ","
  6608. + fieldValue1[(int)morph.hash["mouthuphalf"]] + ",";
  6609. string str2;
  6610. try
  6611. {
  6612. str2 = str1 + fieldValue1[(int)morph.hash["tangopen"]] + ",";
  6613. }
  6614. catch
  6615. {
  6616. str2 = str1 + "0,";
  6617. }
  6618. string str3 = fieldValue1[(int)morph.hash["namida"]] <= 0.0
  6619. ? str2 + 0 + ","
  6620. : str2 + 1 + ",";
  6621. string str4 = fieldValue1[(int)morph.hash["tear1"]] <= 0.0
  6622. ? str3 + 0 + ","
  6623. : str3 + 1 + ",";
  6624. string str5 = fieldValue1[(int)morph.hash["tear2"]] <= 0.0
  6625. ? str4 + 0 + ","
  6626. : str4 + 1 + ",";
  6627. string str6 = fieldValue1[(int)morph.hash["tear3"]] <= 0.0
  6628. ? str5 + 0 + ","
  6629. : str5 + 1 + ",";
  6630. string str7 = fieldValue1[(int)morph.hash["shock"]] <= 0.0
  6631. ? str6 + 0 + ","
  6632. : str6 + 1 + ",";
  6633. string str8 = fieldValue1[(int)morph.hash["yodare"]] <= 0.0
  6634. ? str7 + 0 + ","
  6635. : str7 + 1 + ",";
  6636. string str9 = fieldValue1[(int)morph.hash["hoho"]] <= 0.0
  6637. ? str8 + 0 + ","
  6638. : str8 + 1 + ",";
  6639. string str10 = fieldValue1[(int)morph.hash["hoho2"]] <= 0.0
  6640. ? str9 + 0 + ","
  6641. : str9 + 1 + ",";
  6642. string str11 = fieldValue1[(int)morph.hash["hohos"]] <= 0.0
  6643. ? str10 + 0 + ","
  6644. : str10 + 1 + ",";
  6645. string str12 = fieldValue1[(int)morph.hash["hohol"]] <= 0.0
  6646. ? str11 + 0 + ","
  6647. : str11 + 1 + ",";
  6648. string str13 = fieldValue1[(int)morph.hash["toothoff"]] <= 0.0
  6649. ? str12 + 0 + ","
  6650. : str12 + 1 + ",";
  6651. string str14 = fieldValue1[(int)morph.hash["nosefook"]] <= 0.0
  6652. ? str13 + 0 + ":"
  6653. : str13 + 1 + ":";
  6654. Preferences["face"]["f" + num2].Value = str14;
  6655. SaveConfig();
  6656. List<string> stringList = new List<string>(300);
  6657. stringList.AddRange(faceArray);
  6658. for (int index = 1; index < 300; ++index)
  6659. {
  6660. IniKey iniKey = Preferences["face"]["f" + index];
  6661. if (iniKey.Value != null)
  6662. {
  6663. string[] strArray = iniKey.Value.Split(':');
  6664. if (strArray.Length > 1)
  6665. {
  6666. stringList.Add(strArray[0] + "               :" + index + ":" + strArray[1]);
  6667. }
  6668. }
  6669. else
  6670. {
  6671. break;
  6672. }
  6673. }
  6674. faceCombo.selectedItemIndex = 0;
  6675. faceComboList = new GUIContent[stringList.ToArray().Length];
  6676. for (int index = 0; index < stringList.ToArray().Length; ++index)
  6677. {
  6678. faceComboList[index] = new GUIContent(stringList.ToArray()[index]);
  6679. }
  6680. faceCombo.selectedItemIndex = stringList.ToArray().Length - 1;
  6681. inName4 = "";
  6682. }
  6683. if (faceIndex[selectMaidIndex] < faceArray.Length)
  6684. {
  6685. GUI.enabled = false;
  6686. }
  6687. if (GUI.Button(new Rect(GetPix(144),
  6688. GetPix(faceSaveInputY),
  6689. GetPix(24),
  6690. GetPix(20)),
  6691. "削",
  6692. style3))
  6693. {
  6694. GameMain.Instance.SoundMgr.PlaySe("se002.ogg", false);
  6695. Preferences["face"]["f" + faceComboList[faceIndex[selectMaidIndex]].text.Split(':')[1]].Value = "del";
  6696. SaveConfig();
  6697. List<string> stringList = new List<string>(300);
  6698. stringList.AddRange(faceArray);
  6699. for (int index = 1; index < 300; ++index)
  6700. {
  6701. IniKey iniKey = Preferences["face"]["f" + index];
  6702. if (iniKey.Value != null)
  6703. {
  6704. string[] strArray = iniKey.Value.Split(':');
  6705. if (strArray.Length > 1)
  6706. {
  6707. stringList.Add(strArray[0] + "               :" + index + ":" + strArray[1]);
  6708. }
  6709. }
  6710. else
  6711. {
  6712. break;
  6713. }
  6714. }
  6715. faceCombo.selectedItemIndex = 0;
  6716. faceComboList = new GUIContent[stringList.ToArray().Length];
  6717. for (int index = 0; index < stringList.ToArray().Length; ++index)
  6718. {
  6719. faceComboList[index] = new GUIContent(stringList.ToArray()[index]);
  6720. }
  6721. faceCombo.selectedItemIndex = 0;
  6722. for (int index = 0; index < maidCnt; ++index)
  6723. {
  6724. if (maidArray[index] && maidArray[index].Visible
  6725. && stringList.ToArray().Length <= faceIndex[index])
  6726. {
  6727. faceIndex[index] = 0;
  6728. }
  6729. }
  6730. }
  6731. GUI.enabled = true;
  6732. }
  6733. GUI.EndScrollView();
  6734. if (faceCombo.isClickedComboButton)
  6735. {
  6736. GUI.enabled = true;
  6737. }
  6738. if (isFace[selectMaidIndex])
  6739. {
  6740. faceIndex[selectMaidIndex] =
  6741. faceCombo.List(new Rect(GetPix(35),
  6742. GetPix(95),
  6743. GetPix(95),
  6744. GetPix(23)),
  6745. faceComboList[faceIndex[selectMaidIndex]].text,
  6746. faceComboList,
  6747. buttonStyle,
  6748. "box",
  6749. listStyle2);
  6750. }
  6751. else
  6752. {
  6753. faceCombo.List(new Rect(GetPix(35), GetPix(95), GetPix(95), GetPix(23)),
  6754. faceComboList[faceIndex[selectMaidIndex]].text,
  6755. faceComboList,
  6756. buttonStyle,
  6757. "box",
  6758. listStyle2);
  6759. }
  6760. if (faceCombo.isClickedComboButton)
  6761. {
  6762. isCombo = true;
  6763. }
  6764. else if (isCombo)
  6765. {
  6766. isCombo = false;
  6767. TMorph morph = maidArray[selectMaidIndex].body0.Face.morph;
  6768. float[] fieldValue1 = GetFieldValue<TMorph, float[]>(morph, "BlendValues");
  6769. morph.EyeMabataki = 0.0f;
  6770. if (faceIndex[selectMaidIndex] < faceArray.Length)
  6771. {
  6772. morph.MulBlendValues(faceArray[faceIndex[selectMaidIndex]], 1f);
  6773. }
  6774. else
  6775. {
  6776. float[] fieldValue2 = GetFieldValue<TMorph, float[]>(morph, "BlendValuesBackup");
  6777. if (!isVR)
  6778. {
  6779. maidArray[selectMaidIndex].boMabataki = false;
  6780. }
  6781. string[] strArray = faceComboList[faceIndex[selectMaidIndex]].text.Split(':')[2].Split(',');
  6782. fieldValue2[(int)morph.hash["eyeclose"]] = float.Parse(strArray[0]);
  6783. fieldValue2[(int)morph.hash["eyeclose2"]] = float.Parse(strArray[1]);
  6784. fieldValue2[(int)morph.hash["eyeclose3"]] = float.Parse(strArray[2]);
  6785. fieldValue2[(int)morph.hash["eyeclose6"]] = float.Parse(strArray[3]);
  6786. fieldValue1[(int)morph.hash["hitomih"]] = float.Parse(strArray[4]);
  6787. fieldValue1[(int)morph.hash["hitomis"]] = float.Parse(strArray[5]);
  6788. fieldValue1[(int)morph.hash["mayuha"]] = float.Parse(strArray[6]);
  6789. fieldValue1[(int)morph.hash["mayuup"]] = float.Parse(strArray[7]);
  6790. fieldValue1[(int)morph.hash["mayuv"]] = float.Parse(strArray[8]);
  6791. fieldValue1[(int)morph.hash["mayuvhalf"]] = float.Parse(strArray[9]);
  6792. fieldValue1[(int)morph.hash["moutha"]] = float.Parse(strArray[10]);
  6793. fieldValue1[(int)morph.hash["mouths"]] = float.Parse(strArray[11]);
  6794. fieldValue1[(int)morph.hash["mouthdw"]] = float.Parse(strArray[12]);
  6795. fieldValue1[(int)morph.hash["mouthup"]] = float.Parse(strArray[13]);
  6796. fieldValue1[(int)morph.hash["tangout"]] = float.Parse(strArray[14]);
  6797. fieldValue1[(int)morph.hash["tangup"]] = float.Parse(strArray[15]);
  6798. fieldValue1[(int)morph.hash["eyebig"]] = float.Parse(strArray[16]);
  6799. fieldValue2[(int)morph.hash["eyeclose5"]] = float.Parse(strArray[17]);
  6800. fieldValue1[(int)morph.hash["mayuw"]] = float.Parse(strArray[18]);
  6801. fieldValue1[(int)morph.hash["mouthhe"]] = float.Parse(strArray[19]);
  6802. fieldValue1[(int)morph.hash["mouthc"]] = float.Parse(strArray[20]);
  6803. fieldValue1[(int)morph.hash["mouthi"]] = float.Parse(strArray[21]);
  6804. fieldValue1[(int)morph.hash["mouthuphalf"]] = float.Parse(strArray[22]) + 0.01f;
  6805. try
  6806. {
  6807. fieldValue1[(int)morph.hash["tangopen"]] = float.Parse(strArray[23]);
  6808. }
  6809. catch { }
  6810. if (float.Parse(strArray[24]) == 1.0)
  6811. {
  6812. fieldValue1[(int)morph.hash["namida"]] = 1f;
  6813. }
  6814. else
  6815. {
  6816. fieldValue1[(int)morph.hash["namida"]] = 0.0f;
  6817. }
  6818. if (float.Parse(strArray[25]) == 1.0)
  6819. {
  6820. fieldValue1[(int)morph.hash["tear1"]] = 1f;
  6821. }
  6822. else
  6823. {
  6824. fieldValue1[(int)morph.hash["tear1"]] = 0.0f;
  6825. }
  6826. if (float.Parse(strArray[26]) == 1.0)
  6827. {
  6828. fieldValue1[(int)morph.hash["tear2"]] = 1f;
  6829. }
  6830. else
  6831. {
  6832. fieldValue1[(int)morph.hash["tear2"]] = 0.0f;
  6833. }
  6834. if (float.Parse(strArray[27]) == 1.0)
  6835. {
  6836. fieldValue1[(int)morph.hash["tear3"]] = 1f;
  6837. }
  6838. else
  6839. {
  6840. fieldValue1[(int)morph.hash["tear3"]] = 0.0f;
  6841. }
  6842. if (float.Parse(strArray[28]) == 1.0)
  6843. {
  6844. fieldValue1[(int)morph.hash["shock"]] = 1f;
  6845. }
  6846. else
  6847. {
  6848. fieldValue1[(int)morph.hash["shock"]] = 0.0f;
  6849. }
  6850. if (float.Parse(strArray[29]) == 1.0)
  6851. {
  6852. fieldValue1[(int)morph.hash["yodare"]] = 1f;
  6853. }
  6854. else
  6855. {
  6856. fieldValue1[(int)morph.hash["yodare"]] = 0.0f;
  6857. }
  6858. if (float.Parse(strArray[30]) == 1.0)
  6859. {
  6860. fieldValue1[(int)morph.hash["hoho"]] = 0.5f;
  6861. }
  6862. else
  6863. {
  6864. fieldValue1[(int)morph.hash["hoho"]] = 0.0f;
  6865. }
  6866. if (float.Parse(strArray[31]) == 1.0)
  6867. {
  6868. fieldValue1[(int)morph.hash["hoho2"]] = 0.5f;
  6869. }
  6870. else
  6871. {
  6872. fieldValue1[(int)morph.hash["hoho2"]] = 0.0f;
  6873. }
  6874. if (float.Parse(strArray[32]) == 1.0)
  6875. {
  6876. fieldValue1[(int)morph.hash["hohos"]] = 1f;
  6877. }
  6878. else
  6879. {
  6880. fieldValue1[(int)morph.hash["hohos"]] = 0.0f;
  6881. }
  6882. if (float.Parse(strArray[33]) == 1.0)
  6883. {
  6884. fieldValue1[(int)morph.hash["hohol"]] = 1f;
  6885. }
  6886. else
  6887. {
  6888. fieldValue1[(int)morph.hash["hohol"]] = 0.0f;
  6889. }
  6890. if (float.Parse(strArray[34]) == 1.0)
  6891. {
  6892. fieldValue1[(int)morph.hash["toothoff"]] = 1f;
  6893. }
  6894. else
  6895. {
  6896. fieldValue1[(int)morph.hash["toothoff"]] = 0.0f;
  6897. }
  6898. if (strArray.Length > 35)
  6899. {
  6900. morph.boNoseFook = float.Parse(strArray[35]) == 1.0;
  6901. }
  6902. }
  6903. maidArray[selectMaidIndex].body0.Face.morph.FixBlendValues_Face();
  6904. isFaceInit = true;
  6905. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  6906. }
  6907. GUI.enabled = !faceCombo.isClickedComboButton;
  6908. bool state = GUI.enabled;
  6909. GUI.enabled = true;
  6910. GUI.DragWindow();
  6911. GUI.enabled = state;
  6912. yotogiFlg = false;
  6913. if (sceneLevel != 14
  6914. || !GameObject
  6915. .Find("/UI Root/YotogiPlayPanel/CommandViewer/SkillViewer/MaskGroup/SkillGroup/CommandParent/CommandUnit"))
  6916. {
  6917. return;
  6918. }
  6919. yotogiFlg = true;
  6920. }
  6921. private void MaidCallWindow(int winID)
  6922. {
  6923. CharacterMgr characterMgr = GameMain.Instance.CharacterMgr;
  6924. GUIStyle style1 = "label";
  6925. style1.fontSize = GetPix(14);
  6926. style1.alignment = TextAnchor.UpperLeft;
  6927. GUIStyle style2 = "button";
  6928. style2.fontSize = GetPix(16);
  6929. style2.alignment = TextAnchor.MiddleCenter;
  6930. GUIStyle style3 = new GUIStyle("toggle")
  6931. {
  6932. fontSize = GetPix(13)
  6933. };
  6934. float pix = GetPix(70);
  6935. if (comboBoxList == null)
  6936. {
  6937. comboBoxControl.selectedItemIndex = 0;
  6938. comboBoxList = new GUIContent[11];
  6939. comboBoxList[0] = new GUIContent("通常");
  6940. comboBoxList[1] = new GUIContent("横一列");
  6941. comboBoxList[2] = new GUIContent("縦一列");
  6942. comboBoxList[3] = new GUIContent("斜め");
  6943. comboBoxList[4] = new GUIContent("円(外向き)");
  6944. comboBoxList[5] = new GUIContent("円(内向き)");
  6945. comboBoxList[6] = new GUIContent("扇");
  6946. comboBoxList[7] = new GUIContent("V");
  6947. comboBoxList[8] = new GUIContent("^");
  6948. comboBoxList[9] = new GUIContent("M");
  6949. comboBoxList[10] = new GUIContent("W");
  6950. }
  6951. bool flag1 = true;
  6952. if (faceFlg || poseFlg || sceneFlg || kankyoFlg || kankyo2Flg)
  6953. {
  6954. flag1 = false;
  6955. }
  6956. if (!isF6 && GUI.Toggle(new Rect(GetPix(2),
  6957. GetPix(2),
  6958. GetPix(39),
  6959. GetPix(20)),
  6960. flag1,
  6961. "配置",
  6962. style3))
  6963. {
  6964. faceFlg = false;
  6965. poseFlg = false;
  6966. sceneFlg = false;
  6967. kankyoFlg = false;
  6968. kankyo2Flg = false;
  6969. bGui = true;
  6970. }
  6971. if (!yotogiFlg && GUI.Toggle(new Rect(GetPix(41),
  6972. GetPix(2),
  6973. GetPix(39),
  6974. GetPix(20)),
  6975. poseFlg,
  6976. "操作",
  6977. style3))
  6978. {
  6979. poseFlg = true;
  6980. faceFlg = false;
  6981. sceneFlg = false;
  6982. kankyoFlg = false;
  6983. kankyo2Flg = false;
  6984. }
  6985. if (GUI.Toggle(new Rect(GetPix(80), GetPix(2), GetPix(39), GetPix(20)),
  6986. faceFlg,
  6987. "表情",
  6988. style3))
  6989. {
  6990. faceFlg = true;
  6991. poseFlg = false;
  6992. sceneFlg = false;
  6993. kankyoFlg = false;
  6994. kankyo2Flg = false;
  6995. if (!faceFlg2)
  6996. {
  6997. isFaceInit = true;
  6998. faceFlg2 = true;
  6999. maidArray[selectMaidIndex].boMabataki = false;
  7000. faceCombo.selectedItemIndex = faceIndex[selectMaidIndex];
  7001. }
  7002. }
  7003. if (GUI.Toggle(new Rect(GetPix(119), GetPix(2), GetPix(39), GetPix(20)),
  7004. kankyoFlg,
  7005. "環境",
  7006. style3))
  7007. {
  7008. poseFlg = false;
  7009. faceFlg = false;
  7010. sceneFlg = false;
  7011. kankyoFlg = true;
  7012. kankyo2Flg = false;
  7013. }
  7014. if (!line1)
  7015. {
  7016. line1 = MakeTex(2, 2, new Color(0.0f, 0.0f, 0.0f, 0.3f));
  7017. line2 = MakeTex(2, 2, new Color(0.7f, 0.7f, 0.7f, 0.6f));
  7018. }
  7019. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 2f), line1);
  7020. GUI.DrawTexture(new Rect(GetPix(5), GetPix(20), GetPix(160), 1f), line2);
  7021. int stockMaidCount1 = characterMgr.GetStockMaidCount();
  7022. Rect position;
  7023. Rect viewRect;
  7024. if (sceneLevel != 5)
  7025. {
  7026. position = new Rect(GetPix(7),
  7027. GetPix(110),
  7028. rectWin.width - GetPix(14),
  7029. rectWin.height * 0.83f);
  7030. viewRect = new Rect(0.0f,
  7031. 0.0f,
  7032. position.width * 0.85f,
  7033. (pix + GetPix(5)) * stockMaidCount1 + GetPix(15));
  7034. }
  7035. else
  7036. {
  7037. position = new Rect(GetPix(7),
  7038. GetPix(110),
  7039. rectWin.width - GetPix(14),
  7040. (float)(rectWin.height * 0.829999983310699 * 0.980000019073486));
  7041. viewRect = new Rect(0.0f,
  7042. 0.0f,
  7043. position.width * 0.85f,
  7044. (float)((pix + (double)GetPix(5)) * stockMaidCount1
  7045. + GetPix(15) * 0.920000016689301));
  7046. }
  7047. float y = 0.0f;
  7048. if (comboBoxControl.isClickedComboButton)
  7049. {
  7050. GUI.enabled = false;
  7051. }
  7052. if (GUI.Button(new Rect(GetPix(10), GetPix(78), rectWin.width * 0.85f, GetPix(28)),
  7053. "呼び出す",
  7054. style2))
  7055. {
  7056. isYobidashi = true;
  7057. selectMaidIndex = 0;
  7058. copyIndex = 0;
  7059. for (int index = 0; index < maxMaidCnt; ++index)
  7060. {
  7061. if (!isLock[index] && maidArray[index] && maidArray[index].Visible)
  7062. {
  7063. maidArray[index].CrossFade(poseArray[0] + ".anm", false, true, false, 0.0f, 1f);
  7064. maidArray[index].SetAutoTwistAll(true);
  7065. }
  7066. maidArray[index] = null;
  7067. }
  7068. for (int index = 0; index < maxMaidCnt; ++index)
  7069. {
  7070. isStop[index] = false;
  7071. }
  7072. bGui = false;
  7073. isFadeOut = true;
  7074. GameMain.Instance.MainCamera.FadeOut(0.0f, false, null, true, new Color());
  7075. for (int index = 0; index < characterMgr.GetStockMaidCount(); ++index)
  7076. {
  7077. characterMgr.GetStockMaidList()[index].Visible = false;
  7078. }
  7079. }
  7080. GUIStyle style4 = "button";
  7081. style4.fontSize = GetPix(13);
  7082. GUIStyleState guiStyleState = new GUIStyleState();
  7083. if (GUI.Button(new Rect(GetPix(10), GetPix(52), rectWin.width * 0.4f, GetPix(23)),
  7084. "7人選択",
  7085. style4))
  7086. {
  7087. if (sceneLevel != 5)
  7088. {
  7089. selectList = new ArrayList
  7090. {
  7091. 0,
  7092. 1,
  7093. 2,
  7094. 3,
  7095. 4,
  7096. 5,
  7097. 6
  7098. };
  7099. }
  7100. else
  7101. {
  7102. int stockMaidCount2 = characterMgr.GetStockMaidCount();
  7103. selectList = new ArrayList
  7104. {
  7105. editMaid
  7106. };
  7107. if (stockMaidCount2 > 1)
  7108. {
  7109. if (editMaid >= 1)
  7110. {
  7111. selectList.Add(0);
  7112. }
  7113. else if (stockMaidCount2 > 2)
  7114. {
  7115. selectList.Add(1);
  7116. }
  7117. }
  7118. if (stockMaidCount2 > 2)
  7119. {
  7120. if (editMaid >= 2)
  7121. {
  7122. selectList.Add(1);
  7123. }
  7124. else if (stockMaidCount2 > 3)
  7125. {
  7126. selectList.Add(2);
  7127. }
  7128. }
  7129. if (stockMaidCount2 > 3)
  7130. {
  7131. if (editMaid >= 3)
  7132. {
  7133. selectList.Add(2);
  7134. }
  7135. else if (stockMaidCount2 > 4)
  7136. {
  7137. selectList.Add(3);
  7138. }
  7139. }
  7140. if (stockMaidCount2 > 4)
  7141. {
  7142. if (editMaid >= 4)
  7143. {
  7144. selectList.Add(3);
  7145. }
  7146. else if (stockMaidCount2 > 5)
  7147. {
  7148. selectList.Add(4);
  7149. }
  7150. }
  7151. if (stockMaidCount2 > 5)
  7152. {
  7153. if (editMaid >= 5)
  7154. {
  7155. selectList.Add(4);
  7156. }
  7157. else if (stockMaidCount2 > 6)
  7158. {
  7159. selectList.Add(5);
  7160. }
  7161. }
  7162. if (stockMaidCount2 > 6)
  7163. {
  7164. if (editMaid >= 6)
  7165. {
  7166. selectList.Add(5);
  7167. }
  7168. else if (stockMaidCount2 > 7)
  7169. {
  7170. selectList.Add(6);
  7171. }
  7172. }
  7173. }
  7174. }
  7175. if (GUI.Button(new Rect(rectWin.width * 0.5f, GetPix(52), rectWin.width * 0.4f, GetPix(23)),
  7176. "選択解除",
  7177. style4))
  7178. {
  7179. selectList = new ArrayList();
  7180. if (sceneLevel == 5)
  7181. {
  7182. selectList.Add(editMaid);
  7183. }
  7184. }
  7185. GUI.enabled = true;
  7186. maidCallScrollPos = GUI.BeginScrollView(position, maidCallScrollPos, viewRect);
  7187. for (int nStockNo = 0; nStockNo < characterMgr.GetStockMaidCount(); ++nStockNo)
  7188. {
  7189. GUI.enabled = true;
  7190. GUI.DrawTexture(new Rect(2f, y + 2f, (float)(rectWin.width * 0.829999983310699 - 4.0), pix - 4f),
  7191. Texture2D.whiteTexture);
  7192. bool flag2 = false;
  7193. for (int index = 0; index < selectList.Count; ++index)
  7194. {
  7195. if ((int)selectList[index] == nStockNo)
  7196. {
  7197. flag2 = true;
  7198. break;
  7199. }
  7200. }
  7201. if (comboBoxControl.isClickedComboButton)
  7202. {
  7203. GUI.enabled = false;
  7204. GUI.Button(new Rect(0.0f, y, rectWin.width * 0.83f, pix), "", style2);
  7205. GUI.Button(new Rect(0.0f, y, rectWin.width * 0.83f, pix), "", style2);
  7206. }
  7207. if (GUI.Button(new Rect(0.0f, y, rectWin.width * 0.83f, pix), "", style2))
  7208. {
  7209. if (flag2)
  7210. {
  7211. for (int index = 0; index < selectList.Count; ++index)
  7212. {
  7213. if ((int)selectList[index] == nStockNo && (sceneLevel != 5 || (int)selectList[index] != editMaid))
  7214. {
  7215. selectList.Remove(nStockNo);
  7216. break;
  7217. }
  7218. }
  7219. }
  7220. else
  7221. {
  7222. if (selectList.Count > maxMaidCnt - 1)
  7223. {
  7224. selectList.Remove(selectList[maxMaidCnt - 1]);
  7225. }
  7226. selectList.Add(nStockNo);
  7227. }
  7228. }
  7229. GUI.enabled = true;
  7230. if (flag2)
  7231. {
  7232. GUI.DrawTexture(new Rect(5f, y + 5f, (float)(rectWin.width * 0.829999983310699 - 10.0), pix - 10f),
  7233. Texture2D.whiteTexture);
  7234. }
  7235. if (characterMgr.GetStockMaid(nStockNo).GetThumIcon())
  7236. {
  7237. GUI.DrawTexture(new Rect(0.0f, y - 5f, pix, pix), characterMgr.GetStockMaid(nStockNo).GetThumIcon());
  7238. }
  7239. string text = characterMgr.GetStockMaid(nStockNo).status.lastName + "\n"
  7240. + characterMgr.GetStockMaid(nStockNo).status.firstName;
  7241. guiStyleState.textColor = Color.black;
  7242. style1.normal = guiStyleState;
  7243. GUI.Label(new Rect(GetPix(65), y + pix / 4f, pix * 2f, pix * 3f), text, style1);
  7244. if (flag2)
  7245. {
  7246. for (int index = 0; index < selectList.Count; ++index)
  7247. {
  7248. if ((int)selectList[index] == nStockNo)
  7249. {
  7250. GUI.Label(new Rect(rectWin.width * 0.7f, y + 6f, pix, pix), (index + 1).ToString(), style1);
  7251. break;
  7252. }
  7253. }
  7254. }
  7255. y += pix + GetPix(5);
  7256. }
  7257. GUI.EndScrollView();
  7258. guiStyleState.textColor = Color.white;
  7259. style1.normal = guiStyleState;
  7260. comboBoxControl.List(new Rect(GetPix(10), GetPix(25), rectWin.width * 0.56f, GetPix(24)),
  7261. comboBoxList[comboBoxControl.GetSelectedItemIndex()].text,
  7262. comboBoxList,
  7263. listStyle);
  7264. bool OKButton = GUI.Button(new Rect(rectWin.width * 0.66f, GetPix(25), rectWin.width * 0.24f, GetPix(24)),
  7265. "決定",
  7266. style4);
  7267. GUI.DragWindow();
  7268. if (!OKButton)
  7269. {
  7270. return;
  7271. }
  7272. for (int index = 0; index < maxMaidCnt; ++index)
  7273. {
  7274. isStop[index] = false;
  7275. }
  7276. switch (comboBoxControl.GetSelectedItemIndex())
  7277. {
  7278. case 0:
  7279. for (int index = 0; index < maidCnt; ++index)
  7280. {
  7281. Vector3 zero1 = Vector3.zero;
  7282. Vector3 zero2 = Vector3.zero;
  7283. if (selectList.Count <= 7)
  7284. {
  7285. if (selectList.Count % 2 == 1)
  7286. {
  7287. switch (index)
  7288. {
  7289. case 0:
  7290. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.0f));
  7291. break;
  7292. case 1:
  7293. maidArray[index].SetPos(new Vector3(-0.6f, 0.0f, 0.26f));
  7294. break;
  7295. case 2:
  7296. maidArray[index].SetPos(new Vector3(0.6f, 0.0f, 0.26f));
  7297. break;
  7298. case 3:
  7299. maidArray[index].SetPos(new Vector3(-1.1f, 0.0f, 0.69f));
  7300. break;
  7301. case 4:
  7302. maidArray[index].SetPos(new Vector3(1.1f, 0.0f, 0.69f));
  7303. break;
  7304. case 5:
  7305. maidArray[index].SetPos(new Vector3(-1.47f, 0.0f, 1.1f));
  7306. break;
  7307. case 6:
  7308. maidArray[index].SetPos(new Vector3(1.47f, 0.0f, 1.1f));
  7309. break;
  7310. }
  7311. }
  7312. else
  7313. {
  7314. switch (index)
  7315. {
  7316. case 0:
  7317. maidArray[index].SetPos(new Vector3(0.3f, 0.0f, 0.0f));
  7318. break;
  7319. case 1:
  7320. maidArray[index].SetPos(new Vector3(-0.3f, 0.0f, 0.0f));
  7321. break;
  7322. case 2:
  7323. maidArray[index].SetPos(new Vector3(0.7f, 0.0f, 0.4f));
  7324. break;
  7325. case 3:
  7326. maidArray[index].SetPos(new Vector3(-0.7f, 0.0f, 0.4f));
  7327. break;
  7328. case 4:
  7329. maidArray[index].SetPos(new Vector3(1f, 0.0f, 0.9f));
  7330. break;
  7331. case 5:
  7332. maidArray[index].SetPos(new Vector3(-1f, 0.0f, 0.9f));
  7333. break;
  7334. }
  7335. }
  7336. }
  7337. else
  7338. {
  7339. float num1 = 0.0f;
  7340. if (selectList.Count >= 11)
  7341. {
  7342. float num2 = -0.4f;
  7343. if (selectList.Count % 2 == 1)
  7344. {
  7345. switch (index)
  7346. {
  7347. case 0:
  7348. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.0f + num2));
  7349. break;
  7350. case 1:
  7351. maidArray[index].SetPos(new Vector3(-0.5f, 0.0f, 0.2f + num2));
  7352. break;
  7353. case 2:
  7354. maidArray[index].SetPos(new Vector3(0.5f, 0.0f, 0.2f + num2));
  7355. break;
  7356. case 3:
  7357. maidArray[index].SetPos(new Vector3(-0.9f, 0.0f, 0.55f + num2));
  7358. break;
  7359. case 4:
  7360. maidArray[index].SetPos(new Vector3(0.9f, 0.0f, 0.55f + num2));
  7361. break;
  7362. case 5:
  7363. maidArray[index].SetPos(new Vector3(-1.25f, 0.0f, 0.9f + num2));
  7364. break;
  7365. case 6:
  7366. maidArray[index].SetPos(new Vector3(1.25f, 0.0f, 0.9f + num2));
  7367. break;
  7368. case 7:
  7369. maidArray[index].SetPos(new Vector3(-1.57f, 0.0f, 1.3f + num2));
  7370. break;
  7371. case 8:
  7372. maidArray[index].SetPos(new Vector3(1.57f, 0.0f, 1.3f + num2));
  7373. break;
  7374. case 9:
  7375. maidArray[index].SetPos(new Vector3(-1.77f, 0.0f, 1.72f + num2));
  7376. break;
  7377. case 10:
  7378. maidArray[index].SetPos(new Vector3(1.77f, 0.0f, 1.72f + num2));
  7379. break;
  7380. case 11:
  7381. maidArray[index].SetPos(new Vector3(-1.85f, 0.0f, 2.17f + num2));
  7382. break;
  7383. case 12:
  7384. maidArray[index].SetPos(new Vector3(1.85f, 0.0f, 2.17f + num2));
  7385. break;
  7386. default:
  7387. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f + num2));
  7388. break;
  7389. }
  7390. }
  7391. else
  7392. {
  7393. switch (index)
  7394. {
  7395. case 0:
  7396. maidArray[index].SetPos(new Vector3(0.25f, 0.0f, 0.0f + num2));
  7397. break;
  7398. case 1:
  7399. maidArray[index].SetPos(new Vector3(-0.25f, 0.0f, 0.0f + num2));
  7400. break;
  7401. case 2:
  7402. maidArray[index].SetPos(new Vector3(0.7f, 0.0f, 0.25f + num2));
  7403. break;
  7404. case 3:
  7405. maidArray[index].SetPos(new Vector3(-0.7f, 0.0f, 0.25f + num2));
  7406. break;
  7407. case 4:
  7408. maidArray[index].SetPos(new Vector3(1.05f, 0.0f, 0.6f + num2));
  7409. break;
  7410. case 5:
  7411. maidArray[index].SetPos(new Vector3(-1.05f, 0.0f, 0.6f + num2));
  7412. break;
  7413. case 6:
  7414. maidArray[index].SetPos(new Vector3(1.35f, 0.0f, 0.9f + num2));
  7415. break;
  7416. case 7:
  7417. maidArray[index].SetPos(new Vector3(-1.35f, 0.0f, 0.9f + num2));
  7418. break;
  7419. case 8:
  7420. maidArray[index].SetPos(new Vector3(1.6f, 0.0f, 1.3f + num2));
  7421. break;
  7422. case 9:
  7423. maidArray[index].SetPos(new Vector3(-1.6f, 0.0f, 1.3f + num2));
  7424. break;
  7425. case 10:
  7426. maidArray[index].SetPos(new Vector3(1.8f, 0.0f, 1.72f + num2));
  7427. break;
  7428. case 11:
  7429. maidArray[index].SetPos(new Vector3(-1.8f, 0.0f, 1.72f + num2));
  7430. break;
  7431. case 12:
  7432. maidArray[index].SetPos(new Vector3(1.9f, 0.0f, 2.17f + num2));
  7433. break;
  7434. case 13:
  7435. maidArray[index].SetPos(new Vector3(-1.9f, 0.0f, 2.17f + num2));
  7436. break;
  7437. default:
  7438. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f + num2));
  7439. break;
  7440. }
  7441. }
  7442. }
  7443. else if (selectList.Count >= 8)
  7444. {
  7445. if (selectList.Count >= 9)
  7446. {
  7447. num1 = -0.2f;
  7448. }
  7449. if (selectList.Count % 2 == 1)
  7450. {
  7451. switch (index)
  7452. {
  7453. case 0:
  7454. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.0f + num1));
  7455. break;
  7456. case 1:
  7457. maidArray[index].SetPos(new Vector3(-0.55f, 0.0f, 0.2f + num1));
  7458. break;
  7459. case 2:
  7460. maidArray[index].SetPos(new Vector3(0.55f, 0.0f, 0.2f + num1));
  7461. break;
  7462. case 3:
  7463. maidArray[index].SetPos(new Vector3(-1f, 0.0f, 0.6f + num1));
  7464. break;
  7465. case 4:
  7466. maidArray[index].SetPos(new Vector3(1f, 0.0f, 0.6f + num1));
  7467. break;
  7468. case 5:
  7469. maidArray[index].SetPos(new Vector3(-1.35f, 0.0f, 1f + num1));
  7470. break;
  7471. case 6:
  7472. maidArray[index].SetPos(new Vector3(1.35f, 0.0f, 1f + num1));
  7473. break;
  7474. case 7:
  7475. maidArray[index].SetPos(new Vector3(-1.6f, 0.0f, 1.4f + num1));
  7476. break;
  7477. case 8:
  7478. maidArray[index].SetPos(new Vector3(1.6f, 0.0f, 1.4f + num1));
  7479. break;
  7480. }
  7481. }
  7482. else
  7483. {
  7484. switch (index)
  7485. {
  7486. case 0:
  7487. maidArray[index].SetPos(new Vector3(0.28f, 0.0f, 0.0f + num1));
  7488. break;
  7489. case 1:
  7490. maidArray[index].SetPos(new Vector3(-0.28f, 0.0f, 0.0f + num1));
  7491. break;
  7492. case 2:
  7493. maidArray[index].SetPos(new Vector3(0.78f, 0.0f, 0.3f + num1));
  7494. break;
  7495. case 3:
  7496. maidArray[index].SetPos(new Vector3(-0.78f, 0.0f, 0.3f + num1));
  7497. break;
  7498. case 4:
  7499. maidArray[index].SetPos(new Vector3(1.22f, 0.0f, 0.7f + num1));
  7500. break;
  7501. case 5:
  7502. maidArray[index].SetPos(new Vector3(-1.22f, 0.0f, 0.7f + num1));
  7503. break;
  7504. case 6:
  7505. maidArray[index].SetPos(new Vector3(1.55f, 0.0f, 1.1f + num1));
  7506. break;
  7507. case 7:
  7508. maidArray[index].SetPos(new Vector3(-1.55f, 0.0f, 1.1f + num1));
  7509. break;
  7510. case 8:
  7511. maidArray[index].SetPos(new Vector3(1.77f, 0.0f, 1.58f + num1));
  7512. break;
  7513. case 9:
  7514. maidArray[index].SetPos(new Vector3(-1.77f, 0.0f, 1.58f + num1));
  7515. break;
  7516. }
  7517. }
  7518. }
  7519. }
  7520. zero2.y = (float)(Math.Atan2(maidArray[index].transform.position.x,
  7521. maidArray[index].transform.position.z - 1.5) * 180.0 / Math.PI) + 180f;
  7522. maidArray[index].SetRot(zero2);
  7523. }
  7524. break;
  7525. case 1:
  7526. for (int index = 0; index < maidCnt; ++index)
  7527. {
  7528. Vector3 zero1 = Vector3.zero;
  7529. Vector3 zero2 = Vector3.zero;
  7530. if (maidCnt < 9)
  7531. {
  7532. switch (index)
  7533. {
  7534. case 1:
  7535. zero1.x = -0.6f;
  7536. break;
  7537. case 2:
  7538. zero1.x = 0.6f;
  7539. break;
  7540. case 3:
  7541. zero1.x = -1.2f;
  7542. break;
  7543. case 4:
  7544. zero1.x = 1.2f;
  7545. break;
  7546. case 5:
  7547. zero1.x = -1.8f;
  7548. break;
  7549. case 6:
  7550. zero1.x = 1.8f;
  7551. break;
  7552. case 7:
  7553. zero1.x = -2.4f;
  7554. break;
  7555. case 8:
  7556. zero1.x = 2.4f;
  7557. break;
  7558. case 9:
  7559. zero1.x = -3f;
  7560. break;
  7561. case 10:
  7562. zero1.x = 3f;
  7563. break;
  7564. }
  7565. }
  7566. else
  7567. {
  7568. switch (index)
  7569. {
  7570. case 1:
  7571. zero1.x = -0.5f;
  7572. break;
  7573. case 2:
  7574. zero1.x = 0.5f;
  7575. break;
  7576. case 3:
  7577. zero1.x = -1f;
  7578. break;
  7579. case 4:
  7580. zero1.x = 1f;
  7581. break;
  7582. case 5:
  7583. zero1.x = -1.5f;
  7584. break;
  7585. case 6:
  7586. zero1.x = 1.5f;
  7587. break;
  7588. case 7:
  7589. zero1.x = -2f;
  7590. break;
  7591. case 8:
  7592. zero1.x = 2f;
  7593. break;
  7594. case 9:
  7595. zero1.x = -2.5f;
  7596. break;
  7597. case 10:
  7598. zero1.x = 2.5f;
  7599. break;
  7600. case 11:
  7601. zero1.x = -3f;
  7602. break;
  7603. case 12:
  7604. zero1.x = 3f;
  7605. break;
  7606. case 13:
  7607. zero1.x = -3.5f;
  7608. break;
  7609. }
  7610. }
  7611. maidArray[index].SetPos(zero1);
  7612. maidArray[index].SetRot(zero2);
  7613. if (index >= 14)
  7614. {
  7615. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  7616. }
  7617. }
  7618. break;
  7619. case 2:
  7620. for (int index = 0; index < maidCnt; ++index)
  7621. {
  7622. Vector3 zero1 = Vector3.zero;
  7623. Vector3 zero2 = Vector3.zero;
  7624. if (maidCnt < 9)
  7625. {
  7626. switch (index)
  7627. {
  7628. case 1:
  7629. zero1.z = 0.6f;
  7630. break;
  7631. case 2:
  7632. zero1.z = -0.6f;
  7633. break;
  7634. case 3:
  7635. zero1.z = 1.2f;
  7636. break;
  7637. case 4:
  7638. zero1.z = -1.2f;
  7639. break;
  7640. case 5:
  7641. zero1.z = 1.8f;
  7642. break;
  7643. case 6:
  7644. zero1.z = -1.8f;
  7645. break;
  7646. case 7:
  7647. zero1.z = 2.4f;
  7648. break;
  7649. case 8:
  7650. zero1.z = -2.4f;
  7651. break;
  7652. case 9:
  7653. zero1.z = 3f;
  7654. break;
  7655. case 10:
  7656. zero1.z = -3f;
  7657. break;
  7658. }
  7659. }
  7660. else
  7661. {
  7662. switch (index)
  7663. {
  7664. case 1:
  7665. zero1.z = 0.5f;
  7666. break;
  7667. case 2:
  7668. zero1.z = -0.5f;
  7669. break;
  7670. case 3:
  7671. zero1.z = 1f;
  7672. break;
  7673. case 4:
  7674. zero1.z = -1f;
  7675. break;
  7676. case 5:
  7677. zero1.z = 1.5f;
  7678. break;
  7679. case 6:
  7680. zero1.z = -1.5f;
  7681. break;
  7682. case 7:
  7683. zero1.z = 2f;
  7684. break;
  7685. case 8:
  7686. zero1.z = -2f;
  7687. break;
  7688. case 9:
  7689. zero1.z = 2.5f;
  7690. break;
  7691. case 10:
  7692. zero1.z = -2.5f;
  7693. break;
  7694. case 11:
  7695. zero1.z = 3f;
  7696. break;
  7697. case 12:
  7698. zero1.z = -3f;
  7699. break;
  7700. case 13:
  7701. zero1.z = 3.5f;
  7702. break;
  7703. }
  7704. }
  7705. maidArray[index].SetPos(zero1);
  7706. maidArray[index].SetRot(zero2);
  7707. if (index >= 14)
  7708. {
  7709. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  7710. }
  7711. }
  7712. break;
  7713. case 3:
  7714. for (int index = 0; index < maidCnt; ++index)
  7715. {
  7716. Vector3 zero1 = Vector3.zero;
  7717. Vector3 zero2 = Vector3.zero;
  7718. float num = 0.5f;
  7719. if (maidCnt > 11)
  7720. {
  7721. num = 0.25f;
  7722. }
  7723. else if (maidCnt > 9)
  7724. {
  7725. num = 0.32f;
  7726. }
  7727. else if (maidCnt > 7)
  7728. {
  7729. num = 0.4f;
  7730. }
  7731. switch (index)
  7732. {
  7733. case 1:
  7734. zero1.x = -num;
  7735. zero1.z = num;
  7736. break;
  7737. case 2:
  7738. zero1.x = num;
  7739. zero1.z = -num;
  7740. break;
  7741. case 3:
  7742. zero1.x = (float)(-num * 2.0);
  7743. zero1.z = num * 2f;
  7744. break;
  7745. case 4:
  7746. zero1.x = num * 2f;
  7747. zero1.z = (float)(-num * 2.0);
  7748. break;
  7749. case 5:
  7750. zero1.x = (float)(-num * 3.0);
  7751. zero1.z = num * 3f;
  7752. break;
  7753. case 6:
  7754. zero1.x = num * 3f;
  7755. zero1.z = (float)(-num * 3.0);
  7756. break;
  7757. case 7:
  7758. zero1.x = (float)(-num * 4.0);
  7759. zero1.z = num * 4f;
  7760. break;
  7761. case 8:
  7762. zero1.x = num * 4f;
  7763. zero1.z = (float)(-num * 4.0);
  7764. break;
  7765. case 9:
  7766. zero1.x = (float)(-num * 5.0);
  7767. zero1.z = num * 5f;
  7768. break;
  7769. case 10:
  7770. zero1.x = num * 5f;
  7771. zero1.z = (float)(-num * 5.0);
  7772. break;
  7773. case 11:
  7774. zero1.x = (float)(-num * 6.0);
  7775. zero1.z = num * 6f;
  7776. break;
  7777. case 12:
  7778. zero1.x = num * 6f;
  7779. zero1.z = (float)(-num * 6.0);
  7780. break;
  7781. case 13:
  7782. zero1.x = (float)(-num * 7.0);
  7783. zero1.z = num * 7f;
  7784. break;
  7785. }
  7786. maidArray[index].SetPos(zero1);
  7787. maidArray[index].SetRot(zero2);
  7788. if (index >= 14)
  7789. {
  7790. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  7791. }
  7792. }
  7793. break;
  7794. case 4:
  7795. for (int index = 0; index < maidCnt; ++index)
  7796. {
  7797. Vector3 zero1 = Vector3.zero;
  7798. Vector3 zero2 = Vector3.zero;
  7799. float num = (float)(0.400000005960464 + 0.0799999982118607 * maidCnt);
  7800. zero1.x = num * (float)Math.Cos(Math.PI / 180.0 * (90 + 360 * index / maidCnt));
  7801. zero1.z = num * (float)Math.Sin(Math.PI / 180.0 * (90 + 360 * index / maidCnt));
  7802. maidArray[index].SetPos(zero1);
  7803. zero2.y = (float)(Math.Atan2(zero1.x, zero1.z) * 180.0 / Math.PI);
  7804. maidArray[index].SetRot(zero2);
  7805. }
  7806. break;
  7807. case 5:
  7808. for (int index = 0; index < maidCnt; ++index)
  7809. {
  7810. Vector3 zero1 = Vector3.zero;
  7811. Vector3 zero2 = Vector3.zero;
  7812. float num = (float)(0.400000005960464 + 0.0799999982118607 * maidCnt);
  7813. zero1.x = num * (float)Math.Cos(Math.PI / 180.0 * (90 + 360 * index / maidCnt));
  7814. zero1.z = num * (float)Math.Sin(Math.PI / 180.0 * (90 + 360 * index / maidCnt));
  7815. maidArray[index].SetPos(zero1);
  7816. zero2.y = (float)(Math.Atan2(zero1.x, zero1.z) * 180.0 / Math.PI) + 180f;
  7817. maidArray[index].SetRot(zero2);
  7818. }
  7819. break;
  7820. case 6:
  7821. for (int index = 0; index < maidCnt; ++index)
  7822. {
  7823. Vector3 zero1 = Vector3.zero;
  7824. Vector3 zero2 = Vector3.zero;
  7825. float num = 0.0f;
  7826. if (maidCnt > 9)
  7827. {
  7828. num = -0.4f;
  7829. }
  7830. else if (maidCnt > 7)
  7831. {
  7832. num = -0.2f;
  7833. }
  7834. switch (index)
  7835. {
  7836. case 0:
  7837. zero1.z = 0.3f;
  7838. break;
  7839. case 1:
  7840. zero1.x = -0.9f;
  7841. zero1.z = -0.4f;
  7842. zero2.y = 40f;
  7843. break;
  7844. case 2:
  7845. zero1.x = 0.9f;
  7846. zero1.z = -0.4f;
  7847. zero2.y = -40f;
  7848. break;
  7849. case 3:
  7850. zero1.x = -0.4f;
  7851. zero1.z = -0.8f;
  7852. zero2.y = 20f;
  7853. break;
  7854. case 4:
  7855. zero1.x = 0.4f;
  7856. zero1.z = -0.8f;
  7857. zero2.y = -20f;
  7858. break;
  7859. case 5:
  7860. zero1.x = -1.2f;
  7861. zero1.z = 0.1f;
  7862. zero2.y = 60f;
  7863. break;
  7864. case 6:
  7865. zero1.x = 1.2f;
  7866. zero1.z = 0.1f;
  7867. zero2.y = -60f;
  7868. break;
  7869. case 7:
  7870. zero1.x = -1.5f;
  7871. zero1.z = 0.6f;
  7872. zero2.y = 80f;
  7873. break;
  7874. case 8:
  7875. zero1.x = 1.5f;
  7876. zero1.z = 0.6f;
  7877. zero2.y = -80f;
  7878. break;
  7879. case 9:
  7880. zero1.x = -1.6f;
  7881. zero1.z = 1.15f;
  7882. zero2.y = 100f;
  7883. break;
  7884. case 10:
  7885. zero1.x = 1.6f;
  7886. zero1.z = 1.15f;
  7887. zero2.y = -100f;
  7888. break;
  7889. case 11:
  7890. zero1.x = -1.6f;
  7891. zero1.z = 1.65f;
  7892. zero2.y = 110f;
  7893. break;
  7894. case 12:
  7895. zero1.x = 1.65f;
  7896. zero1.z = 1.65f;
  7897. zero2.y = -110f;
  7898. break;
  7899. case 13:
  7900. zero1.x = -1.65f;
  7901. zero1.z = 2.15f;
  7902. zero2.y = 120f;
  7903. break;
  7904. }
  7905. if (index > 0)
  7906. {
  7907. zero1.z += num;
  7908. }
  7909. else
  7910. {
  7911. zero1.z -= num;
  7912. }
  7913. maidArray[index].SetPos(zero1);
  7914. maidArray[index].SetRot(zero2);
  7915. if (index >= 14)
  7916. {
  7917. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  7918. }
  7919. }
  7920. break;
  7921. case 7:
  7922. for (int index = 0; index < maidCnt; ++index)
  7923. {
  7924. Vector3 zero1 = Vector3.zero;
  7925. Vector3 zero2 = Vector3.zero;
  7926. float num = 0.0f;
  7927. if (maidCnt > 11)
  7928. {
  7929. num = 0.6f;
  7930. }
  7931. else if (maidCnt > 9)
  7932. {
  7933. num = 0.4f;
  7934. }
  7935. else if (maidCnt > 7)
  7936. {
  7937. num = 0.2f;
  7938. }
  7939. switch (index)
  7940. {
  7941. case 0:
  7942. zero1.z = 0.8f;
  7943. break;
  7944. case 1:
  7945. zero1.x = -0.45f;
  7946. zero1.z = 0.3f;
  7947. zero2.y = -10f;
  7948. break;
  7949. case 2:
  7950. zero1.x = 0.45f;
  7951. zero1.z = 0.3f;
  7952. zero2.y = 10f;
  7953. break;
  7954. case 3:
  7955. zero1.x = -0.8f;
  7956. zero1.z = -0.2f;
  7957. zero2.y = -20f;
  7958. break;
  7959. case 4:
  7960. zero1.x = 0.8f;
  7961. zero1.z = -0.2f;
  7962. zero2.y = 20f;
  7963. break;
  7964. case 5:
  7965. zero1.x = -1.2f;
  7966. zero1.z = -0.75f;
  7967. zero2.y = -30f;
  7968. break;
  7969. case 6:
  7970. zero1.x = 1.2f;
  7971. zero1.z = -0.75f;
  7972. zero2.y = 30f;
  7973. break;
  7974. case 7:
  7975. zero1.x = -1.6f;
  7976. zero1.z = -1.25f;
  7977. zero2.y = -40f;
  7978. break;
  7979. case 8:
  7980. zero1.x = 1.6f;
  7981. zero1.z = -1.25f;
  7982. zero2.y = 40f;
  7983. break;
  7984. case 9:
  7985. zero1.x = -2f;
  7986. zero1.z = -1.75f;
  7987. zero2.y = -50f;
  7988. break;
  7989. case 10:
  7990. zero1.x = 2f;
  7991. zero1.z = -1.75f;
  7992. zero2.y = 50f;
  7993. break;
  7994. case 11:
  7995. zero1.x = -2.4f;
  7996. zero1.z = -2.25f;
  7997. zero2.y = -60f;
  7998. break;
  7999. case 12:
  8000. zero1.x = 2.4f;
  8001. zero1.z = -2.25f;
  8002. zero2.y = 60f;
  8003. break;
  8004. case 13:
  8005. zero1.x = -2.8f;
  8006. zero1.z = -2.75f;
  8007. zero2.y = -70f;
  8008. break;
  8009. }
  8010. zero1.z += num;
  8011. maidArray[index].SetPos(zero1);
  8012. maidArray[index].SetRot(zero2);
  8013. if (index >= 14)
  8014. {
  8015. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  8016. }
  8017. }
  8018. break;
  8019. case 8:
  8020. for (int index = 0; index < maidCnt; ++index)
  8021. {
  8022. Vector3 zero1 = Vector3.zero;
  8023. Vector3 zero2 = Vector3.zero;
  8024. float num = 0.0f;
  8025. if (maidCnt > 11)
  8026. {
  8027. num = -0.6f;
  8028. }
  8029. else if (maidCnt > 9)
  8030. {
  8031. num = -0.4f;
  8032. }
  8033. else if (maidCnt > 7)
  8034. {
  8035. num = -0.2f;
  8036. }
  8037. switch (index)
  8038. {
  8039. case 0:
  8040. zero1.z = -0.75f;
  8041. break;
  8042. case 1:
  8043. zero1.x = -0.45f;
  8044. zero1.z = -0.2f;
  8045. zero2.y = 20f;
  8046. break;
  8047. case 2:
  8048. zero1.x = 0.45f;
  8049. zero1.z = -0.2f;
  8050. zero2.y = -20f;
  8051. break;
  8052. case 3:
  8053. zero1.x = -0.8f;
  8054. zero1.z = 0.3f;
  8055. zero2.y = 35f;
  8056. break;
  8057. case 4:
  8058. zero1.x = 0.8f;
  8059. zero1.z = 0.3f;
  8060. zero2.y = -35f;
  8061. break;
  8062. case 5:
  8063. zero1.x = -1.2f;
  8064. zero1.z = 0.8f;
  8065. zero2.y = 50f;
  8066. break;
  8067. case 6:
  8068. zero1.x = 1.2f;
  8069. zero1.z = 0.8f;
  8070. zero2.y = -50f;
  8071. break;
  8072. case 7:
  8073. zero1.x = -1.6f;
  8074. zero1.z = 1.3f;
  8075. zero2.y = 65f;
  8076. break;
  8077. case 8:
  8078. zero1.x = 1.6f;
  8079. zero1.z = 1.3f;
  8080. zero2.y = -65f;
  8081. break;
  8082. case 9:
  8083. zero1.x = -2f;
  8084. zero1.z = 1.8f;
  8085. zero2.y = 80f;
  8086. break;
  8087. case 10:
  8088. zero1.x = 2f;
  8089. zero1.z = 1.8f;
  8090. zero2.y = -80f;
  8091. break;
  8092. case 11:
  8093. zero1.x = -2.4f;
  8094. zero1.z = 2.3f;
  8095. zero2.y = 90f;
  8096. break;
  8097. case 12:
  8098. zero1.x = 2.4f;
  8099. zero1.z = 2.3f;
  8100. zero2.y = -90f;
  8101. break;
  8102. case 13:
  8103. zero1.x = -2.8f;
  8104. zero1.z = 2.8f;
  8105. zero2.y = 100f;
  8106. break;
  8107. }
  8108. zero1.z += num;
  8109. maidArray[index].SetPos(zero1);
  8110. maidArray[index].SetRot(zero2);
  8111. if (index >= 14)
  8112. {
  8113. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  8114. }
  8115. }
  8116. break;
  8117. case 9:
  8118. for (int index = 0; index < maidCnt; ++index)
  8119. {
  8120. Vector3 zero1 = Vector3.zero;
  8121. Vector3 zero2 = Vector3.zero;
  8122. float num = 1f;
  8123. if (maidCnt > 9)
  8124. {
  8125. num = 0.84f;
  8126. }
  8127. else if (maidCnt > 7)
  8128. {
  8129. num = 0.92f;
  8130. }
  8131. switch (index)
  8132. {
  8133. case 0:
  8134. zero1.z = 0.0f;
  8135. break;
  8136. case 1:
  8137. zero1.x = -0.5f;
  8138. zero1.z = -0.5f;
  8139. break;
  8140. case 2:
  8141. zero1.x = 0.5f;
  8142. zero1.z = -0.5f;
  8143. break;
  8144. case 3:
  8145. zero1.x = -1f;
  8146. zero1.z = 0.2f;
  8147. break;
  8148. case 4:
  8149. zero1.x = 1f;
  8150. zero1.z = 0.2f;
  8151. break;
  8152. case 5:
  8153. zero1.x = -1.5f;
  8154. zero1.z = -0.5f;
  8155. break;
  8156. case 6:
  8157. zero1.x = 1.5f;
  8158. zero1.z = -0.5f;
  8159. break;
  8160. case 7:
  8161. zero1.x = -2f;
  8162. zero1.z = 0.2f;
  8163. break;
  8164. case 8:
  8165. zero1.x = 2f;
  8166. zero1.z = 0.2f;
  8167. break;
  8168. case 9:
  8169. zero1.x = -2.5f;
  8170. zero1.z = -0.5f;
  8171. break;
  8172. case 10:
  8173. zero1.x = 2.5f;
  8174. zero1.z = -0.5f;
  8175. break;
  8176. case 11:
  8177. zero1.x = -3f;
  8178. zero1.z = 0.2f;
  8179. break;
  8180. case 12:
  8181. zero1.x = 3f;
  8182. zero1.z = 0.2f;
  8183. break;
  8184. case 13:
  8185. zero1.x = -3.5f;
  8186. zero1.z = -0.5f;
  8187. break;
  8188. }
  8189. zero1.x *= num;
  8190. maidArray[index].SetPos(zero1);
  8191. maidArray[index].SetRot(zero2);
  8192. if (index >= 14)
  8193. {
  8194. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  8195. }
  8196. }
  8197. break;
  8198. case 10:
  8199. for (int index = 0; index < maidCnt; ++index)
  8200. {
  8201. Vector3 zero1 = Vector3.zero;
  8202. Vector3 zero2 = Vector3.zero;
  8203. float num = 1f;
  8204. if (maidCnt > 9)
  8205. {
  8206. num = 0.84f;
  8207. }
  8208. else if (maidCnt > 7)
  8209. {
  8210. num = 0.92f;
  8211. }
  8212. switch (index)
  8213. {
  8214. case 0:
  8215. zero1.z = -0.4f;
  8216. break;
  8217. case 1:
  8218. zero1.x = -0.5f;
  8219. zero1.z = 0.2f;
  8220. break;
  8221. case 2:
  8222. zero1.x = 0.5f;
  8223. zero1.z = 0.2f;
  8224. break;
  8225. case 3:
  8226. zero1.x = -1f;
  8227. zero1.z = -0.5f;
  8228. break;
  8229. case 4:
  8230. zero1.x = 1f;
  8231. zero1.z = -0.5f;
  8232. break;
  8233. case 5:
  8234. zero1.x = -1.5f;
  8235. zero1.z = 0.2f;
  8236. break;
  8237. case 6:
  8238. zero1.x = 1.5f;
  8239. zero1.z = 0.2f;
  8240. break;
  8241. case 7:
  8242. zero1.x = -2f;
  8243. zero1.z = -0.5f;
  8244. break;
  8245. case 8:
  8246. zero1.x = 2f;
  8247. zero1.z = -0.5f;
  8248. break;
  8249. case 9:
  8250. zero1.x = -2.5f;
  8251. zero1.z = 0.2f;
  8252. break;
  8253. case 10:
  8254. zero1.x = 2.5f;
  8255. zero1.z = 0.2f;
  8256. break;
  8257. case 11:
  8258. zero1.x = -3f;
  8259. zero1.z = -0.5f;
  8260. break;
  8261. case 12:
  8262. zero1.x = 3f;
  8263. zero1.z = -0.5f;
  8264. break;
  8265. case 13:
  8266. zero1.x = -3.5f;
  8267. zero1.z = 0.2f;
  8268. break;
  8269. }
  8270. zero1.x *= num;
  8271. maidArray[index].SetPos(zero1);
  8272. maidArray[index].SetRot(zero2);
  8273. if (index >= 14)
  8274. {
  8275. maidArray[index].SetPos(new Vector3(0.0f, 0.0f, 0.7f));
  8276. }
  8277. }
  8278. break;
  8279. }
  8280. for (int index = 0; index < maxMaidCnt; ++index)
  8281. {
  8282. if (!isLock[index] && maidArray[index] != null && maidArray[index].Visible)
  8283. {
  8284. maidArray[index].CrossFade(poseArray[0] + ".anm", false, true, false, 0.0f, 1f);
  8285. maidArray[index].SetAutoTwistAll(true);
  8286. }
  8287. }
  8288. }
  8289. private void MessageWindow(int winID)
  8290. {
  8291. GUIStyle style1 = "label";
  8292. style1.fontSize = GetPix(12);
  8293. style1.alignment = TextAnchor.UpperLeft;
  8294. GUIStyle style2 = "button";
  8295. style2.fontSize = GetPix(16);
  8296. GUI.Label(new Rect(GetPix(8), GetPix(4), GetPix(80), GetPix(25)),
  8297. "名前",
  8298. style1);
  8299. inName = GUI.TextField(new Rect(GetPix(35),
  8300. GetPix(4),
  8301. GetPix(120),
  8302. GetPix(20)),
  8303. inName);
  8304. GUI.Label(new Rect(GetPix(180), GetPix(4), GetPix(100), GetPix(25)),
  8305. "サイズ",
  8306. style1);
  8307. fontSize = (int)GUI.HorizontalSlider(new Rect(GetPix(220),
  8308. GetPix(9),
  8309. GetPix(100),
  8310. GetPix(20)),
  8311. fontSize,
  8312. 25f,
  8313. 60f);
  8314. if (fontSize != mFontSize)
  8315. {
  8316. mFontSize = fontSize;
  8317. GameObject gameObject = GameObject.Find("__GameMain__/SystemUI Root").transform.Find("MessageWindowPanel").gameObject;
  8318. //MessageClass messageClass = new MessageClass(gameObject, GameMain.Instance.ScriptMgr.adv_kag.MessageWindowMgr);
  8319. SetFieldValue<UILabel, int>(UTY.GetChildObject(gameObject, "MessageViewer/MsgParent/Message", false)
  8320. .GetComponent<UILabel>(),
  8321. "mFontSize",
  8322. fontSize);
  8323. }
  8324. GUI.Label(new Rect(GetPix(325), GetPix(4), GetPix(100), GetPix(25)),
  8325. fontSize.ToString() + "pt",
  8326. style1);
  8327. inText = GUI.TextArea(new Rect(GetPix(8),
  8328. GetPix(26),
  8329. rectWin2.width - GetPix(15),
  8330. GetPix(52)),
  8331. inText,
  8332. 300);
  8333. if (GUI.Button(new Rect(GetPix(8), GetPix(82), GetPix(60), GetPix(20)),
  8334. "決定",
  8335. style2))
  8336. {
  8337. isMessage = true;
  8338. bGuiMessage = false;
  8339. GameObject gameObject1 = GameObject.Find("__GameMain__/SystemUI Root").transform.Find("MessageWindowPanel").gameObject;
  8340. MessageWindowMgr messageWindowMgr = GameMain.Instance.ScriptMgr.adv_kag.MessageWindowMgr;
  8341. messageWindowMgr.OpenMessageWindowPanel();
  8342. UILabel component = UTY.GetChildObject(gameObject1, "MessageViewer/MsgParent/Message", false).GetComponent<UILabel>();
  8343. UILabel nameComponent = UTY.GetChildObject(gameObject1, "MessageViewer/MsgParent/SpeakerName/Name", false).GetComponent<UILabel>();
  8344. MessageClass inst = new MessageClass(gameObject1, messageWindowMgr);
  8345. // Fix for ENG version: reconfigure MessageClass to behave as in JP game
  8346. inst.subtitles_manager_.visible = false;
  8347. inst.subtitles_manager_ = null;
  8348. component.gameObject.SetActive(true);
  8349. nameComponent.gameObject.SetActive(true);
  8350. UTY.GetChildObject(gameObject1, "MessageViewer/MsgParent/MessageBox", false).SetActive(true);
  8351. SetFieldValue<MessageClass, UILabel>(inst, "message_label_", component);
  8352. SetFieldValue<MessageClass, UILabel>(inst, "name_label_", nameComponent);
  8353. component.ProcessText();
  8354. SetFieldValue<UILabel, int>(component, "mFontSize", fontSize);
  8355. inst.SetText(inName, inText, "", 0, AudioSourceMgr.Type.System);
  8356. inst.FinishChAnime();
  8357. }
  8358. GUI.DragWindow();
  8359. }
  8360. }
  8361. }