game.ts 285 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420
  1. // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-ts_proto v1.180.0
  4. // protoc v5.26.0
  5. // source: game.proto
  6. /* eslint-disable */
  7. import {
  8. activityConfInfo,
  9. activityTimeInfo,
  10. altarInfo,
  11. building,
  12. card,
  13. dailyDungeonsInfo,
  14. drawAwardInfo,
  15. drawInfo,
  16. equip,
  17. groceryInfo,
  18. hero,
  19. idNum,
  20. mail,
  21. manual,
  22. popGiftInfo,
  23. privilegeCardInfo,
  24. quest,
  25. rankingInfo,
  26. redPointInfo,
  27. reward,
  28. shopInfo,
  29. sidPos,
  30. } from "./typedef";
  31. export const protobufPackage = "game";
  32. /** 心跳 */
  33. export interface ping {
  34. }
  35. /** 心跳响应 */
  36. export interface pingRsp {
  37. /** 时间 */
  38. time: number;
  39. }
  40. /** 登录请求 */
  41. export interface login {
  42. /** 服务器id */
  43. sid: number;
  44. /** 玩家账号(渠道分配) */
  45. account: string;
  46. /** 玩家渠道( 目前填"xiaohei") */
  47. channel: string;
  48. }
  49. /** 登录相应 */
  50. export interface loginRsp {
  51. /** 错误码 */
  52. errno: number;
  53. }
  54. /** 创角请求 */
  55. export interface create {
  56. /** 玩家姓名 */
  57. nickname: string;
  58. }
  59. /** 创角响应 */
  60. export interface createRsp {
  61. /** 错误码 */
  62. errno: number;
  63. }
  64. /** 玩家信息 */
  65. export interface user {
  66. /** 玩家唯一id */
  67. uid: string;
  68. /** 玩家名字 */
  69. nickname: string;
  70. /** 等级 */
  71. level: number;
  72. /** 经验 */
  73. exp: number;
  74. /** 头像 */
  75. avatar: number;
  76. /** 服务器当前时间 */
  77. svrtime: number;
  78. /** 重置姓名的时间 */
  79. renameTime: number;
  80. /** 创角时间 */
  81. createtime: number;
  82. /** 货币数组 */
  83. currency: idNum[];
  84. }
  85. /** 获得奖励消息 */
  86. export interface rewardInfo {
  87. /** 特殊标记 */
  88. flags: string;
  89. /** 得到的奖励 */
  90. added: reward | undefined;
  91. }
  92. /** 城镇变化 */
  93. export interface cityChange {
  94. /** 变化的数据 */
  95. currency:
  96. | idNum
  97. | undefined;
  98. /** 下次改变时间 */
  99. time: number;
  100. }
  101. /** 货币支付消息 */
  102. export interface payCurrency {
  103. /** 当前的货币数量(支付后的) */
  104. now: idNum[];
  105. /** 支付的货币数量 */
  106. pay: idNum[];
  107. }
  108. /** 碎片支付消息 */
  109. export interface payDebrisNty {
  110. /** 碎片支付 */
  111. list: idNum[];
  112. }
  113. /** 异常抛出 */
  114. export interface exceptionNty {
  115. /** 错误码 */
  116. errno: number;
  117. }
  118. /** 创建订单 */
  119. export interface createOrderNty {
  120. /** 订单id */
  121. id: string;
  122. /** 计费点id */
  123. cfid: number;
  124. }
  125. /** 主城数据请求 */
  126. export interface cityData {
  127. }
  128. /** 主城数据响应 */
  129. export interface cityDataRsp {
  130. /** 错误码 */
  131. errno: number;
  132. /** 累计时间 */
  133. time: number;
  134. /** 建筑数据 */
  135. list: building[];
  136. /** 主城技能列表 */
  137. skillList: number[];
  138. /** 主城技能id */
  139. skillid: number;
  140. }
  141. /** 主城数据推送 */
  142. export interface cityDataSend {
  143. /** 累计时间 */
  144. time: number;
  145. /** 建筑数据 */
  146. list: building[];
  147. }
  148. /** 建筑升级请求 */
  149. export interface buildingUpgrade {
  150. /** 主城id */
  151. id: number;
  152. }
  153. /** 建筑升级响应 */
  154. export interface buildingUpgradeRsp {
  155. /** 错误码 */
  156. errno: number;
  157. /** 建筑数据 */
  158. data: building | undefined;
  159. }
  160. /** 建筑一键收获 */
  161. export interface buildingOneKey {
  162. }
  163. /** 建筑一键收获 */
  164. export interface buildingOneKeyRsp {
  165. /** 错误码 */
  166. errno: number;
  167. /** 建筑数据 */
  168. list: building[];
  169. }
  170. /** 闯关数据 */
  171. export interface adventureData {
  172. }
  173. /** 闯关数据 */
  174. export interface adventureDataRsp {
  175. /** 错误码 */
  176. errno: number;
  177. /** 简单关卡 */
  178. id1: number;
  179. /** 通关奖励 */
  180. award1: number[];
  181. /** 困难关卡 */
  182. id2: number;
  183. /** 通关奖励 */
  184. award2: number[];
  185. /** 当前冒险关卡类型 */
  186. type: number;
  187. /** 当前波次信息 */
  188. layer: number;
  189. /** 当前费用 */
  190. cost: number;
  191. }
  192. /** 闯关开始 */
  193. export interface adventureStart {
  194. /** 闯关请求 */
  195. id: number;
  196. /** 冒险关卡类型 */
  197. type: number;
  198. }
  199. /** 闯关开始 */
  200. export interface adventureStartRsp {
  201. /** 错误码 */
  202. errno: number;
  203. /** 是否开启试玩 */
  204. btrial: boolean;
  205. /** 试玩id */
  206. trialId: number;
  207. /** 试玩次数 */
  208. trialNum: number;
  209. }
  210. /** 闯关结束 */
  211. export interface adventureEnd {
  212. /** 是否胜利 */
  213. win: boolean;
  214. /** 杀怪数量 */
  215. monsterNum: number;
  216. /** 杀boss数量 */
  217. bossNum: number;
  218. /** 杀精英数量 */
  219. eliteNum: number;
  220. }
  221. /** 闯关结束 */
  222. export interface adventureEndRsp {
  223. /** 错误码 */
  224. errno: number;
  225. }
  226. /** 开始波次 */
  227. export interface adventureLayer {
  228. /** 波次 */
  229. layer: number;
  230. /** 费用 */
  231. cost: number;
  232. /** 杀怪数量 */
  233. monsterNum: number;
  234. /** 杀boss数量 */
  235. bossNum: number;
  236. /** 杀精英数量 */
  237. eliteNum: number;
  238. }
  239. /** 开始波次 */
  240. export interface adventureLayerRsp {
  241. /** 错误码 */
  242. errno: number;
  243. }
  244. /** 扫荡 */
  245. export interface adventureSweep {
  246. /** 关卡id */
  247. id: number;
  248. /** 冒险关卡类型 */
  249. type: number;
  250. }
  251. /** 扫荡 */
  252. export interface adventureSweepRsp {
  253. /** 错误码 */
  254. errno: number;
  255. }
  256. /** 领取通关奖励 */
  257. export interface adventurePassAward {
  258. /** 关卡id */
  259. id: number;
  260. /** 冒险关卡类型 */
  261. type: number;
  262. }
  263. /** 领取通关奖励 */
  264. export interface adventurePassAwardRsp {
  265. /** 错误码 */
  266. errno: number;
  267. /** 关卡id */
  268. id: number;
  269. /** 冒险关卡类型 */
  270. type: number;
  271. }
  272. /** 冒险广告奖励 */
  273. export interface adventureAdAward {
  274. }
  275. /** 冒险广告奖励 */
  276. export interface adventureAdAwardRsp {
  277. /** 错误码 */
  278. errno: number;
  279. }
  280. /** 冒险试用英雄 */
  281. export interface adventureTrial {
  282. }
  283. /** 冒险试用英雄 */
  284. export interface adventureTrialRsp {
  285. /** 错误码 */
  286. errno: number;
  287. }
  288. /** 获取邮件数据 */
  289. export interface getMail {
  290. }
  291. /** 获取邮件数据 */
  292. export interface getMailRsp {
  293. /** 错误码 */
  294. errno: number;
  295. /** 邮件数据 */
  296. list: mail[];
  297. }
  298. /** 获取邮件奖励 */
  299. export interface getMailGoods {
  300. /** 需要取出的id */
  301. list: string[];
  302. /** 是否一键领取 */
  303. bonekey: boolean;
  304. }
  305. /** 获取邮件奖励 */
  306. export interface getMailGoodsRsp {
  307. /** 错误码 */
  308. errno: number;
  309. /** 取出的id */
  310. list: string[];
  311. }
  312. /** 删除邮件 */
  313. export interface delMail {
  314. /** 需要删除的id */
  315. list: string[];
  316. }
  317. /** 删除邮件 */
  318. export interface delMailRsp {
  319. /** 错误码 */
  320. errno: number;
  321. /** 删除的id */
  322. list: string[];
  323. }
  324. /** 标记为已读 */
  325. export interface flagMail {
  326. /** 需要标记的id */
  327. list: string[];
  328. }
  329. /** 标记为已读 */
  330. export interface flagMailRsp {
  331. /** 错误码 */
  332. errno: number;
  333. }
  334. /** 发送邮件sc */
  335. export interface sendMail {
  336. /** 邮件数据 */
  337. list: mail[];
  338. }
  339. /** 简单的邮件数据 */
  340. export interface simpleMail {
  341. /** 邮件的数量 */
  342. num: number;
  343. /** 未读邮件数量 */
  344. noread: number;
  345. /** 有奖励的邮件(可能已经读过但没领取奖励) */
  346. needread: number;
  347. }
  348. /** 上阵数据 */
  349. export interface embattleGetData {
  350. }
  351. /** 上阵数据 */
  352. export interface embattleGetDataRsp {
  353. /** 错误码 */
  354. errno: number;
  355. /** 角色位置信息 */
  356. list: sidPos[];
  357. /** 卡牌位置信息 */
  358. cardList: sidPos[];
  359. }
  360. /** 角色上阵 */
  361. export interface embattleBattle {
  362. /** ture 是技能 */
  363. skill: boolean;
  364. /** 角色唯一id(为空时,检查下阵逻辑) */
  365. sid: string;
  366. /** 从1开始 */
  367. pos: number;
  368. }
  369. /** 角色上阵 */
  370. export interface embattleBattleRsp {
  371. /** 错误码 */
  372. errno: number;
  373. /** 角色位置信息 */
  374. list: sidPos[];
  375. /** 卡牌位置信息 */
  376. cardList: sidPos[];
  377. }
  378. /** 角色背包数据 */
  379. export interface heroGetData {
  380. }
  381. /** 角色背包数据 */
  382. export interface heroGetDataRsp {
  383. /** 错误码 */
  384. errno: number;
  385. /** 角色数据 */
  386. list: hero[];
  387. }
  388. /** 角色升级 */
  389. export interface heroUpgrade {
  390. /** 角色唯一id */
  391. sid: string;
  392. /** 升几级 */
  393. num: number;
  394. }
  395. /** 角色升级 */
  396. export interface heroUpgradeRsp {
  397. /** 错误码 */
  398. errno: number;
  399. /** 角色数据 */
  400. data: hero | undefined;
  401. }
  402. /** 角色突破 */
  403. export interface heroUpgradeStar {
  404. /** 角色唯一id */
  405. sid: string;
  406. /** 同名卡唯一id */
  407. same: string[];
  408. /** 非同名卡唯一id */
  409. other: string[];
  410. /** 替代品货币 */
  411. currency: idNum | undefined;
  412. }
  413. /** 角色突破 */
  414. export interface heroUpgradeStarRsp {
  415. /** 错误码 */
  416. errno: number;
  417. /** 角色数据 */
  418. data:
  419. | hero
  420. | undefined;
  421. /** 同名卡唯一id */
  422. same: string[];
  423. /** 非同名卡唯一id */
  424. other: string[];
  425. /** 替代品货币 */
  426. currency: idNum | undefined;
  427. }
  428. /** 一键突破 */
  429. export interface heroOnekeyUpgradeStar {
  430. }
  431. /** 一键突破 */
  432. export interface heroOnekeyUpgradeStarRsp {
  433. /** 错误码 */
  434. errno: number;
  435. /** 删除的角色 */
  436. delList: string[];
  437. /** 变化的角色 */
  438. changeList: hero[];
  439. }
  440. /** 角色重置 */
  441. export interface heroReset {
  442. /** 是否重置等级 */
  443. level: boolean;
  444. /** 重置角色唯一id */
  445. sid: string;
  446. }
  447. /** 角色重置 */
  448. export interface heroResetRsp {
  449. /** 错误码 */
  450. errno: number;
  451. /** 角色数据 */
  452. data: hero | undefined;
  453. }
  454. /** 角色穿戴 */
  455. export interface heroWearEquip {
  456. /** 角色sid */
  457. sid: string;
  458. /** 装备信息 */
  459. list: string[];
  460. }
  461. /** 角色穿戴 */
  462. export interface heroWearEquipRsp {
  463. /** 错误码 */
  464. errno: number;
  465. /** 装备信息 */
  466. list: string[];
  467. /** 角色数据 */
  468. data: hero | undefined;
  469. }
  470. /** 角色穿戴 */
  471. export interface heroChangeNty {
  472. /** 英雄信息 */
  473. list: hero[];
  474. }
  475. /** 技能卡牌数据 */
  476. export interface skillCardGetData {
  477. }
  478. /** 技能卡牌数据 */
  479. export interface skillCardGetDataRsp {
  480. /** 错误码 */
  481. errno: number;
  482. /** 技能卡牌数据 */
  483. list: card[];
  484. }
  485. /** 技能卡牌升级 */
  486. export interface skillCardUpgrade {
  487. /** 技能卡牌唯一id */
  488. sid: string;
  489. /** 升几级 */
  490. num: number;
  491. }
  492. /** 技能卡牌升级 */
  493. export interface skillCardUpgradeRsp {
  494. /** 错误码 */
  495. errno: number;
  496. /** 技能卡牌数据 */
  497. data: card | undefined;
  498. }
  499. /** 技能卡牌突破 */
  500. export interface skillCardUpgradeStar {
  501. /** 技能卡牌唯一id */
  502. sid: string;
  503. }
  504. /** 技能卡牌突破 */
  505. export interface skillCardUpgradeStarRsp {
  506. /** 错误码 */
  507. errno: number;
  508. /** 技能卡牌数据 */
  509. data: card | undefined;
  510. }
  511. /** 队伍数据 */
  512. export interface roleGetData {
  513. }
  514. /** 队伍数据 */
  515. export interface roleGetDataRsp {
  516. /** 错误码 */
  517. errno: number;
  518. /** 等级 */
  519. level: number;
  520. /** 经验 */
  521. exp: number;
  522. }
  523. /** 队伍等级提升 */
  524. export interface roleUpgrade {
  525. }
  526. /** 队伍等级提升 */
  527. export interface roleUpgradeRsp {
  528. /** 错误码 */
  529. errno: number;
  530. /** 等级 */
  531. level: number;
  532. /** 经验 */
  533. exp: number;
  534. }
  535. /** 改名 */
  536. export interface roleRename {
  537. /** 名字 */
  538. name: string;
  539. }
  540. /** 改名 */
  541. export interface roleRenameRsp {
  542. /** 错误码 */
  543. errno: number;
  544. /** 名字 */
  545. name: string;
  546. /** 重置姓名的时间 */
  547. time: number;
  548. }
  549. /** 碎片背包数据 */
  550. export interface debrisGetData {
  551. }
  552. /** 碎片背包数据 */
  553. export interface debrisGetDataRsp {
  554. /** 错误码 */
  555. errno: number;
  556. /** 数据 */
  557. list: idNum[];
  558. }
  559. /** 碎片合成 */
  560. export interface debrisMerge {
  561. /** 碎片id */
  562. id: number;
  563. }
  564. /** 碎片合成 */
  565. export interface debrisMergeRsp {
  566. /** 错误码 */
  567. errno: number;
  568. }
  569. /** 装备背包数据 */
  570. export interface equipGetData {
  571. }
  572. /** 装备背包数据 */
  573. export interface equipGetDataRsp {
  574. /** 错误码 */
  575. errno: number;
  576. /** 装备数据 */
  577. list: equip[];
  578. }
  579. /** 装备升级 */
  580. export interface equipUpgrade {
  581. /** 装备唯一id */
  582. sid: string;
  583. /** 升几级 */
  584. num: number;
  585. }
  586. /** 装备升级 */
  587. export interface equipUpgradeRsp {
  588. /** 错误码 */
  589. errno: number;
  590. /** 装备数据 */
  591. data: equip | undefined;
  592. }
  593. /** 装备突破 */
  594. export interface equipUpgradeStar {
  595. /** 装备唯一id */
  596. sid: string;
  597. /** 同名卡唯一id */
  598. same: string[];
  599. /** 非同名卡唯一id */
  600. other: string[];
  601. /** 替代品货币 */
  602. currency: idNum | undefined;
  603. }
  604. /** 装备突破 */
  605. export interface equipUpgradeStarRsp {
  606. /** 错误码 */
  607. errno: number;
  608. /** 装备数据 */
  609. data:
  610. | equip
  611. | undefined;
  612. /** 同名卡唯一id */
  613. same: string[];
  614. /** 非同名卡唯一id */
  615. other: string[];
  616. /** 替代品货币 */
  617. currency: idNum | undefined;
  618. }
  619. /** 一键突破 */
  620. export interface equipOnekeyUpgradeStar {
  621. }
  622. /** 一键突破 */
  623. export interface equipOnekeyUpgradeStarRsp {
  624. /** 错误码 */
  625. errno: number;
  626. /** 删除的装备 */
  627. delList: string[];
  628. /** 变化的装备 */
  629. changeList: equip[];
  630. }
  631. /** 装备重置 */
  632. export interface equipReset {
  633. /** 是否重置等级 */
  634. level: boolean;
  635. /** 重置装备唯一id */
  636. sid: string;
  637. }
  638. /** 装备重置 */
  639. export interface equipResetRsp {
  640. /** 错误码 */
  641. errno: number;
  642. /** 装备数据 */
  643. data: equip | undefined;
  644. }
  645. /** 装备重置 */
  646. export interface equipChangeNty {
  647. /** 英雄信息 */
  648. list: equip[];
  649. }
  650. /** 天赋数据 */
  651. export interface talentGetData {
  652. }
  653. /** 天赋数据 */
  654. export interface talentGetDataRsp {
  655. /** 错误码 */
  656. errno: number;
  657. /** 天赋1 */
  658. id1: number;
  659. /** 天赋2 */
  660. id2: number;
  661. }
  662. /** 天赋激活 */
  663. export interface talentActivate {
  664. /** 激活id */
  665. id: number;
  666. }
  667. /** 天赋激活 */
  668. export interface talentActivateRsp {
  669. /** 错误码 */
  670. errno: number;
  671. /** 激活id */
  672. id: number;
  673. }
  674. /** 签到数据 */
  675. export interface signInGetData {
  676. }
  677. /** 签到数据 */
  678. export interface signInGetDataRsp {
  679. /** 错误码 */
  680. errno: number;
  681. }
  682. /** 签到奖励 */
  683. export interface signInAward {
  684. /** 第几天 */
  685. day: number;
  686. }
  687. /** 签到奖励 */
  688. export interface signInAwardRsp {
  689. /** 错误码 */
  690. errno: number;
  691. /** 第几天 */
  692. day: number;
  693. /** 领奖数据 */
  694. award: number;
  695. }
  696. /** 新一轮签到数据 */
  697. export interface signInNty {
  698. /** 是否开启 */
  699. open: boolean;
  700. /** 第几天 */
  701. day: number;
  702. /** 领奖数据 */
  703. award: number;
  704. /** 当前轮次 */
  705. round: number;
  706. }
  707. /** 任务数据 */
  708. export interface questGetData {
  709. }
  710. /** 任务数据 */
  711. export interface questGetDataRsp {
  712. /** 错误码 */
  713. errno: number;
  714. /** 日常刷新时等级 */
  715. dlv: number;
  716. /** 周常刷新时等级 */
  717. wlv: number;
  718. /** 日常活跃领取 */
  719. daward: number;
  720. /** 周常活跃领取 */
  721. waward: number;
  722. /** 日常任务 */
  723. daily: quest[];
  724. /** 周常任务 */
  725. weekly: quest[];
  726. /** 成就任务 */
  727. achievement: quest[];
  728. /** 主线任务 */
  729. mainQuest: quest | undefined;
  730. }
  731. /** 领取任务奖励 */
  732. export interface questGetAward {
  733. /** 任务id */
  734. id: number;
  735. }
  736. /** 领取任务奖励 */
  737. export interface questGetAwardRsp {
  738. /** 错误码 */
  739. errno: number;
  740. /** 任务id */
  741. id: number;
  742. /** 任务数据变化(成就任务这里会变为下个成就任务) */
  743. data: quest | undefined;
  744. }
  745. /** 领取活跃奖励 */
  746. export interface questActiveAward {
  747. /** 1日常任务 2周常任务 */
  748. type: number;
  749. }
  750. /** 领取活跃奖励 */
  751. export interface questActiveAwardRsp {
  752. /** 错误码 */
  753. errno: number;
  754. /** 1日常任务 2周常任务 */
  755. type: number;
  756. /** 已领取的活跃奖励 */
  757. award: number;
  758. }
  759. /** 任务 */
  760. export interface questCmplateNotify {
  761. /** 任务数据变化(成就任务这里会变为下个成就任务) */
  762. data: quest | undefined;
  763. }
  764. /** 战令数据 */
  765. export interface manualGetData {
  766. /** 模块id */
  767. moduleid: number;
  768. }
  769. /** 战令数据 */
  770. export interface manualGetDataRsp {
  771. /** 错误码 */
  772. errno: number;
  773. /** 是否开启 */
  774. open: boolean;
  775. /** 开启时间 */
  776. openTime: number;
  777. /** 等级 */
  778. level: number;
  779. /** 经验 */
  780. exp: number;
  781. /** 轮次 */
  782. round: number;
  783. /** 战令数据 */
  784. list: manual[];
  785. /** 模块id */
  786. moduleid: number;
  787. }
  788. /** 战令购买经验 */
  789. export interface manualBuyExp {
  790. /** 模块id */
  791. moduleid: number;
  792. }
  793. /** 战令购买经验 */
  794. export interface manualBuyExpRsp {
  795. /** 错误码 */
  796. errno: number;
  797. /** 等级 */
  798. level: number;
  799. /** 经验 */
  800. exp: number;
  801. /** 模块id */
  802. moduleid: number;
  803. }
  804. /** 战令领取奖励 */
  805. export interface manualGetAward {
  806. /** 模块id */
  807. moduleid: number;
  808. }
  809. /** 战令领取奖励 */
  810. export interface manualGetAwardRsp {
  811. /** 错误码 */
  812. errno: number;
  813. /** 已领取的奖励 */
  814. award: number;
  815. /** 模块id */
  816. moduleid: number;
  817. }
  818. /** 战令通知 */
  819. export interface manualNotify {
  820. /** 是否开启 */
  821. open: boolean;
  822. /** 开启时间 */
  823. openTime: number;
  824. /** 等级 */
  825. level: number;
  826. /** 经验 */
  827. exp: number;
  828. /** 轮次 */
  829. round: number;
  830. /** 战令数据 */
  831. list: manual[];
  832. /** 模块id */
  833. moduleid: number;
  834. }
  835. /** 购买战令 */
  836. export interface manualBuy {
  837. /** 礼包id */
  838. giftid: number;
  839. /** 模块id */
  840. moduleid: number;
  841. }
  842. /** 购买战令 */
  843. export interface manualBuyRsp {
  844. /** 错误码 */
  845. errno: number;
  846. /** 模块id */
  847. moduleid: number;
  848. }
  849. /** 抽奖 */
  850. export interface draw {
  851. /** 抽奖类型 1高级英雄 2普通英雄 3装备 */
  852. drawType: number;
  853. /** 抽奖付费方式 1免费 2召唤卷 3其它货币 */
  854. payType: number;
  855. /** 数量 */
  856. num: number;
  857. }
  858. /** 抽奖 */
  859. export interface drawRsp {
  860. /** 错误码 */
  861. errno: number;
  862. /** 抽奖类型 */
  863. drawType: number;
  864. /** 每天抽奖次数 */
  865. daily: number;
  866. /** 已免费次数 */
  867. free: number;
  868. /** 剩余多少次出特殊奖励列表 */
  869. list: number[];
  870. /** 抽奖数据 */
  871. awardList: drawAwardInfo[];
  872. }
  873. /** 抽奖数据 */
  874. export interface drawGetData {
  875. }
  876. /** 抽奖数据 */
  877. export interface drawGetDataRsp {
  878. /** 错误码 */
  879. errno: number;
  880. /** 高级英雄抽奖数据 */
  881. hero:
  882. | drawInfo
  883. | undefined;
  884. /** 普通英雄抽奖数据 */
  885. hero2:
  886. | drawInfo
  887. | undefined;
  888. /** 装备锻造数据 */
  889. equip: drawInfo | undefined;
  890. }
  891. /** 商店数据 */
  892. export interface shopData {
  893. }
  894. /** 商店数据 */
  895. export interface shopDataRsp {
  896. /** 错误码 */
  897. errno: number;
  898. /** 商店数据 */
  899. list: shopInfo[];
  900. }
  901. /** 商店购买 */
  902. export interface shopBuy {
  903. /** 商店类型 */
  904. type: number;
  905. /** 商品id */
  906. id: number;
  907. /** 商品数量 */
  908. num: number;
  909. }
  910. /** 商店购买 */
  911. export interface shopBuyRsp {
  912. /** 错误码 */
  913. errno: number;
  914. }
  915. /** 商店购买 */
  916. export interface shopNotify {
  917. /** 商店类型 */
  918. type: number;
  919. /** 商品id */
  920. id: number;
  921. /** 已购买数量 */
  922. num: number;
  923. }
  924. /** 排行榜数据 */
  925. export interface rankingData {
  926. /** 排行类型 1冒险排行 2战力排行 */
  927. type: number;
  928. }
  929. /** 排行榜数据 */
  930. export interface rankingDataRsp {
  931. /** 错误码 */
  932. errno: number;
  933. /** 排行类型 1冒险排行 2战力排行 */
  934. type: number;
  935. /** 排行数据 */
  936. list: rankingInfo[];
  937. /** 自己的数据(没有就是未上榜) */
  938. myslef: rankingInfo | undefined;
  939. }
  940. /** 杂货店数据 */
  941. export interface groceryData {
  942. /** 1体力购买 2金币购买 */
  943. type: number;
  944. }
  945. /** 杂货店数据 */
  946. export interface groceryDataRsp {
  947. /** 错误码 */
  948. errno: number;
  949. /** 杂货店数据 */
  950. data: groceryInfo | undefined;
  951. }
  952. /** 杂货店购买 */
  953. export interface groceryBuy {
  954. /** 1体力购买 2金币购买 */
  955. type: number;
  956. /** 免费还是付费 */
  957. free: boolean;
  958. }
  959. /** 杂货店购买 */
  960. export interface groceryBuyRsp {
  961. /** 错误码 */
  962. errno: number;
  963. /** 杂货店数据 */
  964. data: groceryInfo | undefined;
  965. }
  966. /** 祭坛数据 */
  967. export interface altarData {
  968. }
  969. /** 祭坛数据 */
  970. export interface altarDataRsp {
  971. /** 错误码 */
  972. errno: number;
  973. /** 前5英雄id */
  974. baseList: string[];
  975. /** 上阵英雄数据 */
  976. list: altarInfo[];
  977. /** 购买的格子数量 */
  978. buyNum: number;
  979. /** 可免费置换次数 */
  980. equipFree: number;
  981. /** 可免费置换次数 */
  982. heroFree: number;
  983. }
  984. /** 祭坛上阵 */
  985. export interface altarBattle {
  986. /** 上阵位置 */
  987. pos: number;
  988. /** 上阵英雄唯一id */
  989. sid: string;
  990. }
  991. /** 祭坛上阵 */
  992. export interface altarBattleRsp {
  993. /** 错误码 */
  994. errno: number;
  995. /** 上阵位置 */
  996. pos: number;
  997. /** 上阵位置信息 */
  998. data: altarInfo | undefined;
  999. }
  1000. /** 祭坛置换 */
  1001. export interface altarExchange {
  1002. /** 1英雄置换 2装备置换 */
  1003. type: number;
  1004. /** 唯一id */
  1005. sid: string;
  1006. }
  1007. /** 祭坛置换 */
  1008. export interface altarExchangeRsp {
  1009. /** 错误码 */
  1010. errno: number;
  1011. /** 1英雄置换 2装备置换 */
  1012. type: number;
  1013. /** 唯一id */
  1014. sid: string;
  1015. /** 置换后的模板id */
  1016. id: number;
  1017. }
  1018. /** 祭坛置换确认 */
  1019. export interface altarExchangeConfirm {
  1020. /** 1英雄置换 2装备置换 */
  1021. type: number;
  1022. /** 唯一id */
  1023. sid: string;
  1024. /** 是否置换 */
  1025. change: boolean;
  1026. }
  1027. /** 祭坛置换确认 */
  1028. export interface altarExchangeConfirmRsp {
  1029. /** 错误码 */
  1030. errno: number;
  1031. }
  1032. /** 祭坛购买上阵位 */
  1033. export interface altarBuyBattleSpace {
  1034. }
  1035. /** 祭坛购买上阵位 */
  1036. export interface altarBuyBattleSpaceRsp {
  1037. /** 错误码 */
  1038. errno: number;
  1039. /** 上阵位置 */
  1040. pos: number;
  1041. /** 上阵位置信息 */
  1042. data: altarInfo | undefined;
  1043. }
  1044. /** 祭坛重置上阵位时间 */
  1045. export interface altarResetCd {
  1046. /** 上阵位置 */
  1047. pos: number;
  1048. }
  1049. /** 祭坛重置上阵位时间 */
  1050. export interface altarResetCdRsp {
  1051. /** 错误码 */
  1052. errno: number;
  1053. /** 上阵位置 */
  1054. pos: number;
  1055. /** 上阵位置信息 */
  1056. data: altarInfo | undefined;
  1057. }
  1058. /** 遗迹数据 */
  1059. export interface relicData {
  1060. }
  1061. /** 遗迹数据 */
  1062. export interface relicDataRsp {
  1063. /** 错误码 */
  1064. errno: number;
  1065. }
  1066. /** 遗迹前往下个位置 */
  1067. export interface relicNextPos {
  1068. pos: number;
  1069. }
  1070. /** 遗迹前往下个位置 */
  1071. export interface relicNextPosRsp {
  1072. /** 错误码 */
  1073. errno: number;
  1074. }
  1075. /** 遗迹前往下一层 */
  1076. export interface relicNextLayer {
  1077. }
  1078. /** 遗迹前往下一层 */
  1079. export interface relicNextLayerRsp {
  1080. /** 错误码 */
  1081. errno: number;
  1082. }
  1083. /** 遗迹选择buff */
  1084. export interface relicSelectBuff {
  1085. }
  1086. /** 遗迹选择buff */
  1087. export interface relicSelectBuffRsp {
  1088. /** 错误码 */
  1089. errno: number;
  1090. }
  1091. /** 遗迹重置 */
  1092. export interface relicReset {
  1093. difficulty: number;
  1094. }
  1095. /** 遗迹重置 */
  1096. export interface relicResetRsp {
  1097. /** 错误码 */
  1098. errno: number;
  1099. }
  1100. /** 遗迹事件选择 */
  1101. export interface relicEventSelect {
  1102. /** 事件类型 2战斗 3温泉 4buff选择 */
  1103. type: number;
  1104. /** 战斗是否胜利 */
  1105. win: boolean;
  1106. /** 战斗消耗费用 */
  1107. cost: number;
  1108. /** 选择 */
  1109. select: number;
  1110. }
  1111. /** 遗迹事件选择 */
  1112. export interface relicEventSelectRsp {
  1113. /** 错误码 */
  1114. errno: number;
  1115. }
  1116. /** 遗迹数据推送 */
  1117. export interface relicDataNty {
  1118. /** 历史最高难度 */
  1119. maxDiff: number;
  1120. /** 当前难度 */
  1121. curDiff: number;
  1122. /** 已选buff */
  1123. buffList: number[];
  1124. /** 所在层级 */
  1125. layer: number;
  1126. /** 当前位置 */
  1127. pos: number;
  1128. /** 当前状态 */
  1129. cost: number;
  1130. /** 状态 0 结束 1选择buff */
  1131. state: number;
  1132. /** 可重置的时间 */
  1133. resetTime: number;
  1134. /** 历史路径 */
  1135. posList: number[];
  1136. /** 驻军关卡关卡id */
  1137. battleInfo: number[];
  1138. }
  1139. /** 遗迹事件推送 */
  1140. export interface relicEventNty {
  1141. /** 事件类型 2战斗 3温泉 4buff选择 */
  1142. type: number;
  1143. /** 挑战id */
  1144. battleId: number;
  1145. /** 挑战类型 1普通 2精英 3boss 7驻军 */
  1146. battleType: number;
  1147. /** 可选择的buff */
  1148. selectBuff: number[];
  1149. }
  1150. /** 活动时间 */
  1151. export interface activityTimeListNty {
  1152. /** 活动时间列表 */
  1153. list: activityTimeInfo[];
  1154. }
  1155. /** 活动配置 */
  1156. export interface activityGetConfList {
  1157. list: string[];
  1158. }
  1159. /** 活动配置 */
  1160. export interface activityGetConfListRsp {
  1161. /** 错误码 */
  1162. errno: number;
  1163. list: activityConfInfo[];
  1164. }
  1165. export interface activityGetConfNty {
  1166. list: number[];
  1167. }
  1168. /** 特权卡数据 */
  1169. export interface privilegeCardData {
  1170. }
  1171. /** 特权卡数据 */
  1172. export interface privilegeCardDataRsp {
  1173. /** 错误码 */
  1174. errno: number;
  1175. /** 特权卡数据 */
  1176. list: privilegeCardInfo[];
  1177. }
  1178. /** 特权卡购买 */
  1179. export interface privilegeCardBuy {
  1180. /** 模块id */
  1181. moduleid: number;
  1182. }
  1183. /** 特权卡购买 */
  1184. export interface privilegeCardBuyRsp {
  1185. /** 错误码 */
  1186. errno: number;
  1187. }
  1188. /** 特权卡解锁 */
  1189. export interface privilegeCardUnlockNty {
  1190. /** 解锁特权卡数据 */
  1191. data: privilegeCardInfo | undefined;
  1192. }
  1193. /** 特权卡奖励 */
  1194. export interface privilegeCardAward {
  1195. /** 模块id */
  1196. moduleid: number;
  1197. }
  1198. /** 特权卡奖励 */
  1199. export interface privilegeCardAwardRsp {
  1200. /** 模块id */
  1201. errno: number;
  1202. /** 模块id */
  1203. moduleid: number;
  1204. /** 模块id */
  1205. award: boolean;
  1206. }
  1207. /** 宝箱奖励 */
  1208. export interface boxGetAward {
  1209. /** 奖励宝箱id */
  1210. id: number;
  1211. /** 奖励id */
  1212. select: number;
  1213. /** 宝箱类型 */
  1214. type: number;
  1215. /** 数量 */
  1216. num: number;
  1217. }
  1218. /** 宝箱奖励 */
  1219. export interface boxGetAwardRsp {
  1220. /** 模块id */
  1221. errno: number;
  1222. /** 宝箱类型 */
  1223. type: number;
  1224. }
  1225. export interface firstRechargeData {
  1226. /** 模块id */
  1227. moduleid: number;
  1228. }
  1229. /** 首充礼包数据 */
  1230. export interface firstRechargeDataRsp {
  1231. /** 错误码 */
  1232. errno: number;
  1233. /** 模块id */
  1234. moduleid: number;
  1235. /** 是否购买 */
  1236. state: boolean;
  1237. /** 当前第几天 */
  1238. day: number;
  1239. /** 奖励领取数据按位 */
  1240. award: number;
  1241. }
  1242. /** 首充礼包购买 */
  1243. export interface firstRechargeBuy {
  1244. /** 模块id */
  1245. moduleid: number;
  1246. }
  1247. /** 首充礼包购买 */
  1248. export interface firstRechargeBuyRsp {
  1249. /** 错误码 */
  1250. errno: number;
  1251. /** 模块id */
  1252. moduleid: number;
  1253. }
  1254. /** 首充礼包奖励 */
  1255. export interface firstRechargeAward {
  1256. /** 模块id */
  1257. moduleid: number;
  1258. /** 领取第天的奖励 */
  1259. day: number;
  1260. }
  1261. /** 首充礼包奖励 */
  1262. export interface firstRechargeAwardRsp {
  1263. /** 错误码 */
  1264. errno: number;
  1265. /** 模块id */
  1266. moduleid: number;
  1267. /** 领奖数据 */
  1268. award: number;
  1269. }
  1270. /** 首充礼包推送 */
  1271. export interface firstRechargeNty {
  1272. /** 模块id */
  1273. moduleid: number;
  1274. /** 是否购买 */
  1275. state: boolean;
  1276. /** 当前第几天 */
  1277. day: number;
  1278. /** 奖励领取数据按位 */
  1279. award: number;
  1280. }
  1281. /** 日常副本数据 */
  1282. export interface dailyDungeonsData {
  1283. }
  1284. /** 日常副本数据 */
  1285. export interface dailyDungeonsDataRsp {
  1286. /** 错误码 */
  1287. errno: number;
  1288. /** 日常副本数据 */
  1289. list: dailyDungeonsInfo[];
  1290. }
  1291. /** 日常副本战斗开始 */
  1292. export interface dailyDungeonsStart {
  1293. type: number;
  1294. diff: number;
  1295. }
  1296. /** 日常副本战斗开始 */
  1297. export interface dailyDungeonsStartRsp {
  1298. /** 错误码 */
  1299. errno: number;
  1300. awardList: idNum[];
  1301. }
  1302. /** 日常副本战斗结束 */
  1303. export interface dailyDungeonsEnd {
  1304. /** 是否胜利 */
  1305. win: boolean;
  1306. /** 杀怪数量 */
  1307. monsterNum: number;
  1308. /** 杀boss数量 */
  1309. bossNum: number;
  1310. /** 杀精英数量 */
  1311. eliteNum: number;
  1312. }
  1313. /** 日常副本战斗结束 */
  1314. export interface dailyDungeonsEndRsp {
  1315. /** 错误码 */
  1316. errno: number;
  1317. /** 副本数据 */
  1318. data: dailyDungeonsInfo | undefined;
  1319. }
  1320. /** 日常副本扫荡 */
  1321. export interface dailyDungeonsSweep {
  1322. type: number;
  1323. diff: number;
  1324. }
  1325. /** 日常副本扫荡 */
  1326. export interface dailyDungeonsSweepRsp {
  1327. /** 错误码 */
  1328. errno: number;
  1329. /** 副本数据 */
  1330. data: dailyDungeonsInfo | undefined;
  1331. }
  1332. /** 冒险礼包数据 */
  1333. export interface advGiftData {
  1334. }
  1335. /** 冒险礼包数据 */
  1336. export interface advGiftDataRsp {
  1337. /** 错误码 */
  1338. errno: number;
  1339. }
  1340. /** 冒险礼包购买 */
  1341. export interface advGiftBuy {
  1342. /** 礼包id */
  1343. id: number;
  1344. }
  1345. /** 冒险礼包购买 */
  1346. export interface advGiftBuyRsp {
  1347. /** 错误码 */
  1348. errno: number;
  1349. }
  1350. /** 冒险礼包推送 */
  1351. export interface advGiftNty {
  1352. /** 已购买的礼包数据 */
  1353. list: idNum[];
  1354. }
  1355. /** 弹窗礼包数据 */
  1356. export interface popGiftData {
  1357. }
  1358. /** 弹窗礼包数据 */
  1359. export interface popGiftDataRsp {
  1360. /** 错误码 */
  1361. errno: number;
  1362. /** 弹窗礼包数据 */
  1363. list: popGiftInfo[];
  1364. }
  1365. /** 弹窗礼包购买 */
  1366. export interface popGiftBuy {
  1367. /** 礼包id */
  1368. id: number;
  1369. }
  1370. /** 弹窗礼包购买 */
  1371. export interface popGiftBuyRsp {
  1372. /** 错误码 */
  1373. errno: number;
  1374. }
  1375. /** 弹窗礼包推送 */
  1376. export interface popGiftNty {
  1377. /** 弹窗礼包数据 */
  1378. data: popGiftInfo | undefined;
  1379. }
  1380. /** 弹窗礼包数据变化 */
  1381. export interface popGiftChangeNty {
  1382. /** 弹窗礼包数据 */
  1383. data: popGiftInfo | undefined;
  1384. }
  1385. /** 基金数据 */
  1386. export interface fundData {
  1387. /** 模块id */
  1388. moduleid: number;
  1389. }
  1390. /** 基金数据 */
  1391. export interface fundDataRsp {
  1392. /** 错误码 */
  1393. errno: number;
  1394. /** 模块id */
  1395. moduleid: number;
  1396. /** 是否购买 */
  1397. state: boolean;
  1398. /** 领奖数据 */
  1399. award: number;
  1400. /** 领奖数据 */
  1401. freeAward: number;
  1402. /** 当前进度 */
  1403. progress: number;
  1404. }
  1405. /** 基金购买 */
  1406. export interface fundBuy {
  1407. /** 模块id */
  1408. moduleid: number;
  1409. }
  1410. /** 基金购买 */
  1411. export interface fundBuyRsp {
  1412. /** 错误码 */
  1413. errno: number;
  1414. /** 模块id */
  1415. moduleid: number;
  1416. }
  1417. /** 基金奖励 */
  1418. export interface fundAward {
  1419. /** 模块id */
  1420. moduleid: number;
  1421. }
  1422. /** 基金奖励 */
  1423. export interface fundAwardRsp {
  1424. /** 错误码 */
  1425. errno: number;
  1426. /** 模块id */
  1427. moduleid: number;
  1428. /** 领奖数据 */
  1429. award: number;
  1430. /** 领奖数据 */
  1431. freeAward: number;
  1432. }
  1433. /** 基金推送 */
  1434. export interface fundNty {
  1435. /** 模块id */
  1436. moduleid: number;
  1437. /** 是否购买 */
  1438. state: boolean;
  1439. /** 领奖数据 */
  1440. award: number;
  1441. /** 领奖数据 */
  1442. freeAward: number;
  1443. /** 当前进度 */
  1444. progress: number;
  1445. }
  1446. /** 连续充值数据 */
  1447. export interface keepRechargeData {
  1448. }
  1449. /** 连续充值数据 */
  1450. export interface keepRechargeDataRsp {
  1451. /** 错误码 */
  1452. errno: number;
  1453. /** 连续充值天数 */
  1454. day: number;
  1455. /** 当天充值数量 */
  1456. num: number;
  1457. /** 领取奖励信息(按位存) */
  1458. award: number;
  1459. }
  1460. /** 连续充值奖励 */
  1461. export interface keepRechargeAward {
  1462. /** 领取奖励的天数 */
  1463. day: number;
  1464. }
  1465. /** 连续充值奖励 */
  1466. export interface keepRechargeAwardRsp {
  1467. /** 错误码 */
  1468. errno: number;
  1469. /** 领取奖励信息(按位存) */
  1470. award: number;
  1471. }
  1472. /** 红点数据 */
  1473. export interface getRedPointList {
  1474. }
  1475. /** 红点数据 */
  1476. export interface getRedPointListRsp {
  1477. /** 错误码 */
  1478. errno: number;
  1479. /** 红点数据 */
  1480. list: redPointInfo[];
  1481. }
  1482. /** 充值结果 */
  1483. export interface rechargeResult {
  1484. /** 服务器订单号 */
  1485. orderId: string;
  1486. /** 支付平台返回的订单号 */
  1487. payOrderId: string;
  1488. /** 支付平台返回的purchaseToken */
  1489. purchaseToken: string;
  1490. /** 支付方式 */
  1491. payType: string;
  1492. /** 计费点 */
  1493. cfgId: number;
  1494. }
  1495. /** 充值结果 */
  1496. export interface rechargeResultRsp {
  1497. /** 错误码 */
  1498. errno: number;
  1499. }
  1500. /** 领取在线奖励 */
  1501. export interface onlineAwardGetAward {
  1502. /** 领取第几个在线奖励 */
  1503. pos: number;
  1504. }
  1505. /** 领取在线奖励 */
  1506. export interface onlineAwardGetAwardRsp {
  1507. /** 错误码 */
  1508. errno: number;
  1509. /** 领取奖励数据 */
  1510. award: number;
  1511. }
  1512. /** 在线奖励数据 */
  1513. export interface onlineAwardGetData {
  1514. }
  1515. /** 在线奖励数据 */
  1516. export interface onlineAwardGetDataRsp {
  1517. /** 错误码 */
  1518. errno: number;
  1519. }
  1520. /** 在线奖励数据推送 */
  1521. export interface onlineAwardNty {
  1522. /** 是否开启 */
  1523. open: boolean;
  1524. /** 在线时长 */
  1525. time: number;
  1526. /** 领取奖励数据 */
  1527. award: number;
  1528. }
  1529. /** 战斗加速数据 */
  1530. export interface speedUpData {
  1531. }
  1532. /** 战斗加速数据 */
  1533. export interface speedUpDataRsp {
  1534. /** 错误码 */
  1535. errno: number;
  1536. /** 剩余加速时间 */
  1537. time: number;
  1538. }
  1539. /** 战斗加速时间购买 */
  1540. export interface speedUpBuy {
  1541. /** 是否广告观看 */
  1542. free: boolean;
  1543. }
  1544. /** 战斗加速时间购买 */
  1545. export interface speedUpBuyRsp {
  1546. /** 错误码 */
  1547. errno: number;
  1548. /** 剩余加速时间 */
  1549. time: number;
  1550. }
  1551. /** 主城技能升级 */
  1552. export interface citySkillUpgrade {
  1553. /** 技能id */
  1554. id: number;
  1555. }
  1556. /** 主城技能升级 */
  1557. export interface citySkillUpgradeRsp {
  1558. /** 错误码 */
  1559. errno: number;
  1560. /** 技能id */
  1561. id: number;
  1562. }
  1563. /** 主城技能上阵 */
  1564. export interface citySkillBattle {
  1565. /** 技能id */
  1566. id: number;
  1567. }
  1568. /** 主城技能上阵 */
  1569. export interface citySkillBattleRsp {
  1570. /** 错误码 */
  1571. errno: number;
  1572. /** 技能id */
  1573. id: number;
  1574. }
  1575. /** 建筑探索 */
  1576. export interface buildingExplore {
  1577. /** 建筑id */
  1578. id: number;
  1579. }
  1580. /** 建筑探索 */
  1581. export interface buildingExploreRsp {
  1582. /** 错误码 */
  1583. errno: number;
  1584. /** 建筑数据 */
  1585. data: building | undefined;
  1586. }
  1587. /** 领取自动探索奖励 */
  1588. export interface buildingAutoExploreAward {
  1589. /** 建筑id */
  1590. id: number;
  1591. }
  1592. /** 领取自动探索奖励 */
  1593. export interface buildingAutoExploreAwardRsp {
  1594. /** 错误码 */
  1595. errno: number;
  1596. /** 建筑数据 */
  1597. data: building | undefined;
  1598. }
  1599. /** 建筑探索上阵 */
  1600. export interface buildingExploreBattle {
  1601. /** 建筑id */
  1602. id: number;
  1603. /** 上阵数据 */
  1604. list: string[];
  1605. }
  1606. /** 建筑探索上阵 */
  1607. export interface buildingExploreBattleRsp {
  1608. /** 错误码 */
  1609. errno: number;
  1610. /** 建筑数据 */
  1611. data: building | undefined;
  1612. }
  1613. /** 建筑自动探索设置 */
  1614. export interface buildingAutoExploreOption {
  1615. /** 建筑id */
  1616. id: number;
  1617. /** 是否开启 */
  1618. open: boolean;
  1619. }
  1620. /** 建筑自动探索设置 */
  1621. export interface buildingAutoExploreOptionRsp {
  1622. /** 错误码 */
  1623. errno: number;
  1624. /** 建筑数据 */
  1625. data: building | undefined;
  1626. }
  1627. /** 等级礼包数据 */
  1628. export interface levelGiftData {
  1629. }
  1630. /** 等级礼包数据 */
  1631. export interface levelGiftDataRsp {
  1632. /** 错误码 */
  1633. errno: number;
  1634. }
  1635. /** 等级礼包购买 */
  1636. export interface levelGiftBuy {
  1637. /** 礼包id */
  1638. id: number;
  1639. }
  1640. /** 等级礼包购买 */
  1641. export interface levelGiftBuyRsp {
  1642. /** 错误码 */
  1643. errno: number;
  1644. }
  1645. /** 等级礼包推送 */
  1646. export interface levelGiftNty {
  1647. /** 已购买的礼包数据 */
  1648. list: idNum[];
  1649. }
  1650. /** 等级礼包取消红点 */
  1651. export interface levelGiftDelRedPoint {
  1652. }
  1653. /** 等级礼包取消红点 */
  1654. export interface levelGiftDelRedPointRsp {
  1655. /** 错误码 */
  1656. errno: number;
  1657. }
  1658. /** 千抽活动数据 */
  1659. export interface lotteryData {
  1660. }
  1661. /** 千抽活动数据 */
  1662. export interface lotteryDataRsp {
  1663. /** 错误码 */
  1664. errno: number;
  1665. }
  1666. /** 千抽活动奖励 */
  1667. export interface lotteryAward {
  1668. /** 是否为免费奖励 */
  1669. free: boolean;
  1670. }
  1671. /** 千抽活动奖励 */
  1672. export interface lotteryAwardRsp {
  1673. /** 错误码 */
  1674. errno: number;
  1675. /** 是否为免费奖励 */
  1676. free: boolean;
  1677. /** 领取进度 */
  1678. award: number;
  1679. }
  1680. /** 千抽活动购买 */
  1681. export interface lotteryBuy {
  1682. }
  1683. /** 千抽活动购买 */
  1684. export interface lotteryBuyRsp {
  1685. /** 错误码 */
  1686. errno: number;
  1687. }
  1688. /** 千抽活动推送 */
  1689. export interface lotteryNty {
  1690. /** 状态0未开启 1开启 2关闭 */
  1691. state: number;
  1692. /** 免费奖励领取进度 */
  1693. free: number;
  1694. /** 付费奖励领取进度-1为未解锁. */
  1695. award: number;
  1696. /** 第几天 */
  1697. day: number;
  1698. }
  1699. /** 开服排行活动数据 */
  1700. export interface actRankData {
  1701. /** 排行活动id */
  1702. id: number;
  1703. }
  1704. /** 开服排行活动数据 */
  1705. export interface actRankDataRsp {
  1706. /** 错误码 */
  1707. errno: number;
  1708. /** 排行数据 */
  1709. list: rankingInfo[];
  1710. }
  1711. /** 开服宝藏活动数据 */
  1712. export interface treasureGetData {
  1713. }
  1714. /** 开服宝藏活动数据 */
  1715. export interface treasureGetDataRsp {
  1716. /** 错误码 */
  1717. errno: number;
  1718. /** 购买次数 */
  1719. buy: number;
  1720. /** 签到进度 */
  1721. sign: number;
  1722. /** 已抽到数据 */
  1723. list: number[];
  1724. /** 是否抽到大奖 */
  1725. treasure: boolean;
  1726. }
  1727. /** 开服宝藏活动抽奖 */
  1728. export interface treasureDraw {
  1729. }
  1730. /** 开服宝藏活动抽奖 */
  1731. export interface treasureDrawRsp {
  1732. /** 错误码 */
  1733. errno: number;
  1734. /** 0为大奖 */
  1735. pos: number;
  1736. }
  1737. /** 开服宝藏活动签到 */
  1738. export interface treasureSign {
  1739. }
  1740. /** 开服宝藏活动签到 */
  1741. export interface treasureSignRsp {
  1742. /** 错误码 */
  1743. errno: number;
  1744. /** 签到进度 */
  1745. sign: number;
  1746. }
  1747. /** 开服宝藏活动购买 */
  1748. export interface treasureBuy {
  1749. }
  1750. /** 开服宝藏活动购买 */
  1751. export interface treasureBuyRsp {
  1752. /** 错误码 */
  1753. errno: number;
  1754. /** 购买次数 */
  1755. buy: number;
  1756. }
  1757. function createBaseping(): ping {
  1758. return {};
  1759. }
  1760. export const ping = {
  1761. fromJSON(_: any): ping {
  1762. return {};
  1763. },
  1764. toJSON(_: ping): unknown {
  1765. const obj: any = {};
  1766. return obj;
  1767. },
  1768. create<I extends Exact<DeepPartial<ping>, I>>(base?: I): ping {
  1769. return ping.fromPartial(base ?? ({} as any));
  1770. },
  1771. fromPartial<I extends Exact<DeepPartial<ping>, I>>(_: I): ping {
  1772. const message = createBaseping();
  1773. return message;
  1774. },
  1775. };
  1776. function createBasepingRsp(): pingRsp {
  1777. return { time: 0 };
  1778. }
  1779. export const pingRsp = {
  1780. fromJSON(object: any): pingRsp {
  1781. return { time: isSet(object.time) ? globalThis.Number(object.time) : 0 };
  1782. },
  1783. toJSON(message: pingRsp): unknown {
  1784. const obj: any = {};
  1785. if (message.time !== 0) {
  1786. obj.time = Math.round(message.time);
  1787. }
  1788. return obj;
  1789. },
  1790. create<I extends Exact<DeepPartial<pingRsp>, I>>(base?: I): pingRsp {
  1791. return pingRsp.fromPartial(base ?? ({} as any));
  1792. },
  1793. fromPartial<I extends Exact<DeepPartial<pingRsp>, I>>(object: I): pingRsp {
  1794. const message = createBasepingRsp();
  1795. message.time = object.time ?? 0;
  1796. return message;
  1797. },
  1798. };
  1799. function createBaselogin(): login {
  1800. return { sid: 0, account: "", channel: "" };
  1801. }
  1802. export const login = {
  1803. fromJSON(object: any): login {
  1804. return {
  1805. sid: isSet(object.sid) ? globalThis.Number(object.sid) : 0,
  1806. account: isSet(object.account) ? globalThis.String(object.account) : "",
  1807. channel: isSet(object.channel) ? globalThis.String(object.channel) : "",
  1808. };
  1809. },
  1810. toJSON(message: login): unknown {
  1811. const obj: any = {};
  1812. if (message.sid !== 0) {
  1813. obj.sid = Math.round(message.sid);
  1814. }
  1815. if (message.account !== "") {
  1816. obj.account = message.account;
  1817. }
  1818. if (message.channel !== "") {
  1819. obj.channel = message.channel;
  1820. }
  1821. return obj;
  1822. },
  1823. create<I extends Exact<DeepPartial<login>, I>>(base?: I): login {
  1824. return login.fromPartial(base ?? ({} as any));
  1825. },
  1826. fromPartial<I extends Exact<DeepPartial<login>, I>>(object: I): login {
  1827. const message = createBaselogin();
  1828. message.sid = object.sid ?? 0;
  1829. message.account = object.account ?? "";
  1830. message.channel = object.channel ?? "";
  1831. return message;
  1832. },
  1833. };
  1834. function createBaseloginRsp(): loginRsp {
  1835. return { errno: 0 };
  1836. }
  1837. export const loginRsp = {
  1838. fromJSON(object: any): loginRsp {
  1839. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  1840. },
  1841. toJSON(message: loginRsp): unknown {
  1842. const obj: any = {};
  1843. if (message.errno !== 0) {
  1844. obj.errno = Math.round(message.errno);
  1845. }
  1846. return obj;
  1847. },
  1848. create<I extends Exact<DeepPartial<loginRsp>, I>>(base?: I): loginRsp {
  1849. return loginRsp.fromPartial(base ?? ({} as any));
  1850. },
  1851. fromPartial<I extends Exact<DeepPartial<loginRsp>, I>>(object: I): loginRsp {
  1852. const message = createBaseloginRsp();
  1853. message.errno = object.errno ?? 0;
  1854. return message;
  1855. },
  1856. };
  1857. function createBasecreate(): create {
  1858. return { nickname: "" };
  1859. }
  1860. export const create = {
  1861. fromJSON(object: any): create {
  1862. return { nickname: isSet(object.nickname) ? globalThis.String(object.nickname) : "" };
  1863. },
  1864. toJSON(message: create): unknown {
  1865. const obj: any = {};
  1866. if (message.nickname !== "") {
  1867. obj.nickname = message.nickname;
  1868. }
  1869. return obj;
  1870. },
  1871. create<I extends Exact<DeepPartial<create>, I>>(base?: I): create {
  1872. return create.fromPartial(base ?? ({} as any));
  1873. },
  1874. fromPartial<I extends Exact<DeepPartial<create>, I>>(object: I): create {
  1875. const message = createBasecreate();
  1876. message.nickname = object.nickname ?? "";
  1877. return message;
  1878. },
  1879. };
  1880. function createBasecreateRsp(): createRsp {
  1881. return { errno: 0 };
  1882. }
  1883. export const createRsp = {
  1884. fromJSON(object: any): createRsp {
  1885. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  1886. },
  1887. toJSON(message: createRsp): unknown {
  1888. const obj: any = {};
  1889. if (message.errno !== 0) {
  1890. obj.errno = Math.round(message.errno);
  1891. }
  1892. return obj;
  1893. },
  1894. create<I extends Exact<DeepPartial<createRsp>, I>>(base?: I): createRsp {
  1895. return createRsp.fromPartial(base ?? ({} as any));
  1896. },
  1897. fromPartial<I extends Exact<DeepPartial<createRsp>, I>>(object: I): createRsp {
  1898. const message = createBasecreateRsp();
  1899. message.errno = object.errno ?? 0;
  1900. return message;
  1901. },
  1902. };
  1903. function createBaseuser(): user {
  1904. return { uid: "", nickname: "", level: 0, exp: 0, avatar: 0, svrtime: 0, renameTime: 0, createtime: 0, currency: [] };
  1905. }
  1906. export const user = {
  1907. fromJSON(object: any): user {
  1908. return {
  1909. uid: isSet(object.uid) ? globalThis.String(object.uid) : "",
  1910. nickname: isSet(object.nickname) ? globalThis.String(object.nickname) : "",
  1911. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  1912. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  1913. avatar: isSet(object.avatar) ? globalThis.Number(object.avatar) : 0,
  1914. svrtime: isSet(object.svrtime) ? globalThis.Number(object.svrtime) : 0,
  1915. renameTime: isSet(object.renameTime) ? globalThis.Number(object.renameTime) : 0,
  1916. createtime: isSet(object.createtime) ? globalThis.Number(object.createtime) : 0,
  1917. currency: globalThis.Array.isArray(object?.currency) ? object.currency.map((e: any) => idNum.fromJSON(e)) : [],
  1918. };
  1919. },
  1920. toJSON(message: user): unknown {
  1921. const obj: any = {};
  1922. if (message.uid !== "") {
  1923. obj.uid = message.uid;
  1924. }
  1925. if (message.nickname !== "") {
  1926. obj.nickname = message.nickname;
  1927. }
  1928. if (message.level !== 0) {
  1929. obj.level = Math.round(message.level);
  1930. }
  1931. if (message.exp !== 0) {
  1932. obj.exp = Math.round(message.exp);
  1933. }
  1934. if (message.avatar !== 0) {
  1935. obj.avatar = Math.round(message.avatar);
  1936. }
  1937. if (message.svrtime !== 0) {
  1938. obj.svrtime = Math.round(message.svrtime);
  1939. }
  1940. if (message.renameTime !== 0) {
  1941. obj.renameTime = Math.round(message.renameTime);
  1942. }
  1943. if (message.createtime !== 0) {
  1944. obj.createtime = Math.round(message.createtime);
  1945. }
  1946. if (message.currency?.length) {
  1947. obj.currency = message.currency.map((e) => idNum.toJSON(e));
  1948. }
  1949. return obj;
  1950. },
  1951. create<I extends Exact<DeepPartial<user>, I>>(base?: I): user {
  1952. return user.fromPartial(base ?? ({} as any));
  1953. },
  1954. fromPartial<I extends Exact<DeepPartial<user>, I>>(object: I): user {
  1955. const message = createBaseuser();
  1956. message.uid = object.uid ?? "";
  1957. message.nickname = object.nickname ?? "";
  1958. message.level = object.level ?? 0;
  1959. message.exp = object.exp ?? 0;
  1960. message.avatar = object.avatar ?? 0;
  1961. message.svrtime = object.svrtime ?? 0;
  1962. message.renameTime = object.renameTime ?? 0;
  1963. message.createtime = object.createtime ?? 0;
  1964. message.currency = object.currency?.map((e) => idNum.fromPartial(e)) || [];
  1965. return message;
  1966. },
  1967. };
  1968. function createBaserewardInfo(): rewardInfo {
  1969. return { flags: "", added: undefined };
  1970. }
  1971. export const rewardInfo = {
  1972. fromJSON(object: any): rewardInfo {
  1973. return {
  1974. flags: isSet(object.flags) ? globalThis.String(object.flags) : "",
  1975. added: isSet(object.added) ? reward.fromJSON(object.added) : undefined,
  1976. };
  1977. },
  1978. toJSON(message: rewardInfo): unknown {
  1979. const obj: any = {};
  1980. if (message.flags !== "") {
  1981. obj.flags = message.flags;
  1982. }
  1983. if (message.added !== undefined) {
  1984. obj.added = reward.toJSON(message.added);
  1985. }
  1986. return obj;
  1987. },
  1988. create<I extends Exact<DeepPartial<rewardInfo>, I>>(base?: I): rewardInfo {
  1989. return rewardInfo.fromPartial(base ?? ({} as any));
  1990. },
  1991. fromPartial<I extends Exact<DeepPartial<rewardInfo>, I>>(object: I): rewardInfo {
  1992. const message = createBaserewardInfo();
  1993. message.flags = object.flags ?? "";
  1994. message.added = (object.added !== undefined && object.added !== null)
  1995. ? reward.fromPartial(object.added)
  1996. : undefined;
  1997. return message;
  1998. },
  1999. };
  2000. function createBasecityChange(): cityChange {
  2001. return { currency: undefined, time: 0 };
  2002. }
  2003. export const cityChange = {
  2004. fromJSON(object: any): cityChange {
  2005. return {
  2006. currency: isSet(object.currency) ? idNum.fromJSON(object.currency) : undefined,
  2007. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  2008. };
  2009. },
  2010. toJSON(message: cityChange): unknown {
  2011. const obj: any = {};
  2012. if (message.currency !== undefined) {
  2013. obj.currency = idNum.toJSON(message.currency);
  2014. }
  2015. if (message.time !== 0) {
  2016. obj.time = Math.round(message.time);
  2017. }
  2018. return obj;
  2019. },
  2020. create<I extends Exact<DeepPartial<cityChange>, I>>(base?: I): cityChange {
  2021. return cityChange.fromPartial(base ?? ({} as any));
  2022. },
  2023. fromPartial<I extends Exact<DeepPartial<cityChange>, I>>(object: I): cityChange {
  2024. const message = createBasecityChange();
  2025. message.currency = (object.currency !== undefined && object.currency !== null)
  2026. ? idNum.fromPartial(object.currency)
  2027. : undefined;
  2028. message.time = object.time ?? 0;
  2029. return message;
  2030. },
  2031. };
  2032. function createBasepayCurrency(): payCurrency {
  2033. return { now: [], pay: [] };
  2034. }
  2035. export const payCurrency = {
  2036. fromJSON(object: any): payCurrency {
  2037. return {
  2038. now: globalThis.Array.isArray(object?.now) ? object.now.map((e: any) => idNum.fromJSON(e)) : [],
  2039. pay: globalThis.Array.isArray(object?.pay) ? object.pay.map((e: any) => idNum.fromJSON(e)) : [],
  2040. };
  2041. },
  2042. toJSON(message: payCurrency): unknown {
  2043. const obj: any = {};
  2044. if (message.now?.length) {
  2045. obj.now = message.now.map((e) => idNum.toJSON(e));
  2046. }
  2047. if (message.pay?.length) {
  2048. obj.pay = message.pay.map((e) => idNum.toJSON(e));
  2049. }
  2050. return obj;
  2051. },
  2052. create<I extends Exact<DeepPartial<payCurrency>, I>>(base?: I): payCurrency {
  2053. return payCurrency.fromPartial(base ?? ({} as any));
  2054. },
  2055. fromPartial<I extends Exact<DeepPartial<payCurrency>, I>>(object: I): payCurrency {
  2056. const message = createBasepayCurrency();
  2057. message.now = object.now?.map((e) => idNum.fromPartial(e)) || [];
  2058. message.pay = object.pay?.map((e) => idNum.fromPartial(e)) || [];
  2059. return message;
  2060. },
  2061. };
  2062. function createBasepayDebrisNty(): payDebrisNty {
  2063. return { list: [] };
  2064. }
  2065. export const payDebrisNty = {
  2066. fromJSON(object: any): payDebrisNty {
  2067. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => idNum.fromJSON(e)) : [] };
  2068. },
  2069. toJSON(message: payDebrisNty): unknown {
  2070. const obj: any = {};
  2071. if (message.list?.length) {
  2072. obj.list = message.list.map((e) => idNum.toJSON(e));
  2073. }
  2074. return obj;
  2075. },
  2076. create<I extends Exact<DeepPartial<payDebrisNty>, I>>(base?: I): payDebrisNty {
  2077. return payDebrisNty.fromPartial(base ?? ({} as any));
  2078. },
  2079. fromPartial<I extends Exact<DeepPartial<payDebrisNty>, I>>(object: I): payDebrisNty {
  2080. const message = createBasepayDebrisNty();
  2081. message.list = object.list?.map((e) => idNum.fromPartial(e)) || [];
  2082. return message;
  2083. },
  2084. };
  2085. function createBaseexceptionNty(): exceptionNty {
  2086. return { errno: 0 };
  2087. }
  2088. export const exceptionNty = {
  2089. fromJSON(object: any): exceptionNty {
  2090. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2091. },
  2092. toJSON(message: exceptionNty): unknown {
  2093. const obj: any = {};
  2094. if (message.errno !== 0) {
  2095. obj.errno = Math.round(message.errno);
  2096. }
  2097. return obj;
  2098. },
  2099. create<I extends Exact<DeepPartial<exceptionNty>, I>>(base?: I): exceptionNty {
  2100. return exceptionNty.fromPartial(base ?? ({} as any));
  2101. },
  2102. fromPartial<I extends Exact<DeepPartial<exceptionNty>, I>>(object: I): exceptionNty {
  2103. const message = createBaseexceptionNty();
  2104. message.errno = object.errno ?? 0;
  2105. return message;
  2106. },
  2107. };
  2108. function createBasecreateOrderNty(): createOrderNty {
  2109. return { id: "", cfid: 0 };
  2110. }
  2111. export const createOrderNty = {
  2112. fromJSON(object: any): createOrderNty {
  2113. return {
  2114. id: isSet(object.id) ? globalThis.String(object.id) : "",
  2115. cfid: isSet(object.cfid) ? globalThis.Number(object.cfid) : 0,
  2116. };
  2117. },
  2118. toJSON(message: createOrderNty): unknown {
  2119. const obj: any = {};
  2120. if (message.id !== "") {
  2121. obj.id = message.id;
  2122. }
  2123. if (message.cfid !== 0) {
  2124. obj.cfid = Math.round(message.cfid);
  2125. }
  2126. return obj;
  2127. },
  2128. create<I extends Exact<DeepPartial<createOrderNty>, I>>(base?: I): createOrderNty {
  2129. return createOrderNty.fromPartial(base ?? ({} as any));
  2130. },
  2131. fromPartial<I extends Exact<DeepPartial<createOrderNty>, I>>(object: I): createOrderNty {
  2132. const message = createBasecreateOrderNty();
  2133. message.id = object.id ?? "";
  2134. message.cfid = object.cfid ?? 0;
  2135. return message;
  2136. },
  2137. };
  2138. function createBasecityData(): cityData {
  2139. return {};
  2140. }
  2141. export const cityData = {
  2142. fromJSON(_: any): cityData {
  2143. return {};
  2144. },
  2145. toJSON(_: cityData): unknown {
  2146. const obj: any = {};
  2147. return obj;
  2148. },
  2149. create<I extends Exact<DeepPartial<cityData>, I>>(base?: I): cityData {
  2150. return cityData.fromPartial(base ?? ({} as any));
  2151. },
  2152. fromPartial<I extends Exact<DeepPartial<cityData>, I>>(_: I): cityData {
  2153. const message = createBasecityData();
  2154. return message;
  2155. },
  2156. };
  2157. function createBasecityDataRsp(): cityDataRsp {
  2158. return { errno: 0, time: 0, list: [], skillList: [], skillid: 0 };
  2159. }
  2160. export const cityDataRsp = {
  2161. fromJSON(object: any): cityDataRsp {
  2162. return {
  2163. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2164. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  2165. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => building.fromJSON(e)) : [],
  2166. skillList: globalThis.Array.isArray(object?.skillList)
  2167. ? object.skillList.map((e: any) => globalThis.Number(e))
  2168. : [],
  2169. skillid: isSet(object.skillid) ? globalThis.Number(object.skillid) : 0,
  2170. };
  2171. },
  2172. toJSON(message: cityDataRsp): unknown {
  2173. const obj: any = {};
  2174. if (message.errno !== 0) {
  2175. obj.errno = Math.round(message.errno);
  2176. }
  2177. if (message.time !== 0) {
  2178. obj.time = Math.round(message.time);
  2179. }
  2180. if (message.list?.length) {
  2181. obj.list = message.list.map((e) => building.toJSON(e));
  2182. }
  2183. if (message.skillList?.length) {
  2184. obj.skillList = message.skillList.map((e) => Math.round(e));
  2185. }
  2186. if (message.skillid !== 0) {
  2187. obj.skillid = Math.round(message.skillid);
  2188. }
  2189. return obj;
  2190. },
  2191. create<I extends Exact<DeepPartial<cityDataRsp>, I>>(base?: I): cityDataRsp {
  2192. return cityDataRsp.fromPartial(base ?? ({} as any));
  2193. },
  2194. fromPartial<I extends Exact<DeepPartial<cityDataRsp>, I>>(object: I): cityDataRsp {
  2195. const message = createBasecityDataRsp();
  2196. message.errno = object.errno ?? 0;
  2197. message.time = object.time ?? 0;
  2198. message.list = object.list?.map((e) => building.fromPartial(e)) || [];
  2199. message.skillList = object.skillList?.map((e) => e) || [];
  2200. message.skillid = object.skillid ?? 0;
  2201. return message;
  2202. },
  2203. };
  2204. function createBasecityDataSend(): cityDataSend {
  2205. return { time: 0, list: [] };
  2206. }
  2207. export const cityDataSend = {
  2208. fromJSON(object: any): cityDataSend {
  2209. return {
  2210. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  2211. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => building.fromJSON(e)) : [],
  2212. };
  2213. },
  2214. toJSON(message: cityDataSend): unknown {
  2215. const obj: any = {};
  2216. if (message.time !== 0) {
  2217. obj.time = Math.round(message.time);
  2218. }
  2219. if (message.list?.length) {
  2220. obj.list = message.list.map((e) => building.toJSON(e));
  2221. }
  2222. return obj;
  2223. },
  2224. create<I extends Exact<DeepPartial<cityDataSend>, I>>(base?: I): cityDataSend {
  2225. return cityDataSend.fromPartial(base ?? ({} as any));
  2226. },
  2227. fromPartial<I extends Exact<DeepPartial<cityDataSend>, I>>(object: I): cityDataSend {
  2228. const message = createBasecityDataSend();
  2229. message.time = object.time ?? 0;
  2230. message.list = object.list?.map((e) => building.fromPartial(e)) || [];
  2231. return message;
  2232. },
  2233. };
  2234. function createBasebuildingUpgrade(): buildingUpgrade {
  2235. return { id: 0 };
  2236. }
  2237. export const buildingUpgrade = {
  2238. fromJSON(object: any): buildingUpgrade {
  2239. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  2240. },
  2241. toJSON(message: buildingUpgrade): unknown {
  2242. const obj: any = {};
  2243. if (message.id !== 0) {
  2244. obj.id = Math.round(message.id);
  2245. }
  2246. return obj;
  2247. },
  2248. create<I extends Exact<DeepPartial<buildingUpgrade>, I>>(base?: I): buildingUpgrade {
  2249. return buildingUpgrade.fromPartial(base ?? ({} as any));
  2250. },
  2251. fromPartial<I extends Exact<DeepPartial<buildingUpgrade>, I>>(object: I): buildingUpgrade {
  2252. const message = createBasebuildingUpgrade();
  2253. message.id = object.id ?? 0;
  2254. return message;
  2255. },
  2256. };
  2257. function createBasebuildingUpgradeRsp(): buildingUpgradeRsp {
  2258. return { errno: 0, data: undefined };
  2259. }
  2260. export const buildingUpgradeRsp = {
  2261. fromJSON(object: any): buildingUpgradeRsp {
  2262. return {
  2263. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2264. data: isSet(object.data) ? building.fromJSON(object.data) : undefined,
  2265. };
  2266. },
  2267. toJSON(message: buildingUpgradeRsp): unknown {
  2268. const obj: any = {};
  2269. if (message.errno !== 0) {
  2270. obj.errno = Math.round(message.errno);
  2271. }
  2272. if (message.data !== undefined) {
  2273. obj.data = building.toJSON(message.data);
  2274. }
  2275. return obj;
  2276. },
  2277. create<I extends Exact<DeepPartial<buildingUpgradeRsp>, I>>(base?: I): buildingUpgradeRsp {
  2278. return buildingUpgradeRsp.fromPartial(base ?? ({} as any));
  2279. },
  2280. fromPartial<I extends Exact<DeepPartial<buildingUpgradeRsp>, I>>(object: I): buildingUpgradeRsp {
  2281. const message = createBasebuildingUpgradeRsp();
  2282. message.errno = object.errno ?? 0;
  2283. message.data = (object.data !== undefined && object.data !== null) ? building.fromPartial(object.data) : undefined;
  2284. return message;
  2285. },
  2286. };
  2287. function createBasebuildingOneKey(): buildingOneKey {
  2288. return {};
  2289. }
  2290. export const buildingOneKey = {
  2291. fromJSON(_: any): buildingOneKey {
  2292. return {};
  2293. },
  2294. toJSON(_: buildingOneKey): unknown {
  2295. const obj: any = {};
  2296. return obj;
  2297. },
  2298. create<I extends Exact<DeepPartial<buildingOneKey>, I>>(base?: I): buildingOneKey {
  2299. return buildingOneKey.fromPartial(base ?? ({} as any));
  2300. },
  2301. fromPartial<I extends Exact<DeepPartial<buildingOneKey>, I>>(_: I): buildingOneKey {
  2302. const message = createBasebuildingOneKey();
  2303. return message;
  2304. },
  2305. };
  2306. function createBasebuildingOneKeyRsp(): buildingOneKeyRsp {
  2307. return { errno: 0, list: [] };
  2308. }
  2309. export const buildingOneKeyRsp = {
  2310. fromJSON(object: any): buildingOneKeyRsp {
  2311. return {
  2312. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2313. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => building.fromJSON(e)) : [],
  2314. };
  2315. },
  2316. toJSON(message: buildingOneKeyRsp): unknown {
  2317. const obj: any = {};
  2318. if (message.errno !== 0) {
  2319. obj.errno = Math.round(message.errno);
  2320. }
  2321. if (message.list?.length) {
  2322. obj.list = message.list.map((e) => building.toJSON(e));
  2323. }
  2324. return obj;
  2325. },
  2326. create<I extends Exact<DeepPartial<buildingOneKeyRsp>, I>>(base?: I): buildingOneKeyRsp {
  2327. return buildingOneKeyRsp.fromPartial(base ?? ({} as any));
  2328. },
  2329. fromPartial<I extends Exact<DeepPartial<buildingOneKeyRsp>, I>>(object: I): buildingOneKeyRsp {
  2330. const message = createBasebuildingOneKeyRsp();
  2331. message.errno = object.errno ?? 0;
  2332. message.list = object.list?.map((e) => building.fromPartial(e)) || [];
  2333. return message;
  2334. },
  2335. };
  2336. function createBaseadventureData(): adventureData {
  2337. return {};
  2338. }
  2339. export const adventureData = {
  2340. fromJSON(_: any): adventureData {
  2341. return {};
  2342. },
  2343. toJSON(_: adventureData): unknown {
  2344. const obj: any = {};
  2345. return obj;
  2346. },
  2347. create<I extends Exact<DeepPartial<adventureData>, I>>(base?: I): adventureData {
  2348. return adventureData.fromPartial(base ?? ({} as any));
  2349. },
  2350. fromPartial<I extends Exact<DeepPartial<adventureData>, I>>(_: I): adventureData {
  2351. const message = createBaseadventureData();
  2352. return message;
  2353. },
  2354. };
  2355. function createBaseadventureDataRsp(): adventureDataRsp {
  2356. return { errno: 0, id1: 0, award1: [], id2: 0, award2: [], type: 0, layer: 0, cost: 0 };
  2357. }
  2358. export const adventureDataRsp = {
  2359. fromJSON(object: any): adventureDataRsp {
  2360. return {
  2361. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2362. id1: isSet(object.id1) ? globalThis.Number(object.id1) : 0,
  2363. award1: globalThis.Array.isArray(object?.award1) ? object.award1.map((e: any) => globalThis.Number(e)) : [],
  2364. id2: isSet(object.id2) ? globalThis.Number(object.id2) : 0,
  2365. award2: globalThis.Array.isArray(object?.award2) ? object.award2.map((e: any) => globalThis.Number(e)) : [],
  2366. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  2367. layer: isSet(object.layer) ? globalThis.Number(object.layer) : 0,
  2368. cost: isSet(object.cost) ? globalThis.Number(object.cost) : 0,
  2369. };
  2370. },
  2371. toJSON(message: adventureDataRsp): unknown {
  2372. const obj: any = {};
  2373. if (message.errno !== 0) {
  2374. obj.errno = Math.round(message.errno);
  2375. }
  2376. if (message.id1 !== 0) {
  2377. obj.id1 = Math.round(message.id1);
  2378. }
  2379. if (message.award1?.length) {
  2380. obj.award1 = message.award1.map((e) => Math.round(e));
  2381. }
  2382. if (message.id2 !== 0) {
  2383. obj.id2 = Math.round(message.id2);
  2384. }
  2385. if (message.award2?.length) {
  2386. obj.award2 = message.award2.map((e) => Math.round(e));
  2387. }
  2388. if (message.type !== 0) {
  2389. obj.type = Math.round(message.type);
  2390. }
  2391. if (message.layer !== 0) {
  2392. obj.layer = Math.round(message.layer);
  2393. }
  2394. if (message.cost !== 0) {
  2395. obj.cost = Math.round(message.cost);
  2396. }
  2397. return obj;
  2398. },
  2399. create<I extends Exact<DeepPartial<adventureDataRsp>, I>>(base?: I): adventureDataRsp {
  2400. return adventureDataRsp.fromPartial(base ?? ({} as any));
  2401. },
  2402. fromPartial<I extends Exact<DeepPartial<adventureDataRsp>, I>>(object: I): adventureDataRsp {
  2403. const message = createBaseadventureDataRsp();
  2404. message.errno = object.errno ?? 0;
  2405. message.id1 = object.id1 ?? 0;
  2406. message.award1 = object.award1?.map((e) => e) || [];
  2407. message.id2 = object.id2 ?? 0;
  2408. message.award2 = object.award2?.map((e) => e) || [];
  2409. message.type = object.type ?? 0;
  2410. message.layer = object.layer ?? 0;
  2411. message.cost = object.cost ?? 0;
  2412. return message;
  2413. },
  2414. };
  2415. function createBaseadventureStart(): adventureStart {
  2416. return { id: 0, type: 0 };
  2417. }
  2418. export const adventureStart = {
  2419. fromJSON(object: any): adventureStart {
  2420. return {
  2421. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  2422. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  2423. };
  2424. },
  2425. toJSON(message: adventureStart): unknown {
  2426. const obj: any = {};
  2427. if (message.id !== 0) {
  2428. obj.id = Math.round(message.id);
  2429. }
  2430. if (message.type !== 0) {
  2431. obj.type = Math.round(message.type);
  2432. }
  2433. return obj;
  2434. },
  2435. create<I extends Exact<DeepPartial<adventureStart>, I>>(base?: I): adventureStart {
  2436. return adventureStart.fromPartial(base ?? ({} as any));
  2437. },
  2438. fromPartial<I extends Exact<DeepPartial<adventureStart>, I>>(object: I): adventureStart {
  2439. const message = createBaseadventureStart();
  2440. message.id = object.id ?? 0;
  2441. message.type = object.type ?? 0;
  2442. return message;
  2443. },
  2444. };
  2445. function createBaseadventureStartRsp(): adventureStartRsp {
  2446. return { errno: 0, btrial: false, trialId: 0, trialNum: 0 };
  2447. }
  2448. export const adventureStartRsp = {
  2449. fromJSON(object: any): adventureStartRsp {
  2450. return {
  2451. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2452. btrial: isSet(object.btrial) ? globalThis.Boolean(object.btrial) : false,
  2453. trialId: isSet(object.trialId) ? globalThis.Number(object.trialId) : 0,
  2454. trialNum: isSet(object.trialNum) ? globalThis.Number(object.trialNum) : 0,
  2455. };
  2456. },
  2457. toJSON(message: adventureStartRsp): unknown {
  2458. const obj: any = {};
  2459. if (message.errno !== 0) {
  2460. obj.errno = Math.round(message.errno);
  2461. }
  2462. if (message.btrial !== false) {
  2463. obj.btrial = message.btrial;
  2464. }
  2465. if (message.trialId !== 0) {
  2466. obj.trialId = Math.round(message.trialId);
  2467. }
  2468. if (message.trialNum !== 0) {
  2469. obj.trialNum = Math.round(message.trialNum);
  2470. }
  2471. return obj;
  2472. },
  2473. create<I extends Exact<DeepPartial<adventureStartRsp>, I>>(base?: I): adventureStartRsp {
  2474. return adventureStartRsp.fromPartial(base ?? ({} as any));
  2475. },
  2476. fromPartial<I extends Exact<DeepPartial<adventureStartRsp>, I>>(object: I): adventureStartRsp {
  2477. const message = createBaseadventureStartRsp();
  2478. message.errno = object.errno ?? 0;
  2479. message.btrial = object.btrial ?? false;
  2480. message.trialId = object.trialId ?? 0;
  2481. message.trialNum = object.trialNum ?? 0;
  2482. return message;
  2483. },
  2484. };
  2485. function createBaseadventureEnd(): adventureEnd {
  2486. return { win: false, monsterNum: 0, bossNum: 0, eliteNum: 0 };
  2487. }
  2488. export const adventureEnd = {
  2489. fromJSON(object: any): adventureEnd {
  2490. return {
  2491. win: isSet(object.win) ? globalThis.Boolean(object.win) : false,
  2492. monsterNum: isSet(object.monsterNum) ? globalThis.Number(object.monsterNum) : 0,
  2493. bossNum: isSet(object.bossNum) ? globalThis.Number(object.bossNum) : 0,
  2494. eliteNum: isSet(object.eliteNum) ? globalThis.Number(object.eliteNum) : 0,
  2495. };
  2496. },
  2497. toJSON(message: adventureEnd): unknown {
  2498. const obj: any = {};
  2499. if (message.win !== false) {
  2500. obj.win = message.win;
  2501. }
  2502. if (message.monsterNum !== 0) {
  2503. obj.monsterNum = Math.round(message.monsterNum);
  2504. }
  2505. if (message.bossNum !== 0) {
  2506. obj.bossNum = Math.round(message.bossNum);
  2507. }
  2508. if (message.eliteNum !== 0) {
  2509. obj.eliteNum = Math.round(message.eliteNum);
  2510. }
  2511. return obj;
  2512. },
  2513. create<I extends Exact<DeepPartial<adventureEnd>, I>>(base?: I): adventureEnd {
  2514. return adventureEnd.fromPartial(base ?? ({} as any));
  2515. },
  2516. fromPartial<I extends Exact<DeepPartial<adventureEnd>, I>>(object: I): adventureEnd {
  2517. const message = createBaseadventureEnd();
  2518. message.win = object.win ?? false;
  2519. message.monsterNum = object.monsterNum ?? 0;
  2520. message.bossNum = object.bossNum ?? 0;
  2521. message.eliteNum = object.eliteNum ?? 0;
  2522. return message;
  2523. },
  2524. };
  2525. function createBaseadventureEndRsp(): adventureEndRsp {
  2526. return { errno: 0 };
  2527. }
  2528. export const adventureEndRsp = {
  2529. fromJSON(object: any): adventureEndRsp {
  2530. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2531. },
  2532. toJSON(message: adventureEndRsp): unknown {
  2533. const obj: any = {};
  2534. if (message.errno !== 0) {
  2535. obj.errno = Math.round(message.errno);
  2536. }
  2537. return obj;
  2538. },
  2539. create<I extends Exact<DeepPartial<adventureEndRsp>, I>>(base?: I): adventureEndRsp {
  2540. return adventureEndRsp.fromPartial(base ?? ({} as any));
  2541. },
  2542. fromPartial<I extends Exact<DeepPartial<adventureEndRsp>, I>>(object: I): adventureEndRsp {
  2543. const message = createBaseadventureEndRsp();
  2544. message.errno = object.errno ?? 0;
  2545. return message;
  2546. },
  2547. };
  2548. function createBaseadventureLayer(): adventureLayer {
  2549. return { layer: 0, cost: 0, monsterNum: 0, bossNum: 0, eliteNum: 0 };
  2550. }
  2551. export const adventureLayer = {
  2552. fromJSON(object: any): adventureLayer {
  2553. return {
  2554. layer: isSet(object.layer) ? globalThis.Number(object.layer) : 0,
  2555. cost: isSet(object.cost) ? globalThis.Number(object.cost) : 0,
  2556. monsterNum: isSet(object.monsterNum) ? globalThis.Number(object.monsterNum) : 0,
  2557. bossNum: isSet(object.bossNum) ? globalThis.Number(object.bossNum) : 0,
  2558. eliteNum: isSet(object.eliteNum) ? globalThis.Number(object.eliteNum) : 0,
  2559. };
  2560. },
  2561. toJSON(message: adventureLayer): unknown {
  2562. const obj: any = {};
  2563. if (message.layer !== 0) {
  2564. obj.layer = Math.round(message.layer);
  2565. }
  2566. if (message.cost !== 0) {
  2567. obj.cost = Math.round(message.cost);
  2568. }
  2569. if (message.monsterNum !== 0) {
  2570. obj.monsterNum = Math.round(message.monsterNum);
  2571. }
  2572. if (message.bossNum !== 0) {
  2573. obj.bossNum = Math.round(message.bossNum);
  2574. }
  2575. if (message.eliteNum !== 0) {
  2576. obj.eliteNum = Math.round(message.eliteNum);
  2577. }
  2578. return obj;
  2579. },
  2580. create<I extends Exact<DeepPartial<adventureLayer>, I>>(base?: I): adventureLayer {
  2581. return adventureLayer.fromPartial(base ?? ({} as any));
  2582. },
  2583. fromPartial<I extends Exact<DeepPartial<adventureLayer>, I>>(object: I): adventureLayer {
  2584. const message = createBaseadventureLayer();
  2585. message.layer = object.layer ?? 0;
  2586. message.cost = object.cost ?? 0;
  2587. message.monsterNum = object.monsterNum ?? 0;
  2588. message.bossNum = object.bossNum ?? 0;
  2589. message.eliteNum = object.eliteNum ?? 0;
  2590. return message;
  2591. },
  2592. };
  2593. function createBaseadventureLayerRsp(): adventureLayerRsp {
  2594. return { errno: 0 };
  2595. }
  2596. export const adventureLayerRsp = {
  2597. fromJSON(object: any): adventureLayerRsp {
  2598. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2599. },
  2600. toJSON(message: adventureLayerRsp): unknown {
  2601. const obj: any = {};
  2602. if (message.errno !== 0) {
  2603. obj.errno = Math.round(message.errno);
  2604. }
  2605. return obj;
  2606. },
  2607. create<I extends Exact<DeepPartial<adventureLayerRsp>, I>>(base?: I): adventureLayerRsp {
  2608. return adventureLayerRsp.fromPartial(base ?? ({} as any));
  2609. },
  2610. fromPartial<I extends Exact<DeepPartial<adventureLayerRsp>, I>>(object: I): adventureLayerRsp {
  2611. const message = createBaseadventureLayerRsp();
  2612. message.errno = object.errno ?? 0;
  2613. return message;
  2614. },
  2615. };
  2616. function createBaseadventureSweep(): adventureSweep {
  2617. return { id: 0, type: 0 };
  2618. }
  2619. export const adventureSweep = {
  2620. fromJSON(object: any): adventureSweep {
  2621. return {
  2622. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  2623. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  2624. };
  2625. },
  2626. toJSON(message: adventureSweep): unknown {
  2627. const obj: any = {};
  2628. if (message.id !== 0) {
  2629. obj.id = Math.round(message.id);
  2630. }
  2631. if (message.type !== 0) {
  2632. obj.type = Math.round(message.type);
  2633. }
  2634. return obj;
  2635. },
  2636. create<I extends Exact<DeepPartial<adventureSweep>, I>>(base?: I): adventureSweep {
  2637. return adventureSweep.fromPartial(base ?? ({} as any));
  2638. },
  2639. fromPartial<I extends Exact<DeepPartial<adventureSweep>, I>>(object: I): adventureSweep {
  2640. const message = createBaseadventureSweep();
  2641. message.id = object.id ?? 0;
  2642. message.type = object.type ?? 0;
  2643. return message;
  2644. },
  2645. };
  2646. function createBaseadventureSweepRsp(): adventureSweepRsp {
  2647. return { errno: 0 };
  2648. }
  2649. export const adventureSweepRsp = {
  2650. fromJSON(object: any): adventureSweepRsp {
  2651. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2652. },
  2653. toJSON(message: adventureSweepRsp): unknown {
  2654. const obj: any = {};
  2655. if (message.errno !== 0) {
  2656. obj.errno = Math.round(message.errno);
  2657. }
  2658. return obj;
  2659. },
  2660. create<I extends Exact<DeepPartial<adventureSweepRsp>, I>>(base?: I): adventureSweepRsp {
  2661. return adventureSweepRsp.fromPartial(base ?? ({} as any));
  2662. },
  2663. fromPartial<I extends Exact<DeepPartial<adventureSweepRsp>, I>>(object: I): adventureSweepRsp {
  2664. const message = createBaseadventureSweepRsp();
  2665. message.errno = object.errno ?? 0;
  2666. return message;
  2667. },
  2668. };
  2669. function createBaseadventurePassAward(): adventurePassAward {
  2670. return { id: 0, type: 0 };
  2671. }
  2672. export const adventurePassAward = {
  2673. fromJSON(object: any): adventurePassAward {
  2674. return {
  2675. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  2676. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  2677. };
  2678. },
  2679. toJSON(message: adventurePassAward): unknown {
  2680. const obj: any = {};
  2681. if (message.id !== 0) {
  2682. obj.id = Math.round(message.id);
  2683. }
  2684. if (message.type !== 0) {
  2685. obj.type = Math.round(message.type);
  2686. }
  2687. return obj;
  2688. },
  2689. create<I extends Exact<DeepPartial<adventurePassAward>, I>>(base?: I): adventurePassAward {
  2690. return adventurePassAward.fromPartial(base ?? ({} as any));
  2691. },
  2692. fromPartial<I extends Exact<DeepPartial<adventurePassAward>, I>>(object: I): adventurePassAward {
  2693. const message = createBaseadventurePassAward();
  2694. message.id = object.id ?? 0;
  2695. message.type = object.type ?? 0;
  2696. return message;
  2697. },
  2698. };
  2699. function createBaseadventurePassAwardRsp(): adventurePassAwardRsp {
  2700. return { errno: 0, id: 0, type: 0 };
  2701. }
  2702. export const adventurePassAwardRsp = {
  2703. fromJSON(object: any): adventurePassAwardRsp {
  2704. return {
  2705. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2706. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  2707. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  2708. };
  2709. },
  2710. toJSON(message: adventurePassAwardRsp): unknown {
  2711. const obj: any = {};
  2712. if (message.errno !== 0) {
  2713. obj.errno = Math.round(message.errno);
  2714. }
  2715. if (message.id !== 0) {
  2716. obj.id = Math.round(message.id);
  2717. }
  2718. if (message.type !== 0) {
  2719. obj.type = Math.round(message.type);
  2720. }
  2721. return obj;
  2722. },
  2723. create<I extends Exact<DeepPartial<adventurePassAwardRsp>, I>>(base?: I): adventurePassAwardRsp {
  2724. return adventurePassAwardRsp.fromPartial(base ?? ({} as any));
  2725. },
  2726. fromPartial<I extends Exact<DeepPartial<adventurePassAwardRsp>, I>>(object: I): adventurePassAwardRsp {
  2727. const message = createBaseadventurePassAwardRsp();
  2728. message.errno = object.errno ?? 0;
  2729. message.id = object.id ?? 0;
  2730. message.type = object.type ?? 0;
  2731. return message;
  2732. },
  2733. };
  2734. function createBaseadventureAdAward(): adventureAdAward {
  2735. return {};
  2736. }
  2737. export const adventureAdAward = {
  2738. fromJSON(_: any): adventureAdAward {
  2739. return {};
  2740. },
  2741. toJSON(_: adventureAdAward): unknown {
  2742. const obj: any = {};
  2743. return obj;
  2744. },
  2745. create<I extends Exact<DeepPartial<adventureAdAward>, I>>(base?: I): adventureAdAward {
  2746. return adventureAdAward.fromPartial(base ?? ({} as any));
  2747. },
  2748. fromPartial<I extends Exact<DeepPartial<adventureAdAward>, I>>(_: I): adventureAdAward {
  2749. const message = createBaseadventureAdAward();
  2750. return message;
  2751. },
  2752. };
  2753. function createBaseadventureAdAwardRsp(): adventureAdAwardRsp {
  2754. return { errno: 0 };
  2755. }
  2756. export const adventureAdAwardRsp = {
  2757. fromJSON(object: any): adventureAdAwardRsp {
  2758. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2759. },
  2760. toJSON(message: adventureAdAwardRsp): unknown {
  2761. const obj: any = {};
  2762. if (message.errno !== 0) {
  2763. obj.errno = Math.round(message.errno);
  2764. }
  2765. return obj;
  2766. },
  2767. create<I extends Exact<DeepPartial<adventureAdAwardRsp>, I>>(base?: I): adventureAdAwardRsp {
  2768. return adventureAdAwardRsp.fromPartial(base ?? ({} as any));
  2769. },
  2770. fromPartial<I extends Exact<DeepPartial<adventureAdAwardRsp>, I>>(object: I): adventureAdAwardRsp {
  2771. const message = createBaseadventureAdAwardRsp();
  2772. message.errno = object.errno ?? 0;
  2773. return message;
  2774. },
  2775. };
  2776. function createBaseadventureTrial(): adventureTrial {
  2777. return {};
  2778. }
  2779. export const adventureTrial = {
  2780. fromJSON(_: any): adventureTrial {
  2781. return {};
  2782. },
  2783. toJSON(_: adventureTrial): unknown {
  2784. const obj: any = {};
  2785. return obj;
  2786. },
  2787. create<I extends Exact<DeepPartial<adventureTrial>, I>>(base?: I): adventureTrial {
  2788. return adventureTrial.fromPartial(base ?? ({} as any));
  2789. },
  2790. fromPartial<I extends Exact<DeepPartial<adventureTrial>, I>>(_: I): adventureTrial {
  2791. const message = createBaseadventureTrial();
  2792. return message;
  2793. },
  2794. };
  2795. function createBaseadventureTrialRsp(): adventureTrialRsp {
  2796. return { errno: 0 };
  2797. }
  2798. export const adventureTrialRsp = {
  2799. fromJSON(object: any): adventureTrialRsp {
  2800. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  2801. },
  2802. toJSON(message: adventureTrialRsp): unknown {
  2803. const obj: any = {};
  2804. if (message.errno !== 0) {
  2805. obj.errno = Math.round(message.errno);
  2806. }
  2807. return obj;
  2808. },
  2809. create<I extends Exact<DeepPartial<adventureTrialRsp>, I>>(base?: I): adventureTrialRsp {
  2810. return adventureTrialRsp.fromPartial(base ?? ({} as any));
  2811. },
  2812. fromPartial<I extends Exact<DeepPartial<adventureTrialRsp>, I>>(object: I): adventureTrialRsp {
  2813. const message = createBaseadventureTrialRsp();
  2814. message.errno = object.errno ?? 0;
  2815. return message;
  2816. },
  2817. };
  2818. function createBasegetMail(): getMail {
  2819. return {};
  2820. }
  2821. export const getMail = {
  2822. fromJSON(_: any): getMail {
  2823. return {};
  2824. },
  2825. toJSON(_: getMail): unknown {
  2826. const obj: any = {};
  2827. return obj;
  2828. },
  2829. create<I extends Exact<DeepPartial<getMail>, I>>(base?: I): getMail {
  2830. return getMail.fromPartial(base ?? ({} as any));
  2831. },
  2832. fromPartial<I extends Exact<DeepPartial<getMail>, I>>(_: I): getMail {
  2833. const message = createBasegetMail();
  2834. return message;
  2835. },
  2836. };
  2837. function createBasegetMailRsp(): getMailRsp {
  2838. return { errno: 0, list: [] };
  2839. }
  2840. export const getMailRsp = {
  2841. fromJSON(object: any): getMailRsp {
  2842. return {
  2843. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2844. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => mail.fromJSON(e)) : [],
  2845. };
  2846. },
  2847. toJSON(message: getMailRsp): unknown {
  2848. const obj: any = {};
  2849. if (message.errno !== 0) {
  2850. obj.errno = Math.round(message.errno);
  2851. }
  2852. if (message.list?.length) {
  2853. obj.list = message.list.map((e) => mail.toJSON(e));
  2854. }
  2855. return obj;
  2856. },
  2857. create<I extends Exact<DeepPartial<getMailRsp>, I>>(base?: I): getMailRsp {
  2858. return getMailRsp.fromPartial(base ?? ({} as any));
  2859. },
  2860. fromPartial<I extends Exact<DeepPartial<getMailRsp>, I>>(object: I): getMailRsp {
  2861. const message = createBasegetMailRsp();
  2862. message.errno = object.errno ?? 0;
  2863. message.list = object.list?.map((e) => mail.fromPartial(e)) || [];
  2864. return message;
  2865. },
  2866. };
  2867. function createBasegetMailGoods(): getMailGoods {
  2868. return { list: [], bonekey: false };
  2869. }
  2870. export const getMailGoods = {
  2871. fromJSON(object: any): getMailGoods {
  2872. return {
  2873. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  2874. bonekey: isSet(object.bonekey) ? globalThis.Boolean(object.bonekey) : false,
  2875. };
  2876. },
  2877. toJSON(message: getMailGoods): unknown {
  2878. const obj: any = {};
  2879. if (message.list?.length) {
  2880. obj.list = message.list;
  2881. }
  2882. if (message.bonekey !== false) {
  2883. obj.bonekey = message.bonekey;
  2884. }
  2885. return obj;
  2886. },
  2887. create<I extends Exact<DeepPartial<getMailGoods>, I>>(base?: I): getMailGoods {
  2888. return getMailGoods.fromPartial(base ?? ({} as any));
  2889. },
  2890. fromPartial<I extends Exact<DeepPartial<getMailGoods>, I>>(object: I): getMailGoods {
  2891. const message = createBasegetMailGoods();
  2892. message.list = object.list?.map((e) => e) || [];
  2893. message.bonekey = object.bonekey ?? false;
  2894. return message;
  2895. },
  2896. };
  2897. function createBasegetMailGoodsRsp(): getMailGoodsRsp {
  2898. return { errno: 0, list: [] };
  2899. }
  2900. export const getMailGoodsRsp = {
  2901. fromJSON(object: any): getMailGoodsRsp {
  2902. return {
  2903. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2904. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  2905. };
  2906. },
  2907. toJSON(message: getMailGoodsRsp): unknown {
  2908. const obj: any = {};
  2909. if (message.errno !== 0) {
  2910. obj.errno = Math.round(message.errno);
  2911. }
  2912. if (message.list?.length) {
  2913. obj.list = message.list;
  2914. }
  2915. return obj;
  2916. },
  2917. create<I extends Exact<DeepPartial<getMailGoodsRsp>, I>>(base?: I): getMailGoodsRsp {
  2918. return getMailGoodsRsp.fromPartial(base ?? ({} as any));
  2919. },
  2920. fromPartial<I extends Exact<DeepPartial<getMailGoodsRsp>, I>>(object: I): getMailGoodsRsp {
  2921. const message = createBasegetMailGoodsRsp();
  2922. message.errno = object.errno ?? 0;
  2923. message.list = object.list?.map((e) => e) || [];
  2924. return message;
  2925. },
  2926. };
  2927. function createBasedelMail(): delMail {
  2928. return { list: [] };
  2929. }
  2930. export const delMail = {
  2931. fromJSON(object: any): delMail {
  2932. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [] };
  2933. },
  2934. toJSON(message: delMail): unknown {
  2935. const obj: any = {};
  2936. if (message.list?.length) {
  2937. obj.list = message.list;
  2938. }
  2939. return obj;
  2940. },
  2941. create<I extends Exact<DeepPartial<delMail>, I>>(base?: I): delMail {
  2942. return delMail.fromPartial(base ?? ({} as any));
  2943. },
  2944. fromPartial<I extends Exact<DeepPartial<delMail>, I>>(object: I): delMail {
  2945. const message = createBasedelMail();
  2946. message.list = object.list?.map((e) => e) || [];
  2947. return message;
  2948. },
  2949. };
  2950. function createBasedelMailRsp(): delMailRsp {
  2951. return { errno: 0, list: [] };
  2952. }
  2953. export const delMailRsp = {
  2954. fromJSON(object: any): delMailRsp {
  2955. return {
  2956. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  2957. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  2958. };
  2959. },
  2960. toJSON(message: delMailRsp): unknown {
  2961. const obj: any = {};
  2962. if (message.errno !== 0) {
  2963. obj.errno = Math.round(message.errno);
  2964. }
  2965. if (message.list?.length) {
  2966. obj.list = message.list;
  2967. }
  2968. return obj;
  2969. },
  2970. create<I extends Exact<DeepPartial<delMailRsp>, I>>(base?: I): delMailRsp {
  2971. return delMailRsp.fromPartial(base ?? ({} as any));
  2972. },
  2973. fromPartial<I extends Exact<DeepPartial<delMailRsp>, I>>(object: I): delMailRsp {
  2974. const message = createBasedelMailRsp();
  2975. message.errno = object.errno ?? 0;
  2976. message.list = object.list?.map((e) => e) || [];
  2977. return message;
  2978. },
  2979. };
  2980. function createBaseflagMail(): flagMail {
  2981. return { list: [] };
  2982. }
  2983. export const flagMail = {
  2984. fromJSON(object: any): flagMail {
  2985. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [] };
  2986. },
  2987. toJSON(message: flagMail): unknown {
  2988. const obj: any = {};
  2989. if (message.list?.length) {
  2990. obj.list = message.list;
  2991. }
  2992. return obj;
  2993. },
  2994. create<I extends Exact<DeepPartial<flagMail>, I>>(base?: I): flagMail {
  2995. return flagMail.fromPartial(base ?? ({} as any));
  2996. },
  2997. fromPartial<I extends Exact<DeepPartial<flagMail>, I>>(object: I): flagMail {
  2998. const message = createBaseflagMail();
  2999. message.list = object.list?.map((e) => e) || [];
  3000. return message;
  3001. },
  3002. };
  3003. function createBaseflagMailRsp(): flagMailRsp {
  3004. return { errno: 0 };
  3005. }
  3006. export const flagMailRsp = {
  3007. fromJSON(object: any): flagMailRsp {
  3008. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  3009. },
  3010. toJSON(message: flagMailRsp): unknown {
  3011. const obj: any = {};
  3012. if (message.errno !== 0) {
  3013. obj.errno = Math.round(message.errno);
  3014. }
  3015. return obj;
  3016. },
  3017. create<I extends Exact<DeepPartial<flagMailRsp>, I>>(base?: I): flagMailRsp {
  3018. return flagMailRsp.fromPartial(base ?? ({} as any));
  3019. },
  3020. fromPartial<I extends Exact<DeepPartial<flagMailRsp>, I>>(object: I): flagMailRsp {
  3021. const message = createBaseflagMailRsp();
  3022. message.errno = object.errno ?? 0;
  3023. return message;
  3024. },
  3025. };
  3026. function createBasesendMail(): sendMail {
  3027. return { list: [] };
  3028. }
  3029. export const sendMail = {
  3030. fromJSON(object: any): sendMail {
  3031. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => mail.fromJSON(e)) : [] };
  3032. },
  3033. toJSON(message: sendMail): unknown {
  3034. const obj: any = {};
  3035. if (message.list?.length) {
  3036. obj.list = message.list.map((e) => mail.toJSON(e));
  3037. }
  3038. return obj;
  3039. },
  3040. create<I extends Exact<DeepPartial<sendMail>, I>>(base?: I): sendMail {
  3041. return sendMail.fromPartial(base ?? ({} as any));
  3042. },
  3043. fromPartial<I extends Exact<DeepPartial<sendMail>, I>>(object: I): sendMail {
  3044. const message = createBasesendMail();
  3045. message.list = object.list?.map((e) => mail.fromPartial(e)) || [];
  3046. return message;
  3047. },
  3048. };
  3049. function createBasesimpleMail(): simpleMail {
  3050. return { num: 0, noread: 0, needread: 0 };
  3051. }
  3052. export const simpleMail = {
  3053. fromJSON(object: any): simpleMail {
  3054. return {
  3055. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  3056. noread: isSet(object.noread) ? globalThis.Number(object.noread) : 0,
  3057. needread: isSet(object.needread) ? globalThis.Number(object.needread) : 0,
  3058. };
  3059. },
  3060. toJSON(message: simpleMail): unknown {
  3061. const obj: any = {};
  3062. if (message.num !== 0) {
  3063. obj.num = Math.round(message.num);
  3064. }
  3065. if (message.noread !== 0) {
  3066. obj.noread = Math.round(message.noread);
  3067. }
  3068. if (message.needread !== 0) {
  3069. obj.needread = Math.round(message.needread);
  3070. }
  3071. return obj;
  3072. },
  3073. create<I extends Exact<DeepPartial<simpleMail>, I>>(base?: I): simpleMail {
  3074. return simpleMail.fromPartial(base ?? ({} as any));
  3075. },
  3076. fromPartial<I extends Exact<DeepPartial<simpleMail>, I>>(object: I): simpleMail {
  3077. const message = createBasesimpleMail();
  3078. message.num = object.num ?? 0;
  3079. message.noread = object.noread ?? 0;
  3080. message.needread = object.needread ?? 0;
  3081. return message;
  3082. },
  3083. };
  3084. function createBaseembattleGetData(): embattleGetData {
  3085. return {};
  3086. }
  3087. export const embattleGetData = {
  3088. fromJSON(_: any): embattleGetData {
  3089. return {};
  3090. },
  3091. toJSON(_: embattleGetData): unknown {
  3092. const obj: any = {};
  3093. return obj;
  3094. },
  3095. create<I extends Exact<DeepPartial<embattleGetData>, I>>(base?: I): embattleGetData {
  3096. return embattleGetData.fromPartial(base ?? ({} as any));
  3097. },
  3098. fromPartial<I extends Exact<DeepPartial<embattleGetData>, I>>(_: I): embattleGetData {
  3099. const message = createBaseembattleGetData();
  3100. return message;
  3101. },
  3102. };
  3103. function createBaseembattleGetDataRsp(): embattleGetDataRsp {
  3104. return { errno: 0, list: [], cardList: [] };
  3105. }
  3106. export const embattleGetDataRsp = {
  3107. fromJSON(object: any): embattleGetDataRsp {
  3108. return {
  3109. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3110. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => sidPos.fromJSON(e)) : [],
  3111. cardList: globalThis.Array.isArray(object?.cardList) ? object.cardList.map((e: any) => sidPos.fromJSON(e)) : [],
  3112. };
  3113. },
  3114. toJSON(message: embattleGetDataRsp): unknown {
  3115. const obj: any = {};
  3116. if (message.errno !== 0) {
  3117. obj.errno = Math.round(message.errno);
  3118. }
  3119. if (message.list?.length) {
  3120. obj.list = message.list.map((e) => sidPos.toJSON(e));
  3121. }
  3122. if (message.cardList?.length) {
  3123. obj.cardList = message.cardList.map((e) => sidPos.toJSON(e));
  3124. }
  3125. return obj;
  3126. },
  3127. create<I extends Exact<DeepPartial<embattleGetDataRsp>, I>>(base?: I): embattleGetDataRsp {
  3128. return embattleGetDataRsp.fromPartial(base ?? ({} as any));
  3129. },
  3130. fromPartial<I extends Exact<DeepPartial<embattleGetDataRsp>, I>>(object: I): embattleGetDataRsp {
  3131. const message = createBaseembattleGetDataRsp();
  3132. message.errno = object.errno ?? 0;
  3133. message.list = object.list?.map((e) => sidPos.fromPartial(e)) || [];
  3134. message.cardList = object.cardList?.map((e) => sidPos.fromPartial(e)) || [];
  3135. return message;
  3136. },
  3137. };
  3138. function createBaseembattleBattle(): embattleBattle {
  3139. return { skill: false, sid: "", pos: 0 };
  3140. }
  3141. export const embattleBattle = {
  3142. fromJSON(object: any): embattleBattle {
  3143. return {
  3144. skill: isSet(object.skill) ? globalThis.Boolean(object.skill) : false,
  3145. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3146. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  3147. };
  3148. },
  3149. toJSON(message: embattleBattle): unknown {
  3150. const obj: any = {};
  3151. if (message.skill !== false) {
  3152. obj.skill = message.skill;
  3153. }
  3154. if (message.sid !== "") {
  3155. obj.sid = message.sid;
  3156. }
  3157. if (message.pos !== 0) {
  3158. obj.pos = Math.round(message.pos);
  3159. }
  3160. return obj;
  3161. },
  3162. create<I extends Exact<DeepPartial<embattleBattle>, I>>(base?: I): embattleBattle {
  3163. return embattleBattle.fromPartial(base ?? ({} as any));
  3164. },
  3165. fromPartial<I extends Exact<DeepPartial<embattleBattle>, I>>(object: I): embattleBattle {
  3166. const message = createBaseembattleBattle();
  3167. message.skill = object.skill ?? false;
  3168. message.sid = object.sid ?? "";
  3169. message.pos = object.pos ?? 0;
  3170. return message;
  3171. },
  3172. };
  3173. function createBaseembattleBattleRsp(): embattleBattleRsp {
  3174. return { errno: 0, list: [], cardList: [] };
  3175. }
  3176. export const embattleBattleRsp = {
  3177. fromJSON(object: any): embattleBattleRsp {
  3178. return {
  3179. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3180. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => sidPos.fromJSON(e)) : [],
  3181. cardList: globalThis.Array.isArray(object?.cardList) ? object.cardList.map((e: any) => sidPos.fromJSON(e)) : [],
  3182. };
  3183. },
  3184. toJSON(message: embattleBattleRsp): unknown {
  3185. const obj: any = {};
  3186. if (message.errno !== 0) {
  3187. obj.errno = Math.round(message.errno);
  3188. }
  3189. if (message.list?.length) {
  3190. obj.list = message.list.map((e) => sidPos.toJSON(e));
  3191. }
  3192. if (message.cardList?.length) {
  3193. obj.cardList = message.cardList.map((e) => sidPos.toJSON(e));
  3194. }
  3195. return obj;
  3196. },
  3197. create<I extends Exact<DeepPartial<embattleBattleRsp>, I>>(base?: I): embattleBattleRsp {
  3198. return embattleBattleRsp.fromPartial(base ?? ({} as any));
  3199. },
  3200. fromPartial<I extends Exact<DeepPartial<embattleBattleRsp>, I>>(object: I): embattleBattleRsp {
  3201. const message = createBaseembattleBattleRsp();
  3202. message.errno = object.errno ?? 0;
  3203. message.list = object.list?.map((e) => sidPos.fromPartial(e)) || [];
  3204. message.cardList = object.cardList?.map((e) => sidPos.fromPartial(e)) || [];
  3205. return message;
  3206. },
  3207. };
  3208. function createBaseheroGetData(): heroGetData {
  3209. return {};
  3210. }
  3211. export const heroGetData = {
  3212. fromJSON(_: any): heroGetData {
  3213. return {};
  3214. },
  3215. toJSON(_: heroGetData): unknown {
  3216. const obj: any = {};
  3217. return obj;
  3218. },
  3219. create<I extends Exact<DeepPartial<heroGetData>, I>>(base?: I): heroGetData {
  3220. return heroGetData.fromPartial(base ?? ({} as any));
  3221. },
  3222. fromPartial<I extends Exact<DeepPartial<heroGetData>, I>>(_: I): heroGetData {
  3223. const message = createBaseheroGetData();
  3224. return message;
  3225. },
  3226. };
  3227. function createBaseheroGetDataRsp(): heroGetDataRsp {
  3228. return { errno: 0, list: [] };
  3229. }
  3230. export const heroGetDataRsp = {
  3231. fromJSON(object: any): heroGetDataRsp {
  3232. return {
  3233. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3234. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => hero.fromJSON(e)) : [],
  3235. };
  3236. },
  3237. toJSON(message: heroGetDataRsp): unknown {
  3238. const obj: any = {};
  3239. if (message.errno !== 0) {
  3240. obj.errno = Math.round(message.errno);
  3241. }
  3242. if (message.list?.length) {
  3243. obj.list = message.list.map((e) => hero.toJSON(e));
  3244. }
  3245. return obj;
  3246. },
  3247. create<I extends Exact<DeepPartial<heroGetDataRsp>, I>>(base?: I): heroGetDataRsp {
  3248. return heroGetDataRsp.fromPartial(base ?? ({} as any));
  3249. },
  3250. fromPartial<I extends Exact<DeepPartial<heroGetDataRsp>, I>>(object: I): heroGetDataRsp {
  3251. const message = createBaseheroGetDataRsp();
  3252. message.errno = object.errno ?? 0;
  3253. message.list = object.list?.map((e) => hero.fromPartial(e)) || [];
  3254. return message;
  3255. },
  3256. };
  3257. function createBaseheroUpgrade(): heroUpgrade {
  3258. return { sid: "", num: 0 };
  3259. }
  3260. export const heroUpgrade = {
  3261. fromJSON(object: any): heroUpgrade {
  3262. return {
  3263. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3264. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  3265. };
  3266. },
  3267. toJSON(message: heroUpgrade): unknown {
  3268. const obj: any = {};
  3269. if (message.sid !== "") {
  3270. obj.sid = message.sid;
  3271. }
  3272. if (message.num !== 0) {
  3273. obj.num = Math.round(message.num);
  3274. }
  3275. return obj;
  3276. },
  3277. create<I extends Exact<DeepPartial<heroUpgrade>, I>>(base?: I): heroUpgrade {
  3278. return heroUpgrade.fromPartial(base ?? ({} as any));
  3279. },
  3280. fromPartial<I extends Exact<DeepPartial<heroUpgrade>, I>>(object: I): heroUpgrade {
  3281. const message = createBaseheroUpgrade();
  3282. message.sid = object.sid ?? "";
  3283. message.num = object.num ?? 0;
  3284. return message;
  3285. },
  3286. };
  3287. function createBaseheroUpgradeRsp(): heroUpgradeRsp {
  3288. return { errno: 0, data: undefined };
  3289. }
  3290. export const heroUpgradeRsp = {
  3291. fromJSON(object: any): heroUpgradeRsp {
  3292. return {
  3293. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3294. data: isSet(object.data) ? hero.fromJSON(object.data) : undefined,
  3295. };
  3296. },
  3297. toJSON(message: heroUpgradeRsp): unknown {
  3298. const obj: any = {};
  3299. if (message.errno !== 0) {
  3300. obj.errno = Math.round(message.errno);
  3301. }
  3302. if (message.data !== undefined) {
  3303. obj.data = hero.toJSON(message.data);
  3304. }
  3305. return obj;
  3306. },
  3307. create<I extends Exact<DeepPartial<heroUpgradeRsp>, I>>(base?: I): heroUpgradeRsp {
  3308. return heroUpgradeRsp.fromPartial(base ?? ({} as any));
  3309. },
  3310. fromPartial<I extends Exact<DeepPartial<heroUpgradeRsp>, I>>(object: I): heroUpgradeRsp {
  3311. const message = createBaseheroUpgradeRsp();
  3312. message.errno = object.errno ?? 0;
  3313. message.data = (object.data !== undefined && object.data !== null) ? hero.fromPartial(object.data) : undefined;
  3314. return message;
  3315. },
  3316. };
  3317. function createBaseheroUpgradeStar(): heroUpgradeStar {
  3318. return { sid: "", same: [], other: [], currency: undefined };
  3319. }
  3320. export const heroUpgradeStar = {
  3321. fromJSON(object: any): heroUpgradeStar {
  3322. return {
  3323. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3324. same: globalThis.Array.isArray(object?.same) ? object.same.map((e: any) => globalThis.String(e)) : [],
  3325. other: globalThis.Array.isArray(object?.other) ? object.other.map((e: any) => globalThis.String(e)) : [],
  3326. currency: isSet(object.currency) ? idNum.fromJSON(object.currency) : undefined,
  3327. };
  3328. },
  3329. toJSON(message: heroUpgradeStar): unknown {
  3330. const obj: any = {};
  3331. if (message.sid !== "") {
  3332. obj.sid = message.sid;
  3333. }
  3334. if (message.same?.length) {
  3335. obj.same = message.same;
  3336. }
  3337. if (message.other?.length) {
  3338. obj.other = message.other;
  3339. }
  3340. if (message.currency !== undefined) {
  3341. obj.currency = idNum.toJSON(message.currency);
  3342. }
  3343. return obj;
  3344. },
  3345. create<I extends Exact<DeepPartial<heroUpgradeStar>, I>>(base?: I): heroUpgradeStar {
  3346. return heroUpgradeStar.fromPartial(base ?? ({} as any));
  3347. },
  3348. fromPartial<I extends Exact<DeepPartial<heroUpgradeStar>, I>>(object: I): heroUpgradeStar {
  3349. const message = createBaseheroUpgradeStar();
  3350. message.sid = object.sid ?? "";
  3351. message.same = object.same?.map((e) => e) || [];
  3352. message.other = object.other?.map((e) => e) || [];
  3353. message.currency = (object.currency !== undefined && object.currency !== null)
  3354. ? idNum.fromPartial(object.currency)
  3355. : undefined;
  3356. return message;
  3357. },
  3358. };
  3359. function createBaseheroUpgradeStarRsp(): heroUpgradeStarRsp {
  3360. return { errno: 0, data: undefined, same: [], other: [], currency: undefined };
  3361. }
  3362. export const heroUpgradeStarRsp = {
  3363. fromJSON(object: any): heroUpgradeStarRsp {
  3364. return {
  3365. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3366. data: isSet(object.data) ? hero.fromJSON(object.data) : undefined,
  3367. same: globalThis.Array.isArray(object?.same) ? object.same.map((e: any) => globalThis.String(e)) : [],
  3368. other: globalThis.Array.isArray(object?.other) ? object.other.map((e: any) => globalThis.String(e)) : [],
  3369. currency: isSet(object.currency) ? idNum.fromJSON(object.currency) : undefined,
  3370. };
  3371. },
  3372. toJSON(message: heroUpgradeStarRsp): unknown {
  3373. const obj: any = {};
  3374. if (message.errno !== 0) {
  3375. obj.errno = Math.round(message.errno);
  3376. }
  3377. if (message.data !== undefined) {
  3378. obj.data = hero.toJSON(message.data);
  3379. }
  3380. if (message.same?.length) {
  3381. obj.same = message.same;
  3382. }
  3383. if (message.other?.length) {
  3384. obj.other = message.other;
  3385. }
  3386. if (message.currency !== undefined) {
  3387. obj.currency = idNum.toJSON(message.currency);
  3388. }
  3389. return obj;
  3390. },
  3391. create<I extends Exact<DeepPartial<heroUpgradeStarRsp>, I>>(base?: I): heroUpgradeStarRsp {
  3392. return heroUpgradeStarRsp.fromPartial(base ?? ({} as any));
  3393. },
  3394. fromPartial<I extends Exact<DeepPartial<heroUpgradeStarRsp>, I>>(object: I): heroUpgradeStarRsp {
  3395. const message = createBaseheroUpgradeStarRsp();
  3396. message.errno = object.errno ?? 0;
  3397. message.data = (object.data !== undefined && object.data !== null) ? hero.fromPartial(object.data) : undefined;
  3398. message.same = object.same?.map((e) => e) || [];
  3399. message.other = object.other?.map((e) => e) || [];
  3400. message.currency = (object.currency !== undefined && object.currency !== null)
  3401. ? idNum.fromPartial(object.currency)
  3402. : undefined;
  3403. return message;
  3404. },
  3405. };
  3406. function createBaseheroOnekeyUpgradeStar(): heroOnekeyUpgradeStar {
  3407. return {};
  3408. }
  3409. export const heroOnekeyUpgradeStar = {
  3410. fromJSON(_: any): heroOnekeyUpgradeStar {
  3411. return {};
  3412. },
  3413. toJSON(_: heroOnekeyUpgradeStar): unknown {
  3414. const obj: any = {};
  3415. return obj;
  3416. },
  3417. create<I extends Exact<DeepPartial<heroOnekeyUpgradeStar>, I>>(base?: I): heroOnekeyUpgradeStar {
  3418. return heroOnekeyUpgradeStar.fromPartial(base ?? ({} as any));
  3419. },
  3420. fromPartial<I extends Exact<DeepPartial<heroOnekeyUpgradeStar>, I>>(_: I): heroOnekeyUpgradeStar {
  3421. const message = createBaseheroOnekeyUpgradeStar();
  3422. return message;
  3423. },
  3424. };
  3425. function createBaseheroOnekeyUpgradeStarRsp(): heroOnekeyUpgradeStarRsp {
  3426. return { errno: 0, delList: [], changeList: [] };
  3427. }
  3428. export const heroOnekeyUpgradeStarRsp = {
  3429. fromJSON(object: any): heroOnekeyUpgradeStarRsp {
  3430. return {
  3431. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3432. delList: globalThis.Array.isArray(object?.delList) ? object.delList.map((e: any) => globalThis.String(e)) : [],
  3433. changeList: globalThis.Array.isArray(object?.changeList)
  3434. ? object.changeList.map((e: any) => hero.fromJSON(e))
  3435. : [],
  3436. };
  3437. },
  3438. toJSON(message: heroOnekeyUpgradeStarRsp): unknown {
  3439. const obj: any = {};
  3440. if (message.errno !== 0) {
  3441. obj.errno = Math.round(message.errno);
  3442. }
  3443. if (message.delList?.length) {
  3444. obj.delList = message.delList;
  3445. }
  3446. if (message.changeList?.length) {
  3447. obj.changeList = message.changeList.map((e) => hero.toJSON(e));
  3448. }
  3449. return obj;
  3450. },
  3451. create<I extends Exact<DeepPartial<heroOnekeyUpgradeStarRsp>, I>>(base?: I): heroOnekeyUpgradeStarRsp {
  3452. return heroOnekeyUpgradeStarRsp.fromPartial(base ?? ({} as any));
  3453. },
  3454. fromPartial<I extends Exact<DeepPartial<heroOnekeyUpgradeStarRsp>, I>>(object: I): heroOnekeyUpgradeStarRsp {
  3455. const message = createBaseheroOnekeyUpgradeStarRsp();
  3456. message.errno = object.errno ?? 0;
  3457. message.delList = object.delList?.map((e) => e) || [];
  3458. message.changeList = object.changeList?.map((e) => hero.fromPartial(e)) || [];
  3459. return message;
  3460. },
  3461. };
  3462. function createBaseheroReset(): heroReset {
  3463. return { level: false, sid: "" };
  3464. }
  3465. export const heroReset = {
  3466. fromJSON(object: any): heroReset {
  3467. return {
  3468. level: isSet(object.level) ? globalThis.Boolean(object.level) : false,
  3469. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3470. };
  3471. },
  3472. toJSON(message: heroReset): unknown {
  3473. const obj: any = {};
  3474. if (message.level !== false) {
  3475. obj.level = message.level;
  3476. }
  3477. if (message.sid !== "") {
  3478. obj.sid = message.sid;
  3479. }
  3480. return obj;
  3481. },
  3482. create<I extends Exact<DeepPartial<heroReset>, I>>(base?: I): heroReset {
  3483. return heroReset.fromPartial(base ?? ({} as any));
  3484. },
  3485. fromPartial<I extends Exact<DeepPartial<heroReset>, I>>(object: I): heroReset {
  3486. const message = createBaseheroReset();
  3487. message.level = object.level ?? false;
  3488. message.sid = object.sid ?? "";
  3489. return message;
  3490. },
  3491. };
  3492. function createBaseheroResetRsp(): heroResetRsp {
  3493. return { errno: 0, data: undefined };
  3494. }
  3495. export const heroResetRsp = {
  3496. fromJSON(object: any): heroResetRsp {
  3497. return {
  3498. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3499. data: isSet(object.data) ? hero.fromJSON(object.data) : undefined,
  3500. };
  3501. },
  3502. toJSON(message: heroResetRsp): unknown {
  3503. const obj: any = {};
  3504. if (message.errno !== 0) {
  3505. obj.errno = Math.round(message.errno);
  3506. }
  3507. if (message.data !== undefined) {
  3508. obj.data = hero.toJSON(message.data);
  3509. }
  3510. return obj;
  3511. },
  3512. create<I extends Exact<DeepPartial<heroResetRsp>, I>>(base?: I): heroResetRsp {
  3513. return heroResetRsp.fromPartial(base ?? ({} as any));
  3514. },
  3515. fromPartial<I extends Exact<DeepPartial<heroResetRsp>, I>>(object: I): heroResetRsp {
  3516. const message = createBaseheroResetRsp();
  3517. message.errno = object.errno ?? 0;
  3518. message.data = (object.data !== undefined && object.data !== null) ? hero.fromPartial(object.data) : undefined;
  3519. return message;
  3520. },
  3521. };
  3522. function createBaseheroWearEquip(): heroWearEquip {
  3523. return { sid: "", list: [] };
  3524. }
  3525. export const heroWearEquip = {
  3526. fromJSON(object: any): heroWearEquip {
  3527. return {
  3528. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3529. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  3530. };
  3531. },
  3532. toJSON(message: heroWearEquip): unknown {
  3533. const obj: any = {};
  3534. if (message.sid !== "") {
  3535. obj.sid = message.sid;
  3536. }
  3537. if (message.list?.length) {
  3538. obj.list = message.list;
  3539. }
  3540. return obj;
  3541. },
  3542. create<I extends Exact<DeepPartial<heroWearEquip>, I>>(base?: I): heroWearEquip {
  3543. return heroWearEquip.fromPartial(base ?? ({} as any));
  3544. },
  3545. fromPartial<I extends Exact<DeepPartial<heroWearEquip>, I>>(object: I): heroWearEquip {
  3546. const message = createBaseheroWearEquip();
  3547. message.sid = object.sid ?? "";
  3548. message.list = object.list?.map((e) => e) || [];
  3549. return message;
  3550. },
  3551. };
  3552. function createBaseheroWearEquipRsp(): heroWearEquipRsp {
  3553. return { errno: 0, list: [], data: undefined };
  3554. }
  3555. export const heroWearEquipRsp = {
  3556. fromJSON(object: any): heroWearEquipRsp {
  3557. return {
  3558. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3559. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  3560. data: isSet(object.data) ? hero.fromJSON(object.data) : undefined,
  3561. };
  3562. },
  3563. toJSON(message: heroWearEquipRsp): unknown {
  3564. const obj: any = {};
  3565. if (message.errno !== 0) {
  3566. obj.errno = Math.round(message.errno);
  3567. }
  3568. if (message.list?.length) {
  3569. obj.list = message.list;
  3570. }
  3571. if (message.data !== undefined) {
  3572. obj.data = hero.toJSON(message.data);
  3573. }
  3574. return obj;
  3575. },
  3576. create<I extends Exact<DeepPartial<heroWearEquipRsp>, I>>(base?: I): heroWearEquipRsp {
  3577. return heroWearEquipRsp.fromPartial(base ?? ({} as any));
  3578. },
  3579. fromPartial<I extends Exact<DeepPartial<heroWearEquipRsp>, I>>(object: I): heroWearEquipRsp {
  3580. const message = createBaseheroWearEquipRsp();
  3581. message.errno = object.errno ?? 0;
  3582. message.list = object.list?.map((e) => e) || [];
  3583. message.data = (object.data !== undefined && object.data !== null) ? hero.fromPartial(object.data) : undefined;
  3584. return message;
  3585. },
  3586. };
  3587. function createBaseheroChangeNty(): heroChangeNty {
  3588. return { list: [] };
  3589. }
  3590. export const heroChangeNty = {
  3591. fromJSON(object: any): heroChangeNty {
  3592. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => hero.fromJSON(e)) : [] };
  3593. },
  3594. toJSON(message: heroChangeNty): unknown {
  3595. const obj: any = {};
  3596. if (message.list?.length) {
  3597. obj.list = message.list.map((e) => hero.toJSON(e));
  3598. }
  3599. return obj;
  3600. },
  3601. create<I extends Exact<DeepPartial<heroChangeNty>, I>>(base?: I): heroChangeNty {
  3602. return heroChangeNty.fromPartial(base ?? ({} as any));
  3603. },
  3604. fromPartial<I extends Exact<DeepPartial<heroChangeNty>, I>>(object: I): heroChangeNty {
  3605. const message = createBaseheroChangeNty();
  3606. message.list = object.list?.map((e) => hero.fromPartial(e)) || [];
  3607. return message;
  3608. },
  3609. };
  3610. function createBaseskillCardGetData(): skillCardGetData {
  3611. return {};
  3612. }
  3613. export const skillCardGetData = {
  3614. fromJSON(_: any): skillCardGetData {
  3615. return {};
  3616. },
  3617. toJSON(_: skillCardGetData): unknown {
  3618. const obj: any = {};
  3619. return obj;
  3620. },
  3621. create<I extends Exact<DeepPartial<skillCardGetData>, I>>(base?: I): skillCardGetData {
  3622. return skillCardGetData.fromPartial(base ?? ({} as any));
  3623. },
  3624. fromPartial<I extends Exact<DeepPartial<skillCardGetData>, I>>(_: I): skillCardGetData {
  3625. const message = createBaseskillCardGetData();
  3626. return message;
  3627. },
  3628. };
  3629. function createBaseskillCardGetDataRsp(): skillCardGetDataRsp {
  3630. return { errno: 0, list: [] };
  3631. }
  3632. export const skillCardGetDataRsp = {
  3633. fromJSON(object: any): skillCardGetDataRsp {
  3634. return {
  3635. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3636. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => card.fromJSON(e)) : [],
  3637. };
  3638. },
  3639. toJSON(message: skillCardGetDataRsp): unknown {
  3640. const obj: any = {};
  3641. if (message.errno !== 0) {
  3642. obj.errno = Math.round(message.errno);
  3643. }
  3644. if (message.list?.length) {
  3645. obj.list = message.list.map((e) => card.toJSON(e));
  3646. }
  3647. return obj;
  3648. },
  3649. create<I extends Exact<DeepPartial<skillCardGetDataRsp>, I>>(base?: I): skillCardGetDataRsp {
  3650. return skillCardGetDataRsp.fromPartial(base ?? ({} as any));
  3651. },
  3652. fromPartial<I extends Exact<DeepPartial<skillCardGetDataRsp>, I>>(object: I): skillCardGetDataRsp {
  3653. const message = createBaseskillCardGetDataRsp();
  3654. message.errno = object.errno ?? 0;
  3655. message.list = object.list?.map((e) => card.fromPartial(e)) || [];
  3656. return message;
  3657. },
  3658. };
  3659. function createBaseskillCardUpgrade(): skillCardUpgrade {
  3660. return { sid: "", num: 0 };
  3661. }
  3662. export const skillCardUpgrade = {
  3663. fromJSON(object: any): skillCardUpgrade {
  3664. return {
  3665. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  3666. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  3667. };
  3668. },
  3669. toJSON(message: skillCardUpgrade): unknown {
  3670. const obj: any = {};
  3671. if (message.sid !== "") {
  3672. obj.sid = message.sid;
  3673. }
  3674. if (message.num !== 0) {
  3675. obj.num = Math.round(message.num);
  3676. }
  3677. return obj;
  3678. },
  3679. create<I extends Exact<DeepPartial<skillCardUpgrade>, I>>(base?: I): skillCardUpgrade {
  3680. return skillCardUpgrade.fromPartial(base ?? ({} as any));
  3681. },
  3682. fromPartial<I extends Exact<DeepPartial<skillCardUpgrade>, I>>(object: I): skillCardUpgrade {
  3683. const message = createBaseskillCardUpgrade();
  3684. message.sid = object.sid ?? "";
  3685. message.num = object.num ?? 0;
  3686. return message;
  3687. },
  3688. };
  3689. function createBaseskillCardUpgradeRsp(): skillCardUpgradeRsp {
  3690. return { errno: 0, data: undefined };
  3691. }
  3692. export const skillCardUpgradeRsp = {
  3693. fromJSON(object: any): skillCardUpgradeRsp {
  3694. return {
  3695. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3696. data: isSet(object.data) ? card.fromJSON(object.data) : undefined,
  3697. };
  3698. },
  3699. toJSON(message: skillCardUpgradeRsp): unknown {
  3700. const obj: any = {};
  3701. if (message.errno !== 0) {
  3702. obj.errno = Math.round(message.errno);
  3703. }
  3704. if (message.data !== undefined) {
  3705. obj.data = card.toJSON(message.data);
  3706. }
  3707. return obj;
  3708. },
  3709. create<I extends Exact<DeepPartial<skillCardUpgradeRsp>, I>>(base?: I): skillCardUpgradeRsp {
  3710. return skillCardUpgradeRsp.fromPartial(base ?? ({} as any));
  3711. },
  3712. fromPartial<I extends Exact<DeepPartial<skillCardUpgradeRsp>, I>>(object: I): skillCardUpgradeRsp {
  3713. const message = createBaseskillCardUpgradeRsp();
  3714. message.errno = object.errno ?? 0;
  3715. message.data = (object.data !== undefined && object.data !== null) ? card.fromPartial(object.data) : undefined;
  3716. return message;
  3717. },
  3718. };
  3719. function createBaseskillCardUpgradeStar(): skillCardUpgradeStar {
  3720. return { sid: "" };
  3721. }
  3722. export const skillCardUpgradeStar = {
  3723. fromJSON(object: any): skillCardUpgradeStar {
  3724. return { sid: isSet(object.sid) ? globalThis.String(object.sid) : "" };
  3725. },
  3726. toJSON(message: skillCardUpgradeStar): unknown {
  3727. const obj: any = {};
  3728. if (message.sid !== "") {
  3729. obj.sid = message.sid;
  3730. }
  3731. return obj;
  3732. },
  3733. create<I extends Exact<DeepPartial<skillCardUpgradeStar>, I>>(base?: I): skillCardUpgradeStar {
  3734. return skillCardUpgradeStar.fromPartial(base ?? ({} as any));
  3735. },
  3736. fromPartial<I extends Exact<DeepPartial<skillCardUpgradeStar>, I>>(object: I): skillCardUpgradeStar {
  3737. const message = createBaseskillCardUpgradeStar();
  3738. message.sid = object.sid ?? "";
  3739. return message;
  3740. },
  3741. };
  3742. function createBaseskillCardUpgradeStarRsp(): skillCardUpgradeStarRsp {
  3743. return { errno: 0, data: undefined };
  3744. }
  3745. export const skillCardUpgradeStarRsp = {
  3746. fromJSON(object: any): skillCardUpgradeStarRsp {
  3747. return {
  3748. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3749. data: isSet(object.data) ? card.fromJSON(object.data) : undefined,
  3750. };
  3751. },
  3752. toJSON(message: skillCardUpgradeStarRsp): unknown {
  3753. const obj: any = {};
  3754. if (message.errno !== 0) {
  3755. obj.errno = Math.round(message.errno);
  3756. }
  3757. if (message.data !== undefined) {
  3758. obj.data = card.toJSON(message.data);
  3759. }
  3760. return obj;
  3761. },
  3762. create<I extends Exact<DeepPartial<skillCardUpgradeStarRsp>, I>>(base?: I): skillCardUpgradeStarRsp {
  3763. return skillCardUpgradeStarRsp.fromPartial(base ?? ({} as any));
  3764. },
  3765. fromPartial<I extends Exact<DeepPartial<skillCardUpgradeStarRsp>, I>>(object: I): skillCardUpgradeStarRsp {
  3766. const message = createBaseskillCardUpgradeStarRsp();
  3767. message.errno = object.errno ?? 0;
  3768. message.data = (object.data !== undefined && object.data !== null) ? card.fromPartial(object.data) : undefined;
  3769. return message;
  3770. },
  3771. };
  3772. function createBaseroleGetData(): roleGetData {
  3773. return {};
  3774. }
  3775. export const roleGetData = {
  3776. fromJSON(_: any): roleGetData {
  3777. return {};
  3778. },
  3779. toJSON(_: roleGetData): unknown {
  3780. const obj: any = {};
  3781. return obj;
  3782. },
  3783. create<I extends Exact<DeepPartial<roleGetData>, I>>(base?: I): roleGetData {
  3784. return roleGetData.fromPartial(base ?? ({} as any));
  3785. },
  3786. fromPartial<I extends Exact<DeepPartial<roleGetData>, I>>(_: I): roleGetData {
  3787. const message = createBaseroleGetData();
  3788. return message;
  3789. },
  3790. };
  3791. function createBaseroleGetDataRsp(): roleGetDataRsp {
  3792. return { errno: 0, level: 0, exp: 0 };
  3793. }
  3794. export const roleGetDataRsp = {
  3795. fromJSON(object: any): roleGetDataRsp {
  3796. return {
  3797. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3798. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  3799. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  3800. };
  3801. },
  3802. toJSON(message: roleGetDataRsp): unknown {
  3803. const obj: any = {};
  3804. if (message.errno !== 0) {
  3805. obj.errno = Math.round(message.errno);
  3806. }
  3807. if (message.level !== 0) {
  3808. obj.level = Math.round(message.level);
  3809. }
  3810. if (message.exp !== 0) {
  3811. obj.exp = Math.round(message.exp);
  3812. }
  3813. return obj;
  3814. },
  3815. create<I extends Exact<DeepPartial<roleGetDataRsp>, I>>(base?: I): roleGetDataRsp {
  3816. return roleGetDataRsp.fromPartial(base ?? ({} as any));
  3817. },
  3818. fromPartial<I extends Exact<DeepPartial<roleGetDataRsp>, I>>(object: I): roleGetDataRsp {
  3819. const message = createBaseroleGetDataRsp();
  3820. message.errno = object.errno ?? 0;
  3821. message.level = object.level ?? 0;
  3822. message.exp = object.exp ?? 0;
  3823. return message;
  3824. },
  3825. };
  3826. function createBaseroleUpgrade(): roleUpgrade {
  3827. return {};
  3828. }
  3829. export const roleUpgrade = {
  3830. fromJSON(_: any): roleUpgrade {
  3831. return {};
  3832. },
  3833. toJSON(_: roleUpgrade): unknown {
  3834. const obj: any = {};
  3835. return obj;
  3836. },
  3837. create<I extends Exact<DeepPartial<roleUpgrade>, I>>(base?: I): roleUpgrade {
  3838. return roleUpgrade.fromPartial(base ?? ({} as any));
  3839. },
  3840. fromPartial<I extends Exact<DeepPartial<roleUpgrade>, I>>(_: I): roleUpgrade {
  3841. const message = createBaseroleUpgrade();
  3842. return message;
  3843. },
  3844. };
  3845. function createBaseroleUpgradeRsp(): roleUpgradeRsp {
  3846. return { errno: 0, level: 0, exp: 0 };
  3847. }
  3848. export const roleUpgradeRsp = {
  3849. fromJSON(object: any): roleUpgradeRsp {
  3850. return {
  3851. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3852. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  3853. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  3854. };
  3855. },
  3856. toJSON(message: roleUpgradeRsp): unknown {
  3857. const obj: any = {};
  3858. if (message.errno !== 0) {
  3859. obj.errno = Math.round(message.errno);
  3860. }
  3861. if (message.level !== 0) {
  3862. obj.level = Math.round(message.level);
  3863. }
  3864. if (message.exp !== 0) {
  3865. obj.exp = Math.round(message.exp);
  3866. }
  3867. return obj;
  3868. },
  3869. create<I extends Exact<DeepPartial<roleUpgradeRsp>, I>>(base?: I): roleUpgradeRsp {
  3870. return roleUpgradeRsp.fromPartial(base ?? ({} as any));
  3871. },
  3872. fromPartial<I extends Exact<DeepPartial<roleUpgradeRsp>, I>>(object: I): roleUpgradeRsp {
  3873. const message = createBaseroleUpgradeRsp();
  3874. message.errno = object.errno ?? 0;
  3875. message.level = object.level ?? 0;
  3876. message.exp = object.exp ?? 0;
  3877. return message;
  3878. },
  3879. };
  3880. function createBaseroleRename(): roleRename {
  3881. return { name: "" };
  3882. }
  3883. export const roleRename = {
  3884. fromJSON(object: any): roleRename {
  3885. return { name: isSet(object.name) ? globalThis.String(object.name) : "" };
  3886. },
  3887. toJSON(message: roleRename): unknown {
  3888. const obj: any = {};
  3889. if (message.name !== "") {
  3890. obj.name = message.name;
  3891. }
  3892. return obj;
  3893. },
  3894. create<I extends Exact<DeepPartial<roleRename>, I>>(base?: I): roleRename {
  3895. return roleRename.fromPartial(base ?? ({} as any));
  3896. },
  3897. fromPartial<I extends Exact<DeepPartial<roleRename>, I>>(object: I): roleRename {
  3898. const message = createBaseroleRename();
  3899. message.name = object.name ?? "";
  3900. return message;
  3901. },
  3902. };
  3903. function createBaseroleRenameRsp(): roleRenameRsp {
  3904. return { errno: 0, name: "", time: 0 };
  3905. }
  3906. export const roleRenameRsp = {
  3907. fromJSON(object: any): roleRenameRsp {
  3908. return {
  3909. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3910. name: isSet(object.name) ? globalThis.String(object.name) : "",
  3911. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  3912. };
  3913. },
  3914. toJSON(message: roleRenameRsp): unknown {
  3915. const obj: any = {};
  3916. if (message.errno !== 0) {
  3917. obj.errno = Math.round(message.errno);
  3918. }
  3919. if (message.name !== "") {
  3920. obj.name = message.name;
  3921. }
  3922. if (message.time !== 0) {
  3923. obj.time = Math.round(message.time);
  3924. }
  3925. return obj;
  3926. },
  3927. create<I extends Exact<DeepPartial<roleRenameRsp>, I>>(base?: I): roleRenameRsp {
  3928. return roleRenameRsp.fromPartial(base ?? ({} as any));
  3929. },
  3930. fromPartial<I extends Exact<DeepPartial<roleRenameRsp>, I>>(object: I): roleRenameRsp {
  3931. const message = createBaseroleRenameRsp();
  3932. message.errno = object.errno ?? 0;
  3933. message.name = object.name ?? "";
  3934. message.time = object.time ?? 0;
  3935. return message;
  3936. },
  3937. };
  3938. function createBasedebrisGetData(): debrisGetData {
  3939. return {};
  3940. }
  3941. export const debrisGetData = {
  3942. fromJSON(_: any): debrisGetData {
  3943. return {};
  3944. },
  3945. toJSON(_: debrisGetData): unknown {
  3946. const obj: any = {};
  3947. return obj;
  3948. },
  3949. create<I extends Exact<DeepPartial<debrisGetData>, I>>(base?: I): debrisGetData {
  3950. return debrisGetData.fromPartial(base ?? ({} as any));
  3951. },
  3952. fromPartial<I extends Exact<DeepPartial<debrisGetData>, I>>(_: I): debrisGetData {
  3953. const message = createBasedebrisGetData();
  3954. return message;
  3955. },
  3956. };
  3957. function createBasedebrisGetDataRsp(): debrisGetDataRsp {
  3958. return { errno: 0, list: [] };
  3959. }
  3960. export const debrisGetDataRsp = {
  3961. fromJSON(object: any): debrisGetDataRsp {
  3962. return {
  3963. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  3964. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => idNum.fromJSON(e)) : [],
  3965. };
  3966. },
  3967. toJSON(message: debrisGetDataRsp): unknown {
  3968. const obj: any = {};
  3969. if (message.errno !== 0) {
  3970. obj.errno = Math.round(message.errno);
  3971. }
  3972. if (message.list?.length) {
  3973. obj.list = message.list.map((e) => idNum.toJSON(e));
  3974. }
  3975. return obj;
  3976. },
  3977. create<I extends Exact<DeepPartial<debrisGetDataRsp>, I>>(base?: I): debrisGetDataRsp {
  3978. return debrisGetDataRsp.fromPartial(base ?? ({} as any));
  3979. },
  3980. fromPartial<I extends Exact<DeepPartial<debrisGetDataRsp>, I>>(object: I): debrisGetDataRsp {
  3981. const message = createBasedebrisGetDataRsp();
  3982. message.errno = object.errno ?? 0;
  3983. message.list = object.list?.map((e) => idNum.fromPartial(e)) || [];
  3984. return message;
  3985. },
  3986. };
  3987. function createBasedebrisMerge(): debrisMerge {
  3988. return { id: 0 };
  3989. }
  3990. export const debrisMerge = {
  3991. fromJSON(object: any): debrisMerge {
  3992. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  3993. },
  3994. toJSON(message: debrisMerge): unknown {
  3995. const obj: any = {};
  3996. if (message.id !== 0) {
  3997. obj.id = Math.round(message.id);
  3998. }
  3999. return obj;
  4000. },
  4001. create<I extends Exact<DeepPartial<debrisMerge>, I>>(base?: I): debrisMerge {
  4002. return debrisMerge.fromPartial(base ?? ({} as any));
  4003. },
  4004. fromPartial<I extends Exact<DeepPartial<debrisMerge>, I>>(object: I): debrisMerge {
  4005. const message = createBasedebrisMerge();
  4006. message.id = object.id ?? 0;
  4007. return message;
  4008. },
  4009. };
  4010. function createBasedebrisMergeRsp(): debrisMergeRsp {
  4011. return { errno: 0 };
  4012. }
  4013. export const debrisMergeRsp = {
  4014. fromJSON(object: any): debrisMergeRsp {
  4015. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  4016. },
  4017. toJSON(message: debrisMergeRsp): unknown {
  4018. const obj: any = {};
  4019. if (message.errno !== 0) {
  4020. obj.errno = Math.round(message.errno);
  4021. }
  4022. return obj;
  4023. },
  4024. create<I extends Exact<DeepPartial<debrisMergeRsp>, I>>(base?: I): debrisMergeRsp {
  4025. return debrisMergeRsp.fromPartial(base ?? ({} as any));
  4026. },
  4027. fromPartial<I extends Exact<DeepPartial<debrisMergeRsp>, I>>(object: I): debrisMergeRsp {
  4028. const message = createBasedebrisMergeRsp();
  4029. message.errno = object.errno ?? 0;
  4030. return message;
  4031. },
  4032. };
  4033. function createBaseequipGetData(): equipGetData {
  4034. return {};
  4035. }
  4036. export const equipGetData = {
  4037. fromJSON(_: any): equipGetData {
  4038. return {};
  4039. },
  4040. toJSON(_: equipGetData): unknown {
  4041. const obj: any = {};
  4042. return obj;
  4043. },
  4044. create<I extends Exact<DeepPartial<equipGetData>, I>>(base?: I): equipGetData {
  4045. return equipGetData.fromPartial(base ?? ({} as any));
  4046. },
  4047. fromPartial<I extends Exact<DeepPartial<equipGetData>, I>>(_: I): equipGetData {
  4048. const message = createBaseequipGetData();
  4049. return message;
  4050. },
  4051. };
  4052. function createBaseequipGetDataRsp(): equipGetDataRsp {
  4053. return { errno: 0, list: [] };
  4054. }
  4055. export const equipGetDataRsp = {
  4056. fromJSON(object: any): equipGetDataRsp {
  4057. return {
  4058. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4059. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => equip.fromJSON(e)) : [],
  4060. };
  4061. },
  4062. toJSON(message: equipGetDataRsp): unknown {
  4063. const obj: any = {};
  4064. if (message.errno !== 0) {
  4065. obj.errno = Math.round(message.errno);
  4066. }
  4067. if (message.list?.length) {
  4068. obj.list = message.list.map((e) => equip.toJSON(e));
  4069. }
  4070. return obj;
  4071. },
  4072. create<I extends Exact<DeepPartial<equipGetDataRsp>, I>>(base?: I): equipGetDataRsp {
  4073. return equipGetDataRsp.fromPartial(base ?? ({} as any));
  4074. },
  4075. fromPartial<I extends Exact<DeepPartial<equipGetDataRsp>, I>>(object: I): equipGetDataRsp {
  4076. const message = createBaseequipGetDataRsp();
  4077. message.errno = object.errno ?? 0;
  4078. message.list = object.list?.map((e) => equip.fromPartial(e)) || [];
  4079. return message;
  4080. },
  4081. };
  4082. function createBaseequipUpgrade(): equipUpgrade {
  4083. return { sid: "", num: 0 };
  4084. }
  4085. export const equipUpgrade = {
  4086. fromJSON(object: any): equipUpgrade {
  4087. return {
  4088. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  4089. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  4090. };
  4091. },
  4092. toJSON(message: equipUpgrade): unknown {
  4093. const obj: any = {};
  4094. if (message.sid !== "") {
  4095. obj.sid = message.sid;
  4096. }
  4097. if (message.num !== 0) {
  4098. obj.num = Math.round(message.num);
  4099. }
  4100. return obj;
  4101. },
  4102. create<I extends Exact<DeepPartial<equipUpgrade>, I>>(base?: I): equipUpgrade {
  4103. return equipUpgrade.fromPartial(base ?? ({} as any));
  4104. },
  4105. fromPartial<I extends Exact<DeepPartial<equipUpgrade>, I>>(object: I): equipUpgrade {
  4106. const message = createBaseequipUpgrade();
  4107. message.sid = object.sid ?? "";
  4108. message.num = object.num ?? 0;
  4109. return message;
  4110. },
  4111. };
  4112. function createBaseequipUpgradeRsp(): equipUpgradeRsp {
  4113. return { errno: 0, data: undefined };
  4114. }
  4115. export const equipUpgradeRsp = {
  4116. fromJSON(object: any): equipUpgradeRsp {
  4117. return {
  4118. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4119. data: isSet(object.data) ? equip.fromJSON(object.data) : undefined,
  4120. };
  4121. },
  4122. toJSON(message: equipUpgradeRsp): unknown {
  4123. const obj: any = {};
  4124. if (message.errno !== 0) {
  4125. obj.errno = Math.round(message.errno);
  4126. }
  4127. if (message.data !== undefined) {
  4128. obj.data = equip.toJSON(message.data);
  4129. }
  4130. return obj;
  4131. },
  4132. create<I extends Exact<DeepPartial<equipUpgradeRsp>, I>>(base?: I): equipUpgradeRsp {
  4133. return equipUpgradeRsp.fromPartial(base ?? ({} as any));
  4134. },
  4135. fromPartial<I extends Exact<DeepPartial<equipUpgradeRsp>, I>>(object: I): equipUpgradeRsp {
  4136. const message = createBaseequipUpgradeRsp();
  4137. message.errno = object.errno ?? 0;
  4138. message.data = (object.data !== undefined && object.data !== null) ? equip.fromPartial(object.data) : undefined;
  4139. return message;
  4140. },
  4141. };
  4142. function createBaseequipUpgradeStar(): equipUpgradeStar {
  4143. return { sid: "", same: [], other: [], currency: undefined };
  4144. }
  4145. export const equipUpgradeStar = {
  4146. fromJSON(object: any): equipUpgradeStar {
  4147. return {
  4148. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  4149. same: globalThis.Array.isArray(object?.same) ? object.same.map((e: any) => globalThis.String(e)) : [],
  4150. other: globalThis.Array.isArray(object?.other) ? object.other.map((e: any) => globalThis.String(e)) : [],
  4151. currency: isSet(object.currency) ? idNum.fromJSON(object.currency) : undefined,
  4152. };
  4153. },
  4154. toJSON(message: equipUpgradeStar): unknown {
  4155. const obj: any = {};
  4156. if (message.sid !== "") {
  4157. obj.sid = message.sid;
  4158. }
  4159. if (message.same?.length) {
  4160. obj.same = message.same;
  4161. }
  4162. if (message.other?.length) {
  4163. obj.other = message.other;
  4164. }
  4165. if (message.currency !== undefined) {
  4166. obj.currency = idNum.toJSON(message.currency);
  4167. }
  4168. return obj;
  4169. },
  4170. create<I extends Exact<DeepPartial<equipUpgradeStar>, I>>(base?: I): equipUpgradeStar {
  4171. return equipUpgradeStar.fromPartial(base ?? ({} as any));
  4172. },
  4173. fromPartial<I extends Exact<DeepPartial<equipUpgradeStar>, I>>(object: I): equipUpgradeStar {
  4174. const message = createBaseequipUpgradeStar();
  4175. message.sid = object.sid ?? "";
  4176. message.same = object.same?.map((e) => e) || [];
  4177. message.other = object.other?.map((e) => e) || [];
  4178. message.currency = (object.currency !== undefined && object.currency !== null)
  4179. ? idNum.fromPartial(object.currency)
  4180. : undefined;
  4181. return message;
  4182. },
  4183. };
  4184. function createBaseequipUpgradeStarRsp(): equipUpgradeStarRsp {
  4185. return { errno: 0, data: undefined, same: [], other: [], currency: undefined };
  4186. }
  4187. export const equipUpgradeStarRsp = {
  4188. fromJSON(object: any): equipUpgradeStarRsp {
  4189. return {
  4190. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4191. data: isSet(object.data) ? equip.fromJSON(object.data) : undefined,
  4192. same: globalThis.Array.isArray(object?.same) ? object.same.map((e: any) => globalThis.String(e)) : [],
  4193. other: globalThis.Array.isArray(object?.other) ? object.other.map((e: any) => globalThis.String(e)) : [],
  4194. currency: isSet(object.currency) ? idNum.fromJSON(object.currency) : undefined,
  4195. };
  4196. },
  4197. toJSON(message: equipUpgradeStarRsp): unknown {
  4198. const obj: any = {};
  4199. if (message.errno !== 0) {
  4200. obj.errno = Math.round(message.errno);
  4201. }
  4202. if (message.data !== undefined) {
  4203. obj.data = equip.toJSON(message.data);
  4204. }
  4205. if (message.same?.length) {
  4206. obj.same = message.same;
  4207. }
  4208. if (message.other?.length) {
  4209. obj.other = message.other;
  4210. }
  4211. if (message.currency !== undefined) {
  4212. obj.currency = idNum.toJSON(message.currency);
  4213. }
  4214. return obj;
  4215. },
  4216. create<I extends Exact<DeepPartial<equipUpgradeStarRsp>, I>>(base?: I): equipUpgradeStarRsp {
  4217. return equipUpgradeStarRsp.fromPartial(base ?? ({} as any));
  4218. },
  4219. fromPartial<I extends Exact<DeepPartial<equipUpgradeStarRsp>, I>>(object: I): equipUpgradeStarRsp {
  4220. const message = createBaseequipUpgradeStarRsp();
  4221. message.errno = object.errno ?? 0;
  4222. message.data = (object.data !== undefined && object.data !== null) ? equip.fromPartial(object.data) : undefined;
  4223. message.same = object.same?.map((e) => e) || [];
  4224. message.other = object.other?.map((e) => e) || [];
  4225. message.currency = (object.currency !== undefined && object.currency !== null)
  4226. ? idNum.fromPartial(object.currency)
  4227. : undefined;
  4228. return message;
  4229. },
  4230. };
  4231. function createBaseequipOnekeyUpgradeStar(): equipOnekeyUpgradeStar {
  4232. return {};
  4233. }
  4234. export const equipOnekeyUpgradeStar = {
  4235. fromJSON(_: any): equipOnekeyUpgradeStar {
  4236. return {};
  4237. },
  4238. toJSON(_: equipOnekeyUpgradeStar): unknown {
  4239. const obj: any = {};
  4240. return obj;
  4241. },
  4242. create<I extends Exact<DeepPartial<equipOnekeyUpgradeStar>, I>>(base?: I): equipOnekeyUpgradeStar {
  4243. return equipOnekeyUpgradeStar.fromPartial(base ?? ({} as any));
  4244. },
  4245. fromPartial<I extends Exact<DeepPartial<equipOnekeyUpgradeStar>, I>>(_: I): equipOnekeyUpgradeStar {
  4246. const message = createBaseequipOnekeyUpgradeStar();
  4247. return message;
  4248. },
  4249. };
  4250. function createBaseequipOnekeyUpgradeStarRsp(): equipOnekeyUpgradeStarRsp {
  4251. return { errno: 0, delList: [], changeList: [] };
  4252. }
  4253. export const equipOnekeyUpgradeStarRsp = {
  4254. fromJSON(object: any): equipOnekeyUpgradeStarRsp {
  4255. return {
  4256. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4257. delList: globalThis.Array.isArray(object?.delList) ? object.delList.map((e: any) => globalThis.String(e)) : [],
  4258. changeList: globalThis.Array.isArray(object?.changeList)
  4259. ? object.changeList.map((e: any) => equip.fromJSON(e))
  4260. : [],
  4261. };
  4262. },
  4263. toJSON(message: equipOnekeyUpgradeStarRsp): unknown {
  4264. const obj: any = {};
  4265. if (message.errno !== 0) {
  4266. obj.errno = Math.round(message.errno);
  4267. }
  4268. if (message.delList?.length) {
  4269. obj.delList = message.delList;
  4270. }
  4271. if (message.changeList?.length) {
  4272. obj.changeList = message.changeList.map((e) => equip.toJSON(e));
  4273. }
  4274. return obj;
  4275. },
  4276. create<I extends Exact<DeepPartial<equipOnekeyUpgradeStarRsp>, I>>(base?: I): equipOnekeyUpgradeStarRsp {
  4277. return equipOnekeyUpgradeStarRsp.fromPartial(base ?? ({} as any));
  4278. },
  4279. fromPartial<I extends Exact<DeepPartial<equipOnekeyUpgradeStarRsp>, I>>(object: I): equipOnekeyUpgradeStarRsp {
  4280. const message = createBaseequipOnekeyUpgradeStarRsp();
  4281. message.errno = object.errno ?? 0;
  4282. message.delList = object.delList?.map((e) => e) || [];
  4283. message.changeList = object.changeList?.map((e) => equip.fromPartial(e)) || [];
  4284. return message;
  4285. },
  4286. };
  4287. function createBaseequipReset(): equipReset {
  4288. return { level: false, sid: "" };
  4289. }
  4290. export const equipReset = {
  4291. fromJSON(object: any): equipReset {
  4292. return {
  4293. level: isSet(object.level) ? globalThis.Boolean(object.level) : false,
  4294. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  4295. };
  4296. },
  4297. toJSON(message: equipReset): unknown {
  4298. const obj: any = {};
  4299. if (message.level !== false) {
  4300. obj.level = message.level;
  4301. }
  4302. if (message.sid !== "") {
  4303. obj.sid = message.sid;
  4304. }
  4305. return obj;
  4306. },
  4307. create<I extends Exact<DeepPartial<equipReset>, I>>(base?: I): equipReset {
  4308. return equipReset.fromPartial(base ?? ({} as any));
  4309. },
  4310. fromPartial<I extends Exact<DeepPartial<equipReset>, I>>(object: I): equipReset {
  4311. const message = createBaseequipReset();
  4312. message.level = object.level ?? false;
  4313. message.sid = object.sid ?? "";
  4314. return message;
  4315. },
  4316. };
  4317. function createBaseequipResetRsp(): equipResetRsp {
  4318. return { errno: 0, data: undefined };
  4319. }
  4320. export const equipResetRsp = {
  4321. fromJSON(object: any): equipResetRsp {
  4322. return {
  4323. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4324. data: isSet(object.data) ? equip.fromJSON(object.data) : undefined,
  4325. };
  4326. },
  4327. toJSON(message: equipResetRsp): unknown {
  4328. const obj: any = {};
  4329. if (message.errno !== 0) {
  4330. obj.errno = Math.round(message.errno);
  4331. }
  4332. if (message.data !== undefined) {
  4333. obj.data = equip.toJSON(message.data);
  4334. }
  4335. return obj;
  4336. },
  4337. create<I extends Exact<DeepPartial<equipResetRsp>, I>>(base?: I): equipResetRsp {
  4338. return equipResetRsp.fromPartial(base ?? ({} as any));
  4339. },
  4340. fromPartial<I extends Exact<DeepPartial<equipResetRsp>, I>>(object: I): equipResetRsp {
  4341. const message = createBaseequipResetRsp();
  4342. message.errno = object.errno ?? 0;
  4343. message.data = (object.data !== undefined && object.data !== null) ? equip.fromPartial(object.data) : undefined;
  4344. return message;
  4345. },
  4346. };
  4347. function createBaseequipChangeNty(): equipChangeNty {
  4348. return { list: [] };
  4349. }
  4350. export const equipChangeNty = {
  4351. fromJSON(object: any): equipChangeNty {
  4352. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => equip.fromJSON(e)) : [] };
  4353. },
  4354. toJSON(message: equipChangeNty): unknown {
  4355. const obj: any = {};
  4356. if (message.list?.length) {
  4357. obj.list = message.list.map((e) => equip.toJSON(e));
  4358. }
  4359. return obj;
  4360. },
  4361. create<I extends Exact<DeepPartial<equipChangeNty>, I>>(base?: I): equipChangeNty {
  4362. return equipChangeNty.fromPartial(base ?? ({} as any));
  4363. },
  4364. fromPartial<I extends Exact<DeepPartial<equipChangeNty>, I>>(object: I): equipChangeNty {
  4365. const message = createBaseequipChangeNty();
  4366. message.list = object.list?.map((e) => equip.fromPartial(e)) || [];
  4367. return message;
  4368. },
  4369. };
  4370. function createBasetalentGetData(): talentGetData {
  4371. return {};
  4372. }
  4373. export const talentGetData = {
  4374. fromJSON(_: any): talentGetData {
  4375. return {};
  4376. },
  4377. toJSON(_: talentGetData): unknown {
  4378. const obj: any = {};
  4379. return obj;
  4380. },
  4381. create<I extends Exact<DeepPartial<talentGetData>, I>>(base?: I): talentGetData {
  4382. return talentGetData.fromPartial(base ?? ({} as any));
  4383. },
  4384. fromPartial<I extends Exact<DeepPartial<talentGetData>, I>>(_: I): talentGetData {
  4385. const message = createBasetalentGetData();
  4386. return message;
  4387. },
  4388. };
  4389. function createBasetalentGetDataRsp(): talentGetDataRsp {
  4390. return { errno: 0, id1: 0, id2: 0 };
  4391. }
  4392. export const talentGetDataRsp = {
  4393. fromJSON(object: any): talentGetDataRsp {
  4394. return {
  4395. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4396. id1: isSet(object.id1) ? globalThis.Number(object.id1) : 0,
  4397. id2: isSet(object.id2) ? globalThis.Number(object.id2) : 0,
  4398. };
  4399. },
  4400. toJSON(message: talentGetDataRsp): unknown {
  4401. const obj: any = {};
  4402. if (message.errno !== 0) {
  4403. obj.errno = Math.round(message.errno);
  4404. }
  4405. if (message.id1 !== 0) {
  4406. obj.id1 = Math.round(message.id1);
  4407. }
  4408. if (message.id2 !== 0) {
  4409. obj.id2 = Math.round(message.id2);
  4410. }
  4411. return obj;
  4412. },
  4413. create<I extends Exact<DeepPartial<talentGetDataRsp>, I>>(base?: I): talentGetDataRsp {
  4414. return talentGetDataRsp.fromPartial(base ?? ({} as any));
  4415. },
  4416. fromPartial<I extends Exact<DeepPartial<talentGetDataRsp>, I>>(object: I): talentGetDataRsp {
  4417. const message = createBasetalentGetDataRsp();
  4418. message.errno = object.errno ?? 0;
  4419. message.id1 = object.id1 ?? 0;
  4420. message.id2 = object.id2 ?? 0;
  4421. return message;
  4422. },
  4423. };
  4424. function createBasetalentActivate(): talentActivate {
  4425. return { id: 0 };
  4426. }
  4427. export const talentActivate = {
  4428. fromJSON(object: any): talentActivate {
  4429. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  4430. },
  4431. toJSON(message: talentActivate): unknown {
  4432. const obj: any = {};
  4433. if (message.id !== 0) {
  4434. obj.id = Math.round(message.id);
  4435. }
  4436. return obj;
  4437. },
  4438. create<I extends Exact<DeepPartial<talentActivate>, I>>(base?: I): talentActivate {
  4439. return talentActivate.fromPartial(base ?? ({} as any));
  4440. },
  4441. fromPartial<I extends Exact<DeepPartial<talentActivate>, I>>(object: I): talentActivate {
  4442. const message = createBasetalentActivate();
  4443. message.id = object.id ?? 0;
  4444. return message;
  4445. },
  4446. };
  4447. function createBasetalentActivateRsp(): talentActivateRsp {
  4448. return { errno: 0, id: 0 };
  4449. }
  4450. export const talentActivateRsp = {
  4451. fromJSON(object: any): talentActivateRsp {
  4452. return {
  4453. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4454. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  4455. };
  4456. },
  4457. toJSON(message: talentActivateRsp): unknown {
  4458. const obj: any = {};
  4459. if (message.errno !== 0) {
  4460. obj.errno = Math.round(message.errno);
  4461. }
  4462. if (message.id !== 0) {
  4463. obj.id = Math.round(message.id);
  4464. }
  4465. return obj;
  4466. },
  4467. create<I extends Exact<DeepPartial<talentActivateRsp>, I>>(base?: I): talentActivateRsp {
  4468. return talentActivateRsp.fromPartial(base ?? ({} as any));
  4469. },
  4470. fromPartial<I extends Exact<DeepPartial<talentActivateRsp>, I>>(object: I): talentActivateRsp {
  4471. const message = createBasetalentActivateRsp();
  4472. message.errno = object.errno ?? 0;
  4473. message.id = object.id ?? 0;
  4474. return message;
  4475. },
  4476. };
  4477. function createBasesignInGetData(): signInGetData {
  4478. return {};
  4479. }
  4480. export const signInGetData = {
  4481. fromJSON(_: any): signInGetData {
  4482. return {};
  4483. },
  4484. toJSON(_: signInGetData): unknown {
  4485. const obj: any = {};
  4486. return obj;
  4487. },
  4488. create<I extends Exact<DeepPartial<signInGetData>, I>>(base?: I): signInGetData {
  4489. return signInGetData.fromPartial(base ?? ({} as any));
  4490. },
  4491. fromPartial<I extends Exact<DeepPartial<signInGetData>, I>>(_: I): signInGetData {
  4492. const message = createBasesignInGetData();
  4493. return message;
  4494. },
  4495. };
  4496. function createBasesignInGetDataRsp(): signInGetDataRsp {
  4497. return { errno: 0 };
  4498. }
  4499. export const signInGetDataRsp = {
  4500. fromJSON(object: any): signInGetDataRsp {
  4501. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  4502. },
  4503. toJSON(message: signInGetDataRsp): unknown {
  4504. const obj: any = {};
  4505. if (message.errno !== 0) {
  4506. obj.errno = Math.round(message.errno);
  4507. }
  4508. return obj;
  4509. },
  4510. create<I extends Exact<DeepPartial<signInGetDataRsp>, I>>(base?: I): signInGetDataRsp {
  4511. return signInGetDataRsp.fromPartial(base ?? ({} as any));
  4512. },
  4513. fromPartial<I extends Exact<DeepPartial<signInGetDataRsp>, I>>(object: I): signInGetDataRsp {
  4514. const message = createBasesignInGetDataRsp();
  4515. message.errno = object.errno ?? 0;
  4516. return message;
  4517. },
  4518. };
  4519. function createBasesignInAward(): signInAward {
  4520. return { day: 0 };
  4521. }
  4522. export const signInAward = {
  4523. fromJSON(object: any): signInAward {
  4524. return { day: isSet(object.day) ? globalThis.Number(object.day) : 0 };
  4525. },
  4526. toJSON(message: signInAward): unknown {
  4527. const obj: any = {};
  4528. if (message.day !== 0) {
  4529. obj.day = Math.round(message.day);
  4530. }
  4531. return obj;
  4532. },
  4533. create<I extends Exact<DeepPartial<signInAward>, I>>(base?: I): signInAward {
  4534. return signInAward.fromPartial(base ?? ({} as any));
  4535. },
  4536. fromPartial<I extends Exact<DeepPartial<signInAward>, I>>(object: I): signInAward {
  4537. const message = createBasesignInAward();
  4538. message.day = object.day ?? 0;
  4539. return message;
  4540. },
  4541. };
  4542. function createBasesignInAwardRsp(): signInAwardRsp {
  4543. return { errno: 0, day: 0, award: 0 };
  4544. }
  4545. export const signInAwardRsp = {
  4546. fromJSON(object: any): signInAwardRsp {
  4547. return {
  4548. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4549. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  4550. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  4551. };
  4552. },
  4553. toJSON(message: signInAwardRsp): unknown {
  4554. const obj: any = {};
  4555. if (message.errno !== 0) {
  4556. obj.errno = Math.round(message.errno);
  4557. }
  4558. if (message.day !== 0) {
  4559. obj.day = Math.round(message.day);
  4560. }
  4561. if (message.award !== 0) {
  4562. obj.award = Math.round(message.award);
  4563. }
  4564. return obj;
  4565. },
  4566. create<I extends Exact<DeepPartial<signInAwardRsp>, I>>(base?: I): signInAwardRsp {
  4567. return signInAwardRsp.fromPartial(base ?? ({} as any));
  4568. },
  4569. fromPartial<I extends Exact<DeepPartial<signInAwardRsp>, I>>(object: I): signInAwardRsp {
  4570. const message = createBasesignInAwardRsp();
  4571. message.errno = object.errno ?? 0;
  4572. message.day = object.day ?? 0;
  4573. message.award = object.award ?? 0;
  4574. return message;
  4575. },
  4576. };
  4577. function createBasesignInNty(): signInNty {
  4578. return { open: false, day: 0, award: 0, round: 0 };
  4579. }
  4580. export const signInNty = {
  4581. fromJSON(object: any): signInNty {
  4582. return {
  4583. open: isSet(object.open) ? globalThis.Boolean(object.open) : false,
  4584. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  4585. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  4586. round: isSet(object.round) ? globalThis.Number(object.round) : 0,
  4587. };
  4588. },
  4589. toJSON(message: signInNty): unknown {
  4590. const obj: any = {};
  4591. if (message.open !== false) {
  4592. obj.open = message.open;
  4593. }
  4594. if (message.day !== 0) {
  4595. obj.day = Math.round(message.day);
  4596. }
  4597. if (message.award !== 0) {
  4598. obj.award = Math.round(message.award);
  4599. }
  4600. if (message.round !== 0) {
  4601. obj.round = Math.round(message.round);
  4602. }
  4603. return obj;
  4604. },
  4605. create<I extends Exact<DeepPartial<signInNty>, I>>(base?: I): signInNty {
  4606. return signInNty.fromPartial(base ?? ({} as any));
  4607. },
  4608. fromPartial<I extends Exact<DeepPartial<signInNty>, I>>(object: I): signInNty {
  4609. const message = createBasesignInNty();
  4610. message.open = object.open ?? false;
  4611. message.day = object.day ?? 0;
  4612. message.award = object.award ?? 0;
  4613. message.round = object.round ?? 0;
  4614. return message;
  4615. },
  4616. };
  4617. function createBasequestGetData(): questGetData {
  4618. return {};
  4619. }
  4620. export const questGetData = {
  4621. fromJSON(_: any): questGetData {
  4622. return {};
  4623. },
  4624. toJSON(_: questGetData): unknown {
  4625. const obj: any = {};
  4626. return obj;
  4627. },
  4628. create<I extends Exact<DeepPartial<questGetData>, I>>(base?: I): questGetData {
  4629. return questGetData.fromPartial(base ?? ({} as any));
  4630. },
  4631. fromPartial<I extends Exact<DeepPartial<questGetData>, I>>(_: I): questGetData {
  4632. const message = createBasequestGetData();
  4633. return message;
  4634. },
  4635. };
  4636. function createBasequestGetDataRsp(): questGetDataRsp {
  4637. return {
  4638. errno: 0,
  4639. dlv: 0,
  4640. wlv: 0,
  4641. daward: 0,
  4642. waward: 0,
  4643. daily: [],
  4644. weekly: [],
  4645. achievement: [],
  4646. mainQuest: undefined,
  4647. };
  4648. }
  4649. export const questGetDataRsp = {
  4650. fromJSON(object: any): questGetDataRsp {
  4651. return {
  4652. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4653. dlv: isSet(object.dlv) ? globalThis.Number(object.dlv) : 0,
  4654. wlv: isSet(object.wlv) ? globalThis.Number(object.wlv) : 0,
  4655. daward: isSet(object.daward) ? globalThis.Number(object.daward) : 0,
  4656. waward: isSet(object.waward) ? globalThis.Number(object.waward) : 0,
  4657. daily: globalThis.Array.isArray(object?.daily) ? object.daily.map((e: any) => quest.fromJSON(e)) : [],
  4658. weekly: globalThis.Array.isArray(object?.weekly) ? object.weekly.map((e: any) => quest.fromJSON(e)) : [],
  4659. achievement: globalThis.Array.isArray(object?.achievement)
  4660. ? object.achievement.map((e: any) => quest.fromJSON(e))
  4661. : [],
  4662. mainQuest: isSet(object.mainQuest) ? quest.fromJSON(object.mainQuest) : undefined,
  4663. };
  4664. },
  4665. toJSON(message: questGetDataRsp): unknown {
  4666. const obj: any = {};
  4667. if (message.errno !== 0) {
  4668. obj.errno = Math.round(message.errno);
  4669. }
  4670. if (message.dlv !== 0) {
  4671. obj.dlv = Math.round(message.dlv);
  4672. }
  4673. if (message.wlv !== 0) {
  4674. obj.wlv = Math.round(message.wlv);
  4675. }
  4676. if (message.daward !== 0) {
  4677. obj.daward = Math.round(message.daward);
  4678. }
  4679. if (message.waward !== 0) {
  4680. obj.waward = Math.round(message.waward);
  4681. }
  4682. if (message.daily?.length) {
  4683. obj.daily = message.daily.map((e) => quest.toJSON(e));
  4684. }
  4685. if (message.weekly?.length) {
  4686. obj.weekly = message.weekly.map((e) => quest.toJSON(e));
  4687. }
  4688. if (message.achievement?.length) {
  4689. obj.achievement = message.achievement.map((e) => quest.toJSON(e));
  4690. }
  4691. if (message.mainQuest !== undefined) {
  4692. obj.mainQuest = quest.toJSON(message.mainQuest);
  4693. }
  4694. return obj;
  4695. },
  4696. create<I extends Exact<DeepPartial<questGetDataRsp>, I>>(base?: I): questGetDataRsp {
  4697. return questGetDataRsp.fromPartial(base ?? ({} as any));
  4698. },
  4699. fromPartial<I extends Exact<DeepPartial<questGetDataRsp>, I>>(object: I): questGetDataRsp {
  4700. const message = createBasequestGetDataRsp();
  4701. message.errno = object.errno ?? 0;
  4702. message.dlv = object.dlv ?? 0;
  4703. message.wlv = object.wlv ?? 0;
  4704. message.daward = object.daward ?? 0;
  4705. message.waward = object.waward ?? 0;
  4706. message.daily = object.daily?.map((e) => quest.fromPartial(e)) || [];
  4707. message.weekly = object.weekly?.map((e) => quest.fromPartial(e)) || [];
  4708. message.achievement = object.achievement?.map((e) => quest.fromPartial(e)) || [];
  4709. message.mainQuest = (object.mainQuest !== undefined && object.mainQuest !== null)
  4710. ? quest.fromPartial(object.mainQuest)
  4711. : undefined;
  4712. return message;
  4713. },
  4714. };
  4715. function createBasequestGetAward(): questGetAward {
  4716. return { id: 0 };
  4717. }
  4718. export const questGetAward = {
  4719. fromJSON(object: any): questGetAward {
  4720. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  4721. },
  4722. toJSON(message: questGetAward): unknown {
  4723. const obj: any = {};
  4724. if (message.id !== 0) {
  4725. obj.id = Math.round(message.id);
  4726. }
  4727. return obj;
  4728. },
  4729. create<I extends Exact<DeepPartial<questGetAward>, I>>(base?: I): questGetAward {
  4730. return questGetAward.fromPartial(base ?? ({} as any));
  4731. },
  4732. fromPartial<I extends Exact<DeepPartial<questGetAward>, I>>(object: I): questGetAward {
  4733. const message = createBasequestGetAward();
  4734. message.id = object.id ?? 0;
  4735. return message;
  4736. },
  4737. };
  4738. function createBasequestGetAwardRsp(): questGetAwardRsp {
  4739. return { errno: 0, id: 0, data: undefined };
  4740. }
  4741. export const questGetAwardRsp = {
  4742. fromJSON(object: any): questGetAwardRsp {
  4743. return {
  4744. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4745. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  4746. data: isSet(object.data) ? quest.fromJSON(object.data) : undefined,
  4747. };
  4748. },
  4749. toJSON(message: questGetAwardRsp): unknown {
  4750. const obj: any = {};
  4751. if (message.errno !== 0) {
  4752. obj.errno = Math.round(message.errno);
  4753. }
  4754. if (message.id !== 0) {
  4755. obj.id = Math.round(message.id);
  4756. }
  4757. if (message.data !== undefined) {
  4758. obj.data = quest.toJSON(message.data);
  4759. }
  4760. return obj;
  4761. },
  4762. create<I extends Exact<DeepPartial<questGetAwardRsp>, I>>(base?: I): questGetAwardRsp {
  4763. return questGetAwardRsp.fromPartial(base ?? ({} as any));
  4764. },
  4765. fromPartial<I extends Exact<DeepPartial<questGetAwardRsp>, I>>(object: I): questGetAwardRsp {
  4766. const message = createBasequestGetAwardRsp();
  4767. message.errno = object.errno ?? 0;
  4768. message.id = object.id ?? 0;
  4769. message.data = (object.data !== undefined && object.data !== null) ? quest.fromPartial(object.data) : undefined;
  4770. return message;
  4771. },
  4772. };
  4773. function createBasequestActiveAward(): questActiveAward {
  4774. return { type: 0 };
  4775. }
  4776. export const questActiveAward = {
  4777. fromJSON(object: any): questActiveAward {
  4778. return { type: isSet(object.type) ? globalThis.Number(object.type) : 0 };
  4779. },
  4780. toJSON(message: questActiveAward): unknown {
  4781. const obj: any = {};
  4782. if (message.type !== 0) {
  4783. obj.type = Math.round(message.type);
  4784. }
  4785. return obj;
  4786. },
  4787. create<I extends Exact<DeepPartial<questActiveAward>, I>>(base?: I): questActiveAward {
  4788. return questActiveAward.fromPartial(base ?? ({} as any));
  4789. },
  4790. fromPartial<I extends Exact<DeepPartial<questActiveAward>, I>>(object: I): questActiveAward {
  4791. const message = createBasequestActiveAward();
  4792. message.type = object.type ?? 0;
  4793. return message;
  4794. },
  4795. };
  4796. function createBasequestActiveAwardRsp(): questActiveAwardRsp {
  4797. return { errno: 0, type: 0, award: 0 };
  4798. }
  4799. export const questActiveAwardRsp = {
  4800. fromJSON(object: any): questActiveAwardRsp {
  4801. return {
  4802. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4803. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  4804. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  4805. };
  4806. },
  4807. toJSON(message: questActiveAwardRsp): unknown {
  4808. const obj: any = {};
  4809. if (message.errno !== 0) {
  4810. obj.errno = Math.round(message.errno);
  4811. }
  4812. if (message.type !== 0) {
  4813. obj.type = Math.round(message.type);
  4814. }
  4815. if (message.award !== 0) {
  4816. obj.award = Math.round(message.award);
  4817. }
  4818. return obj;
  4819. },
  4820. create<I extends Exact<DeepPartial<questActiveAwardRsp>, I>>(base?: I): questActiveAwardRsp {
  4821. return questActiveAwardRsp.fromPartial(base ?? ({} as any));
  4822. },
  4823. fromPartial<I extends Exact<DeepPartial<questActiveAwardRsp>, I>>(object: I): questActiveAwardRsp {
  4824. const message = createBasequestActiveAwardRsp();
  4825. message.errno = object.errno ?? 0;
  4826. message.type = object.type ?? 0;
  4827. message.award = object.award ?? 0;
  4828. return message;
  4829. },
  4830. };
  4831. function createBasequestCmplateNotify(): questCmplateNotify {
  4832. return { data: undefined };
  4833. }
  4834. export const questCmplateNotify = {
  4835. fromJSON(object: any): questCmplateNotify {
  4836. return { data: isSet(object.data) ? quest.fromJSON(object.data) : undefined };
  4837. },
  4838. toJSON(message: questCmplateNotify): unknown {
  4839. const obj: any = {};
  4840. if (message.data !== undefined) {
  4841. obj.data = quest.toJSON(message.data);
  4842. }
  4843. return obj;
  4844. },
  4845. create<I extends Exact<DeepPartial<questCmplateNotify>, I>>(base?: I): questCmplateNotify {
  4846. return questCmplateNotify.fromPartial(base ?? ({} as any));
  4847. },
  4848. fromPartial<I extends Exact<DeepPartial<questCmplateNotify>, I>>(object: I): questCmplateNotify {
  4849. const message = createBasequestCmplateNotify();
  4850. message.data = (object.data !== undefined && object.data !== null) ? quest.fromPartial(object.data) : undefined;
  4851. return message;
  4852. },
  4853. };
  4854. function createBasemanualGetData(): manualGetData {
  4855. return { moduleid: 0 };
  4856. }
  4857. export const manualGetData = {
  4858. fromJSON(object: any): manualGetData {
  4859. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  4860. },
  4861. toJSON(message: manualGetData): unknown {
  4862. const obj: any = {};
  4863. if (message.moduleid !== 0) {
  4864. obj.moduleid = Math.round(message.moduleid);
  4865. }
  4866. return obj;
  4867. },
  4868. create<I extends Exact<DeepPartial<manualGetData>, I>>(base?: I): manualGetData {
  4869. return manualGetData.fromPartial(base ?? ({} as any));
  4870. },
  4871. fromPartial<I extends Exact<DeepPartial<manualGetData>, I>>(object: I): manualGetData {
  4872. const message = createBasemanualGetData();
  4873. message.moduleid = object.moduleid ?? 0;
  4874. return message;
  4875. },
  4876. };
  4877. function createBasemanualGetDataRsp(): manualGetDataRsp {
  4878. return { errno: 0, open: false, openTime: 0, level: 0, exp: 0, round: 0, list: [], moduleid: 0 };
  4879. }
  4880. export const manualGetDataRsp = {
  4881. fromJSON(object: any): manualGetDataRsp {
  4882. return {
  4883. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4884. open: isSet(object.open) ? globalThis.Boolean(object.open) : false,
  4885. openTime: isSet(object.openTime) ? globalThis.Number(object.openTime) : 0,
  4886. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  4887. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  4888. round: isSet(object.round) ? globalThis.Number(object.round) : 0,
  4889. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => manual.fromJSON(e)) : [],
  4890. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  4891. };
  4892. },
  4893. toJSON(message: manualGetDataRsp): unknown {
  4894. const obj: any = {};
  4895. if (message.errno !== 0) {
  4896. obj.errno = Math.round(message.errno);
  4897. }
  4898. if (message.open !== false) {
  4899. obj.open = message.open;
  4900. }
  4901. if (message.openTime !== 0) {
  4902. obj.openTime = Math.round(message.openTime);
  4903. }
  4904. if (message.level !== 0) {
  4905. obj.level = Math.round(message.level);
  4906. }
  4907. if (message.exp !== 0) {
  4908. obj.exp = Math.round(message.exp);
  4909. }
  4910. if (message.round !== 0) {
  4911. obj.round = Math.round(message.round);
  4912. }
  4913. if (message.list?.length) {
  4914. obj.list = message.list.map((e) => manual.toJSON(e));
  4915. }
  4916. if (message.moduleid !== 0) {
  4917. obj.moduleid = Math.round(message.moduleid);
  4918. }
  4919. return obj;
  4920. },
  4921. create<I extends Exact<DeepPartial<manualGetDataRsp>, I>>(base?: I): manualGetDataRsp {
  4922. return manualGetDataRsp.fromPartial(base ?? ({} as any));
  4923. },
  4924. fromPartial<I extends Exact<DeepPartial<manualGetDataRsp>, I>>(object: I): manualGetDataRsp {
  4925. const message = createBasemanualGetDataRsp();
  4926. message.errno = object.errno ?? 0;
  4927. message.open = object.open ?? false;
  4928. message.openTime = object.openTime ?? 0;
  4929. message.level = object.level ?? 0;
  4930. message.exp = object.exp ?? 0;
  4931. message.round = object.round ?? 0;
  4932. message.list = object.list?.map((e) => manual.fromPartial(e)) || [];
  4933. message.moduleid = object.moduleid ?? 0;
  4934. return message;
  4935. },
  4936. };
  4937. function createBasemanualBuyExp(): manualBuyExp {
  4938. return { moduleid: 0 };
  4939. }
  4940. export const manualBuyExp = {
  4941. fromJSON(object: any): manualBuyExp {
  4942. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  4943. },
  4944. toJSON(message: manualBuyExp): unknown {
  4945. const obj: any = {};
  4946. if (message.moduleid !== 0) {
  4947. obj.moduleid = Math.round(message.moduleid);
  4948. }
  4949. return obj;
  4950. },
  4951. create<I extends Exact<DeepPartial<manualBuyExp>, I>>(base?: I): manualBuyExp {
  4952. return manualBuyExp.fromPartial(base ?? ({} as any));
  4953. },
  4954. fromPartial<I extends Exact<DeepPartial<manualBuyExp>, I>>(object: I): manualBuyExp {
  4955. const message = createBasemanualBuyExp();
  4956. message.moduleid = object.moduleid ?? 0;
  4957. return message;
  4958. },
  4959. };
  4960. function createBasemanualBuyExpRsp(): manualBuyExpRsp {
  4961. return { errno: 0, level: 0, exp: 0, moduleid: 0 };
  4962. }
  4963. export const manualBuyExpRsp = {
  4964. fromJSON(object: any): manualBuyExpRsp {
  4965. return {
  4966. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  4967. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  4968. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  4969. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  4970. };
  4971. },
  4972. toJSON(message: manualBuyExpRsp): unknown {
  4973. const obj: any = {};
  4974. if (message.errno !== 0) {
  4975. obj.errno = Math.round(message.errno);
  4976. }
  4977. if (message.level !== 0) {
  4978. obj.level = Math.round(message.level);
  4979. }
  4980. if (message.exp !== 0) {
  4981. obj.exp = Math.round(message.exp);
  4982. }
  4983. if (message.moduleid !== 0) {
  4984. obj.moduleid = Math.round(message.moduleid);
  4985. }
  4986. return obj;
  4987. },
  4988. create<I extends Exact<DeepPartial<manualBuyExpRsp>, I>>(base?: I): manualBuyExpRsp {
  4989. return manualBuyExpRsp.fromPartial(base ?? ({} as any));
  4990. },
  4991. fromPartial<I extends Exact<DeepPartial<manualBuyExpRsp>, I>>(object: I): manualBuyExpRsp {
  4992. const message = createBasemanualBuyExpRsp();
  4993. message.errno = object.errno ?? 0;
  4994. message.level = object.level ?? 0;
  4995. message.exp = object.exp ?? 0;
  4996. message.moduleid = object.moduleid ?? 0;
  4997. return message;
  4998. },
  4999. };
  5000. function createBasemanualGetAward(): manualGetAward {
  5001. return { moduleid: 0 };
  5002. }
  5003. export const manualGetAward = {
  5004. fromJSON(object: any): manualGetAward {
  5005. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  5006. },
  5007. toJSON(message: manualGetAward): unknown {
  5008. const obj: any = {};
  5009. if (message.moduleid !== 0) {
  5010. obj.moduleid = Math.round(message.moduleid);
  5011. }
  5012. return obj;
  5013. },
  5014. create<I extends Exact<DeepPartial<manualGetAward>, I>>(base?: I): manualGetAward {
  5015. return manualGetAward.fromPartial(base ?? ({} as any));
  5016. },
  5017. fromPartial<I extends Exact<DeepPartial<manualGetAward>, I>>(object: I): manualGetAward {
  5018. const message = createBasemanualGetAward();
  5019. message.moduleid = object.moduleid ?? 0;
  5020. return message;
  5021. },
  5022. };
  5023. function createBasemanualGetAwardRsp(): manualGetAwardRsp {
  5024. return { errno: 0, award: 0, moduleid: 0 };
  5025. }
  5026. export const manualGetAwardRsp = {
  5027. fromJSON(object: any): manualGetAwardRsp {
  5028. return {
  5029. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5030. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  5031. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  5032. };
  5033. },
  5034. toJSON(message: manualGetAwardRsp): unknown {
  5035. const obj: any = {};
  5036. if (message.errno !== 0) {
  5037. obj.errno = Math.round(message.errno);
  5038. }
  5039. if (message.award !== 0) {
  5040. obj.award = Math.round(message.award);
  5041. }
  5042. if (message.moduleid !== 0) {
  5043. obj.moduleid = Math.round(message.moduleid);
  5044. }
  5045. return obj;
  5046. },
  5047. create<I extends Exact<DeepPartial<manualGetAwardRsp>, I>>(base?: I): manualGetAwardRsp {
  5048. return manualGetAwardRsp.fromPartial(base ?? ({} as any));
  5049. },
  5050. fromPartial<I extends Exact<DeepPartial<manualGetAwardRsp>, I>>(object: I): manualGetAwardRsp {
  5051. const message = createBasemanualGetAwardRsp();
  5052. message.errno = object.errno ?? 0;
  5053. message.award = object.award ?? 0;
  5054. message.moduleid = object.moduleid ?? 0;
  5055. return message;
  5056. },
  5057. };
  5058. function createBasemanualNotify(): manualNotify {
  5059. return { open: false, openTime: 0, level: 0, exp: 0, round: 0, list: [], moduleid: 0 };
  5060. }
  5061. export const manualNotify = {
  5062. fromJSON(object: any): manualNotify {
  5063. return {
  5064. open: isSet(object.open) ? globalThis.Boolean(object.open) : false,
  5065. openTime: isSet(object.openTime) ? globalThis.Number(object.openTime) : 0,
  5066. level: isSet(object.level) ? globalThis.Number(object.level) : 0,
  5067. exp: isSet(object.exp) ? globalThis.Number(object.exp) : 0,
  5068. round: isSet(object.round) ? globalThis.Number(object.round) : 0,
  5069. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => manual.fromJSON(e)) : [],
  5070. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  5071. };
  5072. },
  5073. toJSON(message: manualNotify): unknown {
  5074. const obj: any = {};
  5075. if (message.open !== false) {
  5076. obj.open = message.open;
  5077. }
  5078. if (message.openTime !== 0) {
  5079. obj.openTime = Math.round(message.openTime);
  5080. }
  5081. if (message.level !== 0) {
  5082. obj.level = Math.round(message.level);
  5083. }
  5084. if (message.exp !== 0) {
  5085. obj.exp = Math.round(message.exp);
  5086. }
  5087. if (message.round !== 0) {
  5088. obj.round = Math.round(message.round);
  5089. }
  5090. if (message.list?.length) {
  5091. obj.list = message.list.map((e) => manual.toJSON(e));
  5092. }
  5093. if (message.moduleid !== 0) {
  5094. obj.moduleid = Math.round(message.moduleid);
  5095. }
  5096. return obj;
  5097. },
  5098. create<I extends Exact<DeepPartial<manualNotify>, I>>(base?: I): manualNotify {
  5099. return manualNotify.fromPartial(base ?? ({} as any));
  5100. },
  5101. fromPartial<I extends Exact<DeepPartial<manualNotify>, I>>(object: I): manualNotify {
  5102. const message = createBasemanualNotify();
  5103. message.open = object.open ?? false;
  5104. message.openTime = object.openTime ?? 0;
  5105. message.level = object.level ?? 0;
  5106. message.exp = object.exp ?? 0;
  5107. message.round = object.round ?? 0;
  5108. message.list = object.list?.map((e) => manual.fromPartial(e)) || [];
  5109. message.moduleid = object.moduleid ?? 0;
  5110. return message;
  5111. },
  5112. };
  5113. function createBasemanualBuy(): manualBuy {
  5114. return { giftid: 0, moduleid: 0 };
  5115. }
  5116. export const manualBuy = {
  5117. fromJSON(object: any): manualBuy {
  5118. return {
  5119. giftid: isSet(object.giftid) ? globalThis.Number(object.giftid) : 0,
  5120. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  5121. };
  5122. },
  5123. toJSON(message: manualBuy): unknown {
  5124. const obj: any = {};
  5125. if (message.giftid !== 0) {
  5126. obj.giftid = Math.round(message.giftid);
  5127. }
  5128. if (message.moduleid !== 0) {
  5129. obj.moduleid = Math.round(message.moduleid);
  5130. }
  5131. return obj;
  5132. },
  5133. create<I extends Exact<DeepPartial<manualBuy>, I>>(base?: I): manualBuy {
  5134. return manualBuy.fromPartial(base ?? ({} as any));
  5135. },
  5136. fromPartial<I extends Exact<DeepPartial<manualBuy>, I>>(object: I): manualBuy {
  5137. const message = createBasemanualBuy();
  5138. message.giftid = object.giftid ?? 0;
  5139. message.moduleid = object.moduleid ?? 0;
  5140. return message;
  5141. },
  5142. };
  5143. function createBasemanualBuyRsp(): manualBuyRsp {
  5144. return { errno: 0, moduleid: 0 };
  5145. }
  5146. export const manualBuyRsp = {
  5147. fromJSON(object: any): manualBuyRsp {
  5148. return {
  5149. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5150. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  5151. };
  5152. },
  5153. toJSON(message: manualBuyRsp): unknown {
  5154. const obj: any = {};
  5155. if (message.errno !== 0) {
  5156. obj.errno = Math.round(message.errno);
  5157. }
  5158. if (message.moduleid !== 0) {
  5159. obj.moduleid = Math.round(message.moduleid);
  5160. }
  5161. return obj;
  5162. },
  5163. create<I extends Exact<DeepPartial<manualBuyRsp>, I>>(base?: I): manualBuyRsp {
  5164. return manualBuyRsp.fromPartial(base ?? ({} as any));
  5165. },
  5166. fromPartial<I extends Exact<DeepPartial<manualBuyRsp>, I>>(object: I): manualBuyRsp {
  5167. const message = createBasemanualBuyRsp();
  5168. message.errno = object.errno ?? 0;
  5169. message.moduleid = object.moduleid ?? 0;
  5170. return message;
  5171. },
  5172. };
  5173. function createBasedraw(): draw {
  5174. return { drawType: 0, payType: 0, num: 0 };
  5175. }
  5176. export const draw = {
  5177. fromJSON(object: any): draw {
  5178. return {
  5179. drawType: isSet(object.drawType) ? globalThis.Number(object.drawType) : 0,
  5180. payType: isSet(object.payType) ? globalThis.Number(object.payType) : 0,
  5181. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  5182. };
  5183. },
  5184. toJSON(message: draw): unknown {
  5185. const obj: any = {};
  5186. if (message.drawType !== 0) {
  5187. obj.drawType = Math.round(message.drawType);
  5188. }
  5189. if (message.payType !== 0) {
  5190. obj.payType = Math.round(message.payType);
  5191. }
  5192. if (message.num !== 0) {
  5193. obj.num = Math.round(message.num);
  5194. }
  5195. return obj;
  5196. },
  5197. create<I extends Exact<DeepPartial<draw>, I>>(base?: I): draw {
  5198. return draw.fromPartial(base ?? ({} as any));
  5199. },
  5200. fromPartial<I extends Exact<DeepPartial<draw>, I>>(object: I): draw {
  5201. const message = createBasedraw();
  5202. message.drawType = object.drawType ?? 0;
  5203. message.payType = object.payType ?? 0;
  5204. message.num = object.num ?? 0;
  5205. return message;
  5206. },
  5207. };
  5208. function createBasedrawRsp(): drawRsp {
  5209. return { errno: 0, drawType: 0, daily: 0, free: 0, list: [], awardList: [] };
  5210. }
  5211. export const drawRsp = {
  5212. fromJSON(object: any): drawRsp {
  5213. return {
  5214. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5215. drawType: isSet(object.drawType) ? globalThis.Number(object.drawType) : 0,
  5216. daily: isSet(object.daily) ? globalThis.Number(object.daily) : 0,
  5217. free: isSet(object.free) ? globalThis.Number(object.free) : 0,
  5218. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.Number(e)) : [],
  5219. awardList: globalThis.Array.isArray(object?.awardList)
  5220. ? object.awardList.map((e: any) => drawAwardInfo.fromJSON(e))
  5221. : [],
  5222. };
  5223. },
  5224. toJSON(message: drawRsp): unknown {
  5225. const obj: any = {};
  5226. if (message.errno !== 0) {
  5227. obj.errno = Math.round(message.errno);
  5228. }
  5229. if (message.drawType !== 0) {
  5230. obj.drawType = Math.round(message.drawType);
  5231. }
  5232. if (message.daily !== 0) {
  5233. obj.daily = Math.round(message.daily);
  5234. }
  5235. if (message.free !== 0) {
  5236. obj.free = Math.round(message.free);
  5237. }
  5238. if (message.list?.length) {
  5239. obj.list = message.list.map((e) => Math.round(e));
  5240. }
  5241. if (message.awardList?.length) {
  5242. obj.awardList = message.awardList.map((e) => drawAwardInfo.toJSON(e));
  5243. }
  5244. return obj;
  5245. },
  5246. create<I extends Exact<DeepPartial<drawRsp>, I>>(base?: I): drawRsp {
  5247. return drawRsp.fromPartial(base ?? ({} as any));
  5248. },
  5249. fromPartial<I extends Exact<DeepPartial<drawRsp>, I>>(object: I): drawRsp {
  5250. const message = createBasedrawRsp();
  5251. message.errno = object.errno ?? 0;
  5252. message.drawType = object.drawType ?? 0;
  5253. message.daily = object.daily ?? 0;
  5254. message.free = object.free ?? 0;
  5255. message.list = object.list?.map((e) => e) || [];
  5256. message.awardList = object.awardList?.map((e) => drawAwardInfo.fromPartial(e)) || [];
  5257. return message;
  5258. },
  5259. };
  5260. function createBasedrawGetData(): drawGetData {
  5261. return {};
  5262. }
  5263. export const drawGetData = {
  5264. fromJSON(_: any): drawGetData {
  5265. return {};
  5266. },
  5267. toJSON(_: drawGetData): unknown {
  5268. const obj: any = {};
  5269. return obj;
  5270. },
  5271. create<I extends Exact<DeepPartial<drawGetData>, I>>(base?: I): drawGetData {
  5272. return drawGetData.fromPartial(base ?? ({} as any));
  5273. },
  5274. fromPartial<I extends Exact<DeepPartial<drawGetData>, I>>(_: I): drawGetData {
  5275. const message = createBasedrawGetData();
  5276. return message;
  5277. },
  5278. };
  5279. function createBasedrawGetDataRsp(): drawGetDataRsp {
  5280. return { errno: 0, hero: undefined, hero2: undefined, equip: undefined };
  5281. }
  5282. export const drawGetDataRsp = {
  5283. fromJSON(object: any): drawGetDataRsp {
  5284. return {
  5285. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5286. hero: isSet(object.hero) ? drawInfo.fromJSON(object.hero) : undefined,
  5287. hero2: isSet(object.hero2) ? drawInfo.fromJSON(object.hero2) : undefined,
  5288. equip: isSet(object.equip) ? drawInfo.fromJSON(object.equip) : undefined,
  5289. };
  5290. },
  5291. toJSON(message: drawGetDataRsp): unknown {
  5292. const obj: any = {};
  5293. if (message.errno !== 0) {
  5294. obj.errno = Math.round(message.errno);
  5295. }
  5296. if (message.hero !== undefined) {
  5297. obj.hero = drawInfo.toJSON(message.hero);
  5298. }
  5299. if (message.hero2 !== undefined) {
  5300. obj.hero2 = drawInfo.toJSON(message.hero2);
  5301. }
  5302. if (message.equip !== undefined) {
  5303. obj.equip = drawInfo.toJSON(message.equip);
  5304. }
  5305. return obj;
  5306. },
  5307. create<I extends Exact<DeepPartial<drawGetDataRsp>, I>>(base?: I): drawGetDataRsp {
  5308. return drawGetDataRsp.fromPartial(base ?? ({} as any));
  5309. },
  5310. fromPartial<I extends Exact<DeepPartial<drawGetDataRsp>, I>>(object: I): drawGetDataRsp {
  5311. const message = createBasedrawGetDataRsp();
  5312. message.errno = object.errno ?? 0;
  5313. message.hero = (object.hero !== undefined && object.hero !== null) ? drawInfo.fromPartial(object.hero) : undefined;
  5314. message.hero2 = (object.hero2 !== undefined && object.hero2 !== null)
  5315. ? drawInfo.fromPartial(object.hero2)
  5316. : undefined;
  5317. message.equip = (object.equip !== undefined && object.equip !== null)
  5318. ? drawInfo.fromPartial(object.equip)
  5319. : undefined;
  5320. return message;
  5321. },
  5322. };
  5323. function createBaseshopData(): shopData {
  5324. return {};
  5325. }
  5326. export const shopData = {
  5327. fromJSON(_: any): shopData {
  5328. return {};
  5329. },
  5330. toJSON(_: shopData): unknown {
  5331. const obj: any = {};
  5332. return obj;
  5333. },
  5334. create<I extends Exact<DeepPartial<shopData>, I>>(base?: I): shopData {
  5335. return shopData.fromPartial(base ?? ({} as any));
  5336. },
  5337. fromPartial<I extends Exact<DeepPartial<shopData>, I>>(_: I): shopData {
  5338. const message = createBaseshopData();
  5339. return message;
  5340. },
  5341. };
  5342. function createBaseshopDataRsp(): shopDataRsp {
  5343. return { errno: 0, list: [] };
  5344. }
  5345. export const shopDataRsp = {
  5346. fromJSON(object: any): shopDataRsp {
  5347. return {
  5348. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5349. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => shopInfo.fromJSON(e)) : [],
  5350. };
  5351. },
  5352. toJSON(message: shopDataRsp): unknown {
  5353. const obj: any = {};
  5354. if (message.errno !== 0) {
  5355. obj.errno = Math.round(message.errno);
  5356. }
  5357. if (message.list?.length) {
  5358. obj.list = message.list.map((e) => shopInfo.toJSON(e));
  5359. }
  5360. return obj;
  5361. },
  5362. create<I extends Exact<DeepPartial<shopDataRsp>, I>>(base?: I): shopDataRsp {
  5363. return shopDataRsp.fromPartial(base ?? ({} as any));
  5364. },
  5365. fromPartial<I extends Exact<DeepPartial<shopDataRsp>, I>>(object: I): shopDataRsp {
  5366. const message = createBaseshopDataRsp();
  5367. message.errno = object.errno ?? 0;
  5368. message.list = object.list?.map((e) => shopInfo.fromPartial(e)) || [];
  5369. return message;
  5370. },
  5371. };
  5372. function createBaseshopBuy(): shopBuy {
  5373. return { type: 0, id: 0, num: 0 };
  5374. }
  5375. export const shopBuy = {
  5376. fromJSON(object: any): shopBuy {
  5377. return {
  5378. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5379. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  5380. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  5381. };
  5382. },
  5383. toJSON(message: shopBuy): unknown {
  5384. const obj: any = {};
  5385. if (message.type !== 0) {
  5386. obj.type = Math.round(message.type);
  5387. }
  5388. if (message.id !== 0) {
  5389. obj.id = Math.round(message.id);
  5390. }
  5391. if (message.num !== 0) {
  5392. obj.num = Math.round(message.num);
  5393. }
  5394. return obj;
  5395. },
  5396. create<I extends Exact<DeepPartial<shopBuy>, I>>(base?: I): shopBuy {
  5397. return shopBuy.fromPartial(base ?? ({} as any));
  5398. },
  5399. fromPartial<I extends Exact<DeepPartial<shopBuy>, I>>(object: I): shopBuy {
  5400. const message = createBaseshopBuy();
  5401. message.type = object.type ?? 0;
  5402. message.id = object.id ?? 0;
  5403. message.num = object.num ?? 0;
  5404. return message;
  5405. },
  5406. };
  5407. function createBaseshopBuyRsp(): shopBuyRsp {
  5408. return { errno: 0 };
  5409. }
  5410. export const shopBuyRsp = {
  5411. fromJSON(object: any): shopBuyRsp {
  5412. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  5413. },
  5414. toJSON(message: shopBuyRsp): unknown {
  5415. const obj: any = {};
  5416. if (message.errno !== 0) {
  5417. obj.errno = Math.round(message.errno);
  5418. }
  5419. return obj;
  5420. },
  5421. create<I extends Exact<DeepPartial<shopBuyRsp>, I>>(base?: I): shopBuyRsp {
  5422. return shopBuyRsp.fromPartial(base ?? ({} as any));
  5423. },
  5424. fromPartial<I extends Exact<DeepPartial<shopBuyRsp>, I>>(object: I): shopBuyRsp {
  5425. const message = createBaseshopBuyRsp();
  5426. message.errno = object.errno ?? 0;
  5427. return message;
  5428. },
  5429. };
  5430. function createBaseshopNotify(): shopNotify {
  5431. return { type: 0, id: 0, num: 0 };
  5432. }
  5433. export const shopNotify = {
  5434. fromJSON(object: any): shopNotify {
  5435. return {
  5436. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5437. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  5438. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  5439. };
  5440. },
  5441. toJSON(message: shopNotify): unknown {
  5442. const obj: any = {};
  5443. if (message.type !== 0) {
  5444. obj.type = Math.round(message.type);
  5445. }
  5446. if (message.id !== 0) {
  5447. obj.id = Math.round(message.id);
  5448. }
  5449. if (message.num !== 0) {
  5450. obj.num = Math.round(message.num);
  5451. }
  5452. return obj;
  5453. },
  5454. create<I extends Exact<DeepPartial<shopNotify>, I>>(base?: I): shopNotify {
  5455. return shopNotify.fromPartial(base ?? ({} as any));
  5456. },
  5457. fromPartial<I extends Exact<DeepPartial<shopNotify>, I>>(object: I): shopNotify {
  5458. const message = createBaseshopNotify();
  5459. message.type = object.type ?? 0;
  5460. message.id = object.id ?? 0;
  5461. message.num = object.num ?? 0;
  5462. return message;
  5463. },
  5464. };
  5465. function createBaserankingData(): rankingData {
  5466. return { type: 0 };
  5467. }
  5468. export const rankingData = {
  5469. fromJSON(object: any): rankingData {
  5470. return { type: isSet(object.type) ? globalThis.Number(object.type) : 0 };
  5471. },
  5472. toJSON(message: rankingData): unknown {
  5473. const obj: any = {};
  5474. if (message.type !== 0) {
  5475. obj.type = Math.round(message.type);
  5476. }
  5477. return obj;
  5478. },
  5479. create<I extends Exact<DeepPartial<rankingData>, I>>(base?: I): rankingData {
  5480. return rankingData.fromPartial(base ?? ({} as any));
  5481. },
  5482. fromPartial<I extends Exact<DeepPartial<rankingData>, I>>(object: I): rankingData {
  5483. const message = createBaserankingData();
  5484. message.type = object.type ?? 0;
  5485. return message;
  5486. },
  5487. };
  5488. function createBaserankingDataRsp(): rankingDataRsp {
  5489. return { errno: 0, type: 0, list: [], myslef: undefined };
  5490. }
  5491. export const rankingDataRsp = {
  5492. fromJSON(object: any): rankingDataRsp {
  5493. return {
  5494. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5495. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5496. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => rankingInfo.fromJSON(e)) : [],
  5497. myslef: isSet(object.myslef) ? rankingInfo.fromJSON(object.myslef) : undefined,
  5498. };
  5499. },
  5500. toJSON(message: rankingDataRsp): unknown {
  5501. const obj: any = {};
  5502. if (message.errno !== 0) {
  5503. obj.errno = Math.round(message.errno);
  5504. }
  5505. if (message.type !== 0) {
  5506. obj.type = Math.round(message.type);
  5507. }
  5508. if (message.list?.length) {
  5509. obj.list = message.list.map((e) => rankingInfo.toJSON(e));
  5510. }
  5511. if (message.myslef !== undefined) {
  5512. obj.myslef = rankingInfo.toJSON(message.myslef);
  5513. }
  5514. return obj;
  5515. },
  5516. create<I extends Exact<DeepPartial<rankingDataRsp>, I>>(base?: I): rankingDataRsp {
  5517. return rankingDataRsp.fromPartial(base ?? ({} as any));
  5518. },
  5519. fromPartial<I extends Exact<DeepPartial<rankingDataRsp>, I>>(object: I): rankingDataRsp {
  5520. const message = createBaserankingDataRsp();
  5521. message.errno = object.errno ?? 0;
  5522. message.type = object.type ?? 0;
  5523. message.list = object.list?.map((e) => rankingInfo.fromPartial(e)) || [];
  5524. message.myslef = (object.myslef !== undefined && object.myslef !== null)
  5525. ? rankingInfo.fromPartial(object.myslef)
  5526. : undefined;
  5527. return message;
  5528. },
  5529. };
  5530. function createBasegroceryData(): groceryData {
  5531. return { type: 0 };
  5532. }
  5533. export const groceryData = {
  5534. fromJSON(object: any): groceryData {
  5535. return { type: isSet(object.type) ? globalThis.Number(object.type) : 0 };
  5536. },
  5537. toJSON(message: groceryData): unknown {
  5538. const obj: any = {};
  5539. if (message.type !== 0) {
  5540. obj.type = Math.round(message.type);
  5541. }
  5542. return obj;
  5543. },
  5544. create<I extends Exact<DeepPartial<groceryData>, I>>(base?: I): groceryData {
  5545. return groceryData.fromPartial(base ?? ({} as any));
  5546. },
  5547. fromPartial<I extends Exact<DeepPartial<groceryData>, I>>(object: I): groceryData {
  5548. const message = createBasegroceryData();
  5549. message.type = object.type ?? 0;
  5550. return message;
  5551. },
  5552. };
  5553. function createBasegroceryDataRsp(): groceryDataRsp {
  5554. return { errno: 0, data: undefined };
  5555. }
  5556. export const groceryDataRsp = {
  5557. fromJSON(object: any): groceryDataRsp {
  5558. return {
  5559. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5560. data: isSet(object.data) ? groceryInfo.fromJSON(object.data) : undefined,
  5561. };
  5562. },
  5563. toJSON(message: groceryDataRsp): unknown {
  5564. const obj: any = {};
  5565. if (message.errno !== 0) {
  5566. obj.errno = Math.round(message.errno);
  5567. }
  5568. if (message.data !== undefined) {
  5569. obj.data = groceryInfo.toJSON(message.data);
  5570. }
  5571. return obj;
  5572. },
  5573. create<I extends Exact<DeepPartial<groceryDataRsp>, I>>(base?: I): groceryDataRsp {
  5574. return groceryDataRsp.fromPartial(base ?? ({} as any));
  5575. },
  5576. fromPartial<I extends Exact<DeepPartial<groceryDataRsp>, I>>(object: I): groceryDataRsp {
  5577. const message = createBasegroceryDataRsp();
  5578. message.errno = object.errno ?? 0;
  5579. message.data = (object.data !== undefined && object.data !== null)
  5580. ? groceryInfo.fromPartial(object.data)
  5581. : undefined;
  5582. return message;
  5583. },
  5584. };
  5585. function createBasegroceryBuy(): groceryBuy {
  5586. return { type: 0, free: false };
  5587. }
  5588. export const groceryBuy = {
  5589. fromJSON(object: any): groceryBuy {
  5590. return {
  5591. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5592. free: isSet(object.free) ? globalThis.Boolean(object.free) : false,
  5593. };
  5594. },
  5595. toJSON(message: groceryBuy): unknown {
  5596. const obj: any = {};
  5597. if (message.type !== 0) {
  5598. obj.type = Math.round(message.type);
  5599. }
  5600. if (message.free !== false) {
  5601. obj.free = message.free;
  5602. }
  5603. return obj;
  5604. },
  5605. create<I extends Exact<DeepPartial<groceryBuy>, I>>(base?: I): groceryBuy {
  5606. return groceryBuy.fromPartial(base ?? ({} as any));
  5607. },
  5608. fromPartial<I extends Exact<DeepPartial<groceryBuy>, I>>(object: I): groceryBuy {
  5609. const message = createBasegroceryBuy();
  5610. message.type = object.type ?? 0;
  5611. message.free = object.free ?? false;
  5612. return message;
  5613. },
  5614. };
  5615. function createBasegroceryBuyRsp(): groceryBuyRsp {
  5616. return { errno: 0, data: undefined };
  5617. }
  5618. export const groceryBuyRsp = {
  5619. fromJSON(object: any): groceryBuyRsp {
  5620. return {
  5621. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5622. data: isSet(object.data) ? groceryInfo.fromJSON(object.data) : undefined,
  5623. };
  5624. },
  5625. toJSON(message: groceryBuyRsp): unknown {
  5626. const obj: any = {};
  5627. if (message.errno !== 0) {
  5628. obj.errno = Math.round(message.errno);
  5629. }
  5630. if (message.data !== undefined) {
  5631. obj.data = groceryInfo.toJSON(message.data);
  5632. }
  5633. return obj;
  5634. },
  5635. create<I extends Exact<DeepPartial<groceryBuyRsp>, I>>(base?: I): groceryBuyRsp {
  5636. return groceryBuyRsp.fromPartial(base ?? ({} as any));
  5637. },
  5638. fromPartial<I extends Exact<DeepPartial<groceryBuyRsp>, I>>(object: I): groceryBuyRsp {
  5639. const message = createBasegroceryBuyRsp();
  5640. message.errno = object.errno ?? 0;
  5641. message.data = (object.data !== undefined && object.data !== null)
  5642. ? groceryInfo.fromPartial(object.data)
  5643. : undefined;
  5644. return message;
  5645. },
  5646. };
  5647. function createBasealtarData(): altarData {
  5648. return {};
  5649. }
  5650. export const altarData = {
  5651. fromJSON(_: any): altarData {
  5652. return {};
  5653. },
  5654. toJSON(_: altarData): unknown {
  5655. const obj: any = {};
  5656. return obj;
  5657. },
  5658. create<I extends Exact<DeepPartial<altarData>, I>>(base?: I): altarData {
  5659. return altarData.fromPartial(base ?? ({} as any));
  5660. },
  5661. fromPartial<I extends Exact<DeepPartial<altarData>, I>>(_: I): altarData {
  5662. const message = createBasealtarData();
  5663. return message;
  5664. },
  5665. };
  5666. function createBasealtarDataRsp(): altarDataRsp {
  5667. return { errno: 0, baseList: [], list: [], buyNum: 0, equipFree: 0, heroFree: 0 };
  5668. }
  5669. export const altarDataRsp = {
  5670. fromJSON(object: any): altarDataRsp {
  5671. return {
  5672. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5673. baseList: globalThis.Array.isArray(object?.baseList) ? object.baseList.map((e: any) => globalThis.String(e)) : [],
  5674. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => altarInfo.fromJSON(e)) : [],
  5675. buyNum: isSet(object.buyNum) ? globalThis.Number(object.buyNum) : 0,
  5676. equipFree: isSet(object.equipFree) ? globalThis.Number(object.equipFree) : 0,
  5677. heroFree: isSet(object.heroFree) ? globalThis.Number(object.heroFree) : 0,
  5678. };
  5679. },
  5680. toJSON(message: altarDataRsp): unknown {
  5681. const obj: any = {};
  5682. if (message.errno !== 0) {
  5683. obj.errno = Math.round(message.errno);
  5684. }
  5685. if (message.baseList?.length) {
  5686. obj.baseList = message.baseList;
  5687. }
  5688. if (message.list?.length) {
  5689. obj.list = message.list.map((e) => altarInfo.toJSON(e));
  5690. }
  5691. if (message.buyNum !== 0) {
  5692. obj.buyNum = Math.round(message.buyNum);
  5693. }
  5694. if (message.equipFree !== 0) {
  5695. obj.equipFree = Math.round(message.equipFree);
  5696. }
  5697. if (message.heroFree !== 0) {
  5698. obj.heroFree = Math.round(message.heroFree);
  5699. }
  5700. return obj;
  5701. },
  5702. create<I extends Exact<DeepPartial<altarDataRsp>, I>>(base?: I): altarDataRsp {
  5703. return altarDataRsp.fromPartial(base ?? ({} as any));
  5704. },
  5705. fromPartial<I extends Exact<DeepPartial<altarDataRsp>, I>>(object: I): altarDataRsp {
  5706. const message = createBasealtarDataRsp();
  5707. message.errno = object.errno ?? 0;
  5708. message.baseList = object.baseList?.map((e) => e) || [];
  5709. message.list = object.list?.map((e) => altarInfo.fromPartial(e)) || [];
  5710. message.buyNum = object.buyNum ?? 0;
  5711. message.equipFree = object.equipFree ?? 0;
  5712. message.heroFree = object.heroFree ?? 0;
  5713. return message;
  5714. },
  5715. };
  5716. function createBasealtarBattle(): altarBattle {
  5717. return { pos: 0, sid: "" };
  5718. }
  5719. export const altarBattle = {
  5720. fromJSON(object: any): altarBattle {
  5721. return {
  5722. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  5723. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  5724. };
  5725. },
  5726. toJSON(message: altarBattle): unknown {
  5727. const obj: any = {};
  5728. if (message.pos !== 0) {
  5729. obj.pos = Math.round(message.pos);
  5730. }
  5731. if (message.sid !== "") {
  5732. obj.sid = message.sid;
  5733. }
  5734. return obj;
  5735. },
  5736. create<I extends Exact<DeepPartial<altarBattle>, I>>(base?: I): altarBattle {
  5737. return altarBattle.fromPartial(base ?? ({} as any));
  5738. },
  5739. fromPartial<I extends Exact<DeepPartial<altarBattle>, I>>(object: I): altarBattle {
  5740. const message = createBasealtarBattle();
  5741. message.pos = object.pos ?? 0;
  5742. message.sid = object.sid ?? "";
  5743. return message;
  5744. },
  5745. };
  5746. function createBasealtarBattleRsp(): altarBattleRsp {
  5747. return { errno: 0, pos: 0, data: undefined };
  5748. }
  5749. export const altarBattleRsp = {
  5750. fromJSON(object: any): altarBattleRsp {
  5751. return {
  5752. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5753. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  5754. data: isSet(object.data) ? altarInfo.fromJSON(object.data) : undefined,
  5755. };
  5756. },
  5757. toJSON(message: altarBattleRsp): unknown {
  5758. const obj: any = {};
  5759. if (message.errno !== 0) {
  5760. obj.errno = Math.round(message.errno);
  5761. }
  5762. if (message.pos !== 0) {
  5763. obj.pos = Math.round(message.pos);
  5764. }
  5765. if (message.data !== undefined) {
  5766. obj.data = altarInfo.toJSON(message.data);
  5767. }
  5768. return obj;
  5769. },
  5770. create<I extends Exact<DeepPartial<altarBattleRsp>, I>>(base?: I): altarBattleRsp {
  5771. return altarBattleRsp.fromPartial(base ?? ({} as any));
  5772. },
  5773. fromPartial<I extends Exact<DeepPartial<altarBattleRsp>, I>>(object: I): altarBattleRsp {
  5774. const message = createBasealtarBattleRsp();
  5775. message.errno = object.errno ?? 0;
  5776. message.pos = object.pos ?? 0;
  5777. message.data = (object.data !== undefined && object.data !== null) ? altarInfo.fromPartial(object.data) : undefined;
  5778. return message;
  5779. },
  5780. };
  5781. function createBasealtarExchange(): altarExchange {
  5782. return { type: 0, sid: "" };
  5783. }
  5784. export const altarExchange = {
  5785. fromJSON(object: any): altarExchange {
  5786. return {
  5787. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5788. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  5789. };
  5790. },
  5791. toJSON(message: altarExchange): unknown {
  5792. const obj: any = {};
  5793. if (message.type !== 0) {
  5794. obj.type = Math.round(message.type);
  5795. }
  5796. if (message.sid !== "") {
  5797. obj.sid = message.sid;
  5798. }
  5799. return obj;
  5800. },
  5801. create<I extends Exact<DeepPartial<altarExchange>, I>>(base?: I): altarExchange {
  5802. return altarExchange.fromPartial(base ?? ({} as any));
  5803. },
  5804. fromPartial<I extends Exact<DeepPartial<altarExchange>, I>>(object: I): altarExchange {
  5805. const message = createBasealtarExchange();
  5806. message.type = object.type ?? 0;
  5807. message.sid = object.sid ?? "";
  5808. return message;
  5809. },
  5810. };
  5811. function createBasealtarExchangeRsp(): altarExchangeRsp {
  5812. return { errno: 0, type: 0, sid: "", id: 0 };
  5813. }
  5814. export const altarExchangeRsp = {
  5815. fromJSON(object: any): altarExchangeRsp {
  5816. return {
  5817. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5818. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5819. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  5820. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  5821. };
  5822. },
  5823. toJSON(message: altarExchangeRsp): unknown {
  5824. const obj: any = {};
  5825. if (message.errno !== 0) {
  5826. obj.errno = Math.round(message.errno);
  5827. }
  5828. if (message.type !== 0) {
  5829. obj.type = Math.round(message.type);
  5830. }
  5831. if (message.sid !== "") {
  5832. obj.sid = message.sid;
  5833. }
  5834. if (message.id !== 0) {
  5835. obj.id = Math.round(message.id);
  5836. }
  5837. return obj;
  5838. },
  5839. create<I extends Exact<DeepPartial<altarExchangeRsp>, I>>(base?: I): altarExchangeRsp {
  5840. return altarExchangeRsp.fromPartial(base ?? ({} as any));
  5841. },
  5842. fromPartial<I extends Exact<DeepPartial<altarExchangeRsp>, I>>(object: I): altarExchangeRsp {
  5843. const message = createBasealtarExchangeRsp();
  5844. message.errno = object.errno ?? 0;
  5845. message.type = object.type ?? 0;
  5846. message.sid = object.sid ?? "";
  5847. message.id = object.id ?? 0;
  5848. return message;
  5849. },
  5850. };
  5851. function createBasealtarExchangeConfirm(): altarExchangeConfirm {
  5852. return { type: 0, sid: "", change: false };
  5853. }
  5854. export const altarExchangeConfirm = {
  5855. fromJSON(object: any): altarExchangeConfirm {
  5856. return {
  5857. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  5858. sid: isSet(object.sid) ? globalThis.String(object.sid) : "",
  5859. change: isSet(object.change) ? globalThis.Boolean(object.change) : false,
  5860. };
  5861. },
  5862. toJSON(message: altarExchangeConfirm): unknown {
  5863. const obj: any = {};
  5864. if (message.type !== 0) {
  5865. obj.type = Math.round(message.type);
  5866. }
  5867. if (message.sid !== "") {
  5868. obj.sid = message.sid;
  5869. }
  5870. if (message.change !== false) {
  5871. obj.change = message.change;
  5872. }
  5873. return obj;
  5874. },
  5875. create<I extends Exact<DeepPartial<altarExchangeConfirm>, I>>(base?: I): altarExchangeConfirm {
  5876. return altarExchangeConfirm.fromPartial(base ?? ({} as any));
  5877. },
  5878. fromPartial<I extends Exact<DeepPartial<altarExchangeConfirm>, I>>(object: I): altarExchangeConfirm {
  5879. const message = createBasealtarExchangeConfirm();
  5880. message.type = object.type ?? 0;
  5881. message.sid = object.sid ?? "";
  5882. message.change = object.change ?? false;
  5883. return message;
  5884. },
  5885. };
  5886. function createBasealtarExchangeConfirmRsp(): altarExchangeConfirmRsp {
  5887. return { errno: 0 };
  5888. }
  5889. export const altarExchangeConfirmRsp = {
  5890. fromJSON(object: any): altarExchangeConfirmRsp {
  5891. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  5892. },
  5893. toJSON(message: altarExchangeConfirmRsp): unknown {
  5894. const obj: any = {};
  5895. if (message.errno !== 0) {
  5896. obj.errno = Math.round(message.errno);
  5897. }
  5898. return obj;
  5899. },
  5900. create<I extends Exact<DeepPartial<altarExchangeConfirmRsp>, I>>(base?: I): altarExchangeConfirmRsp {
  5901. return altarExchangeConfirmRsp.fromPartial(base ?? ({} as any));
  5902. },
  5903. fromPartial<I extends Exact<DeepPartial<altarExchangeConfirmRsp>, I>>(object: I): altarExchangeConfirmRsp {
  5904. const message = createBasealtarExchangeConfirmRsp();
  5905. message.errno = object.errno ?? 0;
  5906. return message;
  5907. },
  5908. };
  5909. function createBasealtarBuyBattleSpace(): altarBuyBattleSpace {
  5910. return {};
  5911. }
  5912. export const altarBuyBattleSpace = {
  5913. fromJSON(_: any): altarBuyBattleSpace {
  5914. return {};
  5915. },
  5916. toJSON(_: altarBuyBattleSpace): unknown {
  5917. const obj: any = {};
  5918. return obj;
  5919. },
  5920. create<I extends Exact<DeepPartial<altarBuyBattleSpace>, I>>(base?: I): altarBuyBattleSpace {
  5921. return altarBuyBattleSpace.fromPartial(base ?? ({} as any));
  5922. },
  5923. fromPartial<I extends Exact<DeepPartial<altarBuyBattleSpace>, I>>(_: I): altarBuyBattleSpace {
  5924. const message = createBasealtarBuyBattleSpace();
  5925. return message;
  5926. },
  5927. };
  5928. function createBasealtarBuyBattleSpaceRsp(): altarBuyBattleSpaceRsp {
  5929. return { errno: 0, pos: 0, data: undefined };
  5930. }
  5931. export const altarBuyBattleSpaceRsp = {
  5932. fromJSON(object: any): altarBuyBattleSpaceRsp {
  5933. return {
  5934. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5935. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  5936. data: isSet(object.data) ? altarInfo.fromJSON(object.data) : undefined,
  5937. };
  5938. },
  5939. toJSON(message: altarBuyBattleSpaceRsp): unknown {
  5940. const obj: any = {};
  5941. if (message.errno !== 0) {
  5942. obj.errno = Math.round(message.errno);
  5943. }
  5944. if (message.pos !== 0) {
  5945. obj.pos = Math.round(message.pos);
  5946. }
  5947. if (message.data !== undefined) {
  5948. obj.data = altarInfo.toJSON(message.data);
  5949. }
  5950. return obj;
  5951. },
  5952. create<I extends Exact<DeepPartial<altarBuyBattleSpaceRsp>, I>>(base?: I): altarBuyBattleSpaceRsp {
  5953. return altarBuyBattleSpaceRsp.fromPartial(base ?? ({} as any));
  5954. },
  5955. fromPartial<I extends Exact<DeepPartial<altarBuyBattleSpaceRsp>, I>>(object: I): altarBuyBattleSpaceRsp {
  5956. const message = createBasealtarBuyBattleSpaceRsp();
  5957. message.errno = object.errno ?? 0;
  5958. message.pos = object.pos ?? 0;
  5959. message.data = (object.data !== undefined && object.data !== null) ? altarInfo.fromPartial(object.data) : undefined;
  5960. return message;
  5961. },
  5962. };
  5963. function createBasealtarResetCd(): altarResetCd {
  5964. return { pos: 0 };
  5965. }
  5966. export const altarResetCd = {
  5967. fromJSON(object: any): altarResetCd {
  5968. return { pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0 };
  5969. },
  5970. toJSON(message: altarResetCd): unknown {
  5971. const obj: any = {};
  5972. if (message.pos !== 0) {
  5973. obj.pos = Math.round(message.pos);
  5974. }
  5975. return obj;
  5976. },
  5977. create<I extends Exact<DeepPartial<altarResetCd>, I>>(base?: I): altarResetCd {
  5978. return altarResetCd.fromPartial(base ?? ({} as any));
  5979. },
  5980. fromPartial<I extends Exact<DeepPartial<altarResetCd>, I>>(object: I): altarResetCd {
  5981. const message = createBasealtarResetCd();
  5982. message.pos = object.pos ?? 0;
  5983. return message;
  5984. },
  5985. };
  5986. function createBasealtarResetCdRsp(): altarResetCdRsp {
  5987. return { errno: 0, pos: 0, data: undefined };
  5988. }
  5989. export const altarResetCdRsp = {
  5990. fromJSON(object: any): altarResetCdRsp {
  5991. return {
  5992. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  5993. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  5994. data: isSet(object.data) ? altarInfo.fromJSON(object.data) : undefined,
  5995. };
  5996. },
  5997. toJSON(message: altarResetCdRsp): unknown {
  5998. const obj: any = {};
  5999. if (message.errno !== 0) {
  6000. obj.errno = Math.round(message.errno);
  6001. }
  6002. if (message.pos !== 0) {
  6003. obj.pos = Math.round(message.pos);
  6004. }
  6005. if (message.data !== undefined) {
  6006. obj.data = altarInfo.toJSON(message.data);
  6007. }
  6008. return obj;
  6009. },
  6010. create<I extends Exact<DeepPartial<altarResetCdRsp>, I>>(base?: I): altarResetCdRsp {
  6011. return altarResetCdRsp.fromPartial(base ?? ({} as any));
  6012. },
  6013. fromPartial<I extends Exact<DeepPartial<altarResetCdRsp>, I>>(object: I): altarResetCdRsp {
  6014. const message = createBasealtarResetCdRsp();
  6015. message.errno = object.errno ?? 0;
  6016. message.pos = object.pos ?? 0;
  6017. message.data = (object.data !== undefined && object.data !== null) ? altarInfo.fromPartial(object.data) : undefined;
  6018. return message;
  6019. },
  6020. };
  6021. function createBaserelicData(): relicData {
  6022. return {};
  6023. }
  6024. export const relicData = {
  6025. fromJSON(_: any): relicData {
  6026. return {};
  6027. },
  6028. toJSON(_: relicData): unknown {
  6029. const obj: any = {};
  6030. return obj;
  6031. },
  6032. create<I extends Exact<DeepPartial<relicData>, I>>(base?: I): relicData {
  6033. return relicData.fromPartial(base ?? ({} as any));
  6034. },
  6035. fromPartial<I extends Exact<DeepPartial<relicData>, I>>(_: I): relicData {
  6036. const message = createBaserelicData();
  6037. return message;
  6038. },
  6039. };
  6040. function createBaserelicDataRsp(): relicDataRsp {
  6041. return { errno: 0 };
  6042. }
  6043. export const relicDataRsp = {
  6044. fromJSON(object: any): relicDataRsp {
  6045. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6046. },
  6047. toJSON(message: relicDataRsp): unknown {
  6048. const obj: any = {};
  6049. if (message.errno !== 0) {
  6050. obj.errno = Math.round(message.errno);
  6051. }
  6052. return obj;
  6053. },
  6054. create<I extends Exact<DeepPartial<relicDataRsp>, I>>(base?: I): relicDataRsp {
  6055. return relicDataRsp.fromPartial(base ?? ({} as any));
  6056. },
  6057. fromPartial<I extends Exact<DeepPartial<relicDataRsp>, I>>(object: I): relicDataRsp {
  6058. const message = createBaserelicDataRsp();
  6059. message.errno = object.errno ?? 0;
  6060. return message;
  6061. },
  6062. };
  6063. function createBaserelicNextPos(): relicNextPos {
  6064. return { pos: 0 };
  6065. }
  6066. export const relicNextPos = {
  6067. fromJSON(object: any): relicNextPos {
  6068. return { pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0 };
  6069. },
  6070. toJSON(message: relicNextPos): unknown {
  6071. const obj: any = {};
  6072. if (message.pos !== 0) {
  6073. obj.pos = Math.round(message.pos);
  6074. }
  6075. return obj;
  6076. },
  6077. create<I extends Exact<DeepPartial<relicNextPos>, I>>(base?: I): relicNextPos {
  6078. return relicNextPos.fromPartial(base ?? ({} as any));
  6079. },
  6080. fromPartial<I extends Exact<DeepPartial<relicNextPos>, I>>(object: I): relicNextPos {
  6081. const message = createBaserelicNextPos();
  6082. message.pos = object.pos ?? 0;
  6083. return message;
  6084. },
  6085. };
  6086. function createBaserelicNextPosRsp(): relicNextPosRsp {
  6087. return { errno: 0 };
  6088. }
  6089. export const relicNextPosRsp = {
  6090. fromJSON(object: any): relicNextPosRsp {
  6091. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6092. },
  6093. toJSON(message: relicNextPosRsp): unknown {
  6094. const obj: any = {};
  6095. if (message.errno !== 0) {
  6096. obj.errno = Math.round(message.errno);
  6097. }
  6098. return obj;
  6099. },
  6100. create<I extends Exact<DeepPartial<relicNextPosRsp>, I>>(base?: I): relicNextPosRsp {
  6101. return relicNextPosRsp.fromPartial(base ?? ({} as any));
  6102. },
  6103. fromPartial<I extends Exact<DeepPartial<relicNextPosRsp>, I>>(object: I): relicNextPosRsp {
  6104. const message = createBaserelicNextPosRsp();
  6105. message.errno = object.errno ?? 0;
  6106. return message;
  6107. },
  6108. };
  6109. function createBaserelicNextLayer(): relicNextLayer {
  6110. return {};
  6111. }
  6112. export const relicNextLayer = {
  6113. fromJSON(_: any): relicNextLayer {
  6114. return {};
  6115. },
  6116. toJSON(_: relicNextLayer): unknown {
  6117. const obj: any = {};
  6118. return obj;
  6119. },
  6120. create<I extends Exact<DeepPartial<relicNextLayer>, I>>(base?: I): relicNextLayer {
  6121. return relicNextLayer.fromPartial(base ?? ({} as any));
  6122. },
  6123. fromPartial<I extends Exact<DeepPartial<relicNextLayer>, I>>(_: I): relicNextLayer {
  6124. const message = createBaserelicNextLayer();
  6125. return message;
  6126. },
  6127. };
  6128. function createBaserelicNextLayerRsp(): relicNextLayerRsp {
  6129. return { errno: 0 };
  6130. }
  6131. export const relicNextLayerRsp = {
  6132. fromJSON(object: any): relicNextLayerRsp {
  6133. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6134. },
  6135. toJSON(message: relicNextLayerRsp): unknown {
  6136. const obj: any = {};
  6137. if (message.errno !== 0) {
  6138. obj.errno = Math.round(message.errno);
  6139. }
  6140. return obj;
  6141. },
  6142. create<I extends Exact<DeepPartial<relicNextLayerRsp>, I>>(base?: I): relicNextLayerRsp {
  6143. return relicNextLayerRsp.fromPartial(base ?? ({} as any));
  6144. },
  6145. fromPartial<I extends Exact<DeepPartial<relicNextLayerRsp>, I>>(object: I): relicNextLayerRsp {
  6146. const message = createBaserelicNextLayerRsp();
  6147. message.errno = object.errno ?? 0;
  6148. return message;
  6149. },
  6150. };
  6151. function createBaserelicSelectBuff(): relicSelectBuff {
  6152. return {};
  6153. }
  6154. export const relicSelectBuff = {
  6155. fromJSON(_: any): relicSelectBuff {
  6156. return {};
  6157. },
  6158. toJSON(_: relicSelectBuff): unknown {
  6159. const obj: any = {};
  6160. return obj;
  6161. },
  6162. create<I extends Exact<DeepPartial<relicSelectBuff>, I>>(base?: I): relicSelectBuff {
  6163. return relicSelectBuff.fromPartial(base ?? ({} as any));
  6164. },
  6165. fromPartial<I extends Exact<DeepPartial<relicSelectBuff>, I>>(_: I): relicSelectBuff {
  6166. const message = createBaserelicSelectBuff();
  6167. return message;
  6168. },
  6169. };
  6170. function createBaserelicSelectBuffRsp(): relicSelectBuffRsp {
  6171. return { errno: 0 };
  6172. }
  6173. export const relicSelectBuffRsp = {
  6174. fromJSON(object: any): relicSelectBuffRsp {
  6175. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6176. },
  6177. toJSON(message: relicSelectBuffRsp): unknown {
  6178. const obj: any = {};
  6179. if (message.errno !== 0) {
  6180. obj.errno = Math.round(message.errno);
  6181. }
  6182. return obj;
  6183. },
  6184. create<I extends Exact<DeepPartial<relicSelectBuffRsp>, I>>(base?: I): relicSelectBuffRsp {
  6185. return relicSelectBuffRsp.fromPartial(base ?? ({} as any));
  6186. },
  6187. fromPartial<I extends Exact<DeepPartial<relicSelectBuffRsp>, I>>(object: I): relicSelectBuffRsp {
  6188. const message = createBaserelicSelectBuffRsp();
  6189. message.errno = object.errno ?? 0;
  6190. return message;
  6191. },
  6192. };
  6193. function createBaserelicReset(): relicReset {
  6194. return { difficulty: 0 };
  6195. }
  6196. export const relicReset = {
  6197. fromJSON(object: any): relicReset {
  6198. return { difficulty: isSet(object.difficulty) ? globalThis.Number(object.difficulty) : 0 };
  6199. },
  6200. toJSON(message: relicReset): unknown {
  6201. const obj: any = {};
  6202. if (message.difficulty !== 0) {
  6203. obj.difficulty = Math.round(message.difficulty);
  6204. }
  6205. return obj;
  6206. },
  6207. create<I extends Exact<DeepPartial<relicReset>, I>>(base?: I): relicReset {
  6208. return relicReset.fromPartial(base ?? ({} as any));
  6209. },
  6210. fromPartial<I extends Exact<DeepPartial<relicReset>, I>>(object: I): relicReset {
  6211. const message = createBaserelicReset();
  6212. message.difficulty = object.difficulty ?? 0;
  6213. return message;
  6214. },
  6215. };
  6216. function createBaserelicResetRsp(): relicResetRsp {
  6217. return { errno: 0 };
  6218. }
  6219. export const relicResetRsp = {
  6220. fromJSON(object: any): relicResetRsp {
  6221. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6222. },
  6223. toJSON(message: relicResetRsp): unknown {
  6224. const obj: any = {};
  6225. if (message.errno !== 0) {
  6226. obj.errno = Math.round(message.errno);
  6227. }
  6228. return obj;
  6229. },
  6230. create<I extends Exact<DeepPartial<relicResetRsp>, I>>(base?: I): relicResetRsp {
  6231. return relicResetRsp.fromPartial(base ?? ({} as any));
  6232. },
  6233. fromPartial<I extends Exact<DeepPartial<relicResetRsp>, I>>(object: I): relicResetRsp {
  6234. const message = createBaserelicResetRsp();
  6235. message.errno = object.errno ?? 0;
  6236. return message;
  6237. },
  6238. };
  6239. function createBaserelicEventSelect(): relicEventSelect {
  6240. return { type: 0, win: false, cost: 0, select: 0 };
  6241. }
  6242. export const relicEventSelect = {
  6243. fromJSON(object: any): relicEventSelect {
  6244. return {
  6245. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  6246. win: isSet(object.win) ? globalThis.Boolean(object.win) : false,
  6247. cost: isSet(object.cost) ? globalThis.Number(object.cost) : 0,
  6248. select: isSet(object.select) ? globalThis.Number(object.select) : 0,
  6249. };
  6250. },
  6251. toJSON(message: relicEventSelect): unknown {
  6252. const obj: any = {};
  6253. if (message.type !== 0) {
  6254. obj.type = Math.round(message.type);
  6255. }
  6256. if (message.win !== false) {
  6257. obj.win = message.win;
  6258. }
  6259. if (message.cost !== 0) {
  6260. obj.cost = Math.round(message.cost);
  6261. }
  6262. if (message.select !== 0) {
  6263. obj.select = Math.round(message.select);
  6264. }
  6265. return obj;
  6266. },
  6267. create<I extends Exact<DeepPartial<relicEventSelect>, I>>(base?: I): relicEventSelect {
  6268. return relicEventSelect.fromPartial(base ?? ({} as any));
  6269. },
  6270. fromPartial<I extends Exact<DeepPartial<relicEventSelect>, I>>(object: I): relicEventSelect {
  6271. const message = createBaserelicEventSelect();
  6272. message.type = object.type ?? 0;
  6273. message.win = object.win ?? false;
  6274. message.cost = object.cost ?? 0;
  6275. message.select = object.select ?? 0;
  6276. return message;
  6277. },
  6278. };
  6279. function createBaserelicEventSelectRsp(): relicEventSelectRsp {
  6280. return { errno: 0 };
  6281. }
  6282. export const relicEventSelectRsp = {
  6283. fromJSON(object: any): relicEventSelectRsp {
  6284. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6285. },
  6286. toJSON(message: relicEventSelectRsp): unknown {
  6287. const obj: any = {};
  6288. if (message.errno !== 0) {
  6289. obj.errno = Math.round(message.errno);
  6290. }
  6291. return obj;
  6292. },
  6293. create<I extends Exact<DeepPartial<relicEventSelectRsp>, I>>(base?: I): relicEventSelectRsp {
  6294. return relicEventSelectRsp.fromPartial(base ?? ({} as any));
  6295. },
  6296. fromPartial<I extends Exact<DeepPartial<relicEventSelectRsp>, I>>(object: I): relicEventSelectRsp {
  6297. const message = createBaserelicEventSelectRsp();
  6298. message.errno = object.errno ?? 0;
  6299. return message;
  6300. },
  6301. };
  6302. function createBaserelicDataNty(): relicDataNty {
  6303. return {
  6304. maxDiff: 0,
  6305. curDiff: 0,
  6306. buffList: [],
  6307. layer: 0,
  6308. pos: 0,
  6309. cost: 0,
  6310. state: 0,
  6311. resetTime: 0,
  6312. posList: [],
  6313. battleInfo: [],
  6314. };
  6315. }
  6316. export const relicDataNty = {
  6317. fromJSON(object: any): relicDataNty {
  6318. return {
  6319. maxDiff: isSet(object.maxDiff) ? globalThis.Number(object.maxDiff) : 0,
  6320. curDiff: isSet(object.curDiff) ? globalThis.Number(object.curDiff) : 0,
  6321. buffList: globalThis.Array.isArray(object?.buffList) ? object.buffList.map((e: any) => globalThis.Number(e)) : [],
  6322. layer: isSet(object.layer) ? globalThis.Number(object.layer) : 0,
  6323. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  6324. cost: isSet(object.cost) ? globalThis.Number(object.cost) : 0,
  6325. state: isSet(object.state) ? globalThis.Number(object.state) : 0,
  6326. resetTime: isSet(object.resetTime) ? globalThis.Number(object.resetTime) : 0,
  6327. posList: globalThis.Array.isArray(object?.posList) ? object.posList.map((e: any) => globalThis.Number(e)) : [],
  6328. battleInfo: globalThis.Array.isArray(object?.battleInfo)
  6329. ? object.battleInfo.map((e: any) => globalThis.Number(e))
  6330. : [],
  6331. };
  6332. },
  6333. toJSON(message: relicDataNty): unknown {
  6334. const obj: any = {};
  6335. if (message.maxDiff !== 0) {
  6336. obj.maxDiff = Math.round(message.maxDiff);
  6337. }
  6338. if (message.curDiff !== 0) {
  6339. obj.curDiff = Math.round(message.curDiff);
  6340. }
  6341. if (message.buffList?.length) {
  6342. obj.buffList = message.buffList.map((e) => Math.round(e));
  6343. }
  6344. if (message.layer !== 0) {
  6345. obj.layer = Math.round(message.layer);
  6346. }
  6347. if (message.pos !== 0) {
  6348. obj.pos = Math.round(message.pos);
  6349. }
  6350. if (message.cost !== 0) {
  6351. obj.cost = Math.round(message.cost);
  6352. }
  6353. if (message.state !== 0) {
  6354. obj.state = Math.round(message.state);
  6355. }
  6356. if (message.resetTime !== 0) {
  6357. obj.resetTime = Math.round(message.resetTime);
  6358. }
  6359. if (message.posList?.length) {
  6360. obj.posList = message.posList.map((e) => Math.round(e));
  6361. }
  6362. if (message.battleInfo?.length) {
  6363. obj.battleInfo = message.battleInfo.map((e) => Math.round(e));
  6364. }
  6365. return obj;
  6366. },
  6367. create<I extends Exact<DeepPartial<relicDataNty>, I>>(base?: I): relicDataNty {
  6368. return relicDataNty.fromPartial(base ?? ({} as any));
  6369. },
  6370. fromPartial<I extends Exact<DeepPartial<relicDataNty>, I>>(object: I): relicDataNty {
  6371. const message = createBaserelicDataNty();
  6372. message.maxDiff = object.maxDiff ?? 0;
  6373. message.curDiff = object.curDiff ?? 0;
  6374. message.buffList = object.buffList?.map((e) => e) || [];
  6375. message.layer = object.layer ?? 0;
  6376. message.pos = object.pos ?? 0;
  6377. message.cost = object.cost ?? 0;
  6378. message.state = object.state ?? 0;
  6379. message.resetTime = object.resetTime ?? 0;
  6380. message.posList = object.posList?.map((e) => e) || [];
  6381. message.battleInfo = object.battleInfo?.map((e) => e) || [];
  6382. return message;
  6383. },
  6384. };
  6385. function createBaserelicEventNty(): relicEventNty {
  6386. return { type: 0, battleId: 0, battleType: 0, selectBuff: [] };
  6387. }
  6388. export const relicEventNty = {
  6389. fromJSON(object: any): relicEventNty {
  6390. return {
  6391. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  6392. battleId: isSet(object.battleId) ? globalThis.Number(object.battleId) : 0,
  6393. battleType: isSet(object.battleType) ? globalThis.Number(object.battleType) : 0,
  6394. selectBuff: globalThis.Array.isArray(object?.selectBuff)
  6395. ? object.selectBuff.map((e: any) => globalThis.Number(e))
  6396. : [],
  6397. };
  6398. },
  6399. toJSON(message: relicEventNty): unknown {
  6400. const obj: any = {};
  6401. if (message.type !== 0) {
  6402. obj.type = Math.round(message.type);
  6403. }
  6404. if (message.battleId !== 0) {
  6405. obj.battleId = Math.round(message.battleId);
  6406. }
  6407. if (message.battleType !== 0) {
  6408. obj.battleType = Math.round(message.battleType);
  6409. }
  6410. if (message.selectBuff?.length) {
  6411. obj.selectBuff = message.selectBuff.map((e) => Math.round(e));
  6412. }
  6413. return obj;
  6414. },
  6415. create<I extends Exact<DeepPartial<relicEventNty>, I>>(base?: I): relicEventNty {
  6416. return relicEventNty.fromPartial(base ?? ({} as any));
  6417. },
  6418. fromPartial<I extends Exact<DeepPartial<relicEventNty>, I>>(object: I): relicEventNty {
  6419. const message = createBaserelicEventNty();
  6420. message.type = object.type ?? 0;
  6421. message.battleId = object.battleId ?? 0;
  6422. message.battleType = object.battleType ?? 0;
  6423. message.selectBuff = object.selectBuff?.map((e) => e) || [];
  6424. return message;
  6425. },
  6426. };
  6427. function createBaseactivityTimeListNty(): activityTimeListNty {
  6428. return { list: [] };
  6429. }
  6430. export const activityTimeListNty = {
  6431. fromJSON(object: any): activityTimeListNty {
  6432. return {
  6433. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => activityTimeInfo.fromJSON(e)) : [],
  6434. };
  6435. },
  6436. toJSON(message: activityTimeListNty): unknown {
  6437. const obj: any = {};
  6438. if (message.list?.length) {
  6439. obj.list = message.list.map((e) => activityTimeInfo.toJSON(e));
  6440. }
  6441. return obj;
  6442. },
  6443. create<I extends Exact<DeepPartial<activityTimeListNty>, I>>(base?: I): activityTimeListNty {
  6444. return activityTimeListNty.fromPartial(base ?? ({} as any));
  6445. },
  6446. fromPartial<I extends Exact<DeepPartial<activityTimeListNty>, I>>(object: I): activityTimeListNty {
  6447. const message = createBaseactivityTimeListNty();
  6448. message.list = object.list?.map((e) => activityTimeInfo.fromPartial(e)) || [];
  6449. return message;
  6450. },
  6451. };
  6452. function createBaseactivityGetConfList(): activityGetConfList {
  6453. return { list: [] };
  6454. }
  6455. export const activityGetConfList = {
  6456. fromJSON(object: any): activityGetConfList {
  6457. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [] };
  6458. },
  6459. toJSON(message: activityGetConfList): unknown {
  6460. const obj: any = {};
  6461. if (message.list?.length) {
  6462. obj.list = message.list;
  6463. }
  6464. return obj;
  6465. },
  6466. create<I extends Exact<DeepPartial<activityGetConfList>, I>>(base?: I): activityGetConfList {
  6467. return activityGetConfList.fromPartial(base ?? ({} as any));
  6468. },
  6469. fromPartial<I extends Exact<DeepPartial<activityGetConfList>, I>>(object: I): activityGetConfList {
  6470. const message = createBaseactivityGetConfList();
  6471. message.list = object.list?.map((e) => e) || [];
  6472. return message;
  6473. },
  6474. };
  6475. function createBaseactivityGetConfListRsp(): activityGetConfListRsp {
  6476. return { errno: 0, list: [] };
  6477. }
  6478. export const activityGetConfListRsp = {
  6479. fromJSON(object: any): activityGetConfListRsp {
  6480. return {
  6481. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6482. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => activityConfInfo.fromJSON(e)) : [],
  6483. };
  6484. },
  6485. toJSON(message: activityGetConfListRsp): unknown {
  6486. const obj: any = {};
  6487. if (message.errno !== 0) {
  6488. obj.errno = Math.round(message.errno);
  6489. }
  6490. if (message.list?.length) {
  6491. obj.list = message.list.map((e) => activityConfInfo.toJSON(e));
  6492. }
  6493. return obj;
  6494. },
  6495. create<I extends Exact<DeepPartial<activityGetConfListRsp>, I>>(base?: I): activityGetConfListRsp {
  6496. return activityGetConfListRsp.fromPartial(base ?? ({} as any));
  6497. },
  6498. fromPartial<I extends Exact<DeepPartial<activityGetConfListRsp>, I>>(object: I): activityGetConfListRsp {
  6499. const message = createBaseactivityGetConfListRsp();
  6500. message.errno = object.errno ?? 0;
  6501. message.list = object.list?.map((e) => activityConfInfo.fromPartial(e)) || [];
  6502. return message;
  6503. },
  6504. };
  6505. function createBaseactivityGetConfNty(): activityGetConfNty {
  6506. return { list: [] };
  6507. }
  6508. export const activityGetConfNty = {
  6509. fromJSON(object: any): activityGetConfNty {
  6510. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.Number(e)) : [] };
  6511. },
  6512. toJSON(message: activityGetConfNty): unknown {
  6513. const obj: any = {};
  6514. if (message.list?.length) {
  6515. obj.list = message.list.map((e) => Math.round(e));
  6516. }
  6517. return obj;
  6518. },
  6519. create<I extends Exact<DeepPartial<activityGetConfNty>, I>>(base?: I): activityGetConfNty {
  6520. return activityGetConfNty.fromPartial(base ?? ({} as any));
  6521. },
  6522. fromPartial<I extends Exact<DeepPartial<activityGetConfNty>, I>>(object: I): activityGetConfNty {
  6523. const message = createBaseactivityGetConfNty();
  6524. message.list = object.list?.map((e) => e) || [];
  6525. return message;
  6526. },
  6527. };
  6528. function createBaseprivilegeCardData(): privilegeCardData {
  6529. return {};
  6530. }
  6531. export const privilegeCardData = {
  6532. fromJSON(_: any): privilegeCardData {
  6533. return {};
  6534. },
  6535. toJSON(_: privilegeCardData): unknown {
  6536. const obj: any = {};
  6537. return obj;
  6538. },
  6539. create<I extends Exact<DeepPartial<privilegeCardData>, I>>(base?: I): privilegeCardData {
  6540. return privilegeCardData.fromPartial(base ?? ({} as any));
  6541. },
  6542. fromPartial<I extends Exact<DeepPartial<privilegeCardData>, I>>(_: I): privilegeCardData {
  6543. const message = createBaseprivilegeCardData();
  6544. return message;
  6545. },
  6546. };
  6547. function createBaseprivilegeCardDataRsp(): privilegeCardDataRsp {
  6548. return { errno: 0, list: [] };
  6549. }
  6550. export const privilegeCardDataRsp = {
  6551. fromJSON(object: any): privilegeCardDataRsp {
  6552. return {
  6553. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6554. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => privilegeCardInfo.fromJSON(e)) : [],
  6555. };
  6556. },
  6557. toJSON(message: privilegeCardDataRsp): unknown {
  6558. const obj: any = {};
  6559. if (message.errno !== 0) {
  6560. obj.errno = Math.round(message.errno);
  6561. }
  6562. if (message.list?.length) {
  6563. obj.list = message.list.map((e) => privilegeCardInfo.toJSON(e));
  6564. }
  6565. return obj;
  6566. },
  6567. create<I extends Exact<DeepPartial<privilegeCardDataRsp>, I>>(base?: I): privilegeCardDataRsp {
  6568. return privilegeCardDataRsp.fromPartial(base ?? ({} as any));
  6569. },
  6570. fromPartial<I extends Exact<DeepPartial<privilegeCardDataRsp>, I>>(object: I): privilegeCardDataRsp {
  6571. const message = createBaseprivilegeCardDataRsp();
  6572. message.errno = object.errno ?? 0;
  6573. message.list = object.list?.map((e) => privilegeCardInfo.fromPartial(e)) || [];
  6574. return message;
  6575. },
  6576. };
  6577. function createBaseprivilegeCardBuy(): privilegeCardBuy {
  6578. return { moduleid: 0 };
  6579. }
  6580. export const privilegeCardBuy = {
  6581. fromJSON(object: any): privilegeCardBuy {
  6582. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  6583. },
  6584. toJSON(message: privilegeCardBuy): unknown {
  6585. const obj: any = {};
  6586. if (message.moduleid !== 0) {
  6587. obj.moduleid = Math.round(message.moduleid);
  6588. }
  6589. return obj;
  6590. },
  6591. create<I extends Exact<DeepPartial<privilegeCardBuy>, I>>(base?: I): privilegeCardBuy {
  6592. return privilegeCardBuy.fromPartial(base ?? ({} as any));
  6593. },
  6594. fromPartial<I extends Exact<DeepPartial<privilegeCardBuy>, I>>(object: I): privilegeCardBuy {
  6595. const message = createBaseprivilegeCardBuy();
  6596. message.moduleid = object.moduleid ?? 0;
  6597. return message;
  6598. },
  6599. };
  6600. function createBaseprivilegeCardBuyRsp(): privilegeCardBuyRsp {
  6601. return { errno: 0 };
  6602. }
  6603. export const privilegeCardBuyRsp = {
  6604. fromJSON(object: any): privilegeCardBuyRsp {
  6605. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  6606. },
  6607. toJSON(message: privilegeCardBuyRsp): unknown {
  6608. const obj: any = {};
  6609. if (message.errno !== 0) {
  6610. obj.errno = Math.round(message.errno);
  6611. }
  6612. return obj;
  6613. },
  6614. create<I extends Exact<DeepPartial<privilegeCardBuyRsp>, I>>(base?: I): privilegeCardBuyRsp {
  6615. return privilegeCardBuyRsp.fromPartial(base ?? ({} as any));
  6616. },
  6617. fromPartial<I extends Exact<DeepPartial<privilegeCardBuyRsp>, I>>(object: I): privilegeCardBuyRsp {
  6618. const message = createBaseprivilegeCardBuyRsp();
  6619. message.errno = object.errno ?? 0;
  6620. return message;
  6621. },
  6622. };
  6623. function createBaseprivilegeCardUnlockNty(): privilegeCardUnlockNty {
  6624. return { data: undefined };
  6625. }
  6626. export const privilegeCardUnlockNty = {
  6627. fromJSON(object: any): privilegeCardUnlockNty {
  6628. return { data: isSet(object.data) ? privilegeCardInfo.fromJSON(object.data) : undefined };
  6629. },
  6630. toJSON(message: privilegeCardUnlockNty): unknown {
  6631. const obj: any = {};
  6632. if (message.data !== undefined) {
  6633. obj.data = privilegeCardInfo.toJSON(message.data);
  6634. }
  6635. return obj;
  6636. },
  6637. create<I extends Exact<DeepPartial<privilegeCardUnlockNty>, I>>(base?: I): privilegeCardUnlockNty {
  6638. return privilegeCardUnlockNty.fromPartial(base ?? ({} as any));
  6639. },
  6640. fromPartial<I extends Exact<DeepPartial<privilegeCardUnlockNty>, I>>(object: I): privilegeCardUnlockNty {
  6641. const message = createBaseprivilegeCardUnlockNty();
  6642. message.data = (object.data !== undefined && object.data !== null)
  6643. ? privilegeCardInfo.fromPartial(object.data)
  6644. : undefined;
  6645. return message;
  6646. },
  6647. };
  6648. function createBaseprivilegeCardAward(): privilegeCardAward {
  6649. return { moduleid: 0 };
  6650. }
  6651. export const privilegeCardAward = {
  6652. fromJSON(object: any): privilegeCardAward {
  6653. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  6654. },
  6655. toJSON(message: privilegeCardAward): unknown {
  6656. const obj: any = {};
  6657. if (message.moduleid !== 0) {
  6658. obj.moduleid = Math.round(message.moduleid);
  6659. }
  6660. return obj;
  6661. },
  6662. create<I extends Exact<DeepPartial<privilegeCardAward>, I>>(base?: I): privilegeCardAward {
  6663. return privilegeCardAward.fromPartial(base ?? ({} as any));
  6664. },
  6665. fromPartial<I extends Exact<DeepPartial<privilegeCardAward>, I>>(object: I): privilegeCardAward {
  6666. const message = createBaseprivilegeCardAward();
  6667. message.moduleid = object.moduleid ?? 0;
  6668. return message;
  6669. },
  6670. };
  6671. function createBaseprivilegeCardAwardRsp(): privilegeCardAwardRsp {
  6672. return { errno: 0, moduleid: 0, award: false };
  6673. }
  6674. export const privilegeCardAwardRsp = {
  6675. fromJSON(object: any): privilegeCardAwardRsp {
  6676. return {
  6677. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6678. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6679. award: isSet(object.award) ? globalThis.Boolean(object.award) : false,
  6680. };
  6681. },
  6682. toJSON(message: privilegeCardAwardRsp): unknown {
  6683. const obj: any = {};
  6684. if (message.errno !== 0) {
  6685. obj.errno = Math.round(message.errno);
  6686. }
  6687. if (message.moduleid !== 0) {
  6688. obj.moduleid = Math.round(message.moduleid);
  6689. }
  6690. if (message.award !== false) {
  6691. obj.award = message.award;
  6692. }
  6693. return obj;
  6694. },
  6695. create<I extends Exact<DeepPartial<privilegeCardAwardRsp>, I>>(base?: I): privilegeCardAwardRsp {
  6696. return privilegeCardAwardRsp.fromPartial(base ?? ({} as any));
  6697. },
  6698. fromPartial<I extends Exact<DeepPartial<privilegeCardAwardRsp>, I>>(object: I): privilegeCardAwardRsp {
  6699. const message = createBaseprivilegeCardAwardRsp();
  6700. message.errno = object.errno ?? 0;
  6701. message.moduleid = object.moduleid ?? 0;
  6702. message.award = object.award ?? false;
  6703. return message;
  6704. },
  6705. };
  6706. function createBaseboxGetAward(): boxGetAward {
  6707. return { id: 0, select: 0, type: 0, num: 0 };
  6708. }
  6709. export const boxGetAward = {
  6710. fromJSON(object: any): boxGetAward {
  6711. return {
  6712. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  6713. select: isSet(object.select) ? globalThis.Number(object.select) : 0,
  6714. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  6715. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  6716. };
  6717. },
  6718. toJSON(message: boxGetAward): unknown {
  6719. const obj: any = {};
  6720. if (message.id !== 0) {
  6721. obj.id = Math.round(message.id);
  6722. }
  6723. if (message.select !== 0) {
  6724. obj.select = Math.round(message.select);
  6725. }
  6726. if (message.type !== 0) {
  6727. obj.type = Math.round(message.type);
  6728. }
  6729. if (message.num !== 0) {
  6730. obj.num = Math.round(message.num);
  6731. }
  6732. return obj;
  6733. },
  6734. create<I extends Exact<DeepPartial<boxGetAward>, I>>(base?: I): boxGetAward {
  6735. return boxGetAward.fromPartial(base ?? ({} as any));
  6736. },
  6737. fromPartial<I extends Exact<DeepPartial<boxGetAward>, I>>(object: I): boxGetAward {
  6738. const message = createBaseboxGetAward();
  6739. message.id = object.id ?? 0;
  6740. message.select = object.select ?? 0;
  6741. message.type = object.type ?? 0;
  6742. message.num = object.num ?? 0;
  6743. return message;
  6744. },
  6745. };
  6746. function createBaseboxGetAwardRsp(): boxGetAwardRsp {
  6747. return { errno: 0, type: 0 };
  6748. }
  6749. export const boxGetAwardRsp = {
  6750. fromJSON(object: any): boxGetAwardRsp {
  6751. return {
  6752. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6753. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  6754. };
  6755. },
  6756. toJSON(message: boxGetAwardRsp): unknown {
  6757. const obj: any = {};
  6758. if (message.errno !== 0) {
  6759. obj.errno = Math.round(message.errno);
  6760. }
  6761. if (message.type !== 0) {
  6762. obj.type = Math.round(message.type);
  6763. }
  6764. return obj;
  6765. },
  6766. create<I extends Exact<DeepPartial<boxGetAwardRsp>, I>>(base?: I): boxGetAwardRsp {
  6767. return boxGetAwardRsp.fromPartial(base ?? ({} as any));
  6768. },
  6769. fromPartial<I extends Exact<DeepPartial<boxGetAwardRsp>, I>>(object: I): boxGetAwardRsp {
  6770. const message = createBaseboxGetAwardRsp();
  6771. message.errno = object.errno ?? 0;
  6772. message.type = object.type ?? 0;
  6773. return message;
  6774. },
  6775. };
  6776. function createBasefirstRechargeData(): firstRechargeData {
  6777. return { moduleid: 0 };
  6778. }
  6779. export const firstRechargeData = {
  6780. fromJSON(object: any): firstRechargeData {
  6781. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  6782. },
  6783. toJSON(message: firstRechargeData): unknown {
  6784. const obj: any = {};
  6785. if (message.moduleid !== 0) {
  6786. obj.moduleid = Math.round(message.moduleid);
  6787. }
  6788. return obj;
  6789. },
  6790. create<I extends Exact<DeepPartial<firstRechargeData>, I>>(base?: I): firstRechargeData {
  6791. return firstRechargeData.fromPartial(base ?? ({} as any));
  6792. },
  6793. fromPartial<I extends Exact<DeepPartial<firstRechargeData>, I>>(object: I): firstRechargeData {
  6794. const message = createBasefirstRechargeData();
  6795. message.moduleid = object.moduleid ?? 0;
  6796. return message;
  6797. },
  6798. };
  6799. function createBasefirstRechargeDataRsp(): firstRechargeDataRsp {
  6800. return { errno: 0, moduleid: 0, state: false, day: 0, award: 0 };
  6801. }
  6802. export const firstRechargeDataRsp = {
  6803. fromJSON(object: any): firstRechargeDataRsp {
  6804. return {
  6805. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6806. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6807. state: isSet(object.state) ? globalThis.Boolean(object.state) : false,
  6808. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  6809. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  6810. };
  6811. },
  6812. toJSON(message: firstRechargeDataRsp): unknown {
  6813. const obj: any = {};
  6814. if (message.errno !== 0) {
  6815. obj.errno = Math.round(message.errno);
  6816. }
  6817. if (message.moduleid !== 0) {
  6818. obj.moduleid = Math.round(message.moduleid);
  6819. }
  6820. if (message.state !== false) {
  6821. obj.state = message.state;
  6822. }
  6823. if (message.day !== 0) {
  6824. obj.day = Math.round(message.day);
  6825. }
  6826. if (message.award !== 0) {
  6827. obj.award = Math.round(message.award);
  6828. }
  6829. return obj;
  6830. },
  6831. create<I extends Exact<DeepPartial<firstRechargeDataRsp>, I>>(base?: I): firstRechargeDataRsp {
  6832. return firstRechargeDataRsp.fromPartial(base ?? ({} as any));
  6833. },
  6834. fromPartial<I extends Exact<DeepPartial<firstRechargeDataRsp>, I>>(object: I): firstRechargeDataRsp {
  6835. const message = createBasefirstRechargeDataRsp();
  6836. message.errno = object.errno ?? 0;
  6837. message.moduleid = object.moduleid ?? 0;
  6838. message.state = object.state ?? false;
  6839. message.day = object.day ?? 0;
  6840. message.award = object.award ?? 0;
  6841. return message;
  6842. },
  6843. };
  6844. function createBasefirstRechargeBuy(): firstRechargeBuy {
  6845. return { moduleid: 0 };
  6846. }
  6847. export const firstRechargeBuy = {
  6848. fromJSON(object: any): firstRechargeBuy {
  6849. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  6850. },
  6851. toJSON(message: firstRechargeBuy): unknown {
  6852. const obj: any = {};
  6853. if (message.moduleid !== 0) {
  6854. obj.moduleid = Math.round(message.moduleid);
  6855. }
  6856. return obj;
  6857. },
  6858. create<I extends Exact<DeepPartial<firstRechargeBuy>, I>>(base?: I): firstRechargeBuy {
  6859. return firstRechargeBuy.fromPartial(base ?? ({} as any));
  6860. },
  6861. fromPartial<I extends Exact<DeepPartial<firstRechargeBuy>, I>>(object: I): firstRechargeBuy {
  6862. const message = createBasefirstRechargeBuy();
  6863. message.moduleid = object.moduleid ?? 0;
  6864. return message;
  6865. },
  6866. };
  6867. function createBasefirstRechargeBuyRsp(): firstRechargeBuyRsp {
  6868. return { errno: 0, moduleid: 0 };
  6869. }
  6870. export const firstRechargeBuyRsp = {
  6871. fromJSON(object: any): firstRechargeBuyRsp {
  6872. return {
  6873. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6874. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6875. };
  6876. },
  6877. toJSON(message: firstRechargeBuyRsp): unknown {
  6878. const obj: any = {};
  6879. if (message.errno !== 0) {
  6880. obj.errno = Math.round(message.errno);
  6881. }
  6882. if (message.moduleid !== 0) {
  6883. obj.moduleid = Math.round(message.moduleid);
  6884. }
  6885. return obj;
  6886. },
  6887. create<I extends Exact<DeepPartial<firstRechargeBuyRsp>, I>>(base?: I): firstRechargeBuyRsp {
  6888. return firstRechargeBuyRsp.fromPartial(base ?? ({} as any));
  6889. },
  6890. fromPartial<I extends Exact<DeepPartial<firstRechargeBuyRsp>, I>>(object: I): firstRechargeBuyRsp {
  6891. const message = createBasefirstRechargeBuyRsp();
  6892. message.errno = object.errno ?? 0;
  6893. message.moduleid = object.moduleid ?? 0;
  6894. return message;
  6895. },
  6896. };
  6897. function createBasefirstRechargeAward(): firstRechargeAward {
  6898. return { moduleid: 0, day: 0 };
  6899. }
  6900. export const firstRechargeAward = {
  6901. fromJSON(object: any): firstRechargeAward {
  6902. return {
  6903. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6904. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  6905. };
  6906. },
  6907. toJSON(message: firstRechargeAward): unknown {
  6908. const obj: any = {};
  6909. if (message.moduleid !== 0) {
  6910. obj.moduleid = Math.round(message.moduleid);
  6911. }
  6912. if (message.day !== 0) {
  6913. obj.day = Math.round(message.day);
  6914. }
  6915. return obj;
  6916. },
  6917. create<I extends Exact<DeepPartial<firstRechargeAward>, I>>(base?: I): firstRechargeAward {
  6918. return firstRechargeAward.fromPartial(base ?? ({} as any));
  6919. },
  6920. fromPartial<I extends Exact<DeepPartial<firstRechargeAward>, I>>(object: I): firstRechargeAward {
  6921. const message = createBasefirstRechargeAward();
  6922. message.moduleid = object.moduleid ?? 0;
  6923. message.day = object.day ?? 0;
  6924. return message;
  6925. },
  6926. };
  6927. function createBasefirstRechargeAwardRsp(): firstRechargeAwardRsp {
  6928. return { errno: 0, moduleid: 0, award: 0 };
  6929. }
  6930. export const firstRechargeAwardRsp = {
  6931. fromJSON(object: any): firstRechargeAwardRsp {
  6932. return {
  6933. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  6934. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6935. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  6936. };
  6937. },
  6938. toJSON(message: firstRechargeAwardRsp): unknown {
  6939. const obj: any = {};
  6940. if (message.errno !== 0) {
  6941. obj.errno = Math.round(message.errno);
  6942. }
  6943. if (message.moduleid !== 0) {
  6944. obj.moduleid = Math.round(message.moduleid);
  6945. }
  6946. if (message.award !== 0) {
  6947. obj.award = Math.round(message.award);
  6948. }
  6949. return obj;
  6950. },
  6951. create<I extends Exact<DeepPartial<firstRechargeAwardRsp>, I>>(base?: I): firstRechargeAwardRsp {
  6952. return firstRechargeAwardRsp.fromPartial(base ?? ({} as any));
  6953. },
  6954. fromPartial<I extends Exact<DeepPartial<firstRechargeAwardRsp>, I>>(object: I): firstRechargeAwardRsp {
  6955. const message = createBasefirstRechargeAwardRsp();
  6956. message.errno = object.errno ?? 0;
  6957. message.moduleid = object.moduleid ?? 0;
  6958. message.award = object.award ?? 0;
  6959. return message;
  6960. },
  6961. };
  6962. function createBasefirstRechargeNty(): firstRechargeNty {
  6963. return { moduleid: 0, state: false, day: 0, award: 0 };
  6964. }
  6965. export const firstRechargeNty = {
  6966. fromJSON(object: any): firstRechargeNty {
  6967. return {
  6968. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  6969. state: isSet(object.state) ? globalThis.Boolean(object.state) : false,
  6970. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  6971. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  6972. };
  6973. },
  6974. toJSON(message: firstRechargeNty): unknown {
  6975. const obj: any = {};
  6976. if (message.moduleid !== 0) {
  6977. obj.moduleid = Math.round(message.moduleid);
  6978. }
  6979. if (message.state !== false) {
  6980. obj.state = message.state;
  6981. }
  6982. if (message.day !== 0) {
  6983. obj.day = Math.round(message.day);
  6984. }
  6985. if (message.award !== 0) {
  6986. obj.award = Math.round(message.award);
  6987. }
  6988. return obj;
  6989. },
  6990. create<I extends Exact<DeepPartial<firstRechargeNty>, I>>(base?: I): firstRechargeNty {
  6991. return firstRechargeNty.fromPartial(base ?? ({} as any));
  6992. },
  6993. fromPartial<I extends Exact<DeepPartial<firstRechargeNty>, I>>(object: I): firstRechargeNty {
  6994. const message = createBasefirstRechargeNty();
  6995. message.moduleid = object.moduleid ?? 0;
  6996. message.state = object.state ?? false;
  6997. message.day = object.day ?? 0;
  6998. message.award = object.award ?? 0;
  6999. return message;
  7000. },
  7001. };
  7002. function createBasedailyDungeonsData(): dailyDungeonsData {
  7003. return {};
  7004. }
  7005. export const dailyDungeonsData = {
  7006. fromJSON(_: any): dailyDungeonsData {
  7007. return {};
  7008. },
  7009. toJSON(_: dailyDungeonsData): unknown {
  7010. const obj: any = {};
  7011. return obj;
  7012. },
  7013. create<I extends Exact<DeepPartial<dailyDungeonsData>, I>>(base?: I): dailyDungeonsData {
  7014. return dailyDungeonsData.fromPartial(base ?? ({} as any));
  7015. },
  7016. fromPartial<I extends Exact<DeepPartial<dailyDungeonsData>, I>>(_: I): dailyDungeonsData {
  7017. const message = createBasedailyDungeonsData();
  7018. return message;
  7019. },
  7020. };
  7021. function createBasedailyDungeonsDataRsp(): dailyDungeonsDataRsp {
  7022. return { errno: 0, list: [] };
  7023. }
  7024. export const dailyDungeonsDataRsp = {
  7025. fromJSON(object: any): dailyDungeonsDataRsp {
  7026. return {
  7027. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7028. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => dailyDungeonsInfo.fromJSON(e)) : [],
  7029. };
  7030. },
  7031. toJSON(message: dailyDungeonsDataRsp): unknown {
  7032. const obj: any = {};
  7033. if (message.errno !== 0) {
  7034. obj.errno = Math.round(message.errno);
  7035. }
  7036. if (message.list?.length) {
  7037. obj.list = message.list.map((e) => dailyDungeonsInfo.toJSON(e));
  7038. }
  7039. return obj;
  7040. },
  7041. create<I extends Exact<DeepPartial<dailyDungeonsDataRsp>, I>>(base?: I): dailyDungeonsDataRsp {
  7042. return dailyDungeonsDataRsp.fromPartial(base ?? ({} as any));
  7043. },
  7044. fromPartial<I extends Exact<DeepPartial<dailyDungeonsDataRsp>, I>>(object: I): dailyDungeonsDataRsp {
  7045. const message = createBasedailyDungeonsDataRsp();
  7046. message.errno = object.errno ?? 0;
  7047. message.list = object.list?.map((e) => dailyDungeonsInfo.fromPartial(e)) || [];
  7048. return message;
  7049. },
  7050. };
  7051. function createBasedailyDungeonsStart(): dailyDungeonsStart {
  7052. return { type: 0, diff: 0 };
  7053. }
  7054. export const dailyDungeonsStart = {
  7055. fromJSON(object: any): dailyDungeonsStart {
  7056. return {
  7057. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  7058. diff: isSet(object.diff) ? globalThis.Number(object.diff) : 0,
  7059. };
  7060. },
  7061. toJSON(message: dailyDungeonsStart): unknown {
  7062. const obj: any = {};
  7063. if (message.type !== 0) {
  7064. obj.type = Math.round(message.type);
  7065. }
  7066. if (message.diff !== 0) {
  7067. obj.diff = Math.round(message.diff);
  7068. }
  7069. return obj;
  7070. },
  7071. create<I extends Exact<DeepPartial<dailyDungeonsStart>, I>>(base?: I): dailyDungeonsStart {
  7072. return dailyDungeonsStart.fromPartial(base ?? ({} as any));
  7073. },
  7074. fromPartial<I extends Exact<DeepPartial<dailyDungeonsStart>, I>>(object: I): dailyDungeonsStart {
  7075. const message = createBasedailyDungeonsStart();
  7076. message.type = object.type ?? 0;
  7077. message.diff = object.diff ?? 0;
  7078. return message;
  7079. },
  7080. };
  7081. function createBasedailyDungeonsStartRsp(): dailyDungeonsStartRsp {
  7082. return { errno: 0, awardList: [] };
  7083. }
  7084. export const dailyDungeonsStartRsp = {
  7085. fromJSON(object: any): dailyDungeonsStartRsp {
  7086. return {
  7087. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7088. awardList: globalThis.Array.isArray(object?.awardList) ? object.awardList.map((e: any) => idNum.fromJSON(e)) : [],
  7089. };
  7090. },
  7091. toJSON(message: dailyDungeonsStartRsp): unknown {
  7092. const obj: any = {};
  7093. if (message.errno !== 0) {
  7094. obj.errno = Math.round(message.errno);
  7095. }
  7096. if (message.awardList?.length) {
  7097. obj.awardList = message.awardList.map((e) => idNum.toJSON(e));
  7098. }
  7099. return obj;
  7100. },
  7101. create<I extends Exact<DeepPartial<dailyDungeonsStartRsp>, I>>(base?: I): dailyDungeonsStartRsp {
  7102. return dailyDungeonsStartRsp.fromPartial(base ?? ({} as any));
  7103. },
  7104. fromPartial<I extends Exact<DeepPartial<dailyDungeonsStartRsp>, I>>(object: I): dailyDungeonsStartRsp {
  7105. const message = createBasedailyDungeonsStartRsp();
  7106. message.errno = object.errno ?? 0;
  7107. message.awardList = object.awardList?.map((e) => idNum.fromPartial(e)) || [];
  7108. return message;
  7109. },
  7110. };
  7111. function createBasedailyDungeonsEnd(): dailyDungeonsEnd {
  7112. return { win: false, monsterNum: 0, bossNum: 0, eliteNum: 0 };
  7113. }
  7114. export const dailyDungeonsEnd = {
  7115. fromJSON(object: any): dailyDungeonsEnd {
  7116. return {
  7117. win: isSet(object.win) ? globalThis.Boolean(object.win) : false,
  7118. monsterNum: isSet(object.monsterNum) ? globalThis.Number(object.monsterNum) : 0,
  7119. bossNum: isSet(object.bossNum) ? globalThis.Number(object.bossNum) : 0,
  7120. eliteNum: isSet(object.eliteNum) ? globalThis.Number(object.eliteNum) : 0,
  7121. };
  7122. },
  7123. toJSON(message: dailyDungeonsEnd): unknown {
  7124. const obj: any = {};
  7125. if (message.win !== false) {
  7126. obj.win = message.win;
  7127. }
  7128. if (message.monsterNum !== 0) {
  7129. obj.monsterNum = Math.round(message.monsterNum);
  7130. }
  7131. if (message.bossNum !== 0) {
  7132. obj.bossNum = Math.round(message.bossNum);
  7133. }
  7134. if (message.eliteNum !== 0) {
  7135. obj.eliteNum = Math.round(message.eliteNum);
  7136. }
  7137. return obj;
  7138. },
  7139. create<I extends Exact<DeepPartial<dailyDungeonsEnd>, I>>(base?: I): dailyDungeonsEnd {
  7140. return dailyDungeonsEnd.fromPartial(base ?? ({} as any));
  7141. },
  7142. fromPartial<I extends Exact<DeepPartial<dailyDungeonsEnd>, I>>(object: I): dailyDungeonsEnd {
  7143. const message = createBasedailyDungeonsEnd();
  7144. message.win = object.win ?? false;
  7145. message.monsterNum = object.monsterNum ?? 0;
  7146. message.bossNum = object.bossNum ?? 0;
  7147. message.eliteNum = object.eliteNum ?? 0;
  7148. return message;
  7149. },
  7150. };
  7151. function createBasedailyDungeonsEndRsp(): dailyDungeonsEndRsp {
  7152. return { errno: 0, data: undefined };
  7153. }
  7154. export const dailyDungeonsEndRsp = {
  7155. fromJSON(object: any): dailyDungeonsEndRsp {
  7156. return {
  7157. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7158. data: isSet(object.data) ? dailyDungeonsInfo.fromJSON(object.data) : undefined,
  7159. };
  7160. },
  7161. toJSON(message: dailyDungeonsEndRsp): unknown {
  7162. const obj: any = {};
  7163. if (message.errno !== 0) {
  7164. obj.errno = Math.round(message.errno);
  7165. }
  7166. if (message.data !== undefined) {
  7167. obj.data = dailyDungeonsInfo.toJSON(message.data);
  7168. }
  7169. return obj;
  7170. },
  7171. create<I extends Exact<DeepPartial<dailyDungeonsEndRsp>, I>>(base?: I): dailyDungeonsEndRsp {
  7172. return dailyDungeonsEndRsp.fromPartial(base ?? ({} as any));
  7173. },
  7174. fromPartial<I extends Exact<DeepPartial<dailyDungeonsEndRsp>, I>>(object: I): dailyDungeonsEndRsp {
  7175. const message = createBasedailyDungeonsEndRsp();
  7176. message.errno = object.errno ?? 0;
  7177. message.data = (object.data !== undefined && object.data !== null)
  7178. ? dailyDungeonsInfo.fromPartial(object.data)
  7179. : undefined;
  7180. return message;
  7181. },
  7182. };
  7183. function createBasedailyDungeonsSweep(): dailyDungeonsSweep {
  7184. return { type: 0, diff: 0 };
  7185. }
  7186. export const dailyDungeonsSweep = {
  7187. fromJSON(object: any): dailyDungeonsSweep {
  7188. return {
  7189. type: isSet(object.type) ? globalThis.Number(object.type) : 0,
  7190. diff: isSet(object.diff) ? globalThis.Number(object.diff) : 0,
  7191. };
  7192. },
  7193. toJSON(message: dailyDungeonsSweep): unknown {
  7194. const obj: any = {};
  7195. if (message.type !== 0) {
  7196. obj.type = Math.round(message.type);
  7197. }
  7198. if (message.diff !== 0) {
  7199. obj.diff = Math.round(message.diff);
  7200. }
  7201. return obj;
  7202. },
  7203. create<I extends Exact<DeepPartial<dailyDungeonsSweep>, I>>(base?: I): dailyDungeonsSweep {
  7204. return dailyDungeonsSweep.fromPartial(base ?? ({} as any));
  7205. },
  7206. fromPartial<I extends Exact<DeepPartial<dailyDungeonsSweep>, I>>(object: I): dailyDungeonsSweep {
  7207. const message = createBasedailyDungeonsSweep();
  7208. message.type = object.type ?? 0;
  7209. message.diff = object.diff ?? 0;
  7210. return message;
  7211. },
  7212. };
  7213. function createBasedailyDungeonsSweepRsp(): dailyDungeonsSweepRsp {
  7214. return { errno: 0, data: undefined };
  7215. }
  7216. export const dailyDungeonsSweepRsp = {
  7217. fromJSON(object: any): dailyDungeonsSweepRsp {
  7218. return {
  7219. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7220. data: isSet(object.data) ? dailyDungeonsInfo.fromJSON(object.data) : undefined,
  7221. };
  7222. },
  7223. toJSON(message: dailyDungeonsSweepRsp): unknown {
  7224. const obj: any = {};
  7225. if (message.errno !== 0) {
  7226. obj.errno = Math.round(message.errno);
  7227. }
  7228. if (message.data !== undefined) {
  7229. obj.data = dailyDungeonsInfo.toJSON(message.data);
  7230. }
  7231. return obj;
  7232. },
  7233. create<I extends Exact<DeepPartial<dailyDungeonsSweepRsp>, I>>(base?: I): dailyDungeonsSweepRsp {
  7234. return dailyDungeonsSweepRsp.fromPartial(base ?? ({} as any));
  7235. },
  7236. fromPartial<I extends Exact<DeepPartial<dailyDungeonsSweepRsp>, I>>(object: I): dailyDungeonsSweepRsp {
  7237. const message = createBasedailyDungeonsSweepRsp();
  7238. message.errno = object.errno ?? 0;
  7239. message.data = (object.data !== undefined && object.data !== null)
  7240. ? dailyDungeonsInfo.fromPartial(object.data)
  7241. : undefined;
  7242. return message;
  7243. },
  7244. };
  7245. function createBaseadvGiftData(): advGiftData {
  7246. return {};
  7247. }
  7248. export const advGiftData = {
  7249. fromJSON(_: any): advGiftData {
  7250. return {};
  7251. },
  7252. toJSON(_: advGiftData): unknown {
  7253. const obj: any = {};
  7254. return obj;
  7255. },
  7256. create<I extends Exact<DeepPartial<advGiftData>, I>>(base?: I): advGiftData {
  7257. return advGiftData.fromPartial(base ?? ({} as any));
  7258. },
  7259. fromPartial<I extends Exact<DeepPartial<advGiftData>, I>>(_: I): advGiftData {
  7260. const message = createBaseadvGiftData();
  7261. return message;
  7262. },
  7263. };
  7264. function createBaseadvGiftDataRsp(): advGiftDataRsp {
  7265. return { errno: 0 };
  7266. }
  7267. export const advGiftDataRsp = {
  7268. fromJSON(object: any): advGiftDataRsp {
  7269. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  7270. },
  7271. toJSON(message: advGiftDataRsp): unknown {
  7272. const obj: any = {};
  7273. if (message.errno !== 0) {
  7274. obj.errno = Math.round(message.errno);
  7275. }
  7276. return obj;
  7277. },
  7278. create<I extends Exact<DeepPartial<advGiftDataRsp>, I>>(base?: I): advGiftDataRsp {
  7279. return advGiftDataRsp.fromPartial(base ?? ({} as any));
  7280. },
  7281. fromPartial<I extends Exact<DeepPartial<advGiftDataRsp>, I>>(object: I): advGiftDataRsp {
  7282. const message = createBaseadvGiftDataRsp();
  7283. message.errno = object.errno ?? 0;
  7284. return message;
  7285. },
  7286. };
  7287. function createBaseadvGiftBuy(): advGiftBuy {
  7288. return { id: 0 };
  7289. }
  7290. export const advGiftBuy = {
  7291. fromJSON(object: any): advGiftBuy {
  7292. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  7293. },
  7294. toJSON(message: advGiftBuy): unknown {
  7295. const obj: any = {};
  7296. if (message.id !== 0) {
  7297. obj.id = Math.round(message.id);
  7298. }
  7299. return obj;
  7300. },
  7301. create<I extends Exact<DeepPartial<advGiftBuy>, I>>(base?: I): advGiftBuy {
  7302. return advGiftBuy.fromPartial(base ?? ({} as any));
  7303. },
  7304. fromPartial<I extends Exact<DeepPartial<advGiftBuy>, I>>(object: I): advGiftBuy {
  7305. const message = createBaseadvGiftBuy();
  7306. message.id = object.id ?? 0;
  7307. return message;
  7308. },
  7309. };
  7310. function createBaseadvGiftBuyRsp(): advGiftBuyRsp {
  7311. return { errno: 0 };
  7312. }
  7313. export const advGiftBuyRsp = {
  7314. fromJSON(object: any): advGiftBuyRsp {
  7315. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  7316. },
  7317. toJSON(message: advGiftBuyRsp): unknown {
  7318. const obj: any = {};
  7319. if (message.errno !== 0) {
  7320. obj.errno = Math.round(message.errno);
  7321. }
  7322. return obj;
  7323. },
  7324. create<I extends Exact<DeepPartial<advGiftBuyRsp>, I>>(base?: I): advGiftBuyRsp {
  7325. return advGiftBuyRsp.fromPartial(base ?? ({} as any));
  7326. },
  7327. fromPartial<I extends Exact<DeepPartial<advGiftBuyRsp>, I>>(object: I): advGiftBuyRsp {
  7328. const message = createBaseadvGiftBuyRsp();
  7329. message.errno = object.errno ?? 0;
  7330. return message;
  7331. },
  7332. };
  7333. function createBaseadvGiftNty(): advGiftNty {
  7334. return { list: [] };
  7335. }
  7336. export const advGiftNty = {
  7337. fromJSON(object: any): advGiftNty {
  7338. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => idNum.fromJSON(e)) : [] };
  7339. },
  7340. toJSON(message: advGiftNty): unknown {
  7341. const obj: any = {};
  7342. if (message.list?.length) {
  7343. obj.list = message.list.map((e) => idNum.toJSON(e));
  7344. }
  7345. return obj;
  7346. },
  7347. create<I extends Exact<DeepPartial<advGiftNty>, I>>(base?: I): advGiftNty {
  7348. return advGiftNty.fromPartial(base ?? ({} as any));
  7349. },
  7350. fromPartial<I extends Exact<DeepPartial<advGiftNty>, I>>(object: I): advGiftNty {
  7351. const message = createBaseadvGiftNty();
  7352. message.list = object.list?.map((e) => idNum.fromPartial(e)) || [];
  7353. return message;
  7354. },
  7355. };
  7356. function createBasepopGiftData(): popGiftData {
  7357. return {};
  7358. }
  7359. export const popGiftData = {
  7360. fromJSON(_: any): popGiftData {
  7361. return {};
  7362. },
  7363. toJSON(_: popGiftData): unknown {
  7364. const obj: any = {};
  7365. return obj;
  7366. },
  7367. create<I extends Exact<DeepPartial<popGiftData>, I>>(base?: I): popGiftData {
  7368. return popGiftData.fromPartial(base ?? ({} as any));
  7369. },
  7370. fromPartial<I extends Exact<DeepPartial<popGiftData>, I>>(_: I): popGiftData {
  7371. const message = createBasepopGiftData();
  7372. return message;
  7373. },
  7374. };
  7375. function createBasepopGiftDataRsp(): popGiftDataRsp {
  7376. return { errno: 0, list: [] };
  7377. }
  7378. export const popGiftDataRsp = {
  7379. fromJSON(object: any): popGiftDataRsp {
  7380. return {
  7381. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7382. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => popGiftInfo.fromJSON(e)) : [],
  7383. };
  7384. },
  7385. toJSON(message: popGiftDataRsp): unknown {
  7386. const obj: any = {};
  7387. if (message.errno !== 0) {
  7388. obj.errno = Math.round(message.errno);
  7389. }
  7390. if (message.list?.length) {
  7391. obj.list = message.list.map((e) => popGiftInfo.toJSON(e));
  7392. }
  7393. return obj;
  7394. },
  7395. create<I extends Exact<DeepPartial<popGiftDataRsp>, I>>(base?: I): popGiftDataRsp {
  7396. return popGiftDataRsp.fromPartial(base ?? ({} as any));
  7397. },
  7398. fromPartial<I extends Exact<DeepPartial<popGiftDataRsp>, I>>(object: I): popGiftDataRsp {
  7399. const message = createBasepopGiftDataRsp();
  7400. message.errno = object.errno ?? 0;
  7401. message.list = object.list?.map((e) => popGiftInfo.fromPartial(e)) || [];
  7402. return message;
  7403. },
  7404. };
  7405. function createBasepopGiftBuy(): popGiftBuy {
  7406. return { id: 0 };
  7407. }
  7408. export const popGiftBuy = {
  7409. fromJSON(object: any): popGiftBuy {
  7410. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  7411. },
  7412. toJSON(message: popGiftBuy): unknown {
  7413. const obj: any = {};
  7414. if (message.id !== 0) {
  7415. obj.id = Math.round(message.id);
  7416. }
  7417. return obj;
  7418. },
  7419. create<I extends Exact<DeepPartial<popGiftBuy>, I>>(base?: I): popGiftBuy {
  7420. return popGiftBuy.fromPartial(base ?? ({} as any));
  7421. },
  7422. fromPartial<I extends Exact<DeepPartial<popGiftBuy>, I>>(object: I): popGiftBuy {
  7423. const message = createBasepopGiftBuy();
  7424. message.id = object.id ?? 0;
  7425. return message;
  7426. },
  7427. };
  7428. function createBasepopGiftBuyRsp(): popGiftBuyRsp {
  7429. return { errno: 0 };
  7430. }
  7431. export const popGiftBuyRsp = {
  7432. fromJSON(object: any): popGiftBuyRsp {
  7433. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  7434. },
  7435. toJSON(message: popGiftBuyRsp): unknown {
  7436. const obj: any = {};
  7437. if (message.errno !== 0) {
  7438. obj.errno = Math.round(message.errno);
  7439. }
  7440. return obj;
  7441. },
  7442. create<I extends Exact<DeepPartial<popGiftBuyRsp>, I>>(base?: I): popGiftBuyRsp {
  7443. return popGiftBuyRsp.fromPartial(base ?? ({} as any));
  7444. },
  7445. fromPartial<I extends Exact<DeepPartial<popGiftBuyRsp>, I>>(object: I): popGiftBuyRsp {
  7446. const message = createBasepopGiftBuyRsp();
  7447. message.errno = object.errno ?? 0;
  7448. return message;
  7449. },
  7450. };
  7451. function createBasepopGiftNty(): popGiftNty {
  7452. return { data: undefined };
  7453. }
  7454. export const popGiftNty = {
  7455. fromJSON(object: any): popGiftNty {
  7456. return { data: isSet(object.data) ? popGiftInfo.fromJSON(object.data) : undefined };
  7457. },
  7458. toJSON(message: popGiftNty): unknown {
  7459. const obj: any = {};
  7460. if (message.data !== undefined) {
  7461. obj.data = popGiftInfo.toJSON(message.data);
  7462. }
  7463. return obj;
  7464. },
  7465. create<I extends Exact<DeepPartial<popGiftNty>, I>>(base?: I): popGiftNty {
  7466. return popGiftNty.fromPartial(base ?? ({} as any));
  7467. },
  7468. fromPartial<I extends Exact<DeepPartial<popGiftNty>, I>>(object: I): popGiftNty {
  7469. const message = createBasepopGiftNty();
  7470. message.data = (object.data !== undefined && object.data !== null)
  7471. ? popGiftInfo.fromPartial(object.data)
  7472. : undefined;
  7473. return message;
  7474. },
  7475. };
  7476. function createBasepopGiftChangeNty(): popGiftChangeNty {
  7477. return { data: undefined };
  7478. }
  7479. export const popGiftChangeNty = {
  7480. fromJSON(object: any): popGiftChangeNty {
  7481. return { data: isSet(object.data) ? popGiftInfo.fromJSON(object.data) : undefined };
  7482. },
  7483. toJSON(message: popGiftChangeNty): unknown {
  7484. const obj: any = {};
  7485. if (message.data !== undefined) {
  7486. obj.data = popGiftInfo.toJSON(message.data);
  7487. }
  7488. return obj;
  7489. },
  7490. create<I extends Exact<DeepPartial<popGiftChangeNty>, I>>(base?: I): popGiftChangeNty {
  7491. return popGiftChangeNty.fromPartial(base ?? ({} as any));
  7492. },
  7493. fromPartial<I extends Exact<DeepPartial<popGiftChangeNty>, I>>(object: I): popGiftChangeNty {
  7494. const message = createBasepopGiftChangeNty();
  7495. message.data = (object.data !== undefined && object.data !== null)
  7496. ? popGiftInfo.fromPartial(object.data)
  7497. : undefined;
  7498. return message;
  7499. },
  7500. };
  7501. function createBasefundData(): fundData {
  7502. return { moduleid: 0 };
  7503. }
  7504. export const fundData = {
  7505. fromJSON(object: any): fundData {
  7506. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  7507. },
  7508. toJSON(message: fundData): unknown {
  7509. const obj: any = {};
  7510. if (message.moduleid !== 0) {
  7511. obj.moduleid = Math.round(message.moduleid);
  7512. }
  7513. return obj;
  7514. },
  7515. create<I extends Exact<DeepPartial<fundData>, I>>(base?: I): fundData {
  7516. return fundData.fromPartial(base ?? ({} as any));
  7517. },
  7518. fromPartial<I extends Exact<DeepPartial<fundData>, I>>(object: I): fundData {
  7519. const message = createBasefundData();
  7520. message.moduleid = object.moduleid ?? 0;
  7521. return message;
  7522. },
  7523. };
  7524. function createBasefundDataRsp(): fundDataRsp {
  7525. return { errno: 0, moduleid: 0, state: false, award: 0, freeAward: 0, progress: 0 };
  7526. }
  7527. export const fundDataRsp = {
  7528. fromJSON(object: any): fundDataRsp {
  7529. return {
  7530. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7531. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  7532. state: isSet(object.state) ? globalThis.Boolean(object.state) : false,
  7533. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7534. freeAward: isSet(object.freeAward) ? globalThis.Number(object.freeAward) : 0,
  7535. progress: isSet(object.progress) ? globalThis.Number(object.progress) : 0,
  7536. };
  7537. },
  7538. toJSON(message: fundDataRsp): unknown {
  7539. const obj: any = {};
  7540. if (message.errno !== 0) {
  7541. obj.errno = Math.round(message.errno);
  7542. }
  7543. if (message.moduleid !== 0) {
  7544. obj.moduleid = Math.round(message.moduleid);
  7545. }
  7546. if (message.state !== false) {
  7547. obj.state = message.state;
  7548. }
  7549. if (message.award !== 0) {
  7550. obj.award = Math.round(message.award);
  7551. }
  7552. if (message.freeAward !== 0) {
  7553. obj.freeAward = Math.round(message.freeAward);
  7554. }
  7555. if (message.progress !== 0) {
  7556. obj.progress = Math.round(message.progress);
  7557. }
  7558. return obj;
  7559. },
  7560. create<I extends Exact<DeepPartial<fundDataRsp>, I>>(base?: I): fundDataRsp {
  7561. return fundDataRsp.fromPartial(base ?? ({} as any));
  7562. },
  7563. fromPartial<I extends Exact<DeepPartial<fundDataRsp>, I>>(object: I): fundDataRsp {
  7564. const message = createBasefundDataRsp();
  7565. message.errno = object.errno ?? 0;
  7566. message.moduleid = object.moduleid ?? 0;
  7567. message.state = object.state ?? false;
  7568. message.award = object.award ?? 0;
  7569. message.freeAward = object.freeAward ?? 0;
  7570. message.progress = object.progress ?? 0;
  7571. return message;
  7572. },
  7573. };
  7574. function createBasefundBuy(): fundBuy {
  7575. return { moduleid: 0 };
  7576. }
  7577. export const fundBuy = {
  7578. fromJSON(object: any): fundBuy {
  7579. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  7580. },
  7581. toJSON(message: fundBuy): unknown {
  7582. const obj: any = {};
  7583. if (message.moduleid !== 0) {
  7584. obj.moduleid = Math.round(message.moduleid);
  7585. }
  7586. return obj;
  7587. },
  7588. create<I extends Exact<DeepPartial<fundBuy>, I>>(base?: I): fundBuy {
  7589. return fundBuy.fromPartial(base ?? ({} as any));
  7590. },
  7591. fromPartial<I extends Exact<DeepPartial<fundBuy>, I>>(object: I): fundBuy {
  7592. const message = createBasefundBuy();
  7593. message.moduleid = object.moduleid ?? 0;
  7594. return message;
  7595. },
  7596. };
  7597. function createBasefundBuyRsp(): fundBuyRsp {
  7598. return { errno: 0, moduleid: 0 };
  7599. }
  7600. export const fundBuyRsp = {
  7601. fromJSON(object: any): fundBuyRsp {
  7602. return {
  7603. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7604. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  7605. };
  7606. },
  7607. toJSON(message: fundBuyRsp): unknown {
  7608. const obj: any = {};
  7609. if (message.errno !== 0) {
  7610. obj.errno = Math.round(message.errno);
  7611. }
  7612. if (message.moduleid !== 0) {
  7613. obj.moduleid = Math.round(message.moduleid);
  7614. }
  7615. return obj;
  7616. },
  7617. create<I extends Exact<DeepPartial<fundBuyRsp>, I>>(base?: I): fundBuyRsp {
  7618. return fundBuyRsp.fromPartial(base ?? ({} as any));
  7619. },
  7620. fromPartial<I extends Exact<DeepPartial<fundBuyRsp>, I>>(object: I): fundBuyRsp {
  7621. const message = createBasefundBuyRsp();
  7622. message.errno = object.errno ?? 0;
  7623. message.moduleid = object.moduleid ?? 0;
  7624. return message;
  7625. },
  7626. };
  7627. function createBasefundAward(): fundAward {
  7628. return { moduleid: 0 };
  7629. }
  7630. export const fundAward = {
  7631. fromJSON(object: any): fundAward {
  7632. return { moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0 };
  7633. },
  7634. toJSON(message: fundAward): unknown {
  7635. const obj: any = {};
  7636. if (message.moduleid !== 0) {
  7637. obj.moduleid = Math.round(message.moduleid);
  7638. }
  7639. return obj;
  7640. },
  7641. create<I extends Exact<DeepPartial<fundAward>, I>>(base?: I): fundAward {
  7642. return fundAward.fromPartial(base ?? ({} as any));
  7643. },
  7644. fromPartial<I extends Exact<DeepPartial<fundAward>, I>>(object: I): fundAward {
  7645. const message = createBasefundAward();
  7646. message.moduleid = object.moduleid ?? 0;
  7647. return message;
  7648. },
  7649. };
  7650. function createBasefundAwardRsp(): fundAwardRsp {
  7651. return { errno: 0, moduleid: 0, award: 0, freeAward: 0 };
  7652. }
  7653. export const fundAwardRsp = {
  7654. fromJSON(object: any): fundAwardRsp {
  7655. return {
  7656. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7657. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  7658. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7659. freeAward: isSet(object.freeAward) ? globalThis.Number(object.freeAward) : 0,
  7660. };
  7661. },
  7662. toJSON(message: fundAwardRsp): unknown {
  7663. const obj: any = {};
  7664. if (message.errno !== 0) {
  7665. obj.errno = Math.round(message.errno);
  7666. }
  7667. if (message.moduleid !== 0) {
  7668. obj.moduleid = Math.round(message.moduleid);
  7669. }
  7670. if (message.award !== 0) {
  7671. obj.award = Math.round(message.award);
  7672. }
  7673. if (message.freeAward !== 0) {
  7674. obj.freeAward = Math.round(message.freeAward);
  7675. }
  7676. return obj;
  7677. },
  7678. create<I extends Exact<DeepPartial<fundAwardRsp>, I>>(base?: I): fundAwardRsp {
  7679. return fundAwardRsp.fromPartial(base ?? ({} as any));
  7680. },
  7681. fromPartial<I extends Exact<DeepPartial<fundAwardRsp>, I>>(object: I): fundAwardRsp {
  7682. const message = createBasefundAwardRsp();
  7683. message.errno = object.errno ?? 0;
  7684. message.moduleid = object.moduleid ?? 0;
  7685. message.award = object.award ?? 0;
  7686. message.freeAward = object.freeAward ?? 0;
  7687. return message;
  7688. },
  7689. };
  7690. function createBasefundNty(): fundNty {
  7691. return { moduleid: 0, state: false, award: 0, freeAward: 0, progress: 0 };
  7692. }
  7693. export const fundNty = {
  7694. fromJSON(object: any): fundNty {
  7695. return {
  7696. moduleid: isSet(object.moduleid) ? globalThis.Number(object.moduleid) : 0,
  7697. state: isSet(object.state) ? globalThis.Boolean(object.state) : false,
  7698. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7699. freeAward: isSet(object.freeAward) ? globalThis.Number(object.freeAward) : 0,
  7700. progress: isSet(object.progress) ? globalThis.Number(object.progress) : 0,
  7701. };
  7702. },
  7703. toJSON(message: fundNty): unknown {
  7704. const obj: any = {};
  7705. if (message.moduleid !== 0) {
  7706. obj.moduleid = Math.round(message.moduleid);
  7707. }
  7708. if (message.state !== false) {
  7709. obj.state = message.state;
  7710. }
  7711. if (message.award !== 0) {
  7712. obj.award = Math.round(message.award);
  7713. }
  7714. if (message.freeAward !== 0) {
  7715. obj.freeAward = Math.round(message.freeAward);
  7716. }
  7717. if (message.progress !== 0) {
  7718. obj.progress = Math.round(message.progress);
  7719. }
  7720. return obj;
  7721. },
  7722. create<I extends Exact<DeepPartial<fundNty>, I>>(base?: I): fundNty {
  7723. return fundNty.fromPartial(base ?? ({} as any));
  7724. },
  7725. fromPartial<I extends Exact<DeepPartial<fundNty>, I>>(object: I): fundNty {
  7726. const message = createBasefundNty();
  7727. message.moduleid = object.moduleid ?? 0;
  7728. message.state = object.state ?? false;
  7729. message.award = object.award ?? 0;
  7730. message.freeAward = object.freeAward ?? 0;
  7731. message.progress = object.progress ?? 0;
  7732. return message;
  7733. },
  7734. };
  7735. function createBasekeepRechargeData(): keepRechargeData {
  7736. return {};
  7737. }
  7738. export const keepRechargeData = {
  7739. fromJSON(_: any): keepRechargeData {
  7740. return {};
  7741. },
  7742. toJSON(_: keepRechargeData): unknown {
  7743. const obj: any = {};
  7744. return obj;
  7745. },
  7746. create<I extends Exact<DeepPartial<keepRechargeData>, I>>(base?: I): keepRechargeData {
  7747. return keepRechargeData.fromPartial(base ?? ({} as any));
  7748. },
  7749. fromPartial<I extends Exact<DeepPartial<keepRechargeData>, I>>(_: I): keepRechargeData {
  7750. const message = createBasekeepRechargeData();
  7751. return message;
  7752. },
  7753. };
  7754. function createBasekeepRechargeDataRsp(): keepRechargeDataRsp {
  7755. return { errno: 0, day: 0, num: 0, award: 0 };
  7756. }
  7757. export const keepRechargeDataRsp = {
  7758. fromJSON(object: any): keepRechargeDataRsp {
  7759. return {
  7760. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7761. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  7762. num: isSet(object.num) ? globalThis.Number(object.num) : 0,
  7763. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7764. };
  7765. },
  7766. toJSON(message: keepRechargeDataRsp): unknown {
  7767. const obj: any = {};
  7768. if (message.errno !== 0) {
  7769. obj.errno = Math.round(message.errno);
  7770. }
  7771. if (message.day !== 0) {
  7772. obj.day = Math.round(message.day);
  7773. }
  7774. if (message.num !== 0) {
  7775. obj.num = Math.round(message.num);
  7776. }
  7777. if (message.award !== 0) {
  7778. obj.award = Math.round(message.award);
  7779. }
  7780. return obj;
  7781. },
  7782. create<I extends Exact<DeepPartial<keepRechargeDataRsp>, I>>(base?: I): keepRechargeDataRsp {
  7783. return keepRechargeDataRsp.fromPartial(base ?? ({} as any));
  7784. },
  7785. fromPartial<I extends Exact<DeepPartial<keepRechargeDataRsp>, I>>(object: I): keepRechargeDataRsp {
  7786. const message = createBasekeepRechargeDataRsp();
  7787. message.errno = object.errno ?? 0;
  7788. message.day = object.day ?? 0;
  7789. message.num = object.num ?? 0;
  7790. message.award = object.award ?? 0;
  7791. return message;
  7792. },
  7793. };
  7794. function createBasekeepRechargeAward(): keepRechargeAward {
  7795. return { day: 0 };
  7796. }
  7797. export const keepRechargeAward = {
  7798. fromJSON(object: any): keepRechargeAward {
  7799. return { day: isSet(object.day) ? globalThis.Number(object.day) : 0 };
  7800. },
  7801. toJSON(message: keepRechargeAward): unknown {
  7802. const obj: any = {};
  7803. if (message.day !== 0) {
  7804. obj.day = Math.round(message.day);
  7805. }
  7806. return obj;
  7807. },
  7808. create<I extends Exact<DeepPartial<keepRechargeAward>, I>>(base?: I): keepRechargeAward {
  7809. return keepRechargeAward.fromPartial(base ?? ({} as any));
  7810. },
  7811. fromPartial<I extends Exact<DeepPartial<keepRechargeAward>, I>>(object: I): keepRechargeAward {
  7812. const message = createBasekeepRechargeAward();
  7813. message.day = object.day ?? 0;
  7814. return message;
  7815. },
  7816. };
  7817. function createBasekeepRechargeAwardRsp(): keepRechargeAwardRsp {
  7818. return { errno: 0, award: 0 };
  7819. }
  7820. export const keepRechargeAwardRsp = {
  7821. fromJSON(object: any): keepRechargeAwardRsp {
  7822. return {
  7823. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7824. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7825. };
  7826. },
  7827. toJSON(message: keepRechargeAwardRsp): unknown {
  7828. const obj: any = {};
  7829. if (message.errno !== 0) {
  7830. obj.errno = Math.round(message.errno);
  7831. }
  7832. if (message.award !== 0) {
  7833. obj.award = Math.round(message.award);
  7834. }
  7835. return obj;
  7836. },
  7837. create<I extends Exact<DeepPartial<keepRechargeAwardRsp>, I>>(base?: I): keepRechargeAwardRsp {
  7838. return keepRechargeAwardRsp.fromPartial(base ?? ({} as any));
  7839. },
  7840. fromPartial<I extends Exact<DeepPartial<keepRechargeAwardRsp>, I>>(object: I): keepRechargeAwardRsp {
  7841. const message = createBasekeepRechargeAwardRsp();
  7842. message.errno = object.errno ?? 0;
  7843. message.award = object.award ?? 0;
  7844. return message;
  7845. },
  7846. };
  7847. function createBasegetRedPointList(): getRedPointList {
  7848. return {};
  7849. }
  7850. export const getRedPointList = {
  7851. fromJSON(_: any): getRedPointList {
  7852. return {};
  7853. },
  7854. toJSON(_: getRedPointList): unknown {
  7855. const obj: any = {};
  7856. return obj;
  7857. },
  7858. create<I extends Exact<DeepPartial<getRedPointList>, I>>(base?: I): getRedPointList {
  7859. return getRedPointList.fromPartial(base ?? ({} as any));
  7860. },
  7861. fromPartial<I extends Exact<DeepPartial<getRedPointList>, I>>(_: I): getRedPointList {
  7862. const message = createBasegetRedPointList();
  7863. return message;
  7864. },
  7865. };
  7866. function createBasegetRedPointListRsp(): getRedPointListRsp {
  7867. return { errno: 0, list: [] };
  7868. }
  7869. export const getRedPointListRsp = {
  7870. fromJSON(object: any): getRedPointListRsp {
  7871. return {
  7872. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7873. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => redPointInfo.fromJSON(e)) : [],
  7874. };
  7875. },
  7876. toJSON(message: getRedPointListRsp): unknown {
  7877. const obj: any = {};
  7878. if (message.errno !== 0) {
  7879. obj.errno = Math.round(message.errno);
  7880. }
  7881. if (message.list?.length) {
  7882. obj.list = message.list.map((e) => redPointInfo.toJSON(e));
  7883. }
  7884. return obj;
  7885. },
  7886. create<I extends Exact<DeepPartial<getRedPointListRsp>, I>>(base?: I): getRedPointListRsp {
  7887. return getRedPointListRsp.fromPartial(base ?? ({} as any));
  7888. },
  7889. fromPartial<I extends Exact<DeepPartial<getRedPointListRsp>, I>>(object: I): getRedPointListRsp {
  7890. const message = createBasegetRedPointListRsp();
  7891. message.errno = object.errno ?? 0;
  7892. message.list = object.list?.map((e) => redPointInfo.fromPartial(e)) || [];
  7893. return message;
  7894. },
  7895. };
  7896. function createBaserechargeResult(): rechargeResult {
  7897. return { orderId: "", payOrderId: "", purchaseToken: "", payType: "", cfgId: 0 };
  7898. }
  7899. export const rechargeResult = {
  7900. fromJSON(object: any): rechargeResult {
  7901. return {
  7902. orderId: isSet(object.orderId) ? globalThis.String(object.orderId) : "",
  7903. payOrderId: isSet(object.payOrderId) ? globalThis.String(object.payOrderId) : "",
  7904. purchaseToken: isSet(object.purchaseToken) ? globalThis.String(object.purchaseToken) : "",
  7905. payType: isSet(object.payType) ? globalThis.String(object.payType) : "",
  7906. cfgId: isSet(object.cfgId) ? globalThis.Number(object.cfgId) : 0,
  7907. };
  7908. },
  7909. toJSON(message: rechargeResult): unknown {
  7910. const obj: any = {};
  7911. if (message.orderId !== "") {
  7912. obj.orderId = message.orderId;
  7913. }
  7914. if (message.payOrderId !== "") {
  7915. obj.payOrderId = message.payOrderId;
  7916. }
  7917. if (message.purchaseToken !== "") {
  7918. obj.purchaseToken = message.purchaseToken;
  7919. }
  7920. if (message.payType !== "") {
  7921. obj.payType = message.payType;
  7922. }
  7923. if (message.cfgId !== 0) {
  7924. obj.cfgId = Math.round(message.cfgId);
  7925. }
  7926. return obj;
  7927. },
  7928. create<I extends Exact<DeepPartial<rechargeResult>, I>>(base?: I): rechargeResult {
  7929. return rechargeResult.fromPartial(base ?? ({} as any));
  7930. },
  7931. fromPartial<I extends Exact<DeepPartial<rechargeResult>, I>>(object: I): rechargeResult {
  7932. const message = createBaserechargeResult();
  7933. message.orderId = object.orderId ?? "";
  7934. message.payOrderId = object.payOrderId ?? "";
  7935. message.purchaseToken = object.purchaseToken ?? "";
  7936. message.payType = object.payType ?? "";
  7937. message.cfgId = object.cfgId ?? 0;
  7938. return message;
  7939. },
  7940. };
  7941. function createBaserechargeResultRsp(): rechargeResultRsp {
  7942. return { errno: 0 };
  7943. }
  7944. export const rechargeResultRsp = {
  7945. fromJSON(object: any): rechargeResultRsp {
  7946. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  7947. },
  7948. toJSON(message: rechargeResultRsp): unknown {
  7949. const obj: any = {};
  7950. if (message.errno !== 0) {
  7951. obj.errno = Math.round(message.errno);
  7952. }
  7953. return obj;
  7954. },
  7955. create<I extends Exact<DeepPartial<rechargeResultRsp>, I>>(base?: I): rechargeResultRsp {
  7956. return rechargeResultRsp.fromPartial(base ?? ({} as any));
  7957. },
  7958. fromPartial<I extends Exact<DeepPartial<rechargeResultRsp>, I>>(object: I): rechargeResultRsp {
  7959. const message = createBaserechargeResultRsp();
  7960. message.errno = object.errno ?? 0;
  7961. return message;
  7962. },
  7963. };
  7964. function createBaseonlineAwardGetAward(): onlineAwardGetAward {
  7965. return { pos: 0 };
  7966. }
  7967. export const onlineAwardGetAward = {
  7968. fromJSON(object: any): onlineAwardGetAward {
  7969. return { pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0 };
  7970. },
  7971. toJSON(message: onlineAwardGetAward): unknown {
  7972. const obj: any = {};
  7973. if (message.pos !== 0) {
  7974. obj.pos = Math.round(message.pos);
  7975. }
  7976. return obj;
  7977. },
  7978. create<I extends Exact<DeepPartial<onlineAwardGetAward>, I>>(base?: I): onlineAwardGetAward {
  7979. return onlineAwardGetAward.fromPartial(base ?? ({} as any));
  7980. },
  7981. fromPartial<I extends Exact<DeepPartial<onlineAwardGetAward>, I>>(object: I): onlineAwardGetAward {
  7982. const message = createBaseonlineAwardGetAward();
  7983. message.pos = object.pos ?? 0;
  7984. return message;
  7985. },
  7986. };
  7987. function createBaseonlineAwardGetAwardRsp(): onlineAwardGetAwardRsp {
  7988. return { errno: 0, award: 0 };
  7989. }
  7990. export const onlineAwardGetAwardRsp = {
  7991. fromJSON(object: any): onlineAwardGetAwardRsp {
  7992. return {
  7993. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  7994. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  7995. };
  7996. },
  7997. toJSON(message: onlineAwardGetAwardRsp): unknown {
  7998. const obj: any = {};
  7999. if (message.errno !== 0) {
  8000. obj.errno = Math.round(message.errno);
  8001. }
  8002. if (message.award !== 0) {
  8003. obj.award = Math.round(message.award);
  8004. }
  8005. return obj;
  8006. },
  8007. create<I extends Exact<DeepPartial<onlineAwardGetAwardRsp>, I>>(base?: I): onlineAwardGetAwardRsp {
  8008. return onlineAwardGetAwardRsp.fromPartial(base ?? ({} as any));
  8009. },
  8010. fromPartial<I extends Exact<DeepPartial<onlineAwardGetAwardRsp>, I>>(object: I): onlineAwardGetAwardRsp {
  8011. const message = createBaseonlineAwardGetAwardRsp();
  8012. message.errno = object.errno ?? 0;
  8013. message.award = object.award ?? 0;
  8014. return message;
  8015. },
  8016. };
  8017. function createBaseonlineAwardGetData(): onlineAwardGetData {
  8018. return {};
  8019. }
  8020. export const onlineAwardGetData = {
  8021. fromJSON(_: any): onlineAwardGetData {
  8022. return {};
  8023. },
  8024. toJSON(_: onlineAwardGetData): unknown {
  8025. const obj: any = {};
  8026. return obj;
  8027. },
  8028. create<I extends Exact<DeepPartial<onlineAwardGetData>, I>>(base?: I): onlineAwardGetData {
  8029. return onlineAwardGetData.fromPartial(base ?? ({} as any));
  8030. },
  8031. fromPartial<I extends Exact<DeepPartial<onlineAwardGetData>, I>>(_: I): onlineAwardGetData {
  8032. const message = createBaseonlineAwardGetData();
  8033. return message;
  8034. },
  8035. };
  8036. function createBaseonlineAwardGetDataRsp(): onlineAwardGetDataRsp {
  8037. return { errno: 0 };
  8038. }
  8039. export const onlineAwardGetDataRsp = {
  8040. fromJSON(object: any): onlineAwardGetDataRsp {
  8041. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8042. },
  8043. toJSON(message: onlineAwardGetDataRsp): unknown {
  8044. const obj: any = {};
  8045. if (message.errno !== 0) {
  8046. obj.errno = Math.round(message.errno);
  8047. }
  8048. return obj;
  8049. },
  8050. create<I extends Exact<DeepPartial<onlineAwardGetDataRsp>, I>>(base?: I): onlineAwardGetDataRsp {
  8051. return onlineAwardGetDataRsp.fromPartial(base ?? ({} as any));
  8052. },
  8053. fromPartial<I extends Exact<DeepPartial<onlineAwardGetDataRsp>, I>>(object: I): onlineAwardGetDataRsp {
  8054. const message = createBaseonlineAwardGetDataRsp();
  8055. message.errno = object.errno ?? 0;
  8056. return message;
  8057. },
  8058. };
  8059. function createBaseonlineAwardNty(): onlineAwardNty {
  8060. return { open: false, time: 0, award: 0 };
  8061. }
  8062. export const onlineAwardNty = {
  8063. fromJSON(object: any): onlineAwardNty {
  8064. return {
  8065. open: isSet(object.open) ? globalThis.Boolean(object.open) : false,
  8066. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  8067. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  8068. };
  8069. },
  8070. toJSON(message: onlineAwardNty): unknown {
  8071. const obj: any = {};
  8072. if (message.open !== false) {
  8073. obj.open = message.open;
  8074. }
  8075. if (message.time !== 0) {
  8076. obj.time = Math.round(message.time);
  8077. }
  8078. if (message.award !== 0) {
  8079. obj.award = Math.round(message.award);
  8080. }
  8081. return obj;
  8082. },
  8083. create<I extends Exact<DeepPartial<onlineAwardNty>, I>>(base?: I): onlineAwardNty {
  8084. return onlineAwardNty.fromPartial(base ?? ({} as any));
  8085. },
  8086. fromPartial<I extends Exact<DeepPartial<onlineAwardNty>, I>>(object: I): onlineAwardNty {
  8087. const message = createBaseonlineAwardNty();
  8088. message.open = object.open ?? false;
  8089. message.time = object.time ?? 0;
  8090. message.award = object.award ?? 0;
  8091. return message;
  8092. },
  8093. };
  8094. function createBasespeedUpData(): speedUpData {
  8095. return {};
  8096. }
  8097. export const speedUpData = {
  8098. fromJSON(_: any): speedUpData {
  8099. return {};
  8100. },
  8101. toJSON(_: speedUpData): unknown {
  8102. const obj: any = {};
  8103. return obj;
  8104. },
  8105. create<I extends Exact<DeepPartial<speedUpData>, I>>(base?: I): speedUpData {
  8106. return speedUpData.fromPartial(base ?? ({} as any));
  8107. },
  8108. fromPartial<I extends Exact<DeepPartial<speedUpData>, I>>(_: I): speedUpData {
  8109. const message = createBasespeedUpData();
  8110. return message;
  8111. },
  8112. };
  8113. function createBasespeedUpDataRsp(): speedUpDataRsp {
  8114. return { errno: 0, time: 0 };
  8115. }
  8116. export const speedUpDataRsp = {
  8117. fromJSON(object: any): speedUpDataRsp {
  8118. return {
  8119. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8120. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  8121. };
  8122. },
  8123. toJSON(message: speedUpDataRsp): unknown {
  8124. const obj: any = {};
  8125. if (message.errno !== 0) {
  8126. obj.errno = Math.round(message.errno);
  8127. }
  8128. if (message.time !== 0) {
  8129. obj.time = Math.round(message.time);
  8130. }
  8131. return obj;
  8132. },
  8133. create<I extends Exact<DeepPartial<speedUpDataRsp>, I>>(base?: I): speedUpDataRsp {
  8134. return speedUpDataRsp.fromPartial(base ?? ({} as any));
  8135. },
  8136. fromPartial<I extends Exact<DeepPartial<speedUpDataRsp>, I>>(object: I): speedUpDataRsp {
  8137. const message = createBasespeedUpDataRsp();
  8138. message.errno = object.errno ?? 0;
  8139. message.time = object.time ?? 0;
  8140. return message;
  8141. },
  8142. };
  8143. function createBasespeedUpBuy(): speedUpBuy {
  8144. return { free: false };
  8145. }
  8146. export const speedUpBuy = {
  8147. fromJSON(object: any): speedUpBuy {
  8148. return { free: isSet(object.free) ? globalThis.Boolean(object.free) : false };
  8149. },
  8150. toJSON(message: speedUpBuy): unknown {
  8151. const obj: any = {};
  8152. if (message.free !== false) {
  8153. obj.free = message.free;
  8154. }
  8155. return obj;
  8156. },
  8157. create<I extends Exact<DeepPartial<speedUpBuy>, I>>(base?: I): speedUpBuy {
  8158. return speedUpBuy.fromPartial(base ?? ({} as any));
  8159. },
  8160. fromPartial<I extends Exact<DeepPartial<speedUpBuy>, I>>(object: I): speedUpBuy {
  8161. const message = createBasespeedUpBuy();
  8162. message.free = object.free ?? false;
  8163. return message;
  8164. },
  8165. };
  8166. function createBasespeedUpBuyRsp(): speedUpBuyRsp {
  8167. return { errno: 0, time: 0 };
  8168. }
  8169. export const speedUpBuyRsp = {
  8170. fromJSON(object: any): speedUpBuyRsp {
  8171. return {
  8172. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8173. time: isSet(object.time) ? globalThis.Number(object.time) : 0,
  8174. };
  8175. },
  8176. toJSON(message: speedUpBuyRsp): unknown {
  8177. const obj: any = {};
  8178. if (message.errno !== 0) {
  8179. obj.errno = Math.round(message.errno);
  8180. }
  8181. if (message.time !== 0) {
  8182. obj.time = Math.round(message.time);
  8183. }
  8184. return obj;
  8185. },
  8186. create<I extends Exact<DeepPartial<speedUpBuyRsp>, I>>(base?: I): speedUpBuyRsp {
  8187. return speedUpBuyRsp.fromPartial(base ?? ({} as any));
  8188. },
  8189. fromPartial<I extends Exact<DeepPartial<speedUpBuyRsp>, I>>(object: I): speedUpBuyRsp {
  8190. const message = createBasespeedUpBuyRsp();
  8191. message.errno = object.errno ?? 0;
  8192. message.time = object.time ?? 0;
  8193. return message;
  8194. },
  8195. };
  8196. function createBasecitySkillUpgrade(): citySkillUpgrade {
  8197. return { id: 0 };
  8198. }
  8199. export const citySkillUpgrade = {
  8200. fromJSON(object: any): citySkillUpgrade {
  8201. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8202. },
  8203. toJSON(message: citySkillUpgrade): unknown {
  8204. const obj: any = {};
  8205. if (message.id !== 0) {
  8206. obj.id = Math.round(message.id);
  8207. }
  8208. return obj;
  8209. },
  8210. create<I extends Exact<DeepPartial<citySkillUpgrade>, I>>(base?: I): citySkillUpgrade {
  8211. return citySkillUpgrade.fromPartial(base ?? ({} as any));
  8212. },
  8213. fromPartial<I extends Exact<DeepPartial<citySkillUpgrade>, I>>(object: I): citySkillUpgrade {
  8214. const message = createBasecitySkillUpgrade();
  8215. message.id = object.id ?? 0;
  8216. return message;
  8217. },
  8218. };
  8219. function createBasecitySkillUpgradeRsp(): citySkillUpgradeRsp {
  8220. return { errno: 0, id: 0 };
  8221. }
  8222. export const citySkillUpgradeRsp = {
  8223. fromJSON(object: any): citySkillUpgradeRsp {
  8224. return {
  8225. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8226. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  8227. };
  8228. },
  8229. toJSON(message: citySkillUpgradeRsp): unknown {
  8230. const obj: any = {};
  8231. if (message.errno !== 0) {
  8232. obj.errno = Math.round(message.errno);
  8233. }
  8234. if (message.id !== 0) {
  8235. obj.id = Math.round(message.id);
  8236. }
  8237. return obj;
  8238. },
  8239. create<I extends Exact<DeepPartial<citySkillUpgradeRsp>, I>>(base?: I): citySkillUpgradeRsp {
  8240. return citySkillUpgradeRsp.fromPartial(base ?? ({} as any));
  8241. },
  8242. fromPartial<I extends Exact<DeepPartial<citySkillUpgradeRsp>, I>>(object: I): citySkillUpgradeRsp {
  8243. const message = createBasecitySkillUpgradeRsp();
  8244. message.errno = object.errno ?? 0;
  8245. message.id = object.id ?? 0;
  8246. return message;
  8247. },
  8248. };
  8249. function createBasecitySkillBattle(): citySkillBattle {
  8250. return { id: 0 };
  8251. }
  8252. export const citySkillBattle = {
  8253. fromJSON(object: any): citySkillBattle {
  8254. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8255. },
  8256. toJSON(message: citySkillBattle): unknown {
  8257. const obj: any = {};
  8258. if (message.id !== 0) {
  8259. obj.id = Math.round(message.id);
  8260. }
  8261. return obj;
  8262. },
  8263. create<I extends Exact<DeepPartial<citySkillBattle>, I>>(base?: I): citySkillBattle {
  8264. return citySkillBattle.fromPartial(base ?? ({} as any));
  8265. },
  8266. fromPartial<I extends Exact<DeepPartial<citySkillBattle>, I>>(object: I): citySkillBattle {
  8267. const message = createBasecitySkillBattle();
  8268. message.id = object.id ?? 0;
  8269. return message;
  8270. },
  8271. };
  8272. function createBasecitySkillBattleRsp(): citySkillBattleRsp {
  8273. return { errno: 0, id: 0 };
  8274. }
  8275. export const citySkillBattleRsp = {
  8276. fromJSON(object: any): citySkillBattleRsp {
  8277. return {
  8278. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8279. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  8280. };
  8281. },
  8282. toJSON(message: citySkillBattleRsp): unknown {
  8283. const obj: any = {};
  8284. if (message.errno !== 0) {
  8285. obj.errno = Math.round(message.errno);
  8286. }
  8287. if (message.id !== 0) {
  8288. obj.id = Math.round(message.id);
  8289. }
  8290. return obj;
  8291. },
  8292. create<I extends Exact<DeepPartial<citySkillBattleRsp>, I>>(base?: I): citySkillBattleRsp {
  8293. return citySkillBattleRsp.fromPartial(base ?? ({} as any));
  8294. },
  8295. fromPartial<I extends Exact<DeepPartial<citySkillBattleRsp>, I>>(object: I): citySkillBattleRsp {
  8296. const message = createBasecitySkillBattleRsp();
  8297. message.errno = object.errno ?? 0;
  8298. message.id = object.id ?? 0;
  8299. return message;
  8300. },
  8301. };
  8302. function createBasebuildingExplore(): buildingExplore {
  8303. return { id: 0 };
  8304. }
  8305. export const buildingExplore = {
  8306. fromJSON(object: any): buildingExplore {
  8307. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8308. },
  8309. toJSON(message: buildingExplore): unknown {
  8310. const obj: any = {};
  8311. if (message.id !== 0) {
  8312. obj.id = Math.round(message.id);
  8313. }
  8314. return obj;
  8315. },
  8316. create<I extends Exact<DeepPartial<buildingExplore>, I>>(base?: I): buildingExplore {
  8317. return buildingExplore.fromPartial(base ?? ({} as any));
  8318. },
  8319. fromPartial<I extends Exact<DeepPartial<buildingExplore>, I>>(object: I): buildingExplore {
  8320. const message = createBasebuildingExplore();
  8321. message.id = object.id ?? 0;
  8322. return message;
  8323. },
  8324. };
  8325. function createBasebuildingExploreRsp(): buildingExploreRsp {
  8326. return { errno: 0, data: undefined };
  8327. }
  8328. export const buildingExploreRsp = {
  8329. fromJSON(object: any): buildingExploreRsp {
  8330. return {
  8331. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8332. data: isSet(object.data) ? building.fromJSON(object.data) : undefined,
  8333. };
  8334. },
  8335. toJSON(message: buildingExploreRsp): unknown {
  8336. const obj: any = {};
  8337. if (message.errno !== 0) {
  8338. obj.errno = Math.round(message.errno);
  8339. }
  8340. if (message.data !== undefined) {
  8341. obj.data = building.toJSON(message.data);
  8342. }
  8343. return obj;
  8344. },
  8345. create<I extends Exact<DeepPartial<buildingExploreRsp>, I>>(base?: I): buildingExploreRsp {
  8346. return buildingExploreRsp.fromPartial(base ?? ({} as any));
  8347. },
  8348. fromPartial<I extends Exact<DeepPartial<buildingExploreRsp>, I>>(object: I): buildingExploreRsp {
  8349. const message = createBasebuildingExploreRsp();
  8350. message.errno = object.errno ?? 0;
  8351. message.data = (object.data !== undefined && object.data !== null) ? building.fromPartial(object.data) : undefined;
  8352. return message;
  8353. },
  8354. };
  8355. function createBasebuildingAutoExploreAward(): buildingAutoExploreAward {
  8356. return { id: 0 };
  8357. }
  8358. export const buildingAutoExploreAward = {
  8359. fromJSON(object: any): buildingAutoExploreAward {
  8360. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8361. },
  8362. toJSON(message: buildingAutoExploreAward): unknown {
  8363. const obj: any = {};
  8364. if (message.id !== 0) {
  8365. obj.id = Math.round(message.id);
  8366. }
  8367. return obj;
  8368. },
  8369. create<I extends Exact<DeepPartial<buildingAutoExploreAward>, I>>(base?: I): buildingAutoExploreAward {
  8370. return buildingAutoExploreAward.fromPartial(base ?? ({} as any));
  8371. },
  8372. fromPartial<I extends Exact<DeepPartial<buildingAutoExploreAward>, I>>(object: I): buildingAutoExploreAward {
  8373. const message = createBasebuildingAutoExploreAward();
  8374. message.id = object.id ?? 0;
  8375. return message;
  8376. },
  8377. };
  8378. function createBasebuildingAutoExploreAwardRsp(): buildingAutoExploreAwardRsp {
  8379. return { errno: 0, data: undefined };
  8380. }
  8381. export const buildingAutoExploreAwardRsp = {
  8382. fromJSON(object: any): buildingAutoExploreAwardRsp {
  8383. return {
  8384. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8385. data: isSet(object.data) ? building.fromJSON(object.data) : undefined,
  8386. };
  8387. },
  8388. toJSON(message: buildingAutoExploreAwardRsp): unknown {
  8389. const obj: any = {};
  8390. if (message.errno !== 0) {
  8391. obj.errno = Math.round(message.errno);
  8392. }
  8393. if (message.data !== undefined) {
  8394. obj.data = building.toJSON(message.data);
  8395. }
  8396. return obj;
  8397. },
  8398. create<I extends Exact<DeepPartial<buildingAutoExploreAwardRsp>, I>>(base?: I): buildingAutoExploreAwardRsp {
  8399. return buildingAutoExploreAwardRsp.fromPartial(base ?? ({} as any));
  8400. },
  8401. fromPartial<I extends Exact<DeepPartial<buildingAutoExploreAwardRsp>, I>>(object: I): buildingAutoExploreAwardRsp {
  8402. const message = createBasebuildingAutoExploreAwardRsp();
  8403. message.errno = object.errno ?? 0;
  8404. message.data = (object.data !== undefined && object.data !== null) ? building.fromPartial(object.data) : undefined;
  8405. return message;
  8406. },
  8407. };
  8408. function createBasebuildingExploreBattle(): buildingExploreBattle {
  8409. return { id: 0, list: [] };
  8410. }
  8411. export const buildingExploreBattle = {
  8412. fromJSON(object: any): buildingExploreBattle {
  8413. return {
  8414. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  8415. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.String(e)) : [],
  8416. };
  8417. },
  8418. toJSON(message: buildingExploreBattle): unknown {
  8419. const obj: any = {};
  8420. if (message.id !== 0) {
  8421. obj.id = Math.round(message.id);
  8422. }
  8423. if (message.list?.length) {
  8424. obj.list = message.list;
  8425. }
  8426. return obj;
  8427. },
  8428. create<I extends Exact<DeepPartial<buildingExploreBattle>, I>>(base?: I): buildingExploreBattle {
  8429. return buildingExploreBattle.fromPartial(base ?? ({} as any));
  8430. },
  8431. fromPartial<I extends Exact<DeepPartial<buildingExploreBattle>, I>>(object: I): buildingExploreBattle {
  8432. const message = createBasebuildingExploreBattle();
  8433. message.id = object.id ?? 0;
  8434. message.list = object.list?.map((e) => e) || [];
  8435. return message;
  8436. },
  8437. };
  8438. function createBasebuildingExploreBattleRsp(): buildingExploreBattleRsp {
  8439. return { errno: 0, data: undefined };
  8440. }
  8441. export const buildingExploreBattleRsp = {
  8442. fromJSON(object: any): buildingExploreBattleRsp {
  8443. return {
  8444. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8445. data: isSet(object.data) ? building.fromJSON(object.data) : undefined,
  8446. };
  8447. },
  8448. toJSON(message: buildingExploreBattleRsp): unknown {
  8449. const obj: any = {};
  8450. if (message.errno !== 0) {
  8451. obj.errno = Math.round(message.errno);
  8452. }
  8453. if (message.data !== undefined) {
  8454. obj.data = building.toJSON(message.data);
  8455. }
  8456. return obj;
  8457. },
  8458. create<I extends Exact<DeepPartial<buildingExploreBattleRsp>, I>>(base?: I): buildingExploreBattleRsp {
  8459. return buildingExploreBattleRsp.fromPartial(base ?? ({} as any));
  8460. },
  8461. fromPartial<I extends Exact<DeepPartial<buildingExploreBattleRsp>, I>>(object: I): buildingExploreBattleRsp {
  8462. const message = createBasebuildingExploreBattleRsp();
  8463. message.errno = object.errno ?? 0;
  8464. message.data = (object.data !== undefined && object.data !== null) ? building.fromPartial(object.data) : undefined;
  8465. return message;
  8466. },
  8467. };
  8468. function createBasebuildingAutoExploreOption(): buildingAutoExploreOption {
  8469. return { id: 0, open: false };
  8470. }
  8471. export const buildingAutoExploreOption = {
  8472. fromJSON(object: any): buildingAutoExploreOption {
  8473. return {
  8474. id: isSet(object.id) ? globalThis.Number(object.id) : 0,
  8475. open: isSet(object.open) ? globalThis.Boolean(object.open) : false,
  8476. };
  8477. },
  8478. toJSON(message: buildingAutoExploreOption): unknown {
  8479. const obj: any = {};
  8480. if (message.id !== 0) {
  8481. obj.id = Math.round(message.id);
  8482. }
  8483. if (message.open !== false) {
  8484. obj.open = message.open;
  8485. }
  8486. return obj;
  8487. },
  8488. create<I extends Exact<DeepPartial<buildingAutoExploreOption>, I>>(base?: I): buildingAutoExploreOption {
  8489. return buildingAutoExploreOption.fromPartial(base ?? ({} as any));
  8490. },
  8491. fromPartial<I extends Exact<DeepPartial<buildingAutoExploreOption>, I>>(object: I): buildingAutoExploreOption {
  8492. const message = createBasebuildingAutoExploreOption();
  8493. message.id = object.id ?? 0;
  8494. message.open = object.open ?? false;
  8495. return message;
  8496. },
  8497. };
  8498. function createBasebuildingAutoExploreOptionRsp(): buildingAutoExploreOptionRsp {
  8499. return { errno: 0, data: undefined };
  8500. }
  8501. export const buildingAutoExploreOptionRsp = {
  8502. fromJSON(object: any): buildingAutoExploreOptionRsp {
  8503. return {
  8504. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8505. data: isSet(object.data) ? building.fromJSON(object.data) : undefined,
  8506. };
  8507. },
  8508. toJSON(message: buildingAutoExploreOptionRsp): unknown {
  8509. const obj: any = {};
  8510. if (message.errno !== 0) {
  8511. obj.errno = Math.round(message.errno);
  8512. }
  8513. if (message.data !== undefined) {
  8514. obj.data = building.toJSON(message.data);
  8515. }
  8516. return obj;
  8517. },
  8518. create<I extends Exact<DeepPartial<buildingAutoExploreOptionRsp>, I>>(base?: I): buildingAutoExploreOptionRsp {
  8519. return buildingAutoExploreOptionRsp.fromPartial(base ?? ({} as any));
  8520. },
  8521. fromPartial<I extends Exact<DeepPartial<buildingAutoExploreOptionRsp>, I>>(object: I): buildingAutoExploreOptionRsp {
  8522. const message = createBasebuildingAutoExploreOptionRsp();
  8523. message.errno = object.errno ?? 0;
  8524. message.data = (object.data !== undefined && object.data !== null) ? building.fromPartial(object.data) : undefined;
  8525. return message;
  8526. },
  8527. };
  8528. function createBaselevelGiftData(): levelGiftData {
  8529. return {};
  8530. }
  8531. export const levelGiftData = {
  8532. fromJSON(_: any): levelGiftData {
  8533. return {};
  8534. },
  8535. toJSON(_: levelGiftData): unknown {
  8536. const obj: any = {};
  8537. return obj;
  8538. },
  8539. create<I extends Exact<DeepPartial<levelGiftData>, I>>(base?: I): levelGiftData {
  8540. return levelGiftData.fromPartial(base ?? ({} as any));
  8541. },
  8542. fromPartial<I extends Exact<DeepPartial<levelGiftData>, I>>(_: I): levelGiftData {
  8543. const message = createBaselevelGiftData();
  8544. return message;
  8545. },
  8546. };
  8547. function createBaselevelGiftDataRsp(): levelGiftDataRsp {
  8548. return { errno: 0 };
  8549. }
  8550. export const levelGiftDataRsp = {
  8551. fromJSON(object: any): levelGiftDataRsp {
  8552. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8553. },
  8554. toJSON(message: levelGiftDataRsp): unknown {
  8555. const obj: any = {};
  8556. if (message.errno !== 0) {
  8557. obj.errno = Math.round(message.errno);
  8558. }
  8559. return obj;
  8560. },
  8561. create<I extends Exact<DeepPartial<levelGiftDataRsp>, I>>(base?: I): levelGiftDataRsp {
  8562. return levelGiftDataRsp.fromPartial(base ?? ({} as any));
  8563. },
  8564. fromPartial<I extends Exact<DeepPartial<levelGiftDataRsp>, I>>(object: I): levelGiftDataRsp {
  8565. const message = createBaselevelGiftDataRsp();
  8566. message.errno = object.errno ?? 0;
  8567. return message;
  8568. },
  8569. };
  8570. function createBaselevelGiftBuy(): levelGiftBuy {
  8571. return { id: 0 };
  8572. }
  8573. export const levelGiftBuy = {
  8574. fromJSON(object: any): levelGiftBuy {
  8575. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8576. },
  8577. toJSON(message: levelGiftBuy): unknown {
  8578. const obj: any = {};
  8579. if (message.id !== 0) {
  8580. obj.id = Math.round(message.id);
  8581. }
  8582. return obj;
  8583. },
  8584. create<I extends Exact<DeepPartial<levelGiftBuy>, I>>(base?: I): levelGiftBuy {
  8585. return levelGiftBuy.fromPartial(base ?? ({} as any));
  8586. },
  8587. fromPartial<I extends Exact<DeepPartial<levelGiftBuy>, I>>(object: I): levelGiftBuy {
  8588. const message = createBaselevelGiftBuy();
  8589. message.id = object.id ?? 0;
  8590. return message;
  8591. },
  8592. };
  8593. function createBaselevelGiftBuyRsp(): levelGiftBuyRsp {
  8594. return { errno: 0 };
  8595. }
  8596. export const levelGiftBuyRsp = {
  8597. fromJSON(object: any): levelGiftBuyRsp {
  8598. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8599. },
  8600. toJSON(message: levelGiftBuyRsp): unknown {
  8601. const obj: any = {};
  8602. if (message.errno !== 0) {
  8603. obj.errno = Math.round(message.errno);
  8604. }
  8605. return obj;
  8606. },
  8607. create<I extends Exact<DeepPartial<levelGiftBuyRsp>, I>>(base?: I): levelGiftBuyRsp {
  8608. return levelGiftBuyRsp.fromPartial(base ?? ({} as any));
  8609. },
  8610. fromPartial<I extends Exact<DeepPartial<levelGiftBuyRsp>, I>>(object: I): levelGiftBuyRsp {
  8611. const message = createBaselevelGiftBuyRsp();
  8612. message.errno = object.errno ?? 0;
  8613. return message;
  8614. },
  8615. };
  8616. function createBaselevelGiftNty(): levelGiftNty {
  8617. return { list: [] };
  8618. }
  8619. export const levelGiftNty = {
  8620. fromJSON(object: any): levelGiftNty {
  8621. return { list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => idNum.fromJSON(e)) : [] };
  8622. },
  8623. toJSON(message: levelGiftNty): unknown {
  8624. const obj: any = {};
  8625. if (message.list?.length) {
  8626. obj.list = message.list.map((e) => idNum.toJSON(e));
  8627. }
  8628. return obj;
  8629. },
  8630. create<I extends Exact<DeepPartial<levelGiftNty>, I>>(base?: I): levelGiftNty {
  8631. return levelGiftNty.fromPartial(base ?? ({} as any));
  8632. },
  8633. fromPartial<I extends Exact<DeepPartial<levelGiftNty>, I>>(object: I): levelGiftNty {
  8634. const message = createBaselevelGiftNty();
  8635. message.list = object.list?.map((e) => idNum.fromPartial(e)) || [];
  8636. return message;
  8637. },
  8638. };
  8639. function createBaselevelGiftDelRedPoint(): levelGiftDelRedPoint {
  8640. return {};
  8641. }
  8642. export const levelGiftDelRedPoint = {
  8643. fromJSON(_: any): levelGiftDelRedPoint {
  8644. return {};
  8645. },
  8646. toJSON(_: levelGiftDelRedPoint): unknown {
  8647. const obj: any = {};
  8648. return obj;
  8649. },
  8650. create<I extends Exact<DeepPartial<levelGiftDelRedPoint>, I>>(base?: I): levelGiftDelRedPoint {
  8651. return levelGiftDelRedPoint.fromPartial(base ?? ({} as any));
  8652. },
  8653. fromPartial<I extends Exact<DeepPartial<levelGiftDelRedPoint>, I>>(_: I): levelGiftDelRedPoint {
  8654. const message = createBaselevelGiftDelRedPoint();
  8655. return message;
  8656. },
  8657. };
  8658. function createBaselevelGiftDelRedPointRsp(): levelGiftDelRedPointRsp {
  8659. return { errno: 0 };
  8660. }
  8661. export const levelGiftDelRedPointRsp = {
  8662. fromJSON(object: any): levelGiftDelRedPointRsp {
  8663. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8664. },
  8665. toJSON(message: levelGiftDelRedPointRsp): unknown {
  8666. const obj: any = {};
  8667. if (message.errno !== 0) {
  8668. obj.errno = Math.round(message.errno);
  8669. }
  8670. return obj;
  8671. },
  8672. create<I extends Exact<DeepPartial<levelGiftDelRedPointRsp>, I>>(base?: I): levelGiftDelRedPointRsp {
  8673. return levelGiftDelRedPointRsp.fromPartial(base ?? ({} as any));
  8674. },
  8675. fromPartial<I extends Exact<DeepPartial<levelGiftDelRedPointRsp>, I>>(object: I): levelGiftDelRedPointRsp {
  8676. const message = createBaselevelGiftDelRedPointRsp();
  8677. message.errno = object.errno ?? 0;
  8678. return message;
  8679. },
  8680. };
  8681. function createBaselotteryData(): lotteryData {
  8682. return {};
  8683. }
  8684. export const lotteryData = {
  8685. fromJSON(_: any): lotteryData {
  8686. return {};
  8687. },
  8688. toJSON(_: lotteryData): unknown {
  8689. const obj: any = {};
  8690. return obj;
  8691. },
  8692. create<I extends Exact<DeepPartial<lotteryData>, I>>(base?: I): lotteryData {
  8693. return lotteryData.fromPartial(base ?? ({} as any));
  8694. },
  8695. fromPartial<I extends Exact<DeepPartial<lotteryData>, I>>(_: I): lotteryData {
  8696. const message = createBaselotteryData();
  8697. return message;
  8698. },
  8699. };
  8700. function createBaselotteryDataRsp(): lotteryDataRsp {
  8701. return { errno: 0 };
  8702. }
  8703. export const lotteryDataRsp = {
  8704. fromJSON(object: any): lotteryDataRsp {
  8705. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8706. },
  8707. toJSON(message: lotteryDataRsp): unknown {
  8708. const obj: any = {};
  8709. if (message.errno !== 0) {
  8710. obj.errno = Math.round(message.errno);
  8711. }
  8712. return obj;
  8713. },
  8714. create<I extends Exact<DeepPartial<lotteryDataRsp>, I>>(base?: I): lotteryDataRsp {
  8715. return lotteryDataRsp.fromPartial(base ?? ({} as any));
  8716. },
  8717. fromPartial<I extends Exact<DeepPartial<lotteryDataRsp>, I>>(object: I): lotteryDataRsp {
  8718. const message = createBaselotteryDataRsp();
  8719. message.errno = object.errno ?? 0;
  8720. return message;
  8721. },
  8722. };
  8723. function createBaselotteryAward(): lotteryAward {
  8724. return { free: false };
  8725. }
  8726. export const lotteryAward = {
  8727. fromJSON(object: any): lotteryAward {
  8728. return { free: isSet(object.free) ? globalThis.Boolean(object.free) : false };
  8729. },
  8730. toJSON(message: lotteryAward): unknown {
  8731. const obj: any = {};
  8732. if (message.free !== false) {
  8733. obj.free = message.free;
  8734. }
  8735. return obj;
  8736. },
  8737. create<I extends Exact<DeepPartial<lotteryAward>, I>>(base?: I): lotteryAward {
  8738. return lotteryAward.fromPartial(base ?? ({} as any));
  8739. },
  8740. fromPartial<I extends Exact<DeepPartial<lotteryAward>, I>>(object: I): lotteryAward {
  8741. const message = createBaselotteryAward();
  8742. message.free = object.free ?? false;
  8743. return message;
  8744. },
  8745. };
  8746. function createBaselotteryAwardRsp(): lotteryAwardRsp {
  8747. return { errno: 0, free: false, award: 0 };
  8748. }
  8749. export const lotteryAwardRsp = {
  8750. fromJSON(object: any): lotteryAwardRsp {
  8751. return {
  8752. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8753. free: isSet(object.free) ? globalThis.Boolean(object.free) : false,
  8754. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  8755. };
  8756. },
  8757. toJSON(message: lotteryAwardRsp): unknown {
  8758. const obj: any = {};
  8759. if (message.errno !== 0) {
  8760. obj.errno = Math.round(message.errno);
  8761. }
  8762. if (message.free !== false) {
  8763. obj.free = message.free;
  8764. }
  8765. if (message.award !== 0) {
  8766. obj.award = Math.round(message.award);
  8767. }
  8768. return obj;
  8769. },
  8770. create<I extends Exact<DeepPartial<lotteryAwardRsp>, I>>(base?: I): lotteryAwardRsp {
  8771. return lotteryAwardRsp.fromPartial(base ?? ({} as any));
  8772. },
  8773. fromPartial<I extends Exact<DeepPartial<lotteryAwardRsp>, I>>(object: I): lotteryAwardRsp {
  8774. const message = createBaselotteryAwardRsp();
  8775. message.errno = object.errno ?? 0;
  8776. message.free = object.free ?? false;
  8777. message.award = object.award ?? 0;
  8778. return message;
  8779. },
  8780. };
  8781. function createBaselotteryBuy(): lotteryBuy {
  8782. return {};
  8783. }
  8784. export const lotteryBuy = {
  8785. fromJSON(_: any): lotteryBuy {
  8786. return {};
  8787. },
  8788. toJSON(_: lotteryBuy): unknown {
  8789. const obj: any = {};
  8790. return obj;
  8791. },
  8792. create<I extends Exact<DeepPartial<lotteryBuy>, I>>(base?: I): lotteryBuy {
  8793. return lotteryBuy.fromPartial(base ?? ({} as any));
  8794. },
  8795. fromPartial<I extends Exact<DeepPartial<lotteryBuy>, I>>(_: I): lotteryBuy {
  8796. const message = createBaselotteryBuy();
  8797. return message;
  8798. },
  8799. };
  8800. function createBaselotteryBuyRsp(): lotteryBuyRsp {
  8801. return { errno: 0 };
  8802. }
  8803. export const lotteryBuyRsp = {
  8804. fromJSON(object: any): lotteryBuyRsp {
  8805. return { errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0 };
  8806. },
  8807. toJSON(message: lotteryBuyRsp): unknown {
  8808. const obj: any = {};
  8809. if (message.errno !== 0) {
  8810. obj.errno = Math.round(message.errno);
  8811. }
  8812. return obj;
  8813. },
  8814. create<I extends Exact<DeepPartial<lotteryBuyRsp>, I>>(base?: I): lotteryBuyRsp {
  8815. return lotteryBuyRsp.fromPartial(base ?? ({} as any));
  8816. },
  8817. fromPartial<I extends Exact<DeepPartial<lotteryBuyRsp>, I>>(object: I): lotteryBuyRsp {
  8818. const message = createBaselotteryBuyRsp();
  8819. message.errno = object.errno ?? 0;
  8820. return message;
  8821. },
  8822. };
  8823. function createBaselotteryNty(): lotteryNty {
  8824. return { state: 0, free: 0, award: 0, day: 0 };
  8825. }
  8826. export const lotteryNty = {
  8827. fromJSON(object: any): lotteryNty {
  8828. return {
  8829. state: isSet(object.state) ? globalThis.Number(object.state) : 0,
  8830. free: isSet(object.free) ? globalThis.Number(object.free) : 0,
  8831. award: isSet(object.award) ? globalThis.Number(object.award) : 0,
  8832. day: isSet(object.day) ? globalThis.Number(object.day) : 0,
  8833. };
  8834. },
  8835. toJSON(message: lotteryNty): unknown {
  8836. const obj: any = {};
  8837. if (message.state !== 0) {
  8838. obj.state = Math.round(message.state);
  8839. }
  8840. if (message.free !== 0) {
  8841. obj.free = Math.round(message.free);
  8842. }
  8843. if (message.award !== 0) {
  8844. obj.award = Math.round(message.award);
  8845. }
  8846. if (message.day !== 0) {
  8847. obj.day = Math.round(message.day);
  8848. }
  8849. return obj;
  8850. },
  8851. create<I extends Exact<DeepPartial<lotteryNty>, I>>(base?: I): lotteryNty {
  8852. return lotteryNty.fromPartial(base ?? ({} as any));
  8853. },
  8854. fromPartial<I extends Exact<DeepPartial<lotteryNty>, I>>(object: I): lotteryNty {
  8855. const message = createBaselotteryNty();
  8856. message.state = object.state ?? 0;
  8857. message.free = object.free ?? 0;
  8858. message.award = object.award ?? 0;
  8859. message.day = object.day ?? 0;
  8860. return message;
  8861. },
  8862. };
  8863. function createBaseactRankData(): actRankData {
  8864. return { id: 0 };
  8865. }
  8866. export const actRankData = {
  8867. fromJSON(object: any): actRankData {
  8868. return { id: isSet(object.id) ? globalThis.Number(object.id) : 0 };
  8869. },
  8870. toJSON(message: actRankData): unknown {
  8871. const obj: any = {};
  8872. if (message.id !== 0) {
  8873. obj.id = Math.round(message.id);
  8874. }
  8875. return obj;
  8876. },
  8877. create<I extends Exact<DeepPartial<actRankData>, I>>(base?: I): actRankData {
  8878. return actRankData.fromPartial(base ?? ({} as any));
  8879. },
  8880. fromPartial<I extends Exact<DeepPartial<actRankData>, I>>(object: I): actRankData {
  8881. const message = createBaseactRankData();
  8882. message.id = object.id ?? 0;
  8883. return message;
  8884. },
  8885. };
  8886. function createBaseactRankDataRsp(): actRankDataRsp {
  8887. return { errno: 0, list: [] };
  8888. }
  8889. export const actRankDataRsp = {
  8890. fromJSON(object: any): actRankDataRsp {
  8891. return {
  8892. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8893. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => rankingInfo.fromJSON(e)) : [],
  8894. };
  8895. },
  8896. toJSON(message: actRankDataRsp): unknown {
  8897. const obj: any = {};
  8898. if (message.errno !== 0) {
  8899. obj.errno = Math.round(message.errno);
  8900. }
  8901. if (message.list?.length) {
  8902. obj.list = message.list.map((e) => rankingInfo.toJSON(e));
  8903. }
  8904. return obj;
  8905. },
  8906. create<I extends Exact<DeepPartial<actRankDataRsp>, I>>(base?: I): actRankDataRsp {
  8907. return actRankDataRsp.fromPartial(base ?? ({} as any));
  8908. },
  8909. fromPartial<I extends Exact<DeepPartial<actRankDataRsp>, I>>(object: I): actRankDataRsp {
  8910. const message = createBaseactRankDataRsp();
  8911. message.errno = object.errno ?? 0;
  8912. message.list = object.list?.map((e) => rankingInfo.fromPartial(e)) || [];
  8913. return message;
  8914. },
  8915. };
  8916. function createBasetreasureGetData(): treasureGetData {
  8917. return {};
  8918. }
  8919. export const treasureGetData = {
  8920. fromJSON(_: any): treasureGetData {
  8921. return {};
  8922. },
  8923. toJSON(_: treasureGetData): unknown {
  8924. const obj: any = {};
  8925. return obj;
  8926. },
  8927. create<I extends Exact<DeepPartial<treasureGetData>, I>>(base?: I): treasureGetData {
  8928. return treasureGetData.fromPartial(base ?? ({} as any));
  8929. },
  8930. fromPartial<I extends Exact<DeepPartial<treasureGetData>, I>>(_: I): treasureGetData {
  8931. const message = createBasetreasureGetData();
  8932. return message;
  8933. },
  8934. };
  8935. function createBasetreasureGetDataRsp(): treasureGetDataRsp {
  8936. return { errno: 0, buy: 0, sign: 0, list: [], treasure: false };
  8937. }
  8938. export const treasureGetDataRsp = {
  8939. fromJSON(object: any): treasureGetDataRsp {
  8940. return {
  8941. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  8942. buy: isSet(object.buy) ? globalThis.Number(object.buy) : 0,
  8943. sign: isSet(object.sign) ? globalThis.Number(object.sign) : 0,
  8944. list: globalThis.Array.isArray(object?.list) ? object.list.map((e: any) => globalThis.Number(e)) : [],
  8945. treasure: isSet(object.treasure) ? globalThis.Boolean(object.treasure) : false,
  8946. };
  8947. },
  8948. toJSON(message: treasureGetDataRsp): unknown {
  8949. const obj: any = {};
  8950. if (message.errno !== 0) {
  8951. obj.errno = Math.round(message.errno);
  8952. }
  8953. if (message.buy !== 0) {
  8954. obj.buy = Math.round(message.buy);
  8955. }
  8956. if (message.sign !== 0) {
  8957. obj.sign = Math.round(message.sign);
  8958. }
  8959. if (message.list?.length) {
  8960. obj.list = message.list.map((e) => Math.round(e));
  8961. }
  8962. if (message.treasure !== false) {
  8963. obj.treasure = message.treasure;
  8964. }
  8965. return obj;
  8966. },
  8967. create<I extends Exact<DeepPartial<treasureGetDataRsp>, I>>(base?: I): treasureGetDataRsp {
  8968. return treasureGetDataRsp.fromPartial(base ?? ({} as any));
  8969. },
  8970. fromPartial<I extends Exact<DeepPartial<treasureGetDataRsp>, I>>(object: I): treasureGetDataRsp {
  8971. const message = createBasetreasureGetDataRsp();
  8972. message.errno = object.errno ?? 0;
  8973. message.buy = object.buy ?? 0;
  8974. message.sign = object.sign ?? 0;
  8975. message.list = object.list?.map((e) => e) || [];
  8976. message.treasure = object.treasure ?? false;
  8977. return message;
  8978. },
  8979. };
  8980. function createBasetreasureDraw(): treasureDraw {
  8981. return {};
  8982. }
  8983. export const treasureDraw = {
  8984. fromJSON(_: any): treasureDraw {
  8985. return {};
  8986. },
  8987. toJSON(_: treasureDraw): unknown {
  8988. const obj: any = {};
  8989. return obj;
  8990. },
  8991. create<I extends Exact<DeepPartial<treasureDraw>, I>>(base?: I): treasureDraw {
  8992. return treasureDraw.fromPartial(base ?? ({} as any));
  8993. },
  8994. fromPartial<I extends Exact<DeepPartial<treasureDraw>, I>>(_: I): treasureDraw {
  8995. const message = createBasetreasureDraw();
  8996. return message;
  8997. },
  8998. };
  8999. function createBasetreasureDrawRsp(): treasureDrawRsp {
  9000. return { errno: 0, pos: 0 };
  9001. }
  9002. export const treasureDrawRsp = {
  9003. fromJSON(object: any): treasureDrawRsp {
  9004. return {
  9005. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  9006. pos: isSet(object.pos) ? globalThis.Number(object.pos) : 0,
  9007. };
  9008. },
  9009. toJSON(message: treasureDrawRsp): unknown {
  9010. const obj: any = {};
  9011. if (message.errno !== 0) {
  9012. obj.errno = Math.round(message.errno);
  9013. }
  9014. if (message.pos !== 0) {
  9015. obj.pos = Math.round(message.pos);
  9016. }
  9017. return obj;
  9018. },
  9019. create<I extends Exact<DeepPartial<treasureDrawRsp>, I>>(base?: I): treasureDrawRsp {
  9020. return treasureDrawRsp.fromPartial(base ?? ({} as any));
  9021. },
  9022. fromPartial<I extends Exact<DeepPartial<treasureDrawRsp>, I>>(object: I): treasureDrawRsp {
  9023. const message = createBasetreasureDrawRsp();
  9024. message.errno = object.errno ?? 0;
  9025. message.pos = object.pos ?? 0;
  9026. return message;
  9027. },
  9028. };
  9029. function createBasetreasureSign(): treasureSign {
  9030. return {};
  9031. }
  9032. export const treasureSign = {
  9033. fromJSON(_: any): treasureSign {
  9034. return {};
  9035. },
  9036. toJSON(_: treasureSign): unknown {
  9037. const obj: any = {};
  9038. return obj;
  9039. },
  9040. create<I extends Exact<DeepPartial<treasureSign>, I>>(base?: I): treasureSign {
  9041. return treasureSign.fromPartial(base ?? ({} as any));
  9042. },
  9043. fromPartial<I extends Exact<DeepPartial<treasureSign>, I>>(_: I): treasureSign {
  9044. const message = createBasetreasureSign();
  9045. return message;
  9046. },
  9047. };
  9048. function createBasetreasureSignRsp(): treasureSignRsp {
  9049. return { errno: 0, sign: 0 };
  9050. }
  9051. export const treasureSignRsp = {
  9052. fromJSON(object: any): treasureSignRsp {
  9053. return {
  9054. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  9055. sign: isSet(object.sign) ? globalThis.Number(object.sign) : 0,
  9056. };
  9057. },
  9058. toJSON(message: treasureSignRsp): unknown {
  9059. const obj: any = {};
  9060. if (message.errno !== 0) {
  9061. obj.errno = Math.round(message.errno);
  9062. }
  9063. if (message.sign !== 0) {
  9064. obj.sign = Math.round(message.sign);
  9065. }
  9066. return obj;
  9067. },
  9068. create<I extends Exact<DeepPartial<treasureSignRsp>, I>>(base?: I): treasureSignRsp {
  9069. return treasureSignRsp.fromPartial(base ?? ({} as any));
  9070. },
  9071. fromPartial<I extends Exact<DeepPartial<treasureSignRsp>, I>>(object: I): treasureSignRsp {
  9072. const message = createBasetreasureSignRsp();
  9073. message.errno = object.errno ?? 0;
  9074. message.sign = object.sign ?? 0;
  9075. return message;
  9076. },
  9077. };
  9078. function createBasetreasureBuy(): treasureBuy {
  9079. return {};
  9080. }
  9081. export const treasureBuy = {
  9082. fromJSON(_: any): treasureBuy {
  9083. return {};
  9084. },
  9085. toJSON(_: treasureBuy): unknown {
  9086. const obj: any = {};
  9087. return obj;
  9088. },
  9089. create<I extends Exact<DeepPartial<treasureBuy>, I>>(base?: I): treasureBuy {
  9090. return treasureBuy.fromPartial(base ?? ({} as any));
  9091. },
  9092. fromPartial<I extends Exact<DeepPartial<treasureBuy>, I>>(_: I): treasureBuy {
  9093. const message = createBasetreasureBuy();
  9094. return message;
  9095. },
  9096. };
  9097. function createBasetreasureBuyRsp(): treasureBuyRsp {
  9098. return { errno: 0, buy: 0 };
  9099. }
  9100. export const treasureBuyRsp = {
  9101. fromJSON(object: any): treasureBuyRsp {
  9102. return {
  9103. errno: isSet(object.errno) ? globalThis.Number(object.errno) : 0,
  9104. buy: isSet(object.buy) ? globalThis.Number(object.buy) : 0,
  9105. };
  9106. },
  9107. toJSON(message: treasureBuyRsp): unknown {
  9108. const obj: any = {};
  9109. if (message.errno !== 0) {
  9110. obj.errno = Math.round(message.errno);
  9111. }
  9112. if (message.buy !== 0) {
  9113. obj.buy = Math.round(message.buy);
  9114. }
  9115. return obj;
  9116. },
  9117. create<I extends Exact<DeepPartial<treasureBuyRsp>, I>>(base?: I): treasureBuyRsp {
  9118. return treasureBuyRsp.fromPartial(base ?? ({} as any));
  9119. },
  9120. fromPartial<I extends Exact<DeepPartial<treasureBuyRsp>, I>>(object: I): treasureBuyRsp {
  9121. const message = createBasetreasureBuyRsp();
  9122. message.errno = object.errno ?? 0;
  9123. message.buy = object.buy ?? 0;
  9124. return message;
  9125. },
  9126. };
  9127. type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
  9128. export type DeepPartial<T> = T extends Builtin ? T
  9129. : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
  9130. : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
  9131. : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
  9132. : Partial<T>;
  9133. type KeysOfUnion<T> = T extends T ? keyof T : never;
  9134. export type Exact<P, I extends P> = P extends Builtin ? P
  9135. : P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
  9136. function isSet(value: any): boolean {
  9137. return value !== null && value !== undefined;
  9138. }