AngelScriptAPI.h 288 KB

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