AngelScriptAPI.h 300 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921
  1. // Script API header intended to be 'force included' in IDE for AngelScript content assist / code completion
  2. #define int8 signed char
  3. #define int16 signed short
  4. #define int64 long
  5. #define uint8 unsigned char
  6. #define uint16 unsigned short
  7. #define uint64 unsigned long
  8. #define null 0
  9. // Classes
  10. class Animatable
  11. {
  12. // Methods:
  13. void ApplyAttributes();
  14. Variant GetAttribute(const String&) const;
  15. ValueAnimation GetAttributeAnimation(const String&) const;
  16. float GetAttributeAnimationSpeed(const String&) const;
  17. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  18. Variant GetAttributeDefault(const String&) const;
  19. bool Load(File, bool = false);
  20. bool Load(VectorBuffer&, bool = false);
  21. bool LoadXML(const XMLElement&, bool = false);
  22. void MarkNetworkUpdate() const;
  23. void RemoveInstanceDefault();
  24. void ResetToDefault();
  25. bool Save(File) const;
  26. bool Save(VectorBuffer&) const;
  27. bool SaveXML(XMLElement&) const;
  28. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  29. bool SetAttribute(const String&, const Variant&);
  30. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  31. void SetAttributeAnimationSpeed(const String&, float);
  32. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  33. // Properties:
  34. bool animationEnabled;
  35. /* readonly */
  36. Array<Variant> attributeDefaults;
  37. /* readonly */
  38. Array<AttributeInfo> attributeInfos;
  39. Array<Variant> attributes;
  40. /* readonly */
  41. StringHash baseType;
  42. /* readonly */
  43. String category;
  44. /* readonly */
  45. uint numAttributes;
  46. ObjectAnimation objectAnimation;
  47. /* readonly */
  48. int refs;
  49. bool temporary;
  50. /* readonly */
  51. StringHash type;
  52. /* readonly */
  53. String typeName;
  54. /* readonly */
  55. int weakRefs;
  56. };
  57. class AnimatedModel
  58. {
  59. // Methods:
  60. AnimationState AddAnimationState(Animation);
  61. void ApplyAttributes();
  62. void ApplyMaterialList(const String& = String ( ));
  63. void DrawDebugGeometry(DebugRenderer, bool);
  64. AnimationState GetAnimationState(Animation) const;
  65. AnimationState GetAnimationState(uint) const;
  66. Variant GetAttribute(const String&) const;
  67. ValueAnimation GetAttributeAnimation(const String&) const;
  68. float GetAttributeAnimationSpeed(const String&) const;
  69. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  70. Variant GetAttributeDefault(const String&) const;
  71. float GetMorphWeight(uint) const;
  72. bool IsInView(Camera) const;
  73. bool Load(File, bool = false);
  74. bool Load(VectorBuffer&, bool = false);
  75. bool LoadXML(const XMLElement&, bool = false);
  76. void MarkNetworkUpdate() const;
  77. void Remove();
  78. void RemoveAllAnimationStates();
  79. void RemoveAnimationState(Animation);
  80. void RemoveAnimationState(AnimationState);
  81. void RemoveAnimationState(const String&);
  82. void RemoveAnimationState(uint);
  83. void RemoveInstanceDefault();
  84. void ResetMorphWeights();
  85. void ResetToDefault();
  86. bool Save(File) const;
  87. bool Save(VectorBuffer&) const;
  88. bool SaveXML(XMLElement&) const;
  89. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  90. bool SetAttribute(const String&, const Variant&);
  91. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  92. void SetAttributeAnimationSpeed(const String&, float);
  93. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  94. void SetMorphWeight(uint, float);
  95. // Properties:
  96. bool animationEnabled;
  97. float animationLodBias;
  98. /* readonly */
  99. Array<AnimationState> animationStates;
  100. /* readonly */
  101. Array<Variant> attributeDefaults;
  102. /* readonly */
  103. Array<AttributeInfo> attributeInfos;
  104. Array<Variant> attributes;
  105. /* readonly */
  106. StringHash baseType;
  107. /* readonly */
  108. BoundingBox boundingBox;
  109. bool castShadows;
  110. /* readonly */
  111. String category;
  112. float drawDistance;
  113. bool enabled;
  114. /* readonly */
  115. bool enabledEffective;
  116. /* readonly */
  117. uint id;
  118. /* readonly */
  119. bool inView;
  120. uint lightMask;
  121. float lodBias;
  122. /* writeonly */
  123. Material material;
  124. Array<Material> materials;
  125. uint maxLights;
  126. Model model;
  127. /* readonly */
  128. Array<String> morphNames;
  129. Array<float> morphWeights;
  130. /* readonly */
  131. Node node;
  132. /* readonly */
  133. uint numAnimationStates;
  134. /* readonly */
  135. uint numAttributes;
  136. /* readonly */
  137. uint numGeometries;
  138. /* readonly */
  139. uint numMorphs;
  140. ObjectAnimation objectAnimation;
  141. bool occludee;
  142. bool occluder;
  143. /* readonly */
  144. int refs;
  145. float shadowDistance;
  146. uint shadowMask;
  147. /* readonly */
  148. Skeleton skeleton;
  149. bool temporary;
  150. /* readonly */
  151. StringHash type;
  152. /* readonly */
  153. String typeName;
  154. bool updateInvisible;
  155. uint viewMask;
  156. /* readonly */
  157. int weakRefs;
  158. /* readonly */
  159. BoundingBox worldBoundingBox;
  160. /* readonly */
  161. Zone zone;
  162. uint zoneMask;
  163. };
  164. class AnimatedSprite2D
  165. {
  166. // Methods:
  167. void ApplyAttributes();
  168. void DrawDebugGeometry(DebugRenderer, bool);
  169. Variant GetAttribute(const String&) const;
  170. ValueAnimation GetAttributeAnimation(const String&) const;
  171. float GetAttributeAnimationSpeed(const String&) const;
  172. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  173. Variant GetAttributeDefault(const String&) const;
  174. bool IsInView(Camera) const;
  175. bool Load(File, bool = false);
  176. bool Load(VectorBuffer&, bool = false);
  177. bool LoadXML(const XMLElement&, bool = false);
  178. void MarkNetworkUpdate() const;
  179. void Remove();
  180. void RemoveInstanceDefault();
  181. void ResetToDefault();
  182. bool Save(File) const;
  183. bool Save(VectorBuffer&) const;
  184. bool SaveXML(XMLElement&) const;
  185. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  186. void SetAnimation(AnimationSet2D, const String&, LoopMode2D = LM_DEFAULT);
  187. void SetAnimation(const String&, LoopMode2D = LM_DEFAULT);
  188. bool SetAttribute(const String&, const Variant&);
  189. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  190. void SetAttributeAnimationSpeed(const String&, float);
  191. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  192. void SetFlip(bool, bool);
  193. // Properties:
  194. float alpha;
  195. String animation;
  196. bool animationEnabled;
  197. AnimationSet2D animationSet;
  198. /* readonly */
  199. Array<Variant> attributeDefaults;
  200. /* readonly */
  201. Array<AttributeInfo> attributeInfos;
  202. Array<Variant> attributes;
  203. /* readonly */
  204. StringHash baseType;
  205. BlendMode blendMode;
  206. /* readonly */
  207. BoundingBox boundingBox;
  208. bool castShadows;
  209. /* readonly */
  210. String category;
  211. Color color;
  212. float drawDistance;
  213. bool enabled;
  214. /* readonly */
  215. bool enabledEffective;
  216. bool flipX;
  217. bool flipY;
  218. Vector2 hotSpot;
  219. /* readonly */
  220. uint id;
  221. /* readonly */
  222. bool inView;
  223. int layer;
  224. uint lightMask;
  225. float lodBias;
  226. LoopMode2D loopMode;
  227. uint maxLights;
  228. /* readonly */
  229. Node node;
  230. /* readonly */
  231. uint numAttributes;
  232. ObjectAnimation objectAnimation;
  233. bool occludee;
  234. bool occluder;
  235. int orderInLayer;
  236. /* readonly */
  237. int refs;
  238. float shadowDistance;
  239. uint shadowMask;
  240. float speed;
  241. Sprite2D sprite;
  242. bool temporary;
  243. Texture2D texture;
  244. /* readonly */
  245. StringHash type;
  246. /* readonly */
  247. String typeName;
  248. bool useHotSpot;
  249. uint viewMask;
  250. /* readonly */
  251. int weakRefs;
  252. /* readonly */
  253. BoundingBox worldBoundingBox;
  254. uint zoneMask;
  255. };
  256. class Animation
  257. {
  258. // Methods:
  259. void AddTrigger(float, bool, const Variant&);
  260. bool Load(File);
  261. bool Load(VectorBuffer&);
  262. void RemoveAllTriggers();
  263. void RemoveTrigger(uint);
  264. bool Save(File) const;
  265. bool Save(VectorBuffer&) const;
  266. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  267. // Properties:
  268. /* readonly */
  269. String animationName;
  270. /* readonly */
  271. StringHash baseType;
  272. /* readonly */
  273. String category;
  274. /* readonly */
  275. float length;
  276. /* readonly */
  277. uint memoryUse;
  278. String name;
  279. /* readonly */
  280. uint numTracks;
  281. uint numTriggers;
  282. /* readonly */
  283. int refs;
  284. /* readonly */
  285. Array<AnimationTriggerPoint> triggers;
  286. /* readonly */
  287. StringHash type;
  288. /* readonly */
  289. String typeName;
  290. /* readonly */
  291. uint useTimer;
  292. /* readonly */
  293. int weakRefs;
  294. };
  295. class Animation2D
  296. {
  297. // Properties:
  298. /* readonly */
  299. float length;
  300. /* readonly */
  301. bool looped;
  302. /* readonly */
  303. String name;
  304. /* readonly */
  305. int refs;
  306. /* readonly */
  307. int weakRefs;
  308. };
  309. class AnimationController
  310. {
  311. // Methods:
  312. void ApplyAttributes();
  313. void DrawDebugGeometry(DebugRenderer, bool);
  314. bool Fade(const String&, float, float);
  315. bool FadeOthers(const String&, float, float);
  316. AnimationState GetAnimationState(StringHash) const;
  317. AnimationState GetAnimationState(const String&) const;
  318. Variant GetAttribute(const String&) const;
  319. ValueAnimation GetAttributeAnimation(const String&) const;
  320. float GetAttributeAnimationSpeed(const String&) const;
  321. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  322. Variant GetAttributeDefault(const String&) const;
  323. float GetAutoFade(const String&) const;
  324. float GetFadeTarget(const String&) const;
  325. uint8 GetLayer(const String&) const;
  326. float GetLength(const String&) const;
  327. bool GetLooped(const String&) const;
  328. float GetSpeed(const String&) const;
  329. float GetTime(const String&) const;
  330. float GetWeight(const String&) const;
  331. bool IsFadingIn(const String&) const;
  332. bool IsFadingOut(const String&) const;
  333. bool IsPlaying(const String&) const;
  334. bool Load(File, bool = false);
  335. bool Load(VectorBuffer&, bool = false);
  336. bool LoadXML(const XMLElement&, bool = false);
  337. void MarkNetworkUpdate() const;
  338. bool Play(const String&, uint8, bool, float = 0.0f);
  339. bool PlayExclusive(const String&, uint8, bool, float = 0.0f);
  340. void Remove();
  341. void RemoveInstanceDefault();
  342. void ResetToDefault();
  343. bool Save(File) const;
  344. bool Save(VectorBuffer&) const;
  345. bool SaveXML(XMLElement&) const;
  346. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  347. bool SetAttribute(const String&, const Variant&);
  348. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  349. void SetAttributeAnimationSpeed(const String&, float);
  350. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  351. bool SetAutoFade(const String&, float);
  352. bool SetLayer(const String&, uint8);
  353. bool SetLooped(const String&, bool);
  354. bool SetSpeed(const String&, float);
  355. bool SetStartBone(const String&, const String&);
  356. bool SetTime(const String&, float);
  357. bool SetWeight(const String&, float);
  358. void Stop(const String&, float = 0.0f);
  359. void StopAll(float = 0.0f);
  360. void StopLayer(uint8, float = 0.0f);
  361. const String& GetStartBone(const String&) const;
  362. // Properties:
  363. bool animationEnabled;
  364. /* readonly */
  365. Array<Variant> attributeDefaults;
  366. /* readonly */
  367. Array<AttributeInfo> attributeInfos;
  368. Array<Variant> attributes;
  369. /* readonly */
  370. StringHash baseType;
  371. /* readonly */
  372. String category;
  373. bool enabled;
  374. /* readonly */
  375. bool enabledEffective;
  376. /* readonly */
  377. uint id;
  378. /* readonly */
  379. Node node;
  380. /* readonly */
  381. uint numAttributes;
  382. ObjectAnimation objectAnimation;
  383. /* readonly */
  384. int refs;
  385. bool temporary;
  386. /* readonly */
  387. StringHash type;
  388. /* readonly */
  389. String typeName;
  390. /* readonly */
  391. int weakRefs;
  392. };
  393. class AnimationSet2D
  394. {
  395. // Methods:
  396. Animation2D GetAnimation(const String&) const;
  397. Animation2D GetAnimation(uint) const;
  398. bool Load(File);
  399. bool Load(VectorBuffer&);
  400. bool Save(File) const;
  401. bool Save(VectorBuffer&) const;
  402. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  403. // Properties:
  404. /* readonly */
  405. StringHash baseType;
  406. /* readonly */
  407. String category;
  408. /* readonly */
  409. uint memoryUse;
  410. String name;
  411. /* readonly */
  412. uint numAnimations;
  413. /* readonly */
  414. int refs;
  415. /* readonly */
  416. StringHash type;
  417. /* readonly */
  418. String typeName;
  419. /* readonly */
  420. uint useTimer;
  421. /* readonly */
  422. int weakRefs;
  423. };
  424. class AnimationState
  425. {
  426. // Methods:
  427. void AddTime(float);
  428. void AddWeight(float);
  429. void Apply();
  430. float GetBoneWeight(StringHash) const;
  431. float GetBoneWeight(uint) const;
  432. uint GetTrackIndex(StringHash) const;
  433. uint GetTrackIndex(const String&) const;
  434. void SetBoneWeight(StringHash, float, bool = false);
  435. void SetBoneWeight(const String&, float, bool = false);
  436. void SetBoneWeight(uint, float, bool = false);
  437. // Properties:
  438. /* readonly */
  439. Animation animation;
  440. Array<float> boneWeights;
  441. /* readonly */
  442. bool enabled;
  443. uint8 layer;
  444. /* readonly */
  445. float length;
  446. bool looped;
  447. /* readonly */
  448. AnimatedModel model;
  449. /* readonly */
  450. Node node;
  451. /* readonly */
  452. int refs;
  453. Bone startBone;
  454. float time;
  455. /* readonly */
  456. int weakRefs;
  457. float weight;
  458. };
  459. class AnimationTriggerPoint
  460. {
  461. // Properties:
  462. Variant data;
  463. float time;
  464. };
  465. template <class T> class Array
  466. {
  467. // Methods:
  468. void Clear();
  469. void Erase(uint);
  470. int Find(const T&) const;
  471. int Find(uint, const T&) const;
  472. int FindByRef(const T&) const;
  473. int FindByRef(uint, const T&) const;
  474. void Insert(uint, const T&);
  475. void Pop();
  476. void Push(const T&);
  477. void Reserve(uint);
  478. void Resize(uint);
  479. void Reverse();
  480. void Sort();
  481. void Sort(uint, uint);
  482. void SortReverse();
  483. void SortReverse(uint, uint);
  484. // Properties:
  485. /* readonly */
  486. bool empty;
  487. uint length;
  488. };
  489. class AttributeInfo
  490. {
  491. // Properties:
  492. Variant defaultValue;
  493. /* readonly */
  494. Array<String> enumNames;
  495. uint mode;
  496. String name;
  497. VariantType type;
  498. };
  499. class Audio
  500. {
  501. // Methods:
  502. bool HasMasterGain(const String&) const;
  503. bool Play();
  504. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  505. void SetMode(int, int, bool, bool = true);
  506. void Stop();
  507. // Properties:
  508. /* readonly */
  509. StringHash baseType;
  510. /* readonly */
  511. String category;
  512. /* readonly */
  513. bool initialized;
  514. /* readonly */
  515. bool interpolation;
  516. SoundListener listener;
  517. Array<float> masterGain;
  518. /* readonly */
  519. int mixRate;
  520. /* readonly */
  521. bool playing;
  522. /* readonly */
  523. int refs;
  524. /* readonly */
  525. uint sampleSize;
  526. /* readonly */
  527. bool stereo;
  528. /* readonly */
  529. StringHash type;
  530. /* readonly */
  531. String typeName;
  532. /* readonly */
  533. int weakRefs;
  534. };
  535. class BiasParameters
  536. {
  537. // Properties:
  538. float constantBias;
  539. float slopeScaledBias;
  540. };
  541. class Billboard
  542. {
  543. // Properties:
  544. Color color;
  545. bool enabled;
  546. Vector3 position;
  547. float rotation;
  548. Vector2 size;
  549. Rect uv;
  550. };
  551. class BillboardSet
  552. {
  553. // Methods:
  554. void ApplyAttributes();
  555. void Commit();
  556. void DrawDebugGeometry(DebugRenderer, bool);
  557. Variant GetAttribute(const String&) const;
  558. ValueAnimation GetAttributeAnimation(const String&) const;
  559. float GetAttributeAnimationSpeed(const String&) const;
  560. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  561. Variant GetAttributeDefault(const String&) const;
  562. bool IsInView(Camera) const;
  563. bool Load(File, bool = false);
  564. bool Load(VectorBuffer&, bool = false);
  565. bool LoadXML(const XMLElement&, bool = false);
  566. void MarkNetworkUpdate() const;
  567. void Remove();
  568. void RemoveInstanceDefault();
  569. void ResetToDefault();
  570. bool Save(File) const;
  571. bool Save(VectorBuffer&) const;
  572. bool SaveXML(XMLElement&) const;
  573. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  574. bool SetAttribute(const String&, const Variant&);
  575. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  576. void SetAttributeAnimationSpeed(const String&, float);
  577. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  578. // Properties:
  579. bool animationEnabled;
  580. float animationLodBias;
  581. /* readonly */
  582. Array<Variant> attributeDefaults;
  583. /* readonly */
  584. Array<AttributeInfo> attributeInfos;
  585. Array<Variant> attributes;
  586. /* readonly */
  587. StringHash baseType;
  588. /* readonly */
  589. Array<Billboard> billboards;
  590. /* readonly */
  591. BoundingBox boundingBox;
  592. bool castShadows;
  593. /* readonly */
  594. String category;
  595. float drawDistance;
  596. bool enabled;
  597. /* readonly */
  598. bool enabledEffective;
  599. FaceCameraMode faceCameraMode;
  600. /* readonly */
  601. uint id;
  602. /* readonly */
  603. bool inView;
  604. uint lightMask;
  605. float lodBias;
  606. Material material;
  607. uint maxLights;
  608. /* readonly */
  609. Node node;
  610. /* readonly */
  611. uint numAttributes;
  612. uint numBillboards;
  613. ObjectAnimation objectAnimation;
  614. bool occludee;
  615. bool occluder;
  616. /* readonly */
  617. int refs;
  618. bool relative;
  619. bool scaled;
  620. float shadowDistance;
  621. uint shadowMask;
  622. bool sorted;
  623. bool temporary;
  624. /* readonly */
  625. StringHash type;
  626. /* readonly */
  627. String typeName;
  628. uint viewMask;
  629. /* readonly */
  630. int weakRefs;
  631. /* readonly */
  632. BoundingBox worldBoundingBox;
  633. /* readonly */
  634. Zone zone;
  635. uint zoneMask;
  636. };
  637. class Bone
  638. {
  639. // Properties:
  640. bool animated;
  641. BoundingBox boundingBox;
  642. Vector3 initialPosition;
  643. Quaternion initialRotation;
  644. Vector3 initialScale;
  645. String name;
  646. Node node;
  647. float radius;
  648. };
  649. class BorderImage
  650. {
  651. // Methods:
  652. void AddChild(UIElement);
  653. void ApplyAttributes();
  654. void BringToFront();
  655. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  656. void DisableLayoutUpdate();
  657. IntVector2 ElementToScreen(const IntVector2&);
  658. void EnableLayoutUpdate();
  659. uint FindChild(UIElement) const;
  660. Variant GetAttribute(const String&) const;
  661. ValueAnimation GetAttributeAnimation(const String&) const;
  662. float GetAttributeAnimationSpeed(const String&) const;
  663. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  664. Variant GetAttributeDefault(const String&) const;
  665. UIElement GetChild(const String&, bool = false) const;
  666. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  667. Array<UIElement> GetChildren(bool = false) const;
  668. UIElement GetElementEventSender() const;
  669. uint GetNumChildren(bool) const;
  670. void InsertChild(uint, UIElement);
  671. bool IsInside(IntVector2, bool);
  672. bool IsInsideCombined(IntVector2, bool);
  673. bool Load(File, bool = false);
  674. bool Load(VectorBuffer&, bool = false);
  675. bool LoadChildXML(XMLFile, XMLFile = null);
  676. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  677. bool LoadXML(File);
  678. bool LoadXML(VectorBuffer&);
  679. bool LoadXML(XMLFile, XMLFile);
  680. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  681. bool LoadXML(const XMLElement&, bool = false);
  682. void MarkNetworkUpdate() const;
  683. void Remove();
  684. void RemoveAllChildren();
  685. void RemoveChild(UIElement, uint = 0);
  686. void RemoveChild(uint);
  687. void RemoveInstanceDefault();
  688. void ResetDeepEnabled();
  689. void ResetToDefault();
  690. bool Save(File) const;
  691. bool Save(VectorBuffer&) const;
  692. bool SaveXML(File);
  693. bool SaveXML(VectorBuffer&);
  694. bool SaveXML(XMLElement&) const;
  695. IntVector2 ScreenToElement(const IntVector2&);
  696. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  697. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  698. bool SetAttribute(const String&, const Variant&);
  699. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  700. void SetAttributeAnimationSpeed(const String&, float);
  701. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  702. void SetDeepEnabled(bool);
  703. void SetEnabledRecursive(bool);
  704. void SetFixedHeight(int);
  705. void SetFixedSize(int, int);
  706. void SetFixedWidth(int);
  707. void SetFullImageRect();
  708. void SetHoverOffset(int, int);
  709. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  710. void SetMaxSize(int, int);
  711. void SetMinSize(int, int);
  712. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  713. void SetPosition(int, int);
  714. void SetSize(int, int);
  715. bool SetStyle(const String&, XMLFile = null);
  716. bool SetStyle(const XMLElement&);
  717. bool SetStyleAuto(XMLFile = null);
  718. void UpdateLayout();
  719. const Variant& GetVar(const StringHash&);
  720. // Properties:
  721. bool animationEnabled;
  722. /* readonly */
  723. Array<Variant> attributeDefaults;
  724. /* readonly */
  725. Array<AttributeInfo> attributeInfos;
  726. Array<Variant> attributes;
  727. /* readonly */
  728. StringHash baseType;
  729. BlendMode blendMode;
  730. IntRect border;
  731. bool bringToBack;
  732. bool bringToFront;
  733. /* readonly */
  734. String category;
  735. /* readonly */
  736. IntVector2 childOffset;
  737. /* readonly */
  738. Array<UIElement> children;
  739. IntRect clipBorder;
  740. bool clipChildren;
  741. /* writeonly */
  742. Color color;
  743. /* readonly */
  744. bool colorGradient;
  745. Array<Color> colors;
  746. /* readonly */
  747. IntRect combinedScreenRect;
  748. XMLFile defaultStyle;
  749. /* readonly */
  750. float derivedOpacity;
  751. /* readonly */
  752. uint dragButtonCombo;
  753. /* readonly */
  754. int dragButtonCount;
  755. uint dragDropMode;
  756. bool editable;
  757. bool elementEventSender;
  758. bool enabled;
  759. /* readonly */
  760. bool enabledSelf;
  761. /* readonly */
  762. bool fixedHeight;
  763. /* readonly */
  764. bool fixedSize;
  765. /* readonly */
  766. bool fixedWidth;
  767. bool focus;
  768. FocusMode focusMode;
  769. int height;
  770. HorizontalAlignment horizontalAlignment;
  771. IntVector2 hoverOffset;
  772. /* readonly */
  773. bool hovering;
  774. IntRect imageBorder;
  775. IntRect imageRect;
  776. int indent;
  777. int indentSpacing;
  778. /* readonly */
  779. int indentWidth;
  780. bool internal;
  781. IntRect layoutBorder;
  782. Vector2 layoutFlexScale;
  783. LayoutMode layoutMode;
  784. int layoutSpacing;
  785. int maxHeight;
  786. IntVector2 maxSize;
  787. int maxWidth;
  788. int minHeight;
  789. IntVector2 minSize;
  790. int minWidth;
  791. String name;
  792. /* readonly */
  793. uint numAllChildren;
  794. /* readonly */
  795. uint numAttributes;
  796. /* readonly */
  797. uint numChildren;
  798. ObjectAnimation objectAnimation;
  799. float opacity;
  800. UIElement parent;
  801. IntVector2 position;
  802. int priority;
  803. /* readonly */
  804. int refs;
  805. /* readonly */
  806. UIElement root;
  807. /* readonly */
  808. IntVector2 screenPosition;
  809. bool selected;
  810. IntVector2 size;
  811. bool sortChildren;
  812. String style;
  813. bool temporary;
  814. Texture texture;
  815. bool tiled;
  816. TraversalMode traversalMode;
  817. /* readonly */
  818. StringHash type;
  819. /* readonly */
  820. String typeName;
  821. bool useDerivedOpacity;
  822. /* readonly */
  823. VariantMap vars;
  824. VerticalAlignment verticalAlignment;
  825. bool visible;
  826. /* readonly */
  827. int weakRefs;
  828. int width;
  829. };
  830. class BoundingBox
  831. {
  832. // Methods:
  833. void Clear();
  834. void Clip(const BoundingBox&);
  835. void Define(const BoundingBox&);
  836. void Define(const Frustum&);
  837. void Define(const Polyhedron&);
  838. void Define(const Sphere&);
  839. void Define(const Vector3&);
  840. void Define(const Vector3&, const Vector3&);
  841. void Define(float, float);
  842. Intersection IsInside(const BoundingBox&) const;
  843. Intersection IsInside(const Sphere&) const;
  844. Intersection IsInside(const Vector3&) const;
  845. void Merge(const BoundingBox&);
  846. void Merge(const Frustum&);
  847. void Merge(const Polyhedron&);
  848. void Merge(const Sphere&);
  849. void Merge(const Vector3&);
  850. Rect Projected(const Matrix4&) const;
  851. String ToString() const;
  852. void Transform(const Matrix3&);
  853. void Transform(const Matrix3x4&);
  854. BoundingBox Transformed(const Matrix3&) const;
  855. BoundingBox Transformed(const Matrix3x4&) const;
  856. // Properties:
  857. /* readonly */
  858. Vector3 center;
  859. bool defined;
  860. /* readonly */
  861. Vector3 halfSize;
  862. Vector3 max;
  863. Vector3 min;
  864. /* readonly */
  865. Vector3 size;
  866. };
  867. class Button
  868. {
  869. // Methods:
  870. void AddChild(UIElement);
  871. void ApplyAttributes();
  872. void BringToFront();
  873. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  874. void DisableLayoutUpdate();
  875. IntVector2 ElementToScreen(const IntVector2&);
  876. void EnableLayoutUpdate();
  877. uint FindChild(UIElement) const;
  878. Variant GetAttribute(const String&) const;
  879. ValueAnimation GetAttributeAnimation(const String&) const;
  880. float GetAttributeAnimationSpeed(const String&) const;
  881. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  882. Variant GetAttributeDefault(const String&) const;
  883. UIElement GetChild(const String&, bool = false) const;
  884. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  885. Array<UIElement> GetChildren(bool = false) const;
  886. UIElement GetElementEventSender() const;
  887. uint GetNumChildren(bool) const;
  888. void InsertChild(uint, UIElement);
  889. bool IsInside(IntVector2, bool);
  890. bool IsInsideCombined(IntVector2, bool);
  891. bool Load(File, bool = false);
  892. bool Load(VectorBuffer&, bool = false);
  893. bool LoadChildXML(XMLFile, XMLFile = null);
  894. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  895. bool LoadXML(File);
  896. bool LoadXML(VectorBuffer&);
  897. bool LoadXML(XMLFile, XMLFile);
  898. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  899. bool LoadXML(const XMLElement&, bool = false);
  900. void MarkNetworkUpdate() const;
  901. void Remove();
  902. void RemoveAllChildren();
  903. void RemoveChild(UIElement, uint = 0);
  904. void RemoveChild(uint);
  905. void RemoveInstanceDefault();
  906. void ResetDeepEnabled();
  907. void ResetToDefault();
  908. bool Save(File) const;
  909. bool Save(VectorBuffer&) const;
  910. bool SaveXML(File);
  911. bool SaveXML(VectorBuffer&);
  912. bool SaveXML(XMLElement&) const;
  913. IntVector2 ScreenToElement(const IntVector2&);
  914. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  915. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  916. bool SetAttribute(const String&, const Variant&);
  917. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  918. void SetAttributeAnimationSpeed(const String&, float);
  919. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  920. void SetDeepEnabled(bool);
  921. void SetEnabledRecursive(bool);
  922. void SetFixedHeight(int);
  923. void SetFixedSize(int, int);
  924. void SetFixedWidth(int);
  925. void SetFullImageRect();
  926. void SetHoverOffset(int, int);
  927. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  928. void SetMaxSize(int, int);
  929. void SetMinSize(int, int);
  930. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  931. void SetPosition(int, int);
  932. void SetPressedChildOffset(int, int);
  933. void SetPressedOffset(int, int);
  934. void SetRepeat(float, float);
  935. void SetSize(int, int);
  936. bool SetStyle(const String&, XMLFile = null);
  937. bool SetStyle(const XMLElement&);
  938. bool SetStyleAuto(XMLFile = null);
  939. void UpdateLayout();
  940. const Variant& GetVar(const StringHash&);
  941. // Properties:
  942. bool animationEnabled;
  943. /* readonly */
  944. Array<Variant> attributeDefaults;
  945. /* readonly */
  946. Array<AttributeInfo> attributeInfos;
  947. Array<Variant> attributes;
  948. /* readonly */
  949. StringHash baseType;
  950. BlendMode blendMode;
  951. IntRect border;
  952. bool bringToBack;
  953. bool bringToFront;
  954. /* readonly */
  955. String category;
  956. /* readonly */
  957. IntVector2 childOffset;
  958. /* readonly */
  959. Array<UIElement> children;
  960. IntRect clipBorder;
  961. bool clipChildren;
  962. /* writeonly */
  963. Color color;
  964. /* readonly */
  965. bool colorGradient;
  966. Array<Color> colors;
  967. /* readonly */
  968. IntRect combinedScreenRect;
  969. XMLFile defaultStyle;
  970. /* readonly */
  971. float derivedOpacity;
  972. /* readonly */
  973. uint dragButtonCombo;
  974. /* readonly */
  975. int dragButtonCount;
  976. uint dragDropMode;
  977. bool editable;
  978. bool elementEventSender;
  979. bool enabled;
  980. /* readonly */
  981. bool enabledSelf;
  982. /* readonly */
  983. bool fixedHeight;
  984. /* readonly */
  985. bool fixedSize;
  986. /* readonly */
  987. bool fixedWidth;
  988. bool focus;
  989. FocusMode focusMode;
  990. int height;
  991. HorizontalAlignment horizontalAlignment;
  992. IntVector2 hoverOffset;
  993. /* readonly */
  994. bool hovering;
  995. IntRect imageBorder;
  996. IntRect imageRect;
  997. int indent;
  998. int indentSpacing;
  999. /* readonly */
  1000. int indentWidth;
  1001. bool internal;
  1002. IntRect layoutBorder;
  1003. Vector2 layoutFlexScale;
  1004. LayoutMode layoutMode;
  1005. int layoutSpacing;
  1006. int maxHeight;
  1007. IntVector2 maxSize;
  1008. int maxWidth;
  1009. int minHeight;
  1010. IntVector2 minSize;
  1011. int minWidth;
  1012. String name;
  1013. /* readonly */
  1014. uint numAllChildren;
  1015. /* readonly */
  1016. uint numAttributes;
  1017. /* readonly */
  1018. uint numChildren;
  1019. ObjectAnimation objectAnimation;
  1020. float opacity;
  1021. UIElement parent;
  1022. IntVector2 position;
  1023. /* readonly */
  1024. bool pressed;
  1025. IntVector2 pressedChildOffset;
  1026. IntVector2 pressedOffset;
  1027. int priority;
  1028. /* readonly */
  1029. int refs;
  1030. float repeatDelay;
  1031. float repeatRate;
  1032. /* readonly */
  1033. UIElement root;
  1034. /* readonly */
  1035. IntVector2 screenPosition;
  1036. bool selected;
  1037. IntVector2 size;
  1038. bool sortChildren;
  1039. String style;
  1040. bool temporary;
  1041. Texture texture;
  1042. bool tiled;
  1043. TraversalMode traversalMode;
  1044. /* readonly */
  1045. StringHash type;
  1046. /* readonly */
  1047. String typeName;
  1048. bool useDerivedOpacity;
  1049. /* readonly */
  1050. VariantMap vars;
  1051. VerticalAlignment verticalAlignment;
  1052. bool visible;
  1053. /* readonly */
  1054. int weakRefs;
  1055. int width;
  1056. };
  1057. class Camera
  1058. {
  1059. // Methods:
  1060. void ApplyAttributes();
  1061. void DrawDebugGeometry(DebugRenderer, bool);
  1062. Variant GetAttribute(const String&) const;
  1063. ValueAnimation GetAttributeAnimation(const String&) const;
  1064. float GetAttributeAnimationSpeed(const String&) const;
  1065. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1066. Variant GetAttributeDefault(const String&) const;
  1067. float GetDistance(const Vector3&) const;
  1068. float GetDistanceSquared(const Vector3&) const;
  1069. Ray GetScreenRay(float, float) const;
  1070. Frustum GetSplitFrustum(float, float) const;
  1071. bool Load(File, bool = false);
  1072. bool Load(VectorBuffer&, bool = false);
  1073. bool LoadXML(const XMLElement&, bool = false);
  1074. void MarkNetworkUpdate() const;
  1075. void Remove();
  1076. void RemoveInstanceDefault();
  1077. void ResetToDefault();
  1078. bool Save(File) const;
  1079. bool Save(VectorBuffer&) const;
  1080. bool SaveXML(XMLElement&) const;
  1081. Vector3 ScreenToWorldPoint(const Vector3&) const;
  1082. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1083. bool SetAttribute(const String&, const Variant&);
  1084. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1085. void SetAttributeAnimationSpeed(const String&, float);
  1086. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1087. void SetOrthoSize(const Vector2&);
  1088. Vector2 WorldToScreenPoint(const Vector3&) const;
  1089. // Properties:
  1090. bool animationEnabled;
  1091. float aspectRatio;
  1092. /* readonly */
  1093. Array<Variant> attributeDefaults;
  1094. /* readonly */
  1095. Array<AttributeInfo> attributeInfos;
  1096. Array<Variant> attributes;
  1097. bool autoAspectRatio;
  1098. /* readonly */
  1099. StringHash baseType;
  1100. /* readonly */
  1101. String category;
  1102. Plane clipPlane;
  1103. /* readonly */
  1104. Matrix3x4 effectiveWorldTransform;
  1105. bool enabled;
  1106. /* readonly */
  1107. bool enabledEffective;
  1108. float farClip;
  1109. FillMode fillMode;
  1110. float fov;
  1111. /* readonly */
  1112. Frustum frustum;
  1113. /* readonly */
  1114. float halfViewSize;
  1115. /* readonly */
  1116. uint id;
  1117. float lodBias;
  1118. float nearClip;
  1119. /* readonly */
  1120. Node node;
  1121. /* readonly */
  1122. uint numAttributes;
  1123. ObjectAnimation objectAnimation;
  1124. float orthoSize;
  1125. bool orthographic;
  1126. /* readonly */
  1127. Matrix4 projection;
  1128. Vector2 projectionOffset;
  1129. Plane reflectionPlane;
  1130. /* readonly */
  1131. int refs;
  1132. bool temporary;
  1133. /* readonly */
  1134. StringHash type;
  1135. /* readonly */
  1136. String typeName;
  1137. bool useClipping;
  1138. bool useReflection;
  1139. /* readonly */
  1140. Matrix3x4 view;
  1141. uint viewMask;
  1142. uint viewOverrideFlags;
  1143. /* readonly */
  1144. Frustum viewSpaceFrustum;
  1145. /* readonly */
  1146. int weakRefs;
  1147. float zoom;
  1148. };
  1149. class CascadeParameters
  1150. {
  1151. // Properties:
  1152. float biasAutoAdjust;
  1153. float fadeStart;
  1154. float split1;
  1155. float split2;
  1156. float split3;
  1157. float split4;
  1158. };
  1159. class CheckBox
  1160. {
  1161. // Methods:
  1162. void AddChild(UIElement);
  1163. void ApplyAttributes();
  1164. void BringToFront();
  1165. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  1166. void DisableLayoutUpdate();
  1167. IntVector2 ElementToScreen(const IntVector2&);
  1168. void EnableLayoutUpdate();
  1169. uint FindChild(UIElement) const;
  1170. Variant GetAttribute(const String&) const;
  1171. ValueAnimation GetAttributeAnimation(const String&) const;
  1172. float GetAttributeAnimationSpeed(const String&) const;
  1173. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1174. Variant GetAttributeDefault(const String&) const;
  1175. UIElement GetChild(const String&, bool = false) const;
  1176. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  1177. Array<UIElement> GetChildren(bool = false) const;
  1178. UIElement GetElementEventSender() const;
  1179. uint GetNumChildren(bool) const;
  1180. void InsertChild(uint, UIElement);
  1181. bool IsInside(IntVector2, bool);
  1182. bool IsInsideCombined(IntVector2, bool);
  1183. bool Load(File, bool = false);
  1184. bool Load(VectorBuffer&, bool = false);
  1185. bool LoadChildXML(XMLFile, XMLFile = null);
  1186. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  1187. bool LoadXML(File);
  1188. bool LoadXML(VectorBuffer&);
  1189. bool LoadXML(XMLFile, XMLFile);
  1190. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  1191. bool LoadXML(const XMLElement&, bool = false);
  1192. void MarkNetworkUpdate() const;
  1193. void Remove();
  1194. void RemoveAllChildren();
  1195. void RemoveChild(UIElement, uint = 0);
  1196. void RemoveChild(uint);
  1197. void RemoveInstanceDefault();
  1198. void ResetDeepEnabled();
  1199. void ResetToDefault();
  1200. bool Save(File) const;
  1201. bool Save(VectorBuffer&) const;
  1202. bool SaveXML(File);
  1203. bool SaveXML(VectorBuffer&);
  1204. bool SaveXML(XMLElement&) const;
  1205. IntVector2 ScreenToElement(const IntVector2&);
  1206. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1207. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  1208. bool SetAttribute(const String&, const Variant&);
  1209. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1210. void SetAttributeAnimationSpeed(const String&, float);
  1211. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1212. void SetCheckedOffset(int, int);
  1213. void SetDeepEnabled(bool);
  1214. void SetEnabledRecursive(bool);
  1215. void SetFixedHeight(int);
  1216. void SetFixedSize(int, int);
  1217. void SetFixedWidth(int);
  1218. void SetFullImageRect();
  1219. void SetHoverOffset(int, int);
  1220. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  1221. void SetMaxSize(int, int);
  1222. void SetMinSize(int, int);
  1223. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  1224. void SetPosition(int, int);
  1225. void SetSize(int, int);
  1226. bool SetStyle(const String&, XMLFile = null);
  1227. bool SetStyle(const XMLElement&);
  1228. bool SetStyleAuto(XMLFile = null);
  1229. void UpdateLayout();
  1230. const Variant& GetVar(const StringHash&);
  1231. // Properties:
  1232. bool animationEnabled;
  1233. /* readonly */
  1234. Array<Variant> attributeDefaults;
  1235. /* readonly */
  1236. Array<AttributeInfo> attributeInfos;
  1237. Array<Variant> attributes;
  1238. /* readonly */
  1239. StringHash baseType;
  1240. BlendMode blendMode;
  1241. IntRect border;
  1242. bool bringToBack;
  1243. bool bringToFront;
  1244. /* readonly */
  1245. String category;
  1246. bool checked;
  1247. IntVector2 checkedOffset;
  1248. /* readonly */
  1249. IntVector2 childOffset;
  1250. /* readonly */
  1251. Array<UIElement> children;
  1252. IntRect clipBorder;
  1253. bool clipChildren;
  1254. /* writeonly */
  1255. Color color;
  1256. /* readonly */
  1257. bool colorGradient;
  1258. Array<Color> colors;
  1259. /* readonly */
  1260. IntRect combinedScreenRect;
  1261. XMLFile defaultStyle;
  1262. /* readonly */
  1263. float derivedOpacity;
  1264. /* readonly */
  1265. uint dragButtonCombo;
  1266. /* readonly */
  1267. int dragButtonCount;
  1268. uint dragDropMode;
  1269. bool editable;
  1270. bool elementEventSender;
  1271. bool enabled;
  1272. /* readonly */
  1273. bool enabledSelf;
  1274. /* readonly */
  1275. bool fixedHeight;
  1276. /* readonly */
  1277. bool fixedSize;
  1278. /* readonly */
  1279. bool fixedWidth;
  1280. bool focus;
  1281. FocusMode focusMode;
  1282. int height;
  1283. HorizontalAlignment horizontalAlignment;
  1284. IntVector2 hoverOffset;
  1285. /* readonly */
  1286. bool hovering;
  1287. IntRect imageBorder;
  1288. IntRect imageRect;
  1289. int indent;
  1290. int indentSpacing;
  1291. /* readonly */
  1292. int indentWidth;
  1293. bool internal;
  1294. IntRect layoutBorder;
  1295. Vector2 layoutFlexScale;
  1296. LayoutMode layoutMode;
  1297. int layoutSpacing;
  1298. int maxHeight;
  1299. IntVector2 maxSize;
  1300. int maxWidth;
  1301. int minHeight;
  1302. IntVector2 minSize;
  1303. int minWidth;
  1304. String name;
  1305. /* readonly */
  1306. uint numAllChildren;
  1307. /* readonly */
  1308. uint numAttributes;
  1309. /* readonly */
  1310. uint numChildren;
  1311. ObjectAnimation objectAnimation;
  1312. float opacity;
  1313. UIElement parent;
  1314. IntVector2 position;
  1315. int priority;
  1316. /* readonly */
  1317. int refs;
  1318. /* readonly */
  1319. UIElement root;
  1320. /* readonly */
  1321. IntVector2 screenPosition;
  1322. bool selected;
  1323. IntVector2 size;
  1324. bool sortChildren;
  1325. String style;
  1326. bool temporary;
  1327. Texture texture;
  1328. bool tiled;
  1329. TraversalMode traversalMode;
  1330. /* readonly */
  1331. StringHash type;
  1332. /* readonly */
  1333. String typeName;
  1334. bool useDerivedOpacity;
  1335. /* readonly */
  1336. VariantMap vars;
  1337. VerticalAlignment verticalAlignment;
  1338. bool visible;
  1339. /* readonly */
  1340. int weakRefs;
  1341. int width;
  1342. };
  1343. class CollisionBox2D
  1344. {
  1345. // Methods:
  1346. void ApplyAttributes();
  1347. void DrawDebugGeometry(DebugRenderer, bool);
  1348. Variant GetAttribute(const String&) const;
  1349. ValueAnimation GetAttributeAnimation(const String&) const;
  1350. float GetAttributeAnimationSpeed(const String&) const;
  1351. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1352. Variant GetAttributeDefault(const String&) const;
  1353. bool Load(File, bool = false);
  1354. bool Load(VectorBuffer&, bool = false);
  1355. bool LoadXML(const XMLElement&, bool = false);
  1356. void MarkNetworkUpdate() const;
  1357. void Remove();
  1358. void RemoveInstanceDefault();
  1359. void ResetToDefault();
  1360. bool Save(File) const;
  1361. bool Save(VectorBuffer&) const;
  1362. bool SaveXML(XMLElement&) const;
  1363. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1364. bool SetAttribute(const String&, const Variant&);
  1365. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1366. void SetAttributeAnimationSpeed(const String&, float);
  1367. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1368. void SetCenter(float, float);
  1369. void SetSize(float, float);
  1370. // Properties:
  1371. float angle;
  1372. bool animationEnabled;
  1373. /* readonly */
  1374. Array<Variant> attributeDefaults;
  1375. /* readonly */
  1376. Array<AttributeInfo> attributeInfos;
  1377. Array<Variant> attributes;
  1378. /* readonly */
  1379. StringHash baseType;
  1380. /* readonly */
  1381. String category;
  1382. int categoryBits;
  1383. Vector2 center;
  1384. float density;
  1385. bool enabled;
  1386. /* readonly */
  1387. bool enabledEffective;
  1388. float friction;
  1389. int groupIndex;
  1390. /* readonly */
  1391. uint id;
  1392. /* readonly */
  1393. float inertia;
  1394. int maskBits;
  1395. /* readonly */
  1396. float mass;
  1397. /* readonly */
  1398. Vector2 massCenter;
  1399. /* readonly */
  1400. Node node;
  1401. /* readonly */
  1402. uint numAttributes;
  1403. ObjectAnimation objectAnimation;
  1404. /* readonly */
  1405. int refs;
  1406. float restitution;
  1407. Vector2 size;
  1408. bool temporary;
  1409. bool trigger;
  1410. /* readonly */
  1411. StringHash type;
  1412. /* readonly */
  1413. String typeName;
  1414. /* readonly */
  1415. int weakRefs;
  1416. };
  1417. class CollisionChain2D
  1418. {
  1419. // Methods:
  1420. void ApplyAttributes();
  1421. void DrawDebugGeometry(DebugRenderer, bool);
  1422. Variant GetAttribute(const String&) const;
  1423. ValueAnimation GetAttributeAnimation(const String&) const;
  1424. float GetAttributeAnimationSpeed(const String&) const;
  1425. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1426. Variant GetAttributeDefault(const String&) const;
  1427. Array<Vector2> GetVertices() const;
  1428. bool Load(File, bool = false);
  1429. bool Load(VectorBuffer&, bool = false);
  1430. bool LoadXML(const XMLElement&, bool = false);
  1431. void MarkNetworkUpdate() const;
  1432. void Remove();
  1433. void RemoveInstanceDefault();
  1434. void ResetToDefault();
  1435. bool Save(File) const;
  1436. bool Save(VectorBuffer&) const;
  1437. bool SaveXML(XMLElement&) const;
  1438. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1439. bool SetAttribute(const String&, const Variant&);
  1440. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1441. void SetAttributeAnimationSpeed(const String&, float);
  1442. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1443. void SetVertex(uint, const Vector2&);
  1444. void SetVertices(Array<Vector2>);
  1445. const Vector2& GetVertex(uint) const;
  1446. // Properties:
  1447. bool animationEnabled;
  1448. /* readonly */
  1449. Array<Variant> attributeDefaults;
  1450. /* readonly */
  1451. Array<AttributeInfo> attributeInfos;
  1452. Array<Variant> attributes;
  1453. /* readonly */
  1454. StringHash baseType;
  1455. /* readonly */
  1456. String category;
  1457. int categoryBits;
  1458. float density;
  1459. bool enabled;
  1460. /* readonly */
  1461. bool enabledEffective;
  1462. float friction;
  1463. int groupIndex;
  1464. /* readonly */
  1465. uint id;
  1466. /* readonly */
  1467. float inertia;
  1468. bool loop;
  1469. int maskBits;
  1470. /* readonly */
  1471. float mass;
  1472. /* readonly */
  1473. Vector2 massCenter;
  1474. /* readonly */
  1475. Node node;
  1476. /* readonly */
  1477. uint numAttributes;
  1478. ObjectAnimation objectAnimation;
  1479. /* readonly */
  1480. int refs;
  1481. float restitution;
  1482. bool temporary;
  1483. bool trigger;
  1484. /* readonly */
  1485. StringHash type;
  1486. /* readonly */
  1487. String typeName;
  1488. uint vertexCount;
  1489. /* readonly */
  1490. int weakRefs;
  1491. };
  1492. class CollisionCircle2D
  1493. {
  1494. // Methods:
  1495. void ApplyAttributes();
  1496. void DrawDebugGeometry(DebugRenderer, bool);
  1497. Variant GetAttribute(const String&) const;
  1498. ValueAnimation GetAttributeAnimation(const String&) const;
  1499. float GetAttributeAnimationSpeed(const String&) const;
  1500. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1501. Variant GetAttributeDefault(const String&) const;
  1502. bool Load(File, bool = false);
  1503. bool Load(VectorBuffer&, bool = false);
  1504. bool LoadXML(const XMLElement&, bool = false);
  1505. void MarkNetworkUpdate() const;
  1506. void Remove();
  1507. void RemoveInstanceDefault();
  1508. void ResetToDefault();
  1509. bool Save(File) const;
  1510. bool Save(VectorBuffer&) const;
  1511. bool SaveXML(XMLElement&) const;
  1512. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1513. bool SetAttribute(const String&, const Variant&);
  1514. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1515. void SetAttributeAnimationSpeed(const String&, float);
  1516. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1517. void SetCenter(float, float);
  1518. // Properties:
  1519. bool animationEnabled;
  1520. /* readonly */
  1521. Array<Variant> attributeDefaults;
  1522. /* readonly */
  1523. Array<AttributeInfo> attributeInfos;
  1524. Array<Variant> attributes;
  1525. /* readonly */
  1526. StringHash baseType;
  1527. /* readonly */
  1528. String category;
  1529. int categoryBits;
  1530. Vector2 center;
  1531. float density;
  1532. bool enabled;
  1533. /* readonly */
  1534. bool enabledEffective;
  1535. float friction;
  1536. int groupIndex;
  1537. /* readonly */
  1538. uint id;
  1539. /* readonly */
  1540. float inertia;
  1541. int maskBits;
  1542. /* readonly */
  1543. float mass;
  1544. /* readonly */
  1545. Vector2 massCenter;
  1546. /* readonly */
  1547. Node node;
  1548. /* readonly */
  1549. uint numAttributes;
  1550. ObjectAnimation objectAnimation;
  1551. float radius;
  1552. /* readonly */
  1553. int refs;
  1554. float restitution;
  1555. bool temporary;
  1556. bool trigger;
  1557. /* readonly */
  1558. StringHash type;
  1559. /* readonly */
  1560. String typeName;
  1561. /* readonly */
  1562. int weakRefs;
  1563. };
  1564. class CollisionEdge2D
  1565. {
  1566. // Methods:
  1567. void ApplyAttributes();
  1568. void DrawDebugGeometry(DebugRenderer, bool);
  1569. Variant GetAttribute(const String&) const;
  1570. ValueAnimation GetAttributeAnimation(const String&) const;
  1571. float GetAttributeAnimationSpeed(const String&) const;
  1572. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1573. Variant GetAttributeDefault(const String&) const;
  1574. bool Load(File, bool = false);
  1575. bool Load(VectorBuffer&, bool = false);
  1576. bool LoadXML(const XMLElement&, bool = false);
  1577. void MarkNetworkUpdate() const;
  1578. void Remove();
  1579. void RemoveInstanceDefault();
  1580. void ResetToDefault();
  1581. bool Save(File) const;
  1582. bool Save(VectorBuffer&) const;
  1583. bool SaveXML(XMLElement&) const;
  1584. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1585. bool SetAttribute(const String&, const Variant&);
  1586. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1587. void SetAttributeAnimationSpeed(const String&, float);
  1588. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1589. void SetVertices(const Vector2&, const Vector2&);
  1590. // Properties:
  1591. bool animationEnabled;
  1592. /* readonly */
  1593. Array<Variant> attributeDefaults;
  1594. /* readonly */
  1595. Array<AttributeInfo> attributeInfos;
  1596. Array<Variant> attributes;
  1597. /* readonly */
  1598. StringHash baseType;
  1599. /* readonly */
  1600. String category;
  1601. int categoryBits;
  1602. float density;
  1603. bool enabled;
  1604. /* readonly */
  1605. bool enabledEffective;
  1606. float friction;
  1607. int groupIndex;
  1608. /* readonly */
  1609. uint id;
  1610. /* readonly */
  1611. float inertia;
  1612. int maskBits;
  1613. /* readonly */
  1614. float mass;
  1615. /* readonly */
  1616. Vector2 massCenter;
  1617. /* readonly */
  1618. Node node;
  1619. /* readonly */
  1620. uint numAttributes;
  1621. ObjectAnimation objectAnimation;
  1622. /* readonly */
  1623. int refs;
  1624. float restitution;
  1625. bool temporary;
  1626. bool trigger;
  1627. /* readonly */
  1628. StringHash type;
  1629. /* readonly */
  1630. String typeName;
  1631. Vector2 vertex1;
  1632. Vector2 vertex2;
  1633. /* readonly */
  1634. int weakRefs;
  1635. };
  1636. class CollisionPolygon2D
  1637. {
  1638. // Methods:
  1639. void ApplyAttributes();
  1640. void DrawDebugGeometry(DebugRenderer, bool);
  1641. Variant GetAttribute(const String&) const;
  1642. ValueAnimation GetAttributeAnimation(const String&) const;
  1643. float GetAttributeAnimationSpeed(const String&) const;
  1644. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1645. Variant GetAttributeDefault(const String&) const;
  1646. Array<Vector2> GetVertices() const;
  1647. bool Load(File, bool = false);
  1648. bool Load(VectorBuffer&, bool = false);
  1649. bool LoadXML(const XMLElement&, bool = false);
  1650. void MarkNetworkUpdate() const;
  1651. void Remove();
  1652. void RemoveInstanceDefault();
  1653. void ResetToDefault();
  1654. bool Save(File) const;
  1655. bool Save(VectorBuffer&) const;
  1656. bool SaveXML(XMLElement&) const;
  1657. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1658. bool SetAttribute(const String&, const Variant&);
  1659. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1660. void SetAttributeAnimationSpeed(const String&, float);
  1661. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1662. void SetVertex(uint, const Vector2&);
  1663. void SetVertices(Array<Vector2>);
  1664. const Vector2& GetVertex(uint) const;
  1665. // Properties:
  1666. bool animationEnabled;
  1667. /* readonly */
  1668. Array<Variant> attributeDefaults;
  1669. /* readonly */
  1670. Array<AttributeInfo> attributeInfos;
  1671. Array<Variant> attributes;
  1672. /* readonly */
  1673. StringHash baseType;
  1674. /* readonly */
  1675. String category;
  1676. int categoryBits;
  1677. float density;
  1678. bool enabled;
  1679. /* readonly */
  1680. bool enabledEffective;
  1681. float friction;
  1682. int groupIndex;
  1683. /* readonly */
  1684. uint id;
  1685. /* readonly */
  1686. float inertia;
  1687. int maskBits;
  1688. /* readonly */
  1689. float mass;
  1690. /* readonly */
  1691. Vector2 massCenter;
  1692. /* readonly */
  1693. Node node;
  1694. /* readonly */
  1695. uint numAttributes;
  1696. ObjectAnimation objectAnimation;
  1697. /* readonly */
  1698. int refs;
  1699. float restitution;
  1700. bool temporary;
  1701. bool trigger;
  1702. /* readonly */
  1703. StringHash type;
  1704. /* readonly */
  1705. String typeName;
  1706. uint vertexCount;
  1707. /* readonly */
  1708. int weakRefs;
  1709. };
  1710. class CollisionShape
  1711. {
  1712. // Methods:
  1713. void ApplyAttributes();
  1714. void DrawDebugGeometry(DebugRenderer, bool);
  1715. Variant GetAttribute(const String&) const;
  1716. ValueAnimation GetAttributeAnimation(const String&) const;
  1717. float GetAttributeAnimationSpeed(const String&) const;
  1718. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1719. Variant GetAttributeDefault(const String&) const;
  1720. bool Load(File, bool = false);
  1721. bool Load(VectorBuffer&, bool = false);
  1722. bool LoadXML(const XMLElement&, bool = false);
  1723. void MarkNetworkUpdate() const;
  1724. void Remove();
  1725. void RemoveInstanceDefault();
  1726. void ResetToDefault();
  1727. bool Save(File) const;
  1728. bool Save(VectorBuffer&) const;
  1729. bool SaveXML(XMLElement&) const;
  1730. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1731. bool SetAttribute(const String&, const Variant&);
  1732. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1733. void SetAttributeAnimationSpeed(const String&, float);
  1734. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1735. void SetBox(const Vector3&, const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1736. void SetCapsule(float, float, const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1737. void SetCone(float, float, const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1738. void SetConvexHull(Model, uint = 0, const Vector3& = Vector3 ( 1 , 1 , 1 ), const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1739. void SetCustomConvexHull(CustomGeometry, const Vector3& = Vector3 ( 1 , 1 , 1 ), const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1740. void SetCustomTriangleMesh(CustomGeometry, const Vector3& = Vector3 ( 1 , 1 , 1 ), const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1741. void SetCylinder(float, float, const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1742. void SetSphere(float, const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1743. void SetStaticPlane(const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1744. void SetTerrain(uint = 0);
  1745. void SetTransform(const Vector3&, const Quaternion&);
  1746. void SetTriangleMesh(Model, uint = 0, const Vector3& = Vector3 ( 1 , 1 , 1 ), const Vector3& = Vector3 ( ), const Quaternion& = Quaternion ( ));
  1747. // Properties:
  1748. bool animationEnabled;
  1749. /* readonly */
  1750. Array<Variant> attributeDefaults;
  1751. /* readonly */
  1752. Array<AttributeInfo> attributeInfos;
  1753. Array<Variant> attributes;
  1754. /* readonly */
  1755. StringHash baseType;
  1756. /* readonly */
  1757. String category;
  1758. bool enabled;
  1759. /* readonly */
  1760. bool enabledEffective;
  1761. /* readonly */
  1762. uint id;
  1763. uint lodLevel;
  1764. float margin;
  1765. Model model;
  1766. /* readonly */
  1767. Node node;
  1768. /* readonly */
  1769. uint numAttributes;
  1770. ObjectAnimation objectAnimation;
  1771. Vector3 position;
  1772. /* readonly */
  1773. int refs;
  1774. Quaternion rotation;
  1775. ShapeType shapeType;
  1776. Vector3 size;
  1777. bool temporary;
  1778. /* readonly */
  1779. StringHash type;
  1780. /* readonly */
  1781. String typeName;
  1782. /* readonly */
  1783. int weakRefs;
  1784. /* readonly */
  1785. BoundingBox worldBoundingBox;
  1786. };
  1787. class CollisionShape2D
  1788. {
  1789. // Methods:
  1790. void ApplyAttributes();
  1791. void DrawDebugGeometry(DebugRenderer, bool);
  1792. Variant GetAttribute(const String&) const;
  1793. ValueAnimation GetAttributeAnimation(const String&) const;
  1794. float GetAttributeAnimationSpeed(const String&) const;
  1795. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1796. Variant GetAttributeDefault(const String&) const;
  1797. bool Load(File, bool = false);
  1798. bool Load(VectorBuffer&, bool = false);
  1799. bool LoadXML(const XMLElement&, bool = false);
  1800. void MarkNetworkUpdate() const;
  1801. void Remove();
  1802. void RemoveInstanceDefault();
  1803. void ResetToDefault();
  1804. bool Save(File) const;
  1805. bool Save(VectorBuffer&) const;
  1806. bool SaveXML(XMLElement&) const;
  1807. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1808. bool SetAttribute(const String&, const Variant&);
  1809. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1810. void SetAttributeAnimationSpeed(const String&, float);
  1811. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1812. // Properties:
  1813. bool animationEnabled;
  1814. /* readonly */
  1815. Array<Variant> attributeDefaults;
  1816. /* readonly */
  1817. Array<AttributeInfo> attributeInfos;
  1818. Array<Variant> attributes;
  1819. /* readonly */
  1820. StringHash baseType;
  1821. /* readonly */
  1822. String category;
  1823. int categoryBits;
  1824. float density;
  1825. bool enabled;
  1826. /* readonly */
  1827. bool enabledEffective;
  1828. float friction;
  1829. int groupIndex;
  1830. /* readonly */
  1831. uint id;
  1832. /* readonly */
  1833. float inertia;
  1834. int maskBits;
  1835. /* readonly */
  1836. float mass;
  1837. /* readonly */
  1838. Vector2 massCenter;
  1839. /* readonly */
  1840. Node node;
  1841. /* readonly */
  1842. uint numAttributes;
  1843. ObjectAnimation objectAnimation;
  1844. /* readonly */
  1845. int refs;
  1846. float restitution;
  1847. bool temporary;
  1848. bool trigger;
  1849. /* readonly */
  1850. StringHash type;
  1851. /* readonly */
  1852. String typeName;
  1853. /* readonly */
  1854. int weakRefs;
  1855. };
  1856. class Color
  1857. {
  1858. // Methods:
  1859. Color Abs() const;
  1860. float Average() const;
  1861. float Chroma() const;
  1862. void Clip(bool);
  1863. bool Equals() const;
  1864. void FromHSL(float, float, float, float);
  1865. void FromHSV(float, float, float, float);
  1866. float Hue() const;
  1867. void Invert(bool);
  1868. Color Lerp(const Color&, float) const;
  1869. float Lightness() const;
  1870. float Luma() const;
  1871. float MaxRGB() const;
  1872. float MinRGB() const;
  1873. float Range() const;
  1874. float SaturationHSL() const;
  1875. float SaturationHSV() const;
  1876. float SumRGB() const;
  1877. Vector3 ToHSL() const;
  1878. Vector3 ToHSV() const;
  1879. String ToString() const;
  1880. uint ToUInt() const;
  1881. float Value() const;
  1882. // Properties:
  1883. float a;
  1884. float b;
  1885. /* readonly */
  1886. Array<float> data;
  1887. float g;
  1888. float r;
  1889. /* readonly */
  1890. Vector3 rgb;
  1891. /* readonly */
  1892. Vector4 rgba;
  1893. };
  1894. class ColorFrame
  1895. {
  1896. // Properties:
  1897. Color color;
  1898. float time;
  1899. };
  1900. class Component
  1901. {
  1902. // Methods:
  1903. void ApplyAttributes();
  1904. void DrawDebugGeometry(DebugRenderer, bool);
  1905. Variant GetAttribute(const String&) const;
  1906. ValueAnimation GetAttributeAnimation(const String&) const;
  1907. float GetAttributeAnimationSpeed(const String&) const;
  1908. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  1909. Variant GetAttributeDefault(const String&) const;
  1910. bool Load(File, bool = false);
  1911. bool Load(VectorBuffer&, bool = false);
  1912. bool LoadXML(const XMLElement&, bool = false);
  1913. void MarkNetworkUpdate() const;
  1914. void Remove();
  1915. void RemoveInstanceDefault();
  1916. void ResetToDefault();
  1917. bool Save(File) const;
  1918. bool Save(VectorBuffer&) const;
  1919. bool SaveXML(XMLElement&) const;
  1920. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1921. bool SetAttribute(const String&, const Variant&);
  1922. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  1923. void SetAttributeAnimationSpeed(const String&, float);
  1924. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  1925. // Properties:
  1926. bool animationEnabled;
  1927. /* readonly */
  1928. Array<Variant> attributeDefaults;
  1929. /* readonly */
  1930. Array<AttributeInfo> attributeInfos;
  1931. Array<Variant> attributes;
  1932. /* readonly */
  1933. StringHash baseType;
  1934. /* readonly */
  1935. String category;
  1936. bool enabled;
  1937. /* readonly */
  1938. bool enabledEffective;
  1939. /* readonly */
  1940. uint id;
  1941. /* readonly */
  1942. Node node;
  1943. /* readonly */
  1944. uint numAttributes;
  1945. ObjectAnimation objectAnimation;
  1946. /* readonly */
  1947. int refs;
  1948. bool temporary;
  1949. /* readonly */
  1950. StringHash type;
  1951. /* readonly */
  1952. String typeName;
  1953. /* readonly */
  1954. int weakRefs;
  1955. };
  1956. class Connection
  1957. {
  1958. // Methods:
  1959. void Disconnect(int = 0);
  1960. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  1961. void SendMessage(int, bool, bool, const VectorBuffer&, uint = 0);
  1962. void SendPackageToClient(PackageFile);
  1963. void SendRemoteEvent(Node, const String&, bool, const VariantMap& = VariantMap ( ));
  1964. void SendRemoteEvent(const String&, bool, const VariantMap& = VariantMap ( ));
  1965. String ToString() const;
  1966. // Properties:
  1967. /* readonly */
  1968. String address;
  1969. /* readonly */
  1970. StringHash baseType;
  1971. /* readonly */
  1972. String category;
  1973. /* readonly */
  1974. bool client;
  1975. /* readonly */
  1976. bool connectPending;
  1977. /* readonly */
  1978. bool connected;
  1979. Controls controls;
  1980. /* readonly */
  1981. String downloadName;
  1982. /* readonly */
  1983. float downloadProgress;
  1984. VariantMap identity;
  1985. bool logStatistics;
  1986. /* readonly */
  1987. uint numDownloads;
  1988. /* readonly */
  1989. uint16 port;
  1990. Vector3 position;
  1991. /* readonly */
  1992. int refs;
  1993. Quaternion rotation;
  1994. Scene scene;
  1995. /* readonly */
  1996. bool sceneLoaded;
  1997. /* readonly */
  1998. StringHash type;
  1999. /* readonly */
  2000. String typeName;
  2001. /* readonly */
  2002. int weakRefs;
  2003. };
  2004. class Console
  2005. {
  2006. // Methods:
  2007. void CopySelectedRows() const;
  2008. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2009. void Toggle();
  2010. void UpdateElements();
  2011. // Properties:
  2012. bool autoVisibleOnError;
  2013. /* readonly */
  2014. BorderImage background;
  2015. /* readonly */
  2016. StringHash baseType;
  2017. /* readonly */
  2018. String category;
  2019. /* readonly */
  2020. Button closeButton;
  2021. String commandInterpreter;
  2022. XMLFile defaultStyle;
  2023. bool focusOnShow;
  2024. /* readonly */
  2025. uint historyPosition;
  2026. /* readonly */
  2027. Array<String> historyRow;
  2028. /* readonly */
  2029. LineEdit lineEdit;
  2030. uint numBufferedRows;
  2031. uint numHistoryRows;
  2032. uint numRows;
  2033. /* readonly */
  2034. int refs;
  2035. /* readonly */
  2036. StringHash type;
  2037. /* readonly */
  2038. String typeName;
  2039. bool visible;
  2040. /* readonly */
  2041. int weakRefs;
  2042. };
  2043. class Constraint
  2044. {
  2045. // Methods:
  2046. void ApplyAttributes();
  2047. void DrawDebugGeometry(DebugRenderer, bool);
  2048. Variant GetAttribute(const String&) const;
  2049. ValueAnimation GetAttributeAnimation(const String&) const;
  2050. float GetAttributeAnimationSpeed(const String&) const;
  2051. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2052. Variant GetAttributeDefault(const String&) const;
  2053. bool Load(File, bool = false);
  2054. bool Load(VectorBuffer&, bool = false);
  2055. bool LoadXML(const XMLElement&, bool = false);
  2056. void MarkNetworkUpdate() const;
  2057. void Remove();
  2058. void RemoveInstanceDefault();
  2059. void ResetToDefault();
  2060. bool Save(File) const;
  2061. bool Save(VectorBuffer&) const;
  2062. bool SaveXML(XMLElement&) const;
  2063. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2064. bool SetAttribute(const String&, const Variant&);
  2065. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2066. void SetAttributeAnimationSpeed(const String&, float);
  2067. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2068. // Properties:
  2069. bool animationEnabled;
  2070. /* readonly */
  2071. Array<Variant> attributeDefaults;
  2072. /* readonly */
  2073. Array<AttributeInfo> attributeInfos;
  2074. Array<Variant> attributes;
  2075. /* writeonly */
  2076. Vector3 axis;
  2077. /* readonly */
  2078. StringHash baseType;
  2079. /* readonly */
  2080. String category;
  2081. float cfm;
  2082. ConstraintType constraintType;
  2083. bool disableCollision;
  2084. bool enabled;
  2085. /* readonly */
  2086. bool enabledEffective;
  2087. float erp;
  2088. Vector2 highLimit;
  2089. /* readonly */
  2090. uint id;
  2091. Vector2 lowLimit;
  2092. /* readonly */
  2093. Node node;
  2094. /* readonly */
  2095. uint numAttributes;
  2096. ObjectAnimation objectAnimation;
  2097. /* writeonly */
  2098. Vector3 otherAxis;
  2099. RigidBody otherBody;
  2100. Vector3 otherPosition;
  2101. Quaternion otherRotation;
  2102. /* readonly */
  2103. RigidBody ownBody;
  2104. Vector3 position;
  2105. /* readonly */
  2106. int refs;
  2107. Quaternion rotation;
  2108. bool temporary;
  2109. /* readonly */
  2110. StringHash type;
  2111. /* readonly */
  2112. String typeName;
  2113. /* readonly */
  2114. int weakRefs;
  2115. Vector3 worldPosition;
  2116. };
  2117. class Constraint2D
  2118. {
  2119. // Methods:
  2120. void ApplyAttributes();
  2121. void DrawDebugGeometry(DebugRenderer, bool);
  2122. Variant GetAttribute(const String&) const;
  2123. ValueAnimation GetAttributeAnimation(const String&) const;
  2124. float GetAttributeAnimationSpeed(const String&) const;
  2125. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2126. Variant GetAttributeDefault(const String&) const;
  2127. bool Load(File, bool = false);
  2128. bool Load(VectorBuffer&, bool = false);
  2129. bool LoadXML(const XMLElement&, bool = false);
  2130. void MarkNetworkUpdate() const;
  2131. void Remove();
  2132. void RemoveInstanceDefault();
  2133. void ResetToDefault();
  2134. bool Save(File) const;
  2135. bool Save(VectorBuffer&) const;
  2136. bool SaveXML(XMLElement&) const;
  2137. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2138. bool SetAttribute(const String&, const Variant&);
  2139. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2140. void SetAttributeAnimationSpeed(const String&, float);
  2141. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2142. // Properties:
  2143. bool animationEnabled;
  2144. /* readonly */
  2145. Array<Variant> attributeDefaults;
  2146. /* readonly */
  2147. Array<AttributeInfo> attributeInfos;
  2148. Array<Variant> attributes;
  2149. /* readonly */
  2150. StringHash baseType;
  2151. /* readonly */
  2152. String category;
  2153. bool collideConnected;
  2154. bool enabled;
  2155. /* readonly */
  2156. bool enabledEffective;
  2157. /* readonly */
  2158. uint id;
  2159. /* readonly */
  2160. Node node;
  2161. /* readonly */
  2162. uint numAttributes;
  2163. ObjectAnimation objectAnimation;
  2164. RigidBody2D otherBody;
  2165. /* readonly */
  2166. RigidBody2D ownerBody;
  2167. /* readonly */
  2168. int refs;
  2169. bool temporary;
  2170. /* readonly */
  2171. StringHash type;
  2172. /* readonly */
  2173. String typeName;
  2174. /* readonly */
  2175. int weakRefs;
  2176. };
  2177. class ConstraintDistance2D
  2178. {
  2179. // Methods:
  2180. void ApplyAttributes();
  2181. void DrawDebugGeometry(DebugRenderer, bool);
  2182. Variant GetAttribute(const String&) const;
  2183. ValueAnimation GetAttributeAnimation(const String&) const;
  2184. float GetAttributeAnimationSpeed(const String&) const;
  2185. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2186. Variant GetAttributeDefault(const String&) const;
  2187. bool Load(File, bool = false);
  2188. bool Load(VectorBuffer&, bool = false);
  2189. bool LoadXML(const XMLElement&, bool = false);
  2190. void MarkNetworkUpdate() const;
  2191. void Remove();
  2192. void RemoveInstanceDefault();
  2193. void ResetToDefault();
  2194. bool Save(File) const;
  2195. bool Save(VectorBuffer&) const;
  2196. bool SaveXML(XMLElement&) const;
  2197. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2198. bool SetAttribute(const String&, const Variant&);
  2199. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2200. void SetAttributeAnimationSpeed(const String&, float);
  2201. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2202. // Properties:
  2203. bool animationEnabled;
  2204. /* readonly */
  2205. Array<Variant> attributeDefaults;
  2206. /* readonly */
  2207. Array<AttributeInfo> attributeInfos;
  2208. Array<Variant> attributes;
  2209. /* readonly */
  2210. StringHash baseType;
  2211. /* readonly */
  2212. String category;
  2213. bool collideConnected;
  2214. float dampingRatio;
  2215. bool enabled;
  2216. /* readonly */
  2217. bool enabledEffective;
  2218. float frequencyHz;
  2219. /* readonly */
  2220. uint id;
  2221. /* readonly */
  2222. Node node;
  2223. /* readonly */
  2224. uint numAttributes;
  2225. ObjectAnimation objectAnimation;
  2226. RigidBody2D otherBody;
  2227. Vector2 otherBodyAnchor;
  2228. /* readonly */
  2229. RigidBody2D ownerBody;
  2230. Vector2 ownerBodyAnchor;
  2231. /* readonly */
  2232. int refs;
  2233. bool temporary;
  2234. /* readonly */
  2235. StringHash type;
  2236. /* readonly */
  2237. String typeName;
  2238. /* readonly */
  2239. int weakRefs;
  2240. };
  2241. class ConstraintFriction2D
  2242. {
  2243. // Methods:
  2244. void ApplyAttributes();
  2245. void DrawDebugGeometry(DebugRenderer, bool);
  2246. Variant GetAttribute(const String&) const;
  2247. ValueAnimation GetAttributeAnimation(const String&) const;
  2248. float GetAttributeAnimationSpeed(const String&) const;
  2249. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2250. Variant GetAttributeDefault(const String&) const;
  2251. bool Load(File, bool = false);
  2252. bool Load(VectorBuffer&, bool = false);
  2253. bool LoadXML(const XMLElement&, bool = false);
  2254. void MarkNetworkUpdate() const;
  2255. void Remove();
  2256. void RemoveInstanceDefault();
  2257. void ResetToDefault();
  2258. bool Save(File) const;
  2259. bool Save(VectorBuffer&) const;
  2260. bool SaveXML(XMLElement&) const;
  2261. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2262. bool SetAttribute(const String&, const Variant&);
  2263. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2264. void SetAttributeAnimationSpeed(const String&, float);
  2265. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2266. // Properties:
  2267. Vector2 anchor;
  2268. bool animationEnabled;
  2269. /* readonly */
  2270. Array<Variant> attributeDefaults;
  2271. /* readonly */
  2272. Array<AttributeInfo> attributeInfos;
  2273. Array<Variant> attributes;
  2274. /* readonly */
  2275. StringHash baseType;
  2276. /* readonly */
  2277. String category;
  2278. bool collideConnected;
  2279. bool enabled;
  2280. /* readonly */
  2281. bool enabledEffective;
  2282. /* readonly */
  2283. uint id;
  2284. float maxForce;
  2285. float maxTorque;
  2286. /* readonly */
  2287. Node node;
  2288. /* readonly */
  2289. uint numAttributes;
  2290. ObjectAnimation objectAnimation;
  2291. RigidBody2D otherBody;
  2292. /* readonly */
  2293. RigidBody2D ownerBody;
  2294. /* readonly */
  2295. int refs;
  2296. bool temporary;
  2297. /* readonly */
  2298. StringHash type;
  2299. /* readonly */
  2300. String typeName;
  2301. /* readonly */
  2302. int weakRefs;
  2303. };
  2304. class ConstraintGear2D
  2305. {
  2306. // Methods:
  2307. void ApplyAttributes();
  2308. void DrawDebugGeometry(DebugRenderer, bool);
  2309. Variant GetAttribute(const String&) const;
  2310. ValueAnimation GetAttributeAnimation(const String&) const;
  2311. float GetAttributeAnimationSpeed(const String&) const;
  2312. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2313. Variant GetAttributeDefault(const String&) const;
  2314. bool Load(File, bool = false);
  2315. bool Load(VectorBuffer&, bool = false);
  2316. bool LoadXML(const XMLElement&, bool = false);
  2317. void MarkNetworkUpdate() const;
  2318. void Remove();
  2319. void RemoveInstanceDefault();
  2320. void ResetToDefault();
  2321. bool Save(File) const;
  2322. bool Save(VectorBuffer&) const;
  2323. bool SaveXML(XMLElement&) const;
  2324. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2325. bool SetAttribute(const String&, const Variant&);
  2326. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2327. void SetAttributeAnimationSpeed(const String&, float);
  2328. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2329. // Properties:
  2330. bool animationEnabled;
  2331. /* readonly */
  2332. Array<Variant> attributeDefaults;
  2333. /* readonly */
  2334. Array<AttributeInfo> attributeInfos;
  2335. Array<Variant> attributes;
  2336. /* readonly */
  2337. StringHash baseType;
  2338. /* readonly */
  2339. String category;
  2340. bool collideConnected;
  2341. bool enabled;
  2342. /* readonly */
  2343. bool enabledEffective;
  2344. /* readonly */
  2345. uint id;
  2346. /* readonly */
  2347. Node node;
  2348. /* readonly */
  2349. uint numAttributes;
  2350. ObjectAnimation objectAnimation;
  2351. RigidBody2D otherBody;
  2352. Constraint2D otherConstraint;
  2353. /* readonly */
  2354. RigidBody2D ownerBody;
  2355. Constraint2D ownerConstraint;
  2356. float ratio;
  2357. /* readonly */
  2358. int refs;
  2359. bool temporary;
  2360. /* readonly */
  2361. StringHash type;
  2362. /* readonly */
  2363. String typeName;
  2364. /* readonly */
  2365. int weakRefs;
  2366. };
  2367. class ConstraintMotor2D
  2368. {
  2369. // Methods:
  2370. void ApplyAttributes();
  2371. void DrawDebugGeometry(DebugRenderer, bool);
  2372. Variant GetAttribute(const String&) const;
  2373. ValueAnimation GetAttributeAnimation(const String&) const;
  2374. float GetAttributeAnimationSpeed(const String&) const;
  2375. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2376. Variant GetAttributeDefault(const String&) const;
  2377. bool Load(File, bool = false);
  2378. bool Load(VectorBuffer&, bool = false);
  2379. bool LoadXML(const XMLElement&, bool = false);
  2380. void MarkNetworkUpdate() const;
  2381. void Remove();
  2382. void RemoveInstanceDefault();
  2383. void ResetToDefault();
  2384. bool Save(File) const;
  2385. bool Save(VectorBuffer&) const;
  2386. bool SaveXML(XMLElement&) const;
  2387. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2388. bool SetAttribute(const String&, const Variant&);
  2389. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2390. void SetAttributeAnimationSpeed(const String&, float);
  2391. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2392. // Properties:
  2393. float angularOffset;
  2394. bool animationEnabled;
  2395. /* readonly */
  2396. Array<Variant> attributeDefaults;
  2397. /* readonly */
  2398. Array<AttributeInfo> attributeInfos;
  2399. Array<Variant> attributes;
  2400. /* readonly */
  2401. StringHash baseType;
  2402. /* readonly */
  2403. String category;
  2404. bool collideConnected;
  2405. float correctionFactor;
  2406. bool enabled;
  2407. /* readonly */
  2408. bool enabledEffective;
  2409. /* readonly */
  2410. uint id;
  2411. Vector2 linearOffset;
  2412. float maxForce;
  2413. float maxTorque;
  2414. /* readonly */
  2415. Node node;
  2416. /* readonly */
  2417. uint numAttributes;
  2418. ObjectAnimation objectAnimation;
  2419. RigidBody2D otherBody;
  2420. /* readonly */
  2421. RigidBody2D ownerBody;
  2422. /* readonly */
  2423. int refs;
  2424. bool temporary;
  2425. /* readonly */
  2426. StringHash type;
  2427. /* readonly */
  2428. String typeName;
  2429. /* readonly */
  2430. int weakRefs;
  2431. };
  2432. class ConstraintMouse2D
  2433. {
  2434. // Methods:
  2435. void ApplyAttributes();
  2436. void DrawDebugGeometry(DebugRenderer, bool);
  2437. Variant GetAttribute(const String&) const;
  2438. ValueAnimation GetAttributeAnimation(const String&) const;
  2439. float GetAttributeAnimationSpeed(const String&) const;
  2440. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2441. Variant GetAttributeDefault(const String&) const;
  2442. bool Load(File, bool = false);
  2443. bool Load(VectorBuffer&, bool = false);
  2444. bool LoadXML(const XMLElement&, bool = false);
  2445. void MarkNetworkUpdate() const;
  2446. void Remove();
  2447. void RemoveInstanceDefault();
  2448. void ResetToDefault();
  2449. bool Save(File) const;
  2450. bool Save(VectorBuffer&) const;
  2451. bool SaveXML(XMLElement&) const;
  2452. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2453. bool SetAttribute(const String&, const Variant&);
  2454. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2455. void SetAttributeAnimationSpeed(const String&, float);
  2456. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2457. // Properties:
  2458. bool animationEnabled;
  2459. /* readonly */
  2460. Array<Variant> attributeDefaults;
  2461. /* readonly */
  2462. Array<AttributeInfo> attributeInfos;
  2463. Array<Variant> attributes;
  2464. /* readonly */
  2465. StringHash baseType;
  2466. /* readonly */
  2467. String category;
  2468. bool collideConnected;
  2469. float dampingRatio;
  2470. bool enabled;
  2471. /* readonly */
  2472. bool enabledEffective;
  2473. float frequencyHz;
  2474. /* readonly */
  2475. uint id;
  2476. float maxForce;
  2477. /* readonly */
  2478. Node node;
  2479. /* readonly */
  2480. uint numAttributes;
  2481. ObjectAnimation objectAnimation;
  2482. RigidBody2D otherBody;
  2483. /* readonly */
  2484. RigidBody2D ownerBody;
  2485. /* readonly */
  2486. int refs;
  2487. Vector2 target;
  2488. bool temporary;
  2489. /* readonly */
  2490. StringHash type;
  2491. /* readonly */
  2492. String typeName;
  2493. /* readonly */
  2494. int weakRefs;
  2495. };
  2496. class ConstraintPrismatic2D
  2497. {
  2498. // Methods:
  2499. void ApplyAttributes();
  2500. void DrawDebugGeometry(DebugRenderer, bool);
  2501. Variant GetAttribute(const String&) const;
  2502. ValueAnimation GetAttributeAnimation(const String&) const;
  2503. float GetAttributeAnimationSpeed(const String&) const;
  2504. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2505. Variant GetAttributeDefault(const String&) const;
  2506. bool Load(File, bool = false);
  2507. bool Load(VectorBuffer&, bool = false);
  2508. bool LoadXML(const XMLElement&, bool = false);
  2509. void MarkNetworkUpdate() const;
  2510. void Remove();
  2511. void RemoveInstanceDefault();
  2512. void ResetToDefault();
  2513. bool Save(File) const;
  2514. bool Save(VectorBuffer&) const;
  2515. bool SaveXML(XMLElement&) const;
  2516. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2517. bool SetAttribute(const String&, const Variant&);
  2518. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2519. void SetAttributeAnimationSpeed(const String&, float);
  2520. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2521. // Properties:
  2522. Vector2 anchor;
  2523. bool animationEnabled;
  2524. /* readonly */
  2525. Array<Variant> attributeDefaults;
  2526. /* readonly */
  2527. Array<AttributeInfo> attributeInfos;
  2528. Array<Variant> attributes;
  2529. Vector2 axis;
  2530. /* readonly */
  2531. StringHash baseType;
  2532. /* readonly */
  2533. String category;
  2534. bool collideConnected;
  2535. bool enableLimit;
  2536. bool enableMotor;
  2537. bool enabled;
  2538. /* readonly */
  2539. bool enabledEffective;
  2540. /* readonly */
  2541. uint id;
  2542. float lowerTranslation;
  2543. float maxMotorForce;
  2544. float motorSpeed;
  2545. /* readonly */
  2546. Node node;
  2547. /* readonly */
  2548. uint numAttributes;
  2549. ObjectAnimation objectAnimation;
  2550. RigidBody2D otherBody;
  2551. /* readonly */
  2552. RigidBody2D ownerBody;
  2553. /* readonly */
  2554. int refs;
  2555. bool temporary;
  2556. /* readonly */
  2557. StringHash type;
  2558. /* readonly */
  2559. String typeName;
  2560. float upperTranslation;
  2561. /* readonly */
  2562. int weakRefs;
  2563. };
  2564. class ConstraintPulley2D
  2565. {
  2566. // Methods:
  2567. void ApplyAttributes();
  2568. void DrawDebugGeometry(DebugRenderer, bool);
  2569. Variant GetAttribute(const String&) const;
  2570. ValueAnimation GetAttributeAnimation(const String&) const;
  2571. float GetAttributeAnimationSpeed(const String&) const;
  2572. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2573. Variant GetAttributeDefault(const String&) const;
  2574. bool Load(File, bool = false);
  2575. bool Load(VectorBuffer&, bool = false);
  2576. bool LoadXML(const XMLElement&, bool = false);
  2577. void MarkNetworkUpdate() const;
  2578. void Remove();
  2579. void RemoveInstanceDefault();
  2580. void ResetToDefault();
  2581. bool Save(File) const;
  2582. bool Save(VectorBuffer&) const;
  2583. bool SaveXML(XMLElement&) const;
  2584. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2585. bool SetAttribute(const String&, const Variant&);
  2586. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2587. void SetAttributeAnimationSpeed(const String&, float);
  2588. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2589. // Properties:
  2590. bool animationEnabled;
  2591. /* readonly */
  2592. Array<Variant> attributeDefaults;
  2593. /* readonly */
  2594. Array<AttributeInfo> attributeInfos;
  2595. Array<Variant> attributes;
  2596. /* readonly */
  2597. StringHash baseType;
  2598. /* readonly */
  2599. String category;
  2600. bool collideConnected;
  2601. bool enabled;
  2602. /* readonly */
  2603. bool enabledEffective;
  2604. /* readonly */
  2605. uint id;
  2606. /* readonly */
  2607. Node node;
  2608. /* readonly */
  2609. uint numAttributes;
  2610. ObjectAnimation objectAnimation;
  2611. RigidBody2D otherBody;
  2612. Vector2 otherBodyAnchor;
  2613. Vector2 otherBodyGroundAnchor;
  2614. /* readonly */
  2615. RigidBody2D ownerBody;
  2616. Vector2 ownerBodyAnchor;
  2617. Vector2 ownerBodyGroundAnchor;
  2618. float ratio;
  2619. /* readonly */
  2620. int refs;
  2621. bool temporary;
  2622. /* readonly */
  2623. StringHash type;
  2624. /* readonly */
  2625. String typeName;
  2626. /* readonly */
  2627. int weakRefs;
  2628. };
  2629. class ConstraintRevolute2D
  2630. {
  2631. // Methods:
  2632. void ApplyAttributes();
  2633. void DrawDebugGeometry(DebugRenderer, bool);
  2634. Variant GetAttribute(const String&) const;
  2635. ValueAnimation GetAttributeAnimation(const String&) const;
  2636. float GetAttributeAnimationSpeed(const String&) const;
  2637. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2638. Variant GetAttributeDefault(const String&) const;
  2639. bool Load(File, bool = false);
  2640. bool Load(VectorBuffer&, bool = false);
  2641. bool LoadXML(const XMLElement&, bool = false);
  2642. void MarkNetworkUpdate() const;
  2643. void Remove();
  2644. void RemoveInstanceDefault();
  2645. void ResetToDefault();
  2646. bool Save(File) const;
  2647. bool Save(VectorBuffer&) const;
  2648. bool SaveXML(XMLElement&) const;
  2649. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2650. bool SetAttribute(const String&, const Variant&);
  2651. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2652. void SetAttributeAnimationSpeed(const String&, float);
  2653. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2654. // Properties:
  2655. Vector2 anchor;
  2656. bool animationEnabled;
  2657. /* readonly */
  2658. Array<Variant> attributeDefaults;
  2659. /* readonly */
  2660. Array<AttributeInfo> attributeInfos;
  2661. Array<Variant> attributes;
  2662. /* readonly */
  2663. StringHash baseType;
  2664. /* readonly */
  2665. String category;
  2666. bool collideConnected;
  2667. bool enableLimit;
  2668. bool enableMotor;
  2669. bool enabled;
  2670. /* readonly */
  2671. bool enabledEffective;
  2672. /* readonly */
  2673. uint id;
  2674. float lowerAngle;
  2675. float maxMotorTorque;
  2676. float motorSpeed;
  2677. /* readonly */
  2678. Node node;
  2679. /* readonly */
  2680. uint numAttributes;
  2681. ObjectAnimation objectAnimation;
  2682. RigidBody2D otherBody;
  2683. /* readonly */
  2684. RigidBody2D ownerBody;
  2685. /* readonly */
  2686. int refs;
  2687. bool temporary;
  2688. /* readonly */
  2689. StringHash type;
  2690. /* readonly */
  2691. String typeName;
  2692. float upperAngle;
  2693. /* readonly */
  2694. int weakRefs;
  2695. };
  2696. class ConstraintRope2D
  2697. {
  2698. // Methods:
  2699. void ApplyAttributes();
  2700. void DrawDebugGeometry(DebugRenderer, bool);
  2701. Variant GetAttribute(const String&) const;
  2702. ValueAnimation GetAttributeAnimation(const String&) const;
  2703. float GetAttributeAnimationSpeed(const String&) const;
  2704. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2705. Variant GetAttributeDefault(const String&) const;
  2706. bool Load(File, bool = false);
  2707. bool Load(VectorBuffer&, bool = false);
  2708. bool LoadXML(const XMLElement&, bool = false);
  2709. void MarkNetworkUpdate() const;
  2710. void Remove();
  2711. void RemoveInstanceDefault();
  2712. void ResetToDefault();
  2713. bool Save(File) const;
  2714. bool Save(VectorBuffer&) const;
  2715. bool SaveXML(XMLElement&) const;
  2716. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2717. bool SetAttribute(const String&, const Variant&);
  2718. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2719. void SetAttributeAnimationSpeed(const String&, float);
  2720. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2721. // Properties:
  2722. bool animationEnabled;
  2723. /* readonly */
  2724. Array<Variant> attributeDefaults;
  2725. /* readonly */
  2726. Array<AttributeInfo> attributeInfos;
  2727. Array<Variant> attributes;
  2728. /* readonly */
  2729. StringHash baseType;
  2730. /* readonly */
  2731. String category;
  2732. bool collideConnected;
  2733. bool enabled;
  2734. /* readonly */
  2735. bool enabledEffective;
  2736. /* readonly */
  2737. uint id;
  2738. float maxLength;
  2739. /* readonly */
  2740. Node node;
  2741. /* readonly */
  2742. uint numAttributes;
  2743. ObjectAnimation objectAnimation;
  2744. RigidBody2D otherBody;
  2745. Vector2 otherBodyAnchor;
  2746. /* readonly */
  2747. RigidBody2D ownerBody;
  2748. Vector2 ownerBodyAnchor;
  2749. /* readonly */
  2750. int refs;
  2751. bool temporary;
  2752. /* readonly */
  2753. StringHash type;
  2754. /* readonly */
  2755. String typeName;
  2756. /* readonly */
  2757. int weakRefs;
  2758. };
  2759. class ConstraintWeld2D
  2760. {
  2761. // Methods:
  2762. void ApplyAttributes();
  2763. void DrawDebugGeometry(DebugRenderer, bool);
  2764. Variant GetAttribute(const String&) const;
  2765. ValueAnimation GetAttributeAnimation(const String&) const;
  2766. float GetAttributeAnimationSpeed(const String&) const;
  2767. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2768. Variant GetAttributeDefault(const String&) const;
  2769. bool Load(File, bool = false);
  2770. bool Load(VectorBuffer&, bool = false);
  2771. bool LoadXML(const XMLElement&, bool = false);
  2772. void MarkNetworkUpdate() const;
  2773. void Remove();
  2774. void RemoveInstanceDefault();
  2775. void ResetToDefault();
  2776. bool Save(File) const;
  2777. bool Save(VectorBuffer&) const;
  2778. bool SaveXML(XMLElement&) const;
  2779. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2780. bool SetAttribute(const String&, const Variant&);
  2781. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2782. void SetAttributeAnimationSpeed(const String&, float);
  2783. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2784. // Properties:
  2785. Vector2 anchor;
  2786. bool animationEnabled;
  2787. /* readonly */
  2788. Array<Variant> attributeDefaults;
  2789. /* readonly */
  2790. Array<AttributeInfo> attributeInfos;
  2791. Array<Variant> attributes;
  2792. /* readonly */
  2793. StringHash baseType;
  2794. /* readonly */
  2795. String category;
  2796. bool collideConnected;
  2797. float dampingRatio;
  2798. bool enabled;
  2799. /* readonly */
  2800. bool enabledEffective;
  2801. float frequencyHz;
  2802. /* readonly */
  2803. uint id;
  2804. /* readonly */
  2805. Node node;
  2806. /* readonly */
  2807. uint numAttributes;
  2808. ObjectAnimation objectAnimation;
  2809. RigidBody2D otherBody;
  2810. /* readonly */
  2811. RigidBody2D ownerBody;
  2812. /* readonly */
  2813. int refs;
  2814. bool temporary;
  2815. /* readonly */
  2816. StringHash type;
  2817. /* readonly */
  2818. String typeName;
  2819. /* readonly */
  2820. int weakRefs;
  2821. };
  2822. class ConstraintWheel2D
  2823. {
  2824. // Methods:
  2825. void ApplyAttributes();
  2826. void DrawDebugGeometry(DebugRenderer, bool);
  2827. Variant GetAttribute(const String&) const;
  2828. ValueAnimation GetAttributeAnimation(const String&) const;
  2829. float GetAttributeAnimationSpeed(const String&) const;
  2830. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2831. Variant GetAttributeDefault(const String&) const;
  2832. bool Load(File, bool = false);
  2833. bool Load(VectorBuffer&, bool = false);
  2834. bool LoadXML(const XMLElement&, bool = false);
  2835. void MarkNetworkUpdate() const;
  2836. void Remove();
  2837. void RemoveInstanceDefault();
  2838. void ResetToDefault();
  2839. bool Save(File) const;
  2840. bool Save(VectorBuffer&) const;
  2841. bool SaveXML(XMLElement&) const;
  2842. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2843. bool SetAttribute(const String&, const Variant&);
  2844. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2845. void SetAttributeAnimationSpeed(const String&, float);
  2846. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2847. // Properties:
  2848. Vector2 anchor;
  2849. bool animationEnabled;
  2850. /* readonly */
  2851. Array<Variant> attributeDefaults;
  2852. /* readonly */
  2853. Array<AttributeInfo> attributeInfos;
  2854. Array<Variant> attributes;
  2855. Vector2 axis;
  2856. /* readonly */
  2857. StringHash baseType;
  2858. /* readonly */
  2859. String category;
  2860. bool collideConnected;
  2861. float dampingRatio;
  2862. bool enableMotor;
  2863. bool enabled;
  2864. /* readonly */
  2865. bool enabledEffective;
  2866. float frequencyHz;
  2867. /* readonly */
  2868. uint id;
  2869. float maxMotorTorque;
  2870. float motorSpeed;
  2871. /* readonly */
  2872. Node node;
  2873. /* readonly */
  2874. uint numAttributes;
  2875. ObjectAnimation objectAnimation;
  2876. RigidBody2D otherBody;
  2877. /* readonly */
  2878. RigidBody2D ownerBody;
  2879. /* readonly */
  2880. int refs;
  2881. bool temporary;
  2882. /* readonly */
  2883. StringHash type;
  2884. /* readonly */
  2885. String typeName;
  2886. /* readonly */
  2887. int weakRefs;
  2888. };
  2889. class Controls
  2890. {
  2891. // Methods:
  2892. bool IsDown(uint) const;
  2893. bool IsPressed(uint, const Controls&) const;
  2894. void Reset();
  2895. void Set(uint, bool);
  2896. // Properties:
  2897. uint buttons;
  2898. VariantMap extraData;
  2899. float pitch;
  2900. float yaw;
  2901. };
  2902. class Cursor
  2903. {
  2904. // Methods:
  2905. void AddChild(UIElement);
  2906. void ApplyAttributes();
  2907. void BringToFront();
  2908. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  2909. void DefineShape(CursorShape, Texture, const IntRect&, const IntVector2&);
  2910. void DefineShape(const String&, Texture, const IntRect&, const IntVector2&);
  2911. void DisableLayoutUpdate();
  2912. IntVector2 ElementToScreen(const IntVector2&);
  2913. void EnableLayoutUpdate();
  2914. uint FindChild(UIElement) const;
  2915. Variant GetAttribute(const String&) const;
  2916. ValueAnimation GetAttributeAnimation(const String&) const;
  2917. float GetAttributeAnimationSpeed(const String&) const;
  2918. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  2919. Variant GetAttributeDefault(const String&) const;
  2920. UIElement GetChild(const String&, bool = false) const;
  2921. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  2922. Array<UIElement> GetChildren(bool = false) const;
  2923. UIElement GetElementEventSender() const;
  2924. uint GetNumChildren(bool) const;
  2925. void InsertChild(uint, UIElement);
  2926. bool IsInside(IntVector2, bool);
  2927. bool IsInsideCombined(IntVector2, bool);
  2928. bool Load(File, bool = false);
  2929. bool Load(VectorBuffer&, bool = false);
  2930. bool LoadChildXML(XMLFile, XMLFile = null);
  2931. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  2932. bool LoadXML(File);
  2933. bool LoadXML(VectorBuffer&);
  2934. bool LoadXML(XMLFile, XMLFile);
  2935. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  2936. bool LoadXML(const XMLElement&, bool = false);
  2937. void MarkNetworkUpdate() const;
  2938. void Remove();
  2939. void RemoveAllChildren();
  2940. void RemoveChild(UIElement, uint = 0);
  2941. void RemoveChild(uint);
  2942. void RemoveInstanceDefault();
  2943. void ResetDeepEnabled();
  2944. void ResetToDefault();
  2945. bool Save(File) const;
  2946. bool Save(VectorBuffer&) const;
  2947. bool SaveXML(File);
  2948. bool SaveXML(VectorBuffer&);
  2949. bool SaveXML(XMLElement&) const;
  2950. IntVector2 ScreenToElement(const IntVector2&);
  2951. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  2952. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  2953. bool SetAttribute(const String&, const Variant&);
  2954. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  2955. void SetAttributeAnimationSpeed(const String&, float);
  2956. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  2957. void SetDeepEnabled(bool);
  2958. void SetEnabledRecursive(bool);
  2959. void SetFixedHeight(int);
  2960. void SetFixedSize(int, int);
  2961. void SetFixedWidth(int);
  2962. void SetFullImageRect();
  2963. void SetHoverOffset(int, int);
  2964. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  2965. void SetMaxSize(int, int);
  2966. void SetMinSize(int, int);
  2967. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  2968. void SetPosition(int, int);
  2969. void SetShape(CursorShape);
  2970. void SetShape(const String&);
  2971. void SetSize(int, int);
  2972. bool SetStyle(const String&, XMLFile = null);
  2973. bool SetStyle(const XMLElement&);
  2974. bool SetStyleAuto(XMLFile = null);
  2975. void UpdateLayout();
  2976. const Variant& GetVar(const StringHash&);
  2977. // Properties:
  2978. bool animationEnabled;
  2979. /* readonly */
  2980. Array<Variant> attributeDefaults;
  2981. /* readonly */
  2982. Array<AttributeInfo> attributeInfos;
  2983. Array<Variant> attributes;
  2984. /* readonly */
  2985. StringHash baseType;
  2986. BlendMode blendMode;
  2987. IntRect border;
  2988. bool bringToBack;
  2989. bool bringToFront;
  2990. /* readonly */
  2991. String category;
  2992. /* readonly */
  2993. IntVector2 childOffset;
  2994. /* readonly */
  2995. Array<UIElement> children;
  2996. IntRect clipBorder;
  2997. bool clipChildren;
  2998. /* writeonly */
  2999. Color color;
  3000. /* readonly */
  3001. bool colorGradient;
  3002. Array<Color> colors;
  3003. /* readonly */
  3004. IntRect combinedScreenRect;
  3005. XMLFile defaultStyle;
  3006. /* readonly */
  3007. float derivedOpacity;
  3008. /* readonly */
  3009. uint dragButtonCombo;
  3010. /* readonly */
  3011. int dragButtonCount;
  3012. uint dragDropMode;
  3013. bool editable;
  3014. bool elementEventSender;
  3015. bool enabled;
  3016. /* readonly */
  3017. bool enabledSelf;
  3018. /* readonly */
  3019. bool fixedHeight;
  3020. /* readonly */
  3021. bool fixedSize;
  3022. /* readonly */
  3023. bool fixedWidth;
  3024. bool focus;
  3025. FocusMode focusMode;
  3026. int height;
  3027. HorizontalAlignment horizontalAlignment;
  3028. IntVector2 hoverOffset;
  3029. /* readonly */
  3030. bool hovering;
  3031. IntRect imageBorder;
  3032. IntRect imageRect;
  3033. int indent;
  3034. int indentSpacing;
  3035. /* readonly */
  3036. int indentWidth;
  3037. bool internal;
  3038. IntRect layoutBorder;
  3039. Vector2 layoutFlexScale;
  3040. LayoutMode layoutMode;
  3041. int layoutSpacing;
  3042. int maxHeight;
  3043. IntVector2 maxSize;
  3044. int maxWidth;
  3045. int minHeight;
  3046. IntVector2 minSize;
  3047. int minWidth;
  3048. String name;
  3049. /* readonly */
  3050. uint numAllChildren;
  3051. /* readonly */
  3052. uint numAttributes;
  3053. /* readonly */
  3054. uint numChildren;
  3055. ObjectAnimation objectAnimation;
  3056. float opacity;
  3057. UIElement parent;
  3058. IntVector2 position;
  3059. int priority;
  3060. /* readonly */
  3061. int refs;
  3062. /* readonly */
  3063. UIElement root;
  3064. /* readonly */
  3065. IntVector2 screenPosition;
  3066. bool selected;
  3067. String shape;
  3068. IntVector2 size;
  3069. bool sortChildren;
  3070. String style;
  3071. bool temporary;
  3072. Texture texture;
  3073. bool tiled;
  3074. TraversalMode traversalMode;
  3075. /* readonly */
  3076. StringHash type;
  3077. /* readonly */
  3078. String typeName;
  3079. bool useDerivedOpacity;
  3080. bool useSystemShapes;
  3081. /* readonly */
  3082. VariantMap vars;
  3083. VerticalAlignment verticalAlignment;
  3084. bool visible;
  3085. /* readonly */
  3086. int weakRefs;
  3087. int width;
  3088. };
  3089. class CustomGeometry
  3090. {
  3091. // Methods:
  3092. void ApplyAttributes();
  3093. void BeginGeometry(uint, PrimitiveType);
  3094. void Clear();
  3095. void Commit();
  3096. void DefineColor(const Color&);
  3097. void DefineGeometry(uint, PrimitiveType, uint, bool, bool, bool, bool);
  3098. void DefineNormal(const Vector3&);
  3099. void DefineTangent(const Vector4&);
  3100. void DefineTexCoord(const Vector2&);
  3101. void DefineVertex(const Vector3&);
  3102. void DrawDebugGeometry(DebugRenderer, bool);
  3103. Variant GetAttribute(const String&) const;
  3104. ValueAnimation GetAttributeAnimation(const String&) const;
  3105. float GetAttributeAnimationSpeed(const String&) const;
  3106. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3107. Variant GetAttributeDefault(const String&) const;
  3108. CustomGeometryVertex GetVertex(uint, uint);
  3109. bool IsInView(Camera) const;
  3110. bool Load(File, bool = false);
  3111. bool Load(VectorBuffer&, bool = false);
  3112. bool LoadXML(const XMLElement&, bool = false);
  3113. void MarkNetworkUpdate() const;
  3114. void Remove();
  3115. void RemoveInstanceDefault();
  3116. void ResetToDefault();
  3117. bool Save(File) const;
  3118. bool Save(VectorBuffer&) const;
  3119. bool SaveXML(XMLElement&) const;
  3120. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3121. bool SetAttribute(const String&, const Variant&);
  3122. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3123. void SetAttributeAnimationSpeed(const String&, float);
  3124. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3125. // Properties:
  3126. bool animationEnabled;
  3127. /* readonly */
  3128. Array<Variant> attributeDefaults;
  3129. /* readonly */
  3130. Array<AttributeInfo> attributeInfos;
  3131. Array<Variant> attributes;
  3132. /* readonly */
  3133. StringHash baseType;
  3134. /* readonly */
  3135. BoundingBox boundingBox;
  3136. bool castShadows;
  3137. /* readonly */
  3138. String category;
  3139. float drawDistance;
  3140. bool dynamic;
  3141. bool enabled;
  3142. /* readonly */
  3143. bool enabledEffective;
  3144. /* readonly */
  3145. uint id;
  3146. /* readonly */
  3147. bool inView;
  3148. uint lightMask;
  3149. float lodBias;
  3150. /* writeonly */
  3151. Material material;
  3152. Array<Material> materials;
  3153. uint maxLights;
  3154. /* readonly */
  3155. Node node;
  3156. /* readonly */
  3157. uint numAttributes;
  3158. uint numGeometries;
  3159. /* readonly */
  3160. Array<uint> numVertices;
  3161. ObjectAnimation objectAnimation;
  3162. bool occludee;
  3163. bool occluder;
  3164. /* readonly */
  3165. int refs;
  3166. float shadowDistance;
  3167. uint shadowMask;
  3168. bool temporary;
  3169. /* readonly */
  3170. StringHash type;
  3171. /* readonly */
  3172. String typeName;
  3173. uint viewMask;
  3174. /* readonly */
  3175. int weakRefs;
  3176. /* readonly */
  3177. BoundingBox worldBoundingBox;
  3178. /* readonly */
  3179. Zone zone;
  3180. uint zoneMask;
  3181. };
  3182. class CustomGeometryVertex
  3183. {
  3184. // Properties:
  3185. uint color;
  3186. Vector3 normal;
  3187. Vector3 position;
  3188. Vector4 tangent;
  3189. Vector2 texCoord;
  3190. };
  3191. class DebugHud
  3192. {
  3193. // Methods:
  3194. void ClearAppStats();
  3195. void ResetAppStats(const String&);
  3196. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3197. void SetAppStats(const String&, const String&);
  3198. void SetAppStats(const String&, const Variant&);
  3199. void Toggle(uint);
  3200. void ToggleAll();
  3201. void Update();
  3202. // Properties:
  3203. /* readonly */
  3204. StringHash baseType;
  3205. /* readonly */
  3206. String category;
  3207. XMLFile defaultStyle;
  3208. uint mode;
  3209. /* readonly */
  3210. Text modeText;
  3211. float profilerInterval;
  3212. uint profilerMaxDepth;
  3213. /* readonly */
  3214. Text profilerText;
  3215. /* readonly */
  3216. int refs;
  3217. /* readonly */
  3218. Text statsText;
  3219. /* readonly */
  3220. StringHash type;
  3221. /* readonly */
  3222. String typeName;
  3223. bool useRendererStats;
  3224. /* readonly */
  3225. int weakRefs;
  3226. };
  3227. class DebugRenderer
  3228. {
  3229. // Methods:
  3230. void AddBoundingBox(const BoundingBox&, const Color&, bool = true);
  3231. void AddFrustum(const Frustum&, const Color&, bool = true);
  3232. void AddLine(const Vector3&, const Vector3&, const Color&, bool = true);
  3233. void AddNode(Node, float = 1.0, bool = true);
  3234. void AddPolyhedron(const Polyhedron&, const Color&, bool = true);
  3235. void AddSkeleton(Skeleton, const Color&, bool = true);
  3236. void AddSphere(const Sphere&, const Color&, bool = true);
  3237. void AddTriangle(const Vector3&, const Vector3&, const Vector3&, const Color&, bool = true);
  3238. void ApplyAttributes();
  3239. void DrawDebugGeometry(DebugRenderer, bool);
  3240. Variant GetAttribute(const String&) const;
  3241. ValueAnimation GetAttributeAnimation(const String&) const;
  3242. float GetAttributeAnimationSpeed(const String&) const;
  3243. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3244. Variant GetAttributeDefault(const String&) const;
  3245. bool Load(File, bool = false);
  3246. bool Load(VectorBuffer&, bool = false);
  3247. bool LoadXML(const XMLElement&, bool = false);
  3248. void MarkNetworkUpdate() const;
  3249. void Remove();
  3250. void RemoveInstanceDefault();
  3251. void ResetToDefault();
  3252. bool Save(File) const;
  3253. bool Save(VectorBuffer&) const;
  3254. bool SaveXML(XMLElement&) const;
  3255. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3256. bool SetAttribute(const String&, const Variant&);
  3257. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3258. void SetAttributeAnimationSpeed(const String&, float);
  3259. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3260. // Properties:
  3261. bool animationEnabled;
  3262. /* readonly */
  3263. Array<Variant> attributeDefaults;
  3264. /* readonly */
  3265. Array<AttributeInfo> attributeInfos;
  3266. Array<Variant> attributes;
  3267. /* readonly */
  3268. StringHash baseType;
  3269. /* readonly */
  3270. String category;
  3271. bool enabled;
  3272. /* readonly */
  3273. bool enabledEffective;
  3274. /* readonly */
  3275. uint id;
  3276. /* readonly */
  3277. Node node;
  3278. /* readonly */
  3279. uint numAttributes;
  3280. ObjectAnimation objectAnimation;
  3281. /* readonly */
  3282. int refs;
  3283. bool temporary;
  3284. /* readonly */
  3285. StringHash type;
  3286. /* readonly */
  3287. String typeName;
  3288. /* readonly */
  3289. int weakRefs;
  3290. };
  3291. class DecalSet
  3292. {
  3293. // Methods:
  3294. bool AddDecal(Drawable, const Vector3&, const Quaternion&, float, float, float, const Vector2&, const Vector2&, float = 0.0, float = 0.1, uint = 0xffffffff);
  3295. void ApplyAttributes();
  3296. void DrawDebugGeometry(DebugRenderer, bool);
  3297. Variant GetAttribute(const String&) const;
  3298. ValueAnimation GetAttributeAnimation(const String&) const;
  3299. float GetAttributeAnimationSpeed(const String&) const;
  3300. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3301. Variant GetAttributeDefault(const String&) const;
  3302. bool IsInView(Camera) const;
  3303. bool Load(File, bool = false);
  3304. bool Load(VectorBuffer&, bool = false);
  3305. bool LoadXML(const XMLElement&, bool = false);
  3306. void MarkNetworkUpdate() const;
  3307. void Remove();
  3308. void RemoveAllDecals();
  3309. void RemoveDecals(uint);
  3310. void RemoveInstanceDefault();
  3311. void ResetToDefault();
  3312. bool Save(File) const;
  3313. bool Save(VectorBuffer&) const;
  3314. bool SaveXML(XMLElement&) const;
  3315. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3316. bool SetAttribute(const String&, const Variant&);
  3317. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3318. void SetAttributeAnimationSpeed(const String&, float);
  3319. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3320. // Properties:
  3321. bool animationEnabled;
  3322. /* readonly */
  3323. Array<Variant> attributeDefaults;
  3324. /* readonly */
  3325. Array<AttributeInfo> attributeInfos;
  3326. Array<Variant> attributes;
  3327. /* readonly */
  3328. StringHash baseType;
  3329. /* readonly */
  3330. BoundingBox boundingBox;
  3331. bool castShadows;
  3332. /* readonly */
  3333. String category;
  3334. float drawDistance;
  3335. bool enabled;
  3336. /* readonly */
  3337. bool enabledEffective;
  3338. /* readonly */
  3339. uint id;
  3340. /* readonly */
  3341. bool inView;
  3342. uint lightMask;
  3343. float lodBias;
  3344. Material material;
  3345. uint maxIndices;
  3346. uint maxLights;
  3347. uint maxVertices;
  3348. /* readonly */
  3349. Node node;
  3350. /* readonly */
  3351. uint numAttributes;
  3352. /* readonly */
  3353. uint numDecals;
  3354. /* readonly */
  3355. uint numIndices;
  3356. /* readonly */
  3357. uint numVertices;
  3358. ObjectAnimation objectAnimation;
  3359. bool occludee;
  3360. bool occluder;
  3361. /* readonly */
  3362. int refs;
  3363. float shadowDistance;
  3364. uint shadowMask;
  3365. bool temporary;
  3366. /* readonly */
  3367. StringHash type;
  3368. /* readonly */
  3369. String typeName;
  3370. uint viewMask;
  3371. /* readonly */
  3372. int weakRefs;
  3373. /* readonly */
  3374. BoundingBox worldBoundingBox;
  3375. /* readonly */
  3376. Zone zone;
  3377. uint zoneMask;
  3378. };
  3379. class Deserializer
  3380. {
  3381. // Methods:
  3382. Array<uint8> Read(uint);
  3383. bool ReadBool();
  3384. BoundingBox ReadBoundingBox();
  3385. int8 ReadByte();
  3386. Color ReadColor();
  3387. String ReadFileID();
  3388. float ReadFloat();
  3389. int ReadInt();
  3390. IntRect ReadIntRect();
  3391. IntVector2 ReadIntVector2();
  3392. String ReadLine();
  3393. Matrix3 ReadMatrix3();
  3394. Matrix3x4 ReadMatrix3x4();
  3395. Matrix4 ReadMatrix4();
  3396. uint ReadNetID();
  3397. Quaternion ReadPackedQuaternion();
  3398. Vector3 ReadPackedVector3(float);
  3399. Quaternion ReadQuaternion();
  3400. int16 ReadShort();
  3401. String ReadString();
  3402. StringHash ReadStringHash();
  3403. uint8 ReadUByte();
  3404. uint ReadUInt();
  3405. uint16 ReadUShort();
  3406. uint ReadVLE();
  3407. Variant ReadVariant();
  3408. VariantMap ReadVariantMap();
  3409. Vector2 ReadVector2();
  3410. Vector3 ReadVector3();
  3411. Vector4 ReadVector4();
  3412. VectorBuffer ReadVectorBuffer(uint);
  3413. uint Seek(uint);
  3414. // Properties:
  3415. /* readonly */
  3416. uint checksum;
  3417. /* readonly */
  3418. bool eof;
  3419. /* readonly */
  3420. String name;
  3421. /* readonly */
  3422. uint position;
  3423. /* readonly */
  3424. uint size;
  3425. };
  3426. class Dictionary
  3427. {
  3428. // Methods:
  3429. void Clear();
  3430. void Erase(const String&);
  3431. bool Exists(const String&) const;
  3432. bool Get(const String&, void*) const;
  3433. bool Get(const String&, double&) const;
  3434. bool Get(const String&, int64&) const;
  3435. void Set(const String&, const void*);
  3436. void Set(const String&, const double&);
  3437. void Set(const String&, const int64&);
  3438. // Properties:
  3439. /* readonly */
  3440. bool empty;
  3441. /* readonly */
  3442. Array<String> keys;
  3443. /* readonly */
  3444. uint length;
  3445. };
  3446. class DictionaryValue
  3447. {
  3448. };
  3449. class Drawable
  3450. {
  3451. // Methods:
  3452. void ApplyAttributes();
  3453. void DrawDebugGeometry(DebugRenderer, bool);
  3454. Variant GetAttribute(const String&) const;
  3455. ValueAnimation GetAttributeAnimation(const String&) const;
  3456. float GetAttributeAnimationSpeed(const String&) const;
  3457. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3458. Variant GetAttributeDefault(const String&) const;
  3459. bool IsInView(Camera) const;
  3460. bool Load(File, bool = false);
  3461. bool Load(VectorBuffer&, bool = false);
  3462. bool LoadXML(const XMLElement&, bool = false);
  3463. void MarkNetworkUpdate() const;
  3464. void Remove();
  3465. void RemoveInstanceDefault();
  3466. void ResetToDefault();
  3467. bool Save(File) const;
  3468. bool Save(VectorBuffer&) const;
  3469. bool SaveXML(XMLElement&) const;
  3470. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3471. bool SetAttribute(const String&, const Variant&);
  3472. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3473. void SetAttributeAnimationSpeed(const String&, float);
  3474. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3475. // Properties:
  3476. bool animationEnabled;
  3477. /* readonly */
  3478. Array<Variant> attributeDefaults;
  3479. /* readonly */
  3480. Array<AttributeInfo> attributeInfos;
  3481. Array<Variant> attributes;
  3482. /* readonly */
  3483. StringHash baseType;
  3484. /* readonly */
  3485. BoundingBox boundingBox;
  3486. bool castShadows;
  3487. /* readonly */
  3488. String category;
  3489. float drawDistance;
  3490. bool enabled;
  3491. /* readonly */
  3492. bool enabledEffective;
  3493. /* readonly */
  3494. uint id;
  3495. /* readonly */
  3496. bool inView;
  3497. uint lightMask;
  3498. float lodBias;
  3499. uint maxLights;
  3500. /* readonly */
  3501. Node node;
  3502. /* readonly */
  3503. uint numAttributes;
  3504. ObjectAnimation objectAnimation;
  3505. bool occludee;
  3506. bool occluder;
  3507. /* readonly */
  3508. int refs;
  3509. float shadowDistance;
  3510. uint shadowMask;
  3511. bool temporary;
  3512. /* readonly */
  3513. StringHash type;
  3514. /* readonly */
  3515. String typeName;
  3516. uint viewMask;
  3517. /* readonly */
  3518. int weakRefs;
  3519. /* readonly */
  3520. BoundingBox worldBoundingBox;
  3521. uint zoneMask;
  3522. };
  3523. class Drawable2D
  3524. {
  3525. // Methods:
  3526. void ApplyAttributes();
  3527. void DrawDebugGeometry(DebugRenderer, bool);
  3528. Variant GetAttribute(const String&) const;
  3529. ValueAnimation GetAttributeAnimation(const String&) const;
  3530. float GetAttributeAnimationSpeed(const String&) const;
  3531. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3532. Variant GetAttributeDefault(const String&) const;
  3533. bool IsInView(Camera) const;
  3534. bool Load(File, bool = false);
  3535. bool Load(VectorBuffer&, bool = false);
  3536. bool LoadXML(const XMLElement&, bool = false);
  3537. void MarkNetworkUpdate() const;
  3538. void Remove();
  3539. void RemoveInstanceDefault();
  3540. void ResetToDefault();
  3541. bool Save(File) const;
  3542. bool Save(VectorBuffer&) const;
  3543. bool SaveXML(XMLElement&) const;
  3544. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3545. bool SetAttribute(const String&, const Variant&);
  3546. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3547. void SetAttributeAnimationSpeed(const String&, float);
  3548. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3549. // Properties:
  3550. bool animationEnabled;
  3551. /* readonly */
  3552. Array<Variant> attributeDefaults;
  3553. /* readonly */
  3554. Array<AttributeInfo> attributeInfos;
  3555. Array<Variant> attributes;
  3556. /* readonly */
  3557. StringHash baseType;
  3558. BlendMode blendMode;
  3559. /* readonly */
  3560. BoundingBox boundingBox;
  3561. bool castShadows;
  3562. /* readonly */
  3563. String category;
  3564. float drawDistance;
  3565. bool enabled;
  3566. /* readonly */
  3567. bool enabledEffective;
  3568. /* readonly */
  3569. uint id;
  3570. /* readonly */
  3571. bool inView;
  3572. int layer;
  3573. uint lightMask;
  3574. float lodBias;
  3575. uint maxLights;
  3576. /* readonly */
  3577. Node node;
  3578. /* readonly */
  3579. uint numAttributes;
  3580. ObjectAnimation objectAnimation;
  3581. bool occludee;
  3582. bool occluder;
  3583. int orderInLayer;
  3584. /* readonly */
  3585. int refs;
  3586. float shadowDistance;
  3587. uint shadowMask;
  3588. bool temporary;
  3589. Texture2D texture;
  3590. /* readonly */
  3591. StringHash type;
  3592. /* readonly */
  3593. String typeName;
  3594. uint viewMask;
  3595. /* readonly */
  3596. int weakRefs;
  3597. /* readonly */
  3598. BoundingBox worldBoundingBox;
  3599. uint zoneMask;
  3600. };
  3601. class DropDownList
  3602. {
  3603. // Methods:
  3604. void AddChild(UIElement);
  3605. void AddItem(UIElement);
  3606. void ApplyAttributes();
  3607. void BringToFront();
  3608. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  3609. void DisableLayoutUpdate();
  3610. IntVector2 ElementToScreen(const IntVector2&);
  3611. void EnableLayoutUpdate();
  3612. uint FindChild(UIElement) const;
  3613. Variant GetAttribute(const String&) const;
  3614. ValueAnimation GetAttributeAnimation(const String&) const;
  3615. float GetAttributeAnimationSpeed(const String&) const;
  3616. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  3617. Variant GetAttributeDefault(const String&) const;
  3618. UIElement GetChild(const String&, bool = false) const;
  3619. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  3620. Array<UIElement> GetChildren(bool = false) const;
  3621. UIElement GetElementEventSender() const;
  3622. Array<UIElement> GetItems() const;
  3623. uint GetNumChildren(bool) const;
  3624. void InsertChild(uint, UIElement);
  3625. void InsertItem(uint, UIElement);
  3626. bool IsInside(IntVector2, bool);
  3627. bool IsInsideCombined(IntVector2, bool);
  3628. bool Load(File, bool = false);
  3629. bool Load(VectorBuffer&, bool = false);
  3630. bool LoadChildXML(XMLFile, XMLFile = null);
  3631. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  3632. bool LoadXML(File);
  3633. bool LoadXML(VectorBuffer&);
  3634. bool LoadXML(XMLFile, XMLFile);
  3635. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  3636. bool LoadXML(const XMLElement&, bool = false);
  3637. void MarkNetworkUpdate() const;
  3638. void Remove();
  3639. void RemoveAllChildren();
  3640. void RemoveAllItems();
  3641. void RemoveChild(UIElement, uint = 0);
  3642. void RemoveChild(uint);
  3643. void RemoveInstanceDefault();
  3644. void RemoveItem(UIElement);
  3645. void RemoveItem(uint);
  3646. void ResetDeepEnabled();
  3647. void ResetToDefault();
  3648. bool Save(File) const;
  3649. bool Save(VectorBuffer&) const;
  3650. bool SaveXML(File);
  3651. bool SaveXML(VectorBuffer&);
  3652. bool SaveXML(XMLElement&) const;
  3653. IntVector2 ScreenToElement(const IntVector2&);
  3654. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3655. void SetAccelerator(int, int);
  3656. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  3657. bool SetAttribute(const String&, const Variant&);
  3658. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  3659. void SetAttributeAnimationSpeed(const String&, float);
  3660. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  3661. void SetDeepEnabled(bool);
  3662. void SetEnabledRecursive(bool);
  3663. void SetFixedHeight(int);
  3664. void SetFixedSize(int, int);
  3665. void SetFixedWidth(int);
  3666. void SetFullImageRect();
  3667. void SetHoverOffset(int, int);
  3668. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  3669. void SetMaxSize(int, int);
  3670. void SetMinSize(int, int);
  3671. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  3672. void SetPosition(int, int);
  3673. void SetPressedChildOffset(int, int);
  3674. void SetPressedOffset(int, int);
  3675. void SetRepeat(float, float);
  3676. void SetSize(int, int);
  3677. bool SetStyle(const String&, XMLFile = null);
  3678. bool SetStyle(const XMLElement&);
  3679. bool SetStyleAuto(XMLFile = null);
  3680. void UpdateLayout();
  3681. const Variant& GetVar(const StringHash&);
  3682. UIElement getPopup() const;
  3683. // Properties:
  3684. /* readonly */
  3685. int acceleratorKey;
  3686. /* readonly */
  3687. int acceleratorQualifiers;
  3688. bool animationEnabled;
  3689. /* readonly */
  3690. Array<Variant> attributeDefaults;
  3691. /* readonly */
  3692. Array<AttributeInfo> attributeInfos;
  3693. Array<Variant> attributes;
  3694. /* readonly */
  3695. StringHash baseType;
  3696. BlendMode blendMode;
  3697. IntRect border;
  3698. bool bringToBack;
  3699. bool bringToFront;
  3700. /* readonly */
  3701. String category;
  3702. /* readonly */
  3703. IntVector2 childOffset;
  3704. /* readonly */
  3705. Array<UIElement> children;
  3706. IntRect clipBorder;
  3707. bool clipChildren;
  3708. /* writeonly */
  3709. Color color;
  3710. /* readonly */
  3711. bool colorGradient;
  3712. Array<Color> colors;
  3713. /* readonly */
  3714. IntRect combinedScreenRect;
  3715. XMLFile defaultStyle;
  3716. /* readonly */
  3717. float derivedOpacity;
  3718. /* readonly */
  3719. uint dragButtonCombo;
  3720. /* readonly */
  3721. int dragButtonCount;
  3722. uint dragDropMode;
  3723. bool editable;
  3724. bool elementEventSender;
  3725. bool enabled;
  3726. /* readonly */
  3727. bool enabledSelf;
  3728. /* readonly */
  3729. bool fixedHeight;
  3730. /* readonly */
  3731. bool fixedSize;
  3732. /* readonly */
  3733. bool fixedWidth;
  3734. bool focus;
  3735. FocusMode focusMode;
  3736. int height;
  3737. HorizontalAlignment horizontalAlignment;
  3738. IntVector2 hoverOffset;
  3739. /* readonly */
  3740. bool hovering;
  3741. IntRect imageBorder;
  3742. IntRect imageRect;
  3743. int indent;
  3744. int indentSpacing;
  3745. /* readonly */
  3746. int indentWidth;
  3747. bool internal;
  3748. /* readonly */
  3749. Array<UIElement> items;
  3750. IntRect layoutBorder;
  3751. Vector2 layoutFlexScale;
  3752. LayoutMode layoutMode;
  3753. int layoutSpacing;
  3754. /* readonly */
  3755. ListView listView;
  3756. int maxHeight;
  3757. IntVector2 maxSize;
  3758. int maxWidth;
  3759. int minHeight;
  3760. IntVector2 minSize;
  3761. int minWidth;
  3762. String name;
  3763. /* readonly */
  3764. uint numAllChildren;
  3765. /* readonly */
  3766. uint numAttributes;
  3767. /* readonly */
  3768. uint numChildren;
  3769. /* readonly */
  3770. uint numItems;
  3771. ObjectAnimation objectAnimation;
  3772. float opacity;
  3773. UIElement parent;
  3774. /* readonly */
  3775. UIElement placeholder;
  3776. String placeholderText;
  3777. IntVector2 position;
  3778. /* readonly */
  3779. bool pressed;
  3780. IntVector2 pressedChildOffset;
  3781. IntVector2 pressedOffset;
  3782. int priority;
  3783. /* readonly */
  3784. int refs;
  3785. float repeatDelay;
  3786. float repeatRate;
  3787. bool resizePopup;
  3788. /* readonly */
  3789. UIElement root;
  3790. /* readonly */
  3791. IntVector2 screenPosition;
  3792. bool selected;
  3793. /* readonly */
  3794. UIElement selectedItem;
  3795. uint selection;
  3796. bool showPopup;
  3797. IntVector2 size;
  3798. bool sortChildren;
  3799. String style;
  3800. bool temporary;
  3801. Texture texture;
  3802. bool tiled;
  3803. TraversalMode traversalMode;
  3804. /* readonly */
  3805. StringHash type;
  3806. /* readonly */
  3807. String typeName;
  3808. bool useDerivedOpacity;
  3809. /* readonly */
  3810. VariantMap vars;
  3811. VerticalAlignment verticalAlignment;
  3812. bool visible;
  3813. /* readonly */
  3814. int weakRefs;
  3815. int width;
  3816. };
  3817. class Engine
  3818. {
  3819. // Methods:
  3820. Console CreateConsole();
  3821. DebugHud CreateDebugHud();
  3822. void DumpMemory();
  3823. void DumpProfiler();
  3824. void DumpResources(bool = false);
  3825. void Exit();
  3826. void RunFrame();
  3827. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3828. // Properties:
  3829. bool autoExit;
  3830. /* readonly */
  3831. StringHash baseType;
  3832. /* readonly */
  3833. String category;
  3834. /* readonly */
  3835. bool exiting;
  3836. /* readonly */
  3837. bool headless;
  3838. /* readonly */
  3839. bool initialized;
  3840. int maxFps;
  3841. int maxInactiveFps;
  3842. int minFps;
  3843. bool pauseMinimized;
  3844. /* readonly */
  3845. int refs;
  3846. int timeStepSmoothing;
  3847. /* readonly */
  3848. StringHash type;
  3849. /* readonly */
  3850. String typeName;
  3851. /* readonly */
  3852. int weakRefs;
  3853. };
  3854. class File
  3855. {
  3856. // Methods:
  3857. void Close();
  3858. bool Open(const String&, FileMode = FILE_READ);
  3859. Array<uint8> Read(uint);
  3860. bool ReadBool();
  3861. BoundingBox ReadBoundingBox();
  3862. int8 ReadByte();
  3863. Color ReadColor();
  3864. String ReadFileID();
  3865. float ReadFloat();
  3866. int ReadInt();
  3867. IntRect ReadIntRect();
  3868. IntVector2 ReadIntVector2();
  3869. String ReadLine();
  3870. Matrix3 ReadMatrix3();
  3871. Matrix3x4 ReadMatrix3x4();
  3872. Matrix4 ReadMatrix4();
  3873. uint ReadNetID();
  3874. Quaternion ReadPackedQuaternion();
  3875. Vector3 ReadPackedVector3(float);
  3876. Quaternion ReadQuaternion();
  3877. int16 ReadShort();
  3878. String ReadString();
  3879. StringHash ReadStringHash();
  3880. uint8 ReadUByte();
  3881. uint ReadUInt();
  3882. uint16 ReadUShort();
  3883. uint ReadVLE();
  3884. Variant ReadVariant();
  3885. VariantMap ReadVariantMap();
  3886. Vector2 ReadVector2();
  3887. Vector3 ReadVector3();
  3888. Vector4 ReadVector4();
  3889. VectorBuffer ReadVectorBuffer(uint);
  3890. uint Seek(uint);
  3891. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3892. uint Write(Array<uint8>);
  3893. bool WriteBool(bool);
  3894. bool WriteBoundingBox(const BoundingBox&);
  3895. bool WriteByte(int8);
  3896. bool WriteColor(const Color&);
  3897. bool WriteFileID(const String&);
  3898. bool WriteFloat(float);
  3899. bool WriteInt(int);
  3900. bool WriteIntRect(const IntRect&);
  3901. bool WriteIntVector2(const IntVector2&);
  3902. bool WriteLine(const String&);
  3903. bool WriteMatrix3(const Matrix3&);
  3904. bool WriteMatrix3x4(const Matrix3x4&);
  3905. bool WriteMatrix4(const Matrix4&);
  3906. bool WriteNetID(uint);
  3907. bool WritePackedQuaternion(const Quaternion&);
  3908. bool WritePackedVector3(const Vector3&, float);
  3909. bool WriteQuaternion(const Quaternion&);
  3910. bool WriteShort(int16);
  3911. bool WriteString(const String&);
  3912. bool WriteStringHash(const StringHash&);
  3913. bool WriteUByte(uint8);
  3914. bool WriteUInt(uint);
  3915. bool WriteUShort(uint16);
  3916. bool WriteVLE(uint);
  3917. bool WriteVariant(const Variant&);
  3918. bool WriteVariantMap(const VariantMap&);
  3919. bool WriteVector2(const Vector2&);
  3920. bool WriteVector3(const Vector3&);
  3921. bool WriteVector4(const Vector4&);
  3922. bool WriteVectorBuffer(const VectorBuffer&);
  3923. // Properties:
  3924. /* readonly */
  3925. StringHash baseType;
  3926. /* readonly */
  3927. String category;
  3928. /* readonly */
  3929. uint checksum;
  3930. /* readonly */
  3931. bool eof;
  3932. /* readonly */
  3933. FileMode mode;
  3934. /* readonly */
  3935. String name;
  3936. /* readonly */
  3937. bool open;
  3938. /* readonly */
  3939. bool packaged;
  3940. /* readonly */
  3941. uint position;
  3942. /* readonly */
  3943. int refs;
  3944. /* readonly */
  3945. uint size;
  3946. /* readonly */
  3947. StringHash type;
  3948. /* readonly */
  3949. String typeName;
  3950. /* readonly */
  3951. int weakRefs;
  3952. };
  3953. class FileSelector
  3954. {
  3955. // Methods:
  3956. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  3957. void SetButtonTexts(const String&, const String&);
  3958. void SetFilters(Array<String>, uint);
  3959. void UpdateElements();
  3960. // Properties:
  3961. /* readonly */
  3962. StringHash baseType;
  3963. /* readonly */
  3964. Button cancelButton;
  3965. /* readonly */
  3966. String category;
  3967. XMLFile defaultStyle;
  3968. bool directoryMode;
  3969. /* readonly */
  3970. ListView fileList;
  3971. String fileName;
  3972. /* readonly */
  3973. LineEdit fileNameEdit;
  3974. /* readonly */
  3975. String filter;
  3976. /* readonly */
  3977. uint filterIndex;
  3978. /* readonly */
  3979. DropDownList filterList;
  3980. /* readonly */
  3981. Button okButton;
  3982. String path;
  3983. /* readonly */
  3984. LineEdit pathEdit;
  3985. /* readonly */
  3986. int refs;
  3987. String title;
  3988. /* readonly */
  3989. Text titleText;
  3990. /* readonly */
  3991. StringHash type;
  3992. /* readonly */
  3993. String typeName;
  3994. /* readonly */
  3995. int weakRefs;
  3996. /* readonly */
  3997. Window window;
  3998. };
  3999. class FileSystem
  4000. {
  4001. // Methods:
  4002. bool Copy(const String&, const String&);
  4003. bool CreateDir(const String&);
  4004. bool Delete(const String&);
  4005. bool DirExists(const String&) const;
  4006. bool FileExists(const String&) const;
  4007. String GetAppPreferencesDir(const String&, const String&) const;
  4008. uint GetLastModifiedTime(const String&) const;
  4009. bool Rename(const String&, const String&);
  4010. Array<String> ScanDir(const String&, const String&, uint, bool) const;
  4011. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4012. bool SetLastModifiedTime(const String&, uint);
  4013. int SystemCommand(const String&, bool = false);
  4014. uint SystemCommandAsync(const String&);
  4015. bool SystemOpen(const String&, const String&);
  4016. int SystemRun(const String&, Array<String>);
  4017. uint SystemRunAsync(const String&, Array<String>);
  4018. // Properties:
  4019. /* readonly */
  4020. StringHash baseType;
  4021. /* readonly */
  4022. String category;
  4023. String currentDir;
  4024. bool executeConsoleCommands;
  4025. /* readonly */
  4026. String programDir;
  4027. /* readonly */
  4028. int refs;
  4029. /* readonly */
  4030. StringHash type;
  4031. /* readonly */
  4032. String typeName;
  4033. /* readonly */
  4034. String userDocumentsDir;
  4035. /* readonly */
  4036. int weakRefs;
  4037. };
  4038. class FocusParameters
  4039. {
  4040. // Properties:
  4041. bool autoSize;
  4042. bool focus;
  4043. float minView;
  4044. bool nonUniform;
  4045. float quantize;
  4046. };
  4047. class Font
  4048. {
  4049. // Methods:
  4050. IntVector2 GetTotalGlyphOffset(int) const;
  4051. bool Load(File);
  4052. bool Load(VectorBuffer&);
  4053. bool Save(File) const;
  4054. bool Save(VectorBuffer&) const;
  4055. bool SaveXML(File, int, bool = false);
  4056. bool SaveXML(VectorBuffer&, int, bool = false);
  4057. bool SaveXML(const String&, int, bool = false);
  4058. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4059. // Properties:
  4060. IntVector2 absoluteGlyphOffset;
  4061. /* readonly */
  4062. StringHash baseType;
  4063. /* readonly */
  4064. String category;
  4065. /* readonly */
  4066. uint memoryUse;
  4067. String name;
  4068. /* readonly */
  4069. int refs;
  4070. Vector2 scaledGlyphOffset;
  4071. /* readonly */
  4072. StringHash type;
  4073. /* readonly */
  4074. String typeName;
  4075. /* readonly */
  4076. uint useTimer;
  4077. /* readonly */
  4078. int weakRefs;
  4079. };
  4080. class Frustum
  4081. {
  4082. // Methods:
  4083. void Define(const BoundingBox&, const Matrix3x4&);
  4084. void Define(const Vector3&, const Vector3&, const Matrix3x4&);
  4085. void Define(float, float, float, float, float, const Matrix3x4&);
  4086. void DefineOrtho(float, float, float, float, float, const Matrix3x4&);
  4087. float Distance(const Vector3&) const;
  4088. Intersection IsInside(const BoundingBox&);
  4089. Intersection IsInside(const Sphere&);
  4090. Intersection IsInside(const Vector3&);
  4091. void Transform(const Matrix3&);
  4092. void Transform(const Matrix3x4&);
  4093. Frustum Transformed(const Matrix3&) const;
  4094. Frustum Transformed(const Matrix3x4&) const;
  4095. // Properties:
  4096. /* readonly */
  4097. Array<Vector3> vertices;
  4098. };
  4099. class Graphics
  4100. {
  4101. // Methods:
  4102. void BeginDumpShaders(const String&);
  4103. void Close();
  4104. void EndDumpShaders();
  4105. void Maximize();
  4106. void Minimize();
  4107. void PrecacheShaders(File);
  4108. void PrecacheShaders(VectorBuffer&);
  4109. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4110. bool SetMode(int, int);
  4111. bool SetMode(int, int, bool, bool, bool, bool, bool, int);
  4112. void SetWindowPosition(int, int);
  4113. bool TakeScreenShot(Image);
  4114. bool ToggleFullscreen();
  4115. // Properties:
  4116. /* readonly */
  4117. StringHash baseType;
  4118. /* readonly */
  4119. bool borderless;
  4120. /* readonly */
  4121. String category;
  4122. /* readonly */
  4123. bool deferredSupport;
  4124. /* readonly */
  4125. IntVector2 desktopResolution;
  4126. /* readonly */
  4127. bool deviceLost;
  4128. bool flushGPU;
  4129. bool forceSM2;
  4130. /* readonly */
  4131. bool fullscreen;
  4132. /* readonly */
  4133. bool hardwareShadowSupport;
  4134. /* readonly */
  4135. int height;
  4136. /* readonly */
  4137. bool initialized;
  4138. /* readonly */
  4139. bool instancingSupport;
  4140. /* readonly */
  4141. bool lightPrepassSupport;
  4142. /* readonly */
  4143. int multiSample;
  4144. /* readonly */
  4145. Array<int> multiSampleLevels;
  4146. /* readonly */
  4147. uint numBatches;
  4148. /* readonly */
  4149. uint numPrimitives;
  4150. String orientations;
  4151. /* readonly */
  4152. bool readableDepthSupport;
  4153. /* readonly */
  4154. int refs;
  4155. /* readonly */
  4156. bool resizable;
  4157. /* readonly */
  4158. Array<IntVector2> resolutions;
  4159. bool sRGB;
  4160. /* readonly */
  4161. bool sRGBSupport;
  4162. /* readonly */
  4163. bool sRGBWriteSupport;
  4164. /* readonly */
  4165. bool sm3Support;
  4166. /* readonly */
  4167. bool tripleBuffer;
  4168. /* readonly */
  4169. StringHash type;
  4170. /* readonly */
  4171. String typeName;
  4172. /* readonly */
  4173. bool vsync;
  4174. /* readonly */
  4175. int weakRefs;
  4176. /* readonly */
  4177. int width;
  4178. /* writeonly */
  4179. Image windowIcon;
  4180. IntVector2 windowPosition;
  4181. String windowTitle;
  4182. };
  4183. class HttpRequest
  4184. {
  4185. // Methods:
  4186. Array<uint8> Read(uint);
  4187. bool ReadBool();
  4188. BoundingBox ReadBoundingBox();
  4189. int8 ReadByte();
  4190. Color ReadColor();
  4191. String ReadFileID();
  4192. float ReadFloat();
  4193. int ReadInt();
  4194. IntRect ReadIntRect();
  4195. IntVector2 ReadIntVector2();
  4196. String ReadLine();
  4197. Matrix3 ReadMatrix3();
  4198. Matrix3x4 ReadMatrix3x4();
  4199. Matrix4 ReadMatrix4();
  4200. uint ReadNetID();
  4201. Quaternion ReadPackedQuaternion();
  4202. Vector3 ReadPackedVector3(float);
  4203. Quaternion ReadQuaternion();
  4204. int16 ReadShort();
  4205. String ReadString();
  4206. StringHash ReadStringHash();
  4207. uint8 ReadUByte();
  4208. uint ReadUInt();
  4209. uint16 ReadUShort();
  4210. uint ReadVLE();
  4211. Variant ReadVariant();
  4212. VariantMap ReadVariantMap();
  4213. Vector2 ReadVector2();
  4214. Vector3 ReadVector3();
  4215. Vector4 ReadVector4();
  4216. VectorBuffer ReadVectorBuffer(uint);
  4217. uint Seek(uint);
  4218. // Properties:
  4219. /* readonly */
  4220. uint availableSize;
  4221. /* readonly */
  4222. uint checksum;
  4223. /* readonly */
  4224. bool eof;
  4225. /* readonly */
  4226. String error;
  4227. /* readonly */
  4228. String name;
  4229. /* readonly */
  4230. bool open;
  4231. /* readonly */
  4232. uint position;
  4233. /* readonly */
  4234. int refs;
  4235. /* readonly */
  4236. uint size;
  4237. /* readonly */
  4238. HttpRequestState state;
  4239. /* readonly */
  4240. String url;
  4241. /* readonly */
  4242. String verb;
  4243. /* readonly */
  4244. int weakRefs;
  4245. };
  4246. class Image
  4247. {
  4248. // Methods:
  4249. void Clear(const Color&);
  4250. void ClearInt(uint);
  4251. bool FlipHorizontal();
  4252. bool FlipVertical();
  4253. Color GetPixel(int, int) const;
  4254. Color GetPixel(int, int, int) const;
  4255. Color GetPixelBilinear(float, float) const;
  4256. uint GetPixelInt(int, int) const;
  4257. uint GetPixelInt(int, int, int) const;
  4258. Color GetPixelTrilinear(float, float, float) const;
  4259. Image GetSubimage(const IntRect&) const;
  4260. bool Load(File);
  4261. bool Load(VectorBuffer&);
  4262. bool LoadColorLUT(File);
  4263. bool LoadColorLUT(VectorBuffer&);
  4264. bool Resize(int, int);
  4265. bool Save(File) const;
  4266. bool Save(VectorBuffer&) const;
  4267. void SaveBMP(const String&) const;
  4268. void SaveJPG(const String&, int) const;
  4269. void SavePNG(const String&) const;
  4270. void SaveTGA(const String&) const;
  4271. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4272. void SetPixel(int, int, const Color&);
  4273. void SetPixel(int, int, int, const Color&);
  4274. void SetPixelInt(int, int, int, uint);
  4275. void SetPixelInt(int, int, uint);
  4276. bool SetSize(int, int, int, uint);
  4277. bool SetSize(int, int, uint);
  4278. // Properties:
  4279. /* readonly */
  4280. StringHash baseType;
  4281. /* readonly */
  4282. String category;
  4283. /* readonly */
  4284. uint components;
  4285. /* readonly */
  4286. bool compressed;
  4287. /* readonly */
  4288. CompressedFormat compressedFormat;
  4289. /* readonly */
  4290. int depth;
  4291. /* readonly */
  4292. int height;
  4293. /* readonly */
  4294. uint memoryUse;
  4295. String name;
  4296. /* readonly */
  4297. uint numCompressedLevels;
  4298. /* readonly */
  4299. int refs;
  4300. /* readonly */
  4301. StringHash type;
  4302. /* readonly */
  4303. String typeName;
  4304. /* readonly */
  4305. uint useTimer;
  4306. /* readonly */
  4307. int weakRefs;
  4308. /* readonly */
  4309. int width;
  4310. };
  4311. class Input
  4312. {
  4313. // Methods:
  4314. int AddScreenJoystick(XMLFile = null, XMLFile = null);
  4315. int GetKeyFromName(const String&) const;
  4316. int GetKeyFromScancode(int) const;
  4317. String GetKeyName(int) const;
  4318. int GetScancodeFromKey(int) const;
  4319. int GetScancodeFromName(const String&) const;
  4320. String GetScancodeName(int) const;
  4321. uint LoadGestures(File);
  4322. uint LoadGestures(VectorBuffer&);
  4323. bool RecordGesture();
  4324. void RemoveAllGestures();
  4325. bool RemoveGesture(uint);
  4326. bool RemoveScreenJoystick(int);
  4327. void ResetMouseVisible();
  4328. bool SaveGesture(File, uint);
  4329. bool SaveGesture(VectorBuffer&, uint);
  4330. bool SaveGestures(File);
  4331. bool SaveGestures(VectorBuffer&);
  4332. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4333. void SetMouseVisible(bool, bool = false);
  4334. // Properties:
  4335. /* readonly */
  4336. StringHash baseType;
  4337. /* readonly */
  4338. String category;
  4339. /* readonly */
  4340. bool focus;
  4341. /* readonly */
  4342. Array<JoystickState> joysticks;
  4343. /* readonly */
  4344. Array<JoystickState> joysticksByIndex;
  4345. /* readonly */
  4346. Array<bool> keyDown;
  4347. /* readonly */
  4348. Array<bool> keyPress;
  4349. /* readonly */
  4350. bool minimized;
  4351. /* readonly */
  4352. Array<bool> mouseButtonDown;
  4353. /* readonly */
  4354. Array<bool> mouseButtonPress;
  4355. bool mouseGrabbed;
  4356. MouseMode mouseMode;
  4357. /* readonly */
  4358. IntVector2 mouseMove;
  4359. /* readonly */
  4360. int mouseMoveWheel;
  4361. /* readonly */
  4362. int mouseMoveX;
  4363. /* readonly */
  4364. int mouseMoveY;
  4365. /* readonly */
  4366. IntVector2 mousePosition;
  4367. bool mouseVisible;
  4368. /* readonly */
  4369. uint numJoysticks;
  4370. /* readonly */
  4371. uint numTouches;
  4372. /* readonly */
  4373. Array<bool> qualifierDown;
  4374. /* readonly */
  4375. Array<bool> qualifierPress;
  4376. /* readonly */
  4377. int qualifiers;
  4378. /* readonly */
  4379. int refs;
  4380. /* readonly */
  4381. Array<bool> scancodeDown;
  4382. /* readonly */
  4383. Array<bool> scancodePress;
  4384. Array<bool> screenJoystickVisible;
  4385. /* readonly */
  4386. bool screenKeyboardSupport;
  4387. bool screenKeyboardVisible;
  4388. bool toggleFullscreen;
  4389. bool touchEmulation;
  4390. /* readonly */
  4391. Array<TouchState> touches;
  4392. /* readonly */
  4393. StringHash type;
  4394. /* readonly */
  4395. String typeName;
  4396. /* readonly */
  4397. int weakRefs;
  4398. };
  4399. class IntRect
  4400. {
  4401. // Methods:
  4402. Intersection IsInside(const IntVector2&) const;
  4403. // Properties:
  4404. int bottom;
  4405. /* readonly */
  4406. Array<int> data;
  4407. /* readonly */
  4408. int height;
  4409. int left;
  4410. int right;
  4411. /* readonly */
  4412. IntVector2 size;
  4413. int top;
  4414. /* readonly */
  4415. int width;
  4416. };
  4417. class IntVector2
  4418. {
  4419. // Methods:
  4420. String ToString() const;
  4421. // Properties:
  4422. /* readonly */
  4423. Array<int> data;
  4424. int x;
  4425. int y;
  4426. };
  4427. class JSONFile
  4428. {
  4429. // Methods:
  4430. JSONValue CreateRoot(JSONValueType = JSON_ANY);
  4431. JSONValue GetRoot(JSONValueType = JSON_ANY);
  4432. bool Load(File);
  4433. bool Load(VectorBuffer&);
  4434. bool Save(File) const;
  4435. bool Save(VectorBuffer&) const;
  4436. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4437. // Properties:
  4438. /* readonly */
  4439. StringHash baseType;
  4440. /* readonly */
  4441. String category;
  4442. /* readonly */
  4443. uint memoryUse;
  4444. String name;
  4445. /* readonly */
  4446. int refs;
  4447. /* readonly */
  4448. StringHash type;
  4449. /* readonly */
  4450. String typeName;
  4451. /* readonly */
  4452. uint useTimer;
  4453. /* readonly */
  4454. int weakRefs;
  4455. };
  4456. class JSONValue
  4457. {
  4458. // Methods:
  4459. void AddBool(bool);
  4460. void AddColor(const Color&);
  4461. void AddFloat(float);
  4462. void AddInt(int);
  4463. void AddIntRect(const IntRect&);
  4464. void AddIntVector2(const IntVector2&);
  4465. void AddMatrix3(const Matrix3&);
  4466. void AddMatrix3x4(const Matrix3x4&);
  4467. void AddMatrix4(const Matrix4&);
  4468. void AddQuaternion(const Quaternion&);
  4469. void AddResourceRef(const ResourceRef&);
  4470. void AddResourceRefList(const ResourceRefList&);
  4471. void AddString(const String);
  4472. void AddVariant(const Variant&);
  4473. void AddVariantValue(const Variant&);
  4474. void AddVector2(const Vector2&);
  4475. void AddVector3(const Vector3&);
  4476. void AddVector4(const Vector4&);
  4477. void AddVectorVariant(const Variant&);
  4478. JSONValue CreateChild(JSONValueType = JSON_OBJECT);
  4479. JSONValue CreateChild(const String&, JSONValueType = JSON_OBJECT);
  4480. bool GetBool(const String&) const;
  4481. bool GetBool(uint) const;
  4482. JSONValue GetChild(const String&, JSONValueType = JSON_ANY) const;
  4483. JSONValue GetChild(uint, JSONValueType = JSON_ANY) const;
  4484. Array<String> GetChildNames() const;
  4485. Color GetColor(const String&) const;
  4486. Color GetColor(uint) const;
  4487. float GetFloat(const String&) const;
  4488. float GetFloat(uint) const;
  4489. int GetInt(const String&) const;
  4490. int GetInt(uint) const;
  4491. IntRect GetIntRect(const String&) const;
  4492. IntRect GetIntRect(uint) const;
  4493. IntVector2 GetIntVector2(const String&) const;
  4494. IntVector2 GetIntVector2(uint) const;
  4495. Matrix3 GetMatrix3(const String&) const;
  4496. Matrix3 GetMatrix3(uint) const;
  4497. Matrix3x4 GetMatrix3x4(const String&) const;
  4498. Matrix3x4 GetMatrix3x4(uint) const;
  4499. Matrix4 GetMatrix4(const String&) const;
  4500. Matrix4 GetMatrix4(uint) const;
  4501. Quaternion GetQuaternion(const String&) const;
  4502. Quaternion GetQuaternion(uint) const;
  4503. ResourceRef GetResourceRef(const String&) const;
  4504. ResourceRef GetResourceRef(uint) const;
  4505. ResourceRefList GetResourceRefList(const String&) const;
  4506. ResourceRefList GetResourceRefList(uint) const;
  4507. String GetString(const String&) const;
  4508. String GetString(uint) const;
  4509. Array<String> GetValueNames() const;
  4510. Variant GetVariant(const String&) const;
  4511. Variant GetVariant(uint) const;
  4512. Variant GetVariantValue(const String&, VariantType) const;
  4513. Variant GetVariantValue(uint, VariantType) const;
  4514. Vector2 GetVector2(const String&) const;
  4515. Vector2 GetVector2(uint) const;
  4516. Vector3 GetVector3(const String&) const;
  4517. Vector3 GetVector3(uint) const;
  4518. Vector4 GetVector4(const String&) const;
  4519. Vector4 GetVector4(uint) const;
  4520. Variant GetVectorVariant(const String&) const;
  4521. Variant GetVectorVariant(uint) const;
  4522. void SetBool(const String&, bool);
  4523. void SetColor(const String&, const Color&);
  4524. void SetFloat(const String&, float);
  4525. void SetInt(const String&, int);
  4526. void SetIntRect(const String&, const IntRect&);
  4527. void SetIntVector2(const String&, const IntVector2&);
  4528. void SetMatrix3(const String&, const Matrix3&);
  4529. void SetMatrix3x4(const String&, const Matrix3x4&);
  4530. void SetMatrix4(const String&, const Matrix4&);
  4531. void SetQuaternion(const String&, const Quaternion&);
  4532. void SetResourceRef(const String&, const ResourceRef&);
  4533. void SetResourceRefList(const String&, const ResourceRefList&);
  4534. void SetString(const String&, const String);
  4535. void SetVariant(const String&, const Variant&);
  4536. void SetVariantValue(const String&, const Variant&);
  4537. void SetVector2(const String&, const Vector2&);
  4538. void SetVector3(const String&, const Vector3&);
  4539. void SetVector4(const String&, const Vector4&);
  4540. void SetVectorVariant(const String&, const Variant&);
  4541. // Properties:
  4542. /* readonly */
  4543. bool isArray;
  4544. /* readonly */
  4545. bool isNull;
  4546. /* readonly */
  4547. bool isObject;
  4548. /* readonly */
  4549. bool notNull;
  4550. /* readonly */
  4551. uint size;
  4552. };
  4553. class JoystickState
  4554. {
  4555. // Properties:
  4556. /* readonly */
  4557. Array<float> axisPosition;
  4558. /* readonly */
  4559. Array<bool> buttonDown;
  4560. /* readonly */
  4561. Array<bool> buttonPress;
  4562. /* readonly */
  4563. bool controller;
  4564. /* readonly */
  4565. Array<int> hatPosition;
  4566. int joystickID;
  4567. String name;
  4568. /* readonly */
  4569. uint numAxes;
  4570. /* readonly */
  4571. uint numButtons;
  4572. /* readonly */
  4573. uint numHats;
  4574. };
  4575. class Light
  4576. {
  4577. // Methods:
  4578. void ApplyAttributes();
  4579. void DrawDebugGeometry(DebugRenderer, bool);
  4580. Variant GetAttribute(const String&) const;
  4581. ValueAnimation GetAttributeAnimation(const String&) const;
  4582. float GetAttributeAnimationSpeed(const String&) const;
  4583. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  4584. Variant GetAttributeDefault(const String&) const;
  4585. bool IsInView(Camera) const;
  4586. bool Load(File, bool = false);
  4587. bool Load(VectorBuffer&, bool = false);
  4588. bool LoadXML(const XMLElement&, bool = false);
  4589. void MarkNetworkUpdate() const;
  4590. void Remove();
  4591. void RemoveInstanceDefault();
  4592. void ResetToDefault();
  4593. bool Save(File) const;
  4594. bool Save(VectorBuffer&) const;
  4595. bool SaveXML(XMLElement&) const;
  4596. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4597. bool SetAttribute(const String&, const Variant&);
  4598. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  4599. void SetAttributeAnimationSpeed(const String&, float);
  4600. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  4601. // Properties:
  4602. bool animationEnabled;
  4603. float aspectRatio;
  4604. /* readonly */
  4605. Array<Variant> attributeDefaults;
  4606. /* readonly */
  4607. Array<AttributeInfo> attributeInfos;
  4608. Array<Variant> attributes;
  4609. /* readonly */
  4610. StringHash baseType;
  4611. /* readonly */
  4612. BoundingBox boundingBox;
  4613. float brightness;
  4614. bool castShadows;
  4615. /* readonly */
  4616. String category;
  4617. Color color;
  4618. float drawDistance;
  4619. /* readonly */
  4620. Color effectiveColor;
  4621. /* readonly */
  4622. float effectiveSpecularIntensity;
  4623. bool enabled;
  4624. /* readonly */
  4625. bool enabledEffective;
  4626. float fadeDistance;
  4627. float fov;
  4628. /* readonly */
  4629. Frustum frustum;
  4630. /* readonly */
  4631. uint id;
  4632. /* readonly */
  4633. bool inView;
  4634. uint lightMask;
  4635. LightType lightType;
  4636. float lodBias;
  4637. uint maxLights;
  4638. /* readonly */
  4639. bool negative;
  4640. /* readonly */
  4641. Node node;
  4642. /* readonly */
  4643. uint numAttributes;
  4644. /* readonly */
  4645. int numShadowSplits;
  4646. ObjectAnimation objectAnimation;
  4647. bool occludee;
  4648. bool occluder;
  4649. bool perVertex;
  4650. Texture rampTexture;
  4651. float range;
  4652. /* readonly */
  4653. int refs;
  4654. BiasParameters shadowBias;
  4655. CascadeParameters shadowCascade;
  4656. float shadowDistance;
  4657. float shadowFadeDistance;
  4658. FocusParameters shadowFocus;
  4659. float shadowIntensity;
  4660. uint shadowMask;
  4661. float shadowNearFarRatio;
  4662. float shadowResolution;
  4663. Texture shapeTexture;
  4664. float specularIntensity;
  4665. bool temporary;
  4666. /* readonly */
  4667. StringHash type;
  4668. /* readonly */
  4669. String typeName;
  4670. uint viewMask;
  4671. /* readonly */
  4672. int weakRefs;
  4673. /* readonly */
  4674. BoundingBox worldBoundingBox;
  4675. uint zoneMask;
  4676. };
  4677. class LineEdit
  4678. {
  4679. // Methods:
  4680. void AddChild(UIElement);
  4681. void ApplyAttributes();
  4682. void BringToFront();
  4683. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  4684. void DisableLayoutUpdate();
  4685. IntVector2 ElementToScreen(const IntVector2&);
  4686. void EnableLayoutUpdate();
  4687. uint FindChild(UIElement) const;
  4688. Variant GetAttribute(const String&) const;
  4689. ValueAnimation GetAttributeAnimation(const String&) const;
  4690. float GetAttributeAnimationSpeed(const String&) const;
  4691. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  4692. Variant GetAttributeDefault(const String&) const;
  4693. UIElement GetChild(const String&, bool = false) const;
  4694. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  4695. Array<UIElement> GetChildren(bool = false) const;
  4696. UIElement GetElementEventSender() const;
  4697. uint GetNumChildren(bool) const;
  4698. void InsertChild(uint, UIElement);
  4699. bool IsInside(IntVector2, bool);
  4700. bool IsInsideCombined(IntVector2, bool);
  4701. bool Load(File, bool = false);
  4702. bool Load(VectorBuffer&, bool = false);
  4703. bool LoadChildXML(XMLFile, XMLFile = null);
  4704. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  4705. bool LoadXML(File);
  4706. bool LoadXML(VectorBuffer&);
  4707. bool LoadXML(XMLFile, XMLFile);
  4708. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  4709. bool LoadXML(const XMLElement&, bool = false);
  4710. void MarkNetworkUpdate() const;
  4711. void Remove();
  4712. void RemoveAllChildren();
  4713. void RemoveChild(UIElement, uint = 0);
  4714. void RemoveChild(uint);
  4715. void RemoveInstanceDefault();
  4716. void ResetDeepEnabled();
  4717. void ResetToDefault();
  4718. bool Save(File) const;
  4719. bool Save(VectorBuffer&) const;
  4720. bool SaveXML(File);
  4721. bool SaveXML(VectorBuffer&);
  4722. bool SaveXML(XMLElement&) const;
  4723. IntVector2 ScreenToElement(const IntVector2&);
  4724. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4725. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  4726. bool SetAttribute(const String&, const Variant&);
  4727. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  4728. void SetAttributeAnimationSpeed(const String&, float);
  4729. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  4730. void SetDeepEnabled(bool);
  4731. void SetEnabledRecursive(bool);
  4732. void SetFixedHeight(int);
  4733. void SetFixedSize(int, int);
  4734. void SetFixedWidth(int);
  4735. void SetFullImageRect();
  4736. void SetHoverOffset(int, int);
  4737. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  4738. void SetMaxSize(int, int);
  4739. void SetMinSize(int, int);
  4740. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  4741. void SetPosition(int, int);
  4742. void SetSize(int, int);
  4743. bool SetStyle(const String&, XMLFile = null);
  4744. bool SetStyle(const XMLElement&);
  4745. bool SetStyleAuto(XMLFile = null);
  4746. void UpdateLayout();
  4747. const Variant& GetVar(const StringHash&);
  4748. // Properties:
  4749. bool animationEnabled;
  4750. /* readonly */
  4751. Array<Variant> attributeDefaults;
  4752. /* readonly */
  4753. Array<AttributeInfo> attributeInfos;
  4754. Array<Variant> attributes;
  4755. /* readonly */
  4756. StringHash baseType;
  4757. BlendMode blendMode;
  4758. IntRect border;
  4759. bool bringToBack;
  4760. bool bringToFront;
  4761. /* readonly */
  4762. String category;
  4763. /* readonly */
  4764. IntVector2 childOffset;
  4765. /* readonly */
  4766. Array<UIElement> children;
  4767. IntRect clipBorder;
  4768. bool clipChildren;
  4769. /* writeonly */
  4770. Color color;
  4771. /* readonly */
  4772. bool colorGradient;
  4773. Array<Color> colors;
  4774. /* readonly */
  4775. IntRect combinedScreenRect;
  4776. /* readonly */
  4777. BorderImage cursor;
  4778. float cursorBlinkRate;
  4779. bool cursorMovable;
  4780. uint cursorPosition;
  4781. XMLFile defaultStyle;
  4782. /* readonly */
  4783. float derivedOpacity;
  4784. /* readonly */
  4785. uint dragButtonCombo;
  4786. /* readonly */
  4787. int dragButtonCount;
  4788. uint dragDropMode;
  4789. uint echoCharacter;
  4790. bool editable;
  4791. bool elementEventSender;
  4792. bool enabled;
  4793. /* readonly */
  4794. bool enabledSelf;
  4795. /* readonly */
  4796. bool fixedHeight;
  4797. /* readonly */
  4798. bool fixedSize;
  4799. /* readonly */
  4800. bool fixedWidth;
  4801. bool focus;
  4802. FocusMode focusMode;
  4803. int height;
  4804. HorizontalAlignment horizontalAlignment;
  4805. IntVector2 hoverOffset;
  4806. /* readonly */
  4807. bool hovering;
  4808. IntRect imageBorder;
  4809. IntRect imageRect;
  4810. int indent;
  4811. int indentSpacing;
  4812. /* readonly */
  4813. int indentWidth;
  4814. bool internal;
  4815. IntRect layoutBorder;
  4816. Vector2 layoutFlexScale;
  4817. LayoutMode layoutMode;
  4818. int layoutSpacing;
  4819. int maxHeight;
  4820. uint maxLength;
  4821. IntVector2 maxSize;
  4822. int maxWidth;
  4823. int minHeight;
  4824. IntVector2 minSize;
  4825. int minWidth;
  4826. String name;
  4827. /* readonly */
  4828. uint numAllChildren;
  4829. /* readonly */
  4830. uint numAttributes;
  4831. /* readonly */
  4832. uint numChildren;
  4833. ObjectAnimation objectAnimation;
  4834. float opacity;
  4835. UIElement parent;
  4836. IntVector2 position;
  4837. int priority;
  4838. /* readonly */
  4839. int refs;
  4840. /* readonly */
  4841. UIElement root;
  4842. /* readonly */
  4843. IntVector2 screenPosition;
  4844. bool selected;
  4845. IntVector2 size;
  4846. bool sortChildren;
  4847. String style;
  4848. bool temporary;
  4849. String text;
  4850. bool textCopyable;
  4851. /* readonly */
  4852. Text textElement;
  4853. bool textSelectable;
  4854. Texture texture;
  4855. bool tiled;
  4856. TraversalMode traversalMode;
  4857. /* readonly */
  4858. StringHash type;
  4859. /* readonly */
  4860. String typeName;
  4861. bool useDerivedOpacity;
  4862. /* readonly */
  4863. VariantMap vars;
  4864. VerticalAlignment verticalAlignment;
  4865. bool visible;
  4866. /* readonly */
  4867. int weakRefs;
  4868. int width;
  4869. };
  4870. class ListView
  4871. {
  4872. // Methods:
  4873. void AddChild(UIElement);
  4874. void AddItem(UIElement);
  4875. void AddSelection(uint);
  4876. void ApplyAttributes();
  4877. void BringToFront();
  4878. void ChangeSelection(int, bool);
  4879. void ClearSelection();
  4880. void CopySelectedItemsToClipboard();
  4881. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  4882. void DisableLayoutUpdate();
  4883. IntVector2 ElementToScreen(const IntVector2&);
  4884. void EnableLayoutUpdate();
  4885. void Expand(uint, bool, bool = false);
  4886. uint FindChild(UIElement) const;
  4887. uint FindItem(UIElement);
  4888. Variant GetAttribute(const String&) const;
  4889. ValueAnimation GetAttributeAnimation(const String&) const;
  4890. float GetAttributeAnimationSpeed(const String&) const;
  4891. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  4892. Variant GetAttributeDefault(const String&) const;
  4893. UIElement GetChild(const String&, bool = false) const;
  4894. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  4895. Array<UIElement> GetChildren(bool = false) const;
  4896. UIElement GetElementEventSender() const;
  4897. Array<UIElement> GetItems() const;
  4898. uint GetNumChildren(bool) const;
  4899. void InsertChild(uint, UIElement);
  4900. void InsertItem(uint, UIElement, UIElement = null);
  4901. bool IsExpanded(uint) const;
  4902. bool IsInside(IntVector2, bool);
  4903. bool IsInsideCombined(IntVector2, bool);
  4904. bool IsSelected(uint) const;
  4905. bool Load(File, bool = false);
  4906. bool Load(VectorBuffer&, bool = false);
  4907. bool LoadChildXML(XMLFile, XMLFile = null);
  4908. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  4909. bool LoadXML(File);
  4910. bool LoadXML(VectorBuffer&);
  4911. bool LoadXML(XMLFile, XMLFile);
  4912. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  4913. bool LoadXML(const XMLElement&, bool = false);
  4914. void MarkNetworkUpdate() const;
  4915. void Remove();
  4916. void RemoveAllChildren();
  4917. void RemoveAllItems();
  4918. void RemoveChild(UIElement, uint = 0);
  4919. void RemoveChild(uint);
  4920. void RemoveInstanceDefault();
  4921. void RemoveItem(UIElement, uint = 0);
  4922. void RemoveItem(uint);
  4923. void RemoveSelection(uint);
  4924. void ResetDeepEnabled();
  4925. void ResetToDefault();
  4926. bool Save(File) const;
  4927. bool Save(VectorBuffer&) const;
  4928. bool SaveXML(File);
  4929. bool SaveXML(VectorBuffer&);
  4930. bool SaveXML(XMLElement&) const;
  4931. IntVector2 ScreenToElement(const IntVector2&);
  4932. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  4933. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  4934. bool SetAttribute(const String&, const Variant&);
  4935. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  4936. void SetAttributeAnimationSpeed(const String&, float);
  4937. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  4938. void SetDeepEnabled(bool);
  4939. void SetEnabledRecursive(bool);
  4940. void SetFixedHeight(int);
  4941. void SetFixedSize(int, int);
  4942. void SetFixedWidth(int);
  4943. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  4944. void SetMaxSize(int, int);
  4945. void SetMinSize(int, int);
  4946. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  4947. void SetPosition(int, int);
  4948. void SetScrollBarsVisible(bool, bool);
  4949. void SetSelections(Array<uint>);
  4950. void SetSize(int, int);
  4951. bool SetStyle(const String&, XMLFile = null);
  4952. bool SetStyle(const XMLElement&);
  4953. bool SetStyleAuto(XMLFile = null);
  4954. void SetViewPosition(int, int);
  4955. void ToggleExpand(uint, bool = false);
  4956. void ToggleSelection(uint);
  4957. void UpdateLayout();
  4958. const Variant& GetVar(const StringHash&);
  4959. // Properties:
  4960. bool animationEnabled;
  4961. /* readonly */
  4962. Array<Variant> attributeDefaults;
  4963. /* readonly */
  4964. Array<AttributeInfo> attributeInfos;
  4965. Array<Variant> attributes;
  4966. bool autoDisableChildren;
  4967. float autoDisableThreshold;
  4968. int baseIndent;
  4969. /* readonly */
  4970. StringHash baseType;
  4971. bool bringToBack;
  4972. bool bringToFront;
  4973. /* readonly */
  4974. String category;
  4975. /* readonly */
  4976. IntVector2 childOffset;
  4977. /* readonly */
  4978. Array<UIElement> children;
  4979. bool clearSelectionOnDefocus;
  4980. IntRect clipBorder;
  4981. bool clipChildren;
  4982. /* writeonly */
  4983. Color color;
  4984. /* readonly */
  4985. bool colorGradient;
  4986. Array<Color> colors;
  4987. /* readonly */
  4988. IntRect combinedScreenRect;
  4989. /* readonly */
  4990. UIElement contentElement;
  4991. XMLFile defaultStyle;
  4992. /* readonly */
  4993. float derivedOpacity;
  4994. /* readonly */
  4995. uint dragButtonCombo;
  4996. /* readonly */
  4997. int dragButtonCount;
  4998. uint dragDropMode;
  4999. bool editable;
  5000. bool elementEventSender;
  5001. bool enabled;
  5002. /* readonly */
  5003. bool enabledSelf;
  5004. /* readonly */
  5005. bool fixedHeight;
  5006. /* readonly */
  5007. bool fixedSize;
  5008. /* readonly */
  5009. bool fixedWidth;
  5010. bool focus;
  5011. FocusMode focusMode;
  5012. int height;
  5013. bool hierarchyMode;
  5014. HighlightMode highlightMode;
  5015. HorizontalAlignment horizontalAlignment;
  5016. /* readonly */
  5017. ScrollBar horizontalScrollBar;
  5018. /* readonly */
  5019. bool hovering;
  5020. int indent;
  5021. int indentSpacing;
  5022. /* readonly */
  5023. int indentWidth;
  5024. bool internal;
  5025. /* readonly */
  5026. Array<UIElement> items;
  5027. IntRect layoutBorder;
  5028. Vector2 layoutFlexScale;
  5029. LayoutMode layoutMode;
  5030. int layoutSpacing;
  5031. int maxHeight;
  5032. IntVector2 maxSize;
  5033. int maxWidth;
  5034. int minHeight;
  5035. IntVector2 minSize;
  5036. int minWidth;
  5037. bool multiselect;
  5038. String name;
  5039. /* readonly */
  5040. uint numAllChildren;
  5041. /* readonly */
  5042. uint numAttributes;
  5043. /* readonly */
  5044. uint numChildren;
  5045. /* readonly */
  5046. uint numItems;
  5047. ObjectAnimation objectAnimation;
  5048. float opacity;
  5049. float pageStep;
  5050. UIElement parent;
  5051. IntVector2 position;
  5052. int priority;
  5053. /* readonly */
  5054. int refs;
  5055. /* readonly */
  5056. UIElement root;
  5057. /* readonly */
  5058. IntVector2 screenPosition;
  5059. bool scrollBarsAutoVisible;
  5060. float scrollDeceleration;
  5061. /* readonly */
  5062. BorderImage scrollPanel;
  5063. float scrollSnapEpsilon;
  5064. float scrollStep;
  5065. bool selectOnClickEnd;
  5066. bool selected;
  5067. /* readonly */
  5068. UIElement selectedItem;
  5069. /* readonly */
  5070. Array<UIElement> selectedItems;
  5071. uint selection;
  5072. /* readonly */
  5073. Array<uint> selections;
  5074. IntVector2 size;
  5075. bool sortChildren;
  5076. String style;
  5077. bool temporary;
  5078. TraversalMode traversalMode;
  5079. /* readonly */
  5080. StringHash type;
  5081. /* readonly */
  5082. String typeName;
  5083. bool useDerivedOpacity;
  5084. /* readonly */
  5085. VariantMap vars;
  5086. VerticalAlignment verticalAlignment;
  5087. /* readonly */
  5088. ScrollBar verticalScrollBar;
  5089. IntVector2 viewPosition;
  5090. bool visible;
  5091. /* readonly */
  5092. int weakRefs;
  5093. int width;
  5094. };
  5095. class Log
  5096. {
  5097. // Methods:
  5098. void Close();
  5099. void Debug(const String&);
  5100. void Error(const String&);
  5101. void Info(const String&);
  5102. void Open(const String&);
  5103. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5104. void Warning(const String&);
  5105. void Write(const String&, bool = false);
  5106. // Properties:
  5107. /* readonly */
  5108. StringHash baseType;
  5109. /* readonly */
  5110. String category;
  5111. /* readonly */
  5112. String lastMessage;
  5113. int level;
  5114. bool quiet;
  5115. /* readonly */
  5116. int refs;
  5117. bool timeStamp;
  5118. /* readonly */
  5119. StringHash type;
  5120. /* readonly */
  5121. String typeName;
  5122. /* readonly */
  5123. int weakRefs;
  5124. };
  5125. class Material
  5126. {
  5127. // Methods:
  5128. Material Clone(const String& = String ( )) const;
  5129. ValueAnimation GetShaderParameterAnimation(const String&) const;
  5130. float GetShaderParameterAnimationSpeed(const String&) const;
  5131. WrapMode GetShaderParameterAnimationWrapMode(const String&) const;
  5132. bool Load(File);
  5133. bool Load(VectorBuffer&);
  5134. bool Load(const XMLElement&);
  5135. void RemoveShaderParameter(const String&);
  5136. bool Save(File) const;
  5137. bool Save(VectorBuffer&) const;
  5138. bool Save(XMLElement&) const;
  5139. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5140. void SetShaderParameterAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5141. void SetShaderParameterAnimationSpeed(const String&, float);
  5142. void SetShaderParameterAnimationWrapMode(const String&, WrapMode);
  5143. void SetTechnique(uint, Technique, uint = 0, float = 0.0);
  5144. void SetUVTransform(const Vector2&, float, const Vector2&);
  5145. void SetUVTransform(const Vector2&, float, float);
  5146. void SortTechniques();
  5147. // Properties:
  5148. /* readonly */
  5149. StringHash baseType;
  5150. /* readonly */
  5151. String category;
  5152. CullMode cullMode;
  5153. BiasParameters depthBias;
  5154. /* readonly */
  5155. uint memoryUse;
  5156. String name;
  5157. uint numTechniques;
  5158. /* readonly */
  5159. uint numUsedTextureUnits;
  5160. /* readonly */
  5161. bool occlusion;
  5162. /* readonly */
  5163. int refs;
  5164. Scene scene;
  5165. /* readonly */
  5166. Array<String> shaderParameterNames;
  5167. Array<Variant> shaderParameters;
  5168. CullMode shadowCullMode;
  5169. /* readonly */
  5170. Array<TechniqueEntry> techniqueEntries;
  5171. /* readonly */
  5172. Array<Technique> techniques;
  5173. Array<Texture> textures;
  5174. /* readonly */
  5175. StringHash type;
  5176. /* readonly */
  5177. String typeName;
  5178. /* readonly */
  5179. uint useTimer;
  5180. /* readonly */
  5181. int weakRefs;
  5182. };
  5183. class Matrix3
  5184. {
  5185. // Methods:
  5186. bool Equals(const Matrix3&) const;
  5187. Matrix3 Inverse() const;
  5188. Vector3 Scale() const;
  5189. Matrix3 Scaled(const Vector3&) const;
  5190. void SetScale(const Vector3&);
  5191. void SetScale(float);
  5192. String ToString() const;
  5193. Matrix3 Transpose() const;
  5194. // Properties:
  5195. float m00;
  5196. float m01;
  5197. float m02;
  5198. float m10;
  5199. float m11;
  5200. float m12;
  5201. float m20;
  5202. float m21;
  5203. float m22;
  5204. };
  5205. class Matrix3x4
  5206. {
  5207. // Methods:
  5208. void Decompose(Vector3&, Quaternion&, Vector3&) const;
  5209. bool Equals(const Matrix3x4&) const;
  5210. Matrix3x4 Inverse() const;
  5211. Quaternion Rotation() const;
  5212. Matrix3 RotationMatrix() const;
  5213. Vector3 Scale() const;
  5214. void SetRotation(const Matrix3&);
  5215. void SetScale(const Vector3&);
  5216. void SetScale(float);
  5217. void SetTranslation(const Vector3&);
  5218. Matrix3 ToMatrix3() const;
  5219. Matrix4 ToMatrix4() const;
  5220. String ToString() const;
  5221. Vector3 Translation() const;
  5222. // Properties:
  5223. float m00;
  5224. float m01;
  5225. float m02;
  5226. float m03;
  5227. float m10;
  5228. float m11;
  5229. float m12;
  5230. float m13;
  5231. float m20;
  5232. float m21;
  5233. float m22;
  5234. float m23;
  5235. };
  5236. class Matrix4
  5237. {
  5238. // Methods:
  5239. void Decompose(Vector3&, Quaternion&, Vector3&) const;
  5240. bool Equals(const Matrix4&) const;
  5241. Matrix4 Inverse() const;
  5242. Quaternion Rotation() const;
  5243. Matrix3 RotationMatrix() const;
  5244. Vector3 Scale() const;
  5245. void SetRotation(const Matrix3&);
  5246. void SetScale(const Vector3&);
  5247. void SetScale(float);
  5248. void SetTranslation(const Vector3&);
  5249. Matrix3 ToMatrix3() const;
  5250. String ToString() const;
  5251. Vector3 Translation() const;
  5252. Matrix4 Transpose() const;
  5253. // Properties:
  5254. float m00;
  5255. float m01;
  5256. float m02;
  5257. float m03;
  5258. float m10;
  5259. float m11;
  5260. float m12;
  5261. float m13;
  5262. float m20;
  5263. float m21;
  5264. float m22;
  5265. float m23;
  5266. float m30;
  5267. float m31;
  5268. float m32;
  5269. float m33;
  5270. };
  5271. class Menu
  5272. {
  5273. // Methods:
  5274. void AddChild(UIElement);
  5275. void ApplyAttributes();
  5276. void BringToFront();
  5277. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  5278. void DisableLayoutUpdate();
  5279. IntVector2 ElementToScreen(const IntVector2&);
  5280. void EnableLayoutUpdate();
  5281. uint FindChild(UIElement) const;
  5282. Variant GetAttribute(const String&) const;
  5283. ValueAnimation GetAttributeAnimation(const String&) const;
  5284. float GetAttributeAnimationSpeed(const String&) const;
  5285. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5286. Variant GetAttributeDefault(const String&) const;
  5287. UIElement GetChild(const String&, bool = false) const;
  5288. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  5289. Array<UIElement> GetChildren(bool = false) const;
  5290. UIElement GetElementEventSender() const;
  5291. uint GetNumChildren(bool) const;
  5292. void InsertChild(uint, UIElement);
  5293. bool IsInside(IntVector2, bool);
  5294. bool IsInsideCombined(IntVector2, bool);
  5295. bool Load(File, bool = false);
  5296. bool Load(VectorBuffer&, bool = false);
  5297. bool LoadChildXML(XMLFile, XMLFile = null);
  5298. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  5299. bool LoadXML(File);
  5300. bool LoadXML(VectorBuffer&);
  5301. bool LoadXML(XMLFile, XMLFile);
  5302. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  5303. bool LoadXML(const XMLElement&, bool = false);
  5304. void MarkNetworkUpdate() const;
  5305. void Remove();
  5306. void RemoveAllChildren();
  5307. void RemoveChild(UIElement, uint = 0);
  5308. void RemoveChild(uint);
  5309. void RemoveInstanceDefault();
  5310. void ResetDeepEnabled();
  5311. void ResetToDefault();
  5312. bool Save(File) const;
  5313. bool Save(VectorBuffer&) const;
  5314. bool SaveXML(File);
  5315. bool SaveXML(VectorBuffer&);
  5316. bool SaveXML(XMLElement&) const;
  5317. IntVector2 ScreenToElement(const IntVector2&);
  5318. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5319. void SetAccelerator(int, int);
  5320. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  5321. bool SetAttribute(const String&, const Variant&);
  5322. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5323. void SetAttributeAnimationSpeed(const String&, float);
  5324. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  5325. void SetDeepEnabled(bool);
  5326. void SetEnabledRecursive(bool);
  5327. void SetFixedHeight(int);
  5328. void SetFixedSize(int, int);
  5329. void SetFixedWidth(int);
  5330. void SetFullImageRect();
  5331. void SetHoverOffset(int, int);
  5332. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  5333. void SetMaxSize(int, int);
  5334. void SetMinSize(int, int);
  5335. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  5336. void SetPopupOffset(int, int);
  5337. void SetPosition(int, int);
  5338. void SetPressedChildOffset(int, int);
  5339. void SetPressedOffset(int, int);
  5340. void SetRepeat(float, float);
  5341. void SetSize(int, int);
  5342. bool SetStyle(const String&, XMLFile = null);
  5343. bool SetStyle(const XMLElement&);
  5344. bool SetStyleAuto(XMLFile = null);
  5345. void UpdateLayout();
  5346. const Variant& GetVar(const StringHash&);
  5347. // Properties:
  5348. /* readonly */
  5349. int acceleratorKey;
  5350. /* readonly */
  5351. int acceleratorQualifiers;
  5352. bool animationEnabled;
  5353. /* readonly */
  5354. Array<Variant> attributeDefaults;
  5355. /* readonly */
  5356. Array<AttributeInfo> attributeInfos;
  5357. Array<Variant> attributes;
  5358. /* readonly */
  5359. StringHash baseType;
  5360. BlendMode blendMode;
  5361. IntRect border;
  5362. bool bringToBack;
  5363. bool bringToFront;
  5364. /* readonly */
  5365. String category;
  5366. /* readonly */
  5367. IntVector2 childOffset;
  5368. /* readonly */
  5369. Array<UIElement> children;
  5370. IntRect clipBorder;
  5371. bool clipChildren;
  5372. /* writeonly */
  5373. Color color;
  5374. /* readonly */
  5375. bool colorGradient;
  5376. Array<Color> colors;
  5377. /* readonly */
  5378. IntRect combinedScreenRect;
  5379. XMLFile defaultStyle;
  5380. /* readonly */
  5381. float derivedOpacity;
  5382. /* readonly */
  5383. uint dragButtonCombo;
  5384. /* readonly */
  5385. int dragButtonCount;
  5386. uint dragDropMode;
  5387. bool editable;
  5388. bool elementEventSender;
  5389. bool enabled;
  5390. /* readonly */
  5391. bool enabledSelf;
  5392. /* readonly */
  5393. bool fixedHeight;
  5394. /* readonly */
  5395. bool fixedSize;
  5396. /* readonly */
  5397. bool fixedWidth;
  5398. bool focus;
  5399. FocusMode focusMode;
  5400. int height;
  5401. HorizontalAlignment horizontalAlignment;
  5402. IntVector2 hoverOffset;
  5403. /* readonly */
  5404. bool hovering;
  5405. IntRect imageBorder;
  5406. IntRect imageRect;
  5407. int indent;
  5408. int indentSpacing;
  5409. /* readonly */
  5410. int indentWidth;
  5411. bool internal;
  5412. IntRect layoutBorder;
  5413. Vector2 layoutFlexScale;
  5414. LayoutMode layoutMode;
  5415. int layoutSpacing;
  5416. int maxHeight;
  5417. IntVector2 maxSize;
  5418. int maxWidth;
  5419. int minHeight;
  5420. IntVector2 minSize;
  5421. int minWidth;
  5422. String name;
  5423. /* readonly */
  5424. uint numAllChildren;
  5425. /* readonly */
  5426. uint numAttributes;
  5427. /* readonly */
  5428. uint numChildren;
  5429. ObjectAnimation objectAnimation;
  5430. float opacity;
  5431. UIElement parent;
  5432. UIElement popup;
  5433. IntVector2 popupOffset;
  5434. IntVector2 position;
  5435. /* readonly */
  5436. bool pressed;
  5437. IntVector2 pressedChildOffset;
  5438. IntVector2 pressedOffset;
  5439. int priority;
  5440. /* readonly */
  5441. int refs;
  5442. float repeatDelay;
  5443. float repeatRate;
  5444. /* readonly */
  5445. UIElement root;
  5446. /* readonly */
  5447. IntVector2 screenPosition;
  5448. bool selected;
  5449. bool showPopup;
  5450. IntVector2 size;
  5451. bool sortChildren;
  5452. String style;
  5453. bool temporary;
  5454. Texture texture;
  5455. bool tiled;
  5456. TraversalMode traversalMode;
  5457. /* readonly */
  5458. StringHash type;
  5459. /* readonly */
  5460. String typeName;
  5461. bool useDerivedOpacity;
  5462. /* readonly */
  5463. VariantMap vars;
  5464. VerticalAlignment verticalAlignment;
  5465. bool visible;
  5466. /* readonly */
  5467. int weakRefs;
  5468. int width;
  5469. };
  5470. class MessageBox
  5471. {
  5472. // Methods:
  5473. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5474. // Properties:
  5475. /* readonly */
  5476. StringHash baseType;
  5477. /* readonly */
  5478. String category;
  5479. String message;
  5480. /* readonly */
  5481. int refs;
  5482. String title;
  5483. /* readonly */
  5484. StringHash type;
  5485. /* readonly */
  5486. String typeName;
  5487. /* readonly */
  5488. int weakRefs;
  5489. /* readonly */
  5490. UIElement window;
  5491. };
  5492. class Model
  5493. {
  5494. // Methods:
  5495. Model Clone(const String& = String ( )) const;
  5496. bool Load(File);
  5497. bool Load(VectorBuffer&);
  5498. bool Save(File) const;
  5499. bool Save(VectorBuffer&) const;
  5500. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5501. // Properties:
  5502. /* readonly */
  5503. StringHash baseType;
  5504. /* readonly */
  5505. BoundingBox boundingBox;
  5506. /* readonly */
  5507. String category;
  5508. /* readonly */
  5509. uint memoryUse;
  5510. String name;
  5511. /* readonly */
  5512. uint numGeometries;
  5513. /* readonly */
  5514. Array<uint> numGeometryLodLevels;
  5515. /* readonly */
  5516. uint numMorphs;
  5517. /* readonly */
  5518. int refs;
  5519. /* readonly */
  5520. Skeleton skeleton;
  5521. /* readonly */
  5522. StringHash type;
  5523. /* readonly */
  5524. String typeName;
  5525. /* readonly */
  5526. uint useTimer;
  5527. /* readonly */
  5528. int weakRefs;
  5529. };
  5530. class Navigable
  5531. {
  5532. // Methods:
  5533. void ApplyAttributes();
  5534. void DrawDebugGeometry(DebugRenderer, bool);
  5535. Variant GetAttribute(const String&) const;
  5536. ValueAnimation GetAttributeAnimation(const String&) const;
  5537. float GetAttributeAnimationSpeed(const String&) const;
  5538. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5539. Variant GetAttributeDefault(const String&) const;
  5540. bool Load(File, bool = false);
  5541. bool Load(VectorBuffer&, bool = false);
  5542. bool LoadXML(const XMLElement&, bool = false);
  5543. void MarkNetworkUpdate() const;
  5544. void Remove();
  5545. void RemoveInstanceDefault();
  5546. void ResetToDefault();
  5547. bool Save(File) const;
  5548. bool Save(VectorBuffer&) const;
  5549. bool SaveXML(XMLElement&) const;
  5550. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5551. bool SetAttribute(const String&, const Variant&);
  5552. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5553. void SetAttributeAnimationSpeed(const String&, float);
  5554. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  5555. // Properties:
  5556. bool animationEnabled;
  5557. /* readonly */
  5558. Array<Variant> attributeDefaults;
  5559. /* readonly */
  5560. Array<AttributeInfo> attributeInfos;
  5561. Array<Variant> attributes;
  5562. /* readonly */
  5563. StringHash baseType;
  5564. /* readonly */
  5565. String category;
  5566. bool enabled;
  5567. /* readonly */
  5568. bool enabledEffective;
  5569. /* readonly */
  5570. uint id;
  5571. /* readonly */
  5572. Node node;
  5573. /* readonly */
  5574. uint numAttributes;
  5575. ObjectAnimation objectAnimation;
  5576. bool recursive;
  5577. /* readonly */
  5578. int refs;
  5579. bool temporary;
  5580. /* readonly */
  5581. StringHash type;
  5582. /* readonly */
  5583. String typeName;
  5584. /* readonly */
  5585. int weakRefs;
  5586. };
  5587. class NavigationMesh
  5588. {
  5589. // Methods:
  5590. void ApplyAttributes();
  5591. bool Build();
  5592. bool Build(const BoundingBox&);
  5593. void DrawDebugGeometry(DebugRenderer, bool);
  5594. void DrawDebugGeometry(bool);
  5595. Vector3 FindNearestPoint(const Vector3&, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ));
  5596. Array<Vector3> FindPath(const Vector3&, const Vector3&, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ));
  5597. Variant GetAttribute(const String&) const;
  5598. ValueAnimation GetAttributeAnimation(const String&) const;
  5599. float GetAttributeAnimationSpeed(const String&) const;
  5600. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5601. Variant GetAttributeDefault(const String&) const;
  5602. float GetDistanceToWall(const Vector3&, float, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ));
  5603. Vector3 GetRandomPoint();
  5604. Vector3 GetRandomPointInCircle(const Vector3&, float, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ));
  5605. bool Load(File, bool = false);
  5606. bool Load(VectorBuffer&, bool = false);
  5607. bool LoadXML(const XMLElement&, bool = false);
  5608. void MarkNetworkUpdate() const;
  5609. Vector3 MoveAlongSurface(const Vector3&, const Vector3&, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ), uint = 3);
  5610. Vector3 Raycast(const Vector3&, const Vector3&, const Vector3& = Vector3 ( 1.0 , 1.0 , 1.0 ));
  5611. void Remove();
  5612. void RemoveInstanceDefault();
  5613. void ResetToDefault();
  5614. bool Save(File) const;
  5615. bool Save(VectorBuffer&) const;
  5616. bool SaveXML(XMLElement&) const;
  5617. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5618. bool SetAttribute(const String&, const Variant&);
  5619. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5620. void SetAttributeAnimationSpeed(const String&, float);
  5621. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  5622. // Properties:
  5623. float agentHeight;
  5624. float agentMaxClimb;
  5625. float agentMaxSlope;
  5626. float agentRadius;
  5627. bool animationEnabled;
  5628. /* readonly */
  5629. Array<Variant> attributeDefaults;
  5630. /* readonly */
  5631. Array<AttributeInfo> attributeInfos;
  5632. Array<Variant> attributes;
  5633. /* readonly */
  5634. StringHash baseType;
  5635. /* readonly */
  5636. BoundingBox boundingBox;
  5637. /* readonly */
  5638. String category;
  5639. float cellHeight;
  5640. float cellSize;
  5641. float detailSampleDistance;
  5642. float detailSampleMaxError;
  5643. float edgeMaxError;
  5644. float edgeMaxLength;
  5645. bool enabled;
  5646. /* readonly */
  5647. bool enabledEffective;
  5648. /* readonly */
  5649. uint id;
  5650. /* readonly */
  5651. bool initialized;
  5652. /* readonly */
  5653. Node node;
  5654. /* readonly */
  5655. uint numAttributes;
  5656. /* readonly */
  5657. IntVector2 numTiles;
  5658. ObjectAnimation objectAnimation;
  5659. Vector3 padding;
  5660. /* readonly */
  5661. int refs;
  5662. float regionMergeSize;
  5663. float regionMinSize;
  5664. bool temporary;
  5665. int tileSize;
  5666. /* readonly */
  5667. StringHash type;
  5668. /* readonly */
  5669. String typeName;
  5670. /* readonly */
  5671. int weakRefs;
  5672. /* readonly */
  5673. BoundingBox worldBoundingBox;
  5674. };
  5675. class Network
  5676. {
  5677. // Methods:
  5678. void BroadcastMessage(int, bool, bool, const VectorBuffer&, uint = 0);
  5679. void BroadcastRemoteEvent(Node, const String&, bool, const VariantMap& = VariantMap ( ));
  5680. void BroadcastRemoteEvent(Scene, const String&, bool, const VariantMap& = VariantMap ( ));
  5681. void BroadcastRemoteEvent(const String&, bool, const VariantMap& = VariantMap ( ));
  5682. bool CheckRemoteEvent(const String&) const;
  5683. bool Connect(const String&, uint16, Scene, const VariantMap& = VariantMap ( ));
  5684. void Disconnect(int = 0);
  5685. HttpRequest MakeHttpRequest(const String&, const String& = String ( ), Array<String> = null, const String& = String ( ));
  5686. void RegisterRemoteEvent(const String&) const;
  5687. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5688. void SendPackageToClients(Scene, PackageFile);
  5689. bool StartServer(uint16);
  5690. void StopServer();
  5691. void UnregisterAllRemoteEvents();
  5692. void UnregisterRemoteEvent(const String&) const;
  5693. // Properties:
  5694. /* readonly */
  5695. StringHash baseType;
  5696. /* readonly */
  5697. String category;
  5698. /* readonly */
  5699. Array<Connection> clientConnections;
  5700. String packageCacheDir;
  5701. /* readonly */
  5702. int refs;
  5703. /* readonly */
  5704. Connection serverConnection;
  5705. /* readonly */
  5706. bool serverRunning;
  5707. /* readonly */
  5708. StringHash type;
  5709. /* readonly */
  5710. String typeName;
  5711. int updateFps;
  5712. /* readonly */
  5713. int weakRefs;
  5714. };
  5715. class NetworkPriority
  5716. {
  5717. // Methods:
  5718. void ApplyAttributes();
  5719. void DrawDebugGeometry(DebugRenderer, bool);
  5720. Variant GetAttribute(const String&) const;
  5721. ValueAnimation GetAttributeAnimation(const String&) const;
  5722. float GetAttributeAnimationSpeed(const String&) const;
  5723. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5724. Variant GetAttributeDefault(const String&) const;
  5725. bool Load(File, bool = false);
  5726. bool Load(VectorBuffer&, bool = false);
  5727. bool LoadXML(const XMLElement&, bool = false);
  5728. void MarkNetworkUpdate() const;
  5729. void Remove();
  5730. void RemoveInstanceDefault();
  5731. void ResetToDefault();
  5732. bool Save(File) const;
  5733. bool Save(VectorBuffer&) const;
  5734. bool SaveXML(XMLElement&) const;
  5735. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5736. bool SetAttribute(const String&, const Variant&);
  5737. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5738. void SetAttributeAnimationSpeed(const String&, float);
  5739. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  5740. // Properties:
  5741. bool alwaysUpdateOwner;
  5742. bool animationEnabled;
  5743. /* readonly */
  5744. Array<Variant> attributeDefaults;
  5745. /* readonly */
  5746. Array<AttributeInfo> attributeInfos;
  5747. Array<Variant> attributes;
  5748. float basePriority;
  5749. /* readonly */
  5750. StringHash baseType;
  5751. /* readonly */
  5752. String category;
  5753. float distanceFactor;
  5754. bool enabled;
  5755. /* readonly */
  5756. bool enabledEffective;
  5757. /* readonly */
  5758. uint id;
  5759. float minPriority;
  5760. /* readonly */
  5761. Node node;
  5762. /* readonly */
  5763. uint numAttributes;
  5764. ObjectAnimation objectAnimation;
  5765. /* readonly */
  5766. int refs;
  5767. bool temporary;
  5768. /* readonly */
  5769. StringHash type;
  5770. /* readonly */
  5771. String typeName;
  5772. /* readonly */
  5773. int weakRefs;
  5774. };
  5775. class Node
  5776. {
  5777. // Methods:
  5778. void AddChild(Node, uint = M_MAX_UNSIGNED);
  5779. void ApplyAttributes();
  5780. Node Clone(CreateMode = REPLICATED);
  5781. Component CloneComponent(Component, CreateMode, uint = 0);
  5782. Component CloneComponent(Component, uint = 0);
  5783. Node CreateChild(const String& = String ( ), CreateMode = REPLICATED, uint = 0);
  5784. Component CreateComponent(const String&, CreateMode = REPLICATED, uint = 0);
  5785. ScriptObject CreateScriptObject(ScriptFile, const String&, CreateMode = REPLICATED);
  5786. ScriptObject CreateScriptObject(const String&, const String&, CreateMode = REPLICATED);
  5787. Variant GetAttribute(const String&) const;
  5788. ValueAnimation GetAttributeAnimation(const String&) const;
  5789. float GetAttributeAnimationSpeed(const String&) const;
  5790. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5791. Variant GetAttributeDefault(const String&) const;
  5792. Node GetChild(const String&, bool = false) const;
  5793. Array<Node> GetChildren(bool = false) const;
  5794. Array<Node> GetChildrenWithComponent(const String&, bool = false) const;
  5795. Array<Node> GetChildrenWithScript(bool = false) const;
  5796. Array<Node> GetChildrenWithScript(const String&, bool = false) const;
  5797. Component GetComponent(const String&) const;
  5798. Array<Component> GetComponents() const;
  5799. Array<Component> GetComponents(const String&, bool = false) const;
  5800. Component GetOrCreateComponent(const String&, CreateMode = REPLICATED, uint = 0);
  5801. ScriptObject GetScriptObject() const;
  5802. ScriptObject GetScriptObject(const String&) const;
  5803. bool HasComponent(const String&) const;
  5804. bool Load(File, bool = false);
  5805. bool Load(VectorBuffer&, bool = false);
  5806. bool LoadXML(const XMLElement&, bool = false);
  5807. Vector3 LocalToWorld(const Vector3&) const;
  5808. Vector3 LocalToWorld(const Vector4&) const;
  5809. Vector2 LocalToWorld2D(const Vector2&) const;
  5810. bool LookAt(const Vector3&, const Vector3& = Vector3 ( 0 , 1 , 0 ), TransformSpace = TS_WORLD);
  5811. void MarkNetworkUpdate() const;
  5812. void Pitch(float, TransformSpace = TS_LOCAL);
  5813. void Remove();
  5814. void RemoveAllChildren();
  5815. void RemoveAllComponents();
  5816. void RemoveChild(Node);
  5817. void RemoveChildren(bool, bool, bool);
  5818. void RemoveComponent(Component);
  5819. void RemoveComponent(const String&);
  5820. void RemoveComponents(bool, bool);
  5821. void RemoveInstanceDefault();
  5822. void ResetDeepEnabled();
  5823. void ResetToDefault();
  5824. void Roll(float, TransformSpace = TS_LOCAL);
  5825. void Rotate(const Quaternion&, TransformSpace = TS_LOCAL);
  5826. void Rotate2D(float, TransformSpace = TS_LOCAL);
  5827. void RotateAround(const Vector3&, const Quaternion&, TransformSpace = TS_LOCAL);
  5828. void RotateAround2D(const Vector2&, float, TransformSpace = TS_LOCAL);
  5829. bool Save(File) const;
  5830. bool Save(VectorBuffer&) const;
  5831. bool SaveXML(File);
  5832. bool SaveXML(VectorBuffer&);
  5833. bool SaveXML(XMLElement&) const;
  5834. void Scale(const Vector3&);
  5835. void Scale(float);
  5836. void Scale2D(const Vector2&);
  5837. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5838. bool SetAttribute(const String&, const Variant&);
  5839. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5840. void SetAttributeAnimationSpeed(const String&, float);
  5841. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  5842. void SetDeepEnabled(bool);
  5843. void SetEnabledRecursive(bool);
  5844. void SetPosition2D(float, float);
  5845. void SetScale(float);
  5846. void SetScale2D(float, float);
  5847. void SetTransform(const Vector3&, const Quaternion&);
  5848. void SetTransform(const Vector3&, const Quaternion&, const Vector3&);
  5849. void SetTransform(const Vector3&, const Quaternion&, float);
  5850. void SetTransform2D(const Vector2&, float);
  5851. void SetTransform2D(const Vector2&, float, const Vector2&);
  5852. void SetTransform2D(const Vector2&, float, float);
  5853. void SetWorldTransform(const Vector3&, const Quaternion&);
  5854. void SetWorldTransform(const Vector3&, const Quaternion&, const Vector3&);
  5855. void SetWorldTransform(const Vector3&, const Quaternion&, float);
  5856. void SetWorldTransform2D(const Vector2&, float);
  5857. void SetWorldTransform2D(const Vector2&, float, const Vector2&);
  5858. void SetWorldTransform2D(const Vector2&, float, float);
  5859. void Translate(const Vector3&, TransformSpace = TS_LOCAL);
  5860. void Translate2D(const Vector2&, TransformSpace = TS_LOCAL);
  5861. Vector3 WorldToLocal(const Vector3&) const;
  5862. Vector3 WorldToLocal(const Vector4&) const;
  5863. Vector2 WorldToLocal2D(const Vector2&) const;
  5864. void Yaw(float, TransformSpace = TS_LOCAL);
  5865. // Properties:
  5866. bool animationEnabled;
  5867. /* readonly */
  5868. Array<Variant> attributeDefaults;
  5869. /* readonly */
  5870. Array<AttributeInfo> attributeInfos;
  5871. Array<Variant> attributes;
  5872. /* readonly */
  5873. StringHash baseType;
  5874. /* readonly */
  5875. String category;
  5876. /* readonly */
  5877. Array<Node> children;
  5878. /* readonly */
  5879. Array<Component> components;
  5880. Vector3 direction;
  5881. bool enabled;
  5882. /* readonly */
  5883. bool enabledSelf;
  5884. /* readonly */
  5885. uint id;
  5886. String name;
  5887. /* readonly */
  5888. uint numAllChildren;
  5889. /* readonly */
  5890. uint numAttributes;
  5891. /* readonly */
  5892. uint numChildren;
  5893. /* readonly */
  5894. uint numComponents;
  5895. ObjectAnimation objectAnimation;
  5896. Connection owner;
  5897. Node parent;
  5898. Vector3 position;
  5899. Vector2 position2D;
  5900. /* readonly */
  5901. int refs;
  5902. /* readonly */
  5903. Vector3 right;
  5904. Quaternion rotation;
  5905. float rotation2D;
  5906. Vector3 scale;
  5907. Vector2 scale2D;
  5908. /* readonly */
  5909. Scene scene;
  5910. /* readonly */
  5911. ScriptObject scriptObject;
  5912. bool temporary;
  5913. /* readonly */
  5914. Matrix3x4 transform;
  5915. /* readonly */
  5916. StringHash type;
  5917. /* readonly */
  5918. String typeName;
  5919. /* readonly */
  5920. Vector3 up;
  5921. /* readonly */
  5922. VariantMap vars;
  5923. /* readonly */
  5924. int weakRefs;
  5925. Vector3 worldDirection;
  5926. Vector3 worldPosition;
  5927. Vector2 worldPosition2D;
  5928. /* readonly */
  5929. Vector3 worldRight;
  5930. Quaternion worldRotation;
  5931. float worldRotation2D;
  5932. Vector3 worldScale;
  5933. Vector2 worldScale2D;
  5934. /* readonly */
  5935. Matrix3x4 worldTransform;
  5936. /* readonly */
  5937. Vector3 worldUp;
  5938. };
  5939. class Object
  5940. {
  5941. // Methods:
  5942. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5943. // Properties:
  5944. /* readonly */
  5945. StringHash baseType;
  5946. /* readonly */
  5947. String category;
  5948. /* readonly */
  5949. int refs;
  5950. /* readonly */
  5951. StringHash type;
  5952. /* readonly */
  5953. String typeName;
  5954. /* readonly */
  5955. int weakRefs;
  5956. };
  5957. class ObjectAnimation
  5958. {
  5959. // Methods:
  5960. void AddAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  5961. ValueAnimation GetAttributeAnimation(const String&) const;
  5962. float GetAttributeAnimationSpeed(const String&) const;
  5963. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  5964. bool Load(File);
  5965. bool Load(VectorBuffer&);
  5966. void RemoveAttributeAnimation(ValueAnimation);
  5967. void RemoveAttributeAnimation(const String&);
  5968. bool Save(File) const;
  5969. bool Save(VectorBuffer&) const;
  5970. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  5971. // Properties:
  5972. /* readonly */
  5973. Array<Variant> attributeAnimations;
  5974. /* readonly */
  5975. StringHash baseType;
  5976. /* readonly */
  5977. String category;
  5978. /* readonly */
  5979. uint memoryUse;
  5980. String name;
  5981. /* readonly */
  5982. int refs;
  5983. /* readonly */
  5984. Array<Variant> speeds;
  5985. /* readonly */
  5986. StringHash type;
  5987. /* readonly */
  5988. String typeName;
  5989. /* readonly */
  5990. uint useTimer;
  5991. /* readonly */
  5992. int weakRefs;
  5993. /* readonly */
  5994. Array<Variant> wrapModes;
  5995. };
  5996. class Octree
  5997. {
  5998. // Methods:
  5999. void AddManualDrawable(Drawable);
  6000. void ApplyAttributes();
  6001. void DrawDebugGeometry(DebugRenderer, bool);
  6002. void DrawDebugGeometry(bool) const;
  6003. Variant GetAttribute(const String&) const;
  6004. ValueAnimation GetAttributeAnimation(const String&) const;
  6005. float GetAttributeAnimationSpeed(const String&) const;
  6006. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6007. Variant GetAttributeDefault(const String&) const;
  6008. Array<Drawable> GetDrawables(const BoundingBox&, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK);
  6009. Array<Drawable> GetDrawables(const Frustum&, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK);
  6010. Array<Drawable> GetDrawables(const Sphere&, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK);
  6011. Array<Drawable> GetDrawables(const Vector3&, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK);
  6012. bool Load(File, bool = false);
  6013. bool Load(VectorBuffer&, bool = false);
  6014. bool LoadXML(const XMLElement&, bool = false);
  6015. void MarkNetworkUpdate() const;
  6016. Array<RayQueryResult> Raycast(const Ray&, RayQueryLevel = RAY_TRIANGLE, float = M_INFINITY, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK) const;
  6017. RayQueryResult RaycastSingle(const Ray&, RayQueryLevel = RAY_TRIANGLE, float = M_INFINITY, uint8 = DRAWABLE_ANY, uint = DEFAULT_VIEWMASK) const;
  6018. void Remove();
  6019. void RemoveInstanceDefault();
  6020. void RemoveManualDrawable(Drawable);
  6021. void ResetToDefault();
  6022. bool Save(File) const;
  6023. bool Save(VectorBuffer&) const;
  6024. bool SaveXML(XMLElement&) const;
  6025. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6026. bool SetAttribute(const String&, const Variant&);
  6027. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6028. void SetAttributeAnimationSpeed(const String&, float);
  6029. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6030. void SetSize(const BoundingBox&, uint);
  6031. // Properties:
  6032. bool animationEnabled;
  6033. /* readonly */
  6034. Array<Variant> attributeDefaults;
  6035. /* readonly */
  6036. Array<AttributeInfo> attributeInfos;
  6037. Array<Variant> attributes;
  6038. /* readonly */
  6039. StringHash baseType;
  6040. /* readonly */
  6041. String category;
  6042. bool enabled;
  6043. /* readonly */
  6044. bool enabledEffective;
  6045. /* readonly */
  6046. uint id;
  6047. /* readonly */
  6048. Node node;
  6049. /* readonly */
  6050. uint numAttributes;
  6051. /* readonly */
  6052. uint numLevels;
  6053. ObjectAnimation objectAnimation;
  6054. /* readonly */
  6055. int refs;
  6056. bool temporary;
  6057. /* readonly */
  6058. StringHash type;
  6059. /* readonly */
  6060. String typeName;
  6061. /* readonly */
  6062. int weakRefs;
  6063. /* readonly */
  6064. BoundingBox worldBoundingBox;
  6065. };
  6066. class OffMeshConnection
  6067. {
  6068. // Methods:
  6069. void ApplyAttributes();
  6070. void DrawDebugGeometry(DebugRenderer, bool);
  6071. Variant GetAttribute(const String&) const;
  6072. ValueAnimation GetAttributeAnimation(const String&) const;
  6073. float GetAttributeAnimationSpeed(const String&) const;
  6074. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6075. Variant GetAttributeDefault(const String&) const;
  6076. bool Load(File, bool = false);
  6077. bool Load(VectorBuffer&, bool = false);
  6078. bool LoadXML(const XMLElement&, bool = false);
  6079. void MarkNetworkUpdate() const;
  6080. void Remove();
  6081. void RemoveInstanceDefault();
  6082. void ResetToDefault();
  6083. bool Save(File) const;
  6084. bool Save(VectorBuffer&) const;
  6085. bool SaveXML(XMLElement&) const;
  6086. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6087. bool SetAttribute(const String&, const Variant&);
  6088. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6089. void SetAttributeAnimationSpeed(const String&, float);
  6090. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6091. // Properties:
  6092. bool animationEnabled;
  6093. /* readonly */
  6094. Array<Variant> attributeDefaults;
  6095. /* readonly */
  6096. Array<AttributeInfo> attributeInfos;
  6097. Array<Variant> attributes;
  6098. /* readonly */
  6099. StringHash baseType;
  6100. bool bidirectional;
  6101. /* readonly */
  6102. String category;
  6103. bool enabled;
  6104. /* readonly */
  6105. bool enabledEffective;
  6106. Node endPoint;
  6107. /* readonly */
  6108. uint id;
  6109. /* readonly */
  6110. Node node;
  6111. /* readonly */
  6112. uint numAttributes;
  6113. ObjectAnimation objectAnimation;
  6114. float radius;
  6115. /* readonly */
  6116. int refs;
  6117. bool temporary;
  6118. /* readonly */
  6119. StringHash type;
  6120. /* readonly */
  6121. String typeName;
  6122. /* readonly */
  6123. int weakRefs;
  6124. };
  6125. class PackageFile
  6126. {
  6127. // Methods:
  6128. bool Exists(const String&) const;
  6129. Array<String> GetEntryNames() const;
  6130. bool Open(const String&, uint = 0) const;
  6131. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6132. bool compressed() const;
  6133. // Properties:
  6134. /* readonly */
  6135. StringHash baseType;
  6136. /* readonly */
  6137. String category;
  6138. /* readonly */
  6139. uint checksum;
  6140. /* readonly */
  6141. String name;
  6142. /* readonly */
  6143. uint numFiles;
  6144. /* readonly */
  6145. int refs;
  6146. /* readonly */
  6147. uint totalSize;
  6148. /* readonly */
  6149. StringHash type;
  6150. /* readonly */
  6151. String typeName;
  6152. /* readonly */
  6153. int weakRefs;
  6154. };
  6155. class ParticleEffect
  6156. {
  6157. // Methods:
  6158. void AddColorFrame(ColorFrame);
  6159. void AddColorTime(Color&, float);
  6160. void AddTextureFrame(TextureFrame);
  6161. void AddTextureTime(Rect&, float);
  6162. ColorFrame GetColorFrame(uint) const;
  6163. TextureFrame GetTextureFrame(uint) const;
  6164. bool Load(File);
  6165. bool Load(VectorBuffer&);
  6166. bool Load(const XMLElement&);
  6167. void RemoveColorFrame(uint);
  6168. void RemoveTextureFrame(uint);
  6169. bool Save(File) const;
  6170. bool Save(VectorBuffer&) const;
  6171. bool Save(XMLElement&) const;
  6172. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6173. void SetColorFrame(uint, ColorFrame);
  6174. void SetTextureFrame(uint, TextureFrame);
  6175. void SortColorFrames();
  6176. void SortTextureFrames();
  6177. // Properties:
  6178. float activeTime;
  6179. float animationLodBias;
  6180. /* readonly */
  6181. StringHash baseType;
  6182. /* readonly */
  6183. String category;
  6184. Vector3 constantForce;
  6185. float dampingForce;
  6186. Vector3 emitterSize;
  6187. EmitterType emitterType;
  6188. float inactiveTime;
  6189. Material material;
  6190. Vector3 maxDirection;
  6191. float maxEmissionRate;
  6192. Vector2 maxParticleSize;
  6193. float maxRotation;
  6194. float maxRotationSpeed;
  6195. float maxTimeToLive;
  6196. float maxVelocity;
  6197. /* readonly */
  6198. uint memoryUse;
  6199. Vector3 minDirection;
  6200. float minEmissionRate;
  6201. Vector2 minParticleSize;
  6202. float minRotation;
  6203. float minRotationSpeed;
  6204. float minTimeToLive;
  6205. float minVelocity;
  6206. String name;
  6207. uint numColorFrames;
  6208. uint numParticles;
  6209. uint numTextureFrames;
  6210. /* readonly */
  6211. int refs;
  6212. bool relative;
  6213. bool scaled;
  6214. float sizeAdd;
  6215. float sizeMul;
  6216. bool sorted;
  6217. /* readonly */
  6218. StringHash type;
  6219. /* readonly */
  6220. String typeName;
  6221. bool updateInvisible;
  6222. /* readonly */
  6223. uint useTimer;
  6224. /* readonly */
  6225. int weakRefs;
  6226. };
  6227. class ParticleEffect2D
  6228. {
  6229. // Methods:
  6230. bool Load(File);
  6231. bool Load(VectorBuffer&);
  6232. bool Save(File) const;
  6233. bool Save(VectorBuffer&) const;
  6234. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6235. // Properties:
  6236. /* readonly */
  6237. StringHash baseType;
  6238. /* readonly */
  6239. String category;
  6240. /* readonly */
  6241. uint memoryUse;
  6242. String name;
  6243. /* readonly */
  6244. int refs;
  6245. /* readonly */
  6246. StringHash type;
  6247. /* readonly */
  6248. String typeName;
  6249. /* readonly */
  6250. uint useTimer;
  6251. /* readonly */
  6252. int weakRefs;
  6253. };
  6254. class ParticleEmitter
  6255. {
  6256. // Methods:
  6257. void ApplyAttributes();
  6258. void ApplyEffect();
  6259. void Commit();
  6260. void DrawDebugGeometry(DebugRenderer, bool);
  6261. Variant GetAttribute(const String&) const;
  6262. ValueAnimation GetAttributeAnimation(const String&) const;
  6263. float GetAttributeAnimationSpeed(const String&) const;
  6264. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6265. Variant GetAttributeDefault(const String&) const;
  6266. bool IsInView(Camera) const;
  6267. bool Load(File, bool = false);
  6268. bool Load(VectorBuffer&, bool = false);
  6269. bool LoadXML(const XMLElement&, bool = false);
  6270. void MarkNetworkUpdate() const;
  6271. void Remove();
  6272. void RemoveAllParticles();
  6273. void RemoveInstanceDefault();
  6274. void Reset();
  6275. void ResetEmissionTimer();
  6276. void ResetToDefault();
  6277. bool Save(File) const;
  6278. bool Save(VectorBuffer&) const;
  6279. bool SaveXML(XMLElement&) const;
  6280. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6281. bool SetAttribute(const String&, const Variant&);
  6282. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6283. void SetAttributeAnimationSpeed(const String&, float);
  6284. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6285. // Properties:
  6286. bool animationEnabled;
  6287. float animationLodBias;
  6288. /* readonly */
  6289. Array<Variant> attributeDefaults;
  6290. /* readonly */
  6291. Array<AttributeInfo> attributeInfos;
  6292. Array<Variant> attributes;
  6293. /* readonly */
  6294. StringHash baseType;
  6295. /* readonly */
  6296. Array<Billboard> billboards;
  6297. /* readonly */
  6298. BoundingBox boundingBox;
  6299. bool castShadows;
  6300. /* readonly */
  6301. String category;
  6302. float drawDistance;
  6303. ParticleEffect effect;
  6304. bool emitting;
  6305. bool enabled;
  6306. /* readonly */
  6307. bool enabledEffective;
  6308. FaceCameraMode faceCameraMode;
  6309. /* readonly */
  6310. uint id;
  6311. /* readonly */
  6312. bool inView;
  6313. uint lightMask;
  6314. float lodBias;
  6315. Material material;
  6316. uint maxLights;
  6317. /* readonly */
  6318. Node node;
  6319. /* readonly */
  6320. uint numAttributes;
  6321. uint numBillboards;
  6322. uint numParticles;
  6323. ObjectAnimation objectAnimation;
  6324. bool occludee;
  6325. bool occluder;
  6326. /* readonly */
  6327. int refs;
  6328. bool relative;
  6329. bool scaled;
  6330. bool serializeParticles;
  6331. float shadowDistance;
  6332. uint shadowMask;
  6333. bool sorted;
  6334. bool temporary;
  6335. /* readonly */
  6336. StringHash type;
  6337. /* readonly */
  6338. String typeName;
  6339. uint viewMask;
  6340. /* readonly */
  6341. int weakRefs;
  6342. /* readonly */
  6343. BoundingBox worldBoundingBox;
  6344. /* readonly */
  6345. Zone zone;
  6346. uint zoneMask;
  6347. };
  6348. class ParticleEmitter2D
  6349. {
  6350. // Methods:
  6351. void ApplyAttributes();
  6352. void DrawDebugGeometry(DebugRenderer, bool);
  6353. Variant GetAttribute(const String&) const;
  6354. ValueAnimation GetAttributeAnimation(const String&) const;
  6355. float GetAttributeAnimationSpeed(const String&) const;
  6356. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6357. Variant GetAttributeDefault(const String&) const;
  6358. bool IsInView(Camera) const;
  6359. bool Load(File, bool = false);
  6360. bool Load(VectorBuffer&, bool = false);
  6361. bool LoadXML(const XMLElement&, bool = false);
  6362. void MarkNetworkUpdate() const;
  6363. void Remove();
  6364. void RemoveInstanceDefault();
  6365. void ResetToDefault();
  6366. bool Save(File) const;
  6367. bool Save(VectorBuffer&) const;
  6368. bool SaveXML(XMLElement&) const;
  6369. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6370. bool SetAttribute(const String&, const Variant&);
  6371. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6372. void SetAttributeAnimationSpeed(const String&, float);
  6373. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6374. // Properties:
  6375. bool animationEnabled;
  6376. /* readonly */
  6377. Array<Variant> attributeDefaults;
  6378. /* readonly */
  6379. Array<AttributeInfo> attributeInfos;
  6380. Array<Variant> attributes;
  6381. /* readonly */
  6382. StringHash baseType;
  6383. BlendMode blendMode;
  6384. /* readonly */
  6385. BoundingBox boundingBox;
  6386. bool castShadows;
  6387. /* readonly */
  6388. String category;
  6389. float drawDistance;
  6390. ParticleEffect2D effect;
  6391. bool enabled;
  6392. /* readonly */
  6393. bool enabledEffective;
  6394. /* readonly */
  6395. uint id;
  6396. /* readonly */
  6397. bool inView;
  6398. int layer;
  6399. uint lightMask;
  6400. float lodBias;
  6401. uint maxLights;
  6402. /* readonly */
  6403. Node node;
  6404. /* readonly */
  6405. uint numAttributes;
  6406. ObjectAnimation objectAnimation;
  6407. bool occludee;
  6408. bool occluder;
  6409. int orderInLayer;
  6410. /* readonly */
  6411. int refs;
  6412. float shadowDistance;
  6413. uint shadowMask;
  6414. Sprite2D sprite;
  6415. bool temporary;
  6416. Texture2D texture;
  6417. /* readonly */
  6418. StringHash type;
  6419. /* readonly */
  6420. String typeName;
  6421. uint viewMask;
  6422. /* readonly */
  6423. int weakRefs;
  6424. /* readonly */
  6425. BoundingBox worldBoundingBox;
  6426. uint zoneMask;
  6427. };
  6428. class Pass
  6429. {
  6430. // Properties:
  6431. bool alphaMask;
  6432. BlendMode blendMode;
  6433. CompareMode depthTestMode;
  6434. bool depthWrite;
  6435. bool desktop;
  6436. PassLightingMode lightingMode;
  6437. String pixelShader;
  6438. String pixelShaderDefines;
  6439. /* readonly */
  6440. int refs;
  6441. bool sm3;
  6442. String vertexShader;
  6443. String vertexShaderDefines;
  6444. /* readonly */
  6445. int weakRefs;
  6446. };
  6447. class PhysicsRaycastResult
  6448. {
  6449. // Properties:
  6450. /* readonly */
  6451. RigidBody body;
  6452. float distance;
  6453. Vector3 normal;
  6454. Vector3 position;
  6455. };
  6456. class PhysicsRaycastResult2D
  6457. {
  6458. // Properties:
  6459. /* readonly */
  6460. RigidBody2D body;
  6461. float distance;
  6462. Vector2 normal;
  6463. Vector2 position;
  6464. };
  6465. class PhysicsWorld
  6466. {
  6467. // Methods:
  6468. void ApplyAttributes();
  6469. PhysicsRaycastResult ConvexCast(CollisionShape, const Vector3&, const Quaternion&, const Vector3&, const Quaternion&, uint = 0xffff);
  6470. void DrawDebugGeometry(DebugRenderer, bool);
  6471. void DrawDebugGeometry(bool);
  6472. Variant GetAttribute(const String&) const;
  6473. ValueAnimation GetAttributeAnimation(const String&) const;
  6474. float GetAttributeAnimationSpeed(const String&) const;
  6475. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6476. Variant GetAttributeDefault(const String&) const;
  6477. Array<RigidBody> GetRigidBodies(RigidBody);
  6478. Array<RigidBody> GetRigidBodies(const BoundingBox&, uint = 0xffff);
  6479. Array<RigidBody> GetRigidBodies(const Sphere&, uint = 0xffff);
  6480. bool Load(File, bool = false);
  6481. bool Load(VectorBuffer&, bool = false);
  6482. bool LoadXML(const XMLElement&, bool = false);
  6483. void MarkNetworkUpdate() const;
  6484. Array<PhysicsRaycastResult> Raycast(const Ray&, float = M_INFINITY, uint = 0xffff);
  6485. PhysicsRaycastResult RaycastSingle(const Ray&, float = M_INFINITY, uint = 0xffff);
  6486. void Remove();
  6487. void RemoveCachedGeometry(Model);
  6488. void RemoveInstanceDefault();
  6489. void ResetToDefault();
  6490. bool Save(File) const;
  6491. bool Save(VectorBuffer&) const;
  6492. bool SaveXML(XMLElement&) const;
  6493. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6494. bool SetAttribute(const String&, const Variant&);
  6495. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6496. void SetAttributeAnimationSpeed(const String&, float);
  6497. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6498. PhysicsRaycastResult SphereCast(const Ray&, float, float = M_INFINITY, uint = 0xffff);
  6499. void Update(float);
  6500. void UpdateCollisions();
  6501. // Properties:
  6502. bool animationEnabled;
  6503. /* readonly */
  6504. Array<Variant> attributeDefaults;
  6505. /* readonly */
  6506. Array<AttributeInfo> attributeInfos;
  6507. Array<Variant> attributes;
  6508. /* readonly */
  6509. StringHash baseType;
  6510. /* readonly */
  6511. String category;
  6512. bool enabled;
  6513. /* readonly */
  6514. bool enabledEffective;
  6515. int fps;
  6516. Vector3 gravity;
  6517. /* readonly */
  6518. uint id;
  6519. bool internalEdge;
  6520. bool interpolation;
  6521. int maxSubSteps;
  6522. /* readonly */
  6523. Node node;
  6524. /* readonly */
  6525. uint numAttributes;
  6526. int numIterations;
  6527. ObjectAnimation objectAnimation;
  6528. /* readonly */
  6529. int refs;
  6530. bool splitImpulse;
  6531. bool temporary;
  6532. /* readonly */
  6533. StringHash type;
  6534. /* readonly */
  6535. String typeName;
  6536. /* readonly */
  6537. int weakRefs;
  6538. };
  6539. class PhysicsWorld2D
  6540. {
  6541. // Methods:
  6542. void ApplyAttributes();
  6543. void DrawDebugGeometry() const;
  6544. void DrawDebugGeometry(DebugRenderer, bool);
  6545. Variant GetAttribute(const String&) const;
  6546. ValueAnimation GetAttributeAnimation(const String&) const;
  6547. float GetAttributeAnimationSpeed(const String&) const;
  6548. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  6549. Variant GetAttributeDefault(const String&) const;
  6550. Array<RigidBody2D> GetRigidBodies(const Rect&, uint = 0xffff);
  6551. RigidBody2D GetRigidBody(const Vector2&, uint = 0xffff);
  6552. RigidBody2D GetRigidBody(int, int, uint = 0xffff);
  6553. bool Load(File, bool = false);
  6554. bool Load(VectorBuffer&, bool = false);
  6555. bool LoadXML(const XMLElement&, bool = false);
  6556. void MarkNetworkUpdate() const;
  6557. Array<PhysicsRaycastResult2D> Raycast(const Vector2&, const Vector2&, uint = 0xffff);
  6558. PhysicsRaycastResult2D RaycastSingle(const Vector2&, const Vector2&, uint = 0xffff);
  6559. void Remove();
  6560. void RemoveInstanceDefault();
  6561. void ResetToDefault();
  6562. bool Save(File) const;
  6563. bool Save(VectorBuffer&) const;
  6564. bool SaveXML(XMLElement&) const;
  6565. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6566. bool SetAttribute(const String&, const Variant&);
  6567. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  6568. void SetAttributeAnimationSpeed(const String&, float);
  6569. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  6570. // Properties:
  6571. bool allowSleeping;
  6572. bool animationEnabled;
  6573. /* readonly */
  6574. Array<Variant> attributeDefaults;
  6575. /* readonly */
  6576. Array<AttributeInfo> attributeInfos;
  6577. Array<Variant> attributes;
  6578. bool autoClearForces;
  6579. /* readonly */
  6580. StringHash baseType;
  6581. /* readonly */
  6582. String category;
  6583. bool continuousPhysics;
  6584. bool drawAabb;
  6585. bool drawCenterOfMass;
  6586. bool drawJoint;
  6587. bool drawPair;
  6588. bool drawShape;
  6589. bool enabled;
  6590. /* readonly */
  6591. bool enabledEffective;
  6592. Vector2 gravity;
  6593. /* readonly */
  6594. uint id;
  6595. /* readonly */
  6596. Node node;
  6597. /* readonly */
  6598. uint numAttributes;
  6599. ObjectAnimation objectAnimation;
  6600. uint positionIterations;
  6601. /* readonly */
  6602. int refs;
  6603. bool subStepping;
  6604. bool temporary;
  6605. /* readonly */
  6606. StringHash type;
  6607. /* readonly */
  6608. String typeName;
  6609. uint velocityIterations;
  6610. bool warmStarting;
  6611. /* readonly */
  6612. int weakRefs;
  6613. };
  6614. class Plane
  6615. {
  6616. // Methods:
  6617. void Define(const Vector3&, const Vector3&);
  6618. void Define(const Vector3&, const Vector3&, const Vector3&);
  6619. void Define(const Vector4&);
  6620. float Distance(const Vector3&) const;
  6621. Vector3 Project(const Vector3&) const;
  6622. Vector3 Reflect(const Vector3&) const;
  6623. Vector4 ToVector4() const;
  6624. void Transform(const Matrix3&);
  6625. void Transform(const Matrix3x4&);
  6626. void Transform(const Matrix4&);
  6627. Plane Transformed(const Matrix3&) const;
  6628. Plane Transformed(const Matrix3x4&) const;
  6629. Plane Transformed(const Matrix4&) const;
  6630. // Properties:
  6631. Vector3 absNormal;
  6632. float d;
  6633. Vector3 normal;
  6634. /* readonly */
  6635. Matrix3x4 reflectionMatrix;
  6636. };
  6637. class Polyhedron
  6638. {
  6639. // Methods:
  6640. void AddFace(const Vector3&, const Vector3&, const Vector3&);
  6641. void AddFace(const Vector3&, const Vector3&, const Vector3&, const Vector3&);
  6642. void AddFace(const Array<Vector3>);
  6643. void Clear();
  6644. void Clip(const BoundingBox&);
  6645. void Clip(const Frustum&);
  6646. void Define(const BoundingBox&);
  6647. void Define(const Frustum&);
  6648. void Transform(const Matrix3&);
  6649. void Transform(const Matrix3x4&);
  6650. Polyhedron Transformed(const Matrix3&) const;
  6651. Polyhedron Transformed(const Matrix3x4&) const;
  6652. // Properties:
  6653. /* readonly */
  6654. Array<Array<Vector3>> face;
  6655. /* readonly */
  6656. uint numFaces;
  6657. };
  6658. class PropertySet2D
  6659. {
  6660. // Methods:
  6661. bool HasProperty(const String&) const;
  6662. const String& GetProperty(const String&) const;
  6663. // Properties:
  6664. /* readonly */
  6665. int refs;
  6666. /* readonly */
  6667. int weakRefs;
  6668. };
  6669. class Quaternion
  6670. {
  6671. // Methods:
  6672. float DotProduct(const Quaternion&) const;
  6673. bool Equals(const Quaternion&) const;
  6674. void FromAngleAxis(float, const Vector3&);
  6675. void FromAxes(const Vector3&, const Vector3&, const Vector3&);
  6676. void FromEulerAngles(float, float, float);
  6677. bool FromLookRotation(const Vector3&, const Vector3&);
  6678. void FromRotationTo(const Vector3&, const Vector3&);
  6679. Quaternion Inverse() const;
  6680. bool IsNaN() const;
  6681. Quaternion Nlerp(Quaternion, float, bool) const;
  6682. void Normalize();
  6683. Quaternion Normalized() const;
  6684. Quaternion Slerp(Quaternion, float) const;
  6685. String ToString() const;
  6686. // Properties:
  6687. /* readonly */
  6688. Vector3 eulerAngles;
  6689. /* readonly */
  6690. float pitch;
  6691. /* readonly */
  6692. float roll;
  6693. float w;
  6694. float x;
  6695. float y;
  6696. /* readonly */
  6697. float yaw;
  6698. float z;
  6699. };
  6700. class Ray
  6701. {
  6702. // Methods:
  6703. Vector3 ClosestPoint(const Ray&) const;
  6704. void Define(const Vector3&, const Vector3&);
  6705. float Distance(const Vector3&) const;
  6706. float HitDistance(const BoundingBox&) const;
  6707. float HitDistance(const Frustum&, bool = true) const;
  6708. float HitDistance(const Plane&) const;
  6709. float HitDistance(const Sphere&) const;
  6710. float HitDistance(const Vector3&, const Vector3&, const Vector3&) const;
  6711. Vector3 Project(const Vector3&) const;
  6712. Ray Transformed(const Matrix3x4&) const;
  6713. // Properties:
  6714. Vector3 direction;
  6715. Vector3 origin;
  6716. };
  6717. class RayQueryResult
  6718. {
  6719. // Properties:
  6720. float distance;
  6721. /* readonly */
  6722. Drawable drawable;
  6723. /* readonly */
  6724. Node node;
  6725. Vector3 normal;
  6726. Vector3 position;
  6727. uint subObject;
  6728. };
  6729. class Rect
  6730. {
  6731. // Methods:
  6732. void Clear();
  6733. void Clip(const Rect&);
  6734. void Define(const Vector2&);
  6735. void Define(const Vector2&, const Vector2&);
  6736. bool Equals(const Rect&) const;
  6737. Intersection IsInside(const Vector2&) const;
  6738. void Merge(const Rect&);
  6739. void Merge(const Vector2&);
  6740. Vector4 ToVector4() const;
  6741. // Properties:
  6742. float bottom;
  6743. /* readonly */
  6744. Vector2 center;
  6745. bool defined;
  6746. /* readonly */
  6747. Vector2 halfSize;
  6748. float left;
  6749. Vector2 max;
  6750. Vector2 min;
  6751. float right;
  6752. /* readonly */
  6753. Vector2 size;
  6754. float top;
  6755. };
  6756. class RefCounted
  6757. {
  6758. // Properties:
  6759. /* readonly */
  6760. int refs;
  6761. /* readonly */
  6762. int weakRefs;
  6763. };
  6764. class RenderPath
  6765. {
  6766. // Methods:
  6767. void AddCommand(const RenderPathCommand&);
  6768. void AddRenderTarget(const RenderTargetInfo&);
  6769. bool Append(XMLFile);
  6770. RenderPath Clone();
  6771. void InsertCommand(uint, const RenderPathCommand&);
  6772. bool Load(XMLFile);
  6773. void RemoveCommand(uint);
  6774. void RemoveCommands(const String&);
  6775. void RemoveRenderTarget(const String&);
  6776. void RemoveRenderTarget(uint);
  6777. void RemoveRenderTargts(const String&);
  6778. void SetEnabled(const String&, bool);
  6779. void ToggleEnabled(const String&);
  6780. // Properties:
  6781. Array<RenderPathCommand> commands;
  6782. /* readonly */
  6783. uint numCommands;
  6784. /* readonly */
  6785. uint numRenderTargets;
  6786. /* readonly */
  6787. int refs;
  6788. Array<RenderTargetInfo> renderTargets;
  6789. Array<Variant> shaderParameters;
  6790. /* readonly */
  6791. int weakRefs;
  6792. };
  6793. class RenderPathCommand
  6794. {
  6795. // Methods:
  6796. void RemoveShaderParameter(const String&);
  6797. // Properties:
  6798. Color clearColor;
  6799. float clearDepth;
  6800. uint clearFlags;
  6801. uint clearStencil;
  6802. String depthStencilName;
  6803. bool enabled;
  6804. bool markToStencil;
  6805. String metadata;
  6806. uint numOutputs;
  6807. Array<String> outputNames;
  6808. String pass;
  6809. String pixelShaderDefines;
  6810. String pixelShaderName;
  6811. Array<Variant> shaderParameters;
  6812. RenderCommandSortMode sortMode;
  6813. String tag;
  6814. Array<String> textureNames;
  6815. RenderCommandType type;
  6816. bool useFogColor;
  6817. bool useLitBase;
  6818. bool vertexLights;
  6819. String vertexShaderDefines;
  6820. String vertexShaderName;
  6821. };
  6822. class RenderSurface
  6823. {
  6824. // Methods:
  6825. void QueueUpdate();
  6826. // Properties:
  6827. /* readonly */
  6828. int height;
  6829. RenderSurface linkedDepthStencil;
  6830. RenderSurface linkedRenderTarget;
  6831. uint numViewports;
  6832. /* readonly */
  6833. Texture parentTexture;
  6834. RenderSurfaceUpdateMode updateMode;
  6835. /* readonly */
  6836. TextureUsage usage;
  6837. Array<Viewport> viewports;
  6838. /* readonly */
  6839. int width;
  6840. };
  6841. class RenderTargetInfo
  6842. {
  6843. // Properties:
  6844. bool enabled;
  6845. bool filtered;
  6846. uint format;
  6847. String name;
  6848. bool persistent;
  6849. bool sRGB;
  6850. Vector2 size;
  6851. RenderTargetSizeMode sizeMode;
  6852. String tag;
  6853. };
  6854. class Renderer
  6855. {
  6856. // Methods:
  6857. void DrawDebugGeometry(bool) const;
  6858. void ReloadShaders() const;
  6859. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6860. void SetDefaultRenderPath(XMLFile);
  6861. // Properties:
  6862. /* readonly */
  6863. StringHash baseType;
  6864. /* readonly */
  6865. String category;
  6866. /* readonly */
  6867. Material defaultLightRamp;
  6868. /* readonly */
  6869. Material defaultLightSpot;
  6870. /* readonly */
  6871. Material defaultMaterial;
  6872. RenderPath defaultRenderPath;
  6873. /* readonly */
  6874. Zone defaultZone;
  6875. bool drawShadows;
  6876. bool dynamicInstancing;
  6877. bool hdrRendering;
  6878. int materialQuality;
  6879. int maxInstanceTriangles;
  6880. int maxOccluderTriangles;
  6881. int maxShadowMaps;
  6882. int maxSortedInstances;
  6883. int minInstances;
  6884. float mobileShadowBiasAdd;
  6885. float mobileShadowBiasMul;
  6886. /* readonly */
  6887. uint numBatches;
  6888. /* readonly */
  6889. Array<uint> numGeometries;
  6890. /* readonly */
  6891. Array<uint> numLights;
  6892. /* readonly */
  6893. Array<uint> numOccluders;
  6894. /* readonly */
  6895. uint numPrimitives;
  6896. /* readonly */
  6897. Array<uint> numShadowMaps;
  6898. uint numViewports;
  6899. /* readonly */
  6900. uint numViews;
  6901. float occluderSizeThreshold;
  6902. int occlusionBufferSize;
  6903. /* readonly */
  6904. int refs;
  6905. bool reuseShadowMaps;
  6906. int shadowMapSize;
  6907. int shadowQuality;
  6908. bool specularLighting;
  6909. int textureAnisotropy;
  6910. TextureFilterMode textureFilterMode;
  6911. int textureQuality;
  6912. /* readonly */
  6913. StringHash type;
  6914. /* readonly */
  6915. String typeName;
  6916. Array<Viewport> viewports;
  6917. /* readonly */
  6918. int weakRefs;
  6919. };
  6920. class Resource
  6921. {
  6922. // Methods:
  6923. bool Load(File);
  6924. bool Load(VectorBuffer&);
  6925. bool Save(File) const;
  6926. bool Save(VectorBuffer&) const;
  6927. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6928. // Properties:
  6929. /* readonly */
  6930. StringHash baseType;
  6931. /* readonly */
  6932. String category;
  6933. /* readonly */
  6934. uint memoryUse;
  6935. String name;
  6936. /* readonly */
  6937. int refs;
  6938. /* readonly */
  6939. StringHash type;
  6940. /* readonly */
  6941. String typeName;
  6942. /* readonly */
  6943. uint useTimer;
  6944. /* readonly */
  6945. int weakRefs;
  6946. };
  6947. class ResourceCache
  6948. {
  6949. // Methods:
  6950. bool AddManualResource(Resource);
  6951. bool AddPackageFile(PackageFile, uint = M_MAX_UNSIGNED);
  6952. bool AddPackageFile(const String&, uint = M_MAX_UNSIGNED);
  6953. bool AddResourceDir(const String&, uint = M_MAX_UNSIGNED);
  6954. bool BackgroundLoadResource(const String&, const String&, bool = true);
  6955. bool Exists(const String&) const;
  6956. File GetFile(const String&);
  6957. String GetPreferredResourceDir(const String&) const;
  6958. Resource GetResource(StringHash, const String&, bool = true);
  6959. Resource GetResource(const String&, const String&, bool = true);
  6960. String GetResourceFileName(const String&) const;
  6961. void ReleaseAllResources(bool = false);
  6962. void ReleaseResource(const String&, const String&, bool = false);
  6963. void ReleaseResources(StringHash, bool = false);
  6964. void ReleaseResources(const String&, bool = false);
  6965. void ReleaseResources(const String&, const String&, bool = false);
  6966. bool ReloadResource(Resource);
  6967. void ReloadResourceWithDependencies(const String&);
  6968. void RemovePackageFile(PackageFile, bool = true, bool = false);
  6969. void RemovePackageFile(const String&, bool = true, bool = false);
  6970. void RemoveResourceDir(const String&);
  6971. String SanitateResourceDirName(const String&) const;
  6972. String SanitateResourceName(const String&) const;
  6973. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  6974. // Properties:
  6975. bool autoReloadResources;
  6976. /* readonly */
  6977. StringHash baseType;
  6978. /* readonly */
  6979. String category;
  6980. int finishBackgroundResourcesMs;
  6981. Array<uint> memoryBudget;
  6982. /* readonly */
  6983. Array<uint> memoryUse;
  6984. /* readonly */
  6985. uint numBackgroundLoadResources;
  6986. /* readonly */
  6987. Array<PackageFile> packageFiles;
  6988. /* readonly */
  6989. int refs;
  6990. /* readonly */
  6991. Array<String> resourceDirs;
  6992. bool returnFailedResources;
  6993. /* readonly */
  6994. bool seachPackagesFirst;
  6995. /* writeonly */
  6996. bool searchPackagesFirst;
  6997. /* readonly */
  6998. uint totalMemoryUse;
  6999. /* readonly */
  7000. StringHash type;
  7001. /* readonly */
  7002. String typeName;
  7003. /* readonly */
  7004. int weakRefs;
  7005. };
  7006. class ResourceRef
  7007. {
  7008. // Properties:
  7009. String name;
  7010. StringHash type;
  7011. };
  7012. class ResourceRefList
  7013. {
  7014. // Methods:
  7015. void Resize(uint);
  7016. // Properties:
  7017. /* readonly */
  7018. bool empty;
  7019. /* readonly */
  7020. uint length;
  7021. Array<String> names;
  7022. StringHash type;
  7023. };
  7024. class RigidBody
  7025. {
  7026. // Methods:
  7027. void Activate();
  7028. void ApplyAttributes();
  7029. void ApplyForce(const Vector3&);
  7030. void ApplyForce(const Vector3&, const Vector3&);
  7031. void ApplyImpulse(const Vector3&);
  7032. void ApplyImpulse(const Vector3&, const Vector3&);
  7033. void ApplyTorque(const Vector3&);
  7034. void ApplyTorqueImpulse(const Vector3&);
  7035. void DisableMassUpdate();
  7036. void DrawDebugGeometry(DebugRenderer, bool);
  7037. void EnableMassUpdate();
  7038. Variant GetAttribute(const String&) const;
  7039. ValueAnimation GetAttributeAnimation(const String&) const;
  7040. float GetAttributeAnimationSpeed(const String&) const;
  7041. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7042. Variant GetAttributeDefault(const String&) const;
  7043. Vector3 GetVelocityAtPoint(const Vector3&) const;
  7044. bool Load(File, bool = false);
  7045. bool Load(VectorBuffer&, bool = false);
  7046. bool LoadXML(const XMLElement&, bool = false);
  7047. void MarkNetworkUpdate() const;
  7048. void ReAddBodyToWorld();
  7049. void Remove();
  7050. void RemoveInstanceDefault();
  7051. void ResetForces();
  7052. void ResetToDefault();
  7053. bool Save(File) const;
  7054. bool Save(VectorBuffer&) const;
  7055. bool SaveXML(XMLElement&) const;
  7056. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7057. bool SetAttribute(const String&, const Variant&);
  7058. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7059. void SetAttributeAnimationSpeed(const String&, float);
  7060. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7061. void SetCollisionLayerAndMask(uint, uint);
  7062. void SetTransform(const Vector3&, const Quaternion&);
  7063. // Properties:
  7064. /* readonly */
  7065. bool active;
  7066. float angularDamping;
  7067. Vector3 angularFactor;
  7068. float angularRestThreshold;
  7069. Vector3 angularVelocity;
  7070. bool animationEnabled;
  7071. Vector3 anisotropicFriction;
  7072. /* readonly */
  7073. Array<Variant> attributeDefaults;
  7074. /* readonly */
  7075. Array<AttributeInfo> attributeInfos;
  7076. Array<Variant> attributes;
  7077. /* readonly */
  7078. StringHash baseType;
  7079. /* readonly */
  7080. String category;
  7081. float ccdMotionThreshold;
  7082. float ccdRadius;
  7083. /* readonly */
  7084. Vector3 centerOfMass;
  7085. /* readonly */
  7086. Array<RigidBody> collidingBodies;
  7087. CollisionEventMode collisionEventMode;
  7088. uint collisionLayer;
  7089. uint collisionMask;
  7090. float contactProcessingThreshold;
  7091. bool enabled;
  7092. /* readonly */
  7093. bool enabledEffective;
  7094. float friction;
  7095. Vector3 gravityOverride;
  7096. /* readonly */
  7097. uint id;
  7098. bool kinematic;
  7099. float linearDamping;
  7100. Vector3 linearFactor;
  7101. float linearRestThreshold;
  7102. Vector3 linearVelocity;
  7103. float mass;
  7104. /* readonly */
  7105. Node node;
  7106. /* readonly */
  7107. uint numAttributes;
  7108. ObjectAnimation objectAnimation;
  7109. Vector3 position;
  7110. /* readonly */
  7111. int refs;
  7112. float restitution;
  7113. float rollingFriction;
  7114. Quaternion rotation;
  7115. bool temporary;
  7116. bool trigger;
  7117. /* readonly */
  7118. StringHash type;
  7119. /* readonly */
  7120. String typeName;
  7121. bool useGravity;
  7122. /* readonly */
  7123. int weakRefs;
  7124. };
  7125. class RigidBody2D
  7126. {
  7127. // Methods:
  7128. void ApplyAngularImpulse(float, bool);
  7129. void ApplyAttributes();
  7130. void ApplyForce(const Vector2&, const Vector2&, bool);
  7131. void ApplyForceToCenter(const Vector2&, bool);
  7132. void ApplyLinearImpulse(const Vector2&, const Vector2&, bool);
  7133. void ApplyTorque(float, bool);
  7134. void DrawDebugGeometry(DebugRenderer, bool);
  7135. Variant GetAttribute(const String&) const;
  7136. ValueAnimation GetAttributeAnimation(const String&) const;
  7137. float GetAttributeAnimationSpeed(const String&) const;
  7138. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7139. Variant GetAttributeDefault(const String&) const;
  7140. bool Load(File, bool = false);
  7141. bool Load(VectorBuffer&, bool = false);
  7142. bool LoadXML(const XMLElement&, bool = false);
  7143. void MarkNetworkUpdate() const;
  7144. void Remove();
  7145. void RemoveInstanceDefault();
  7146. void ResetToDefault();
  7147. bool Save(File) const;
  7148. bool Save(VectorBuffer&) const;
  7149. bool SaveXML(XMLElement&) const;
  7150. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7151. bool SetAttribute(const String&, const Variant&);
  7152. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7153. void SetAttributeAnimationSpeed(const String&, float);
  7154. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7155. // Properties:
  7156. bool allowSleep;
  7157. float angularDamping;
  7158. bool animationEnabled;
  7159. /* readonly */
  7160. Array<Variant> attributeDefaults;
  7161. /* readonly */
  7162. Array<AttributeInfo> attributeInfos;
  7163. Array<Variant> attributes;
  7164. bool awake;
  7165. /* readonly */
  7166. StringHash baseType;
  7167. BodyType2D bodyType;
  7168. bool bullet;
  7169. /* readonly */
  7170. String category;
  7171. bool enabled;
  7172. /* readonly */
  7173. bool enabledEffective;
  7174. bool fixedRotation;
  7175. float gravityScale;
  7176. /* readonly */
  7177. uint id;
  7178. float inertia;
  7179. float linearDamping;
  7180. Vector2 linearVelocity;
  7181. float mass;
  7182. Vector2 massCenter;
  7183. /* readonly */
  7184. Node node;
  7185. /* readonly */
  7186. uint numAttributes;
  7187. ObjectAnimation objectAnimation;
  7188. /* readonly */
  7189. int refs;
  7190. bool temporary;
  7191. /* readonly */
  7192. StringHash type;
  7193. /* readonly */
  7194. String typeName;
  7195. bool useFixtureMass;
  7196. /* readonly */
  7197. int weakRefs;
  7198. };
  7199. class Scene
  7200. {
  7201. // Methods:
  7202. void AddChild(Node, uint = M_MAX_UNSIGNED);
  7203. void AddRequiredPackageFile(PackageFile);
  7204. void ApplyAttributes();
  7205. void Clear(bool = true, bool = true);
  7206. void ClearRequiredPackageFiles();
  7207. Component CloneComponent(Component, CreateMode, uint = 0);
  7208. Component CloneComponent(Component, uint = 0);
  7209. Node CreateChild(const String& = String ( ), CreateMode = REPLICATED, uint = 0);
  7210. Component CreateComponent(const String&, CreateMode = REPLICATED, uint = 0);
  7211. ScriptObject CreateScriptObject(ScriptFile, const String&, CreateMode = REPLICATED);
  7212. ScriptObject CreateScriptObject(const String&, const String&, CreateMode = REPLICATED);
  7213. Variant GetAttribute(const String&) const;
  7214. ValueAnimation GetAttributeAnimation(const String&) const;
  7215. float GetAttributeAnimationSpeed(const String&) const;
  7216. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7217. Variant GetAttributeDefault(const String&) const;
  7218. Node GetChild(const String&, bool = false) const;
  7219. Array<Node> GetChildren(bool = false) const;
  7220. Array<Node> GetChildrenWithComponent(const String&, bool = false) const;
  7221. Array<Node> GetChildrenWithScript(bool = false) const;
  7222. Array<Node> GetChildrenWithScript(const String&, bool = false) const;
  7223. Component GetComponent(const String&) const;
  7224. Component GetComponent(uint);
  7225. Array<Component> GetComponents() const;
  7226. Array<Component> GetComponents(const String&, bool = false) const;
  7227. Node GetNode(uint);
  7228. Component GetOrCreateComponent(const String&, CreateMode = REPLICATED, uint = 0);
  7229. ScriptObject GetScriptObject() const;
  7230. ScriptObject GetScriptObject(const String&) const;
  7231. bool HasComponent(const String&) const;
  7232. Node Instantiate(File, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7233. Node Instantiate(VectorBuffer&, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7234. Node InstantiateXML(File, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7235. Node InstantiateXML(VectorBuffer&, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7236. Node InstantiateXML(XMLFile, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7237. Node InstantiateXML(const XMLElement&, const Vector3&, const Quaternion&, CreateMode = REPLICATED);
  7238. bool Load(File, bool = false);
  7239. bool Load(VectorBuffer&, bool = false);
  7240. bool LoadAsync(File, LoadMode = LOAD_SCENE_AND_RESOURCES);
  7241. bool LoadAsyncXML(File, LoadMode = LOAD_SCENE_AND_RESOURCES);
  7242. bool LoadXML(File);
  7243. bool LoadXML(VectorBuffer&);
  7244. bool LoadXML(const XMLElement&, bool = false);
  7245. Vector3 LocalToWorld(const Vector3&) const;
  7246. Vector3 LocalToWorld(const Vector4&) const;
  7247. Vector2 LocalToWorld2D(const Vector2&) const;
  7248. bool LookAt(const Vector3&, const Vector3& = Vector3 ( 0 , 1 , 0 ), TransformSpace = TS_WORLD);
  7249. void MarkNetworkUpdate() const;
  7250. void Pitch(float, TransformSpace = TS_LOCAL);
  7251. void RegisterVar(const String&);
  7252. void Remove();
  7253. void RemoveAllChildren();
  7254. void RemoveAllComponents();
  7255. void RemoveChild(Node);
  7256. void RemoveChildren(bool, bool, bool);
  7257. void RemoveComponent(Component);
  7258. void RemoveComponent(const String&);
  7259. void RemoveComponents(bool, bool);
  7260. void RemoveInstanceDefault();
  7261. void ResetToDefault();
  7262. void Roll(float, TransformSpace = TS_LOCAL);
  7263. void Rotate(const Quaternion&, TransformSpace = TS_LOCAL);
  7264. void Rotate2D(float, TransformSpace = TS_LOCAL);
  7265. void RotateAround(const Vector3&, const Quaternion&, TransformSpace = TS_LOCAL);
  7266. void RotateAround2D(const Vector2&, float, TransformSpace = TS_LOCAL);
  7267. bool Save(File) const;
  7268. bool Save(VectorBuffer&) const;
  7269. bool SaveXML(File);
  7270. bool SaveXML(VectorBuffer&);
  7271. bool SaveXML(XMLElement&) const;
  7272. void Scale(const Vector3&);
  7273. void Scale(float);
  7274. void Scale2D(const Vector2&);
  7275. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7276. bool SetAttribute(const String&, const Variant&);
  7277. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7278. void SetAttributeAnimationSpeed(const String&, float);
  7279. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7280. void SetPosition2D(float, float);
  7281. void SetScale(float);
  7282. void SetScale2D(float, float);
  7283. void SetTransform(const Vector3&, const Quaternion&);
  7284. void SetTransform(const Vector3&, const Quaternion&, const Vector3&);
  7285. void SetTransform(const Vector3&, const Quaternion&, float);
  7286. void SetTransform2D(const Vector2&, float);
  7287. void SetTransform2D(const Vector2&, float, const Vector2&);
  7288. void SetTransform2D(const Vector2&, float, float);
  7289. void SetWorldTransform(const Vector3&, const Quaternion&);
  7290. void SetWorldTransform(const Vector3&, const Quaternion&, const Vector3&);
  7291. void SetWorldTransform(const Vector3&, const Quaternion&, float);
  7292. void SetWorldTransform2D(const Vector2&, float);
  7293. void SetWorldTransform2D(const Vector2&, float, const Vector2&);
  7294. void SetWorldTransform2D(const Vector2&, float, float);
  7295. void StopAsyncLoading();
  7296. const String& GetVarName(StringHash) const;
  7297. void Translate(const Vector3&, TransformSpace = TS_LOCAL);
  7298. void Translate2D(const Vector2&, TransformSpace = TS_LOCAL);
  7299. void UnregisterAllVars(const String&);
  7300. void UnregisterVar(const String&);
  7301. void Update(float);
  7302. Vector3 WorldToLocal(const Vector3&) const;
  7303. Vector3 WorldToLocal(const Vector4&) const;
  7304. Vector2 WorldToLocal2D(const Vector2&) const;
  7305. void Yaw(float, TransformSpace = TS_LOCAL);
  7306. // Properties:
  7307. bool animationEnabled;
  7308. /* readonly */
  7309. LoadMode asyncLoadMode;
  7310. /* readonly */
  7311. bool asyncLoading;
  7312. int asyncLoadingMs;
  7313. /* readonly */
  7314. float asyncProgress;
  7315. /* readonly */
  7316. Array<Variant> attributeDefaults;
  7317. /* readonly */
  7318. Array<AttributeInfo> attributeInfos;
  7319. Array<Variant> attributes;
  7320. /* readonly */
  7321. StringHash baseType;
  7322. /* readonly */
  7323. String category;
  7324. /* readonly */
  7325. uint checksum;
  7326. /* readonly */
  7327. Array<Node> children;
  7328. /* readonly */
  7329. Array<Component> components;
  7330. /* readonly */
  7331. DebugRenderer debugRenderer;
  7332. Vector3 direction;
  7333. float elapsedTime;
  7334. /* readonly */
  7335. String fileName;
  7336. /* readonly */
  7337. uint id;
  7338. String name;
  7339. /* readonly */
  7340. uint numAllChildren;
  7341. /* readonly */
  7342. uint numAttributes;
  7343. /* readonly */
  7344. uint numChildren;
  7345. /* readonly */
  7346. uint numComponents;
  7347. ObjectAnimation objectAnimation;
  7348. /* readonly */
  7349. Octree octree;
  7350. Node parent;
  7351. /* readonly */
  7352. PhysicsWorld physicsWorld;
  7353. /* readonly */
  7354. PhysicsWorld2D physicsWorld2D;
  7355. Vector3 position;
  7356. Vector2 position2D;
  7357. /* readonly */
  7358. int refs;
  7359. /* readonly */
  7360. Array<PackageFile> requiredPackageFiles;
  7361. /* readonly */
  7362. Vector3 right;
  7363. Quaternion rotation;
  7364. float rotation2D;
  7365. Vector3 scale;
  7366. Vector2 scale2D;
  7367. /* readonly */
  7368. ScriptObject scriptObject;
  7369. float smoothingConstant;
  7370. float snapThreshold;
  7371. bool temporary;
  7372. float timeScale;
  7373. /* readonly */
  7374. Matrix3x4 transform;
  7375. /* readonly */
  7376. StringHash type;
  7377. /* readonly */
  7378. String typeName;
  7379. /* readonly */
  7380. Vector3 up;
  7381. bool updateEnabled;
  7382. /* readonly */
  7383. VariantMap vars;
  7384. /* readonly */
  7385. int weakRefs;
  7386. Vector3 worldDirection;
  7387. Vector3 worldPosition;
  7388. Vector2 worldPosition2D;
  7389. /* readonly */
  7390. Vector3 worldRight;
  7391. Quaternion worldRotation;
  7392. float worldRotation2D;
  7393. Vector3 worldScale;
  7394. Vector2 worldScale2D;
  7395. /* readonly */
  7396. Matrix3x4 worldTransform;
  7397. /* readonly */
  7398. Vector3 worldUp;
  7399. };
  7400. class Script
  7401. {
  7402. // Methods:
  7403. void DumpAPI(DumpMode = DOXYGEN, const String& = String ( ));
  7404. bool Execute(const String&);
  7405. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7406. // Properties:
  7407. /* readonly */
  7408. StringHash baseType;
  7409. /* readonly */
  7410. String category;
  7411. Scene defaultScene;
  7412. ScriptFile defaultScriptFile;
  7413. bool executeConsoleCommands;
  7414. /* readonly */
  7415. int refs;
  7416. /* readonly */
  7417. StringHash type;
  7418. /* readonly */
  7419. String typeName;
  7420. /* readonly */
  7421. int weakRefs;
  7422. };
  7423. class ScriptFile
  7424. {
  7425. // Methods:
  7426. void ClearDelayedExecute(const String& = String ( ));
  7427. void DelayedExecute(float, bool, const String&, const Array<Variant> = null);
  7428. bool Execute(const String&, const Array<Variant> = null);
  7429. bool Load(File);
  7430. bool Load(VectorBuffer&);
  7431. bool Save(File) const;
  7432. bool Save(VectorBuffer&) const;
  7433. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7434. // Properties:
  7435. /* readonly */
  7436. StringHash baseType;
  7437. /* readonly */
  7438. String category;
  7439. /* readonly */
  7440. bool compiled;
  7441. /* readonly */
  7442. uint memoryUse;
  7443. String name;
  7444. /* readonly */
  7445. int refs;
  7446. /* readonly */
  7447. StringHash type;
  7448. /* readonly */
  7449. String typeName;
  7450. /* readonly */
  7451. uint useTimer;
  7452. /* readonly */
  7453. int weakRefs;
  7454. };
  7455. class ScriptInstance
  7456. {
  7457. // Methods:
  7458. void ApplyAttributes();
  7459. void ClearDelayedExecute(const String& = String ( ));
  7460. bool CreateObject(ScriptFile, const String&);
  7461. void DelayedExecute(float, bool, const String&, const Array<Variant> = null);
  7462. void DrawDebugGeometry(DebugRenderer, bool);
  7463. bool Execute(const String&, const Array<Variant> = null);
  7464. Variant GetAttribute(const String&) const;
  7465. ValueAnimation GetAttributeAnimation(const String&) const;
  7466. float GetAttributeAnimationSpeed(const String&) const;
  7467. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7468. Variant GetAttributeDefault(const String&) const;
  7469. bool Load(File, bool = false);
  7470. bool Load(VectorBuffer&, bool = false);
  7471. bool LoadXML(const XMLElement&, bool = false);
  7472. void MarkNetworkUpdate() const;
  7473. void Remove();
  7474. void RemoveInstanceDefault();
  7475. void ResetToDefault();
  7476. bool Save(File) const;
  7477. bool Save(VectorBuffer&) const;
  7478. bool SaveXML(XMLElement&) const;
  7479. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7480. bool SetAttribute(const String&, const Variant&);
  7481. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7482. void SetAttributeAnimationSpeed(const String&, float);
  7483. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7484. // Properties:
  7485. bool animationEnabled;
  7486. /* readonly */
  7487. Array<Variant> attributeDefaults;
  7488. /* readonly */
  7489. Array<AttributeInfo> attributeInfos;
  7490. Array<Variant> attributes;
  7491. /* readonly */
  7492. StringHash baseType;
  7493. /* readonly */
  7494. String category;
  7495. String className;
  7496. bool enabled;
  7497. /* readonly */
  7498. bool enabledEffective;
  7499. /* readonly */
  7500. uint id;
  7501. /* readonly */
  7502. Node node;
  7503. /* readonly */
  7504. uint numAttributes;
  7505. ObjectAnimation objectAnimation;
  7506. /* readonly */
  7507. int refs;
  7508. ScriptFile scriptFile;
  7509. /* readonly */
  7510. ScriptObject scriptObject;
  7511. bool temporary;
  7512. /* readonly */
  7513. StringHash type;
  7514. /* readonly */
  7515. String typeName;
  7516. /* readonly */
  7517. int weakRefs;
  7518. };
  7519. class ScriptObject
  7520. {
  7521. };
  7522. class ScrollBar
  7523. {
  7524. // Methods:
  7525. void AddChild(UIElement);
  7526. void ApplyAttributes();
  7527. void BringToFront();
  7528. void ChangeValue(float);
  7529. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  7530. void DisableLayoutUpdate();
  7531. IntVector2 ElementToScreen(const IntVector2&);
  7532. void EnableLayoutUpdate();
  7533. uint FindChild(UIElement) const;
  7534. Variant GetAttribute(const String&) const;
  7535. ValueAnimation GetAttributeAnimation(const String&) const;
  7536. float GetAttributeAnimationSpeed(const String&) const;
  7537. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7538. Variant GetAttributeDefault(const String&) const;
  7539. UIElement GetChild(const String&, bool = false) const;
  7540. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  7541. Array<UIElement> GetChildren(bool = false) const;
  7542. UIElement GetElementEventSender() const;
  7543. uint GetNumChildren(bool) const;
  7544. void InsertChild(uint, UIElement);
  7545. bool IsInside(IntVector2, bool);
  7546. bool IsInsideCombined(IntVector2, bool);
  7547. bool Load(File, bool = false);
  7548. bool Load(VectorBuffer&, bool = false);
  7549. bool LoadChildXML(XMLFile, XMLFile = null);
  7550. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  7551. bool LoadXML(File);
  7552. bool LoadXML(VectorBuffer&);
  7553. bool LoadXML(XMLFile, XMLFile);
  7554. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  7555. bool LoadXML(const XMLElement&, bool = false);
  7556. void MarkNetworkUpdate() const;
  7557. void Remove();
  7558. void RemoveAllChildren();
  7559. void RemoveChild(UIElement, uint = 0);
  7560. void RemoveChild(uint);
  7561. void RemoveInstanceDefault();
  7562. void ResetDeepEnabled();
  7563. void ResetToDefault();
  7564. bool Save(File) const;
  7565. bool Save(VectorBuffer&) const;
  7566. bool SaveXML(File);
  7567. bool SaveXML(VectorBuffer&);
  7568. bool SaveXML(XMLElement&) const;
  7569. IntVector2 ScreenToElement(const IntVector2&);
  7570. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7571. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  7572. bool SetAttribute(const String&, const Variant&);
  7573. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7574. void SetAttributeAnimationSpeed(const String&, float);
  7575. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7576. void SetDeepEnabled(bool);
  7577. void SetEnabledRecursive(bool);
  7578. void SetFixedHeight(int);
  7579. void SetFixedSize(int, int);
  7580. void SetFixedWidth(int);
  7581. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  7582. void SetMaxSize(int, int);
  7583. void SetMinSize(int, int);
  7584. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  7585. void SetPosition(int, int);
  7586. void SetSize(int, int);
  7587. bool SetStyle(const String&, XMLFile = null);
  7588. bool SetStyle(const XMLElement&);
  7589. bool SetStyleAuto(XMLFile = null);
  7590. void StepBack();
  7591. void StepForward();
  7592. void UpdateLayout();
  7593. const Variant& GetVar(const StringHash&);
  7594. // Properties:
  7595. bool animationEnabled;
  7596. /* readonly */
  7597. Array<Variant> attributeDefaults;
  7598. /* readonly */
  7599. Array<AttributeInfo> attributeInfos;
  7600. Array<Variant> attributes;
  7601. /* readonly */
  7602. Button backButton;
  7603. /* readonly */
  7604. StringHash baseType;
  7605. bool bringToBack;
  7606. bool bringToFront;
  7607. /* readonly */
  7608. String category;
  7609. /* readonly */
  7610. IntVector2 childOffset;
  7611. /* readonly */
  7612. Array<UIElement> children;
  7613. IntRect clipBorder;
  7614. bool clipChildren;
  7615. /* writeonly */
  7616. Color color;
  7617. /* readonly */
  7618. bool colorGradient;
  7619. Array<Color> colors;
  7620. /* readonly */
  7621. IntRect combinedScreenRect;
  7622. XMLFile defaultStyle;
  7623. /* readonly */
  7624. float derivedOpacity;
  7625. /* readonly */
  7626. uint dragButtonCombo;
  7627. /* readonly */
  7628. int dragButtonCount;
  7629. uint dragDropMode;
  7630. bool editable;
  7631. /* readonly */
  7632. float effectiveScrollStep;
  7633. bool elementEventSender;
  7634. bool enabled;
  7635. /* readonly */
  7636. bool enabledSelf;
  7637. /* readonly */
  7638. bool fixedHeight;
  7639. /* readonly */
  7640. bool fixedSize;
  7641. /* readonly */
  7642. bool fixedWidth;
  7643. bool focus;
  7644. FocusMode focusMode;
  7645. /* readonly */
  7646. Button forwardButton;
  7647. int height;
  7648. HorizontalAlignment horizontalAlignment;
  7649. /* readonly */
  7650. bool hovering;
  7651. int indent;
  7652. int indentSpacing;
  7653. /* readonly */
  7654. int indentWidth;
  7655. bool internal;
  7656. IntRect layoutBorder;
  7657. Vector2 layoutFlexScale;
  7658. LayoutMode layoutMode;
  7659. int layoutSpacing;
  7660. int maxHeight;
  7661. IntVector2 maxSize;
  7662. int maxWidth;
  7663. int minHeight;
  7664. IntVector2 minSize;
  7665. int minWidth;
  7666. String name;
  7667. /* readonly */
  7668. uint numAllChildren;
  7669. /* readonly */
  7670. uint numAttributes;
  7671. /* readonly */
  7672. uint numChildren;
  7673. ObjectAnimation objectAnimation;
  7674. float opacity;
  7675. Orientation orientation;
  7676. UIElement parent;
  7677. IntVector2 position;
  7678. int priority;
  7679. float range;
  7680. /* readonly */
  7681. int refs;
  7682. /* readonly */
  7683. UIElement root;
  7684. /* readonly */
  7685. IntVector2 screenPosition;
  7686. float scrollStep;
  7687. bool selected;
  7688. IntVector2 size;
  7689. /* readonly */
  7690. Slider slider;
  7691. bool sortChildren;
  7692. float stepFactor;
  7693. String style;
  7694. bool temporary;
  7695. TraversalMode traversalMode;
  7696. /* readonly */
  7697. StringHash type;
  7698. /* readonly */
  7699. String typeName;
  7700. bool useDerivedOpacity;
  7701. float value;
  7702. /* readonly */
  7703. VariantMap vars;
  7704. VerticalAlignment verticalAlignment;
  7705. bool visible;
  7706. /* readonly */
  7707. int weakRefs;
  7708. int width;
  7709. };
  7710. class ScrollView
  7711. {
  7712. // Methods:
  7713. void AddChild(UIElement);
  7714. void ApplyAttributes();
  7715. void BringToFront();
  7716. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  7717. void DisableLayoutUpdate();
  7718. IntVector2 ElementToScreen(const IntVector2&);
  7719. void EnableLayoutUpdate();
  7720. uint FindChild(UIElement) const;
  7721. Variant GetAttribute(const String&) const;
  7722. ValueAnimation GetAttributeAnimation(const String&) const;
  7723. float GetAttributeAnimationSpeed(const String&) const;
  7724. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7725. Variant GetAttributeDefault(const String&) const;
  7726. UIElement GetChild(const String&, bool = false) const;
  7727. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  7728. Array<UIElement> GetChildren(bool = false) const;
  7729. UIElement GetElementEventSender() const;
  7730. uint GetNumChildren(bool) const;
  7731. void InsertChild(uint, UIElement);
  7732. bool IsInside(IntVector2, bool);
  7733. bool IsInsideCombined(IntVector2, bool);
  7734. bool Load(File, bool = false);
  7735. bool Load(VectorBuffer&, bool = false);
  7736. bool LoadChildXML(XMLFile, XMLFile = null);
  7737. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  7738. bool LoadXML(File);
  7739. bool LoadXML(VectorBuffer&);
  7740. bool LoadXML(XMLFile, XMLFile);
  7741. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  7742. bool LoadXML(const XMLElement&, bool = false);
  7743. void MarkNetworkUpdate() const;
  7744. void Remove();
  7745. void RemoveAllChildren();
  7746. void RemoveChild(UIElement, uint = 0);
  7747. void RemoveChild(uint);
  7748. void RemoveInstanceDefault();
  7749. void ResetDeepEnabled();
  7750. void ResetToDefault();
  7751. bool Save(File) const;
  7752. bool Save(VectorBuffer&) const;
  7753. bool SaveXML(File);
  7754. bool SaveXML(VectorBuffer&);
  7755. bool SaveXML(XMLElement&) const;
  7756. IntVector2 ScreenToElement(const IntVector2&);
  7757. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7758. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  7759. bool SetAttribute(const String&, const Variant&);
  7760. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  7761. void SetAttributeAnimationSpeed(const String&, float);
  7762. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  7763. void SetDeepEnabled(bool);
  7764. void SetEnabledRecursive(bool);
  7765. void SetFixedHeight(int);
  7766. void SetFixedSize(int, int);
  7767. void SetFixedWidth(int);
  7768. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  7769. void SetMaxSize(int, int);
  7770. void SetMinSize(int, int);
  7771. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  7772. void SetPosition(int, int);
  7773. void SetScrollBarsVisible(bool, bool);
  7774. void SetSize(int, int);
  7775. bool SetStyle(const String&, XMLFile = null);
  7776. bool SetStyle(const XMLElement&);
  7777. bool SetStyleAuto(XMLFile = null);
  7778. void SetViewPosition(int, int);
  7779. void UpdateLayout();
  7780. const Variant& GetVar(const StringHash&);
  7781. // Properties:
  7782. bool animationEnabled;
  7783. /* readonly */
  7784. Array<Variant> attributeDefaults;
  7785. /* readonly */
  7786. Array<AttributeInfo> attributeInfos;
  7787. Array<Variant> attributes;
  7788. bool autoDisableChildren;
  7789. float autoDisableThreshold;
  7790. /* readonly */
  7791. StringHash baseType;
  7792. bool bringToBack;
  7793. bool bringToFront;
  7794. /* readonly */
  7795. String category;
  7796. /* readonly */
  7797. IntVector2 childOffset;
  7798. /* readonly */
  7799. Array<UIElement> children;
  7800. IntRect clipBorder;
  7801. bool clipChildren;
  7802. /* writeonly */
  7803. Color color;
  7804. /* readonly */
  7805. bool colorGradient;
  7806. Array<Color> colors;
  7807. /* readonly */
  7808. IntRect combinedScreenRect;
  7809. UIElement contentElement;
  7810. XMLFile defaultStyle;
  7811. /* readonly */
  7812. float derivedOpacity;
  7813. /* readonly */
  7814. uint dragButtonCombo;
  7815. /* readonly */
  7816. int dragButtonCount;
  7817. uint dragDropMode;
  7818. bool editable;
  7819. bool elementEventSender;
  7820. bool enabled;
  7821. /* readonly */
  7822. bool enabledSelf;
  7823. /* readonly */
  7824. bool fixedHeight;
  7825. /* readonly */
  7826. bool fixedSize;
  7827. /* readonly */
  7828. bool fixedWidth;
  7829. bool focus;
  7830. FocusMode focusMode;
  7831. int height;
  7832. HorizontalAlignment horizontalAlignment;
  7833. /* readonly */
  7834. ScrollBar horizontalScrollBar;
  7835. /* readonly */
  7836. bool hovering;
  7837. int indent;
  7838. int indentSpacing;
  7839. /* readonly */
  7840. int indentWidth;
  7841. bool internal;
  7842. IntRect layoutBorder;
  7843. Vector2 layoutFlexScale;
  7844. LayoutMode layoutMode;
  7845. int layoutSpacing;
  7846. int maxHeight;
  7847. IntVector2 maxSize;
  7848. int maxWidth;
  7849. int minHeight;
  7850. IntVector2 minSize;
  7851. int minWidth;
  7852. String name;
  7853. /* readonly */
  7854. uint numAllChildren;
  7855. /* readonly */
  7856. uint numAttributes;
  7857. /* readonly */
  7858. uint numChildren;
  7859. ObjectAnimation objectAnimation;
  7860. float opacity;
  7861. float pageStep;
  7862. UIElement parent;
  7863. IntVector2 position;
  7864. int priority;
  7865. /* readonly */
  7866. int refs;
  7867. /* readonly */
  7868. UIElement root;
  7869. /* readonly */
  7870. IntVector2 screenPosition;
  7871. bool scrollBarsAutoVisible;
  7872. float scrollDeceleration;
  7873. /* readonly */
  7874. BorderImage scrollPanel;
  7875. float scrollSnapEpsilon;
  7876. float scrollStep;
  7877. bool selected;
  7878. IntVector2 size;
  7879. bool sortChildren;
  7880. String style;
  7881. bool temporary;
  7882. TraversalMode traversalMode;
  7883. /* readonly */
  7884. StringHash type;
  7885. /* readonly */
  7886. String typeName;
  7887. bool useDerivedOpacity;
  7888. /* readonly */
  7889. VariantMap vars;
  7890. VerticalAlignment verticalAlignment;
  7891. /* readonly */
  7892. ScrollBar verticalScrollBar;
  7893. IntVector2 viewPosition;
  7894. bool visible;
  7895. /* readonly */
  7896. int weakRefs;
  7897. int width;
  7898. };
  7899. class Serializable
  7900. {
  7901. // Methods:
  7902. void ApplyAttributes();
  7903. Variant GetAttribute(const String&) const;
  7904. Variant GetAttributeDefault(const String&) const;
  7905. bool Load(File, bool = false);
  7906. bool Load(VectorBuffer&, bool = false);
  7907. bool LoadXML(const XMLElement&, bool = false);
  7908. void MarkNetworkUpdate() const;
  7909. void RemoveInstanceDefault();
  7910. void ResetToDefault();
  7911. bool Save(File) const;
  7912. bool Save(VectorBuffer&) const;
  7913. bool SaveXML(XMLElement&) const;
  7914. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  7915. bool SetAttribute(const String&, const Variant&);
  7916. // Properties:
  7917. /* readonly */
  7918. Array<Variant> attributeDefaults;
  7919. /* readonly */
  7920. Array<AttributeInfo> attributeInfos;
  7921. Array<Variant> attributes;
  7922. /* readonly */
  7923. StringHash baseType;
  7924. /* readonly */
  7925. String category;
  7926. /* readonly */
  7927. uint numAttributes;
  7928. /* readonly */
  7929. int refs;
  7930. bool temporary;
  7931. /* readonly */
  7932. StringHash type;
  7933. /* readonly */
  7934. String typeName;
  7935. /* readonly */
  7936. int weakRefs;
  7937. };
  7938. class Serializer
  7939. {
  7940. // Methods:
  7941. uint Write(Array<uint8>);
  7942. bool WriteBool(bool);
  7943. bool WriteBoundingBox(const BoundingBox&);
  7944. bool WriteByte(int8);
  7945. bool WriteColor(const Color&);
  7946. bool WriteFileID(const String&);
  7947. bool WriteFloat(float);
  7948. bool WriteInt(int);
  7949. bool WriteIntRect(const IntRect&);
  7950. bool WriteIntVector2(const IntVector2&);
  7951. bool WriteLine(const String&);
  7952. bool WriteMatrix3(const Matrix3&);
  7953. bool WriteMatrix3x4(const Matrix3x4&);
  7954. bool WriteMatrix4(const Matrix4&);
  7955. bool WriteNetID(uint);
  7956. bool WritePackedQuaternion(const Quaternion&);
  7957. bool WritePackedVector3(const Vector3&, float);
  7958. bool WriteQuaternion(const Quaternion&);
  7959. bool WriteShort(int16);
  7960. bool WriteString(const String&);
  7961. bool WriteStringHash(const StringHash&);
  7962. bool WriteUByte(uint8);
  7963. bool WriteUInt(uint);
  7964. bool WriteUShort(uint16);
  7965. bool WriteVLE(uint);
  7966. bool WriteVariant(const Variant&);
  7967. bool WriteVariantMap(const VariantMap&);
  7968. bool WriteVector2(const Vector2&);
  7969. bool WriteVector3(const Vector3&);
  7970. bool WriteVector4(const Vector4&);
  7971. bool WriteVectorBuffer(const VectorBuffer&);
  7972. };
  7973. class Skeleton
  7974. {
  7975. // Methods:
  7976. Bone GetBone(const String&) const;
  7977. void Reset();
  7978. // Properties:
  7979. /* readonly */
  7980. Array<Bone> bones;
  7981. /* readonly */
  7982. uint numBones;
  7983. /* readonly */
  7984. Bone rootBone;
  7985. };
  7986. class Skybox
  7987. {
  7988. // Methods:
  7989. void ApplyAttributes();
  7990. void ApplyMaterialList(const String& = String ( ));
  7991. void DrawDebugGeometry(DebugRenderer, bool);
  7992. Variant GetAttribute(const String&) const;
  7993. ValueAnimation GetAttributeAnimation(const String&) const;
  7994. float GetAttributeAnimationSpeed(const String&) const;
  7995. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  7996. Variant GetAttributeDefault(const String&) const;
  7997. bool IsInView(Camera) const;
  7998. bool Load(File, bool = false);
  7999. bool Load(VectorBuffer&, bool = false);
  8000. bool LoadXML(const XMLElement&, bool = false);
  8001. void MarkNetworkUpdate() const;
  8002. void Remove();
  8003. void RemoveInstanceDefault();
  8004. void ResetToDefault();
  8005. bool Save(File) const;
  8006. bool Save(VectorBuffer&) const;
  8007. bool SaveXML(XMLElement&) const;
  8008. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8009. bool SetAttribute(const String&, const Variant&);
  8010. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8011. void SetAttributeAnimationSpeed(const String&, float);
  8012. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8013. // Properties:
  8014. bool animationEnabled;
  8015. /* readonly */
  8016. Array<Variant> attributeDefaults;
  8017. /* readonly */
  8018. Array<AttributeInfo> attributeInfos;
  8019. Array<Variant> attributes;
  8020. /* readonly */
  8021. StringHash baseType;
  8022. /* readonly */
  8023. BoundingBox boundingBox;
  8024. bool castShadows;
  8025. /* readonly */
  8026. String category;
  8027. float drawDistance;
  8028. bool enabled;
  8029. /* readonly */
  8030. bool enabledEffective;
  8031. /* readonly */
  8032. uint id;
  8033. /* readonly */
  8034. bool inView;
  8035. uint lightMask;
  8036. float lodBias;
  8037. /* writeonly */
  8038. Material material;
  8039. Array<Material> materials;
  8040. uint maxLights;
  8041. Model model;
  8042. /* readonly */
  8043. Node node;
  8044. /* readonly */
  8045. uint numAttributes;
  8046. /* readonly */
  8047. uint numGeometries;
  8048. ObjectAnimation objectAnimation;
  8049. bool occludee;
  8050. bool occluder;
  8051. /* readonly */
  8052. int refs;
  8053. float shadowDistance;
  8054. uint shadowMask;
  8055. bool temporary;
  8056. /* readonly */
  8057. StringHash type;
  8058. /* readonly */
  8059. String typeName;
  8060. uint viewMask;
  8061. /* readonly */
  8062. int weakRefs;
  8063. /* readonly */
  8064. BoundingBox worldBoundingBox;
  8065. /* readonly */
  8066. Zone zone;
  8067. uint zoneMask;
  8068. };
  8069. class Slider
  8070. {
  8071. // Methods:
  8072. void AddChild(UIElement);
  8073. void ApplyAttributes();
  8074. void BringToFront();
  8075. void ChangeValue(float);
  8076. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  8077. void DisableLayoutUpdate();
  8078. IntVector2 ElementToScreen(const IntVector2&);
  8079. void EnableLayoutUpdate();
  8080. uint FindChild(UIElement) const;
  8081. Variant GetAttribute(const String&) const;
  8082. ValueAnimation GetAttributeAnimation(const String&) const;
  8083. float GetAttributeAnimationSpeed(const String&) const;
  8084. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8085. Variant GetAttributeDefault(const String&) const;
  8086. UIElement GetChild(const String&, bool = false) const;
  8087. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  8088. Array<UIElement> GetChildren(bool = false) const;
  8089. UIElement GetElementEventSender() const;
  8090. uint GetNumChildren(bool) const;
  8091. void InsertChild(uint, UIElement);
  8092. bool IsInside(IntVector2, bool);
  8093. bool IsInsideCombined(IntVector2, bool);
  8094. bool Load(File, bool = false);
  8095. bool Load(VectorBuffer&, bool = false);
  8096. bool LoadChildXML(XMLFile, XMLFile = null);
  8097. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  8098. bool LoadXML(File);
  8099. bool LoadXML(VectorBuffer&);
  8100. bool LoadXML(XMLFile, XMLFile);
  8101. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  8102. bool LoadXML(const XMLElement&, bool = false);
  8103. void MarkNetworkUpdate() const;
  8104. void Remove();
  8105. void RemoveAllChildren();
  8106. void RemoveChild(UIElement, uint = 0);
  8107. void RemoveChild(uint);
  8108. void RemoveInstanceDefault();
  8109. void ResetDeepEnabled();
  8110. void ResetToDefault();
  8111. bool Save(File) const;
  8112. bool Save(VectorBuffer&) const;
  8113. bool SaveXML(File);
  8114. bool SaveXML(VectorBuffer&);
  8115. bool SaveXML(XMLElement&) const;
  8116. IntVector2 ScreenToElement(const IntVector2&);
  8117. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8118. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  8119. bool SetAttribute(const String&, const Variant&);
  8120. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8121. void SetAttributeAnimationSpeed(const String&, float);
  8122. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8123. void SetDeepEnabled(bool);
  8124. void SetEnabledRecursive(bool);
  8125. void SetFixedHeight(int);
  8126. void SetFixedSize(int, int);
  8127. void SetFixedWidth(int);
  8128. void SetFullImageRect();
  8129. void SetHoverOffset(int, int);
  8130. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  8131. void SetMaxSize(int, int);
  8132. void SetMinSize(int, int);
  8133. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  8134. void SetPosition(int, int);
  8135. void SetSize(int, int);
  8136. bool SetStyle(const String&, XMLFile = null);
  8137. bool SetStyle(const XMLElement&);
  8138. bool SetStyleAuto(XMLFile = null);
  8139. void UpdateLayout();
  8140. const Variant& GetVar(const StringHash&);
  8141. // Properties:
  8142. bool animationEnabled;
  8143. /* readonly */
  8144. Array<Variant> attributeDefaults;
  8145. /* readonly */
  8146. Array<AttributeInfo> attributeInfos;
  8147. Array<Variant> attributes;
  8148. /* readonly */
  8149. StringHash baseType;
  8150. BlendMode blendMode;
  8151. IntRect border;
  8152. bool bringToBack;
  8153. bool bringToFront;
  8154. /* readonly */
  8155. String category;
  8156. /* readonly */
  8157. IntVector2 childOffset;
  8158. /* readonly */
  8159. Array<UIElement> children;
  8160. IntRect clipBorder;
  8161. bool clipChildren;
  8162. /* writeonly */
  8163. Color color;
  8164. /* readonly */
  8165. bool colorGradient;
  8166. Array<Color> colors;
  8167. /* readonly */
  8168. IntRect combinedScreenRect;
  8169. XMLFile defaultStyle;
  8170. /* readonly */
  8171. float derivedOpacity;
  8172. /* readonly */
  8173. uint dragButtonCombo;
  8174. /* readonly */
  8175. int dragButtonCount;
  8176. uint dragDropMode;
  8177. bool editable;
  8178. bool elementEventSender;
  8179. bool enabled;
  8180. /* readonly */
  8181. bool enabledSelf;
  8182. /* readonly */
  8183. bool fixedHeight;
  8184. /* readonly */
  8185. bool fixedSize;
  8186. /* readonly */
  8187. bool fixedWidth;
  8188. bool focus;
  8189. FocusMode focusMode;
  8190. int height;
  8191. HorizontalAlignment horizontalAlignment;
  8192. IntVector2 hoverOffset;
  8193. /* readonly */
  8194. bool hovering;
  8195. IntRect imageBorder;
  8196. IntRect imageRect;
  8197. int indent;
  8198. int indentSpacing;
  8199. /* readonly */
  8200. int indentWidth;
  8201. bool internal;
  8202. /* readonly */
  8203. BorderImage knob;
  8204. IntRect layoutBorder;
  8205. Vector2 layoutFlexScale;
  8206. LayoutMode layoutMode;
  8207. int layoutSpacing;
  8208. int maxHeight;
  8209. IntVector2 maxSize;
  8210. int maxWidth;
  8211. int minHeight;
  8212. IntVector2 minSize;
  8213. int minWidth;
  8214. String name;
  8215. /* readonly */
  8216. uint numAllChildren;
  8217. /* readonly */
  8218. uint numAttributes;
  8219. /* readonly */
  8220. uint numChildren;
  8221. ObjectAnimation objectAnimation;
  8222. float opacity;
  8223. Orientation orientation;
  8224. UIElement parent;
  8225. IntVector2 position;
  8226. int priority;
  8227. float range;
  8228. /* readonly */
  8229. int refs;
  8230. float repeatRate;
  8231. /* readonly */
  8232. UIElement root;
  8233. /* readonly */
  8234. IntVector2 screenPosition;
  8235. bool selected;
  8236. IntVector2 size;
  8237. bool sortChildren;
  8238. String style;
  8239. bool temporary;
  8240. Texture texture;
  8241. bool tiled;
  8242. TraversalMode traversalMode;
  8243. /* readonly */
  8244. StringHash type;
  8245. /* readonly */
  8246. String typeName;
  8247. bool useDerivedOpacity;
  8248. float value;
  8249. /* readonly */
  8250. VariantMap vars;
  8251. VerticalAlignment verticalAlignment;
  8252. bool visible;
  8253. /* readonly */
  8254. int weakRefs;
  8255. int width;
  8256. };
  8257. class SmoothedTransform
  8258. {
  8259. // Methods:
  8260. void ApplyAttributes();
  8261. void DrawDebugGeometry(DebugRenderer, bool);
  8262. Variant GetAttribute(const String&) const;
  8263. ValueAnimation GetAttributeAnimation(const String&) const;
  8264. float GetAttributeAnimationSpeed(const String&) const;
  8265. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8266. Variant GetAttributeDefault(const String&) const;
  8267. bool Load(File, bool = false);
  8268. bool Load(VectorBuffer&, bool = false);
  8269. bool LoadXML(const XMLElement&, bool = false);
  8270. void MarkNetworkUpdate() const;
  8271. void Remove();
  8272. void RemoveInstanceDefault();
  8273. void ResetToDefault();
  8274. bool Save(File) const;
  8275. bool Save(VectorBuffer&) const;
  8276. bool SaveXML(XMLElement&) const;
  8277. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8278. bool SetAttribute(const String&, const Variant&);
  8279. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8280. void SetAttributeAnimationSpeed(const String&, float);
  8281. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8282. void Update(float, float);
  8283. // Properties:
  8284. bool animationEnabled;
  8285. /* readonly */
  8286. Array<Variant> attributeDefaults;
  8287. /* readonly */
  8288. Array<AttributeInfo> attributeInfos;
  8289. Array<Variant> attributes;
  8290. /* readonly */
  8291. StringHash baseType;
  8292. /* readonly */
  8293. String category;
  8294. bool enabled;
  8295. /* readonly */
  8296. bool enabledEffective;
  8297. /* readonly */
  8298. uint id;
  8299. /* readonly */
  8300. bool inProgress;
  8301. /* readonly */
  8302. Node node;
  8303. /* readonly */
  8304. uint numAttributes;
  8305. ObjectAnimation objectAnimation;
  8306. /* readonly */
  8307. int refs;
  8308. Vector3 targetPosition;
  8309. Quaternion targetRotation;
  8310. Vector3 targetWorldPosition;
  8311. Quaternion targetWorldRotation;
  8312. bool temporary;
  8313. /* readonly */
  8314. StringHash type;
  8315. /* readonly */
  8316. String typeName;
  8317. /* readonly */
  8318. int weakRefs;
  8319. };
  8320. class Sound
  8321. {
  8322. // Methods:
  8323. bool Load(File);
  8324. bool Load(VectorBuffer&);
  8325. bool Save(File) const;
  8326. bool Save(VectorBuffer&) const;
  8327. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8328. // Properties:
  8329. /* readonly */
  8330. StringHash baseType;
  8331. /* readonly */
  8332. String category;
  8333. /* readonly */
  8334. bool compressed;
  8335. /* readonly */
  8336. float frequency;
  8337. /* readonly */
  8338. float length;
  8339. bool looped;
  8340. /* readonly */
  8341. uint memoryUse;
  8342. String name;
  8343. /* readonly */
  8344. int refs;
  8345. /* readonly */
  8346. uint sampleSize;
  8347. /* readonly */
  8348. bool sixteenBit;
  8349. /* readonly */
  8350. bool stereo;
  8351. /* readonly */
  8352. StringHash type;
  8353. /* readonly */
  8354. String typeName;
  8355. /* readonly */
  8356. uint useTimer;
  8357. /* readonly */
  8358. int weakRefs;
  8359. };
  8360. class SoundListener
  8361. {
  8362. // Methods:
  8363. void ApplyAttributes();
  8364. void DrawDebugGeometry(DebugRenderer, bool);
  8365. Variant GetAttribute(const String&) const;
  8366. ValueAnimation GetAttributeAnimation(const String&) const;
  8367. float GetAttributeAnimationSpeed(const String&) const;
  8368. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8369. Variant GetAttributeDefault(const String&) const;
  8370. bool Load(File, bool = false);
  8371. bool Load(VectorBuffer&, bool = false);
  8372. bool LoadXML(const XMLElement&, bool = false);
  8373. void MarkNetworkUpdate() const;
  8374. void Remove();
  8375. void RemoveInstanceDefault();
  8376. void ResetToDefault();
  8377. bool Save(File) const;
  8378. bool Save(VectorBuffer&) const;
  8379. bool SaveXML(XMLElement&) const;
  8380. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8381. bool SetAttribute(const String&, const Variant&);
  8382. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8383. void SetAttributeAnimationSpeed(const String&, float);
  8384. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8385. // Properties:
  8386. bool animationEnabled;
  8387. /* readonly */
  8388. Array<Variant> attributeDefaults;
  8389. /* readonly */
  8390. Array<AttributeInfo> attributeInfos;
  8391. Array<Variant> attributes;
  8392. /* readonly */
  8393. StringHash baseType;
  8394. /* readonly */
  8395. String category;
  8396. bool enabled;
  8397. /* readonly */
  8398. bool enabledEffective;
  8399. /* readonly */
  8400. uint id;
  8401. /* readonly */
  8402. Node node;
  8403. /* readonly */
  8404. uint numAttributes;
  8405. ObjectAnimation objectAnimation;
  8406. /* readonly */
  8407. int refs;
  8408. bool temporary;
  8409. /* readonly */
  8410. StringHash type;
  8411. /* readonly */
  8412. String typeName;
  8413. /* readonly */
  8414. int weakRefs;
  8415. };
  8416. class SoundSource
  8417. {
  8418. // Methods:
  8419. void ApplyAttributes();
  8420. void DrawDebugGeometry(DebugRenderer, bool);
  8421. Variant GetAttribute(const String&) const;
  8422. ValueAnimation GetAttributeAnimation(const String&) const;
  8423. float GetAttributeAnimationSpeed(const String&) const;
  8424. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8425. Variant GetAttributeDefault(const String&) const;
  8426. bool Load(File, bool = false);
  8427. bool Load(VectorBuffer&, bool = false);
  8428. bool LoadXML(const XMLElement&, bool = false);
  8429. void MarkNetworkUpdate() const;
  8430. void Play(Sound);
  8431. void Play(Sound, float);
  8432. void Play(Sound, float, float);
  8433. void Play(Sound, float, float, float);
  8434. void Remove();
  8435. void RemoveInstanceDefault();
  8436. void ResetToDefault();
  8437. bool Save(File) const;
  8438. bool Save(VectorBuffer&) const;
  8439. bool SaveXML(XMLElement&) const;
  8440. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8441. bool SetAttribute(const String&, const Variant&);
  8442. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8443. void SetAttributeAnimationSpeed(const String&, float);
  8444. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8445. void Stop();
  8446. // Properties:
  8447. bool animationEnabled;
  8448. /* readonly */
  8449. float attenuation;
  8450. /* readonly */
  8451. Array<Variant> attributeDefaults;
  8452. /* readonly */
  8453. Array<AttributeInfo> attributeInfos;
  8454. Array<Variant> attributes;
  8455. bool autoRemove;
  8456. /* readonly */
  8457. StringHash baseType;
  8458. /* readonly */
  8459. String category;
  8460. bool enabled;
  8461. /* readonly */
  8462. bool enabledEffective;
  8463. float frequency;
  8464. float gain;
  8465. /* readonly */
  8466. uint id;
  8467. /* readonly */
  8468. Node node;
  8469. /* readonly */
  8470. uint numAttributes;
  8471. ObjectAnimation objectAnimation;
  8472. float panning;
  8473. /* readonly */
  8474. bool playing;
  8475. /* readonly */
  8476. int refs;
  8477. /* readonly */
  8478. Sound sound;
  8479. String soundType;
  8480. bool temporary;
  8481. /* readonly */
  8482. float timePosition;
  8483. /* readonly */
  8484. StringHash type;
  8485. /* readonly */
  8486. String typeName;
  8487. /* readonly */
  8488. int weakRefs;
  8489. };
  8490. class SoundSource3D
  8491. {
  8492. // Methods:
  8493. void ApplyAttributes();
  8494. void DrawDebugGeometry(DebugRenderer, bool);
  8495. Variant GetAttribute(const String&) const;
  8496. ValueAnimation GetAttributeAnimation(const String&) const;
  8497. float GetAttributeAnimationSpeed(const String&) const;
  8498. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8499. Variant GetAttributeDefault(const String&) const;
  8500. bool Load(File, bool = false);
  8501. bool Load(VectorBuffer&, bool = false);
  8502. bool LoadXML(const XMLElement&, bool = false);
  8503. void MarkNetworkUpdate() const;
  8504. void Play(Sound);
  8505. void Play(Sound, float);
  8506. void Play(Sound, float, float);
  8507. void Play(Sound, float, float, float);
  8508. void Remove();
  8509. void RemoveInstanceDefault();
  8510. void ResetToDefault();
  8511. bool Save(File) const;
  8512. bool Save(VectorBuffer&) const;
  8513. bool SaveXML(XMLElement&) const;
  8514. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8515. void SetAngleAttenuation(float, float);
  8516. bool SetAttribute(const String&, const Variant&);
  8517. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8518. void SetAttributeAnimationSpeed(const String&, float);
  8519. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8520. void SetDistanceAttenuation(float, float, float);
  8521. void Stop();
  8522. // Properties:
  8523. bool animationEnabled;
  8524. /* readonly */
  8525. float attenuation;
  8526. /* readonly */
  8527. Array<Variant> attributeDefaults;
  8528. /* readonly */
  8529. Array<AttributeInfo> attributeInfos;
  8530. Array<Variant> attributes;
  8531. bool autoRemove;
  8532. /* readonly */
  8533. StringHash baseType;
  8534. /* readonly */
  8535. String category;
  8536. bool enabled;
  8537. /* readonly */
  8538. bool enabledEffective;
  8539. float farDistance;
  8540. float frequency;
  8541. float gain;
  8542. /* readonly */
  8543. uint id;
  8544. float innerAngle;
  8545. float nearDistance;
  8546. /* readonly */
  8547. Node node;
  8548. /* readonly */
  8549. uint numAttributes;
  8550. ObjectAnimation objectAnimation;
  8551. float outerAngle;
  8552. float panning;
  8553. /* readonly */
  8554. bool playing;
  8555. /* readonly */
  8556. int refs;
  8557. float rolloffFactor;
  8558. /* readonly */
  8559. Sound sound;
  8560. String soundType;
  8561. bool temporary;
  8562. /* readonly */
  8563. float timePosition;
  8564. /* readonly */
  8565. StringHash type;
  8566. /* readonly */
  8567. String typeName;
  8568. /* readonly */
  8569. int weakRefs;
  8570. };
  8571. class Sphere
  8572. {
  8573. // Methods:
  8574. void Clear();
  8575. void Define(const BoundingBox&);
  8576. void Define(const Frustum&);
  8577. void Define(const Polyhedron&);
  8578. void Define(const Sphere&);
  8579. void Define(const Vector3&, float);
  8580. float Distance(const Vector3&) const;
  8581. Intersection IsInside(const BoundingBox&) const;
  8582. Intersection IsInside(const Sphere&) const;
  8583. Intersection IsInside(const Vector3&) const;
  8584. void Merge(const BoundingBox&);
  8585. void Merge(const Frustum&);
  8586. void Merge(const Sphere&);
  8587. void Merge(const Vector3&);
  8588. // Properties:
  8589. Vector3 center;
  8590. bool defined;
  8591. float radius;
  8592. };
  8593. class Spline
  8594. {
  8595. // Methods:
  8596. void AddKnot(const Variant&);
  8597. void AddKnot(const Variant&, uint);
  8598. void Clear();
  8599. Variant GetPoint(float);
  8600. void RemoveKnot();
  8601. void RemoveKnot(uint);
  8602. // Properties:
  8603. InterpolationMode interpolationMode;
  8604. Array<Variant> knot;
  8605. Array<Variant> knots;
  8606. };
  8607. class SplinePath
  8608. {
  8609. // Methods:
  8610. void AddControlPoint(Node, uint = M_MAX_UNSIGNED);
  8611. void ApplyAttributes();
  8612. void ClearControlPoints();
  8613. void DrawDebugGeometry(DebugRenderer, bool);
  8614. Variant GetAttribute(const String&) const;
  8615. ValueAnimation GetAttributeAnimation(const String&) const;
  8616. float GetAttributeAnimationSpeed(const String&) const;
  8617. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8618. Variant GetAttributeDefault(const String&) const;
  8619. Vector3 GetPoint(float) const;
  8620. bool Load(File, bool = false);
  8621. bool Load(VectorBuffer&, bool = false);
  8622. bool LoadXML(const XMLElement&, bool = false);
  8623. void MarkNetworkUpdate() const;
  8624. void Move(float);
  8625. void Remove();
  8626. void RemoveControlPoint(Node);
  8627. void RemoveInstanceDefault();
  8628. void Reset();
  8629. void ResetToDefault();
  8630. bool Save(File) const;
  8631. bool Save(VectorBuffer&) const;
  8632. bool SaveXML(XMLElement&) const;
  8633. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8634. bool SetAttribute(const String&, const Variant&);
  8635. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8636. void SetAttributeAnimationSpeed(const String&, float);
  8637. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8638. // Properties:
  8639. bool animationEnabled;
  8640. /* readonly */
  8641. Array<Variant> attributeDefaults;
  8642. /* readonly */
  8643. Array<AttributeInfo> attributeInfos;
  8644. Array<Variant> attributes;
  8645. /* readonly */
  8646. StringHash baseType;
  8647. /* readonly */
  8648. String category;
  8649. Node controlledNode;
  8650. bool enabled;
  8651. /* readonly */
  8652. bool enabledEffective;
  8653. /* readonly */
  8654. uint id;
  8655. InterpolationMode interpolationMode;
  8656. /* readonly */
  8657. bool isFinished;
  8658. /* readonly */
  8659. Node node;
  8660. /* readonly */
  8661. uint numAttributes;
  8662. ObjectAnimation objectAnimation;
  8663. Vector3 position;
  8664. /* readonly */
  8665. int refs;
  8666. float speed;
  8667. bool temporary;
  8668. /* readonly */
  8669. StringHash type;
  8670. /* readonly */
  8671. String typeName;
  8672. /* readonly */
  8673. int weakRefs;
  8674. };
  8675. class Sprite
  8676. {
  8677. // Methods:
  8678. void AddChild(UIElement);
  8679. void ApplyAttributes();
  8680. void BringToFront();
  8681. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  8682. uint FindChild(UIElement) const;
  8683. Variant GetAttribute(const String&) const;
  8684. ValueAnimation GetAttributeAnimation(const String&) const;
  8685. float GetAttributeAnimationSpeed(const String&) const;
  8686. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8687. Variant GetAttributeDefault(const String&) const;
  8688. UIElement GetChild(const String&, bool = false) const;
  8689. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  8690. Array<UIElement> GetChildren(bool = false) const;
  8691. UIElement GetElementEventSender() const;
  8692. uint GetNumChildren(bool) const;
  8693. void InsertChild(uint, UIElement);
  8694. bool Load(File, bool = false);
  8695. bool Load(VectorBuffer&, bool = false);
  8696. bool LoadChildXML(XMLFile, XMLFile = null);
  8697. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  8698. bool LoadXML(File);
  8699. bool LoadXML(VectorBuffer&);
  8700. bool LoadXML(XMLFile, XMLFile);
  8701. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  8702. bool LoadXML(const XMLElement&, bool = false);
  8703. void MarkNetworkUpdate() const;
  8704. void Remove();
  8705. void RemoveAllChildren();
  8706. void RemoveChild(UIElement, uint = 0);
  8707. void RemoveChild(uint);
  8708. void RemoveInstanceDefault();
  8709. void ResetToDefault();
  8710. bool Save(File) const;
  8711. bool Save(VectorBuffer&) const;
  8712. bool SaveXML(File);
  8713. bool SaveXML(VectorBuffer&);
  8714. bool SaveXML(XMLElement&) const;
  8715. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8716. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  8717. bool SetAttribute(const String&, const Variant&);
  8718. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8719. void SetAttributeAnimationSpeed(const String&, float);
  8720. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8721. void SetFixedHeight(int);
  8722. void SetFixedSize(int, int);
  8723. void SetFixedWidth(int);
  8724. void SetFullImageRect();
  8725. void SetHotSpot(int, int);
  8726. void SetMaxSize(int, int);
  8727. void SetMinSize(int, int);
  8728. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  8729. void SetPosition(float, float);
  8730. void SetScale(float);
  8731. void SetScale(float, float);
  8732. void SetSize(int, int);
  8733. bool SetStyle(const String&, XMLFile = null);
  8734. bool SetStyle(const XMLElement&);
  8735. bool SetStyleAuto(XMLFile = null);
  8736. const Variant& GetVar(const StringHash&);
  8737. // Properties:
  8738. bool animationEnabled;
  8739. /* readonly */
  8740. Array<Variant> attributeDefaults;
  8741. /* readonly */
  8742. Array<AttributeInfo> attributeInfos;
  8743. Array<Variant> attributes;
  8744. /* readonly */
  8745. StringHash baseType;
  8746. BlendMode blendMode;
  8747. bool bringToBack;
  8748. bool bringToFront;
  8749. /* readonly */
  8750. String category;
  8751. /* readonly */
  8752. Array<UIElement> children;
  8753. /* writeonly */
  8754. Color color;
  8755. /* readonly */
  8756. bool colorGradient;
  8757. Array<Color> colors;
  8758. XMLFile defaultStyle;
  8759. /* readonly */
  8760. float derivedOpacity;
  8761. /* readonly */
  8762. uint dragButtonCombo;
  8763. /* readonly */
  8764. int dragButtonCount;
  8765. bool elementEventSender;
  8766. int height;
  8767. HorizontalAlignment horizontalAlignment;
  8768. IntVector2 hotSpot;
  8769. IntRect imageRect;
  8770. String name;
  8771. /* readonly */
  8772. uint numAllChildren;
  8773. /* readonly */
  8774. uint numAttributes;
  8775. /* readonly */
  8776. uint numChildren;
  8777. ObjectAnimation objectAnimation;
  8778. float opacity;
  8779. UIElement parent;
  8780. Vector2 position;
  8781. int priority;
  8782. /* readonly */
  8783. int refs;
  8784. /* readonly */
  8785. UIElement root;
  8786. float rotation;
  8787. Vector2 scale;
  8788. IntVector2 size;
  8789. bool sortChildren;
  8790. String style;
  8791. bool temporary;
  8792. Texture texture;
  8793. /* readonly */
  8794. StringHash type;
  8795. /* readonly */
  8796. String typeName;
  8797. bool useDerivedOpacity;
  8798. /* readonly */
  8799. VariantMap vars;
  8800. VerticalAlignment verticalAlignment;
  8801. bool visible;
  8802. /* readonly */
  8803. int weakRefs;
  8804. int width;
  8805. };
  8806. class Sprite2D
  8807. {
  8808. // Methods:
  8809. bool Load(File);
  8810. bool Load(VectorBuffer&);
  8811. bool Save(File) const;
  8812. bool Save(VectorBuffer&) const;
  8813. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8814. // Properties:
  8815. /* readonly */
  8816. StringHash baseType;
  8817. /* readonly */
  8818. String category;
  8819. Vector2 hotSpot;
  8820. /* readonly */
  8821. uint memoryUse;
  8822. String name;
  8823. IntVector2 offset;
  8824. IntRect rectangle;
  8825. /* readonly */
  8826. int refs;
  8827. Texture2D texture;
  8828. /* readonly */
  8829. StringHash type;
  8830. /* readonly */
  8831. String typeName;
  8832. /* readonly */
  8833. uint useTimer;
  8834. /* readonly */
  8835. int weakRefs;
  8836. };
  8837. class SpriteSheet2D
  8838. {
  8839. // Methods:
  8840. void DefineSprite(const String&, const IntRect&, const Vector2& = Vector2 ( 0.5f , 0.5f ), const IntVector2& = IntVector2 :: ZERO);
  8841. Sprite2D GetSprite(const String&);
  8842. bool Load(File);
  8843. bool Load(VectorBuffer&);
  8844. bool Save(File) const;
  8845. bool Save(VectorBuffer&) const;
  8846. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8847. // Properties:
  8848. /* readonly */
  8849. StringHash baseType;
  8850. /* readonly */
  8851. String category;
  8852. /* readonly */
  8853. uint memoryUse;
  8854. String name;
  8855. /* readonly */
  8856. int refs;
  8857. /* readonly */
  8858. Texture2D texture;
  8859. /* readonly */
  8860. StringHash type;
  8861. /* readonly */
  8862. String typeName;
  8863. /* readonly */
  8864. uint useTimer;
  8865. /* readonly */
  8866. int weakRefs;
  8867. };
  8868. class StaticModel
  8869. {
  8870. // Methods:
  8871. void ApplyAttributes();
  8872. void ApplyMaterialList(const String& = String ( ));
  8873. void DrawDebugGeometry(DebugRenderer, bool);
  8874. Variant GetAttribute(const String&) const;
  8875. ValueAnimation GetAttributeAnimation(const String&) const;
  8876. float GetAttributeAnimationSpeed(const String&) const;
  8877. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8878. Variant GetAttributeDefault(const String&) const;
  8879. bool IsInView(Camera) const;
  8880. bool IsInside(const Vector3&) const;
  8881. bool IsInsideLocal(const Vector3&) const;
  8882. bool Load(File, bool = false);
  8883. bool Load(VectorBuffer&, bool = false);
  8884. bool LoadXML(const XMLElement&, bool = false);
  8885. void MarkNetworkUpdate() const;
  8886. void Remove();
  8887. void RemoveInstanceDefault();
  8888. void ResetToDefault();
  8889. bool Save(File) const;
  8890. bool Save(VectorBuffer&) const;
  8891. bool SaveXML(XMLElement&) const;
  8892. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8893. bool SetAttribute(const String&, const Variant&);
  8894. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8895. void SetAttributeAnimationSpeed(const String&, float);
  8896. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8897. // Properties:
  8898. bool animationEnabled;
  8899. /* readonly */
  8900. Array<Variant> attributeDefaults;
  8901. /* readonly */
  8902. Array<AttributeInfo> attributeInfos;
  8903. Array<Variant> attributes;
  8904. /* readonly */
  8905. StringHash baseType;
  8906. /* readonly */
  8907. BoundingBox boundingBox;
  8908. bool castShadows;
  8909. /* readonly */
  8910. String category;
  8911. float drawDistance;
  8912. bool enabled;
  8913. /* readonly */
  8914. bool enabledEffective;
  8915. /* readonly */
  8916. uint id;
  8917. /* readonly */
  8918. bool inView;
  8919. uint lightMask;
  8920. float lodBias;
  8921. /* writeonly */
  8922. Material material;
  8923. Array<Material> materials;
  8924. uint maxLights;
  8925. Model model;
  8926. /* readonly */
  8927. Node node;
  8928. /* readonly */
  8929. uint numAttributes;
  8930. /* readonly */
  8931. uint numGeometries;
  8932. ObjectAnimation objectAnimation;
  8933. bool occludee;
  8934. bool occluder;
  8935. uint occlusionLodLevel;
  8936. /* readonly */
  8937. int refs;
  8938. float shadowDistance;
  8939. uint shadowMask;
  8940. bool temporary;
  8941. /* readonly */
  8942. StringHash type;
  8943. /* readonly */
  8944. String typeName;
  8945. uint viewMask;
  8946. /* readonly */
  8947. int weakRefs;
  8948. /* readonly */
  8949. BoundingBox worldBoundingBox;
  8950. uint zoneMask;
  8951. };
  8952. class StaticModelGroup
  8953. {
  8954. // Methods:
  8955. void AddInstanceNode(Node);
  8956. void ApplyAttributes();
  8957. void ApplyMaterialList(const String& = String ( ));
  8958. void DrawDebugGeometry(DebugRenderer, bool);
  8959. Variant GetAttribute(const String&) const;
  8960. ValueAnimation GetAttributeAnimation(const String&) const;
  8961. float GetAttributeAnimationSpeed(const String&) const;
  8962. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  8963. Variant GetAttributeDefault(const String&) const;
  8964. bool IsInView(Camera) const;
  8965. bool Load(File, bool = false);
  8966. bool Load(VectorBuffer&, bool = false);
  8967. bool LoadXML(const XMLElement&, bool = false);
  8968. void MarkNetworkUpdate() const;
  8969. void Remove();
  8970. void RemoveAllInstanceNodes();
  8971. void RemoveInstanceDefault();
  8972. void RemoveInstanceNode(Node);
  8973. void ResetToDefault();
  8974. bool Save(File) const;
  8975. bool Save(VectorBuffer&) const;
  8976. bool SaveXML(XMLElement&) const;
  8977. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  8978. bool SetAttribute(const String&, const Variant&);
  8979. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  8980. void SetAttributeAnimationSpeed(const String&, float);
  8981. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  8982. // Properties:
  8983. bool animationEnabled;
  8984. /* readonly */
  8985. Array<Variant> attributeDefaults;
  8986. /* readonly */
  8987. Array<AttributeInfo> attributeInfos;
  8988. Array<Variant> attributes;
  8989. /* readonly */
  8990. StringHash baseType;
  8991. /* readonly */
  8992. BoundingBox boundingBox;
  8993. bool castShadows;
  8994. /* readonly */
  8995. String category;
  8996. float drawDistance;
  8997. bool enabled;
  8998. /* readonly */
  8999. bool enabledEffective;
  9000. /* readonly */
  9001. uint id;
  9002. /* readonly */
  9003. bool inView;
  9004. /* readonly */
  9005. Array<Node> instanceNodes;
  9006. uint lightMask;
  9007. float lodBias;
  9008. /* writeonly */
  9009. Material material;
  9010. Array<Material> materials;
  9011. uint maxLights;
  9012. Model model;
  9013. /* readonly */
  9014. Node node;
  9015. /* readonly */
  9016. uint numAttributes;
  9017. /* readonly */
  9018. uint numGeometries;
  9019. /* readonly */
  9020. uint numInstanceNodes;
  9021. ObjectAnimation objectAnimation;
  9022. bool occludee;
  9023. bool occluder;
  9024. uint occlusionLodLevel;
  9025. /* readonly */
  9026. int refs;
  9027. float shadowDistance;
  9028. uint shadowMask;
  9029. bool temporary;
  9030. /* readonly */
  9031. StringHash type;
  9032. /* readonly */
  9033. String typeName;
  9034. uint viewMask;
  9035. /* readonly */
  9036. int weakRefs;
  9037. /* readonly */
  9038. BoundingBox worldBoundingBox;
  9039. /* readonly */
  9040. Zone zone;
  9041. uint zoneMask;
  9042. };
  9043. class StaticSprite2D
  9044. {
  9045. // Methods:
  9046. void ApplyAttributes();
  9047. void DrawDebugGeometry(DebugRenderer, bool);
  9048. Variant GetAttribute(const String&) const;
  9049. ValueAnimation GetAttributeAnimation(const String&) const;
  9050. float GetAttributeAnimationSpeed(const String&) const;
  9051. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9052. Variant GetAttributeDefault(const String&) const;
  9053. bool IsInView(Camera) const;
  9054. bool Load(File, bool = false);
  9055. bool Load(VectorBuffer&, bool = false);
  9056. bool LoadXML(const XMLElement&, bool = false);
  9057. void MarkNetworkUpdate() const;
  9058. void Remove();
  9059. void RemoveInstanceDefault();
  9060. void ResetToDefault();
  9061. bool Save(File) const;
  9062. bool Save(VectorBuffer&) const;
  9063. bool SaveXML(XMLElement&) const;
  9064. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9065. bool SetAttribute(const String&, const Variant&);
  9066. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9067. void SetAttributeAnimationSpeed(const String&, float);
  9068. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9069. void SetFlip(bool, bool);
  9070. // Properties:
  9071. float alpha;
  9072. bool animationEnabled;
  9073. /* readonly */
  9074. Array<Variant> attributeDefaults;
  9075. /* readonly */
  9076. Array<AttributeInfo> attributeInfos;
  9077. Array<Variant> attributes;
  9078. /* readonly */
  9079. StringHash baseType;
  9080. BlendMode blendMode;
  9081. /* readonly */
  9082. BoundingBox boundingBox;
  9083. bool castShadows;
  9084. /* readonly */
  9085. String category;
  9086. Color color;
  9087. float drawDistance;
  9088. bool enabled;
  9089. /* readonly */
  9090. bool enabledEffective;
  9091. bool flipX;
  9092. bool flipY;
  9093. Vector2 hotSpot;
  9094. /* readonly */
  9095. uint id;
  9096. /* readonly */
  9097. bool inView;
  9098. int layer;
  9099. uint lightMask;
  9100. float lodBias;
  9101. uint maxLights;
  9102. /* readonly */
  9103. Node node;
  9104. /* readonly */
  9105. uint numAttributes;
  9106. ObjectAnimation objectAnimation;
  9107. bool occludee;
  9108. bool occluder;
  9109. int orderInLayer;
  9110. /* readonly */
  9111. int refs;
  9112. float shadowDistance;
  9113. uint shadowMask;
  9114. Sprite2D sprite;
  9115. bool temporary;
  9116. Texture2D texture;
  9117. /* readonly */
  9118. StringHash type;
  9119. /* readonly */
  9120. String typeName;
  9121. bool useHotSpot;
  9122. uint viewMask;
  9123. /* readonly */
  9124. int weakRefs;
  9125. /* readonly */
  9126. BoundingBox worldBoundingBox;
  9127. uint zoneMask;
  9128. };
  9129. class String
  9130. {
  9131. // Methods:
  9132. void AppendUTF8(uint);
  9133. uint AtUTF8(uint) const;
  9134. uint ByteOffsetUTF8(uint) const;
  9135. void Clear();
  9136. int Compare(const String&, bool = true) const;
  9137. bool Contains(const String&, bool = true) const;
  9138. bool Contains(uint8, bool = true) const;
  9139. bool EndsWith(const String&, bool = true) const;
  9140. uint Find(const String&, uint = 0, bool = true) const;
  9141. uint Find(uint8, uint = 0, bool = true) const;
  9142. uint FindLast(const String&, uint = 0xffffffff, bool = true) const;
  9143. uint FindLast(uint8, uint = 0xffffffff, bool = true) const;
  9144. void Join(Array<String>&, const String&);
  9145. uint NextUTF8Char(uint&) const;
  9146. void Replace(const String&, const String&, bool = true);
  9147. void Replace(uint8, uint8, bool = true);
  9148. void ReplaceUTF8(uint, uint);
  9149. String Replaced(const String&, const String&, bool = true) const;
  9150. String Replaced(uint8, uint8, bool = true) const;
  9151. void Resize(uint);
  9152. void SetUTF8FromLatin1(const String&);
  9153. Array<String> Split(uint8) const;
  9154. bool StartsWith(const String&, bool = true) const;
  9155. String Substring(uint) const;
  9156. String Substring(uint, uint) const;
  9157. String SubstringUTF8(uint) const;
  9158. String SubstringUTF8(uint, uint) const;
  9159. bool ToBool() const;
  9160. Color ToColor() const;
  9161. float ToFloat() const;
  9162. int ToInt() const;
  9163. IntRect ToIntRect() const;
  9164. IntVector2 ToIntVector2() const;
  9165. String ToLower() const;
  9166. Matrix3 ToMatrix3() const;
  9167. Matrix3x4 ToMatrix3x4() const;
  9168. Matrix4 ToMatrix4() const;
  9169. Quaternion ToQuaternion() const;
  9170. uint ToUInt() const;
  9171. String ToUpper() const;
  9172. Vector2 ToVector2() const;
  9173. Vector3 ToVector3() const;
  9174. Vector4 ToVector4(bool = false) const;
  9175. Variant ToVectorVariant() const;
  9176. String Trimmed() const;
  9177. // Properties:
  9178. /* readonly */
  9179. bool empty;
  9180. /* readonly */
  9181. uint length;
  9182. /* readonly */
  9183. uint utf8Length;
  9184. };
  9185. class StringHash
  9186. {
  9187. // Methods:
  9188. String ToString() const;
  9189. // Properties:
  9190. /* readonly */
  9191. uint value;
  9192. };
  9193. class Technique
  9194. {
  9195. // Methods:
  9196. Pass CreatePass(StringHash);
  9197. Pass GetPass(StringHash);
  9198. Pass GetSupportedPass(StringHash);
  9199. bool HasPass(StringHash) const;
  9200. bool Load(File);
  9201. bool Load(VectorBuffer&);
  9202. void RemovePass(StringHash);
  9203. bool Save(File) const;
  9204. bool Save(VectorBuffer&) const;
  9205. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9206. // Properties:
  9207. /* readonly */
  9208. StringHash baseType;
  9209. /* readonly */
  9210. String category;
  9211. bool desktop;
  9212. /* readonly */
  9213. uint memoryUse;
  9214. String name;
  9215. /* readonly */
  9216. uint numPasses;
  9217. /* readonly */
  9218. Array<StringHash> passTypes;
  9219. /* readonly */
  9220. Array<Pass> passes;
  9221. /* readonly */
  9222. int refs;
  9223. bool sm3;
  9224. /* readonly */
  9225. bool supported;
  9226. /* readonly */
  9227. StringHash type;
  9228. /* readonly */
  9229. String typeName;
  9230. /* readonly */
  9231. uint useTimer;
  9232. /* readonly */
  9233. int weakRefs;
  9234. };
  9235. class TechniqueEntry
  9236. {
  9237. // Properties:
  9238. float lodDistance;
  9239. int qualityLevel;
  9240. Technique technique;
  9241. };
  9242. class Terrain
  9243. {
  9244. // Methods:
  9245. void ApplyAttributes();
  9246. void ApplyHeightMap();
  9247. void DrawDebugGeometry(DebugRenderer, bool);
  9248. Variant GetAttribute(const String&) const;
  9249. ValueAnimation GetAttributeAnimation(const String&) const;
  9250. float GetAttributeAnimationSpeed(const String&) const;
  9251. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9252. Variant GetAttributeDefault(const String&) const;
  9253. float GetHeight(const Vector3&) const;
  9254. Vector3 GetNormal(const Vector3&) const;
  9255. TerrainPatch GetPatch(int, int) const;
  9256. bool Load(File, bool = false);
  9257. bool Load(VectorBuffer&, bool = false);
  9258. bool LoadXML(const XMLElement&, bool = false);
  9259. void MarkNetworkUpdate() const;
  9260. void Remove();
  9261. void RemoveInstanceDefault();
  9262. void ResetToDefault();
  9263. bool Save(File) const;
  9264. bool Save(VectorBuffer&) const;
  9265. bool SaveXML(XMLElement&) const;
  9266. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9267. bool SetAttribute(const String&, const Variant&);
  9268. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9269. void SetAttributeAnimationSpeed(const String&, float);
  9270. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9271. IntVector2 WorldToHeightMap(const Vector3&) const;
  9272. // Properties:
  9273. bool animationEnabled;
  9274. /* readonly */
  9275. Array<Variant> attributeDefaults;
  9276. /* readonly */
  9277. Array<AttributeInfo> attributeInfos;
  9278. Array<Variant> attributes;
  9279. /* readonly */
  9280. StringHash baseType;
  9281. bool castShadows;
  9282. /* readonly */
  9283. String category;
  9284. float drawDistance;
  9285. bool enabled;
  9286. /* readonly */
  9287. bool enabledEffective;
  9288. Image heightMap;
  9289. /* readonly */
  9290. uint id;
  9291. uint lightMask;
  9292. float lodBias;
  9293. Material material;
  9294. uint maxLights;
  9295. /* readonly */
  9296. Node node;
  9297. /* readonly */
  9298. uint numAttributes;
  9299. /* readonly */
  9300. IntVector2 numPatches;
  9301. /* readonly */
  9302. IntVector2 numVertices;
  9303. ObjectAnimation objectAnimation;
  9304. bool occludee;
  9305. bool occluder;
  9306. int patchSize;
  9307. /* readonly */
  9308. Array<TerrainPatch> patches;
  9309. /* readonly */
  9310. int refs;
  9311. float shadowDistance;
  9312. uint shadowMask;
  9313. bool smoothing;
  9314. Vector3 spacing;
  9315. bool temporary;
  9316. /* readonly */
  9317. StringHash type;
  9318. /* readonly */
  9319. String typeName;
  9320. uint viewMask;
  9321. /* readonly */
  9322. int weakRefs;
  9323. uint zoneMask;
  9324. };
  9325. class TerrainPatch
  9326. {
  9327. // Methods:
  9328. void ApplyAttributes();
  9329. void DrawDebugGeometry(DebugRenderer, bool);
  9330. Variant GetAttribute(const String&) const;
  9331. ValueAnimation GetAttributeAnimation(const String&) const;
  9332. float GetAttributeAnimationSpeed(const String&) const;
  9333. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9334. Variant GetAttributeDefault(const String&) const;
  9335. bool IsInView(Camera) const;
  9336. bool Load(File, bool = false);
  9337. bool Load(VectorBuffer&, bool = false);
  9338. bool LoadXML(const XMLElement&, bool = false);
  9339. void MarkNetworkUpdate() const;
  9340. void Remove();
  9341. void RemoveInstanceDefault();
  9342. void ResetToDefault();
  9343. bool Save(File) const;
  9344. bool Save(VectorBuffer&) const;
  9345. bool SaveXML(XMLElement&) const;
  9346. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9347. bool SetAttribute(const String&, const Variant&);
  9348. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9349. void SetAttributeAnimationSpeed(const String&, float);
  9350. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9351. // Properties:
  9352. bool animationEnabled;
  9353. /* readonly */
  9354. Array<Variant> attributeDefaults;
  9355. /* readonly */
  9356. Array<AttributeInfo> attributeInfos;
  9357. Array<Variant> attributes;
  9358. /* readonly */
  9359. StringHash baseType;
  9360. /* readonly */
  9361. BoundingBox boundingBox;
  9362. bool castShadows;
  9363. /* readonly */
  9364. String category;
  9365. float drawDistance;
  9366. bool enabled;
  9367. /* readonly */
  9368. bool enabledEffective;
  9369. /* readonly */
  9370. uint id;
  9371. /* readonly */
  9372. bool inView;
  9373. uint lightMask;
  9374. float lodBias;
  9375. uint maxLights;
  9376. /* readonly */
  9377. Node node;
  9378. /* readonly */
  9379. uint numAttributes;
  9380. ObjectAnimation objectAnimation;
  9381. bool occludee;
  9382. bool occluder;
  9383. /* readonly */
  9384. int refs;
  9385. float shadowDistance;
  9386. uint shadowMask;
  9387. bool temporary;
  9388. /* readonly */
  9389. StringHash type;
  9390. /* readonly */
  9391. String typeName;
  9392. uint viewMask;
  9393. /* readonly */
  9394. int weakRefs;
  9395. /* readonly */
  9396. BoundingBox worldBoundingBox;
  9397. uint zoneMask;
  9398. };
  9399. class Text
  9400. {
  9401. // Methods:
  9402. void AddChild(UIElement);
  9403. void ApplyAttributes();
  9404. void BringToFront();
  9405. void ClearSelection();
  9406. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  9407. void DisableLayoutUpdate();
  9408. IntVector2 ElementToScreen(const IntVector2&);
  9409. void EnableLayoutUpdate();
  9410. uint FindChild(UIElement) const;
  9411. Variant GetAttribute(const String&) const;
  9412. ValueAnimation GetAttributeAnimation(const String&) const;
  9413. float GetAttributeAnimationSpeed(const String&) const;
  9414. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9415. Variant GetAttributeDefault(const String&) const;
  9416. UIElement GetChild(const String&, bool = false) const;
  9417. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  9418. Array<UIElement> GetChildren(bool = false) const;
  9419. UIElement GetElementEventSender() const;
  9420. uint GetNumChildren(bool) const;
  9421. void InsertChild(uint, UIElement);
  9422. bool IsInside(IntVector2, bool);
  9423. bool IsInsideCombined(IntVector2, bool);
  9424. bool Load(File, bool = false);
  9425. bool Load(VectorBuffer&, bool = false);
  9426. bool LoadChildXML(XMLFile, XMLFile = null);
  9427. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  9428. bool LoadXML(File);
  9429. bool LoadXML(VectorBuffer&);
  9430. bool LoadXML(XMLFile, XMLFile);
  9431. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  9432. bool LoadXML(const XMLElement&, bool = false);
  9433. void MarkNetworkUpdate() const;
  9434. void Remove();
  9435. void RemoveAllChildren();
  9436. void RemoveChild(UIElement, uint = 0);
  9437. void RemoveChild(uint);
  9438. void RemoveInstanceDefault();
  9439. void ResetDeepEnabled();
  9440. void ResetToDefault();
  9441. bool Save(File) const;
  9442. bool Save(VectorBuffer&) const;
  9443. bool SaveXML(File);
  9444. bool SaveXML(VectorBuffer&);
  9445. bool SaveXML(XMLElement&) const;
  9446. IntVector2 ScreenToElement(const IntVector2&);
  9447. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9448. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  9449. bool SetAttribute(const String&, const Variant&);
  9450. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9451. void SetAttributeAnimationSpeed(const String&, float);
  9452. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9453. void SetDeepEnabled(bool);
  9454. void SetEnabledRecursive(bool);
  9455. void SetFixedHeight(int);
  9456. void SetFixedSize(int, int);
  9457. void SetFixedWidth(int);
  9458. bool SetFont(Font, int);
  9459. bool SetFont(const String&, int);
  9460. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  9461. void SetMaxSize(int, int);
  9462. void SetMinSize(int, int);
  9463. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  9464. void SetPosition(int, int);
  9465. void SetSelection(uint, uint = M_MAX_UNSIGNED);
  9466. void SetSize(int, int);
  9467. bool SetStyle(const String&, XMLFile = null);
  9468. bool SetStyle(const XMLElement&);
  9469. bool SetStyleAuto(XMLFile = null);
  9470. void UpdateLayout();
  9471. const Variant& GetVar(const StringHash&);
  9472. // Properties:
  9473. bool animationEnabled;
  9474. /* readonly */
  9475. Array<Variant> attributeDefaults;
  9476. /* readonly */
  9477. Array<AttributeInfo> attributeInfos;
  9478. Array<Variant> attributes;
  9479. /* readonly */
  9480. StringHash baseType;
  9481. bool bringToBack;
  9482. bool bringToFront;
  9483. /* readonly */
  9484. String category;
  9485. /* readonly */
  9486. Array<IntVector2> charPositions;
  9487. /* readonly */
  9488. Array<IntVector2> charSizes;
  9489. /* readonly */
  9490. IntVector2 childOffset;
  9491. /* readonly */
  9492. Array<UIElement> children;
  9493. IntRect clipBorder;
  9494. bool clipChildren;
  9495. /* writeonly */
  9496. Color color;
  9497. /* readonly */
  9498. bool colorGradient;
  9499. Array<Color> colors;
  9500. /* readonly */
  9501. IntRect combinedScreenRect;
  9502. XMLFile defaultStyle;
  9503. /* readonly */
  9504. float derivedOpacity;
  9505. /* readonly */
  9506. uint dragButtonCombo;
  9507. /* readonly */
  9508. int dragButtonCount;
  9509. uint dragDropMode;
  9510. bool editable;
  9511. Color effectColor;
  9512. bool elementEventSender;
  9513. bool enabled;
  9514. /* readonly */
  9515. bool enabledSelf;
  9516. /* readonly */
  9517. bool fixedHeight;
  9518. /* readonly */
  9519. bool fixedSize;
  9520. /* readonly */
  9521. bool fixedWidth;
  9522. bool focus;
  9523. FocusMode focusMode;
  9524. /* readonly */
  9525. Font font;
  9526. /* readonly */
  9527. int fontSize;
  9528. int height;
  9529. HorizontalAlignment horizontalAlignment;
  9530. Color hoverColor;
  9531. /* readonly */
  9532. bool hovering;
  9533. int indent;
  9534. int indentSpacing;
  9535. /* readonly */
  9536. int indentWidth;
  9537. bool internal;
  9538. IntRect layoutBorder;
  9539. Vector2 layoutFlexScale;
  9540. LayoutMode layoutMode;
  9541. int layoutSpacing;
  9542. int maxHeight;
  9543. IntVector2 maxSize;
  9544. int maxWidth;
  9545. int minHeight;
  9546. IntVector2 minSize;
  9547. int minWidth;
  9548. String name;
  9549. /* readonly */
  9550. uint numAllChildren;
  9551. /* readonly */
  9552. uint numAttributes;
  9553. /* readonly */
  9554. uint numChars;
  9555. /* readonly */
  9556. uint numChildren;
  9557. /* readonly */
  9558. uint numRows;
  9559. ObjectAnimation objectAnimation;
  9560. float opacity;
  9561. UIElement parent;
  9562. IntVector2 position;
  9563. int priority;
  9564. /* readonly */
  9565. int refs;
  9566. /* readonly */
  9567. UIElement root;
  9568. /* readonly */
  9569. int rowHeight;
  9570. float rowSpacing;
  9571. /* readonly */
  9572. Array<int> rowWidths;
  9573. /* readonly */
  9574. IntVector2 screenPosition;
  9575. bool selected;
  9576. Color selectionColor;
  9577. /* readonly */
  9578. uint selectionLength;
  9579. /* readonly */
  9580. uint selectionStart;
  9581. IntVector2 size;
  9582. bool sortChildren;
  9583. String style;
  9584. bool temporary;
  9585. String text;
  9586. HorizontalAlignment textAlignment;
  9587. TextEffect textEffect;
  9588. TraversalMode traversalMode;
  9589. /* readonly */
  9590. StringHash type;
  9591. /* readonly */
  9592. String typeName;
  9593. bool useDerivedOpacity;
  9594. /* readonly */
  9595. VariantMap vars;
  9596. VerticalAlignment verticalAlignment;
  9597. bool visible;
  9598. /* readonly */
  9599. int weakRefs;
  9600. int width;
  9601. bool wordwrap;
  9602. };
  9603. class Text3D
  9604. {
  9605. // Methods:
  9606. void ApplyAttributes();
  9607. void DrawDebugGeometry(DebugRenderer, bool);
  9608. Variant GetAttribute(const String&) const;
  9609. ValueAnimation GetAttributeAnimation(const String&) const;
  9610. float GetAttributeAnimationSpeed(const String&) const;
  9611. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9612. Variant GetAttributeDefault(const String&) const;
  9613. bool IsInView(Camera) const;
  9614. bool Load(File, bool = false);
  9615. bool Load(VectorBuffer&, bool = false);
  9616. bool LoadXML(const XMLElement&, bool = false);
  9617. void MarkNetworkUpdate() const;
  9618. void Remove();
  9619. void RemoveInstanceDefault();
  9620. void ResetToDefault();
  9621. bool Save(File) const;
  9622. bool Save(VectorBuffer&) const;
  9623. bool SaveXML(XMLElement&) const;
  9624. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9625. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  9626. bool SetAttribute(const String&, const Variant&);
  9627. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9628. void SetAttributeAnimationSpeed(const String&, float);
  9629. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9630. bool SetFont(Font, int);
  9631. bool SetFont(const String&, int);
  9632. // Properties:
  9633. bool animationEnabled;
  9634. /* readonly */
  9635. Array<Variant> attributeDefaults;
  9636. /* readonly */
  9637. Array<AttributeInfo> attributeInfos;
  9638. Array<Variant> attributes;
  9639. /* readonly */
  9640. StringHash baseType;
  9641. /* readonly */
  9642. BoundingBox boundingBox;
  9643. bool castShadows;
  9644. /* readonly */
  9645. String category;
  9646. /* readonly */
  9647. Array<IntVector2> charPositions;
  9648. /* readonly */
  9649. Array<IntVector2> charSizes;
  9650. /* writeonly */
  9651. Color color;
  9652. Array<Color> colors;
  9653. float drawDistance;
  9654. Color effectColor;
  9655. float effectDepthBias;
  9656. bool enabled;
  9657. /* readonly */
  9658. bool enabledEffective;
  9659. FaceCameraMode faceCameraMode;
  9660. /* readonly */
  9661. Font font;
  9662. /* readonly */
  9663. int fontSize;
  9664. HorizontalAlignment horizontalAlignment;
  9665. /* readonly */
  9666. uint id;
  9667. /* readonly */
  9668. bool inView;
  9669. uint lightMask;
  9670. float lodBias;
  9671. Material material;
  9672. uint maxLights;
  9673. /* readonly */
  9674. Node node;
  9675. /* readonly */
  9676. uint numAttributes;
  9677. /* readonly */
  9678. uint numChars;
  9679. /* readonly */
  9680. uint numRows;
  9681. ObjectAnimation objectAnimation;
  9682. bool occludee;
  9683. bool occluder;
  9684. float opacity;
  9685. /* readonly */
  9686. int refs;
  9687. /* readonly */
  9688. int rowHeight;
  9689. float rowSpacing;
  9690. /* readonly */
  9691. Array<int> rowWidths;
  9692. float shadowDistance;
  9693. uint shadowMask;
  9694. bool temporary;
  9695. String text;
  9696. HorizontalAlignment textAlignment;
  9697. TextEffect textEffect;
  9698. /* readonly */
  9699. StringHash type;
  9700. /* readonly */
  9701. String typeName;
  9702. VerticalAlignment verticalAlignment;
  9703. uint viewMask;
  9704. /* readonly */
  9705. int weakRefs;
  9706. int width;
  9707. bool wordwrap;
  9708. /* readonly */
  9709. BoundingBox worldBoundingBox;
  9710. uint zoneMask;
  9711. };
  9712. class Texture
  9713. {
  9714. // Methods:
  9715. void ClearDataLost();
  9716. bool Load(File);
  9717. bool Load(VectorBuffer&);
  9718. bool Save(File) const;
  9719. bool Save(VectorBuffer&) const;
  9720. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9721. void SetNumLevels(uint);
  9722. // Properties:
  9723. Array<TextureAddressMode> addressMode;
  9724. Texture backupTexture;
  9725. /* readonly */
  9726. StringHash baseType;
  9727. Color borderColor;
  9728. /* readonly */
  9729. String category;
  9730. /* readonly */
  9731. bool compressed;
  9732. /* readonly */
  9733. bool dataLost;
  9734. TextureFilterMode filterMode;
  9735. /* readonly */
  9736. uint format;
  9737. /* readonly */
  9738. int height;
  9739. /* readonly */
  9740. Array<int> levelHeight;
  9741. /* readonly */
  9742. Array<int> levelWidth;
  9743. /* readonly */
  9744. uint levels;
  9745. /* readonly */
  9746. uint memoryUse;
  9747. Array<int> mipsToSkip;
  9748. String name;
  9749. /* readonly */
  9750. int refs;
  9751. bool sRGB;
  9752. /* readonly */
  9753. StringHash type;
  9754. /* readonly */
  9755. String typeName;
  9756. /* readonly */
  9757. TextureUsage usage;
  9758. /* readonly */
  9759. uint useTimer;
  9760. /* readonly */
  9761. int weakRefs;
  9762. /* readonly */
  9763. int width;
  9764. };
  9765. class Texture2D
  9766. {
  9767. // Methods:
  9768. void ClearDataLost();
  9769. bool Load(File);
  9770. bool Load(VectorBuffer&);
  9771. bool Save(File) const;
  9772. bool Save(VectorBuffer&) const;
  9773. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9774. bool SetData(Image, bool = false);
  9775. void SetNumLevels(uint);
  9776. bool SetSize(int, int, uint, TextureUsage = TEXTURE_STATIC);
  9777. // Properties:
  9778. Array<TextureAddressMode> addressMode;
  9779. Texture backupTexture;
  9780. /* readonly */
  9781. StringHash baseType;
  9782. Color borderColor;
  9783. /* readonly */
  9784. String category;
  9785. /* readonly */
  9786. bool compressed;
  9787. /* readonly */
  9788. bool dataLost;
  9789. TextureFilterMode filterMode;
  9790. /* readonly */
  9791. uint format;
  9792. /* readonly */
  9793. int height;
  9794. /* readonly */
  9795. Array<int> levelHeight;
  9796. /* readonly */
  9797. Array<int> levelWidth;
  9798. /* readonly */
  9799. uint levels;
  9800. /* readonly */
  9801. uint memoryUse;
  9802. Array<int> mipsToSkip;
  9803. String name;
  9804. /* readonly */
  9805. int refs;
  9806. /* readonly */
  9807. RenderSurface renderSurface;
  9808. bool sRGB;
  9809. /* readonly */
  9810. StringHash type;
  9811. /* readonly */
  9812. String typeName;
  9813. /* readonly */
  9814. TextureUsage usage;
  9815. /* readonly */
  9816. uint useTimer;
  9817. /* readonly */
  9818. int weakRefs;
  9819. /* readonly */
  9820. int width;
  9821. };
  9822. class Texture3D
  9823. {
  9824. // Methods:
  9825. void ClearDataLost();
  9826. bool Load(File);
  9827. bool Load(VectorBuffer&);
  9828. bool Save(File) const;
  9829. bool Save(VectorBuffer&) const;
  9830. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9831. bool SetData(Image, bool = false);
  9832. void SetNumLevels(uint);
  9833. bool SetSize(int, int, uint, TextureUsage = TEXTURE_STATIC);
  9834. // Properties:
  9835. Array<TextureAddressMode> addressMode;
  9836. Texture backupTexture;
  9837. /* readonly */
  9838. StringHash baseType;
  9839. Color borderColor;
  9840. /* readonly */
  9841. String category;
  9842. /* readonly */
  9843. bool compressed;
  9844. /* readonly */
  9845. bool dataLost;
  9846. TextureFilterMode filterMode;
  9847. /* readonly */
  9848. uint format;
  9849. /* readonly */
  9850. int height;
  9851. /* readonly */
  9852. Array<int> levelHeight;
  9853. /* readonly */
  9854. Array<int> levelWidth;
  9855. /* readonly */
  9856. uint levels;
  9857. /* readonly */
  9858. uint memoryUse;
  9859. Array<int> mipsToSkip;
  9860. String name;
  9861. /* readonly */
  9862. int refs;
  9863. /* readonly */
  9864. RenderSurface renderSurface;
  9865. bool sRGB;
  9866. /* readonly */
  9867. StringHash type;
  9868. /* readonly */
  9869. String typeName;
  9870. /* readonly */
  9871. TextureUsage usage;
  9872. /* readonly */
  9873. uint useTimer;
  9874. /* readonly */
  9875. int weakRefs;
  9876. /* readonly */
  9877. int width;
  9878. };
  9879. class TextureCube
  9880. {
  9881. // Methods:
  9882. void ClearDataLost();
  9883. bool Load(File);
  9884. bool Load(VectorBuffer&);
  9885. bool Save(File) const;
  9886. bool Save(VectorBuffer&) const;
  9887. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9888. bool SetData(CubeMapFace, Image, bool = false);
  9889. void SetNumLevels(uint);
  9890. bool SetSize(int, uint, TextureUsage = TEXTURE_STATIC);
  9891. // Properties:
  9892. Array<TextureAddressMode> addressMode;
  9893. Texture backupTexture;
  9894. /* readonly */
  9895. StringHash baseType;
  9896. Color borderColor;
  9897. /* readonly */
  9898. String category;
  9899. /* readonly */
  9900. bool compressed;
  9901. /* readonly */
  9902. bool dataLost;
  9903. TextureFilterMode filterMode;
  9904. /* readonly */
  9905. uint format;
  9906. /* readonly */
  9907. int height;
  9908. /* readonly */
  9909. Array<int> levelHeight;
  9910. /* readonly */
  9911. Array<int> levelWidth;
  9912. /* readonly */
  9913. uint levels;
  9914. /* readonly */
  9915. uint memoryUse;
  9916. Array<int> mipsToSkip;
  9917. String name;
  9918. /* readonly */
  9919. int refs;
  9920. /* readonly */
  9921. Array<RenderSurface> renderSurfaces;
  9922. bool sRGB;
  9923. /* readonly */
  9924. StringHash type;
  9925. /* readonly */
  9926. String typeName;
  9927. /* readonly */
  9928. TextureUsage usage;
  9929. /* readonly */
  9930. uint useTimer;
  9931. /* readonly */
  9932. int weakRefs;
  9933. /* readonly */
  9934. int width;
  9935. };
  9936. class TextureFrame
  9937. {
  9938. // Properties:
  9939. float time;
  9940. Rect uv;
  9941. };
  9942. class Tile2D
  9943. {
  9944. // Methods:
  9945. bool HasProperty(const String&) const;
  9946. const String& GetProperty(const String&) const;
  9947. // Properties:
  9948. /* readonly */
  9949. int gid;
  9950. /* readonly */
  9951. int refs;
  9952. /* readonly */
  9953. Sprite2D sprite;
  9954. /* readonly */
  9955. int weakRefs;
  9956. };
  9957. class TileMap2D
  9958. {
  9959. // Methods:
  9960. void ApplyAttributes();
  9961. void DrawDebugGeometry(DebugRenderer, bool);
  9962. Variant GetAttribute(const String&) const;
  9963. ValueAnimation GetAttributeAnimation(const String&) const;
  9964. float GetAttributeAnimationSpeed(const String&) const;
  9965. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  9966. Variant GetAttributeDefault(const String&) const;
  9967. TileMapLayer2D GetLayer(uint) const;
  9968. bool Load(File, bool = false);
  9969. bool Load(VectorBuffer&, bool = false);
  9970. bool LoadXML(const XMLElement&, bool = false);
  9971. void MarkNetworkUpdate() const;
  9972. bool PositionToTileIndex(int&, int&, const Vector2&) const;
  9973. void Remove();
  9974. void RemoveInstanceDefault();
  9975. void ResetToDefault();
  9976. bool Save(File) const;
  9977. bool Save(VectorBuffer&) const;
  9978. bool SaveXML(XMLElement&) const;
  9979. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  9980. bool SetAttribute(const String&, const Variant&);
  9981. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  9982. void SetAttributeAnimationSpeed(const String&, float);
  9983. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  9984. Vector2 TileIndexToPosition(int, int) const;
  9985. // Properties:
  9986. bool animationEnabled;
  9987. /* readonly */
  9988. Array<Variant> attributeDefaults;
  9989. /* readonly */
  9990. Array<AttributeInfo> attributeInfos;
  9991. Array<Variant> attributes;
  9992. /* readonly */
  9993. StringHash baseType;
  9994. /* readonly */
  9995. String category;
  9996. bool enabled;
  9997. /* readonly */
  9998. bool enabledEffective;
  9999. /* readonly */
  10000. uint id;
  10001. /* readonly */
  10002. TileMapInfo2D info;
  10003. /* readonly */
  10004. Node node;
  10005. /* readonly */
  10006. uint numAttributes;
  10007. /* readonly */
  10008. uint numLayers;
  10009. ObjectAnimation objectAnimation;
  10010. /* readonly */
  10011. int refs;
  10012. bool temporary;
  10013. TmxFile2D tmxFile;
  10014. /* readonly */
  10015. StringHash type;
  10016. /* readonly */
  10017. String typeName;
  10018. /* readonly */
  10019. int weakRefs;
  10020. };
  10021. class TileMapInfo2D
  10022. {
  10023. // Properties:
  10024. int height;
  10025. /* readonly */
  10026. float mapHeight;
  10027. /* readonly */
  10028. float mapWidth;
  10029. Orientation2D orientation;
  10030. float tileHeight;
  10031. float tileWidth;
  10032. int width;
  10033. };
  10034. class TileMapLayer2D
  10035. {
  10036. // Methods:
  10037. void ApplyAttributes();
  10038. void DrawDebugGeometry(DebugRenderer, bool);
  10039. Variant GetAttribute(const String&) const;
  10040. ValueAnimation GetAttributeAnimation(const String&) const;
  10041. float GetAttributeAnimationSpeed(const String&) const;
  10042. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  10043. Variant GetAttributeDefault(const String&) const;
  10044. TileMapObject2D GetObject(uint) const;
  10045. Node GetObjectNode(uint) const;
  10046. Tile2D GetTile(int, int) const;
  10047. Node GetTileNode(int, int) const;
  10048. bool HasProperty(const String&) const;
  10049. bool Load(File, bool = false);
  10050. bool Load(VectorBuffer&, bool = false);
  10051. bool LoadXML(const XMLElement&, bool = false);
  10052. void MarkNetworkUpdate() const;
  10053. void Remove();
  10054. void RemoveInstanceDefault();
  10055. void ResetToDefault();
  10056. bool Save(File) const;
  10057. bool Save(VectorBuffer&) const;
  10058. bool SaveXML(XMLElement&) const;
  10059. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10060. bool SetAttribute(const String&, const Variant&);
  10061. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  10062. void SetAttributeAnimationSpeed(const String&, float);
  10063. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  10064. const String& GetProperty(const String&) const;
  10065. // Properties:
  10066. bool animationEnabled;
  10067. /* readonly */
  10068. Array<Variant> attributeDefaults;
  10069. /* readonly */
  10070. Array<AttributeInfo> attributeInfos;
  10071. Array<Variant> attributes;
  10072. /* readonly */
  10073. StringHash baseType;
  10074. /* readonly */
  10075. String category;
  10076. int drawOrder;
  10077. bool enabled;
  10078. /* readonly */
  10079. bool enabledEffective;
  10080. /* readonly */
  10081. int height;
  10082. /* readonly */
  10083. uint id;
  10084. /* readonly */
  10085. Node imageNode;
  10086. /* readonly */
  10087. TileMapLayerType2D layerType;
  10088. /* readonly */
  10089. Node node;
  10090. /* readonly */
  10091. uint numAttributes;
  10092. /* readonly */
  10093. uint numObjects;
  10094. ObjectAnimation objectAnimation;
  10095. /* readonly */
  10096. int refs;
  10097. bool temporary;
  10098. /* readonly */
  10099. StringHash type;
  10100. /* readonly */
  10101. String typeName;
  10102. bool visible;
  10103. /* readonly */
  10104. int weakRefs;
  10105. /* readonly */
  10106. int width;
  10107. };
  10108. class TileMapObject2D
  10109. {
  10110. // Methods:
  10111. bool HasProperty(const String&) const;
  10112. const String& GetProperty(const String&) const;
  10113. const Vector2& GetPoint(uint) const;
  10114. // Properties:
  10115. /* readonly */
  10116. String name;
  10117. /* readonly */
  10118. uint numPoints;
  10119. /* readonly */
  10120. TileObjectType2D objectType;
  10121. /* readonly */
  10122. Vector2 position;
  10123. /* readonly */
  10124. int refs;
  10125. /* readonly */
  10126. Vector2 size;
  10127. /* readonly */
  10128. int tileGid;
  10129. /* readonly */
  10130. Sprite2D tileSprite;
  10131. /* readonly */
  10132. String type;
  10133. /* readonly */
  10134. int weakRefs;
  10135. };
  10136. class Time
  10137. {
  10138. // Methods:
  10139. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10140. // Properties:
  10141. /* readonly */
  10142. StringHash baseType;
  10143. /* readonly */
  10144. String category;
  10145. /* readonly */
  10146. float elapsedTime;
  10147. /* readonly */
  10148. uint frameNumber;
  10149. /* readonly */
  10150. int refs;
  10151. /* readonly */
  10152. uint systemTime;
  10153. /* readonly */
  10154. uint timeSinceEpoch;
  10155. /* readonly */
  10156. String timeStamp;
  10157. /* readonly */
  10158. float timeStep;
  10159. /* readonly */
  10160. StringHash type;
  10161. /* readonly */
  10162. String typeName;
  10163. /* readonly */
  10164. int weakRefs;
  10165. };
  10166. class Timer
  10167. {
  10168. // Methods:
  10169. uint GetMSec(bool);
  10170. void Reset();
  10171. };
  10172. class TmxFile2D
  10173. {
  10174. // Methods:
  10175. bool Load(File);
  10176. bool Load(VectorBuffer&);
  10177. bool Save(File) const;
  10178. bool Save(VectorBuffer&) const;
  10179. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10180. // Properties:
  10181. /* readonly */
  10182. StringHash baseType;
  10183. /* readonly */
  10184. String category;
  10185. /* readonly */
  10186. uint memoryUse;
  10187. String name;
  10188. /* readonly */
  10189. int refs;
  10190. /* readonly */
  10191. StringHash type;
  10192. /* readonly */
  10193. String typeName;
  10194. /* readonly */
  10195. uint useTimer;
  10196. /* readonly */
  10197. int weakRefs;
  10198. };
  10199. class ToolTip
  10200. {
  10201. // Methods:
  10202. void AddChild(UIElement);
  10203. void ApplyAttributes();
  10204. void BringToFront();
  10205. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  10206. void DisableLayoutUpdate();
  10207. IntVector2 ElementToScreen(const IntVector2&);
  10208. void EnableLayoutUpdate();
  10209. uint FindChild(UIElement) const;
  10210. Variant GetAttribute(const String&) const;
  10211. ValueAnimation GetAttributeAnimation(const String&) const;
  10212. float GetAttributeAnimationSpeed(const String&) const;
  10213. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  10214. Variant GetAttributeDefault(const String&) const;
  10215. UIElement GetChild(const String&, bool = false) const;
  10216. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  10217. Array<UIElement> GetChildren(bool = false) const;
  10218. UIElement GetElementEventSender() const;
  10219. uint GetNumChildren(bool) const;
  10220. void InsertChild(uint, UIElement);
  10221. bool IsInside(IntVector2, bool);
  10222. bool IsInsideCombined(IntVector2, bool);
  10223. bool Load(File, bool = false);
  10224. bool Load(VectorBuffer&, bool = false);
  10225. bool LoadChildXML(XMLFile, XMLFile = null);
  10226. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  10227. bool LoadXML(File);
  10228. bool LoadXML(VectorBuffer&);
  10229. bool LoadXML(XMLFile, XMLFile);
  10230. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  10231. bool LoadXML(const XMLElement&, bool = false);
  10232. void MarkNetworkUpdate() const;
  10233. void Remove();
  10234. void RemoveAllChildren();
  10235. void RemoveChild(UIElement, uint = 0);
  10236. void RemoveChild(uint);
  10237. void RemoveInstanceDefault();
  10238. void ResetDeepEnabled();
  10239. void ResetToDefault();
  10240. bool Save(File) const;
  10241. bool Save(VectorBuffer&) const;
  10242. bool SaveXML(File);
  10243. bool SaveXML(VectorBuffer&);
  10244. bool SaveXML(XMLElement&) const;
  10245. IntVector2 ScreenToElement(const IntVector2&);
  10246. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10247. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  10248. bool SetAttribute(const String&, const Variant&);
  10249. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  10250. void SetAttributeAnimationSpeed(const String&, float);
  10251. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  10252. void SetDeepEnabled(bool);
  10253. void SetEnabledRecursive(bool);
  10254. void SetFixedHeight(int);
  10255. void SetFixedSize(int, int);
  10256. void SetFixedWidth(int);
  10257. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  10258. void SetMaxSize(int, int);
  10259. void SetMinSize(int, int);
  10260. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  10261. void SetPosition(int, int);
  10262. void SetSize(int, int);
  10263. bool SetStyle(const String&, XMLFile = null);
  10264. bool SetStyle(const XMLElement&);
  10265. bool SetStyleAuto(XMLFile = null);
  10266. void UpdateLayout();
  10267. const Variant& GetVar(const StringHash&);
  10268. // Properties:
  10269. bool animationEnabled;
  10270. /* readonly */
  10271. Array<Variant> attributeDefaults;
  10272. /* readonly */
  10273. Array<AttributeInfo> attributeInfos;
  10274. Array<Variant> attributes;
  10275. /* readonly */
  10276. StringHash baseType;
  10277. bool bringToBack;
  10278. bool bringToFront;
  10279. /* readonly */
  10280. String category;
  10281. /* readonly */
  10282. IntVector2 childOffset;
  10283. /* readonly */
  10284. Array<UIElement> children;
  10285. IntRect clipBorder;
  10286. bool clipChildren;
  10287. /* writeonly */
  10288. Color color;
  10289. /* readonly */
  10290. bool colorGradient;
  10291. Array<Color> colors;
  10292. /* readonly */
  10293. IntRect combinedScreenRect;
  10294. XMLFile defaultStyle;
  10295. float delay;
  10296. /* readonly */
  10297. float derivedOpacity;
  10298. /* readonly */
  10299. uint dragButtonCombo;
  10300. /* readonly */
  10301. int dragButtonCount;
  10302. uint dragDropMode;
  10303. bool editable;
  10304. bool elementEventSender;
  10305. bool enabled;
  10306. /* readonly */
  10307. bool enabledSelf;
  10308. /* readonly */
  10309. bool fixedHeight;
  10310. /* readonly */
  10311. bool fixedSize;
  10312. /* readonly */
  10313. bool fixedWidth;
  10314. bool focus;
  10315. FocusMode focusMode;
  10316. int height;
  10317. HorizontalAlignment horizontalAlignment;
  10318. /* readonly */
  10319. bool hovering;
  10320. int indent;
  10321. int indentSpacing;
  10322. /* readonly */
  10323. int indentWidth;
  10324. bool internal;
  10325. IntRect layoutBorder;
  10326. Vector2 layoutFlexScale;
  10327. LayoutMode layoutMode;
  10328. int layoutSpacing;
  10329. int maxHeight;
  10330. IntVector2 maxSize;
  10331. int maxWidth;
  10332. int minHeight;
  10333. IntVector2 minSize;
  10334. int minWidth;
  10335. String name;
  10336. /* readonly */
  10337. uint numAllChildren;
  10338. /* readonly */
  10339. uint numAttributes;
  10340. /* readonly */
  10341. uint numChildren;
  10342. ObjectAnimation objectAnimation;
  10343. float opacity;
  10344. UIElement parent;
  10345. IntVector2 position;
  10346. int priority;
  10347. /* readonly */
  10348. int refs;
  10349. /* readonly */
  10350. UIElement root;
  10351. /* readonly */
  10352. IntVector2 screenPosition;
  10353. bool selected;
  10354. IntVector2 size;
  10355. bool sortChildren;
  10356. String style;
  10357. bool temporary;
  10358. TraversalMode traversalMode;
  10359. /* readonly */
  10360. StringHash type;
  10361. /* readonly */
  10362. String typeName;
  10363. bool useDerivedOpacity;
  10364. /* readonly */
  10365. VariantMap vars;
  10366. VerticalAlignment verticalAlignment;
  10367. bool visible;
  10368. /* readonly */
  10369. int weakRefs;
  10370. int width;
  10371. };
  10372. class TouchState
  10373. {
  10374. // Properties:
  10375. IntVector2 delta;
  10376. IntVector2 lastPosition;
  10377. IntVector2 position;
  10378. float pressure;
  10379. int touchID;
  10380. /* readonly */
  10381. UIElement touchedElement;
  10382. };
  10383. class UI
  10384. {
  10385. // Methods:
  10386. void Clear();
  10387. void DebugDraw(UIElement);
  10388. UIElement GetElementAt(const IntVector2&, bool = true);
  10389. UIElement GetElementAt(int, int, bool = true);
  10390. bool HasModalElement() const;
  10391. bool IsDragging() const;
  10392. UIElement LoadLayout(File);
  10393. UIElement LoadLayout(File, XMLFile);
  10394. UIElement LoadLayout(VectorBuffer&);
  10395. UIElement LoadLayout(VectorBuffer&, XMLFile);
  10396. UIElement LoadLayout(XMLFile);
  10397. UIElement LoadLayout(XMLFile, XMLFile);
  10398. bool SaveLayout(File, UIElement);
  10399. bool SaveLayout(VectorBuffer&, UIElement);
  10400. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10401. void SetFocusElement(UIElement, bool = false);
  10402. const Array<UIElement> GetDragElements();
  10403. // Properties:
  10404. /* readonly */
  10405. StringHash baseType;
  10406. /* readonly */
  10407. String category;
  10408. String clipBoardText;
  10409. Cursor cursor;
  10410. /* readonly */
  10411. IntVector2 cursorPosition;
  10412. float defaultToolTipDelay;
  10413. float doubleClickInterval;
  10414. int dragBeginDistance;
  10415. float dragBeginInterval;
  10416. UIElement focusElement;
  10417. bool forceAutoHint;
  10418. /* readonly */
  10419. UIElement frontElement;
  10420. int maxFontTextureSize;
  10421. /* readonly */
  10422. UIElement modalRoot;
  10423. bool nonFocusedMouseWheel;
  10424. /* readonly */
  10425. int refs;
  10426. /* readonly */
  10427. UIElement root;
  10428. /* readonly */
  10429. StringHash type;
  10430. /* readonly */
  10431. String typeName;
  10432. bool useMutableGlyphs;
  10433. bool useScreenKeyboard;
  10434. bool useSystemClipboard;
  10435. /* readonly */
  10436. int weakRefs;
  10437. };
  10438. class UIElement
  10439. {
  10440. // Methods:
  10441. void AddChild(UIElement);
  10442. void ApplyAttributes();
  10443. void BringToFront();
  10444. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  10445. void DisableLayoutUpdate();
  10446. IntVector2 ElementToScreen(const IntVector2&);
  10447. void EnableLayoutUpdate();
  10448. uint FindChild(UIElement) const;
  10449. Variant GetAttribute(const String&) const;
  10450. ValueAnimation GetAttributeAnimation(const String&) const;
  10451. float GetAttributeAnimationSpeed(const String&) const;
  10452. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  10453. Variant GetAttributeDefault(const String&) const;
  10454. UIElement GetChild(const String&, bool = false) const;
  10455. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  10456. Array<UIElement> GetChildren(bool = false) const;
  10457. UIElement GetElementEventSender() const;
  10458. uint GetNumChildren(bool) const;
  10459. void InsertChild(uint, UIElement);
  10460. bool IsInside(IntVector2, bool);
  10461. bool IsInsideCombined(IntVector2, bool);
  10462. bool Load(File, bool = false);
  10463. bool Load(VectorBuffer&, bool = false);
  10464. bool LoadChildXML(XMLFile, XMLFile = null);
  10465. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  10466. bool LoadXML(File);
  10467. bool LoadXML(VectorBuffer&);
  10468. bool LoadXML(XMLFile, XMLFile);
  10469. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  10470. bool LoadXML(const XMLElement&, bool = false);
  10471. void MarkNetworkUpdate() const;
  10472. void Remove();
  10473. void RemoveAllChildren();
  10474. void RemoveChild(UIElement, uint = 0);
  10475. void RemoveChild(uint);
  10476. void RemoveInstanceDefault();
  10477. void ResetDeepEnabled();
  10478. void ResetToDefault();
  10479. bool Save(File) const;
  10480. bool Save(VectorBuffer&) const;
  10481. bool SaveXML(File);
  10482. bool SaveXML(VectorBuffer&);
  10483. bool SaveXML(XMLElement&) const;
  10484. IntVector2 ScreenToElement(const IntVector2&);
  10485. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10486. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  10487. bool SetAttribute(const String&, const Variant&);
  10488. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  10489. void SetAttributeAnimationSpeed(const String&, float);
  10490. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  10491. void SetDeepEnabled(bool);
  10492. void SetEnabledRecursive(bool);
  10493. void SetFixedHeight(int);
  10494. void SetFixedSize(int, int);
  10495. void SetFixedWidth(int);
  10496. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  10497. void SetMaxSize(int, int);
  10498. void SetMinSize(int, int);
  10499. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  10500. void SetPosition(int, int);
  10501. void SetSize(int, int);
  10502. bool SetStyle(const String&, XMLFile = null);
  10503. bool SetStyle(const XMLElement&);
  10504. bool SetStyleAuto(XMLFile = null);
  10505. void UpdateLayout();
  10506. const Variant& GetVar(const StringHash&);
  10507. // Properties:
  10508. bool animationEnabled;
  10509. /* readonly */
  10510. Array<Variant> attributeDefaults;
  10511. /* readonly */
  10512. Array<AttributeInfo> attributeInfos;
  10513. Array<Variant> attributes;
  10514. /* readonly */
  10515. StringHash baseType;
  10516. bool bringToBack;
  10517. bool bringToFront;
  10518. /* readonly */
  10519. String category;
  10520. /* readonly */
  10521. IntVector2 childOffset;
  10522. /* readonly */
  10523. Array<UIElement> children;
  10524. IntRect clipBorder;
  10525. bool clipChildren;
  10526. /* writeonly */
  10527. Color color;
  10528. /* readonly */
  10529. bool colorGradient;
  10530. Array<Color> colors;
  10531. /* readonly */
  10532. IntRect combinedScreenRect;
  10533. XMLFile defaultStyle;
  10534. /* readonly */
  10535. float derivedOpacity;
  10536. /* readonly */
  10537. uint dragButtonCombo;
  10538. /* readonly */
  10539. int dragButtonCount;
  10540. uint dragDropMode;
  10541. bool editable;
  10542. bool elementEventSender;
  10543. bool enabled;
  10544. /* readonly */
  10545. bool enabledSelf;
  10546. /* readonly */
  10547. bool fixedHeight;
  10548. /* readonly */
  10549. bool fixedSize;
  10550. /* readonly */
  10551. bool fixedWidth;
  10552. bool focus;
  10553. FocusMode focusMode;
  10554. int height;
  10555. HorizontalAlignment horizontalAlignment;
  10556. /* readonly */
  10557. bool hovering;
  10558. int indent;
  10559. int indentSpacing;
  10560. /* readonly */
  10561. int indentWidth;
  10562. bool internal;
  10563. IntRect layoutBorder;
  10564. Vector2 layoutFlexScale;
  10565. LayoutMode layoutMode;
  10566. int layoutSpacing;
  10567. int maxHeight;
  10568. IntVector2 maxSize;
  10569. int maxWidth;
  10570. int minHeight;
  10571. IntVector2 minSize;
  10572. int minWidth;
  10573. String name;
  10574. /* readonly */
  10575. uint numAllChildren;
  10576. /* readonly */
  10577. uint numAttributes;
  10578. /* readonly */
  10579. uint numChildren;
  10580. ObjectAnimation objectAnimation;
  10581. float opacity;
  10582. UIElement parent;
  10583. IntVector2 position;
  10584. int priority;
  10585. /* readonly */
  10586. int refs;
  10587. /* readonly */
  10588. UIElement root;
  10589. /* readonly */
  10590. IntVector2 screenPosition;
  10591. bool selected;
  10592. IntVector2 size;
  10593. bool sortChildren;
  10594. String style;
  10595. bool temporary;
  10596. TraversalMode traversalMode;
  10597. /* readonly */
  10598. StringHash type;
  10599. /* readonly */
  10600. String typeName;
  10601. bool useDerivedOpacity;
  10602. /* readonly */
  10603. VariantMap vars;
  10604. VerticalAlignment verticalAlignment;
  10605. bool visible;
  10606. /* readonly */
  10607. int weakRefs;
  10608. int width;
  10609. };
  10610. class ValueAnimation
  10611. {
  10612. // Methods:
  10613. bool Load(File);
  10614. bool Load(VectorBuffer&);
  10615. bool Save(File) const;
  10616. bool Save(VectorBuffer&) const;
  10617. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10618. void SetEventFrame(float, const String&, const VariantMap& = VariantMap ( ));
  10619. void SetKeyFrame(float, const Variant&);
  10620. // Properties:
  10621. /* readonly */
  10622. StringHash baseType;
  10623. /* readonly */
  10624. String category;
  10625. InterpMethod interpolationMethod;
  10626. /* readonly */
  10627. uint memoryUse;
  10628. String name;
  10629. /* readonly */
  10630. int refs;
  10631. float splineTension;
  10632. /* readonly */
  10633. StringHash type;
  10634. /* readonly */
  10635. String typeName;
  10636. /* readonly */
  10637. uint useTimer;
  10638. VariantType valueType;
  10639. /* readonly */
  10640. int weakRefs;
  10641. };
  10642. class Variant
  10643. {
  10644. // Methods:
  10645. void Clear();
  10646. const Color& GetColor() const;
  10647. void FromString(VariantType, const String&);
  10648. void FromString(const String&, const String&);
  10649. bool GetBool() const;
  10650. VectorBuffer GetBuffer() const;
  10651. float GetFloat() const;
  10652. int GetInt() const;
  10653. RefCounted GetPtr() const;
  10654. ScriptObject GetScriptObject() const;
  10655. StringHash GetStringHash() const;
  10656. uint GetUInt() const;
  10657. Array<Variant> GetVariantVector() const;
  10658. const IntRect& GetIntRect() const;
  10659. const IntVector2& GetIntVector2() const;
  10660. const Matrix3& GetMatrix3() const;
  10661. const Matrix3x4& GetMatrix3x4() const;
  10662. const Matrix4& GetMatrix4() const;
  10663. const Quaternion& GetQuaternion() const;
  10664. const ResourceRef& GetResourceRef() const;
  10665. const ResourceRefList& GetResourceRefList() const;
  10666. const String& GetString() const;
  10667. String ToString() const;
  10668. const VariantMap& GetVariantMap() const;
  10669. const Vector2& GetVector2() const;
  10670. const Vector3& GetVector3() const;
  10671. const Vector4& GetVector4() const;
  10672. // Properties:
  10673. /* readonly */
  10674. bool empty;
  10675. /* readonly */
  10676. VariantType type;
  10677. /* readonly */
  10678. String typeName;
  10679. /* readonly */
  10680. bool zero;
  10681. };
  10682. class VariantMap
  10683. {
  10684. // Methods:
  10685. void Clear();
  10686. bool Contains(StringHash) const;
  10687. bool Contains(const String&) const;
  10688. bool Erase(StringHash);
  10689. bool Erase(const String&);
  10690. // Properties:
  10691. /* readonly */
  10692. Array<StringHash> keys;
  10693. /* readonly */
  10694. uint length;
  10695. /* readonly */
  10696. Array<Variant> values;
  10697. };
  10698. class Vector2
  10699. {
  10700. // Methods:
  10701. float AbsDotProduct(const Vector2&) const;
  10702. float DotProduct(const Vector2&) const;
  10703. bool Equals(const Vector2&) const;
  10704. bool IsNaN() const;
  10705. Vector2 Lerp(const Vector2&, float) const;
  10706. void Normalize();
  10707. Vector2 Normalized() const;
  10708. String ToString() const;
  10709. // Properties:
  10710. /* readonly */
  10711. Array<float> data;
  10712. /* readonly */
  10713. float length;
  10714. /* readonly */
  10715. float lengthSquared;
  10716. float x;
  10717. float y;
  10718. };
  10719. class Vector3
  10720. {
  10721. // Methods:
  10722. float AbsDotProduct(const Vector3&) const;
  10723. float Angle(const Vector3&) const;
  10724. Vector3 CrossProduct(const Vector3&) const;
  10725. float DotProduct(const Vector3&) const;
  10726. bool Equals(const Vector3&) const;
  10727. bool IsNaN() const;
  10728. Vector3 Lerp(const Vector3&, float) const;
  10729. void Normalize();
  10730. Vector3 Normalized() const;
  10731. String ToString() const;
  10732. // Properties:
  10733. /* readonly */
  10734. Array<float> data;
  10735. /* readonly */
  10736. float length;
  10737. /* readonly */
  10738. float lengthSquared;
  10739. float x;
  10740. float y;
  10741. float z;
  10742. };
  10743. class Vector4
  10744. {
  10745. // Methods:
  10746. float AbsDotProduct(const Vector4&) const;
  10747. float DotProduct(const Vector4&) const;
  10748. bool Equals(const Vector4&) const;
  10749. bool IsNaN() const;
  10750. Vector4 Lerp(const Vector4&, float) const;
  10751. String ToString() const;
  10752. // Properties:
  10753. /* readonly */
  10754. Array<float> data;
  10755. float w;
  10756. float x;
  10757. float y;
  10758. float z;
  10759. };
  10760. class VectorBuffer
  10761. {
  10762. // Methods:
  10763. void Clear();
  10764. Array<uint8> Read(uint);
  10765. bool ReadBool();
  10766. BoundingBox ReadBoundingBox();
  10767. int8 ReadByte();
  10768. Color ReadColor();
  10769. String ReadFileID();
  10770. float ReadFloat();
  10771. int ReadInt();
  10772. IntRect ReadIntRect();
  10773. IntVector2 ReadIntVector2();
  10774. String ReadLine();
  10775. Matrix3 ReadMatrix3();
  10776. Matrix3x4 ReadMatrix3x4();
  10777. Matrix4 ReadMatrix4();
  10778. uint ReadNetID();
  10779. Quaternion ReadPackedQuaternion();
  10780. Vector3 ReadPackedVector3(float);
  10781. Quaternion ReadQuaternion();
  10782. int16 ReadShort();
  10783. String ReadString();
  10784. StringHash ReadStringHash();
  10785. uint8 ReadUByte();
  10786. uint ReadUInt();
  10787. uint16 ReadUShort();
  10788. uint ReadVLE();
  10789. Variant ReadVariant();
  10790. VariantMap ReadVariantMap();
  10791. Vector2 ReadVector2();
  10792. Vector3 ReadVector3();
  10793. Vector4 ReadVector4();
  10794. VectorBuffer ReadVectorBuffer(uint);
  10795. void Resize(uint);
  10796. uint Seek(uint);
  10797. void SetData(Deserializer, uint);
  10798. uint Write(Array<uint8>);
  10799. bool WriteBool(bool);
  10800. bool WriteBoundingBox(const BoundingBox&);
  10801. bool WriteByte(int8);
  10802. bool WriteColor(const Color&);
  10803. bool WriteFileID(const String&);
  10804. bool WriteFloat(float);
  10805. bool WriteInt(int);
  10806. bool WriteIntRect(const IntRect&);
  10807. bool WriteIntVector2(const IntVector2&);
  10808. bool WriteLine(const String&);
  10809. bool WriteMatrix3(const Matrix3&);
  10810. bool WriteMatrix3x4(const Matrix3x4&);
  10811. bool WriteMatrix4(const Matrix4&);
  10812. bool WriteNetID(uint);
  10813. bool WritePackedQuaternion(const Quaternion&);
  10814. bool WritePackedVector3(const Vector3&, float);
  10815. bool WriteQuaternion(const Quaternion&);
  10816. bool WriteShort(int16);
  10817. bool WriteString(const String&);
  10818. bool WriteStringHash(const StringHash&);
  10819. bool WriteUByte(uint8);
  10820. bool WriteUInt(uint);
  10821. bool WriteUShort(uint16);
  10822. bool WriteVLE(uint);
  10823. bool WriteVariant(const Variant&);
  10824. bool WriteVariantMap(const VariantMap&);
  10825. bool WriteVector2(const Vector2&);
  10826. bool WriteVector3(const Vector3&);
  10827. bool WriteVector4(const Vector4&);
  10828. bool WriteVectorBuffer(const VectorBuffer&);
  10829. // Properties:
  10830. /* readonly */
  10831. uint checksum;
  10832. /* readonly */
  10833. bool eof;
  10834. /* readonly */
  10835. String name;
  10836. /* readonly */
  10837. uint position;
  10838. /* readonly */
  10839. uint size;
  10840. };
  10841. class View3D
  10842. {
  10843. // Methods:
  10844. void AddChild(UIElement);
  10845. void ApplyAttributes();
  10846. void BringToFront();
  10847. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  10848. void DisableLayoutUpdate();
  10849. IntVector2 ElementToScreen(const IntVector2&);
  10850. void EnableLayoutUpdate();
  10851. uint FindChild(UIElement) const;
  10852. Variant GetAttribute(const String&) const;
  10853. ValueAnimation GetAttributeAnimation(const String&) const;
  10854. float GetAttributeAnimationSpeed(const String&) const;
  10855. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  10856. Variant GetAttributeDefault(const String&) const;
  10857. UIElement GetChild(const String&, bool = false) const;
  10858. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  10859. Array<UIElement> GetChildren(bool = false) const;
  10860. UIElement GetElementEventSender() const;
  10861. uint GetNumChildren(bool) const;
  10862. void InsertChild(uint, UIElement);
  10863. bool IsInside(IntVector2, bool);
  10864. bool IsInsideCombined(IntVector2, bool);
  10865. bool Load(File, bool = false);
  10866. bool Load(VectorBuffer&, bool = false);
  10867. bool LoadChildXML(XMLFile, XMLFile = null);
  10868. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  10869. bool LoadXML(File);
  10870. bool LoadXML(VectorBuffer&);
  10871. bool LoadXML(XMLFile, XMLFile);
  10872. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  10873. bool LoadXML(const XMLElement&, bool = false);
  10874. void MarkNetworkUpdate() const;
  10875. void QueueUpdate();
  10876. void Remove();
  10877. void RemoveAllChildren();
  10878. void RemoveChild(UIElement, uint = 0);
  10879. void RemoveChild(uint);
  10880. void RemoveInstanceDefault();
  10881. void ResetDeepEnabled();
  10882. void ResetToDefault();
  10883. bool Save(File) const;
  10884. bool Save(VectorBuffer&) const;
  10885. bool SaveXML(File);
  10886. bool SaveXML(VectorBuffer&);
  10887. bool SaveXML(XMLElement&) const;
  10888. IntVector2 ScreenToElement(const IntVector2&);
  10889. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  10890. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  10891. bool SetAttribute(const String&, const Variant&);
  10892. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  10893. void SetAttributeAnimationSpeed(const String&, float);
  10894. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  10895. void SetDeepEnabled(bool);
  10896. void SetEnabledRecursive(bool);
  10897. void SetFixedHeight(int);
  10898. void SetFixedSize(int, int);
  10899. void SetFixedWidth(int);
  10900. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  10901. void SetMaxSize(int, int);
  10902. void SetMinSize(int, int);
  10903. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  10904. void SetPosition(int, int);
  10905. void SetSize(int, int);
  10906. bool SetStyle(const String&, XMLFile = null);
  10907. bool SetStyle(const XMLElement&);
  10908. bool SetStyleAuto(XMLFile = null);
  10909. void SetView(Scene, Camera, bool = true);
  10910. void UpdateLayout();
  10911. const Variant& GetVar(const StringHash&);
  10912. // Properties:
  10913. bool animationEnabled;
  10914. /* readonly */
  10915. Array<Variant> attributeDefaults;
  10916. /* readonly */
  10917. Array<AttributeInfo> attributeInfos;
  10918. Array<Variant> attributes;
  10919. bool autoUpdate;
  10920. /* readonly */
  10921. StringHash baseType;
  10922. bool bringToBack;
  10923. bool bringToFront;
  10924. /* readonly */
  10925. Node cameraNode;
  10926. /* readonly */
  10927. String category;
  10928. /* readonly */
  10929. IntVector2 childOffset;
  10930. /* readonly */
  10931. Array<UIElement> children;
  10932. IntRect clipBorder;
  10933. bool clipChildren;
  10934. /* writeonly */
  10935. Color color;
  10936. /* readonly */
  10937. bool colorGradient;
  10938. Array<Color> colors;
  10939. /* readonly */
  10940. IntRect combinedScreenRect;
  10941. XMLFile defaultStyle;
  10942. /* readonly */
  10943. Texture2D depthTexture;
  10944. /* readonly */
  10945. float derivedOpacity;
  10946. /* readonly */
  10947. uint dragButtonCombo;
  10948. /* readonly */
  10949. int dragButtonCount;
  10950. uint dragDropMode;
  10951. bool editable;
  10952. bool elementEventSender;
  10953. bool enabled;
  10954. /* readonly */
  10955. bool enabledSelf;
  10956. /* readonly */
  10957. bool fixedHeight;
  10958. bool fixedHeightResizing;
  10959. /* readonly */
  10960. bool fixedSize;
  10961. /* readonly */
  10962. bool fixedWidth;
  10963. bool fixedWidthResizing;
  10964. bool focus;
  10965. FocusMode focusMode;
  10966. uint format;
  10967. int height;
  10968. HorizontalAlignment horizontalAlignment;
  10969. /* readonly */
  10970. bool hovering;
  10971. int indent;
  10972. int indentSpacing;
  10973. /* readonly */
  10974. int indentWidth;
  10975. bool internal;
  10976. IntRect layoutBorder;
  10977. Vector2 layoutFlexScale;
  10978. LayoutMode layoutMode;
  10979. int layoutSpacing;
  10980. int maxHeight;
  10981. IntVector2 maxSize;
  10982. int maxWidth;
  10983. int minHeight;
  10984. IntVector2 minSize;
  10985. int minWidth;
  10986. bool modal;
  10987. bool modalAutoDismiss;
  10988. Color modalFrameColor;
  10989. IntVector2 modalFrameSize;
  10990. Color modalShadeColor;
  10991. bool movable;
  10992. String name;
  10993. /* readonly */
  10994. uint numAllChildren;
  10995. /* readonly */
  10996. uint numAttributes;
  10997. /* readonly */
  10998. uint numChildren;
  10999. ObjectAnimation objectAnimation;
  11000. float opacity;
  11001. UIElement parent;
  11002. IntVector2 position;
  11003. int priority;
  11004. /* readonly */
  11005. int refs;
  11006. /* readonly */
  11007. Texture2D renderTexture;
  11008. bool resizable;
  11009. IntRect resizeBorder;
  11010. /* readonly */
  11011. UIElement root;
  11012. /* readonly */
  11013. Scene scene;
  11014. /* readonly */
  11015. IntVector2 screenPosition;
  11016. bool selected;
  11017. IntVector2 size;
  11018. bool sortChildren;
  11019. String style;
  11020. bool temporary;
  11021. TraversalMode traversalMode;
  11022. /* readonly */
  11023. StringHash type;
  11024. /* readonly */
  11025. String typeName;
  11026. bool useDerivedOpacity;
  11027. /* readonly */
  11028. VariantMap vars;
  11029. VerticalAlignment verticalAlignment;
  11030. /* readonly */
  11031. Viewport viewport;
  11032. bool visible;
  11033. /* readonly */
  11034. int weakRefs;
  11035. int width;
  11036. };
  11037. class Viewport
  11038. {
  11039. // Methods:
  11040. Ray GetScreenRay(int, int) const;
  11041. Vector3 ScreenToWorldPoint(int, int, float) const;
  11042. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  11043. void SetRenderPath(XMLFile);
  11044. Vector2 WorldToScreenPoint(const Vector3&) const;
  11045. // Properties:
  11046. /* readonly */
  11047. StringHash baseType;
  11048. Camera camera;
  11049. /* readonly */
  11050. String category;
  11051. bool drawDebug;
  11052. IntRect rect;
  11053. /* readonly */
  11054. int refs;
  11055. RenderPath renderPath;
  11056. Scene scene;
  11057. /* readonly */
  11058. StringHash type;
  11059. /* readonly */
  11060. String typeName;
  11061. /* readonly */
  11062. int weakRefs;
  11063. };
  11064. class WeakHandle
  11065. {
  11066. // Methods:
  11067. RefCounted Get() const;
  11068. // Properties:
  11069. /* readonly */
  11070. bool expired;
  11071. /* readonly */
  11072. int refs;
  11073. /* readonly */
  11074. int weakRefs;
  11075. };
  11076. class Window
  11077. {
  11078. // Methods:
  11079. void AddChild(UIElement);
  11080. void ApplyAttributes();
  11081. void BringToFront();
  11082. UIElement CreateChild(const String&, const String& = String ( ), uint = M_MAX_UNSIGNED);
  11083. void DisableLayoutUpdate();
  11084. IntVector2 ElementToScreen(const IntVector2&);
  11085. void EnableLayoutUpdate();
  11086. uint FindChild(UIElement) const;
  11087. Variant GetAttribute(const String&) const;
  11088. ValueAnimation GetAttributeAnimation(const String&) const;
  11089. float GetAttributeAnimationSpeed(const String&) const;
  11090. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  11091. Variant GetAttributeDefault(const String&) const;
  11092. UIElement GetChild(const String&, bool = false) const;
  11093. UIElement GetChild(const StringHash&, const Variant& = Variant ( ), bool = false) const;
  11094. Array<UIElement> GetChildren(bool = false) const;
  11095. UIElement GetElementEventSender() const;
  11096. uint GetNumChildren(bool) const;
  11097. void InsertChild(uint, UIElement);
  11098. bool IsInside(IntVector2, bool);
  11099. bool IsInsideCombined(IntVector2, bool);
  11100. bool Load(File, bool = false);
  11101. bool Load(VectorBuffer&, bool = false);
  11102. bool LoadChildXML(XMLFile, XMLFile = null);
  11103. bool LoadChildXML(const XMLElement&, XMLFile = null, bool = false);
  11104. bool LoadXML(File);
  11105. bool LoadXML(VectorBuffer&);
  11106. bool LoadXML(XMLFile, XMLFile);
  11107. bool LoadXML(const XMLElement&, XMLFile, bool = false);
  11108. bool LoadXML(const XMLElement&, bool = false);
  11109. void MarkNetworkUpdate() const;
  11110. void Remove();
  11111. void RemoveAllChildren();
  11112. void RemoveChild(UIElement, uint = 0);
  11113. void RemoveChild(uint);
  11114. void RemoveInstanceDefault();
  11115. void ResetDeepEnabled();
  11116. void ResetToDefault();
  11117. bool Save(File) const;
  11118. bool Save(VectorBuffer&) const;
  11119. bool SaveXML(File);
  11120. bool SaveXML(VectorBuffer&);
  11121. bool SaveXML(XMLElement&) const;
  11122. IntVector2 ScreenToElement(const IntVector2&);
  11123. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  11124. void SetAlignment(HorizontalAlignment, VerticalAlignment);
  11125. bool SetAttribute(const String&, const Variant&);
  11126. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  11127. void SetAttributeAnimationSpeed(const String&, float);
  11128. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  11129. void SetDeepEnabled(bool);
  11130. void SetEnabledRecursive(bool);
  11131. void SetFixedHeight(int);
  11132. void SetFixedSize(int, int);
  11133. void SetFixedWidth(int);
  11134. void SetLayout(LayoutMode, int = 0, const IntRect& = IntRect ( 0 , 0 , 0 , 0 ));
  11135. void SetMaxSize(int, int);
  11136. void SetMinSize(int, int);
  11137. void SetParent(UIElement, uint = M_MAX_UNSIGNED);
  11138. void SetPosition(int, int);
  11139. void SetSize(int, int);
  11140. bool SetStyle(const String&, XMLFile = null);
  11141. bool SetStyle(const XMLElement&);
  11142. bool SetStyleAuto(XMLFile = null);
  11143. void UpdateLayout();
  11144. const Variant& GetVar(const StringHash&);
  11145. // Properties:
  11146. bool animationEnabled;
  11147. /* readonly */
  11148. Array<Variant> attributeDefaults;
  11149. /* readonly */
  11150. Array<AttributeInfo> attributeInfos;
  11151. Array<Variant> attributes;
  11152. /* readonly */
  11153. StringHash baseType;
  11154. bool bringToBack;
  11155. bool bringToFront;
  11156. /* readonly */
  11157. String category;
  11158. /* readonly */
  11159. IntVector2 childOffset;
  11160. /* readonly */
  11161. Array<UIElement> children;
  11162. IntRect clipBorder;
  11163. bool clipChildren;
  11164. /* writeonly */
  11165. Color color;
  11166. /* readonly */
  11167. bool colorGradient;
  11168. Array<Color> colors;
  11169. /* readonly */
  11170. IntRect combinedScreenRect;
  11171. XMLFile defaultStyle;
  11172. /* readonly */
  11173. float derivedOpacity;
  11174. /* readonly */
  11175. uint dragButtonCombo;
  11176. /* readonly */
  11177. int dragButtonCount;
  11178. uint dragDropMode;
  11179. bool editable;
  11180. bool elementEventSender;
  11181. bool enabled;
  11182. /* readonly */
  11183. bool enabledSelf;
  11184. /* readonly */
  11185. bool fixedHeight;
  11186. bool fixedHeightResizing;
  11187. /* readonly */
  11188. bool fixedSize;
  11189. /* readonly */
  11190. bool fixedWidth;
  11191. bool fixedWidthResizing;
  11192. bool focus;
  11193. FocusMode focusMode;
  11194. int height;
  11195. HorizontalAlignment horizontalAlignment;
  11196. /* readonly */
  11197. bool hovering;
  11198. int indent;
  11199. int indentSpacing;
  11200. /* readonly */
  11201. int indentWidth;
  11202. bool internal;
  11203. IntRect layoutBorder;
  11204. Vector2 layoutFlexScale;
  11205. LayoutMode layoutMode;
  11206. int layoutSpacing;
  11207. int maxHeight;
  11208. IntVector2 maxSize;
  11209. int maxWidth;
  11210. int minHeight;
  11211. IntVector2 minSize;
  11212. int minWidth;
  11213. bool modal;
  11214. bool modalAutoDismiss;
  11215. Color modalFrameColor;
  11216. IntVector2 modalFrameSize;
  11217. Color modalShadeColor;
  11218. bool movable;
  11219. String name;
  11220. /* readonly */
  11221. uint numAllChildren;
  11222. /* readonly */
  11223. uint numAttributes;
  11224. /* readonly */
  11225. uint numChildren;
  11226. ObjectAnimation objectAnimation;
  11227. float opacity;
  11228. UIElement parent;
  11229. IntVector2 position;
  11230. int priority;
  11231. /* readonly */
  11232. int refs;
  11233. bool resizable;
  11234. IntRect resizeBorder;
  11235. /* readonly */
  11236. UIElement root;
  11237. /* readonly */
  11238. IntVector2 screenPosition;
  11239. bool selected;
  11240. IntVector2 size;
  11241. bool sortChildren;
  11242. String style;
  11243. bool temporary;
  11244. TraversalMode traversalMode;
  11245. /* readonly */
  11246. StringHash type;
  11247. /* readonly */
  11248. String typeName;
  11249. bool useDerivedOpacity;
  11250. /* readonly */
  11251. VariantMap vars;
  11252. VerticalAlignment verticalAlignment;
  11253. bool visible;
  11254. /* readonly */
  11255. int weakRefs;
  11256. int width;
  11257. };
  11258. class XMLElement
  11259. {
  11260. // Methods:
  11261. XMLElement CreateChild(const String&);
  11262. String GetAttribute(const String& = String ( )) const;
  11263. String GetAttributeLower(const String&) const;
  11264. Array<String> GetAttributeNames() const;
  11265. String GetAttributeUpper(const String&) const;
  11266. bool GetBool(const String&) const;
  11267. BoundingBox GetBoundingBox() const;
  11268. XMLElement GetChild(const String& = String ( )) const;
  11269. Color GetColor(const String&) const;
  11270. float GetFloat(const String&) const;
  11271. int GetInt(const String&) const;
  11272. Matrix3 GetMatrix3(const String&) const;
  11273. Matrix3x4 GetMatrix3x4(const String&) const;
  11274. Matrix4 GetMatrix4(const String&) const;
  11275. XMLElement GetNext(const String& = String ( )) const;
  11276. Quaternion GetQuaternion(const String&) const;
  11277. ResourceRef GetResourceRef() const;
  11278. ResourceRefList GetResourceRefList() const;
  11279. uint GetUInt(const String&) const;
  11280. String GetValue() const;
  11281. Variant GetVariant() const;
  11282. VariantMap GetVariantMap() const;
  11283. Array<Variant> GetVariantVector() const;
  11284. Vector2 GetVector2(const String&) const;
  11285. Vector3 GetVector3(const String&) const;
  11286. Vector4 GetVector4(const String&) const;
  11287. Variant GetVectorVariant(const String&) const;
  11288. bool HasAttribute(const String&) const;
  11289. bool HasChild(const String&) const;
  11290. bool RemoveAttribute(const String& = String ( ));
  11291. bool RemoveChild(const String&);
  11292. bool RemoveChild(const XMLElement&);
  11293. bool RemoveChildren(const String& = String ( ));
  11294. XPathResultSet Select(const String&);
  11295. XPathResultSet SelectPrepared(const XPathQuery&);
  11296. XMLElement SelectSingle(const String&);
  11297. XMLElement SelectSinglePrepared(const XPathQuery&);
  11298. bool SetAttribute(const String&);
  11299. bool SetAttribute(const String&, const String&);
  11300. bool SetBool(const String&, bool);
  11301. bool SetBoundingBox(const BoundingBox&);
  11302. bool SetColor(const String&, const Color&);
  11303. bool SetFloat(const String&, float);
  11304. bool SetInt(const String&, int);
  11305. bool SetMatrix3(const String&, const Matrix3&);
  11306. bool SetMatrix3x4(const String&, const Matrix3x4&);
  11307. bool SetMatrix4(const String&, const Matrix4&);
  11308. bool SetQuaternion(const String&, const Quaternion&);
  11309. bool SetResourceRef(const String&, const ResourceRef&);
  11310. bool SetResourceRefList(const String&, const ResourceRefList&);
  11311. bool SetUInt(const String&, uint);
  11312. bool SetValue(const String&);
  11313. bool SetVariant(const Variant&);
  11314. bool SetVariantMap(const VariantMap&);
  11315. bool SetVariantVector(Array<Variant>);
  11316. bool SetVector2(const String&, const Vector2&);
  11317. bool SetVector3(const String&, const Vector3&);
  11318. bool SetVector4(const String&, const Vector4&);
  11319. bool SetVectorVariant(const String&, const Variant&);
  11320. // Properties:
  11321. /* readonly */
  11322. XMLFile file;
  11323. /* readonly */
  11324. bool isNull;
  11325. /* readonly */
  11326. String name;
  11327. /* readonly */
  11328. XMLElement nextResult;
  11329. /* readonly */
  11330. bool notNull;
  11331. /* readonly */
  11332. uint numAttributes;
  11333. /* readonly */
  11334. XMLElement parent;
  11335. String value;
  11336. };
  11337. class XMLFile
  11338. {
  11339. // Methods:
  11340. XMLElement CreateRoot(const String&);
  11341. bool FromString(const String&);
  11342. XMLElement GetRoot(const String& = String ( ));
  11343. bool Load(File);
  11344. bool Load(VectorBuffer&);
  11345. void Patch(XMLElement);
  11346. void Patch(XMLFile);
  11347. bool Save(File) const;
  11348. bool Save(VectorBuffer&) const;
  11349. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  11350. String ToString() const;
  11351. // Properties:
  11352. /* readonly */
  11353. StringHash baseType;
  11354. /* readonly */
  11355. String category;
  11356. /* readonly */
  11357. uint memoryUse;
  11358. String name;
  11359. /* readonly */
  11360. int refs;
  11361. /* readonly */
  11362. XMLElement root;
  11363. /* readonly */
  11364. StringHash type;
  11365. /* readonly */
  11366. String typeName;
  11367. /* readonly */
  11368. uint useTimer;
  11369. /* readonly */
  11370. int weakRefs;
  11371. };
  11372. class XPathQuery
  11373. {
  11374. // Methods:
  11375. void Bind();
  11376. void Clear();
  11377. XPathResultSet Evaluate(XMLElement);
  11378. bool EvaluateToBool(XMLElement);
  11379. float EvaluateToFloat(XMLElement);
  11380. String EvaluateToString(XMLElement);
  11381. bool SetQuery(const String&, const String& = String ( ), bool = true);
  11382. bool SetVariable(const String&, bool);
  11383. bool SetVariable(const String&, const String&);
  11384. bool SetVariable(const String&, const XPathResultSet&);
  11385. bool SetVariable(const String&, float);
  11386. // Properties:
  11387. String query;
  11388. };
  11389. class XPathResultSet
  11390. {
  11391. // Properties:
  11392. /* readonly */
  11393. bool empty;
  11394. /* readonly */
  11395. XMLElement firstResult;
  11396. /* readonly */
  11397. uint size;
  11398. };
  11399. class Zone
  11400. {
  11401. // Methods:
  11402. void ApplyAttributes();
  11403. void DrawDebugGeometry(DebugRenderer, bool);
  11404. Variant GetAttribute(const String&) const;
  11405. ValueAnimation GetAttributeAnimation(const String&) const;
  11406. float GetAttributeAnimationSpeed(const String&) const;
  11407. WrapMode GetAttributeAnimationWrapMode(const String&) const;
  11408. Variant GetAttributeDefault(const String&) const;
  11409. bool IsInView(Camera) const;
  11410. bool Load(File, bool = false);
  11411. bool Load(VectorBuffer&, bool = false);
  11412. bool LoadXML(const XMLElement&, bool = false);
  11413. void MarkNetworkUpdate() const;
  11414. void Remove();
  11415. void RemoveInstanceDefault();
  11416. void ResetToDefault();
  11417. bool Save(File) const;
  11418. bool Save(VectorBuffer&) const;
  11419. bool SaveXML(XMLElement&) const;
  11420. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  11421. bool SetAttribute(const String&, const Variant&);
  11422. void SetAttributeAnimation(const String&, ValueAnimation, WrapMode = WM_LOOP, float = 1.0f);
  11423. void SetAttributeAnimationSpeed(const String&, float);
  11424. void SetAttributeAnimationWrapMode(const String&, WrapMode);
  11425. // Properties:
  11426. Color ambientColor;
  11427. /* readonly */
  11428. Color ambientEndColor;
  11429. bool ambientGradient;
  11430. /* readonly */
  11431. Color ambientStartColor;
  11432. bool animationEnabled;
  11433. /* readonly */
  11434. Array<Variant> attributeDefaults;
  11435. /* readonly */
  11436. Array<AttributeInfo> attributeInfos;
  11437. Array<Variant> attributes;
  11438. /* readonly */
  11439. StringHash baseType;
  11440. BoundingBox boundingBox;
  11441. bool castShadows;
  11442. /* readonly */
  11443. String category;
  11444. float drawDistance;
  11445. bool enabled;
  11446. /* readonly */
  11447. bool enabledEffective;
  11448. Color fogColor;
  11449. float fogEnd;
  11450. float fogHeight;
  11451. float fogHeightScale;
  11452. float fogStart;
  11453. bool heightFog;
  11454. /* readonly */
  11455. uint id;
  11456. /* readonly */
  11457. bool inView;
  11458. /* readonly */
  11459. Matrix3x4 inverseWorldTransform;
  11460. uint lightMask;
  11461. float lodBias;
  11462. uint maxLights;
  11463. /* readonly */
  11464. Node node;
  11465. /* readonly */
  11466. uint numAttributes;
  11467. ObjectAnimation objectAnimation;
  11468. bool occludee;
  11469. bool occluder;
  11470. bool override;
  11471. int priority;
  11472. /* readonly */
  11473. int refs;
  11474. float shadowDistance;
  11475. uint shadowMask;
  11476. bool temporary;
  11477. /* readonly */
  11478. StringHash type;
  11479. /* readonly */
  11480. String typeName;
  11481. uint viewMask;
  11482. /* readonly */
  11483. int weakRefs;
  11484. /* readonly */
  11485. BoundingBox worldBoundingBox;
  11486. uint zoneMask;
  11487. Texture zoneTexture;
  11488. };
  11489. // Enumerations
  11490. enum BlendMode
  11491. {
  11492. BLEND_REPLACE,
  11493. BLEND_ADD,
  11494. BLEND_MULTIPLY,
  11495. BLEND_ALPHA,
  11496. BLEND_ADDALPHA,
  11497. BLEND_PREMULALPHA,
  11498. BLEND_INVDESTALPHA,
  11499. BLEND_SUBTRACT,
  11500. BLEND_SUBTRACTALPHA,
  11501. };
  11502. enum BodyType2D
  11503. {
  11504. BT_STATIC,
  11505. BT_DYNAMIC,
  11506. BT_KINEMATIC,
  11507. };
  11508. enum CollisionEventMode
  11509. {
  11510. COLLISION_NEVER,
  11511. COLLISION_ACTIVE,
  11512. COLLISION_ALWAYS,
  11513. };
  11514. enum CompareMode
  11515. {
  11516. CMP_ALWAYS,
  11517. CMP_EQUAL,
  11518. CMP_NOTEQUAL,
  11519. CMP_LESS,
  11520. CMP_LESSEQUAL,
  11521. CMP_GREATER,
  11522. CMP_GREATEREQUAL,
  11523. };
  11524. enum CompressedFormat
  11525. {
  11526. CF_NONE,
  11527. CF_RGBA,
  11528. CF_DXT1,
  11529. CF_DXT3,
  11530. CF_DXT5,
  11531. CF_ETC1,
  11532. CF_PVRTC_RGB_2BPP,
  11533. CF_PVRTC_RGBA_2BPP,
  11534. CF_PVRTC_RGB_4BPP,
  11535. CF_PVRTC_RGBA_4BPP,
  11536. };
  11537. enum ConstraintType
  11538. {
  11539. CONSTRAINT_POINT,
  11540. CONSTRAINT_HINGE,
  11541. CONSTRAINT_SLIDER,
  11542. CONSTRAINT_CONETWIST,
  11543. };
  11544. enum Corner
  11545. {
  11546. C_TOPLEFT,
  11547. C_TOPRIGHT,
  11548. C_BOTTOMLEFT,
  11549. C_BOTTOMRIGHT,
  11550. };
  11551. enum CreateMode
  11552. {
  11553. REPLICATED,
  11554. LOCAL,
  11555. };
  11556. enum CubeMapFace
  11557. {
  11558. FACE_POSITIVE_X,
  11559. FACE_NEGATIVE_X,
  11560. FACE_POSITIVE_Y,
  11561. FACE_NEGATIVE_Y,
  11562. FACE_POSITIVE_Z,
  11563. FACE_NEGATIVE_Z,
  11564. };
  11565. enum CullMode
  11566. {
  11567. CULL_NONE,
  11568. CULL_CCW,
  11569. CULL_CW,
  11570. };
  11571. enum CursorShape
  11572. {
  11573. CS_NORMAL,
  11574. CS_IBEAM,
  11575. CS_CROSS,
  11576. CS_RESIZEVERTICAL,
  11577. CS_RESIZEDIAGONAL_TOPRIGHT,
  11578. CS_RESIZEHORIZONTAL,
  11579. CS_RESIZEDIAGONAL_TOPLEFT,
  11580. CS_RESIZE_ALL,
  11581. CS_ACCEPTDROP,
  11582. CS_REJECTDROP,
  11583. CS_BUSY,
  11584. CS_BUSY_ARROW,
  11585. };
  11586. enum DumpMode
  11587. {
  11588. DOXYGEN,
  11589. C_HEADER,
  11590. };
  11591. enum EmitterType
  11592. {
  11593. EMITTER_SPHERE,
  11594. EMITTER_BOX,
  11595. };
  11596. enum EmitterType2D
  11597. {
  11598. EMITTER_TYPE_GRAVITY,
  11599. EMITTER_TYPE_RADIAL,
  11600. };
  11601. enum FaceCameraMode
  11602. {
  11603. FC_NONE,
  11604. FC_ROTATE_XYZ,
  11605. FC_ROTATE_Y,
  11606. FC_LOOKAT_XYZ,
  11607. FC_LOOKAT_Y,
  11608. };
  11609. enum FileMode
  11610. {
  11611. FILE_READ,
  11612. FILE_WRITE,
  11613. FILE_READWRITE,
  11614. };
  11615. enum FillMode
  11616. {
  11617. FILL_SOLID,
  11618. FILL_WIREFRAME,
  11619. FILL_POINT,
  11620. };
  11621. enum FocusMode
  11622. {
  11623. FM_NOTFOCUSABLE,
  11624. FM_RESETFOCUS,
  11625. FM_FOCUSABLE,
  11626. FM_FOCUSABLE_DEFOCUSABLE,
  11627. };
  11628. enum HighlightMode
  11629. {
  11630. HM_NEVER,
  11631. HM_FOCUS,
  11632. HM_ALWAYS,
  11633. };
  11634. enum HorizontalAlignment
  11635. {
  11636. HA_LEFT,
  11637. HA_CENTER,
  11638. HA_RIGHT,
  11639. };
  11640. enum HttpRequestState
  11641. {
  11642. HTTP_INITIALIZING,
  11643. HTTP_ERROR,
  11644. HTTP_OPEN,
  11645. HTTP_CLOSED,
  11646. };
  11647. enum InterpMethod
  11648. {
  11649. IM_LINEAR,
  11650. IM_SPLINE,
  11651. };
  11652. enum InterpolationMode
  11653. {
  11654. BEZIER_CURVE,
  11655. };
  11656. enum Intersection
  11657. {
  11658. OUTSIDE,
  11659. INTERSECTS,
  11660. INSIDE,
  11661. };
  11662. enum JSONValueType
  11663. {
  11664. JSON_ANY,
  11665. JSON_OBJECT,
  11666. JSON_ARRAY,
  11667. };
  11668. enum LayoutMode
  11669. {
  11670. LM_FREE,
  11671. LM_HORIZONTAL,
  11672. LM_VERTICAL,
  11673. };
  11674. enum LightType
  11675. {
  11676. LIGHT_DIRECTIONAL,
  11677. LIGHT_SPOT,
  11678. LIGHT_POINT,
  11679. };
  11680. enum LoadMode
  11681. {
  11682. LOAD_RESOURCES_ONLY,
  11683. LOAD_SCENE,
  11684. LOAD_SCENE_AND_RESOURCES,
  11685. };
  11686. enum LoopMode2D
  11687. {
  11688. LM_DEFAULT,
  11689. LM_FORCE_LOOPED,
  11690. LM_FORCE_CLAMPED,
  11691. };
  11692. enum MouseMode
  11693. {
  11694. MM_ABSOLUTE,
  11695. MM_RELATIVE,
  11696. MM_WRAP,
  11697. };
  11698. enum Orientation
  11699. {
  11700. O_HORIZONTAL,
  11701. O_VERTICAL,
  11702. };
  11703. enum Orientation2D
  11704. {
  11705. O_ORTHOGONAL,
  11706. O_ISOMETRIC,
  11707. O_STAGGERED,
  11708. };
  11709. enum PassLightingMode
  11710. {
  11711. LIGHTING_UNLIT,
  11712. LIGHTING_PERVERTEX,
  11713. LIGHTING_PERPIXEL,
  11714. };
  11715. enum PrimitiveType
  11716. {
  11717. TRIANGLE_LIST,
  11718. LINE_LIST,
  11719. POINT_LIST,
  11720. TRIANGLE_STRIP,
  11721. LINE_STRIP,
  11722. TRIANGLE_FAN,
  11723. };
  11724. enum RayQueryLevel
  11725. {
  11726. RAY_AABB,
  11727. RAY_OBB,
  11728. RAY_TRIANGLE,
  11729. };
  11730. enum RenderCommandSortMode
  11731. {
  11732. SORT_FRONTTOBACK,
  11733. SORT_BACKTOFRONT,
  11734. };
  11735. enum RenderCommandType
  11736. {
  11737. CMD_NONE,
  11738. CMD_CLEAR,
  11739. CMD_SCENEPASS,
  11740. CMD_QUAD,
  11741. CMD_FORWARDLIGHTS,
  11742. CMD_LIGHTVOLUMES,
  11743. CMD_RENDERUI,
  11744. };
  11745. enum RenderSurfaceUpdateMode
  11746. {
  11747. SURFACE_MANUALUPDATE,
  11748. SURFACE_UPDATEVISIBLE,
  11749. SURFACE_UPDATEALWAYS,
  11750. };
  11751. enum RenderTargetSizeMode
  11752. {
  11753. SIZE_ABSOLUTE,
  11754. SIZE_VIEWPORTDIVISOR,
  11755. SIZE_VIEWPORTMULTIPLIER,
  11756. };
  11757. enum ShapeType
  11758. {
  11759. SHAPE_BOX,
  11760. SHAPE_SPHERE,
  11761. SHAPE_STATICPLANE,
  11762. SHAPE_CYLINDER,
  11763. SHAPE_CAPSULE,
  11764. SHAPE_CONE,
  11765. SHAPE_TRIANGLEMESH,
  11766. SHAPE_CONVEXHULL,
  11767. SHAPE_TERRAIN,
  11768. };
  11769. enum TextEffect
  11770. {
  11771. TE_NONE,
  11772. TE_SHADOW,
  11773. TE_STROKE,
  11774. };
  11775. enum TextureAddressMode
  11776. {
  11777. ADDRESS_WRAP,
  11778. ADDRESS_MIRROR,
  11779. ADDRESS_CLAMP,
  11780. ADDRESS_BORDER,
  11781. };
  11782. enum TextureCoordinate
  11783. {
  11784. COORD_U,
  11785. COORD_V,
  11786. COORD_W,
  11787. };
  11788. enum TextureFilterMode
  11789. {
  11790. FILTER_NEAREST,
  11791. FILTER_BILINEAR,
  11792. FILTER_TRILINEAR,
  11793. FILTER_ANISOTROPIC,
  11794. FILTER_DEFAULT,
  11795. };
  11796. enum TextureUnit
  11797. {
  11798. TU_DIFFUSE,
  11799. TU_NORMAL,
  11800. TU_SPECULAR,
  11801. TU_EMISSIVE,
  11802. TU_ENVIRONMENT,
  11803. TU_LIGHTRAMP,
  11804. TU_LIGHTSHAPE,
  11805. TU_SHADOWMAP,
  11806. TU_FACESELECT,
  11807. TU_INDIRECTION,
  11808. TU_ALBEDOBUFFER,
  11809. TU_NORMALBUFFER,
  11810. TU_DEPTHBUFFER,
  11811. TU_LIGHTBUFFER,
  11812. TU_VOLUMEMAP,
  11813. TU_ZONE,
  11814. MAX_MATERIAL_TEXTURE_UNITS,
  11815. MAX_NAMED_TEXTURE_UNITS,
  11816. MAX_TEXTURE_UNITS,
  11817. };
  11818. enum TextureUsage
  11819. {
  11820. TEXTURE_STATIC,
  11821. TEXTURE_DYNAMIC,
  11822. TEXTURE_RENDERTARGET,
  11823. TEXTURE_DEPTHSTENCIL,
  11824. };
  11825. enum TileMapLayerType2D
  11826. {
  11827. LT_TILE_LAYER,
  11828. LT_OBJECT_GROUP,
  11829. LT_IMAGE_LAYER,
  11830. LT_INVALID,
  11831. };
  11832. enum TileObjectType2D
  11833. {
  11834. OT_RECTANGLE,
  11835. OT_ELLIPSE,
  11836. OT_POLYGON,
  11837. OT_POLYLINE,
  11838. OT_TILE,
  11839. OT_INVALID,
  11840. };
  11841. enum TransformSpace
  11842. {
  11843. TS_LOCAL,
  11844. TS_PARENT,
  11845. TS_WORLD,
  11846. };
  11847. enum TraversalMode
  11848. {
  11849. TM_BREADTH_FIRST,
  11850. TM_DEPTH_FIRST,
  11851. };
  11852. enum VariantType
  11853. {
  11854. VAR_NONE,
  11855. VAR_INT,
  11856. VAR_BOOL,
  11857. VAR_FLOAT,
  11858. VAR_VECTOR2,
  11859. VAR_VECTOR3,
  11860. VAR_VECTOR4,
  11861. VAR_QUATERNION,
  11862. VAR_COLOR,
  11863. VAR_STRING,
  11864. VAR_BUFFER,
  11865. VAR_VOIDPTR,
  11866. VAR_RESOURCEREF,
  11867. VAR_RESOURCEREFLIST,
  11868. VAR_VARIANTVECTOR,
  11869. VAR_VARIANTMAP,
  11870. VAR_INTRECT,
  11871. VAR_INTVECTOR2,
  11872. VAR_PTR,
  11873. VAR_MATRIX3,
  11874. VAR_MATRIX3X4,
  11875. VAR_MATRIX4,
  11876. };
  11877. enum VerticalAlignment
  11878. {
  11879. VA_TOP,
  11880. VA_CENTER,
  11881. VA_BOTTOM,
  11882. };
  11883. enum WrapMode
  11884. {
  11885. WM_LOOP,
  11886. WM_ONCE,
  11887. WM_CLAMP,
  11888. };
  11889. // Global functions
  11890. float Abs(float);
  11891. float Acos(float);
  11892. String AddTrailingSlash(const String&);
  11893. float Asin(float);
  11894. float Atan(float);
  11895. float Atan2(float, float);
  11896. float Ceil(float);
  11897. float Clamp(float, float, float);
  11898. int Clamp(int, int, int);
  11899. void ClearDelayedExecute(const String& = String ( ));
  11900. VectorBuffer CompressVectorBuffer(VectorBuffer&);
  11901. float Cos(float);
  11902. uint CountSetBits(uint);
  11903. VectorBuffer DecompressVectorBuffer(VectorBuffer&);
  11904. void DelayedExecute(float, bool, const String&, const Array<Variant> = null);
  11905. bool Equals(float, float);
  11906. void ErrorDialog(const String&, const String&);
  11907. float Floor(float);
  11908. uint GetAlphaFormat();
  11909. Array<String> GetArguments();
  11910. String GetConsoleInput();
  11911. uint GetDepthStencilFormat();
  11912. Object GetEventSender();
  11913. String GetExtension(const String&, bool = true);
  11914. String GetFileName(const String&);
  11915. String GetFileNameAndExtension(const String&, bool = false);
  11916. uint GetFloat16Format();
  11917. uint GetFloat32Format();
  11918. uint GetFormat(const String&);
  11919. String GetInternalPath(const String&);
  11920. uint GetLuminanceAlphaFormat();
  11921. uint GetLuminanceFormat();
  11922. uint GetNumLogicalCPUs();
  11923. uint GetNumPhysicalCPUs();
  11924. Array<String> GetObjectCategories();
  11925. Array<String> GetObjectsByCategory(const String&);
  11926. String GetParentPath(const String&);
  11927. String GetPath(const String&);
  11928. String GetPlatform();
  11929. uint GetRG16Format();
  11930. uint GetRGBA16Format();
  11931. uint GetRGBAFloat16Format();
  11932. uint GetRGBAFloat32Format();
  11933. uint GetRGBAFormat();
  11934. uint GetRGBFormat();
  11935. uint GetRGFloat16Format();
  11936. uint GetRGFloat32Format();
  11937. uint GetRandomSeed();
  11938. uint GetReadableDepthFormat();
  11939. String GetTextureUnitName(TextureUnit);
  11940. bool IsAbsolutePath(const String&);
  11941. bool IsAlpha(uint);
  11942. bool IsDigit(uint);
  11943. bool IsNaN(float);
  11944. bool IsPowerOfTwo(uint);
  11945. String Join(Array<String>&, const String&);
  11946. float Lerp(float, float, float);
  11947. void MarkNetworkUpdate();
  11948. float Max(float, float);
  11949. int Max(int, int);
  11950. float Min(float, float);
  11951. int Min(int, int);
  11952. float Mod(float, float);
  11953. uint NextPowerOfTwo(uint);
  11954. void OpenConsoleWindow();
  11955. float Pow(float, float);
  11956. void Print(bool, bool = false);
  11957. void Print(const String&, bool = false);
  11958. void Print(const Variant&, bool = false);
  11959. void Print(float, bool = false);
  11960. void Print(int, bool = false);
  11961. void Print(uint, bool = false);
  11962. void PrintCallStack(bool = false);
  11963. float Random();
  11964. float Random(float);
  11965. float Random(float, float);
  11966. int RandomInt();
  11967. int RandomInt(int);
  11968. int RandomInt(int, int);
  11969. float RandomNormal(float, float);
  11970. void Remove();
  11971. String RemoveTrailingSlash(const String&);
  11972. String ReplaceExtension(const String&, const String&);
  11973. uint SDBMHash(uint, uint8);
  11974. void SendEvent(const String&, VariantMap& = VariantMap ( ));
  11975. void SetRandomSeed(uint);
  11976. float Sign(float);
  11977. float Sin(float);
  11978. float SmoothStep(float, float, float);
  11979. float Sqrt(float);
  11980. const String& GetTypeName(StringHash);
  11981. void SubscribeToEvent(Object, const String&, const String&);
  11982. void SubscribeToEvent(const String&, const String&);
  11983. float Tan(float);
  11984. uint ToLower(uint);
  11985. String ToStringHex(int);
  11986. uint ToUpper(uint);
  11987. void UnsubscribeFromAllEvents();
  11988. void UnsubscribeFromAllEventsExcept(Array<String>);
  11989. void UnsubscribeFromEvent(Object, const String&);
  11990. void UnsubscribeFromEvent(const String&);
  11991. void UnsubscribeFromEvents(Object);
  11992. // Global properties
  11993. Audio audio;
  11994. ResourceCache cache;
  11995. Console console;
  11996. DebugHud debugHud;
  11997. DebugRenderer debugRenderer;
  11998. Engine engine;
  11999. FileSystem fileSystem;
  12000. Graphics graphics;
  12001. Input input;
  12002. Log log;
  12003. Network network;
  12004. Node node;
  12005. Octree octree;
  12006. PhysicsWorld physicsWorld;
  12007. PhysicsWorld2D physicsWorld2D;
  12008. Renderer renderer;
  12009. ResourceCache resourceCache;
  12010. Scene scene;
  12011. Script script;
  12012. ScriptFile scriptFile;
  12013. ScriptInstance self;
  12014. Time time;
  12015. UI ui;
  12016. // Global constants
  12017. uint AM_COMPONENTID;
  12018. uint AM_DEFAULT;
  12019. uint AM_FILE;
  12020. uint AM_LATESTDATA;
  12021. uint AM_NET;
  12022. uint AM_NODEID;
  12023. uint AM_NODEIDVECTOR;
  12024. uint AM_NOEDIT;
  12025. Color BLACK;
  12026. Color BLUE;
  12027. int CONTROLLER_AXIS_LEFTX;
  12028. int CONTROLLER_AXIS_LEFTY;
  12029. int CONTROLLER_AXIS_RIGHTX;
  12030. int CONTROLLER_AXIS_RIGHTY;
  12031. int CONTROLLER_AXIS_TRIGGERLEFT;
  12032. int CONTROLLER_AXIS_TRIGGERRIGHT;
  12033. int CONTROLLER_BUTTON_A;
  12034. int CONTROLLER_BUTTON_B;
  12035. int CONTROLLER_BUTTON_BACK;
  12036. int CONTROLLER_BUTTON_DPAD_DOWN;
  12037. int CONTROLLER_BUTTON_DPAD_LEFT;
  12038. int CONTROLLER_BUTTON_DPAD_RIGHT;
  12039. int CONTROLLER_BUTTON_DPAD_UP;
  12040. int CONTROLLER_BUTTON_GUIDE;
  12041. int CONTROLLER_BUTTON_LEFTSHOULDER;
  12042. int CONTROLLER_BUTTON_LEFTSTICK;
  12043. int CONTROLLER_BUTTON_RIGHTSHOULDER;
  12044. int CONTROLLER_BUTTON_RIGHTSTICK;
  12045. int CONTROLLER_BUTTON_START;
  12046. int CONTROLLER_BUTTON_X;
  12047. int CONTROLLER_BUTTON_Y;
  12048. Color CYAN;
  12049. uint DD_DISABLED;
  12050. uint DD_SOURCE;
  12051. uint DD_SOURCE_AND_TARGET;
  12052. uint DD_TARGET;
  12053. uint DEBUGHUD_SHOW_ALL;
  12054. uint DEBUGHUD_SHOW_MODE;
  12055. uint DEBUGHUD_SHOW_NONE;
  12056. uint DEBUGHUD_SHOW_PROFILER;
  12057. uint DEBUGHUD_SHOW_STATS;
  12058. uint DEFAULT_LIGHTMASK;
  12059. uint DEFAULT_VIEWMASK;
  12060. uint DRAWABLE_ANY;
  12061. uint DRAWABLE_GEOMETRY;
  12062. uint DRAWABLE_GEOMETRY2D;
  12063. uint DRAWABLE_LIGHT;
  12064. uint DRAWABLE_ZONE;
  12065. uint FIRST_LOCAL_ID;
  12066. uint FIRST_REPLICATED_ID;
  12067. Color GRAY;
  12068. Color GREEN;
  12069. int HAT_CENTER;
  12070. int HAT_DOWN;
  12071. int HAT_LEFT;
  12072. int HAT_RIGHT;
  12073. int HAT_UP;
  12074. int KEY_0;
  12075. int KEY_1;
  12076. int KEY_2;
  12077. int KEY_3;
  12078. int KEY_4;
  12079. int KEY_5;
  12080. int KEY_6;
  12081. int KEY_7;
  12082. int KEY_8;
  12083. int KEY_9;
  12084. int KEY_A;
  12085. int KEY_ALT;
  12086. int KEY_APPLICATION;
  12087. int KEY_B;
  12088. int KEY_BACKSPACE;
  12089. int KEY_C;
  12090. int KEY_CAPSLOCK;
  12091. int KEY_CTRL;
  12092. int KEY_D;
  12093. int KEY_DELETE;
  12094. int KEY_DOWN;
  12095. int KEY_E;
  12096. int KEY_END;
  12097. int KEY_ESC;
  12098. int KEY_F;
  12099. int KEY_F1;
  12100. int KEY_F10;
  12101. int KEY_F11;
  12102. int KEY_F12;
  12103. int KEY_F13;
  12104. int KEY_F14;
  12105. int KEY_F15;
  12106. int KEY_F16;
  12107. int KEY_F17;
  12108. int KEY_F18;
  12109. int KEY_F19;
  12110. int KEY_F2;
  12111. int KEY_F20;
  12112. int KEY_F21;
  12113. int KEY_F22;
  12114. int KEY_F23;
  12115. int KEY_F24;
  12116. int KEY_F3;
  12117. int KEY_F4;
  12118. int KEY_F5;
  12119. int KEY_F6;
  12120. int KEY_F7;
  12121. int KEY_F8;
  12122. int KEY_F9;
  12123. int KEY_G;
  12124. int KEY_GUI;
  12125. int KEY_H;
  12126. int KEY_HOME;
  12127. int KEY_I;
  12128. int KEY_INSERT;
  12129. int KEY_J;
  12130. int KEY_K;
  12131. int KEY_KP_0;
  12132. int KEY_KP_1;
  12133. int KEY_KP_2;
  12134. int KEY_KP_3;
  12135. int KEY_KP_4;
  12136. int KEY_KP_5;
  12137. int KEY_KP_6;
  12138. int KEY_KP_7;
  12139. int KEY_KP_8;
  12140. int KEY_KP_9;
  12141. int KEY_KP_DIVIDE;
  12142. int KEY_KP_ENTER;
  12143. int KEY_KP_MINUS;
  12144. int KEY_KP_MULTIPLY;
  12145. int KEY_KP_PERIOD;
  12146. int KEY_KP_PLUS;
  12147. int KEY_L;
  12148. int KEY_LALT;
  12149. int KEY_LCTRL;
  12150. int KEY_LEFT;
  12151. int KEY_LGUI;
  12152. int KEY_LSHIFT;
  12153. int KEY_M;
  12154. int KEY_N;
  12155. int KEY_NUMLOCKCLEAR;
  12156. int KEY_O;
  12157. int KEY_P;
  12158. int KEY_PAGEDOWN;
  12159. int KEY_PAGEUP;
  12160. int KEY_PAUSE;
  12161. int KEY_PRINTSCREEN;
  12162. int KEY_Q;
  12163. int KEY_R;
  12164. int KEY_RALT;
  12165. int KEY_RCTRL;
  12166. int KEY_RETURN;
  12167. int KEY_RETURN2;
  12168. int KEY_RGUI;
  12169. int KEY_RIGHT;
  12170. int KEY_RSHIFT;
  12171. int KEY_S;
  12172. int KEY_SCROLLLOCK;
  12173. int KEY_SELECT;
  12174. int KEY_SHIFT;
  12175. int KEY_SPACE;
  12176. int KEY_T;
  12177. int KEY_TAB;
  12178. int KEY_U;
  12179. int KEY_UP;
  12180. int KEY_V;
  12181. int KEY_W;
  12182. int KEY_X;
  12183. int KEY_Y;
  12184. int KEY_Z;
  12185. uint LAST_LOCAL_ID;
  12186. uint LAST_REPLICATED_ID;
  12187. int LOG_DEBUG;
  12188. int LOG_ERROR;
  12189. int LOG_INFO;
  12190. int LOG_NONE;
  12191. int LOG_WARNING;
  12192. Color MAGENTA;
  12193. int MOUSEB_LEFT;
  12194. int MOUSEB_MIDDLE;
  12195. int MOUSEB_RIGHT;
  12196. float M_DEGTORAD;
  12197. float M_DEGTORAD_2;
  12198. float M_EPSILON;
  12199. float M_HALF_PI;
  12200. float M_INFINITY;
  12201. float M_LARGE_EPSILON;
  12202. float M_LARGE_VALUE;
  12203. int M_MAX_INT;
  12204. uint M_MAX_UNSIGNED;
  12205. int M_MIN_INT;
  12206. uint M_MIN_UNSIGNED;
  12207. float M_PI;
  12208. float M_RADTODEG;
  12209. float PIXEL_SIZE;
  12210. int QUALITY_HIGH;
  12211. int QUALITY_LOW;
  12212. int QUALITY_MAX;
  12213. int QUALITY_MEDIUM;
  12214. int QUAL_ALT;
  12215. int QUAL_ANY;
  12216. int QUAL_CTRL;
  12217. int QUAL_SHIFT;
  12218. Color RED;
  12219. int SCANCODE_0;
  12220. int SCANCODE_1;
  12221. int SCANCODE_2;
  12222. int SCANCODE_3;
  12223. int SCANCODE_4;
  12224. int SCANCODE_5;
  12225. int SCANCODE_6;
  12226. int SCANCODE_7;
  12227. int SCANCODE_8;
  12228. int SCANCODE_9;
  12229. int SCANCODE_A;
  12230. int SCANCODE_AC_BACK;
  12231. int SCANCODE_AC_BOOKMARKS;
  12232. int SCANCODE_AC_FORWARD;
  12233. int SCANCODE_AC_HOME;
  12234. int SCANCODE_AC_REFRESH;
  12235. int SCANCODE_AC_SEARCH;
  12236. int SCANCODE_AC_STOP;
  12237. int SCANCODE_AGAIN;
  12238. int SCANCODE_ALT;
  12239. int SCANCODE_ALTERASE;
  12240. int SCANCODE_APOSTROPHE;
  12241. int SCANCODE_APP1;
  12242. int SCANCODE_APP2;
  12243. int SCANCODE_APPLICATION;
  12244. int SCANCODE_AUDIOMUTE;
  12245. int SCANCODE_AUDIONEXT;
  12246. int SCANCODE_AUDIOPLAY;
  12247. int SCANCODE_AUDIOPREV;
  12248. int SCANCODE_AUDIOSTOP;
  12249. int SCANCODE_B;
  12250. int SCANCODE_BACKSLASH;
  12251. int SCANCODE_BACKSPACE;
  12252. int SCANCODE_BRIGHTNESSDOWN;
  12253. int SCANCODE_BRIGHTNESSUP;
  12254. int SCANCODE_C;
  12255. int SCANCODE_CALCULATOR;
  12256. int SCANCODE_CANCEL;
  12257. int SCANCODE_CAPSLOCK;
  12258. int SCANCODE_CLEAR;
  12259. int SCANCODE_CLEARAGAIN;
  12260. int SCANCODE_COMMA;
  12261. int SCANCODE_COMPUTER;
  12262. int SCANCODE_COPY;
  12263. int SCANCODE_CRSEL;
  12264. int SCANCODE_CTRL;
  12265. int SCANCODE_CURRENCYSUBUNIT;
  12266. int SCANCODE_CURRENCYUNIT;
  12267. int SCANCODE_CUT;
  12268. int SCANCODE_D;
  12269. int SCANCODE_DECIMALSEPARATOR;
  12270. int SCANCODE_DELETE;
  12271. int SCANCODE_DISPLAYSWITCH;
  12272. int SCANCODE_DOWN;
  12273. int SCANCODE_E;
  12274. int SCANCODE_EJECT;
  12275. int SCANCODE_END;
  12276. int SCANCODE_EQUALS;
  12277. int SCANCODE_ESCAPE;
  12278. int SCANCODE_EXECUTE;
  12279. int SCANCODE_EXSEL;
  12280. int SCANCODE_F;
  12281. int SCANCODE_F1;
  12282. int SCANCODE_F10;
  12283. int SCANCODE_F11;
  12284. int SCANCODE_F12;
  12285. int SCANCODE_F13;
  12286. int SCANCODE_F14;
  12287. int SCANCODE_F15;
  12288. int SCANCODE_F16;
  12289. int SCANCODE_F17;
  12290. int SCANCODE_F18;
  12291. int SCANCODE_F19;
  12292. int SCANCODE_F2;
  12293. int SCANCODE_F20;
  12294. int SCANCODE_F21;
  12295. int SCANCODE_F22;
  12296. int SCANCODE_F23;
  12297. int SCANCODE_F24;
  12298. int SCANCODE_F3;
  12299. int SCANCODE_F4;
  12300. int SCANCODE_F5;
  12301. int SCANCODE_F6;
  12302. int SCANCODE_F7;
  12303. int SCANCODE_F8;
  12304. int SCANCODE_F9;
  12305. int SCANCODE_FIND;
  12306. int SCANCODE_G;
  12307. int SCANCODE_GRAVE;
  12308. int SCANCODE_GUI;
  12309. int SCANCODE_H;
  12310. int SCANCODE_HELP;
  12311. int SCANCODE_HOME;
  12312. int SCANCODE_I;
  12313. int SCANCODE_INSERT;
  12314. int SCANCODE_INTERNATIONAL1;
  12315. int SCANCODE_INTERNATIONAL2;
  12316. int SCANCODE_INTERNATIONAL3;
  12317. int SCANCODE_INTERNATIONAL4;
  12318. int SCANCODE_INTERNATIONAL5;
  12319. int SCANCODE_INTERNATIONAL6;
  12320. int SCANCODE_INTERNATIONAL7;
  12321. int SCANCODE_INTERNATIONAL8;
  12322. int SCANCODE_INTERNATIONAL9;
  12323. int SCANCODE_J;
  12324. int SCANCODE_K;
  12325. int SCANCODE_KBDILLUMDOWN;
  12326. int SCANCODE_KBDILLUMTOGGLE;
  12327. int SCANCODE_KBDILLUMUP;
  12328. int SCANCODE_KP_0;
  12329. int SCANCODE_KP_00;
  12330. int SCANCODE_KP_000;
  12331. int SCANCODE_KP_1;
  12332. int SCANCODE_KP_2;
  12333. int SCANCODE_KP_3;
  12334. int SCANCODE_KP_4;
  12335. int SCANCODE_KP_5;
  12336. int SCANCODE_KP_6;
  12337. int SCANCODE_KP_7;
  12338. int SCANCODE_KP_8;
  12339. int SCANCODE_KP_9;
  12340. int SCANCODE_KP_A;
  12341. int SCANCODE_KP_AMPERSAND;
  12342. int SCANCODE_KP_AT;
  12343. int SCANCODE_KP_B;
  12344. int SCANCODE_KP_BACKSPACE;
  12345. int SCANCODE_KP_BINARY;
  12346. int SCANCODE_KP_C;
  12347. int SCANCODE_KP_CLEAR;
  12348. int SCANCODE_KP_CLEARENTRY;
  12349. int SCANCODE_KP_COLON;
  12350. int SCANCODE_KP_COMMA;
  12351. int SCANCODE_KP_D;
  12352. int SCANCODE_KP_DBLAMPERSAND;
  12353. int SCANCODE_KP_DBLVERTICALBAR;
  12354. int SCANCODE_KP_DECIMAL;
  12355. int SCANCODE_KP_DIVIDE;
  12356. int SCANCODE_KP_E;
  12357. int SCANCODE_KP_ENTER;
  12358. int SCANCODE_KP_EQUALS;
  12359. int SCANCODE_KP_EQUALSAS400;
  12360. int SCANCODE_KP_EXCLAM;
  12361. int SCANCODE_KP_F;
  12362. int SCANCODE_KP_GREATER;
  12363. int SCANCODE_KP_HASH;
  12364. int SCANCODE_KP_HEXADECIMAL;
  12365. int SCANCODE_KP_LEFTBRACE;
  12366. int SCANCODE_KP_LEFTPAREN;
  12367. int SCANCODE_KP_LESS;
  12368. int SCANCODE_KP_MEMADD;
  12369. int SCANCODE_KP_MEMCLEAR;
  12370. int SCANCODE_KP_MEMDIVIDE;
  12371. int SCANCODE_KP_MEMMULTIPLY;
  12372. int SCANCODE_KP_MEMRECALL;
  12373. int SCANCODE_KP_MEMSTORE;
  12374. int SCANCODE_KP_MEMSUBTRACT;
  12375. int SCANCODE_KP_MINUS;
  12376. int SCANCODE_KP_MULTIPLY;
  12377. int SCANCODE_KP_OCTAL;
  12378. int SCANCODE_KP_PERCENT;
  12379. int SCANCODE_KP_PERIOD;
  12380. int SCANCODE_KP_PLUS;
  12381. int SCANCODE_KP_PLUSMINUS;
  12382. int SCANCODE_KP_POWER;
  12383. int SCANCODE_KP_RIGHTBRACE;
  12384. int SCANCODE_KP_RIGHTPAREN;
  12385. int SCANCODE_KP_SPACE;
  12386. int SCANCODE_KP_TAB;
  12387. int SCANCODE_KP_VERTICALBAR;
  12388. int SCANCODE_KP_XOR;
  12389. int SCANCODE_L;
  12390. int SCANCODE_LALT;
  12391. int SCANCODE_LANG1;
  12392. int SCANCODE_LANG2;
  12393. int SCANCODE_LANG3;
  12394. int SCANCODE_LANG4;
  12395. int SCANCODE_LANG5;
  12396. int SCANCODE_LANG6;
  12397. int SCANCODE_LANG7;
  12398. int SCANCODE_LANG8;
  12399. int SCANCODE_LANG9;
  12400. int SCANCODE_LCTRL;
  12401. int SCANCODE_LEFT;
  12402. int SCANCODE_LEFTBRACKET;
  12403. int SCANCODE_LGUI;
  12404. int SCANCODE_LSHIFT;
  12405. int SCANCODE_M;
  12406. int SCANCODE_MAIL;
  12407. int SCANCODE_MEDIASELECT;
  12408. int SCANCODE_MENU;
  12409. int SCANCODE_MINUS;
  12410. int SCANCODE_MODE;
  12411. int SCANCODE_MUTE;
  12412. int SCANCODE_N;
  12413. int SCANCODE_NONUSBACKSLASH;
  12414. int SCANCODE_NONUSHASH;
  12415. int SCANCODE_NUMLOCKCLEAR;
  12416. int SCANCODE_O;
  12417. int SCANCODE_OPER;
  12418. int SCANCODE_OUT;
  12419. int SCANCODE_P;
  12420. int SCANCODE_PAGEDOWN;
  12421. int SCANCODE_PAGEUP;
  12422. int SCANCODE_PASTE;
  12423. int SCANCODE_PAUSE;
  12424. int SCANCODE_PERIOD;
  12425. int SCANCODE_POWER;
  12426. int SCANCODE_PRINTSCREEN;
  12427. int SCANCODE_PRIOR;
  12428. int SCANCODE_Q;
  12429. int SCANCODE_R;
  12430. int SCANCODE_RALT;
  12431. int SCANCODE_RCTRL;
  12432. int SCANCODE_RETURN;
  12433. int SCANCODE_RETURN2;
  12434. int SCANCODE_RGUI;
  12435. int SCANCODE_RIGHT;
  12436. int SCANCODE_RIGHTBRACKET;
  12437. int SCANCODE_RSHIFT;
  12438. int SCANCODE_S;
  12439. int SCANCODE_SCROLLLOCK;
  12440. int SCANCODE_SELECT;
  12441. int SCANCODE_SEMICOLON;
  12442. int SCANCODE_SEPARATOR;
  12443. int SCANCODE_SHIFT;
  12444. int SCANCODE_SLASH;
  12445. int SCANCODE_SLEEP;
  12446. int SCANCODE_SPACE;
  12447. int SCANCODE_STOP;
  12448. int SCANCODE_SYSREQ;
  12449. int SCANCODE_T;
  12450. int SCANCODE_TAB;
  12451. int SCANCODE_THOUSANDSSEPARATOR;
  12452. int SCANCODE_U;
  12453. int SCANCODE_UNDO;
  12454. int SCANCODE_UNKNOWN;
  12455. int SCANCODE_UP;
  12456. int SCANCODE_V;
  12457. int SCANCODE_VOLUMEDOWN;
  12458. int SCANCODE_VOLUMEUP;
  12459. int SCANCODE_W;
  12460. int SCANCODE_WWW;
  12461. int SCANCODE_X;
  12462. int SCANCODE_Y;
  12463. int SCANCODE_Z;
  12464. uint SCAN_DIRS;
  12465. uint SCAN_FILES;
  12466. uint SCAN_HIDDEN;
  12467. int SHADOWQUALITY_HIGH_16BIT;
  12468. int SHADOWQUALITY_HIGH_24BIT;
  12469. int SHADOWQUALITY_LOW_16BIT;
  12470. int SHADOWQUALITY_LOW_24BIT;
  12471. String SOUND_AMBIENT;
  12472. String SOUND_EFFECT;
  12473. String SOUND_MASTER;
  12474. String SOUND_MUSIC;
  12475. String SOUND_VOICE;
  12476. Color TRANSPARENT;
  12477. uint VO_DISABLE_OCCLUSION;
  12478. uint VO_DISABLE_SHADOWS;
  12479. uint VO_LOW_MATERIAL_QUALITY;
  12480. uint VO_NONE;
  12481. Color WHITE;
  12482. Color YELLOW;