lua_Joint.cpp 235 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912
  1. #include "Base.h"
  2. #include "ScriptController.h"
  3. #include "lua_Joint.h"
  4. #include "Animation.h"
  5. #include "AnimationTarget.h"
  6. #include "AudioSource.h"
  7. #include "Base.h"
  8. #include "Game.h"
  9. #include "Joint.h"
  10. #include "MeshSkin.h"
  11. #include "Node.h"
  12. #include "PhysicsCharacter.h"
  13. #include "PhysicsGhostObject.h"
  14. #include "PhysicsRigidBody.h"
  15. #include "PhysicsVehicle.h"
  16. #include "PhysicsVehicleWheel.h"
  17. #include "Ref.h"
  18. #include "Scene.h"
  19. #include "ScriptController.h"
  20. #include "ScriptTarget.h"
  21. #include "Terrain.h"
  22. #include "Transform.h"
  23. #include "lua_CurveInterpolationType.h"
  24. #include "lua_NodeType.h"
  25. #include "lua_PhysicsCollisionObjectType.h"
  26. namespace gameplay
  27. {
  28. void luaRegister_Joint()
  29. {
  30. const luaL_Reg lua_members[] =
  31. {
  32. {"addAdvertisedDescendant", lua_Joint_addAdvertisedDescendant},
  33. {"addChild", lua_Joint_addChild},
  34. {"addListener", lua_Joint_addListener},
  35. {"addRef", lua_Joint_addRef},
  36. {"addScriptCallback", lua_Joint_addScriptCallback},
  37. {"clone", lua_Joint_clone},
  38. {"createAnimation", lua_Joint_createAnimation},
  39. {"createAnimationFromBy", lua_Joint_createAnimationFromBy},
  40. {"createAnimationFromTo", lua_Joint_createAnimationFromTo},
  41. {"destroyAnimation", lua_Joint_destroyAnimation},
  42. {"findNode", lua_Joint_findNode},
  43. {"getActiveCameraTranslationView", lua_Joint_getActiveCameraTranslationView},
  44. {"getActiveCameraTranslationWorld", lua_Joint_getActiveCameraTranslationWorld},
  45. {"getAdvertisedDescendant", lua_Joint_getAdvertisedDescendant},
  46. {"getAgent", lua_Joint_getAgent},
  47. {"getAnimation", lua_Joint_getAnimation},
  48. {"getAnimationPropertyComponentCount", lua_Joint_getAnimationPropertyComponentCount},
  49. {"getAnimationPropertyValue", lua_Joint_getAnimationPropertyValue},
  50. {"getAudioSource", lua_Joint_getAudioSource},
  51. {"getBackVector", lua_Joint_getBackVector},
  52. {"getBoundingSphere", lua_Joint_getBoundingSphere},
  53. {"getCamera", lua_Joint_getCamera},
  54. {"getChildCount", lua_Joint_getChildCount},
  55. {"getCollisionObject", lua_Joint_getCollisionObject},
  56. {"getDownVector", lua_Joint_getDownVector},
  57. {"getFirstChild", lua_Joint_getFirstChild},
  58. {"getForm", lua_Joint_getForm},
  59. {"getForwardVector", lua_Joint_getForwardVector},
  60. {"getForwardVectorView", lua_Joint_getForwardVectorView},
  61. {"getForwardVectorWorld", lua_Joint_getForwardVectorWorld},
  62. {"getId", lua_Joint_getId},
  63. {"getInverseBindPose", lua_Joint_getInverseBindPose},
  64. {"getInverseTransposeWorldMatrix", lua_Joint_getInverseTransposeWorldMatrix},
  65. {"getInverseTransposeWorldViewMatrix", lua_Joint_getInverseTransposeWorldViewMatrix},
  66. {"getInverseViewMatrix", lua_Joint_getInverseViewMatrix},
  67. {"getInverseViewProjectionMatrix", lua_Joint_getInverseViewProjectionMatrix},
  68. {"getLeftVector", lua_Joint_getLeftVector},
  69. {"getLight", lua_Joint_getLight},
  70. {"getMatrix", lua_Joint_getMatrix},
  71. {"getModel", lua_Joint_getModel},
  72. {"getNextSibling", lua_Joint_getNextSibling},
  73. {"getNumAdvertisedDescendants", lua_Joint_getNumAdvertisedDescendants},
  74. {"getParent", lua_Joint_getParent},
  75. {"getParticleEmitter", lua_Joint_getParticleEmitter},
  76. {"getPreviousSibling", lua_Joint_getPreviousSibling},
  77. {"getProjectionMatrix", lua_Joint_getProjectionMatrix},
  78. {"getRefCount", lua_Joint_getRefCount},
  79. {"getRightVector", lua_Joint_getRightVector},
  80. {"getRightVectorWorld", lua_Joint_getRightVectorWorld},
  81. {"getRootNode", lua_Joint_getRootNode},
  82. {"getRotation", lua_Joint_getRotation},
  83. {"getScale", lua_Joint_getScale},
  84. {"getScaleX", lua_Joint_getScaleX},
  85. {"getScaleY", lua_Joint_getScaleY},
  86. {"getScaleZ", lua_Joint_getScaleZ},
  87. {"getScene", lua_Joint_getScene},
  88. {"getTag", lua_Joint_getTag},
  89. {"getTerrain", lua_Joint_getTerrain},
  90. {"getTranslation", lua_Joint_getTranslation},
  91. {"getTranslationView", lua_Joint_getTranslationView},
  92. {"getTranslationWorld", lua_Joint_getTranslationWorld},
  93. {"getTranslationX", lua_Joint_getTranslationX},
  94. {"getTranslationY", lua_Joint_getTranslationY},
  95. {"getTranslationZ", lua_Joint_getTranslationZ},
  96. {"getType", lua_Joint_getType},
  97. {"getUpVector", lua_Joint_getUpVector},
  98. {"getUpVectorWorld", lua_Joint_getUpVectorWorld},
  99. {"getViewMatrix", lua_Joint_getViewMatrix},
  100. {"getViewProjectionMatrix", lua_Joint_getViewProjectionMatrix},
  101. {"getWorldMatrix", lua_Joint_getWorldMatrix},
  102. {"getWorldViewMatrix", lua_Joint_getWorldViewMatrix},
  103. {"getWorldViewProjectionMatrix", lua_Joint_getWorldViewProjectionMatrix},
  104. {"hasTag", lua_Joint_hasTag},
  105. {"isStatic", lua_Joint_isStatic},
  106. {"release", lua_Joint_release},
  107. {"removeAllChildren", lua_Joint_removeAllChildren},
  108. {"removeChild", lua_Joint_removeChild},
  109. {"removeListener", lua_Joint_removeListener},
  110. {"removeScriptCallback", lua_Joint_removeScriptCallback},
  111. {"rotate", lua_Joint_rotate},
  112. {"rotateX", lua_Joint_rotateX},
  113. {"rotateY", lua_Joint_rotateY},
  114. {"rotateZ", lua_Joint_rotateZ},
  115. {"scale", lua_Joint_scale},
  116. {"scaleX", lua_Joint_scaleX},
  117. {"scaleY", lua_Joint_scaleY},
  118. {"scaleZ", lua_Joint_scaleZ},
  119. {"set", lua_Joint_set},
  120. {"setAgent", lua_Joint_setAgent},
  121. {"setAnimationPropertyValue", lua_Joint_setAnimationPropertyValue},
  122. {"setAudioSource", lua_Joint_setAudioSource},
  123. {"setCamera", lua_Joint_setCamera},
  124. {"setCollisionObject", lua_Joint_setCollisionObject},
  125. {"setForm", lua_Joint_setForm},
  126. {"setId", lua_Joint_setId},
  127. {"setIdentity", lua_Joint_setIdentity},
  128. {"setLight", lua_Joint_setLight},
  129. {"setModel", lua_Joint_setModel},
  130. {"setParticleEmitter", lua_Joint_setParticleEmitter},
  131. {"setRotation", lua_Joint_setRotation},
  132. {"setScale", lua_Joint_setScale},
  133. {"setScaleX", lua_Joint_setScaleX},
  134. {"setScaleY", lua_Joint_setScaleY},
  135. {"setScaleZ", lua_Joint_setScaleZ},
  136. {"setTag", lua_Joint_setTag},
  137. {"setTerrain", lua_Joint_setTerrain},
  138. {"setTranslation", lua_Joint_setTranslation},
  139. {"setTranslationX", lua_Joint_setTranslationX},
  140. {"setTranslationY", lua_Joint_setTranslationY},
  141. {"setTranslationZ", lua_Joint_setTranslationZ},
  142. {"transformPoint", lua_Joint_transformPoint},
  143. {"transformVector", lua_Joint_transformVector},
  144. {"translate", lua_Joint_translate},
  145. {"translateForward", lua_Joint_translateForward},
  146. {"translateLeft", lua_Joint_translateLeft},
  147. {"translateSmooth", lua_Joint_translateSmooth},
  148. {"translateUp", lua_Joint_translateUp},
  149. {"translateX", lua_Joint_translateX},
  150. {"translateY", lua_Joint_translateY},
  151. {"translateZ", lua_Joint_translateZ},
  152. {NULL, NULL}
  153. };
  154. const luaL_Reg lua_statics[] =
  155. {
  156. {"ANIMATE_ROTATE", lua_Joint_static_ANIMATE_ROTATE},
  157. {"ANIMATE_ROTATE_TRANSLATE", lua_Joint_static_ANIMATE_ROTATE_TRANSLATE},
  158. {"ANIMATE_SCALE", lua_Joint_static_ANIMATE_SCALE},
  159. {"ANIMATE_SCALE_ROTATE", lua_Joint_static_ANIMATE_SCALE_ROTATE},
  160. {"ANIMATE_SCALE_ROTATE_TRANSLATE", lua_Joint_static_ANIMATE_SCALE_ROTATE_TRANSLATE},
  161. {"ANIMATE_SCALE_TRANSLATE", lua_Joint_static_ANIMATE_SCALE_TRANSLATE},
  162. {"ANIMATE_SCALE_UNIT", lua_Joint_static_ANIMATE_SCALE_UNIT},
  163. {"ANIMATE_SCALE_X", lua_Joint_static_ANIMATE_SCALE_X},
  164. {"ANIMATE_SCALE_Y", lua_Joint_static_ANIMATE_SCALE_Y},
  165. {"ANIMATE_SCALE_Z", lua_Joint_static_ANIMATE_SCALE_Z},
  166. {"ANIMATE_TRANSLATE", lua_Joint_static_ANIMATE_TRANSLATE},
  167. {"ANIMATE_TRANSLATE_X", lua_Joint_static_ANIMATE_TRANSLATE_X},
  168. {"ANIMATE_TRANSLATE_Y", lua_Joint_static_ANIMATE_TRANSLATE_Y},
  169. {"ANIMATE_TRANSLATE_Z", lua_Joint_static_ANIMATE_TRANSLATE_Z},
  170. {"isTransformChangedSuspended", lua_Joint_static_isTransformChangedSuspended},
  171. {"resumeTransformChanged", lua_Joint_static_resumeTransformChanged},
  172. {"suspendTransformChanged", lua_Joint_static_suspendTransformChanged},
  173. {NULL, NULL}
  174. };
  175. std::vector<std::string> scopePath;
  176. gameplay::ScriptUtil::registerClass("Joint", lua_members, NULL, lua_Joint__gc, lua_statics, scopePath);
  177. }
  178. static Joint* getInstance(lua_State* state)
  179. {
  180. void* userdata = luaL_checkudata(state, 1, "Joint");
  181. luaL_argcheck(state, userdata != NULL, 1, "'Joint' expected.");
  182. return (Joint*)((gameplay::ScriptUtil::LuaObject*)userdata)->instance;
  183. }
  184. int lua_Joint__gc(lua_State* state)
  185. {
  186. // Get the number of parameters.
  187. int paramCount = lua_gettop(state);
  188. // Attempt to match the parameters to a valid binding.
  189. switch (paramCount)
  190. {
  191. case 1:
  192. {
  193. if ((lua_type(state, 1) == LUA_TUSERDATA))
  194. {
  195. void* userdata = luaL_checkudata(state, 1, "Joint");
  196. luaL_argcheck(state, userdata != NULL, 1, "'Joint' expected.");
  197. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)userdata;
  198. if (object->owns)
  199. {
  200. Joint* instance = (Joint*)object->instance;
  201. SAFE_RELEASE(instance);
  202. }
  203. return 0;
  204. }
  205. lua_pushstring(state, "lua_Joint__gc - Failed to match the given parameters to a valid function signature.");
  206. lua_error(state);
  207. break;
  208. }
  209. default:
  210. {
  211. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  212. lua_error(state);
  213. break;
  214. }
  215. }
  216. return 0;
  217. }
  218. int lua_Joint_addAdvertisedDescendant(lua_State* state)
  219. {
  220. // Get the number of parameters.
  221. int paramCount = lua_gettop(state);
  222. // Attempt to match the parameters to a valid binding.
  223. switch (paramCount)
  224. {
  225. case 2:
  226. {
  227. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  228. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  229. {
  230. // Get parameter 1 off the stack.
  231. bool param1Valid;
  232. gameplay::ScriptUtil::LuaArray<Node> param1 = gameplay::ScriptUtil::getObjectPointer<Node>(2, "Node", false, &param1Valid);
  233. if (!param1Valid)
  234. {
  235. lua_pushstring(state, "Failed to convert parameter 1 to type 'Node'.");
  236. lua_error(state);
  237. }
  238. Joint* instance = getInstance(state);
  239. instance->addAdvertisedDescendant(param1);
  240. return 0;
  241. }
  242. lua_pushstring(state, "lua_Joint_addAdvertisedDescendant - Failed to match the given parameters to a valid function signature.");
  243. lua_error(state);
  244. break;
  245. }
  246. default:
  247. {
  248. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  249. lua_error(state);
  250. break;
  251. }
  252. }
  253. return 0;
  254. }
  255. int lua_Joint_addChild(lua_State* state)
  256. {
  257. // Get the number of parameters.
  258. int paramCount = lua_gettop(state);
  259. // Attempt to match the parameters to a valid binding.
  260. switch (paramCount)
  261. {
  262. case 2:
  263. {
  264. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  265. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  266. {
  267. // Get parameter 1 off the stack.
  268. bool param1Valid;
  269. gameplay::ScriptUtil::LuaArray<Node> param1 = gameplay::ScriptUtil::getObjectPointer<Node>(2, "Node", false, &param1Valid);
  270. if (!param1Valid)
  271. {
  272. lua_pushstring(state, "Failed to convert parameter 1 to type 'Node'.");
  273. lua_error(state);
  274. }
  275. Joint* instance = getInstance(state);
  276. instance->addChild(param1);
  277. return 0;
  278. }
  279. lua_pushstring(state, "lua_Joint_addChild - Failed to match the given parameters to a valid function signature.");
  280. lua_error(state);
  281. break;
  282. }
  283. default:
  284. {
  285. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  286. lua_error(state);
  287. break;
  288. }
  289. }
  290. return 0;
  291. }
  292. int lua_Joint_addListener(lua_State* state)
  293. {
  294. // Get the number of parameters.
  295. int paramCount = lua_gettop(state);
  296. // Attempt to match the parameters to a valid binding.
  297. switch (paramCount)
  298. {
  299. case 2:
  300. {
  301. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  302. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  303. {
  304. // Get parameter 1 off the stack.
  305. bool param1Valid;
  306. gameplay::ScriptUtil::LuaArray<Transform::Listener> param1 = gameplay::ScriptUtil::getObjectPointer<Transform::Listener>(2, "TransformListener", false, &param1Valid);
  307. if (!param1Valid)
  308. {
  309. lua_pushstring(state, "Failed to convert parameter 1 to type 'Transform::Listener'.");
  310. lua_error(state);
  311. }
  312. Joint* instance = getInstance(state);
  313. instance->addListener(param1);
  314. return 0;
  315. }
  316. lua_pushstring(state, "lua_Joint_addListener - Failed to match the given parameters to a valid function signature.");
  317. lua_error(state);
  318. break;
  319. }
  320. case 3:
  321. {
  322. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  323. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL) &&
  324. lua_type(state, 3) == LUA_TNUMBER)
  325. {
  326. // Get parameter 1 off the stack.
  327. bool param1Valid;
  328. gameplay::ScriptUtil::LuaArray<Transform::Listener> param1 = gameplay::ScriptUtil::getObjectPointer<Transform::Listener>(2, "TransformListener", false, &param1Valid);
  329. if (!param1Valid)
  330. {
  331. lua_pushstring(state, "Failed to convert parameter 1 to type 'Transform::Listener'.");
  332. lua_error(state);
  333. }
  334. // Get parameter 2 off the stack.
  335. long param2 = (long)luaL_checklong(state, 3);
  336. Joint* instance = getInstance(state);
  337. instance->addListener(param1, param2);
  338. return 0;
  339. }
  340. lua_pushstring(state, "lua_Joint_addListener - Failed to match the given parameters to a valid function signature.");
  341. lua_error(state);
  342. break;
  343. }
  344. default:
  345. {
  346. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  347. lua_error(state);
  348. break;
  349. }
  350. }
  351. return 0;
  352. }
  353. int lua_Joint_addRef(lua_State* state)
  354. {
  355. // Get the number of parameters.
  356. int paramCount = lua_gettop(state);
  357. // Attempt to match the parameters to a valid binding.
  358. switch (paramCount)
  359. {
  360. case 1:
  361. {
  362. if ((lua_type(state, 1) == LUA_TUSERDATA))
  363. {
  364. Joint* instance = getInstance(state);
  365. instance->addRef();
  366. return 0;
  367. }
  368. lua_pushstring(state, "lua_Joint_addRef - Failed to match the given parameters to a valid function signature.");
  369. lua_error(state);
  370. break;
  371. }
  372. default:
  373. {
  374. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  375. lua_error(state);
  376. break;
  377. }
  378. }
  379. return 0;
  380. }
  381. int lua_Joint_addScriptCallback(lua_State* state)
  382. {
  383. // Get the number of parameters.
  384. int paramCount = lua_gettop(state);
  385. // Attempt to match the parameters to a valid binding.
  386. switch (paramCount)
  387. {
  388. case 3:
  389. {
  390. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  391. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  392. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  393. {
  394. // Get parameter 1 off the stack.
  395. std::string param1 = gameplay::ScriptUtil::getString(2, true);
  396. // Get parameter 2 off the stack.
  397. std::string param2 = gameplay::ScriptUtil::getString(3, true);
  398. Joint* instance = getInstance(state);
  399. instance->addScriptCallback(param1, param2);
  400. return 0;
  401. }
  402. lua_pushstring(state, "lua_Joint_addScriptCallback - Failed to match the given parameters to a valid function signature.");
  403. lua_error(state);
  404. break;
  405. }
  406. default:
  407. {
  408. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  409. lua_error(state);
  410. break;
  411. }
  412. }
  413. return 0;
  414. }
  415. int lua_Joint_clone(lua_State* state)
  416. {
  417. // Get the number of parameters.
  418. int paramCount = lua_gettop(state);
  419. // Attempt to match the parameters to a valid binding.
  420. switch (paramCount)
  421. {
  422. case 1:
  423. {
  424. if ((lua_type(state, 1) == LUA_TUSERDATA))
  425. {
  426. Joint* instance = getInstance(state);
  427. void* returnPtr = (void*)instance->clone();
  428. if (returnPtr)
  429. {
  430. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  431. object->instance = returnPtr;
  432. object->owns = true;
  433. luaL_getmetatable(state, "Node");
  434. lua_setmetatable(state, -2);
  435. }
  436. else
  437. {
  438. lua_pushnil(state);
  439. }
  440. return 1;
  441. }
  442. lua_pushstring(state, "lua_Joint_clone - Failed to match the given parameters to a valid function signature.");
  443. lua_error(state);
  444. break;
  445. }
  446. default:
  447. {
  448. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  449. lua_error(state);
  450. break;
  451. }
  452. }
  453. return 0;
  454. }
  455. int lua_Joint_createAnimation(lua_State* state)
  456. {
  457. // Get the number of parameters.
  458. int paramCount = lua_gettop(state);
  459. // Attempt to match the parameters to a valid binding.
  460. switch (paramCount)
  461. {
  462. case 3:
  463. {
  464. do
  465. {
  466. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  467. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  468. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  469. {
  470. // Get parameter 1 off the stack.
  471. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  472. // Get parameter 2 off the stack.
  473. const char* param2 = gameplay::ScriptUtil::getString(3, false);
  474. Joint* instance = getInstance(state);
  475. void* returnPtr = (void*)instance->createAnimation(param1, param2);
  476. if (returnPtr)
  477. {
  478. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  479. object->instance = returnPtr;
  480. object->owns = false;
  481. luaL_getmetatable(state, "Animation");
  482. lua_setmetatable(state, -2);
  483. }
  484. else
  485. {
  486. lua_pushnil(state);
  487. }
  488. return 1;
  489. }
  490. } while (0);
  491. do
  492. {
  493. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  494. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  495. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  496. {
  497. // Get parameter 1 off the stack.
  498. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  499. // Get parameter 2 off the stack.
  500. bool param2Valid;
  501. gameplay::ScriptUtil::LuaArray<Properties> param2 = gameplay::ScriptUtil::getObjectPointer<Properties>(3, "Properties", false, &param2Valid);
  502. if (!param2Valid)
  503. break;
  504. Joint* instance = getInstance(state);
  505. void* returnPtr = (void*)instance->createAnimation(param1, param2);
  506. if (returnPtr)
  507. {
  508. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  509. object->instance = returnPtr;
  510. object->owns = false;
  511. luaL_getmetatable(state, "Animation");
  512. lua_setmetatable(state, -2);
  513. }
  514. else
  515. {
  516. lua_pushnil(state);
  517. }
  518. return 1;
  519. }
  520. } while (0);
  521. lua_pushstring(state, "lua_Joint_createAnimation - Failed to match the given parameters to a valid function signature.");
  522. lua_error(state);
  523. break;
  524. }
  525. case 7:
  526. {
  527. do
  528. {
  529. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  530. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  531. lua_type(state, 3) == LUA_TNUMBER &&
  532. lua_type(state, 4) == LUA_TNUMBER &&
  533. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  534. (lua_type(state, 6) == LUA_TTABLE || lua_type(state, 6) == LUA_TLIGHTUSERDATA) &&
  535. (lua_type(state, 7) == LUA_TSTRING || lua_type(state, 7) == LUA_TNIL))
  536. {
  537. // Get parameter 1 off the stack.
  538. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  539. // Get parameter 2 off the stack.
  540. int param2 = (int)luaL_checkint(state, 3);
  541. // Get parameter 3 off the stack.
  542. unsigned int param3 = (unsigned int)luaL_checkunsigned(state, 4);
  543. // Get parameter 4 off the stack.
  544. gameplay::ScriptUtil::LuaArray<unsigned int> param4 = gameplay::ScriptUtil::getUnsignedIntPointer(5);
  545. // Get parameter 5 off the stack.
  546. gameplay::ScriptUtil::LuaArray<float> param5 = gameplay::ScriptUtil::getFloatPointer(6);
  547. // Get parameter 6 off the stack.
  548. Curve::InterpolationType param6 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 7));
  549. Joint* instance = getInstance(state);
  550. void* returnPtr = (void*)instance->createAnimation(param1, param2, param3, param4, param5, param6);
  551. if (returnPtr)
  552. {
  553. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  554. object->instance = returnPtr;
  555. object->owns = false;
  556. luaL_getmetatable(state, "Animation");
  557. lua_setmetatable(state, -2);
  558. }
  559. else
  560. {
  561. lua_pushnil(state);
  562. }
  563. return 1;
  564. }
  565. } while (0);
  566. lua_pushstring(state, "lua_Joint_createAnimation - Failed to match the given parameters to a valid function signature.");
  567. lua_error(state);
  568. break;
  569. }
  570. case 9:
  571. {
  572. do
  573. {
  574. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  575. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  576. lua_type(state, 3) == LUA_TNUMBER &&
  577. lua_type(state, 4) == LUA_TNUMBER &&
  578. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  579. (lua_type(state, 6) == LUA_TTABLE || lua_type(state, 6) == LUA_TLIGHTUSERDATA) &&
  580. (lua_type(state, 7) == LUA_TTABLE || lua_type(state, 7) == LUA_TLIGHTUSERDATA) &&
  581. (lua_type(state, 8) == LUA_TTABLE || lua_type(state, 8) == LUA_TLIGHTUSERDATA) &&
  582. (lua_type(state, 9) == LUA_TSTRING || lua_type(state, 9) == LUA_TNIL))
  583. {
  584. // Get parameter 1 off the stack.
  585. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  586. // Get parameter 2 off the stack.
  587. int param2 = (int)luaL_checkint(state, 3);
  588. // Get parameter 3 off the stack.
  589. unsigned int param3 = (unsigned int)luaL_checkunsigned(state, 4);
  590. // Get parameter 4 off the stack.
  591. gameplay::ScriptUtil::LuaArray<unsigned int> param4 = gameplay::ScriptUtil::getUnsignedIntPointer(5);
  592. // Get parameter 5 off the stack.
  593. gameplay::ScriptUtil::LuaArray<float> param5 = gameplay::ScriptUtil::getFloatPointer(6);
  594. // Get parameter 6 off the stack.
  595. gameplay::ScriptUtil::LuaArray<float> param6 = gameplay::ScriptUtil::getFloatPointer(7);
  596. // Get parameter 7 off the stack.
  597. gameplay::ScriptUtil::LuaArray<float> param7 = gameplay::ScriptUtil::getFloatPointer(8);
  598. // Get parameter 8 off the stack.
  599. Curve::InterpolationType param8 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 9));
  600. Joint* instance = getInstance(state);
  601. void* returnPtr = (void*)instance->createAnimation(param1, param2, param3, param4, param5, param6, param7, param8);
  602. if (returnPtr)
  603. {
  604. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  605. object->instance = returnPtr;
  606. object->owns = false;
  607. luaL_getmetatable(state, "Animation");
  608. lua_setmetatable(state, -2);
  609. }
  610. else
  611. {
  612. lua_pushnil(state);
  613. }
  614. return 1;
  615. }
  616. } while (0);
  617. lua_pushstring(state, "lua_Joint_createAnimation - Failed to match the given parameters to a valid function signature.");
  618. lua_error(state);
  619. break;
  620. }
  621. default:
  622. {
  623. lua_pushstring(state, "Invalid number of parameters (expected 3, 7 or 9).");
  624. lua_error(state);
  625. break;
  626. }
  627. }
  628. return 0;
  629. }
  630. int lua_Joint_createAnimationFromBy(lua_State* state)
  631. {
  632. // Get the number of parameters.
  633. int paramCount = lua_gettop(state);
  634. // Attempt to match the parameters to a valid binding.
  635. switch (paramCount)
  636. {
  637. case 7:
  638. {
  639. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  640. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  641. lua_type(state, 3) == LUA_TNUMBER &&
  642. (lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TLIGHTUSERDATA) &&
  643. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  644. (lua_type(state, 6) == LUA_TSTRING || lua_type(state, 6) == LUA_TNIL) &&
  645. lua_type(state, 7) == LUA_TNUMBER)
  646. {
  647. // Get parameter 1 off the stack.
  648. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  649. // Get parameter 2 off the stack.
  650. int param2 = (int)luaL_checkint(state, 3);
  651. // Get parameter 3 off the stack.
  652. gameplay::ScriptUtil::LuaArray<float> param3 = gameplay::ScriptUtil::getFloatPointer(4);
  653. // Get parameter 4 off the stack.
  654. gameplay::ScriptUtil::LuaArray<float> param4 = gameplay::ScriptUtil::getFloatPointer(5);
  655. // Get parameter 5 off the stack.
  656. Curve::InterpolationType param5 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 6));
  657. // Get parameter 6 off the stack.
  658. unsigned long param6 = (unsigned long)luaL_checkunsigned(state, 7);
  659. Joint* instance = getInstance(state);
  660. void* returnPtr = (void*)instance->createAnimationFromBy(param1, param2, param3, param4, param5, param6);
  661. if (returnPtr)
  662. {
  663. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  664. object->instance = returnPtr;
  665. object->owns = false;
  666. luaL_getmetatable(state, "Animation");
  667. lua_setmetatable(state, -2);
  668. }
  669. else
  670. {
  671. lua_pushnil(state);
  672. }
  673. return 1;
  674. }
  675. lua_pushstring(state, "lua_Joint_createAnimationFromBy - Failed to match the given parameters to a valid function signature.");
  676. lua_error(state);
  677. break;
  678. }
  679. default:
  680. {
  681. lua_pushstring(state, "Invalid number of parameters (expected 7).");
  682. lua_error(state);
  683. break;
  684. }
  685. }
  686. return 0;
  687. }
  688. int lua_Joint_createAnimationFromTo(lua_State* state)
  689. {
  690. // Get the number of parameters.
  691. int paramCount = lua_gettop(state);
  692. // Attempt to match the parameters to a valid binding.
  693. switch (paramCount)
  694. {
  695. case 7:
  696. {
  697. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  698. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  699. lua_type(state, 3) == LUA_TNUMBER &&
  700. (lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TLIGHTUSERDATA) &&
  701. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  702. (lua_type(state, 6) == LUA_TSTRING || lua_type(state, 6) == LUA_TNIL) &&
  703. lua_type(state, 7) == LUA_TNUMBER)
  704. {
  705. // Get parameter 1 off the stack.
  706. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  707. // Get parameter 2 off the stack.
  708. int param2 = (int)luaL_checkint(state, 3);
  709. // Get parameter 3 off the stack.
  710. gameplay::ScriptUtil::LuaArray<float> param3 = gameplay::ScriptUtil::getFloatPointer(4);
  711. // Get parameter 4 off the stack.
  712. gameplay::ScriptUtil::LuaArray<float> param4 = gameplay::ScriptUtil::getFloatPointer(5);
  713. // Get parameter 5 off the stack.
  714. Curve::InterpolationType param5 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 6));
  715. // Get parameter 6 off the stack.
  716. unsigned long param6 = (unsigned long)luaL_checkunsigned(state, 7);
  717. Joint* instance = getInstance(state);
  718. void* returnPtr = (void*)instance->createAnimationFromTo(param1, param2, param3, param4, param5, param6);
  719. if (returnPtr)
  720. {
  721. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  722. object->instance = returnPtr;
  723. object->owns = false;
  724. luaL_getmetatable(state, "Animation");
  725. lua_setmetatable(state, -2);
  726. }
  727. else
  728. {
  729. lua_pushnil(state);
  730. }
  731. return 1;
  732. }
  733. lua_pushstring(state, "lua_Joint_createAnimationFromTo - Failed to match the given parameters to a valid function signature.");
  734. lua_error(state);
  735. break;
  736. }
  737. default:
  738. {
  739. lua_pushstring(state, "Invalid number of parameters (expected 7).");
  740. lua_error(state);
  741. break;
  742. }
  743. }
  744. return 0;
  745. }
  746. int lua_Joint_destroyAnimation(lua_State* state)
  747. {
  748. // Get the number of parameters.
  749. int paramCount = lua_gettop(state);
  750. // Attempt to match the parameters to a valid binding.
  751. switch (paramCount)
  752. {
  753. case 1:
  754. {
  755. if ((lua_type(state, 1) == LUA_TUSERDATA))
  756. {
  757. Joint* instance = getInstance(state);
  758. instance->destroyAnimation();
  759. return 0;
  760. }
  761. lua_pushstring(state, "lua_Joint_destroyAnimation - Failed to match the given parameters to a valid function signature.");
  762. lua_error(state);
  763. break;
  764. }
  765. case 2:
  766. {
  767. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  768. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  769. {
  770. // Get parameter 1 off the stack.
  771. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  772. Joint* instance = getInstance(state);
  773. instance->destroyAnimation(param1);
  774. return 0;
  775. }
  776. lua_pushstring(state, "lua_Joint_destroyAnimation - Failed to match the given parameters to a valid function signature.");
  777. lua_error(state);
  778. break;
  779. }
  780. default:
  781. {
  782. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  783. lua_error(state);
  784. break;
  785. }
  786. }
  787. return 0;
  788. }
  789. int lua_Joint_findNode(lua_State* state)
  790. {
  791. // Get the number of parameters.
  792. int paramCount = lua_gettop(state);
  793. // Attempt to match the parameters to a valid binding.
  794. switch (paramCount)
  795. {
  796. case 2:
  797. {
  798. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  799. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  800. {
  801. // Get parameter 1 off the stack.
  802. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  803. Joint* instance = getInstance(state);
  804. void* returnPtr = (void*)instance->findNode(param1);
  805. if (returnPtr)
  806. {
  807. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  808. object->instance = returnPtr;
  809. object->owns = false;
  810. luaL_getmetatable(state, "Node");
  811. lua_setmetatable(state, -2);
  812. }
  813. else
  814. {
  815. lua_pushnil(state);
  816. }
  817. return 1;
  818. }
  819. lua_pushstring(state, "lua_Joint_findNode - Failed to match the given parameters to a valid function signature.");
  820. lua_error(state);
  821. break;
  822. }
  823. case 3:
  824. {
  825. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  826. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  827. lua_type(state, 3) == LUA_TBOOLEAN)
  828. {
  829. // Get parameter 1 off the stack.
  830. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  831. // Get parameter 2 off the stack.
  832. bool param2 = gameplay::ScriptUtil::luaCheckBool(state, 3);
  833. Joint* instance = getInstance(state);
  834. void* returnPtr = (void*)instance->findNode(param1, param2);
  835. if (returnPtr)
  836. {
  837. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  838. object->instance = returnPtr;
  839. object->owns = false;
  840. luaL_getmetatable(state, "Node");
  841. lua_setmetatable(state, -2);
  842. }
  843. else
  844. {
  845. lua_pushnil(state);
  846. }
  847. return 1;
  848. }
  849. lua_pushstring(state, "lua_Joint_findNode - Failed to match the given parameters to a valid function signature.");
  850. lua_error(state);
  851. break;
  852. }
  853. case 4:
  854. {
  855. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  856. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  857. lua_type(state, 3) == LUA_TBOOLEAN &&
  858. lua_type(state, 4) == LUA_TBOOLEAN)
  859. {
  860. // Get parameter 1 off the stack.
  861. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  862. // Get parameter 2 off the stack.
  863. bool param2 = gameplay::ScriptUtil::luaCheckBool(state, 3);
  864. // Get parameter 3 off the stack.
  865. bool param3 = gameplay::ScriptUtil::luaCheckBool(state, 4);
  866. Joint* instance = getInstance(state);
  867. void* returnPtr = (void*)instance->findNode(param1, param2, param3);
  868. if (returnPtr)
  869. {
  870. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  871. object->instance = returnPtr;
  872. object->owns = false;
  873. luaL_getmetatable(state, "Node");
  874. lua_setmetatable(state, -2);
  875. }
  876. else
  877. {
  878. lua_pushnil(state);
  879. }
  880. return 1;
  881. }
  882. lua_pushstring(state, "lua_Joint_findNode - Failed to match the given parameters to a valid function signature.");
  883. lua_error(state);
  884. break;
  885. }
  886. default:
  887. {
  888. lua_pushstring(state, "Invalid number of parameters (expected 2, 3 or 4).");
  889. lua_error(state);
  890. break;
  891. }
  892. }
  893. return 0;
  894. }
  895. int lua_Joint_getActiveCameraTranslationView(lua_State* state)
  896. {
  897. // Get the number of parameters.
  898. int paramCount = lua_gettop(state);
  899. // Attempt to match the parameters to a valid binding.
  900. switch (paramCount)
  901. {
  902. case 1:
  903. {
  904. if ((lua_type(state, 1) == LUA_TUSERDATA))
  905. {
  906. Joint* instance = getInstance(state);
  907. void* returnPtr = (void*)new Vector3(instance->getActiveCameraTranslationView());
  908. if (returnPtr)
  909. {
  910. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  911. object->instance = returnPtr;
  912. object->owns = true;
  913. luaL_getmetatable(state, "Vector3");
  914. lua_setmetatable(state, -2);
  915. }
  916. else
  917. {
  918. lua_pushnil(state);
  919. }
  920. return 1;
  921. }
  922. lua_pushstring(state, "lua_Joint_getActiveCameraTranslationView - Failed to match the given parameters to a valid function signature.");
  923. lua_error(state);
  924. break;
  925. }
  926. default:
  927. {
  928. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  929. lua_error(state);
  930. break;
  931. }
  932. }
  933. return 0;
  934. }
  935. int lua_Joint_getActiveCameraTranslationWorld(lua_State* state)
  936. {
  937. // Get the number of parameters.
  938. int paramCount = lua_gettop(state);
  939. // Attempt to match the parameters to a valid binding.
  940. switch (paramCount)
  941. {
  942. case 1:
  943. {
  944. if ((lua_type(state, 1) == LUA_TUSERDATA))
  945. {
  946. Joint* instance = getInstance(state);
  947. void* returnPtr = (void*)new Vector3(instance->getActiveCameraTranslationWorld());
  948. if (returnPtr)
  949. {
  950. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  951. object->instance = returnPtr;
  952. object->owns = true;
  953. luaL_getmetatable(state, "Vector3");
  954. lua_setmetatable(state, -2);
  955. }
  956. else
  957. {
  958. lua_pushnil(state);
  959. }
  960. return 1;
  961. }
  962. lua_pushstring(state, "lua_Joint_getActiveCameraTranslationWorld - Failed to match the given parameters to a valid function signature.");
  963. lua_error(state);
  964. break;
  965. }
  966. default:
  967. {
  968. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  969. lua_error(state);
  970. break;
  971. }
  972. }
  973. return 0;
  974. }
  975. int lua_Joint_getAdvertisedDescendant(lua_State* state)
  976. {
  977. // Get the number of parameters.
  978. int paramCount = lua_gettop(state);
  979. // Attempt to match the parameters to a valid binding.
  980. switch (paramCount)
  981. {
  982. case 2:
  983. {
  984. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  985. lua_type(state, 2) == LUA_TNUMBER)
  986. {
  987. // Get parameter 1 off the stack.
  988. unsigned int param1 = (unsigned int)luaL_checkunsigned(state, 2);
  989. Joint* instance = getInstance(state);
  990. void* returnPtr = (void*)instance->getAdvertisedDescendant(param1);
  991. if (returnPtr)
  992. {
  993. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  994. object->instance = returnPtr;
  995. object->owns = false;
  996. luaL_getmetatable(state, "Node");
  997. lua_setmetatable(state, -2);
  998. }
  999. else
  1000. {
  1001. lua_pushnil(state);
  1002. }
  1003. return 1;
  1004. }
  1005. lua_pushstring(state, "lua_Joint_getAdvertisedDescendant - Failed to match the given parameters to a valid function signature.");
  1006. lua_error(state);
  1007. break;
  1008. }
  1009. default:
  1010. {
  1011. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  1012. lua_error(state);
  1013. break;
  1014. }
  1015. }
  1016. return 0;
  1017. }
  1018. int lua_Joint_getAgent(lua_State* state)
  1019. {
  1020. // Get the number of parameters.
  1021. int paramCount = lua_gettop(state);
  1022. // Attempt to match the parameters to a valid binding.
  1023. switch (paramCount)
  1024. {
  1025. case 1:
  1026. {
  1027. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1028. {
  1029. Joint* instance = getInstance(state);
  1030. void* returnPtr = (void*)instance->getAgent();
  1031. if (returnPtr)
  1032. {
  1033. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1034. object->instance = returnPtr;
  1035. object->owns = false;
  1036. luaL_getmetatable(state, "AIAgent");
  1037. lua_setmetatable(state, -2);
  1038. }
  1039. else
  1040. {
  1041. lua_pushnil(state);
  1042. }
  1043. return 1;
  1044. }
  1045. lua_pushstring(state, "lua_Joint_getAgent - Failed to match the given parameters to a valid function signature.");
  1046. lua_error(state);
  1047. break;
  1048. }
  1049. default:
  1050. {
  1051. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1052. lua_error(state);
  1053. break;
  1054. }
  1055. }
  1056. return 0;
  1057. }
  1058. int lua_Joint_getAnimation(lua_State* state)
  1059. {
  1060. // Get the number of parameters.
  1061. int paramCount = lua_gettop(state);
  1062. // Attempt to match the parameters to a valid binding.
  1063. switch (paramCount)
  1064. {
  1065. case 1:
  1066. {
  1067. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1068. {
  1069. Joint* instance = getInstance(state);
  1070. void* returnPtr = (void*)instance->getAnimation();
  1071. if (returnPtr)
  1072. {
  1073. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1074. object->instance = returnPtr;
  1075. object->owns = false;
  1076. luaL_getmetatable(state, "Animation");
  1077. lua_setmetatable(state, -2);
  1078. }
  1079. else
  1080. {
  1081. lua_pushnil(state);
  1082. }
  1083. return 1;
  1084. }
  1085. lua_pushstring(state, "lua_Joint_getAnimation - Failed to match the given parameters to a valid function signature.");
  1086. lua_error(state);
  1087. break;
  1088. }
  1089. case 2:
  1090. {
  1091. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1092. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1093. {
  1094. // Get parameter 1 off the stack.
  1095. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  1096. Joint* instance = getInstance(state);
  1097. void* returnPtr = (void*)instance->getAnimation(param1);
  1098. if (returnPtr)
  1099. {
  1100. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1101. object->instance = returnPtr;
  1102. object->owns = false;
  1103. luaL_getmetatable(state, "Animation");
  1104. lua_setmetatable(state, -2);
  1105. }
  1106. else
  1107. {
  1108. lua_pushnil(state);
  1109. }
  1110. return 1;
  1111. }
  1112. lua_pushstring(state, "lua_Joint_getAnimation - Failed to match the given parameters to a valid function signature.");
  1113. lua_error(state);
  1114. break;
  1115. }
  1116. default:
  1117. {
  1118. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1119. lua_error(state);
  1120. break;
  1121. }
  1122. }
  1123. return 0;
  1124. }
  1125. int lua_Joint_getAnimationPropertyComponentCount(lua_State* state)
  1126. {
  1127. // Get the number of parameters.
  1128. int paramCount = lua_gettop(state);
  1129. // Attempt to match the parameters to a valid binding.
  1130. switch (paramCount)
  1131. {
  1132. case 2:
  1133. {
  1134. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1135. lua_type(state, 2) == LUA_TNUMBER)
  1136. {
  1137. // Get parameter 1 off the stack.
  1138. int param1 = (int)luaL_checkint(state, 2);
  1139. Joint* instance = getInstance(state);
  1140. unsigned int result = instance->getAnimationPropertyComponentCount(param1);
  1141. // Push the return value onto the stack.
  1142. lua_pushunsigned(state, result);
  1143. return 1;
  1144. }
  1145. lua_pushstring(state, "lua_Joint_getAnimationPropertyComponentCount - Failed to match the given parameters to a valid function signature.");
  1146. lua_error(state);
  1147. break;
  1148. }
  1149. default:
  1150. {
  1151. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  1152. lua_error(state);
  1153. break;
  1154. }
  1155. }
  1156. return 0;
  1157. }
  1158. int lua_Joint_getAnimationPropertyValue(lua_State* state)
  1159. {
  1160. // Get the number of parameters.
  1161. int paramCount = lua_gettop(state);
  1162. // Attempt to match the parameters to a valid binding.
  1163. switch (paramCount)
  1164. {
  1165. case 3:
  1166. {
  1167. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1168. lua_type(state, 2) == LUA_TNUMBER &&
  1169. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  1170. {
  1171. // Get parameter 1 off the stack.
  1172. int param1 = (int)luaL_checkint(state, 2);
  1173. // Get parameter 2 off the stack.
  1174. bool param2Valid;
  1175. gameplay::ScriptUtil::LuaArray<AnimationValue> param2 = gameplay::ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false, &param2Valid);
  1176. if (!param2Valid)
  1177. {
  1178. lua_pushstring(state, "Failed to convert parameter 2 to type 'AnimationValue'.");
  1179. lua_error(state);
  1180. }
  1181. Joint* instance = getInstance(state);
  1182. instance->getAnimationPropertyValue(param1, param2);
  1183. return 0;
  1184. }
  1185. lua_pushstring(state, "lua_Joint_getAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  1186. lua_error(state);
  1187. break;
  1188. }
  1189. default:
  1190. {
  1191. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  1192. lua_error(state);
  1193. break;
  1194. }
  1195. }
  1196. return 0;
  1197. }
  1198. int lua_Joint_getAudioSource(lua_State* state)
  1199. {
  1200. // Get the number of parameters.
  1201. int paramCount = lua_gettop(state);
  1202. // Attempt to match the parameters to a valid binding.
  1203. switch (paramCount)
  1204. {
  1205. case 1:
  1206. {
  1207. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1208. {
  1209. Joint* instance = getInstance(state);
  1210. void* returnPtr = (void*)instance->getAudioSource();
  1211. if (returnPtr)
  1212. {
  1213. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1214. object->instance = returnPtr;
  1215. object->owns = false;
  1216. luaL_getmetatable(state, "AudioSource");
  1217. lua_setmetatable(state, -2);
  1218. }
  1219. else
  1220. {
  1221. lua_pushnil(state);
  1222. }
  1223. return 1;
  1224. }
  1225. lua_pushstring(state, "lua_Joint_getAudioSource - Failed to match the given parameters to a valid function signature.");
  1226. lua_error(state);
  1227. break;
  1228. }
  1229. default:
  1230. {
  1231. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1232. lua_error(state);
  1233. break;
  1234. }
  1235. }
  1236. return 0;
  1237. }
  1238. int lua_Joint_getBackVector(lua_State* state)
  1239. {
  1240. // Get the number of parameters.
  1241. int paramCount = lua_gettop(state);
  1242. // Attempt to match the parameters to a valid binding.
  1243. switch (paramCount)
  1244. {
  1245. case 1:
  1246. {
  1247. do
  1248. {
  1249. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1250. {
  1251. Joint* instance = getInstance(state);
  1252. void* returnPtr = (void*)new Vector3(instance->getBackVector());
  1253. if (returnPtr)
  1254. {
  1255. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1256. object->instance = returnPtr;
  1257. object->owns = true;
  1258. luaL_getmetatable(state, "Vector3");
  1259. lua_setmetatable(state, -2);
  1260. }
  1261. else
  1262. {
  1263. lua_pushnil(state);
  1264. }
  1265. return 1;
  1266. }
  1267. } while (0);
  1268. lua_pushstring(state, "lua_Joint_getBackVector - Failed to match the given parameters to a valid function signature.");
  1269. lua_error(state);
  1270. break;
  1271. }
  1272. case 2:
  1273. {
  1274. do
  1275. {
  1276. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1277. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  1278. {
  1279. // Get parameter 1 off the stack.
  1280. bool param1Valid;
  1281. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  1282. if (!param1Valid)
  1283. break;
  1284. Joint* instance = getInstance(state);
  1285. instance->getBackVector(param1);
  1286. return 0;
  1287. }
  1288. } while (0);
  1289. lua_pushstring(state, "lua_Joint_getBackVector - Failed to match the given parameters to a valid function signature.");
  1290. lua_error(state);
  1291. break;
  1292. }
  1293. default:
  1294. {
  1295. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1296. lua_error(state);
  1297. break;
  1298. }
  1299. }
  1300. return 0;
  1301. }
  1302. int lua_Joint_getBoundingSphere(lua_State* state)
  1303. {
  1304. // Get the number of parameters.
  1305. int paramCount = lua_gettop(state);
  1306. // Attempt to match the parameters to a valid binding.
  1307. switch (paramCount)
  1308. {
  1309. case 1:
  1310. {
  1311. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1312. {
  1313. Joint* instance = getInstance(state);
  1314. void* returnPtr = (void*)&(instance->getBoundingSphere());
  1315. if (returnPtr)
  1316. {
  1317. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1318. object->instance = returnPtr;
  1319. object->owns = false;
  1320. luaL_getmetatable(state, "BoundingSphere");
  1321. lua_setmetatable(state, -2);
  1322. }
  1323. else
  1324. {
  1325. lua_pushnil(state);
  1326. }
  1327. return 1;
  1328. }
  1329. lua_pushstring(state, "lua_Joint_getBoundingSphere - Failed to match the given parameters to a valid function signature.");
  1330. lua_error(state);
  1331. break;
  1332. }
  1333. default:
  1334. {
  1335. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1336. lua_error(state);
  1337. break;
  1338. }
  1339. }
  1340. return 0;
  1341. }
  1342. int lua_Joint_getCamera(lua_State* state)
  1343. {
  1344. // Get the number of parameters.
  1345. int paramCount = lua_gettop(state);
  1346. // Attempt to match the parameters to a valid binding.
  1347. switch (paramCount)
  1348. {
  1349. case 1:
  1350. {
  1351. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1352. {
  1353. Joint* instance = getInstance(state);
  1354. void* returnPtr = (void*)instance->getCamera();
  1355. if (returnPtr)
  1356. {
  1357. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1358. object->instance = returnPtr;
  1359. object->owns = false;
  1360. luaL_getmetatable(state, "Camera");
  1361. lua_setmetatable(state, -2);
  1362. }
  1363. else
  1364. {
  1365. lua_pushnil(state);
  1366. }
  1367. return 1;
  1368. }
  1369. lua_pushstring(state, "lua_Joint_getCamera - Failed to match the given parameters to a valid function signature.");
  1370. lua_error(state);
  1371. break;
  1372. }
  1373. default:
  1374. {
  1375. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1376. lua_error(state);
  1377. break;
  1378. }
  1379. }
  1380. return 0;
  1381. }
  1382. int lua_Joint_getChildCount(lua_State* state)
  1383. {
  1384. // Get the number of parameters.
  1385. int paramCount = lua_gettop(state);
  1386. // Attempt to match the parameters to a valid binding.
  1387. switch (paramCount)
  1388. {
  1389. case 1:
  1390. {
  1391. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1392. {
  1393. Joint* instance = getInstance(state);
  1394. unsigned int result = instance->getChildCount();
  1395. // Push the return value onto the stack.
  1396. lua_pushunsigned(state, result);
  1397. return 1;
  1398. }
  1399. lua_pushstring(state, "lua_Joint_getChildCount - Failed to match the given parameters to a valid function signature.");
  1400. lua_error(state);
  1401. break;
  1402. }
  1403. default:
  1404. {
  1405. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1406. lua_error(state);
  1407. break;
  1408. }
  1409. }
  1410. return 0;
  1411. }
  1412. int lua_Joint_getCollisionObject(lua_State* state)
  1413. {
  1414. // Get the number of parameters.
  1415. int paramCount = lua_gettop(state);
  1416. // Attempt to match the parameters to a valid binding.
  1417. switch (paramCount)
  1418. {
  1419. case 1:
  1420. {
  1421. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1422. {
  1423. Joint* instance = getInstance(state);
  1424. void* returnPtr = (void*)instance->getCollisionObject();
  1425. if (returnPtr)
  1426. {
  1427. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1428. object->instance = returnPtr;
  1429. object->owns = false;
  1430. luaL_getmetatable(state, "PhysicsCollisionObject");
  1431. lua_setmetatable(state, -2);
  1432. }
  1433. else
  1434. {
  1435. lua_pushnil(state);
  1436. }
  1437. return 1;
  1438. }
  1439. lua_pushstring(state, "lua_Joint_getCollisionObject - Failed to match the given parameters to a valid function signature.");
  1440. lua_error(state);
  1441. break;
  1442. }
  1443. default:
  1444. {
  1445. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1446. lua_error(state);
  1447. break;
  1448. }
  1449. }
  1450. return 0;
  1451. }
  1452. int lua_Joint_getDownVector(lua_State* state)
  1453. {
  1454. // Get the number of parameters.
  1455. int paramCount = lua_gettop(state);
  1456. // Attempt to match the parameters to a valid binding.
  1457. switch (paramCount)
  1458. {
  1459. case 1:
  1460. {
  1461. do
  1462. {
  1463. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1464. {
  1465. Joint* instance = getInstance(state);
  1466. void* returnPtr = (void*)new Vector3(instance->getDownVector());
  1467. if (returnPtr)
  1468. {
  1469. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1470. object->instance = returnPtr;
  1471. object->owns = true;
  1472. luaL_getmetatable(state, "Vector3");
  1473. lua_setmetatable(state, -2);
  1474. }
  1475. else
  1476. {
  1477. lua_pushnil(state);
  1478. }
  1479. return 1;
  1480. }
  1481. } while (0);
  1482. lua_pushstring(state, "lua_Joint_getDownVector - Failed to match the given parameters to a valid function signature.");
  1483. lua_error(state);
  1484. break;
  1485. }
  1486. case 2:
  1487. {
  1488. do
  1489. {
  1490. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1491. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  1492. {
  1493. // Get parameter 1 off the stack.
  1494. bool param1Valid;
  1495. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  1496. if (!param1Valid)
  1497. break;
  1498. Joint* instance = getInstance(state);
  1499. instance->getDownVector(param1);
  1500. return 0;
  1501. }
  1502. } while (0);
  1503. lua_pushstring(state, "lua_Joint_getDownVector - Failed to match the given parameters to a valid function signature.");
  1504. lua_error(state);
  1505. break;
  1506. }
  1507. default:
  1508. {
  1509. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1510. lua_error(state);
  1511. break;
  1512. }
  1513. }
  1514. return 0;
  1515. }
  1516. int lua_Joint_getFirstChild(lua_State* state)
  1517. {
  1518. // Get the number of parameters.
  1519. int paramCount = lua_gettop(state);
  1520. // Attempt to match the parameters to a valid binding.
  1521. switch (paramCount)
  1522. {
  1523. case 1:
  1524. {
  1525. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1526. {
  1527. Joint* instance = getInstance(state);
  1528. void* returnPtr = (void*)instance->getFirstChild();
  1529. if (returnPtr)
  1530. {
  1531. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1532. object->instance = returnPtr;
  1533. object->owns = false;
  1534. luaL_getmetatable(state, "Node");
  1535. lua_setmetatable(state, -2);
  1536. }
  1537. else
  1538. {
  1539. lua_pushnil(state);
  1540. }
  1541. return 1;
  1542. }
  1543. lua_pushstring(state, "lua_Joint_getFirstChild - Failed to match the given parameters to a valid function signature.");
  1544. lua_error(state);
  1545. break;
  1546. }
  1547. default:
  1548. {
  1549. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1550. lua_error(state);
  1551. break;
  1552. }
  1553. }
  1554. return 0;
  1555. }
  1556. int lua_Joint_getForm(lua_State* state)
  1557. {
  1558. // Get the number of parameters.
  1559. int paramCount = lua_gettop(state);
  1560. // Attempt to match the parameters to a valid binding.
  1561. switch (paramCount)
  1562. {
  1563. case 1:
  1564. {
  1565. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1566. {
  1567. Joint* instance = getInstance(state);
  1568. void* returnPtr = (void*)instance->getForm();
  1569. if (returnPtr)
  1570. {
  1571. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1572. object->instance = returnPtr;
  1573. object->owns = false;
  1574. luaL_getmetatable(state, "Form");
  1575. lua_setmetatable(state, -2);
  1576. }
  1577. else
  1578. {
  1579. lua_pushnil(state);
  1580. }
  1581. return 1;
  1582. }
  1583. lua_pushstring(state, "lua_Joint_getForm - Failed to match the given parameters to a valid function signature.");
  1584. lua_error(state);
  1585. break;
  1586. }
  1587. default:
  1588. {
  1589. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1590. lua_error(state);
  1591. break;
  1592. }
  1593. }
  1594. return 0;
  1595. }
  1596. int lua_Joint_getForwardVector(lua_State* state)
  1597. {
  1598. // Get the number of parameters.
  1599. int paramCount = lua_gettop(state);
  1600. // Attempt to match the parameters to a valid binding.
  1601. switch (paramCount)
  1602. {
  1603. case 1:
  1604. {
  1605. do
  1606. {
  1607. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1608. {
  1609. Joint* instance = getInstance(state);
  1610. void* returnPtr = (void*)new Vector3(instance->getForwardVector());
  1611. if (returnPtr)
  1612. {
  1613. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1614. object->instance = returnPtr;
  1615. object->owns = true;
  1616. luaL_getmetatable(state, "Vector3");
  1617. lua_setmetatable(state, -2);
  1618. }
  1619. else
  1620. {
  1621. lua_pushnil(state);
  1622. }
  1623. return 1;
  1624. }
  1625. } while (0);
  1626. lua_pushstring(state, "lua_Joint_getForwardVector - Failed to match the given parameters to a valid function signature.");
  1627. lua_error(state);
  1628. break;
  1629. }
  1630. case 2:
  1631. {
  1632. do
  1633. {
  1634. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1635. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  1636. {
  1637. // Get parameter 1 off the stack.
  1638. bool param1Valid;
  1639. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  1640. if (!param1Valid)
  1641. break;
  1642. Joint* instance = getInstance(state);
  1643. instance->getForwardVector(param1);
  1644. return 0;
  1645. }
  1646. } while (0);
  1647. lua_pushstring(state, "lua_Joint_getForwardVector - Failed to match the given parameters to a valid function signature.");
  1648. lua_error(state);
  1649. break;
  1650. }
  1651. default:
  1652. {
  1653. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1654. lua_error(state);
  1655. break;
  1656. }
  1657. }
  1658. return 0;
  1659. }
  1660. int lua_Joint_getForwardVectorView(lua_State* state)
  1661. {
  1662. // Get the number of parameters.
  1663. int paramCount = lua_gettop(state);
  1664. // Attempt to match the parameters to a valid binding.
  1665. switch (paramCount)
  1666. {
  1667. case 1:
  1668. {
  1669. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1670. {
  1671. Joint* instance = getInstance(state);
  1672. void* returnPtr = (void*)new Vector3(instance->getForwardVectorView());
  1673. if (returnPtr)
  1674. {
  1675. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1676. object->instance = returnPtr;
  1677. object->owns = true;
  1678. luaL_getmetatable(state, "Vector3");
  1679. lua_setmetatable(state, -2);
  1680. }
  1681. else
  1682. {
  1683. lua_pushnil(state);
  1684. }
  1685. return 1;
  1686. }
  1687. lua_pushstring(state, "lua_Joint_getForwardVectorView - Failed to match the given parameters to a valid function signature.");
  1688. lua_error(state);
  1689. break;
  1690. }
  1691. default:
  1692. {
  1693. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1694. lua_error(state);
  1695. break;
  1696. }
  1697. }
  1698. return 0;
  1699. }
  1700. int lua_Joint_getForwardVectorWorld(lua_State* state)
  1701. {
  1702. // Get the number of parameters.
  1703. int paramCount = lua_gettop(state);
  1704. // Attempt to match the parameters to a valid binding.
  1705. switch (paramCount)
  1706. {
  1707. case 1:
  1708. {
  1709. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1710. {
  1711. Joint* instance = getInstance(state);
  1712. void* returnPtr = (void*)new Vector3(instance->getForwardVectorWorld());
  1713. if (returnPtr)
  1714. {
  1715. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1716. object->instance = returnPtr;
  1717. object->owns = true;
  1718. luaL_getmetatable(state, "Vector3");
  1719. lua_setmetatable(state, -2);
  1720. }
  1721. else
  1722. {
  1723. lua_pushnil(state);
  1724. }
  1725. return 1;
  1726. }
  1727. lua_pushstring(state, "lua_Joint_getForwardVectorWorld - Failed to match the given parameters to a valid function signature.");
  1728. lua_error(state);
  1729. break;
  1730. }
  1731. default:
  1732. {
  1733. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1734. lua_error(state);
  1735. break;
  1736. }
  1737. }
  1738. return 0;
  1739. }
  1740. int lua_Joint_getId(lua_State* state)
  1741. {
  1742. // Get the number of parameters.
  1743. int paramCount = lua_gettop(state);
  1744. // Attempt to match the parameters to a valid binding.
  1745. switch (paramCount)
  1746. {
  1747. case 1:
  1748. {
  1749. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1750. {
  1751. Joint* instance = getInstance(state);
  1752. const char* result = instance->getId();
  1753. // Push the return value onto the stack.
  1754. lua_pushstring(state, result);
  1755. return 1;
  1756. }
  1757. lua_pushstring(state, "lua_Joint_getId - Failed to match the given parameters to a valid function signature.");
  1758. lua_error(state);
  1759. break;
  1760. }
  1761. default:
  1762. {
  1763. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1764. lua_error(state);
  1765. break;
  1766. }
  1767. }
  1768. return 0;
  1769. }
  1770. int lua_Joint_getInverseBindPose(lua_State* state)
  1771. {
  1772. // Get the number of parameters.
  1773. int paramCount = lua_gettop(state);
  1774. // Attempt to match the parameters to a valid binding.
  1775. switch (paramCount)
  1776. {
  1777. case 1:
  1778. {
  1779. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1780. {
  1781. Joint* instance = getInstance(state);
  1782. void* returnPtr = (void*)&(instance->getInverseBindPose());
  1783. if (returnPtr)
  1784. {
  1785. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1786. object->instance = returnPtr;
  1787. object->owns = false;
  1788. luaL_getmetatable(state, "Matrix");
  1789. lua_setmetatable(state, -2);
  1790. }
  1791. else
  1792. {
  1793. lua_pushnil(state);
  1794. }
  1795. return 1;
  1796. }
  1797. lua_pushstring(state, "lua_Joint_getInverseBindPose - Failed to match the given parameters to a valid function signature.");
  1798. lua_error(state);
  1799. break;
  1800. }
  1801. default:
  1802. {
  1803. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1804. lua_error(state);
  1805. break;
  1806. }
  1807. }
  1808. return 0;
  1809. }
  1810. int lua_Joint_getInverseTransposeWorldMatrix(lua_State* state)
  1811. {
  1812. // Get the number of parameters.
  1813. int paramCount = lua_gettop(state);
  1814. // Attempt to match the parameters to a valid binding.
  1815. switch (paramCount)
  1816. {
  1817. case 1:
  1818. {
  1819. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1820. {
  1821. Joint* instance = getInstance(state);
  1822. void* returnPtr = (void*)&(instance->getInverseTransposeWorldMatrix());
  1823. if (returnPtr)
  1824. {
  1825. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1826. object->instance = returnPtr;
  1827. object->owns = false;
  1828. luaL_getmetatable(state, "Matrix");
  1829. lua_setmetatable(state, -2);
  1830. }
  1831. else
  1832. {
  1833. lua_pushnil(state);
  1834. }
  1835. return 1;
  1836. }
  1837. lua_pushstring(state, "lua_Joint_getInverseTransposeWorldMatrix - Failed to match the given parameters to a valid function signature.");
  1838. lua_error(state);
  1839. break;
  1840. }
  1841. default:
  1842. {
  1843. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1844. lua_error(state);
  1845. break;
  1846. }
  1847. }
  1848. return 0;
  1849. }
  1850. int lua_Joint_getInverseTransposeWorldViewMatrix(lua_State* state)
  1851. {
  1852. // Get the number of parameters.
  1853. int paramCount = lua_gettop(state);
  1854. // Attempt to match the parameters to a valid binding.
  1855. switch (paramCount)
  1856. {
  1857. case 1:
  1858. {
  1859. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1860. {
  1861. Joint* instance = getInstance(state);
  1862. void* returnPtr = (void*)&(instance->getInverseTransposeWorldViewMatrix());
  1863. if (returnPtr)
  1864. {
  1865. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1866. object->instance = returnPtr;
  1867. object->owns = false;
  1868. luaL_getmetatable(state, "Matrix");
  1869. lua_setmetatable(state, -2);
  1870. }
  1871. else
  1872. {
  1873. lua_pushnil(state);
  1874. }
  1875. return 1;
  1876. }
  1877. lua_pushstring(state, "lua_Joint_getInverseTransposeWorldViewMatrix - Failed to match the given parameters to a valid function signature.");
  1878. lua_error(state);
  1879. break;
  1880. }
  1881. default:
  1882. {
  1883. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1884. lua_error(state);
  1885. break;
  1886. }
  1887. }
  1888. return 0;
  1889. }
  1890. int lua_Joint_getInverseViewMatrix(lua_State* state)
  1891. {
  1892. // Get the number of parameters.
  1893. int paramCount = lua_gettop(state);
  1894. // Attempt to match the parameters to a valid binding.
  1895. switch (paramCount)
  1896. {
  1897. case 1:
  1898. {
  1899. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1900. {
  1901. Joint* instance = getInstance(state);
  1902. void* returnPtr = (void*)&(instance->getInverseViewMatrix());
  1903. if (returnPtr)
  1904. {
  1905. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1906. object->instance = returnPtr;
  1907. object->owns = false;
  1908. luaL_getmetatable(state, "Matrix");
  1909. lua_setmetatable(state, -2);
  1910. }
  1911. else
  1912. {
  1913. lua_pushnil(state);
  1914. }
  1915. return 1;
  1916. }
  1917. lua_pushstring(state, "lua_Joint_getInverseViewMatrix - Failed to match the given parameters to a valid function signature.");
  1918. lua_error(state);
  1919. break;
  1920. }
  1921. default:
  1922. {
  1923. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1924. lua_error(state);
  1925. break;
  1926. }
  1927. }
  1928. return 0;
  1929. }
  1930. int lua_Joint_getInverseViewProjectionMatrix(lua_State* state)
  1931. {
  1932. // Get the number of parameters.
  1933. int paramCount = lua_gettop(state);
  1934. // Attempt to match the parameters to a valid binding.
  1935. switch (paramCount)
  1936. {
  1937. case 1:
  1938. {
  1939. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1940. {
  1941. Joint* instance = getInstance(state);
  1942. void* returnPtr = (void*)&(instance->getInverseViewProjectionMatrix());
  1943. if (returnPtr)
  1944. {
  1945. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1946. object->instance = returnPtr;
  1947. object->owns = false;
  1948. luaL_getmetatable(state, "Matrix");
  1949. lua_setmetatable(state, -2);
  1950. }
  1951. else
  1952. {
  1953. lua_pushnil(state);
  1954. }
  1955. return 1;
  1956. }
  1957. lua_pushstring(state, "lua_Joint_getInverseViewProjectionMatrix - Failed to match the given parameters to a valid function signature.");
  1958. lua_error(state);
  1959. break;
  1960. }
  1961. default:
  1962. {
  1963. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1964. lua_error(state);
  1965. break;
  1966. }
  1967. }
  1968. return 0;
  1969. }
  1970. int lua_Joint_getLeftVector(lua_State* state)
  1971. {
  1972. // Get the number of parameters.
  1973. int paramCount = lua_gettop(state);
  1974. // Attempt to match the parameters to a valid binding.
  1975. switch (paramCount)
  1976. {
  1977. case 1:
  1978. {
  1979. do
  1980. {
  1981. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1982. {
  1983. Joint* instance = getInstance(state);
  1984. void* returnPtr = (void*)new Vector3(instance->getLeftVector());
  1985. if (returnPtr)
  1986. {
  1987. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  1988. object->instance = returnPtr;
  1989. object->owns = true;
  1990. luaL_getmetatable(state, "Vector3");
  1991. lua_setmetatable(state, -2);
  1992. }
  1993. else
  1994. {
  1995. lua_pushnil(state);
  1996. }
  1997. return 1;
  1998. }
  1999. } while (0);
  2000. lua_pushstring(state, "lua_Joint_getLeftVector - Failed to match the given parameters to a valid function signature.");
  2001. lua_error(state);
  2002. break;
  2003. }
  2004. case 2:
  2005. {
  2006. do
  2007. {
  2008. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2009. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2010. {
  2011. // Get parameter 1 off the stack.
  2012. bool param1Valid;
  2013. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  2014. if (!param1Valid)
  2015. break;
  2016. Joint* instance = getInstance(state);
  2017. instance->getLeftVector(param1);
  2018. return 0;
  2019. }
  2020. } while (0);
  2021. lua_pushstring(state, "lua_Joint_getLeftVector - Failed to match the given parameters to a valid function signature.");
  2022. lua_error(state);
  2023. break;
  2024. }
  2025. default:
  2026. {
  2027. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2028. lua_error(state);
  2029. break;
  2030. }
  2031. }
  2032. return 0;
  2033. }
  2034. int lua_Joint_getLight(lua_State* state)
  2035. {
  2036. // Get the number of parameters.
  2037. int paramCount = lua_gettop(state);
  2038. // Attempt to match the parameters to a valid binding.
  2039. switch (paramCount)
  2040. {
  2041. case 1:
  2042. {
  2043. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2044. {
  2045. Joint* instance = getInstance(state);
  2046. void* returnPtr = (void*)instance->getLight();
  2047. if (returnPtr)
  2048. {
  2049. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2050. object->instance = returnPtr;
  2051. object->owns = false;
  2052. luaL_getmetatable(state, "Light");
  2053. lua_setmetatable(state, -2);
  2054. }
  2055. else
  2056. {
  2057. lua_pushnil(state);
  2058. }
  2059. return 1;
  2060. }
  2061. lua_pushstring(state, "lua_Joint_getLight - Failed to match the given parameters to a valid function signature.");
  2062. lua_error(state);
  2063. break;
  2064. }
  2065. default:
  2066. {
  2067. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2068. lua_error(state);
  2069. break;
  2070. }
  2071. }
  2072. return 0;
  2073. }
  2074. int lua_Joint_getMatrix(lua_State* state)
  2075. {
  2076. // Get the number of parameters.
  2077. int paramCount = lua_gettop(state);
  2078. // Attempt to match the parameters to a valid binding.
  2079. switch (paramCount)
  2080. {
  2081. case 1:
  2082. {
  2083. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2084. {
  2085. Joint* instance = getInstance(state);
  2086. void* returnPtr = (void*)&(instance->getMatrix());
  2087. if (returnPtr)
  2088. {
  2089. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2090. object->instance = returnPtr;
  2091. object->owns = false;
  2092. luaL_getmetatable(state, "Matrix");
  2093. lua_setmetatable(state, -2);
  2094. }
  2095. else
  2096. {
  2097. lua_pushnil(state);
  2098. }
  2099. return 1;
  2100. }
  2101. lua_pushstring(state, "lua_Joint_getMatrix - Failed to match the given parameters to a valid function signature.");
  2102. lua_error(state);
  2103. break;
  2104. }
  2105. default:
  2106. {
  2107. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2108. lua_error(state);
  2109. break;
  2110. }
  2111. }
  2112. return 0;
  2113. }
  2114. int lua_Joint_getModel(lua_State* state)
  2115. {
  2116. // Get the number of parameters.
  2117. int paramCount = lua_gettop(state);
  2118. // Attempt to match the parameters to a valid binding.
  2119. switch (paramCount)
  2120. {
  2121. case 1:
  2122. {
  2123. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2124. {
  2125. Joint* instance = getInstance(state);
  2126. void* returnPtr = (void*)instance->getModel();
  2127. if (returnPtr)
  2128. {
  2129. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2130. object->instance = returnPtr;
  2131. object->owns = false;
  2132. luaL_getmetatable(state, "Model");
  2133. lua_setmetatable(state, -2);
  2134. }
  2135. else
  2136. {
  2137. lua_pushnil(state);
  2138. }
  2139. return 1;
  2140. }
  2141. lua_pushstring(state, "lua_Joint_getModel - Failed to match the given parameters to a valid function signature.");
  2142. lua_error(state);
  2143. break;
  2144. }
  2145. default:
  2146. {
  2147. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2148. lua_error(state);
  2149. break;
  2150. }
  2151. }
  2152. return 0;
  2153. }
  2154. int lua_Joint_getNextSibling(lua_State* state)
  2155. {
  2156. // Get the number of parameters.
  2157. int paramCount = lua_gettop(state);
  2158. // Attempt to match the parameters to a valid binding.
  2159. switch (paramCount)
  2160. {
  2161. case 1:
  2162. {
  2163. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2164. {
  2165. Joint* instance = getInstance(state);
  2166. void* returnPtr = (void*)instance->getNextSibling();
  2167. if (returnPtr)
  2168. {
  2169. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2170. object->instance = returnPtr;
  2171. object->owns = false;
  2172. luaL_getmetatable(state, "Node");
  2173. lua_setmetatable(state, -2);
  2174. }
  2175. else
  2176. {
  2177. lua_pushnil(state);
  2178. }
  2179. return 1;
  2180. }
  2181. lua_pushstring(state, "lua_Joint_getNextSibling - Failed to match the given parameters to a valid function signature.");
  2182. lua_error(state);
  2183. break;
  2184. }
  2185. default:
  2186. {
  2187. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2188. lua_error(state);
  2189. break;
  2190. }
  2191. }
  2192. return 0;
  2193. }
  2194. int lua_Joint_getNumAdvertisedDescendants(lua_State* state)
  2195. {
  2196. // Get the number of parameters.
  2197. int paramCount = lua_gettop(state);
  2198. // Attempt to match the parameters to a valid binding.
  2199. switch (paramCount)
  2200. {
  2201. case 1:
  2202. {
  2203. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2204. {
  2205. Joint* instance = getInstance(state);
  2206. unsigned int result = instance->getNumAdvertisedDescendants();
  2207. // Push the return value onto the stack.
  2208. lua_pushunsigned(state, result);
  2209. return 1;
  2210. }
  2211. lua_pushstring(state, "lua_Joint_getNumAdvertisedDescendants - Failed to match the given parameters to a valid function signature.");
  2212. lua_error(state);
  2213. break;
  2214. }
  2215. default:
  2216. {
  2217. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2218. lua_error(state);
  2219. break;
  2220. }
  2221. }
  2222. return 0;
  2223. }
  2224. int lua_Joint_getParent(lua_State* state)
  2225. {
  2226. // Get the number of parameters.
  2227. int paramCount = lua_gettop(state);
  2228. // Attempt to match the parameters to a valid binding.
  2229. switch (paramCount)
  2230. {
  2231. case 1:
  2232. {
  2233. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2234. {
  2235. Joint* instance = getInstance(state);
  2236. void* returnPtr = (void*)instance->getParent();
  2237. if (returnPtr)
  2238. {
  2239. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2240. object->instance = returnPtr;
  2241. object->owns = false;
  2242. luaL_getmetatable(state, "Node");
  2243. lua_setmetatable(state, -2);
  2244. }
  2245. else
  2246. {
  2247. lua_pushnil(state);
  2248. }
  2249. return 1;
  2250. }
  2251. lua_pushstring(state, "lua_Joint_getParent - Failed to match the given parameters to a valid function signature.");
  2252. lua_error(state);
  2253. break;
  2254. }
  2255. default:
  2256. {
  2257. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2258. lua_error(state);
  2259. break;
  2260. }
  2261. }
  2262. return 0;
  2263. }
  2264. int lua_Joint_getParticleEmitter(lua_State* state)
  2265. {
  2266. // Get the number of parameters.
  2267. int paramCount = lua_gettop(state);
  2268. // Attempt to match the parameters to a valid binding.
  2269. switch (paramCount)
  2270. {
  2271. case 1:
  2272. {
  2273. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2274. {
  2275. Joint* instance = getInstance(state);
  2276. void* returnPtr = (void*)instance->getParticleEmitter();
  2277. if (returnPtr)
  2278. {
  2279. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2280. object->instance = returnPtr;
  2281. object->owns = false;
  2282. luaL_getmetatable(state, "ParticleEmitter");
  2283. lua_setmetatable(state, -2);
  2284. }
  2285. else
  2286. {
  2287. lua_pushnil(state);
  2288. }
  2289. return 1;
  2290. }
  2291. lua_pushstring(state, "lua_Joint_getParticleEmitter - Failed to match the given parameters to a valid function signature.");
  2292. lua_error(state);
  2293. break;
  2294. }
  2295. default:
  2296. {
  2297. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2298. lua_error(state);
  2299. break;
  2300. }
  2301. }
  2302. return 0;
  2303. }
  2304. int lua_Joint_getPreviousSibling(lua_State* state)
  2305. {
  2306. // Get the number of parameters.
  2307. int paramCount = lua_gettop(state);
  2308. // Attempt to match the parameters to a valid binding.
  2309. switch (paramCount)
  2310. {
  2311. case 1:
  2312. {
  2313. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2314. {
  2315. Joint* instance = getInstance(state);
  2316. void* returnPtr = (void*)instance->getPreviousSibling();
  2317. if (returnPtr)
  2318. {
  2319. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2320. object->instance = returnPtr;
  2321. object->owns = false;
  2322. luaL_getmetatable(state, "Node");
  2323. lua_setmetatable(state, -2);
  2324. }
  2325. else
  2326. {
  2327. lua_pushnil(state);
  2328. }
  2329. return 1;
  2330. }
  2331. lua_pushstring(state, "lua_Joint_getPreviousSibling - Failed to match the given parameters to a valid function signature.");
  2332. lua_error(state);
  2333. break;
  2334. }
  2335. default:
  2336. {
  2337. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2338. lua_error(state);
  2339. break;
  2340. }
  2341. }
  2342. return 0;
  2343. }
  2344. int lua_Joint_getProjectionMatrix(lua_State* state)
  2345. {
  2346. // Get the number of parameters.
  2347. int paramCount = lua_gettop(state);
  2348. // Attempt to match the parameters to a valid binding.
  2349. switch (paramCount)
  2350. {
  2351. case 1:
  2352. {
  2353. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2354. {
  2355. Joint* instance = getInstance(state);
  2356. void* returnPtr = (void*)&(instance->getProjectionMatrix());
  2357. if (returnPtr)
  2358. {
  2359. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2360. object->instance = returnPtr;
  2361. object->owns = false;
  2362. luaL_getmetatable(state, "Matrix");
  2363. lua_setmetatable(state, -2);
  2364. }
  2365. else
  2366. {
  2367. lua_pushnil(state);
  2368. }
  2369. return 1;
  2370. }
  2371. lua_pushstring(state, "lua_Joint_getProjectionMatrix - Failed to match the given parameters to a valid function signature.");
  2372. lua_error(state);
  2373. break;
  2374. }
  2375. default:
  2376. {
  2377. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2378. lua_error(state);
  2379. break;
  2380. }
  2381. }
  2382. return 0;
  2383. }
  2384. int lua_Joint_getRefCount(lua_State* state)
  2385. {
  2386. // Get the number of parameters.
  2387. int paramCount = lua_gettop(state);
  2388. // Attempt to match the parameters to a valid binding.
  2389. switch (paramCount)
  2390. {
  2391. case 1:
  2392. {
  2393. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2394. {
  2395. Joint* instance = getInstance(state);
  2396. unsigned int result = instance->getRefCount();
  2397. // Push the return value onto the stack.
  2398. lua_pushunsigned(state, result);
  2399. return 1;
  2400. }
  2401. lua_pushstring(state, "lua_Joint_getRefCount - Failed to match the given parameters to a valid function signature.");
  2402. lua_error(state);
  2403. break;
  2404. }
  2405. default:
  2406. {
  2407. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2408. lua_error(state);
  2409. break;
  2410. }
  2411. }
  2412. return 0;
  2413. }
  2414. int lua_Joint_getRightVector(lua_State* state)
  2415. {
  2416. // Get the number of parameters.
  2417. int paramCount = lua_gettop(state);
  2418. // Attempt to match the parameters to a valid binding.
  2419. switch (paramCount)
  2420. {
  2421. case 1:
  2422. {
  2423. do
  2424. {
  2425. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2426. {
  2427. Joint* instance = getInstance(state);
  2428. void* returnPtr = (void*)new Vector3(instance->getRightVector());
  2429. if (returnPtr)
  2430. {
  2431. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2432. object->instance = returnPtr;
  2433. object->owns = true;
  2434. luaL_getmetatable(state, "Vector3");
  2435. lua_setmetatable(state, -2);
  2436. }
  2437. else
  2438. {
  2439. lua_pushnil(state);
  2440. }
  2441. return 1;
  2442. }
  2443. } while (0);
  2444. lua_pushstring(state, "lua_Joint_getRightVector - Failed to match the given parameters to a valid function signature.");
  2445. lua_error(state);
  2446. break;
  2447. }
  2448. case 2:
  2449. {
  2450. do
  2451. {
  2452. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2453. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2454. {
  2455. // Get parameter 1 off the stack.
  2456. bool param1Valid;
  2457. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  2458. if (!param1Valid)
  2459. break;
  2460. Joint* instance = getInstance(state);
  2461. instance->getRightVector(param1);
  2462. return 0;
  2463. }
  2464. } while (0);
  2465. lua_pushstring(state, "lua_Joint_getRightVector - Failed to match the given parameters to a valid function signature.");
  2466. lua_error(state);
  2467. break;
  2468. }
  2469. default:
  2470. {
  2471. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2472. lua_error(state);
  2473. break;
  2474. }
  2475. }
  2476. return 0;
  2477. }
  2478. int lua_Joint_getRightVectorWorld(lua_State* state)
  2479. {
  2480. // Get the number of parameters.
  2481. int paramCount = lua_gettop(state);
  2482. // Attempt to match the parameters to a valid binding.
  2483. switch (paramCount)
  2484. {
  2485. case 1:
  2486. {
  2487. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2488. {
  2489. Joint* instance = getInstance(state);
  2490. void* returnPtr = (void*)new Vector3(instance->getRightVectorWorld());
  2491. if (returnPtr)
  2492. {
  2493. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2494. object->instance = returnPtr;
  2495. object->owns = true;
  2496. luaL_getmetatable(state, "Vector3");
  2497. lua_setmetatable(state, -2);
  2498. }
  2499. else
  2500. {
  2501. lua_pushnil(state);
  2502. }
  2503. return 1;
  2504. }
  2505. lua_pushstring(state, "lua_Joint_getRightVectorWorld - Failed to match the given parameters to a valid function signature.");
  2506. lua_error(state);
  2507. break;
  2508. }
  2509. default:
  2510. {
  2511. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2512. lua_error(state);
  2513. break;
  2514. }
  2515. }
  2516. return 0;
  2517. }
  2518. int lua_Joint_getRootNode(lua_State* state)
  2519. {
  2520. // Get the number of parameters.
  2521. int paramCount = lua_gettop(state);
  2522. // Attempt to match the parameters to a valid binding.
  2523. switch (paramCount)
  2524. {
  2525. case 1:
  2526. {
  2527. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2528. {
  2529. Joint* instance = getInstance(state);
  2530. void* returnPtr = (void*)instance->getRootNode();
  2531. if (returnPtr)
  2532. {
  2533. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2534. object->instance = returnPtr;
  2535. object->owns = false;
  2536. luaL_getmetatable(state, "Node");
  2537. lua_setmetatable(state, -2);
  2538. }
  2539. else
  2540. {
  2541. lua_pushnil(state);
  2542. }
  2543. return 1;
  2544. }
  2545. lua_pushstring(state, "lua_Joint_getRootNode - Failed to match the given parameters to a valid function signature.");
  2546. lua_error(state);
  2547. break;
  2548. }
  2549. default:
  2550. {
  2551. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2552. lua_error(state);
  2553. break;
  2554. }
  2555. }
  2556. return 0;
  2557. }
  2558. int lua_Joint_getRotation(lua_State* state)
  2559. {
  2560. // Get the number of parameters.
  2561. int paramCount = lua_gettop(state);
  2562. // Attempt to match the parameters to a valid binding.
  2563. switch (paramCount)
  2564. {
  2565. case 1:
  2566. {
  2567. do
  2568. {
  2569. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2570. {
  2571. Joint* instance = getInstance(state);
  2572. void* returnPtr = (void*)&(instance->getRotation());
  2573. if (returnPtr)
  2574. {
  2575. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2576. object->instance = returnPtr;
  2577. object->owns = false;
  2578. luaL_getmetatable(state, "Quaternion");
  2579. lua_setmetatable(state, -2);
  2580. }
  2581. else
  2582. {
  2583. lua_pushnil(state);
  2584. }
  2585. return 1;
  2586. }
  2587. } while (0);
  2588. lua_pushstring(state, "lua_Joint_getRotation - Failed to match the given parameters to a valid function signature.");
  2589. lua_error(state);
  2590. break;
  2591. }
  2592. case 2:
  2593. {
  2594. do
  2595. {
  2596. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2597. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2598. {
  2599. // Get parameter 1 off the stack.
  2600. bool param1Valid;
  2601. gameplay::ScriptUtil::LuaArray<Quaternion> param1 = gameplay::ScriptUtil::getObjectPointer<Quaternion>(2, "Quaternion", false, &param1Valid);
  2602. if (!param1Valid)
  2603. break;
  2604. Joint* instance = getInstance(state);
  2605. instance->getRotation(param1);
  2606. return 0;
  2607. }
  2608. } while (0);
  2609. do
  2610. {
  2611. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2612. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2613. {
  2614. // Get parameter 1 off the stack.
  2615. bool param1Valid;
  2616. gameplay::ScriptUtil::LuaArray<Matrix> param1 = gameplay::ScriptUtil::getObjectPointer<Matrix>(2, "Matrix", false, &param1Valid);
  2617. if (!param1Valid)
  2618. break;
  2619. Joint* instance = getInstance(state);
  2620. instance->getRotation(param1);
  2621. return 0;
  2622. }
  2623. } while (0);
  2624. do
  2625. {
  2626. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2627. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2628. {
  2629. // Get parameter 1 off the stack.
  2630. bool param1Valid;
  2631. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  2632. if (!param1Valid)
  2633. break;
  2634. Joint* instance = getInstance(state);
  2635. float result = instance->getRotation(param1);
  2636. // Push the return value onto the stack.
  2637. lua_pushnumber(state, result);
  2638. return 1;
  2639. }
  2640. } while (0);
  2641. lua_pushstring(state, "lua_Joint_getRotation - Failed to match the given parameters to a valid function signature.");
  2642. lua_error(state);
  2643. break;
  2644. }
  2645. default:
  2646. {
  2647. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2648. lua_error(state);
  2649. break;
  2650. }
  2651. }
  2652. return 0;
  2653. }
  2654. int lua_Joint_getScale(lua_State* state)
  2655. {
  2656. // Get the number of parameters.
  2657. int paramCount = lua_gettop(state);
  2658. // Attempt to match the parameters to a valid binding.
  2659. switch (paramCount)
  2660. {
  2661. case 1:
  2662. {
  2663. do
  2664. {
  2665. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2666. {
  2667. Joint* instance = getInstance(state);
  2668. void* returnPtr = (void*)&(instance->getScale());
  2669. if (returnPtr)
  2670. {
  2671. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2672. object->instance = returnPtr;
  2673. object->owns = false;
  2674. luaL_getmetatable(state, "Vector3");
  2675. lua_setmetatable(state, -2);
  2676. }
  2677. else
  2678. {
  2679. lua_pushnil(state);
  2680. }
  2681. return 1;
  2682. }
  2683. } while (0);
  2684. lua_pushstring(state, "lua_Joint_getScale - Failed to match the given parameters to a valid function signature.");
  2685. lua_error(state);
  2686. break;
  2687. }
  2688. case 2:
  2689. {
  2690. do
  2691. {
  2692. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2693. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2694. {
  2695. // Get parameter 1 off the stack.
  2696. bool param1Valid;
  2697. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  2698. if (!param1Valid)
  2699. break;
  2700. Joint* instance = getInstance(state);
  2701. instance->getScale(param1);
  2702. return 0;
  2703. }
  2704. } while (0);
  2705. lua_pushstring(state, "lua_Joint_getScale - Failed to match the given parameters to a valid function signature.");
  2706. lua_error(state);
  2707. break;
  2708. }
  2709. default:
  2710. {
  2711. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2712. lua_error(state);
  2713. break;
  2714. }
  2715. }
  2716. return 0;
  2717. }
  2718. int lua_Joint_getScaleX(lua_State* state)
  2719. {
  2720. // Get the number of parameters.
  2721. int paramCount = lua_gettop(state);
  2722. // Attempt to match the parameters to a valid binding.
  2723. switch (paramCount)
  2724. {
  2725. case 1:
  2726. {
  2727. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2728. {
  2729. Joint* instance = getInstance(state);
  2730. float result = instance->getScaleX();
  2731. // Push the return value onto the stack.
  2732. lua_pushnumber(state, result);
  2733. return 1;
  2734. }
  2735. lua_pushstring(state, "lua_Joint_getScaleX - Failed to match the given parameters to a valid function signature.");
  2736. lua_error(state);
  2737. break;
  2738. }
  2739. default:
  2740. {
  2741. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2742. lua_error(state);
  2743. break;
  2744. }
  2745. }
  2746. return 0;
  2747. }
  2748. int lua_Joint_getScaleY(lua_State* state)
  2749. {
  2750. // Get the number of parameters.
  2751. int paramCount = lua_gettop(state);
  2752. // Attempt to match the parameters to a valid binding.
  2753. switch (paramCount)
  2754. {
  2755. case 1:
  2756. {
  2757. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2758. {
  2759. Joint* instance = getInstance(state);
  2760. float result = instance->getScaleY();
  2761. // Push the return value onto the stack.
  2762. lua_pushnumber(state, result);
  2763. return 1;
  2764. }
  2765. lua_pushstring(state, "lua_Joint_getScaleY - Failed to match the given parameters to a valid function signature.");
  2766. lua_error(state);
  2767. break;
  2768. }
  2769. default:
  2770. {
  2771. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2772. lua_error(state);
  2773. break;
  2774. }
  2775. }
  2776. return 0;
  2777. }
  2778. int lua_Joint_getScaleZ(lua_State* state)
  2779. {
  2780. // Get the number of parameters.
  2781. int paramCount = lua_gettop(state);
  2782. // Attempt to match the parameters to a valid binding.
  2783. switch (paramCount)
  2784. {
  2785. case 1:
  2786. {
  2787. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2788. {
  2789. Joint* instance = getInstance(state);
  2790. float result = instance->getScaleZ();
  2791. // Push the return value onto the stack.
  2792. lua_pushnumber(state, result);
  2793. return 1;
  2794. }
  2795. lua_pushstring(state, "lua_Joint_getScaleZ - Failed to match the given parameters to a valid function signature.");
  2796. lua_error(state);
  2797. break;
  2798. }
  2799. default:
  2800. {
  2801. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2802. lua_error(state);
  2803. break;
  2804. }
  2805. }
  2806. return 0;
  2807. }
  2808. int lua_Joint_getScene(lua_State* state)
  2809. {
  2810. // Get the number of parameters.
  2811. int paramCount = lua_gettop(state);
  2812. // Attempt to match the parameters to a valid binding.
  2813. switch (paramCount)
  2814. {
  2815. case 1:
  2816. {
  2817. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2818. {
  2819. Joint* instance = getInstance(state);
  2820. void* returnPtr = (void*)instance->getScene();
  2821. if (returnPtr)
  2822. {
  2823. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2824. object->instance = returnPtr;
  2825. object->owns = false;
  2826. luaL_getmetatable(state, "Scene");
  2827. lua_setmetatable(state, -2);
  2828. }
  2829. else
  2830. {
  2831. lua_pushnil(state);
  2832. }
  2833. return 1;
  2834. }
  2835. lua_pushstring(state, "lua_Joint_getScene - Failed to match the given parameters to a valid function signature.");
  2836. lua_error(state);
  2837. break;
  2838. }
  2839. default:
  2840. {
  2841. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2842. lua_error(state);
  2843. break;
  2844. }
  2845. }
  2846. return 0;
  2847. }
  2848. int lua_Joint_getTag(lua_State* state)
  2849. {
  2850. // Get the number of parameters.
  2851. int paramCount = lua_gettop(state);
  2852. // Attempt to match the parameters to a valid binding.
  2853. switch (paramCount)
  2854. {
  2855. case 2:
  2856. {
  2857. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2858. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  2859. {
  2860. // Get parameter 1 off the stack.
  2861. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  2862. Joint* instance = getInstance(state);
  2863. const char* result = instance->getTag(param1);
  2864. // Push the return value onto the stack.
  2865. lua_pushstring(state, result);
  2866. return 1;
  2867. }
  2868. lua_pushstring(state, "lua_Joint_getTag - Failed to match the given parameters to a valid function signature.");
  2869. lua_error(state);
  2870. break;
  2871. }
  2872. default:
  2873. {
  2874. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2875. lua_error(state);
  2876. break;
  2877. }
  2878. }
  2879. return 0;
  2880. }
  2881. int lua_Joint_getTerrain(lua_State* state)
  2882. {
  2883. // Get the number of parameters.
  2884. int paramCount = lua_gettop(state);
  2885. // Attempt to match the parameters to a valid binding.
  2886. switch (paramCount)
  2887. {
  2888. case 1:
  2889. {
  2890. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2891. {
  2892. Joint* instance = getInstance(state);
  2893. void* returnPtr = (void*)instance->getTerrain();
  2894. if (returnPtr)
  2895. {
  2896. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2897. object->instance = returnPtr;
  2898. object->owns = false;
  2899. luaL_getmetatable(state, "Terrain");
  2900. lua_setmetatable(state, -2);
  2901. }
  2902. else
  2903. {
  2904. lua_pushnil(state);
  2905. }
  2906. return 1;
  2907. }
  2908. lua_pushstring(state, "lua_Joint_getTerrain - Failed to match the given parameters to a valid function signature.");
  2909. lua_error(state);
  2910. break;
  2911. }
  2912. default:
  2913. {
  2914. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2915. lua_error(state);
  2916. break;
  2917. }
  2918. }
  2919. return 0;
  2920. }
  2921. int lua_Joint_getTranslation(lua_State* state)
  2922. {
  2923. // Get the number of parameters.
  2924. int paramCount = lua_gettop(state);
  2925. // Attempt to match the parameters to a valid binding.
  2926. switch (paramCount)
  2927. {
  2928. case 1:
  2929. {
  2930. do
  2931. {
  2932. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2933. {
  2934. Joint* instance = getInstance(state);
  2935. void* returnPtr = (void*)&(instance->getTranslation());
  2936. if (returnPtr)
  2937. {
  2938. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  2939. object->instance = returnPtr;
  2940. object->owns = false;
  2941. luaL_getmetatable(state, "Vector3");
  2942. lua_setmetatable(state, -2);
  2943. }
  2944. else
  2945. {
  2946. lua_pushnil(state);
  2947. }
  2948. return 1;
  2949. }
  2950. } while (0);
  2951. lua_pushstring(state, "lua_Joint_getTranslation - Failed to match the given parameters to a valid function signature.");
  2952. lua_error(state);
  2953. break;
  2954. }
  2955. case 2:
  2956. {
  2957. do
  2958. {
  2959. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2960. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  2961. {
  2962. // Get parameter 1 off the stack.
  2963. bool param1Valid;
  2964. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  2965. if (!param1Valid)
  2966. break;
  2967. Joint* instance = getInstance(state);
  2968. instance->getTranslation(param1);
  2969. return 0;
  2970. }
  2971. } while (0);
  2972. lua_pushstring(state, "lua_Joint_getTranslation - Failed to match the given parameters to a valid function signature.");
  2973. lua_error(state);
  2974. break;
  2975. }
  2976. default:
  2977. {
  2978. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2979. lua_error(state);
  2980. break;
  2981. }
  2982. }
  2983. return 0;
  2984. }
  2985. int lua_Joint_getTranslationView(lua_State* state)
  2986. {
  2987. // Get the number of parameters.
  2988. int paramCount = lua_gettop(state);
  2989. // Attempt to match the parameters to a valid binding.
  2990. switch (paramCount)
  2991. {
  2992. case 1:
  2993. {
  2994. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2995. {
  2996. Joint* instance = getInstance(state);
  2997. void* returnPtr = (void*)new Vector3(instance->getTranslationView());
  2998. if (returnPtr)
  2999. {
  3000. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3001. object->instance = returnPtr;
  3002. object->owns = true;
  3003. luaL_getmetatable(state, "Vector3");
  3004. lua_setmetatable(state, -2);
  3005. }
  3006. else
  3007. {
  3008. lua_pushnil(state);
  3009. }
  3010. return 1;
  3011. }
  3012. lua_pushstring(state, "lua_Joint_getTranslationView - Failed to match the given parameters to a valid function signature.");
  3013. lua_error(state);
  3014. break;
  3015. }
  3016. default:
  3017. {
  3018. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3019. lua_error(state);
  3020. break;
  3021. }
  3022. }
  3023. return 0;
  3024. }
  3025. int lua_Joint_getTranslationWorld(lua_State* state)
  3026. {
  3027. // Get the number of parameters.
  3028. int paramCount = lua_gettop(state);
  3029. // Attempt to match the parameters to a valid binding.
  3030. switch (paramCount)
  3031. {
  3032. case 1:
  3033. {
  3034. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3035. {
  3036. Joint* instance = getInstance(state);
  3037. void* returnPtr = (void*)new Vector3(instance->getTranslationWorld());
  3038. if (returnPtr)
  3039. {
  3040. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3041. object->instance = returnPtr;
  3042. object->owns = true;
  3043. luaL_getmetatable(state, "Vector3");
  3044. lua_setmetatable(state, -2);
  3045. }
  3046. else
  3047. {
  3048. lua_pushnil(state);
  3049. }
  3050. return 1;
  3051. }
  3052. lua_pushstring(state, "lua_Joint_getTranslationWorld - Failed to match the given parameters to a valid function signature.");
  3053. lua_error(state);
  3054. break;
  3055. }
  3056. default:
  3057. {
  3058. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3059. lua_error(state);
  3060. break;
  3061. }
  3062. }
  3063. return 0;
  3064. }
  3065. int lua_Joint_getTranslationX(lua_State* state)
  3066. {
  3067. // Get the number of parameters.
  3068. int paramCount = lua_gettop(state);
  3069. // Attempt to match the parameters to a valid binding.
  3070. switch (paramCount)
  3071. {
  3072. case 1:
  3073. {
  3074. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3075. {
  3076. Joint* instance = getInstance(state);
  3077. float result = instance->getTranslationX();
  3078. // Push the return value onto the stack.
  3079. lua_pushnumber(state, result);
  3080. return 1;
  3081. }
  3082. lua_pushstring(state, "lua_Joint_getTranslationX - Failed to match the given parameters to a valid function signature.");
  3083. lua_error(state);
  3084. break;
  3085. }
  3086. default:
  3087. {
  3088. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3089. lua_error(state);
  3090. break;
  3091. }
  3092. }
  3093. return 0;
  3094. }
  3095. int lua_Joint_getTranslationY(lua_State* state)
  3096. {
  3097. // Get the number of parameters.
  3098. int paramCount = lua_gettop(state);
  3099. // Attempt to match the parameters to a valid binding.
  3100. switch (paramCount)
  3101. {
  3102. case 1:
  3103. {
  3104. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3105. {
  3106. Joint* instance = getInstance(state);
  3107. float result = instance->getTranslationY();
  3108. // Push the return value onto the stack.
  3109. lua_pushnumber(state, result);
  3110. return 1;
  3111. }
  3112. lua_pushstring(state, "lua_Joint_getTranslationY - Failed to match the given parameters to a valid function signature.");
  3113. lua_error(state);
  3114. break;
  3115. }
  3116. default:
  3117. {
  3118. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3119. lua_error(state);
  3120. break;
  3121. }
  3122. }
  3123. return 0;
  3124. }
  3125. int lua_Joint_getTranslationZ(lua_State* state)
  3126. {
  3127. // Get the number of parameters.
  3128. int paramCount = lua_gettop(state);
  3129. // Attempt to match the parameters to a valid binding.
  3130. switch (paramCount)
  3131. {
  3132. case 1:
  3133. {
  3134. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3135. {
  3136. Joint* instance = getInstance(state);
  3137. float result = instance->getTranslationZ();
  3138. // Push the return value onto the stack.
  3139. lua_pushnumber(state, result);
  3140. return 1;
  3141. }
  3142. lua_pushstring(state, "lua_Joint_getTranslationZ - Failed to match the given parameters to a valid function signature.");
  3143. lua_error(state);
  3144. break;
  3145. }
  3146. default:
  3147. {
  3148. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3149. lua_error(state);
  3150. break;
  3151. }
  3152. }
  3153. return 0;
  3154. }
  3155. int lua_Joint_getType(lua_State* state)
  3156. {
  3157. // Get the number of parameters.
  3158. int paramCount = lua_gettop(state);
  3159. // Attempt to match the parameters to a valid binding.
  3160. switch (paramCount)
  3161. {
  3162. case 1:
  3163. {
  3164. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3165. {
  3166. Joint* instance = getInstance(state);
  3167. Node::Type result = instance->getType();
  3168. // Push the return value onto the stack.
  3169. lua_pushstring(state, lua_stringFromEnum_NodeType(result));
  3170. return 1;
  3171. }
  3172. lua_pushstring(state, "lua_Joint_getType - Failed to match the given parameters to a valid function signature.");
  3173. lua_error(state);
  3174. break;
  3175. }
  3176. default:
  3177. {
  3178. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3179. lua_error(state);
  3180. break;
  3181. }
  3182. }
  3183. return 0;
  3184. }
  3185. int lua_Joint_getUpVector(lua_State* state)
  3186. {
  3187. // Get the number of parameters.
  3188. int paramCount = lua_gettop(state);
  3189. // Attempt to match the parameters to a valid binding.
  3190. switch (paramCount)
  3191. {
  3192. case 1:
  3193. {
  3194. do
  3195. {
  3196. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3197. {
  3198. Joint* instance = getInstance(state);
  3199. void* returnPtr = (void*)new Vector3(instance->getUpVector());
  3200. if (returnPtr)
  3201. {
  3202. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3203. object->instance = returnPtr;
  3204. object->owns = true;
  3205. luaL_getmetatable(state, "Vector3");
  3206. lua_setmetatable(state, -2);
  3207. }
  3208. else
  3209. {
  3210. lua_pushnil(state);
  3211. }
  3212. return 1;
  3213. }
  3214. } while (0);
  3215. lua_pushstring(state, "lua_Joint_getUpVector - Failed to match the given parameters to a valid function signature.");
  3216. lua_error(state);
  3217. break;
  3218. }
  3219. case 2:
  3220. {
  3221. do
  3222. {
  3223. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3224. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  3225. {
  3226. // Get parameter 1 off the stack.
  3227. bool param1Valid;
  3228. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  3229. if (!param1Valid)
  3230. break;
  3231. Joint* instance = getInstance(state);
  3232. instance->getUpVector(param1);
  3233. return 0;
  3234. }
  3235. } while (0);
  3236. lua_pushstring(state, "lua_Joint_getUpVector - Failed to match the given parameters to a valid function signature.");
  3237. lua_error(state);
  3238. break;
  3239. }
  3240. default:
  3241. {
  3242. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  3243. lua_error(state);
  3244. break;
  3245. }
  3246. }
  3247. return 0;
  3248. }
  3249. int lua_Joint_getUpVectorWorld(lua_State* state)
  3250. {
  3251. // Get the number of parameters.
  3252. int paramCount = lua_gettop(state);
  3253. // Attempt to match the parameters to a valid binding.
  3254. switch (paramCount)
  3255. {
  3256. case 1:
  3257. {
  3258. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3259. {
  3260. Joint* instance = getInstance(state);
  3261. void* returnPtr = (void*)new Vector3(instance->getUpVectorWorld());
  3262. if (returnPtr)
  3263. {
  3264. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3265. object->instance = returnPtr;
  3266. object->owns = true;
  3267. luaL_getmetatable(state, "Vector3");
  3268. lua_setmetatable(state, -2);
  3269. }
  3270. else
  3271. {
  3272. lua_pushnil(state);
  3273. }
  3274. return 1;
  3275. }
  3276. lua_pushstring(state, "lua_Joint_getUpVectorWorld - Failed to match the given parameters to a valid function signature.");
  3277. lua_error(state);
  3278. break;
  3279. }
  3280. default:
  3281. {
  3282. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3283. lua_error(state);
  3284. break;
  3285. }
  3286. }
  3287. return 0;
  3288. }
  3289. int lua_Joint_getViewMatrix(lua_State* state)
  3290. {
  3291. // Get the number of parameters.
  3292. int paramCount = lua_gettop(state);
  3293. // Attempt to match the parameters to a valid binding.
  3294. switch (paramCount)
  3295. {
  3296. case 1:
  3297. {
  3298. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3299. {
  3300. Joint* instance = getInstance(state);
  3301. void* returnPtr = (void*)&(instance->getViewMatrix());
  3302. if (returnPtr)
  3303. {
  3304. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3305. object->instance = returnPtr;
  3306. object->owns = false;
  3307. luaL_getmetatable(state, "Matrix");
  3308. lua_setmetatable(state, -2);
  3309. }
  3310. else
  3311. {
  3312. lua_pushnil(state);
  3313. }
  3314. return 1;
  3315. }
  3316. lua_pushstring(state, "lua_Joint_getViewMatrix - Failed to match the given parameters to a valid function signature.");
  3317. lua_error(state);
  3318. break;
  3319. }
  3320. default:
  3321. {
  3322. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3323. lua_error(state);
  3324. break;
  3325. }
  3326. }
  3327. return 0;
  3328. }
  3329. int lua_Joint_getViewProjectionMatrix(lua_State* state)
  3330. {
  3331. // Get the number of parameters.
  3332. int paramCount = lua_gettop(state);
  3333. // Attempt to match the parameters to a valid binding.
  3334. switch (paramCount)
  3335. {
  3336. case 1:
  3337. {
  3338. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3339. {
  3340. Joint* instance = getInstance(state);
  3341. void* returnPtr = (void*)&(instance->getViewProjectionMatrix());
  3342. if (returnPtr)
  3343. {
  3344. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3345. object->instance = returnPtr;
  3346. object->owns = false;
  3347. luaL_getmetatable(state, "Matrix");
  3348. lua_setmetatable(state, -2);
  3349. }
  3350. else
  3351. {
  3352. lua_pushnil(state);
  3353. }
  3354. return 1;
  3355. }
  3356. lua_pushstring(state, "lua_Joint_getViewProjectionMatrix - Failed to match the given parameters to a valid function signature.");
  3357. lua_error(state);
  3358. break;
  3359. }
  3360. default:
  3361. {
  3362. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3363. lua_error(state);
  3364. break;
  3365. }
  3366. }
  3367. return 0;
  3368. }
  3369. int lua_Joint_getWorldMatrix(lua_State* state)
  3370. {
  3371. // Get the number of parameters.
  3372. int paramCount = lua_gettop(state);
  3373. // Attempt to match the parameters to a valid binding.
  3374. switch (paramCount)
  3375. {
  3376. case 1:
  3377. {
  3378. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3379. {
  3380. Joint* instance = getInstance(state);
  3381. void* returnPtr = (void*)&(instance->getWorldMatrix());
  3382. if (returnPtr)
  3383. {
  3384. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3385. object->instance = returnPtr;
  3386. object->owns = false;
  3387. luaL_getmetatable(state, "Matrix");
  3388. lua_setmetatable(state, -2);
  3389. }
  3390. else
  3391. {
  3392. lua_pushnil(state);
  3393. }
  3394. return 1;
  3395. }
  3396. lua_pushstring(state, "lua_Joint_getWorldMatrix - Failed to match the given parameters to a valid function signature.");
  3397. lua_error(state);
  3398. break;
  3399. }
  3400. default:
  3401. {
  3402. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3403. lua_error(state);
  3404. break;
  3405. }
  3406. }
  3407. return 0;
  3408. }
  3409. int lua_Joint_getWorldViewMatrix(lua_State* state)
  3410. {
  3411. // Get the number of parameters.
  3412. int paramCount = lua_gettop(state);
  3413. // Attempt to match the parameters to a valid binding.
  3414. switch (paramCount)
  3415. {
  3416. case 1:
  3417. {
  3418. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3419. {
  3420. Joint* instance = getInstance(state);
  3421. void* returnPtr = (void*)&(instance->getWorldViewMatrix());
  3422. if (returnPtr)
  3423. {
  3424. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3425. object->instance = returnPtr;
  3426. object->owns = false;
  3427. luaL_getmetatable(state, "Matrix");
  3428. lua_setmetatable(state, -2);
  3429. }
  3430. else
  3431. {
  3432. lua_pushnil(state);
  3433. }
  3434. return 1;
  3435. }
  3436. lua_pushstring(state, "lua_Joint_getWorldViewMatrix - Failed to match the given parameters to a valid function signature.");
  3437. lua_error(state);
  3438. break;
  3439. }
  3440. default:
  3441. {
  3442. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3443. lua_error(state);
  3444. break;
  3445. }
  3446. }
  3447. return 0;
  3448. }
  3449. int lua_Joint_getWorldViewProjectionMatrix(lua_State* state)
  3450. {
  3451. // Get the number of parameters.
  3452. int paramCount = lua_gettop(state);
  3453. // Attempt to match the parameters to a valid binding.
  3454. switch (paramCount)
  3455. {
  3456. case 1:
  3457. {
  3458. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3459. {
  3460. Joint* instance = getInstance(state);
  3461. void* returnPtr = (void*)&(instance->getWorldViewProjectionMatrix());
  3462. if (returnPtr)
  3463. {
  3464. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  3465. object->instance = returnPtr;
  3466. object->owns = false;
  3467. luaL_getmetatable(state, "Matrix");
  3468. lua_setmetatable(state, -2);
  3469. }
  3470. else
  3471. {
  3472. lua_pushnil(state);
  3473. }
  3474. return 1;
  3475. }
  3476. lua_pushstring(state, "lua_Joint_getWorldViewProjectionMatrix - Failed to match the given parameters to a valid function signature.");
  3477. lua_error(state);
  3478. break;
  3479. }
  3480. default:
  3481. {
  3482. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3483. lua_error(state);
  3484. break;
  3485. }
  3486. }
  3487. return 0;
  3488. }
  3489. int lua_Joint_hasTag(lua_State* state)
  3490. {
  3491. // Get the number of parameters.
  3492. int paramCount = lua_gettop(state);
  3493. // Attempt to match the parameters to a valid binding.
  3494. switch (paramCount)
  3495. {
  3496. case 2:
  3497. {
  3498. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3499. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  3500. {
  3501. // Get parameter 1 off the stack.
  3502. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  3503. Joint* instance = getInstance(state);
  3504. bool result = instance->hasTag(param1);
  3505. // Push the return value onto the stack.
  3506. lua_pushboolean(state, result);
  3507. return 1;
  3508. }
  3509. lua_pushstring(state, "lua_Joint_hasTag - Failed to match the given parameters to a valid function signature.");
  3510. lua_error(state);
  3511. break;
  3512. }
  3513. default:
  3514. {
  3515. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3516. lua_error(state);
  3517. break;
  3518. }
  3519. }
  3520. return 0;
  3521. }
  3522. int lua_Joint_isStatic(lua_State* state)
  3523. {
  3524. // Get the number of parameters.
  3525. int paramCount = lua_gettop(state);
  3526. // Attempt to match the parameters to a valid binding.
  3527. switch (paramCount)
  3528. {
  3529. case 1:
  3530. {
  3531. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3532. {
  3533. Joint* instance = getInstance(state);
  3534. bool result = instance->isStatic();
  3535. // Push the return value onto the stack.
  3536. lua_pushboolean(state, result);
  3537. return 1;
  3538. }
  3539. lua_pushstring(state, "lua_Joint_isStatic - Failed to match the given parameters to a valid function signature.");
  3540. lua_error(state);
  3541. break;
  3542. }
  3543. default:
  3544. {
  3545. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3546. lua_error(state);
  3547. break;
  3548. }
  3549. }
  3550. return 0;
  3551. }
  3552. int lua_Joint_release(lua_State* state)
  3553. {
  3554. // Get the number of parameters.
  3555. int paramCount = lua_gettop(state);
  3556. // Attempt to match the parameters to a valid binding.
  3557. switch (paramCount)
  3558. {
  3559. case 1:
  3560. {
  3561. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3562. {
  3563. Joint* instance = getInstance(state);
  3564. instance->release();
  3565. return 0;
  3566. }
  3567. lua_pushstring(state, "lua_Joint_release - Failed to match the given parameters to a valid function signature.");
  3568. lua_error(state);
  3569. break;
  3570. }
  3571. default:
  3572. {
  3573. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3574. lua_error(state);
  3575. break;
  3576. }
  3577. }
  3578. return 0;
  3579. }
  3580. int lua_Joint_removeAllChildren(lua_State* state)
  3581. {
  3582. // Get the number of parameters.
  3583. int paramCount = lua_gettop(state);
  3584. // Attempt to match the parameters to a valid binding.
  3585. switch (paramCount)
  3586. {
  3587. case 1:
  3588. {
  3589. if ((lua_type(state, 1) == LUA_TUSERDATA))
  3590. {
  3591. Joint* instance = getInstance(state);
  3592. instance->removeAllChildren();
  3593. return 0;
  3594. }
  3595. lua_pushstring(state, "lua_Joint_removeAllChildren - Failed to match the given parameters to a valid function signature.");
  3596. lua_error(state);
  3597. break;
  3598. }
  3599. default:
  3600. {
  3601. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  3602. lua_error(state);
  3603. break;
  3604. }
  3605. }
  3606. return 0;
  3607. }
  3608. int lua_Joint_removeChild(lua_State* state)
  3609. {
  3610. // Get the number of parameters.
  3611. int paramCount = lua_gettop(state);
  3612. // Attempt to match the parameters to a valid binding.
  3613. switch (paramCount)
  3614. {
  3615. case 2:
  3616. {
  3617. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3618. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  3619. {
  3620. // Get parameter 1 off the stack.
  3621. bool param1Valid;
  3622. gameplay::ScriptUtil::LuaArray<Node> param1 = gameplay::ScriptUtil::getObjectPointer<Node>(2, "Node", false, &param1Valid);
  3623. if (!param1Valid)
  3624. {
  3625. lua_pushstring(state, "Failed to convert parameter 1 to type 'Node'.");
  3626. lua_error(state);
  3627. }
  3628. Joint* instance = getInstance(state);
  3629. instance->removeChild(param1);
  3630. return 0;
  3631. }
  3632. lua_pushstring(state, "lua_Joint_removeChild - Failed to match the given parameters to a valid function signature.");
  3633. lua_error(state);
  3634. break;
  3635. }
  3636. default:
  3637. {
  3638. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3639. lua_error(state);
  3640. break;
  3641. }
  3642. }
  3643. return 0;
  3644. }
  3645. int lua_Joint_removeListener(lua_State* state)
  3646. {
  3647. // Get the number of parameters.
  3648. int paramCount = lua_gettop(state);
  3649. // Attempt to match the parameters to a valid binding.
  3650. switch (paramCount)
  3651. {
  3652. case 2:
  3653. {
  3654. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3655. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  3656. {
  3657. // Get parameter 1 off the stack.
  3658. bool param1Valid;
  3659. gameplay::ScriptUtil::LuaArray<Transform::Listener> param1 = gameplay::ScriptUtil::getObjectPointer<Transform::Listener>(2, "TransformListener", false, &param1Valid);
  3660. if (!param1Valid)
  3661. {
  3662. lua_pushstring(state, "Failed to convert parameter 1 to type 'Transform::Listener'.");
  3663. lua_error(state);
  3664. }
  3665. Joint* instance = getInstance(state);
  3666. instance->removeListener(param1);
  3667. return 0;
  3668. }
  3669. lua_pushstring(state, "lua_Joint_removeListener - Failed to match the given parameters to a valid function signature.");
  3670. lua_error(state);
  3671. break;
  3672. }
  3673. default:
  3674. {
  3675. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3676. lua_error(state);
  3677. break;
  3678. }
  3679. }
  3680. return 0;
  3681. }
  3682. int lua_Joint_removeScriptCallback(lua_State* state)
  3683. {
  3684. // Get the number of parameters.
  3685. int paramCount = lua_gettop(state);
  3686. // Attempt to match the parameters to a valid binding.
  3687. switch (paramCount)
  3688. {
  3689. case 3:
  3690. {
  3691. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3692. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3693. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  3694. {
  3695. // Get parameter 1 off the stack.
  3696. std::string param1 = gameplay::ScriptUtil::getString(2, true);
  3697. // Get parameter 2 off the stack.
  3698. std::string param2 = gameplay::ScriptUtil::getString(3, true);
  3699. Joint* instance = getInstance(state);
  3700. instance->removeScriptCallback(param1, param2);
  3701. return 0;
  3702. }
  3703. lua_pushstring(state, "lua_Joint_removeScriptCallback - Failed to match the given parameters to a valid function signature.");
  3704. lua_error(state);
  3705. break;
  3706. }
  3707. default:
  3708. {
  3709. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3710. lua_error(state);
  3711. break;
  3712. }
  3713. }
  3714. return 0;
  3715. }
  3716. int lua_Joint_rotate(lua_State* state)
  3717. {
  3718. // Get the number of parameters.
  3719. int paramCount = lua_gettop(state);
  3720. // Attempt to match the parameters to a valid binding.
  3721. switch (paramCount)
  3722. {
  3723. case 2:
  3724. {
  3725. do
  3726. {
  3727. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3728. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3729. {
  3730. // Get parameter 1 off the stack.
  3731. bool param1Valid;
  3732. gameplay::ScriptUtil::LuaArray<Quaternion> param1 = gameplay::ScriptUtil::getObjectPointer<Quaternion>(2, "Quaternion", true, &param1Valid);
  3733. if (!param1Valid)
  3734. break;
  3735. Joint* instance = getInstance(state);
  3736. instance->rotate(*param1);
  3737. return 0;
  3738. }
  3739. } while (0);
  3740. do
  3741. {
  3742. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3743. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3744. {
  3745. // Get parameter 1 off the stack.
  3746. bool param1Valid;
  3747. gameplay::ScriptUtil::LuaArray<Matrix> param1 = gameplay::ScriptUtil::getObjectPointer<Matrix>(2, "Matrix", true, &param1Valid);
  3748. if (!param1Valid)
  3749. break;
  3750. Joint* instance = getInstance(state);
  3751. instance->rotate(*param1);
  3752. return 0;
  3753. }
  3754. } while (0);
  3755. lua_pushstring(state, "lua_Joint_rotate - Failed to match the given parameters to a valid function signature.");
  3756. lua_error(state);
  3757. break;
  3758. }
  3759. case 3:
  3760. {
  3761. do
  3762. {
  3763. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3764. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  3765. lua_type(state, 3) == LUA_TNUMBER)
  3766. {
  3767. // Get parameter 1 off the stack.
  3768. bool param1Valid;
  3769. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  3770. if (!param1Valid)
  3771. break;
  3772. // Get parameter 2 off the stack.
  3773. float param2 = (float)luaL_checknumber(state, 3);
  3774. Joint* instance = getInstance(state);
  3775. instance->rotate(*param1, param2);
  3776. return 0;
  3777. }
  3778. } while (0);
  3779. lua_pushstring(state, "lua_Joint_rotate - Failed to match the given parameters to a valid function signature.");
  3780. lua_error(state);
  3781. break;
  3782. }
  3783. case 5:
  3784. {
  3785. do
  3786. {
  3787. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3788. lua_type(state, 2) == LUA_TNUMBER &&
  3789. lua_type(state, 3) == LUA_TNUMBER &&
  3790. lua_type(state, 4) == LUA_TNUMBER &&
  3791. lua_type(state, 5) == LUA_TNUMBER)
  3792. {
  3793. // Get parameter 1 off the stack.
  3794. float param1 = (float)luaL_checknumber(state, 2);
  3795. // Get parameter 2 off the stack.
  3796. float param2 = (float)luaL_checknumber(state, 3);
  3797. // Get parameter 3 off the stack.
  3798. float param3 = (float)luaL_checknumber(state, 4);
  3799. // Get parameter 4 off the stack.
  3800. float param4 = (float)luaL_checknumber(state, 5);
  3801. Joint* instance = getInstance(state);
  3802. instance->rotate(param1, param2, param3, param4);
  3803. return 0;
  3804. }
  3805. } while (0);
  3806. lua_pushstring(state, "lua_Joint_rotate - Failed to match the given parameters to a valid function signature.");
  3807. lua_error(state);
  3808. break;
  3809. }
  3810. default:
  3811. {
  3812. lua_pushstring(state, "Invalid number of parameters (expected 2, 3 or 5).");
  3813. lua_error(state);
  3814. break;
  3815. }
  3816. }
  3817. return 0;
  3818. }
  3819. int lua_Joint_rotateX(lua_State* state)
  3820. {
  3821. // Get the number of parameters.
  3822. int paramCount = lua_gettop(state);
  3823. // Attempt to match the parameters to a valid binding.
  3824. switch (paramCount)
  3825. {
  3826. case 2:
  3827. {
  3828. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3829. lua_type(state, 2) == LUA_TNUMBER)
  3830. {
  3831. // Get parameter 1 off the stack.
  3832. float param1 = (float)luaL_checknumber(state, 2);
  3833. Joint* instance = getInstance(state);
  3834. instance->rotateX(param1);
  3835. return 0;
  3836. }
  3837. lua_pushstring(state, "lua_Joint_rotateX - Failed to match the given parameters to a valid function signature.");
  3838. lua_error(state);
  3839. break;
  3840. }
  3841. default:
  3842. {
  3843. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3844. lua_error(state);
  3845. break;
  3846. }
  3847. }
  3848. return 0;
  3849. }
  3850. int lua_Joint_rotateY(lua_State* state)
  3851. {
  3852. // Get the number of parameters.
  3853. int paramCount = lua_gettop(state);
  3854. // Attempt to match the parameters to a valid binding.
  3855. switch (paramCount)
  3856. {
  3857. case 2:
  3858. {
  3859. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3860. lua_type(state, 2) == LUA_TNUMBER)
  3861. {
  3862. // Get parameter 1 off the stack.
  3863. float param1 = (float)luaL_checknumber(state, 2);
  3864. Joint* instance = getInstance(state);
  3865. instance->rotateY(param1);
  3866. return 0;
  3867. }
  3868. lua_pushstring(state, "lua_Joint_rotateY - Failed to match the given parameters to a valid function signature.");
  3869. lua_error(state);
  3870. break;
  3871. }
  3872. default:
  3873. {
  3874. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3875. lua_error(state);
  3876. break;
  3877. }
  3878. }
  3879. return 0;
  3880. }
  3881. int lua_Joint_rotateZ(lua_State* state)
  3882. {
  3883. // Get the number of parameters.
  3884. int paramCount = lua_gettop(state);
  3885. // Attempt to match the parameters to a valid binding.
  3886. switch (paramCount)
  3887. {
  3888. case 2:
  3889. {
  3890. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3891. lua_type(state, 2) == LUA_TNUMBER)
  3892. {
  3893. // Get parameter 1 off the stack.
  3894. float param1 = (float)luaL_checknumber(state, 2);
  3895. Joint* instance = getInstance(state);
  3896. instance->rotateZ(param1);
  3897. return 0;
  3898. }
  3899. lua_pushstring(state, "lua_Joint_rotateZ - Failed to match the given parameters to a valid function signature.");
  3900. lua_error(state);
  3901. break;
  3902. }
  3903. default:
  3904. {
  3905. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3906. lua_error(state);
  3907. break;
  3908. }
  3909. }
  3910. return 0;
  3911. }
  3912. int lua_Joint_scale(lua_State* state)
  3913. {
  3914. // Get the number of parameters.
  3915. int paramCount = lua_gettop(state);
  3916. // Attempt to match the parameters to a valid binding.
  3917. switch (paramCount)
  3918. {
  3919. case 2:
  3920. {
  3921. do
  3922. {
  3923. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3924. lua_type(state, 2) == LUA_TNUMBER)
  3925. {
  3926. // Get parameter 1 off the stack.
  3927. float param1 = (float)luaL_checknumber(state, 2);
  3928. Joint* instance = getInstance(state);
  3929. instance->scale(param1);
  3930. return 0;
  3931. }
  3932. } while (0);
  3933. do
  3934. {
  3935. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3936. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3937. {
  3938. // Get parameter 1 off the stack.
  3939. bool param1Valid;
  3940. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  3941. if (!param1Valid)
  3942. break;
  3943. Joint* instance = getInstance(state);
  3944. instance->scale(*param1);
  3945. return 0;
  3946. }
  3947. } while (0);
  3948. lua_pushstring(state, "lua_Joint_scale - Failed to match the given parameters to a valid function signature.");
  3949. lua_error(state);
  3950. break;
  3951. }
  3952. case 4:
  3953. {
  3954. do
  3955. {
  3956. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3957. lua_type(state, 2) == LUA_TNUMBER &&
  3958. lua_type(state, 3) == LUA_TNUMBER &&
  3959. lua_type(state, 4) == LUA_TNUMBER)
  3960. {
  3961. // Get parameter 1 off the stack.
  3962. float param1 = (float)luaL_checknumber(state, 2);
  3963. // Get parameter 2 off the stack.
  3964. float param2 = (float)luaL_checknumber(state, 3);
  3965. // Get parameter 3 off the stack.
  3966. float param3 = (float)luaL_checknumber(state, 4);
  3967. Joint* instance = getInstance(state);
  3968. instance->scale(param1, param2, param3);
  3969. return 0;
  3970. }
  3971. } while (0);
  3972. lua_pushstring(state, "lua_Joint_scale - Failed to match the given parameters to a valid function signature.");
  3973. lua_error(state);
  3974. break;
  3975. }
  3976. default:
  3977. {
  3978. lua_pushstring(state, "Invalid number of parameters (expected 2 or 4).");
  3979. lua_error(state);
  3980. break;
  3981. }
  3982. }
  3983. return 0;
  3984. }
  3985. int lua_Joint_scaleX(lua_State* state)
  3986. {
  3987. // Get the number of parameters.
  3988. int paramCount = lua_gettop(state);
  3989. // Attempt to match the parameters to a valid binding.
  3990. switch (paramCount)
  3991. {
  3992. case 2:
  3993. {
  3994. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3995. lua_type(state, 2) == LUA_TNUMBER)
  3996. {
  3997. // Get parameter 1 off the stack.
  3998. float param1 = (float)luaL_checknumber(state, 2);
  3999. Joint* instance = getInstance(state);
  4000. instance->scaleX(param1);
  4001. return 0;
  4002. }
  4003. lua_pushstring(state, "lua_Joint_scaleX - Failed to match the given parameters to a valid function signature.");
  4004. lua_error(state);
  4005. break;
  4006. }
  4007. default:
  4008. {
  4009. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4010. lua_error(state);
  4011. break;
  4012. }
  4013. }
  4014. return 0;
  4015. }
  4016. int lua_Joint_scaleY(lua_State* state)
  4017. {
  4018. // Get the number of parameters.
  4019. int paramCount = lua_gettop(state);
  4020. // Attempt to match the parameters to a valid binding.
  4021. switch (paramCount)
  4022. {
  4023. case 2:
  4024. {
  4025. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4026. lua_type(state, 2) == LUA_TNUMBER)
  4027. {
  4028. // Get parameter 1 off the stack.
  4029. float param1 = (float)luaL_checknumber(state, 2);
  4030. Joint* instance = getInstance(state);
  4031. instance->scaleY(param1);
  4032. return 0;
  4033. }
  4034. lua_pushstring(state, "lua_Joint_scaleY - Failed to match the given parameters to a valid function signature.");
  4035. lua_error(state);
  4036. break;
  4037. }
  4038. default:
  4039. {
  4040. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4041. lua_error(state);
  4042. break;
  4043. }
  4044. }
  4045. return 0;
  4046. }
  4047. int lua_Joint_scaleZ(lua_State* state)
  4048. {
  4049. // Get the number of parameters.
  4050. int paramCount = lua_gettop(state);
  4051. // Attempt to match the parameters to a valid binding.
  4052. switch (paramCount)
  4053. {
  4054. case 2:
  4055. {
  4056. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4057. lua_type(state, 2) == LUA_TNUMBER)
  4058. {
  4059. // Get parameter 1 off the stack.
  4060. float param1 = (float)luaL_checknumber(state, 2);
  4061. Joint* instance = getInstance(state);
  4062. instance->scaleZ(param1);
  4063. return 0;
  4064. }
  4065. lua_pushstring(state, "lua_Joint_scaleZ - Failed to match the given parameters to a valid function signature.");
  4066. lua_error(state);
  4067. break;
  4068. }
  4069. default:
  4070. {
  4071. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4072. lua_error(state);
  4073. break;
  4074. }
  4075. }
  4076. return 0;
  4077. }
  4078. int lua_Joint_set(lua_State* state)
  4079. {
  4080. // Get the number of parameters.
  4081. int paramCount = lua_gettop(state);
  4082. // Attempt to match the parameters to a valid binding.
  4083. switch (paramCount)
  4084. {
  4085. case 2:
  4086. {
  4087. do
  4088. {
  4089. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4090. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  4091. {
  4092. // Get parameter 1 off the stack.
  4093. bool param1Valid;
  4094. gameplay::ScriptUtil::LuaArray<Transform> param1 = gameplay::ScriptUtil::getObjectPointer<Transform>(2, "Transform", true, &param1Valid);
  4095. if (!param1Valid)
  4096. break;
  4097. Joint* instance = getInstance(state);
  4098. instance->set(*param1);
  4099. return 0;
  4100. }
  4101. } while (0);
  4102. lua_pushstring(state, "lua_Joint_set - Failed to match the given parameters to a valid function signature.");
  4103. lua_error(state);
  4104. break;
  4105. }
  4106. case 4:
  4107. {
  4108. do
  4109. {
  4110. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4111. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  4112. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4113. (lua_type(state, 4) == LUA_TUSERDATA || lua_type(state, 4) == LUA_TNIL))
  4114. {
  4115. // Get parameter 1 off the stack.
  4116. bool param1Valid;
  4117. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  4118. if (!param1Valid)
  4119. break;
  4120. // Get parameter 2 off the stack.
  4121. bool param2Valid;
  4122. gameplay::ScriptUtil::LuaArray<Quaternion> param2 = gameplay::ScriptUtil::getObjectPointer<Quaternion>(3, "Quaternion", true, &param2Valid);
  4123. if (!param2Valid)
  4124. break;
  4125. // Get parameter 3 off the stack.
  4126. bool param3Valid;
  4127. gameplay::ScriptUtil::LuaArray<Vector3> param3 = gameplay::ScriptUtil::getObjectPointer<Vector3>(4, "Vector3", true, &param3Valid);
  4128. if (!param3Valid)
  4129. break;
  4130. Joint* instance = getInstance(state);
  4131. instance->set(*param1, *param2, *param3);
  4132. return 0;
  4133. }
  4134. } while (0);
  4135. do
  4136. {
  4137. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4138. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  4139. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4140. (lua_type(state, 4) == LUA_TUSERDATA || lua_type(state, 4) == LUA_TNIL))
  4141. {
  4142. // Get parameter 1 off the stack.
  4143. bool param1Valid;
  4144. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  4145. if (!param1Valid)
  4146. break;
  4147. // Get parameter 2 off the stack.
  4148. bool param2Valid;
  4149. gameplay::ScriptUtil::LuaArray<Matrix> param2 = gameplay::ScriptUtil::getObjectPointer<Matrix>(3, "Matrix", true, &param2Valid);
  4150. if (!param2Valid)
  4151. break;
  4152. // Get parameter 3 off the stack.
  4153. bool param3Valid;
  4154. gameplay::ScriptUtil::LuaArray<Vector3> param3 = gameplay::ScriptUtil::getObjectPointer<Vector3>(4, "Vector3", true, &param3Valid);
  4155. if (!param3Valid)
  4156. break;
  4157. Joint* instance = getInstance(state);
  4158. instance->set(*param1, *param2, *param3);
  4159. return 0;
  4160. }
  4161. } while (0);
  4162. lua_pushstring(state, "lua_Joint_set - Failed to match the given parameters to a valid function signature.");
  4163. lua_error(state);
  4164. break;
  4165. }
  4166. case 5:
  4167. {
  4168. do
  4169. {
  4170. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4171. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  4172. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4173. lua_type(state, 4) == LUA_TNUMBER &&
  4174. (lua_type(state, 5) == LUA_TUSERDATA || lua_type(state, 5) == LUA_TNIL))
  4175. {
  4176. // Get parameter 1 off the stack.
  4177. bool param1Valid;
  4178. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  4179. if (!param1Valid)
  4180. break;
  4181. // Get parameter 2 off the stack.
  4182. bool param2Valid;
  4183. gameplay::ScriptUtil::LuaArray<Vector3> param2 = gameplay::ScriptUtil::getObjectPointer<Vector3>(3, "Vector3", true, &param2Valid);
  4184. if (!param2Valid)
  4185. break;
  4186. // Get parameter 3 off the stack.
  4187. float param3 = (float)luaL_checknumber(state, 4);
  4188. // Get parameter 4 off the stack.
  4189. bool param4Valid;
  4190. gameplay::ScriptUtil::LuaArray<Vector3> param4 = gameplay::ScriptUtil::getObjectPointer<Vector3>(5, "Vector3", true, &param4Valid);
  4191. if (!param4Valid)
  4192. break;
  4193. Joint* instance = getInstance(state);
  4194. instance->set(*param1, *param2, param3, *param4);
  4195. return 0;
  4196. }
  4197. } while (0);
  4198. lua_pushstring(state, "lua_Joint_set - Failed to match the given parameters to a valid function signature.");
  4199. lua_error(state);
  4200. break;
  4201. }
  4202. default:
  4203. {
  4204. lua_pushstring(state, "Invalid number of parameters (expected 2, 4 or 5).");
  4205. lua_error(state);
  4206. break;
  4207. }
  4208. }
  4209. return 0;
  4210. }
  4211. int lua_Joint_setAgent(lua_State* state)
  4212. {
  4213. // Get the number of parameters.
  4214. int paramCount = lua_gettop(state);
  4215. // Attempt to match the parameters to a valid binding.
  4216. switch (paramCount)
  4217. {
  4218. case 2:
  4219. {
  4220. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4221. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4222. {
  4223. // Get parameter 1 off the stack.
  4224. bool param1Valid;
  4225. gameplay::ScriptUtil::LuaArray<AIAgent> param1 = gameplay::ScriptUtil::getObjectPointer<AIAgent>(2, "AIAgent", false, &param1Valid);
  4226. if (!param1Valid)
  4227. {
  4228. lua_pushstring(state, "Failed to convert parameter 1 to type 'AIAgent'.");
  4229. lua_error(state);
  4230. }
  4231. Joint* instance = getInstance(state);
  4232. instance->setAgent(param1);
  4233. return 0;
  4234. }
  4235. lua_pushstring(state, "lua_Joint_setAgent - Failed to match the given parameters to a valid function signature.");
  4236. lua_error(state);
  4237. break;
  4238. }
  4239. default:
  4240. {
  4241. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4242. lua_error(state);
  4243. break;
  4244. }
  4245. }
  4246. return 0;
  4247. }
  4248. int lua_Joint_setAnimationPropertyValue(lua_State* state)
  4249. {
  4250. // Get the number of parameters.
  4251. int paramCount = lua_gettop(state);
  4252. // Attempt to match the parameters to a valid binding.
  4253. switch (paramCount)
  4254. {
  4255. case 3:
  4256. {
  4257. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4258. lua_type(state, 2) == LUA_TNUMBER &&
  4259. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  4260. {
  4261. // Get parameter 1 off the stack.
  4262. int param1 = (int)luaL_checkint(state, 2);
  4263. // Get parameter 2 off the stack.
  4264. bool param2Valid;
  4265. gameplay::ScriptUtil::LuaArray<AnimationValue> param2 = gameplay::ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false, &param2Valid);
  4266. if (!param2Valid)
  4267. {
  4268. lua_pushstring(state, "Failed to convert parameter 2 to type 'AnimationValue'.");
  4269. lua_error(state);
  4270. }
  4271. Joint* instance = getInstance(state);
  4272. instance->setAnimationPropertyValue(param1, param2);
  4273. return 0;
  4274. }
  4275. lua_pushstring(state, "lua_Joint_setAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  4276. lua_error(state);
  4277. break;
  4278. }
  4279. case 4:
  4280. {
  4281. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4282. lua_type(state, 2) == LUA_TNUMBER &&
  4283. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL) &&
  4284. lua_type(state, 4) == LUA_TNUMBER)
  4285. {
  4286. // Get parameter 1 off the stack.
  4287. int param1 = (int)luaL_checkint(state, 2);
  4288. // Get parameter 2 off the stack.
  4289. bool param2Valid;
  4290. gameplay::ScriptUtil::LuaArray<AnimationValue> param2 = gameplay::ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false, &param2Valid);
  4291. if (!param2Valid)
  4292. {
  4293. lua_pushstring(state, "Failed to convert parameter 2 to type 'AnimationValue'.");
  4294. lua_error(state);
  4295. }
  4296. // Get parameter 3 off the stack.
  4297. float param3 = (float)luaL_checknumber(state, 4);
  4298. Joint* instance = getInstance(state);
  4299. instance->setAnimationPropertyValue(param1, param2, param3);
  4300. return 0;
  4301. }
  4302. lua_pushstring(state, "lua_Joint_setAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  4303. lua_error(state);
  4304. break;
  4305. }
  4306. default:
  4307. {
  4308. lua_pushstring(state, "Invalid number of parameters (expected 3 or 4).");
  4309. lua_error(state);
  4310. break;
  4311. }
  4312. }
  4313. return 0;
  4314. }
  4315. int lua_Joint_setAudioSource(lua_State* state)
  4316. {
  4317. // Get the number of parameters.
  4318. int paramCount = lua_gettop(state);
  4319. // Attempt to match the parameters to a valid binding.
  4320. switch (paramCount)
  4321. {
  4322. case 2:
  4323. {
  4324. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4325. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4326. {
  4327. // Get parameter 1 off the stack.
  4328. bool param1Valid;
  4329. gameplay::ScriptUtil::LuaArray<AudioSource> param1 = gameplay::ScriptUtil::getObjectPointer<AudioSource>(2, "AudioSource", false, &param1Valid);
  4330. if (!param1Valid)
  4331. {
  4332. lua_pushstring(state, "Failed to convert parameter 1 to type 'AudioSource'.");
  4333. lua_error(state);
  4334. }
  4335. Joint* instance = getInstance(state);
  4336. instance->setAudioSource(param1);
  4337. return 0;
  4338. }
  4339. lua_pushstring(state, "lua_Joint_setAudioSource - Failed to match the given parameters to a valid function signature.");
  4340. lua_error(state);
  4341. break;
  4342. }
  4343. default:
  4344. {
  4345. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4346. lua_error(state);
  4347. break;
  4348. }
  4349. }
  4350. return 0;
  4351. }
  4352. int lua_Joint_setCamera(lua_State* state)
  4353. {
  4354. // Get the number of parameters.
  4355. int paramCount = lua_gettop(state);
  4356. // Attempt to match the parameters to a valid binding.
  4357. switch (paramCount)
  4358. {
  4359. case 2:
  4360. {
  4361. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4362. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4363. {
  4364. // Get parameter 1 off the stack.
  4365. bool param1Valid;
  4366. gameplay::ScriptUtil::LuaArray<Camera> param1 = gameplay::ScriptUtil::getObjectPointer<Camera>(2, "Camera", false, &param1Valid);
  4367. if (!param1Valid)
  4368. {
  4369. lua_pushstring(state, "Failed to convert parameter 1 to type 'Camera'.");
  4370. lua_error(state);
  4371. }
  4372. Joint* instance = getInstance(state);
  4373. instance->setCamera(param1);
  4374. return 0;
  4375. }
  4376. lua_pushstring(state, "lua_Joint_setCamera - Failed to match the given parameters to a valid function signature.");
  4377. lua_error(state);
  4378. break;
  4379. }
  4380. default:
  4381. {
  4382. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4383. lua_error(state);
  4384. break;
  4385. }
  4386. }
  4387. return 0;
  4388. }
  4389. int lua_Joint_setCollisionObject(lua_State* state)
  4390. {
  4391. // Get the number of parameters.
  4392. int paramCount = lua_gettop(state);
  4393. // Attempt to match the parameters to a valid binding.
  4394. switch (paramCount)
  4395. {
  4396. case 2:
  4397. {
  4398. do
  4399. {
  4400. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4401. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  4402. {
  4403. // Get parameter 1 off the stack.
  4404. PhysicsCollisionObject::Type param1 = (PhysicsCollisionObject::Type)lua_enumFromString_PhysicsCollisionObjectType(luaL_checkstring(state, 2));
  4405. Joint* instance = getInstance(state);
  4406. void* returnPtr = (void*)instance->setCollisionObject(param1);
  4407. if (returnPtr)
  4408. {
  4409. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4410. object->instance = returnPtr;
  4411. object->owns = false;
  4412. luaL_getmetatable(state, "PhysicsCollisionObject");
  4413. lua_setmetatable(state, -2);
  4414. }
  4415. else
  4416. {
  4417. lua_pushnil(state);
  4418. }
  4419. return 1;
  4420. }
  4421. } while (0);
  4422. do
  4423. {
  4424. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4425. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  4426. {
  4427. // Get parameter 1 off the stack.
  4428. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  4429. Joint* instance = getInstance(state);
  4430. void* returnPtr = (void*)instance->setCollisionObject(param1);
  4431. if (returnPtr)
  4432. {
  4433. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4434. object->instance = returnPtr;
  4435. object->owns = false;
  4436. luaL_getmetatable(state, "PhysicsCollisionObject");
  4437. lua_setmetatable(state, -2);
  4438. }
  4439. else
  4440. {
  4441. lua_pushnil(state);
  4442. }
  4443. return 1;
  4444. }
  4445. } while (0);
  4446. do
  4447. {
  4448. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4449. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4450. {
  4451. // Get parameter 1 off the stack.
  4452. bool param1Valid;
  4453. gameplay::ScriptUtil::LuaArray<Properties> param1 = gameplay::ScriptUtil::getObjectPointer<Properties>(2, "Properties", false, &param1Valid);
  4454. if (!param1Valid)
  4455. break;
  4456. Joint* instance = getInstance(state);
  4457. void* returnPtr = (void*)instance->setCollisionObject(param1);
  4458. if (returnPtr)
  4459. {
  4460. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4461. object->instance = returnPtr;
  4462. object->owns = false;
  4463. luaL_getmetatable(state, "PhysicsCollisionObject");
  4464. lua_setmetatable(state, -2);
  4465. }
  4466. else
  4467. {
  4468. lua_pushnil(state);
  4469. }
  4470. return 1;
  4471. }
  4472. } while (0);
  4473. lua_pushstring(state, "lua_Joint_setCollisionObject - Failed to match the given parameters to a valid function signature.");
  4474. lua_error(state);
  4475. break;
  4476. }
  4477. case 3:
  4478. {
  4479. do
  4480. {
  4481. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4482. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  4483. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL))
  4484. {
  4485. // Get parameter 1 off the stack.
  4486. PhysicsCollisionObject::Type param1 = (PhysicsCollisionObject::Type)lua_enumFromString_PhysicsCollisionObjectType(luaL_checkstring(state, 2));
  4487. // Get parameter 2 off the stack.
  4488. bool param2Valid;
  4489. gameplay::ScriptUtil::LuaArray<PhysicsCollisionShape::Definition> param2 = gameplay::ScriptUtil::getObjectPointer<PhysicsCollisionShape::Definition>(3, "PhysicsCollisionShapeDefinition", true, &param2Valid);
  4490. if (!param2Valid)
  4491. break;
  4492. Joint* instance = getInstance(state);
  4493. void* returnPtr = (void*)instance->setCollisionObject(param1, *param2);
  4494. if (returnPtr)
  4495. {
  4496. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4497. object->instance = returnPtr;
  4498. object->owns = false;
  4499. luaL_getmetatable(state, "PhysicsCollisionObject");
  4500. lua_setmetatable(state, -2);
  4501. }
  4502. else
  4503. {
  4504. lua_pushnil(state);
  4505. }
  4506. return 1;
  4507. }
  4508. } while (0);
  4509. lua_pushstring(state, "lua_Joint_setCollisionObject - Failed to match the given parameters to a valid function signature.");
  4510. lua_error(state);
  4511. break;
  4512. }
  4513. case 4:
  4514. {
  4515. do
  4516. {
  4517. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4518. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  4519. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4520. (lua_type(state, 4) == LUA_TUSERDATA || lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TNIL))
  4521. {
  4522. // Get parameter 1 off the stack.
  4523. PhysicsCollisionObject::Type param1 = (PhysicsCollisionObject::Type)lua_enumFromString_PhysicsCollisionObjectType(luaL_checkstring(state, 2));
  4524. // Get parameter 2 off the stack.
  4525. bool param2Valid;
  4526. gameplay::ScriptUtil::LuaArray<PhysicsCollisionShape::Definition> param2 = gameplay::ScriptUtil::getObjectPointer<PhysicsCollisionShape::Definition>(3, "PhysicsCollisionShapeDefinition", true, &param2Valid);
  4527. if (!param2Valid)
  4528. break;
  4529. // Get parameter 3 off the stack.
  4530. bool param3Valid;
  4531. gameplay::ScriptUtil::LuaArray<PhysicsRigidBody::Parameters> param3 = gameplay::ScriptUtil::getObjectPointer<PhysicsRigidBody::Parameters>(4, "PhysicsRigidBodyParameters", false, &param3Valid);
  4532. if (!param3Valid)
  4533. break;
  4534. Joint* instance = getInstance(state);
  4535. void* returnPtr = (void*)instance->setCollisionObject(param1, *param2, param3);
  4536. if (returnPtr)
  4537. {
  4538. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4539. object->instance = returnPtr;
  4540. object->owns = false;
  4541. luaL_getmetatable(state, "PhysicsCollisionObject");
  4542. lua_setmetatable(state, -2);
  4543. }
  4544. else
  4545. {
  4546. lua_pushnil(state);
  4547. }
  4548. return 1;
  4549. }
  4550. } while (0);
  4551. lua_pushstring(state, "lua_Joint_setCollisionObject - Failed to match the given parameters to a valid function signature.");
  4552. lua_error(state);
  4553. break;
  4554. }
  4555. case 5:
  4556. {
  4557. do
  4558. {
  4559. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4560. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  4561. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4562. (lua_type(state, 4) == LUA_TUSERDATA || lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TNIL) &&
  4563. lua_type(state, 5) == LUA_TNUMBER)
  4564. {
  4565. // Get parameter 1 off the stack.
  4566. PhysicsCollisionObject::Type param1 = (PhysicsCollisionObject::Type)lua_enumFromString_PhysicsCollisionObjectType(luaL_checkstring(state, 2));
  4567. // Get parameter 2 off the stack.
  4568. bool param2Valid;
  4569. gameplay::ScriptUtil::LuaArray<PhysicsCollisionShape::Definition> param2 = gameplay::ScriptUtil::getObjectPointer<PhysicsCollisionShape::Definition>(3, "PhysicsCollisionShapeDefinition", true, &param2Valid);
  4570. if (!param2Valid)
  4571. break;
  4572. // Get parameter 3 off the stack.
  4573. bool param3Valid;
  4574. gameplay::ScriptUtil::LuaArray<PhysicsRigidBody::Parameters> param3 = gameplay::ScriptUtil::getObjectPointer<PhysicsRigidBody::Parameters>(4, "PhysicsRigidBodyParameters", false, &param3Valid);
  4575. if (!param3Valid)
  4576. break;
  4577. // Get parameter 4 off the stack.
  4578. int param4 = (int)luaL_checkint(state, 5);
  4579. Joint* instance = getInstance(state);
  4580. void* returnPtr = (void*)instance->setCollisionObject(param1, *param2, param3, param4);
  4581. if (returnPtr)
  4582. {
  4583. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4584. object->instance = returnPtr;
  4585. object->owns = false;
  4586. luaL_getmetatable(state, "PhysicsCollisionObject");
  4587. lua_setmetatable(state, -2);
  4588. }
  4589. else
  4590. {
  4591. lua_pushnil(state);
  4592. }
  4593. return 1;
  4594. }
  4595. } while (0);
  4596. lua_pushstring(state, "lua_Joint_setCollisionObject - Failed to match the given parameters to a valid function signature.");
  4597. lua_error(state);
  4598. break;
  4599. }
  4600. case 6:
  4601. {
  4602. do
  4603. {
  4604. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4605. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  4606. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  4607. (lua_type(state, 4) == LUA_TUSERDATA || lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TNIL) &&
  4608. lua_type(state, 5) == LUA_TNUMBER &&
  4609. lua_type(state, 6) == LUA_TNUMBER)
  4610. {
  4611. // Get parameter 1 off the stack.
  4612. PhysicsCollisionObject::Type param1 = (PhysicsCollisionObject::Type)lua_enumFromString_PhysicsCollisionObjectType(luaL_checkstring(state, 2));
  4613. // Get parameter 2 off the stack.
  4614. bool param2Valid;
  4615. gameplay::ScriptUtil::LuaArray<PhysicsCollisionShape::Definition> param2 = gameplay::ScriptUtil::getObjectPointer<PhysicsCollisionShape::Definition>(3, "PhysicsCollisionShapeDefinition", true, &param2Valid);
  4616. if (!param2Valid)
  4617. break;
  4618. // Get parameter 3 off the stack.
  4619. bool param3Valid;
  4620. gameplay::ScriptUtil::LuaArray<PhysicsRigidBody::Parameters> param3 = gameplay::ScriptUtil::getObjectPointer<PhysicsRigidBody::Parameters>(4, "PhysicsRigidBodyParameters", false, &param3Valid);
  4621. if (!param3Valid)
  4622. break;
  4623. // Get parameter 4 off the stack.
  4624. int param4 = (int)luaL_checkint(state, 5);
  4625. // Get parameter 5 off the stack.
  4626. int param5 = (int)luaL_checkint(state, 6);
  4627. Joint* instance = getInstance(state);
  4628. void* returnPtr = (void*)instance->setCollisionObject(param1, *param2, param3, param4, param5);
  4629. if (returnPtr)
  4630. {
  4631. gameplay::ScriptUtil::LuaObject* object = (gameplay::ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(gameplay::ScriptUtil::LuaObject));
  4632. object->instance = returnPtr;
  4633. object->owns = false;
  4634. luaL_getmetatable(state, "PhysicsCollisionObject");
  4635. lua_setmetatable(state, -2);
  4636. }
  4637. else
  4638. {
  4639. lua_pushnil(state);
  4640. }
  4641. return 1;
  4642. }
  4643. } while (0);
  4644. lua_pushstring(state, "lua_Joint_setCollisionObject - Failed to match the given parameters to a valid function signature.");
  4645. lua_error(state);
  4646. break;
  4647. }
  4648. default:
  4649. {
  4650. lua_pushstring(state, "Invalid number of parameters (expected 2, 3, 4, 5 or 6).");
  4651. lua_error(state);
  4652. break;
  4653. }
  4654. }
  4655. return 0;
  4656. }
  4657. int lua_Joint_setForm(lua_State* state)
  4658. {
  4659. // Get the number of parameters.
  4660. int paramCount = lua_gettop(state);
  4661. // Attempt to match the parameters to a valid binding.
  4662. switch (paramCount)
  4663. {
  4664. case 2:
  4665. {
  4666. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4667. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4668. {
  4669. // Get parameter 1 off the stack.
  4670. bool param1Valid;
  4671. gameplay::ScriptUtil::LuaArray<Form> param1 = gameplay::ScriptUtil::getObjectPointer<Form>(2, "Form", false, &param1Valid);
  4672. if (!param1Valid)
  4673. {
  4674. lua_pushstring(state, "Failed to convert parameter 1 to type 'Form'.");
  4675. lua_error(state);
  4676. }
  4677. Joint* instance = getInstance(state);
  4678. instance->setForm(param1);
  4679. return 0;
  4680. }
  4681. lua_pushstring(state, "lua_Joint_setForm - Failed to match the given parameters to a valid function signature.");
  4682. lua_error(state);
  4683. break;
  4684. }
  4685. default:
  4686. {
  4687. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4688. lua_error(state);
  4689. break;
  4690. }
  4691. }
  4692. return 0;
  4693. }
  4694. int lua_Joint_setId(lua_State* state)
  4695. {
  4696. // Get the number of parameters.
  4697. int paramCount = lua_gettop(state);
  4698. // Attempt to match the parameters to a valid binding.
  4699. switch (paramCount)
  4700. {
  4701. case 2:
  4702. {
  4703. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4704. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  4705. {
  4706. // Get parameter 1 off the stack.
  4707. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  4708. Joint* instance = getInstance(state);
  4709. instance->setId(param1);
  4710. return 0;
  4711. }
  4712. lua_pushstring(state, "lua_Joint_setId - Failed to match the given parameters to a valid function signature.");
  4713. lua_error(state);
  4714. break;
  4715. }
  4716. default:
  4717. {
  4718. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4719. lua_error(state);
  4720. break;
  4721. }
  4722. }
  4723. return 0;
  4724. }
  4725. int lua_Joint_setIdentity(lua_State* state)
  4726. {
  4727. // Get the number of parameters.
  4728. int paramCount = lua_gettop(state);
  4729. // Attempt to match the parameters to a valid binding.
  4730. switch (paramCount)
  4731. {
  4732. case 1:
  4733. {
  4734. if ((lua_type(state, 1) == LUA_TUSERDATA))
  4735. {
  4736. Joint* instance = getInstance(state);
  4737. instance->setIdentity();
  4738. return 0;
  4739. }
  4740. lua_pushstring(state, "lua_Joint_setIdentity - Failed to match the given parameters to a valid function signature.");
  4741. lua_error(state);
  4742. break;
  4743. }
  4744. default:
  4745. {
  4746. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  4747. lua_error(state);
  4748. break;
  4749. }
  4750. }
  4751. return 0;
  4752. }
  4753. int lua_Joint_setLight(lua_State* state)
  4754. {
  4755. // Get the number of parameters.
  4756. int paramCount = lua_gettop(state);
  4757. // Attempt to match the parameters to a valid binding.
  4758. switch (paramCount)
  4759. {
  4760. case 2:
  4761. {
  4762. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4763. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4764. {
  4765. // Get parameter 1 off the stack.
  4766. bool param1Valid;
  4767. gameplay::ScriptUtil::LuaArray<Light> param1 = gameplay::ScriptUtil::getObjectPointer<Light>(2, "Light", false, &param1Valid);
  4768. if (!param1Valid)
  4769. {
  4770. lua_pushstring(state, "Failed to convert parameter 1 to type 'Light'.");
  4771. lua_error(state);
  4772. }
  4773. Joint* instance = getInstance(state);
  4774. instance->setLight(param1);
  4775. return 0;
  4776. }
  4777. lua_pushstring(state, "lua_Joint_setLight - Failed to match the given parameters to a valid function signature.");
  4778. lua_error(state);
  4779. break;
  4780. }
  4781. default:
  4782. {
  4783. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4784. lua_error(state);
  4785. break;
  4786. }
  4787. }
  4788. return 0;
  4789. }
  4790. int lua_Joint_setModel(lua_State* state)
  4791. {
  4792. // Get the number of parameters.
  4793. int paramCount = lua_gettop(state);
  4794. // Attempt to match the parameters to a valid binding.
  4795. switch (paramCount)
  4796. {
  4797. case 2:
  4798. {
  4799. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4800. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4801. {
  4802. // Get parameter 1 off the stack.
  4803. bool param1Valid;
  4804. gameplay::ScriptUtil::LuaArray<Model> param1 = gameplay::ScriptUtil::getObjectPointer<Model>(2, "Model", false, &param1Valid);
  4805. if (!param1Valid)
  4806. {
  4807. lua_pushstring(state, "Failed to convert parameter 1 to type 'Model'.");
  4808. lua_error(state);
  4809. }
  4810. Joint* instance = getInstance(state);
  4811. instance->setModel(param1);
  4812. return 0;
  4813. }
  4814. lua_pushstring(state, "lua_Joint_setModel - Failed to match the given parameters to a valid function signature.");
  4815. lua_error(state);
  4816. break;
  4817. }
  4818. default:
  4819. {
  4820. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4821. lua_error(state);
  4822. break;
  4823. }
  4824. }
  4825. return 0;
  4826. }
  4827. int lua_Joint_setParticleEmitter(lua_State* state)
  4828. {
  4829. // Get the number of parameters.
  4830. int paramCount = lua_gettop(state);
  4831. // Attempt to match the parameters to a valid binding.
  4832. switch (paramCount)
  4833. {
  4834. case 2:
  4835. {
  4836. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4837. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4838. {
  4839. // Get parameter 1 off the stack.
  4840. bool param1Valid;
  4841. gameplay::ScriptUtil::LuaArray<ParticleEmitter> param1 = gameplay::ScriptUtil::getObjectPointer<ParticleEmitter>(2, "ParticleEmitter", false, &param1Valid);
  4842. if (!param1Valid)
  4843. {
  4844. lua_pushstring(state, "Failed to convert parameter 1 to type 'ParticleEmitter'.");
  4845. lua_error(state);
  4846. }
  4847. Joint* instance = getInstance(state);
  4848. instance->setParticleEmitter(param1);
  4849. return 0;
  4850. }
  4851. lua_pushstring(state, "lua_Joint_setParticleEmitter - Failed to match the given parameters to a valid function signature.");
  4852. lua_error(state);
  4853. break;
  4854. }
  4855. default:
  4856. {
  4857. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4858. lua_error(state);
  4859. break;
  4860. }
  4861. }
  4862. return 0;
  4863. }
  4864. int lua_Joint_setRotation(lua_State* state)
  4865. {
  4866. // Get the number of parameters.
  4867. int paramCount = lua_gettop(state);
  4868. // Attempt to match the parameters to a valid binding.
  4869. switch (paramCount)
  4870. {
  4871. case 2:
  4872. {
  4873. do
  4874. {
  4875. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4876. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  4877. {
  4878. // Get parameter 1 off the stack.
  4879. bool param1Valid;
  4880. gameplay::ScriptUtil::LuaArray<Quaternion> param1 = gameplay::ScriptUtil::getObjectPointer<Quaternion>(2, "Quaternion", true, &param1Valid);
  4881. if (!param1Valid)
  4882. break;
  4883. Joint* instance = getInstance(state);
  4884. instance->setRotation(*param1);
  4885. return 0;
  4886. }
  4887. } while (0);
  4888. do
  4889. {
  4890. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4891. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  4892. {
  4893. // Get parameter 1 off the stack.
  4894. bool param1Valid;
  4895. gameplay::ScriptUtil::LuaArray<Matrix> param1 = gameplay::ScriptUtil::getObjectPointer<Matrix>(2, "Matrix", true, &param1Valid);
  4896. if (!param1Valid)
  4897. break;
  4898. Joint* instance = getInstance(state);
  4899. instance->setRotation(*param1);
  4900. return 0;
  4901. }
  4902. } while (0);
  4903. lua_pushstring(state, "lua_Joint_setRotation - Failed to match the given parameters to a valid function signature.");
  4904. lua_error(state);
  4905. break;
  4906. }
  4907. case 3:
  4908. {
  4909. do
  4910. {
  4911. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4912. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  4913. lua_type(state, 3) == LUA_TNUMBER)
  4914. {
  4915. // Get parameter 1 off the stack.
  4916. bool param1Valid;
  4917. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  4918. if (!param1Valid)
  4919. break;
  4920. // Get parameter 2 off the stack.
  4921. float param2 = (float)luaL_checknumber(state, 3);
  4922. Joint* instance = getInstance(state);
  4923. instance->setRotation(*param1, param2);
  4924. return 0;
  4925. }
  4926. } while (0);
  4927. lua_pushstring(state, "lua_Joint_setRotation - Failed to match the given parameters to a valid function signature.");
  4928. lua_error(state);
  4929. break;
  4930. }
  4931. case 5:
  4932. {
  4933. do
  4934. {
  4935. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4936. lua_type(state, 2) == LUA_TNUMBER &&
  4937. lua_type(state, 3) == LUA_TNUMBER &&
  4938. lua_type(state, 4) == LUA_TNUMBER &&
  4939. lua_type(state, 5) == LUA_TNUMBER)
  4940. {
  4941. // Get parameter 1 off the stack.
  4942. float param1 = (float)luaL_checknumber(state, 2);
  4943. // Get parameter 2 off the stack.
  4944. float param2 = (float)luaL_checknumber(state, 3);
  4945. // Get parameter 3 off the stack.
  4946. float param3 = (float)luaL_checknumber(state, 4);
  4947. // Get parameter 4 off the stack.
  4948. float param4 = (float)luaL_checknumber(state, 5);
  4949. Joint* instance = getInstance(state);
  4950. instance->setRotation(param1, param2, param3, param4);
  4951. return 0;
  4952. }
  4953. } while (0);
  4954. lua_pushstring(state, "lua_Joint_setRotation - Failed to match the given parameters to a valid function signature.");
  4955. lua_error(state);
  4956. break;
  4957. }
  4958. default:
  4959. {
  4960. lua_pushstring(state, "Invalid number of parameters (expected 2, 3 or 5).");
  4961. lua_error(state);
  4962. break;
  4963. }
  4964. }
  4965. return 0;
  4966. }
  4967. int lua_Joint_setScale(lua_State* state)
  4968. {
  4969. // Get the number of parameters.
  4970. int paramCount = lua_gettop(state);
  4971. // Attempt to match the parameters to a valid binding.
  4972. switch (paramCount)
  4973. {
  4974. case 2:
  4975. {
  4976. do
  4977. {
  4978. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4979. lua_type(state, 2) == LUA_TNUMBER)
  4980. {
  4981. // Get parameter 1 off the stack.
  4982. float param1 = (float)luaL_checknumber(state, 2);
  4983. Joint* instance = getInstance(state);
  4984. instance->setScale(param1);
  4985. return 0;
  4986. }
  4987. } while (0);
  4988. do
  4989. {
  4990. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  4991. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  4992. {
  4993. // Get parameter 1 off the stack.
  4994. bool param1Valid;
  4995. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  4996. if (!param1Valid)
  4997. break;
  4998. Joint* instance = getInstance(state);
  4999. instance->setScale(*param1);
  5000. return 0;
  5001. }
  5002. } while (0);
  5003. lua_pushstring(state, "lua_Joint_setScale - Failed to match the given parameters to a valid function signature.");
  5004. lua_error(state);
  5005. break;
  5006. }
  5007. case 4:
  5008. {
  5009. do
  5010. {
  5011. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5012. lua_type(state, 2) == LUA_TNUMBER &&
  5013. lua_type(state, 3) == LUA_TNUMBER &&
  5014. lua_type(state, 4) == LUA_TNUMBER)
  5015. {
  5016. // Get parameter 1 off the stack.
  5017. float param1 = (float)luaL_checknumber(state, 2);
  5018. // Get parameter 2 off the stack.
  5019. float param2 = (float)luaL_checknumber(state, 3);
  5020. // Get parameter 3 off the stack.
  5021. float param3 = (float)luaL_checknumber(state, 4);
  5022. Joint* instance = getInstance(state);
  5023. instance->setScale(param1, param2, param3);
  5024. return 0;
  5025. }
  5026. } while (0);
  5027. lua_pushstring(state, "lua_Joint_setScale - Failed to match the given parameters to a valid function signature.");
  5028. lua_error(state);
  5029. break;
  5030. }
  5031. default:
  5032. {
  5033. lua_pushstring(state, "Invalid number of parameters (expected 2 or 4).");
  5034. lua_error(state);
  5035. break;
  5036. }
  5037. }
  5038. return 0;
  5039. }
  5040. int lua_Joint_setScaleX(lua_State* state)
  5041. {
  5042. // Get the number of parameters.
  5043. int paramCount = lua_gettop(state);
  5044. // Attempt to match the parameters to a valid binding.
  5045. switch (paramCount)
  5046. {
  5047. case 2:
  5048. {
  5049. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5050. lua_type(state, 2) == LUA_TNUMBER)
  5051. {
  5052. // Get parameter 1 off the stack.
  5053. float param1 = (float)luaL_checknumber(state, 2);
  5054. Joint* instance = getInstance(state);
  5055. instance->setScaleX(param1);
  5056. return 0;
  5057. }
  5058. lua_pushstring(state, "lua_Joint_setScaleX - Failed to match the given parameters to a valid function signature.");
  5059. lua_error(state);
  5060. break;
  5061. }
  5062. default:
  5063. {
  5064. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5065. lua_error(state);
  5066. break;
  5067. }
  5068. }
  5069. return 0;
  5070. }
  5071. int lua_Joint_setScaleY(lua_State* state)
  5072. {
  5073. // Get the number of parameters.
  5074. int paramCount = lua_gettop(state);
  5075. // Attempt to match the parameters to a valid binding.
  5076. switch (paramCount)
  5077. {
  5078. case 2:
  5079. {
  5080. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5081. lua_type(state, 2) == LUA_TNUMBER)
  5082. {
  5083. // Get parameter 1 off the stack.
  5084. float param1 = (float)luaL_checknumber(state, 2);
  5085. Joint* instance = getInstance(state);
  5086. instance->setScaleY(param1);
  5087. return 0;
  5088. }
  5089. lua_pushstring(state, "lua_Joint_setScaleY - Failed to match the given parameters to a valid function signature.");
  5090. lua_error(state);
  5091. break;
  5092. }
  5093. default:
  5094. {
  5095. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5096. lua_error(state);
  5097. break;
  5098. }
  5099. }
  5100. return 0;
  5101. }
  5102. int lua_Joint_setScaleZ(lua_State* state)
  5103. {
  5104. // Get the number of parameters.
  5105. int paramCount = lua_gettop(state);
  5106. // Attempt to match the parameters to a valid binding.
  5107. switch (paramCount)
  5108. {
  5109. case 2:
  5110. {
  5111. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5112. lua_type(state, 2) == LUA_TNUMBER)
  5113. {
  5114. // Get parameter 1 off the stack.
  5115. float param1 = (float)luaL_checknumber(state, 2);
  5116. Joint* instance = getInstance(state);
  5117. instance->setScaleZ(param1);
  5118. return 0;
  5119. }
  5120. lua_pushstring(state, "lua_Joint_setScaleZ - Failed to match the given parameters to a valid function signature.");
  5121. lua_error(state);
  5122. break;
  5123. }
  5124. default:
  5125. {
  5126. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5127. lua_error(state);
  5128. break;
  5129. }
  5130. }
  5131. return 0;
  5132. }
  5133. int lua_Joint_setTag(lua_State* state)
  5134. {
  5135. // Get the number of parameters.
  5136. int paramCount = lua_gettop(state);
  5137. // Attempt to match the parameters to a valid binding.
  5138. switch (paramCount)
  5139. {
  5140. case 2:
  5141. {
  5142. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5143. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  5144. {
  5145. // Get parameter 1 off the stack.
  5146. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  5147. Joint* instance = getInstance(state);
  5148. instance->setTag(param1);
  5149. return 0;
  5150. }
  5151. lua_pushstring(state, "lua_Joint_setTag - Failed to match the given parameters to a valid function signature.");
  5152. lua_error(state);
  5153. break;
  5154. }
  5155. case 3:
  5156. {
  5157. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5158. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  5159. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  5160. {
  5161. // Get parameter 1 off the stack.
  5162. const char* param1 = gameplay::ScriptUtil::getString(2, false);
  5163. // Get parameter 2 off the stack.
  5164. const char* param2 = gameplay::ScriptUtil::getString(3, false);
  5165. Joint* instance = getInstance(state);
  5166. instance->setTag(param1, param2);
  5167. return 0;
  5168. }
  5169. lua_pushstring(state, "lua_Joint_setTag - Failed to match the given parameters to a valid function signature.");
  5170. lua_error(state);
  5171. break;
  5172. }
  5173. default:
  5174. {
  5175. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  5176. lua_error(state);
  5177. break;
  5178. }
  5179. }
  5180. return 0;
  5181. }
  5182. int lua_Joint_setTerrain(lua_State* state)
  5183. {
  5184. // Get the number of parameters.
  5185. int paramCount = lua_gettop(state);
  5186. // Attempt to match the parameters to a valid binding.
  5187. switch (paramCount)
  5188. {
  5189. case 2:
  5190. {
  5191. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5192. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  5193. {
  5194. // Get parameter 1 off the stack.
  5195. bool param1Valid;
  5196. gameplay::ScriptUtil::LuaArray<Terrain> param1 = gameplay::ScriptUtil::getObjectPointer<Terrain>(2, "Terrain", false, &param1Valid);
  5197. if (!param1Valid)
  5198. {
  5199. lua_pushstring(state, "Failed to convert parameter 1 to type 'Terrain'.");
  5200. lua_error(state);
  5201. }
  5202. Joint* instance = getInstance(state);
  5203. instance->setTerrain(param1);
  5204. return 0;
  5205. }
  5206. lua_pushstring(state, "lua_Joint_setTerrain - Failed to match the given parameters to a valid function signature.");
  5207. lua_error(state);
  5208. break;
  5209. }
  5210. default:
  5211. {
  5212. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5213. lua_error(state);
  5214. break;
  5215. }
  5216. }
  5217. return 0;
  5218. }
  5219. int lua_Joint_setTranslation(lua_State* state)
  5220. {
  5221. // Get the number of parameters.
  5222. int paramCount = lua_gettop(state);
  5223. // Attempt to match the parameters to a valid binding.
  5224. switch (paramCount)
  5225. {
  5226. case 2:
  5227. {
  5228. do
  5229. {
  5230. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5231. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  5232. {
  5233. // Get parameter 1 off the stack.
  5234. bool param1Valid;
  5235. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  5236. if (!param1Valid)
  5237. break;
  5238. Joint* instance = getInstance(state);
  5239. instance->setTranslation(*param1);
  5240. return 0;
  5241. }
  5242. } while (0);
  5243. lua_pushstring(state, "lua_Joint_setTranslation - Failed to match the given parameters to a valid function signature.");
  5244. lua_error(state);
  5245. break;
  5246. }
  5247. case 4:
  5248. {
  5249. do
  5250. {
  5251. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5252. lua_type(state, 2) == LUA_TNUMBER &&
  5253. lua_type(state, 3) == LUA_TNUMBER &&
  5254. lua_type(state, 4) == LUA_TNUMBER)
  5255. {
  5256. // Get parameter 1 off the stack.
  5257. float param1 = (float)luaL_checknumber(state, 2);
  5258. // Get parameter 2 off the stack.
  5259. float param2 = (float)luaL_checknumber(state, 3);
  5260. // Get parameter 3 off the stack.
  5261. float param3 = (float)luaL_checknumber(state, 4);
  5262. Joint* instance = getInstance(state);
  5263. instance->setTranslation(param1, param2, param3);
  5264. return 0;
  5265. }
  5266. } while (0);
  5267. lua_pushstring(state, "lua_Joint_setTranslation - Failed to match the given parameters to a valid function signature.");
  5268. lua_error(state);
  5269. break;
  5270. }
  5271. default:
  5272. {
  5273. lua_pushstring(state, "Invalid number of parameters (expected 2 or 4).");
  5274. lua_error(state);
  5275. break;
  5276. }
  5277. }
  5278. return 0;
  5279. }
  5280. int lua_Joint_setTranslationX(lua_State* state)
  5281. {
  5282. // Get the number of parameters.
  5283. int paramCount = lua_gettop(state);
  5284. // Attempt to match the parameters to a valid binding.
  5285. switch (paramCount)
  5286. {
  5287. case 2:
  5288. {
  5289. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5290. lua_type(state, 2) == LUA_TNUMBER)
  5291. {
  5292. // Get parameter 1 off the stack.
  5293. float param1 = (float)luaL_checknumber(state, 2);
  5294. Joint* instance = getInstance(state);
  5295. instance->setTranslationX(param1);
  5296. return 0;
  5297. }
  5298. lua_pushstring(state, "lua_Joint_setTranslationX - Failed to match the given parameters to a valid function signature.");
  5299. lua_error(state);
  5300. break;
  5301. }
  5302. default:
  5303. {
  5304. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5305. lua_error(state);
  5306. break;
  5307. }
  5308. }
  5309. return 0;
  5310. }
  5311. int lua_Joint_setTranslationY(lua_State* state)
  5312. {
  5313. // Get the number of parameters.
  5314. int paramCount = lua_gettop(state);
  5315. // Attempt to match the parameters to a valid binding.
  5316. switch (paramCount)
  5317. {
  5318. case 2:
  5319. {
  5320. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5321. lua_type(state, 2) == LUA_TNUMBER)
  5322. {
  5323. // Get parameter 1 off the stack.
  5324. float param1 = (float)luaL_checknumber(state, 2);
  5325. Joint* instance = getInstance(state);
  5326. instance->setTranslationY(param1);
  5327. return 0;
  5328. }
  5329. lua_pushstring(state, "lua_Joint_setTranslationY - Failed to match the given parameters to a valid function signature.");
  5330. lua_error(state);
  5331. break;
  5332. }
  5333. default:
  5334. {
  5335. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5336. lua_error(state);
  5337. break;
  5338. }
  5339. }
  5340. return 0;
  5341. }
  5342. int lua_Joint_setTranslationZ(lua_State* state)
  5343. {
  5344. // Get the number of parameters.
  5345. int paramCount = lua_gettop(state);
  5346. // Attempt to match the parameters to a valid binding.
  5347. switch (paramCount)
  5348. {
  5349. case 2:
  5350. {
  5351. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5352. lua_type(state, 2) == LUA_TNUMBER)
  5353. {
  5354. // Get parameter 1 off the stack.
  5355. float param1 = (float)luaL_checknumber(state, 2);
  5356. Joint* instance = getInstance(state);
  5357. instance->setTranslationZ(param1);
  5358. return 0;
  5359. }
  5360. lua_pushstring(state, "lua_Joint_setTranslationZ - Failed to match the given parameters to a valid function signature.");
  5361. lua_error(state);
  5362. break;
  5363. }
  5364. default:
  5365. {
  5366. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5367. lua_error(state);
  5368. break;
  5369. }
  5370. }
  5371. return 0;
  5372. }
  5373. int lua_Joint_static_ANIMATE_ROTATE(lua_State* state)
  5374. {
  5375. // Validate the number of parameters.
  5376. if (lua_gettop(state) > 0)
  5377. {
  5378. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5379. lua_error(state);
  5380. }
  5381. int result = Joint::ANIMATE_ROTATE;
  5382. // Push the return value onto the stack.
  5383. lua_pushinteger(state, result);
  5384. return 1;
  5385. }
  5386. int lua_Joint_static_ANIMATE_ROTATE_TRANSLATE(lua_State* state)
  5387. {
  5388. // Validate the number of parameters.
  5389. if (lua_gettop(state) > 0)
  5390. {
  5391. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5392. lua_error(state);
  5393. }
  5394. int result = Joint::ANIMATE_ROTATE_TRANSLATE;
  5395. // Push the return value onto the stack.
  5396. lua_pushinteger(state, result);
  5397. return 1;
  5398. }
  5399. int lua_Joint_static_ANIMATE_SCALE(lua_State* state)
  5400. {
  5401. // Validate the number of parameters.
  5402. if (lua_gettop(state) > 0)
  5403. {
  5404. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5405. lua_error(state);
  5406. }
  5407. int result = Joint::ANIMATE_SCALE;
  5408. // Push the return value onto the stack.
  5409. lua_pushinteger(state, result);
  5410. return 1;
  5411. }
  5412. int lua_Joint_static_ANIMATE_SCALE_ROTATE(lua_State* state)
  5413. {
  5414. // Validate the number of parameters.
  5415. if (lua_gettop(state) > 0)
  5416. {
  5417. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5418. lua_error(state);
  5419. }
  5420. int result = Joint::ANIMATE_SCALE_ROTATE;
  5421. // Push the return value onto the stack.
  5422. lua_pushinteger(state, result);
  5423. return 1;
  5424. }
  5425. int lua_Joint_static_ANIMATE_SCALE_ROTATE_TRANSLATE(lua_State* state)
  5426. {
  5427. // Validate the number of parameters.
  5428. if (lua_gettop(state) > 0)
  5429. {
  5430. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5431. lua_error(state);
  5432. }
  5433. int result = Joint::ANIMATE_SCALE_ROTATE_TRANSLATE;
  5434. // Push the return value onto the stack.
  5435. lua_pushinteger(state, result);
  5436. return 1;
  5437. }
  5438. int lua_Joint_static_ANIMATE_SCALE_TRANSLATE(lua_State* state)
  5439. {
  5440. // Validate the number of parameters.
  5441. if (lua_gettop(state) > 0)
  5442. {
  5443. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5444. lua_error(state);
  5445. }
  5446. int result = Joint::ANIMATE_SCALE_TRANSLATE;
  5447. // Push the return value onto the stack.
  5448. lua_pushinteger(state, result);
  5449. return 1;
  5450. }
  5451. int lua_Joint_static_ANIMATE_SCALE_UNIT(lua_State* state)
  5452. {
  5453. // Validate the number of parameters.
  5454. if (lua_gettop(state) > 0)
  5455. {
  5456. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5457. lua_error(state);
  5458. }
  5459. int result = Joint::ANIMATE_SCALE_UNIT;
  5460. // Push the return value onto the stack.
  5461. lua_pushinteger(state, result);
  5462. return 1;
  5463. }
  5464. int lua_Joint_static_ANIMATE_SCALE_X(lua_State* state)
  5465. {
  5466. // Validate the number of parameters.
  5467. if (lua_gettop(state) > 0)
  5468. {
  5469. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5470. lua_error(state);
  5471. }
  5472. int result = Joint::ANIMATE_SCALE_X;
  5473. // Push the return value onto the stack.
  5474. lua_pushinteger(state, result);
  5475. return 1;
  5476. }
  5477. int lua_Joint_static_ANIMATE_SCALE_Y(lua_State* state)
  5478. {
  5479. // Validate the number of parameters.
  5480. if (lua_gettop(state) > 0)
  5481. {
  5482. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5483. lua_error(state);
  5484. }
  5485. int result = Joint::ANIMATE_SCALE_Y;
  5486. // Push the return value onto the stack.
  5487. lua_pushinteger(state, result);
  5488. return 1;
  5489. }
  5490. int lua_Joint_static_ANIMATE_SCALE_Z(lua_State* state)
  5491. {
  5492. // Validate the number of parameters.
  5493. if (lua_gettop(state) > 0)
  5494. {
  5495. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5496. lua_error(state);
  5497. }
  5498. int result = Joint::ANIMATE_SCALE_Z;
  5499. // Push the return value onto the stack.
  5500. lua_pushinteger(state, result);
  5501. return 1;
  5502. }
  5503. int lua_Joint_static_ANIMATE_TRANSLATE(lua_State* state)
  5504. {
  5505. // Validate the number of parameters.
  5506. if (lua_gettop(state) > 0)
  5507. {
  5508. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5509. lua_error(state);
  5510. }
  5511. int result = Joint::ANIMATE_TRANSLATE;
  5512. // Push the return value onto the stack.
  5513. lua_pushinteger(state, result);
  5514. return 1;
  5515. }
  5516. int lua_Joint_static_ANIMATE_TRANSLATE_X(lua_State* state)
  5517. {
  5518. // Validate the number of parameters.
  5519. if (lua_gettop(state) > 0)
  5520. {
  5521. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5522. lua_error(state);
  5523. }
  5524. int result = Joint::ANIMATE_TRANSLATE_X;
  5525. // Push the return value onto the stack.
  5526. lua_pushinteger(state, result);
  5527. return 1;
  5528. }
  5529. int lua_Joint_static_ANIMATE_TRANSLATE_Y(lua_State* state)
  5530. {
  5531. // Validate the number of parameters.
  5532. if (lua_gettop(state) > 0)
  5533. {
  5534. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5535. lua_error(state);
  5536. }
  5537. int result = Joint::ANIMATE_TRANSLATE_Y;
  5538. // Push the return value onto the stack.
  5539. lua_pushinteger(state, result);
  5540. return 1;
  5541. }
  5542. int lua_Joint_static_ANIMATE_TRANSLATE_Z(lua_State* state)
  5543. {
  5544. // Validate the number of parameters.
  5545. if (lua_gettop(state) > 0)
  5546. {
  5547. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5548. lua_error(state);
  5549. }
  5550. int result = Joint::ANIMATE_TRANSLATE_Z;
  5551. // Push the return value onto the stack.
  5552. lua_pushinteger(state, result);
  5553. return 1;
  5554. }
  5555. int lua_Joint_static_isTransformChangedSuspended(lua_State* state)
  5556. {
  5557. // Get the number of parameters.
  5558. int paramCount = lua_gettop(state);
  5559. // Attempt to match the parameters to a valid binding.
  5560. switch (paramCount)
  5561. {
  5562. case 0:
  5563. {
  5564. bool result = Joint::isTransformChangedSuspended();
  5565. // Push the return value onto the stack.
  5566. lua_pushboolean(state, result);
  5567. return 1;
  5568. break;
  5569. }
  5570. default:
  5571. {
  5572. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5573. lua_error(state);
  5574. break;
  5575. }
  5576. }
  5577. return 0;
  5578. }
  5579. int lua_Joint_static_resumeTransformChanged(lua_State* state)
  5580. {
  5581. // Get the number of parameters.
  5582. int paramCount = lua_gettop(state);
  5583. // Attempt to match the parameters to a valid binding.
  5584. switch (paramCount)
  5585. {
  5586. case 0:
  5587. {
  5588. Joint::resumeTransformChanged();
  5589. return 0;
  5590. break;
  5591. }
  5592. default:
  5593. {
  5594. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5595. lua_error(state);
  5596. break;
  5597. }
  5598. }
  5599. return 0;
  5600. }
  5601. int lua_Joint_static_suspendTransformChanged(lua_State* state)
  5602. {
  5603. // Get the number of parameters.
  5604. int paramCount = lua_gettop(state);
  5605. // Attempt to match the parameters to a valid binding.
  5606. switch (paramCount)
  5607. {
  5608. case 0:
  5609. {
  5610. Joint::suspendTransformChanged();
  5611. return 0;
  5612. break;
  5613. }
  5614. default:
  5615. {
  5616. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  5617. lua_error(state);
  5618. break;
  5619. }
  5620. }
  5621. return 0;
  5622. }
  5623. int lua_Joint_transformPoint(lua_State* state)
  5624. {
  5625. // Get the number of parameters.
  5626. int paramCount = lua_gettop(state);
  5627. // Attempt to match the parameters to a valid binding.
  5628. switch (paramCount)
  5629. {
  5630. case 2:
  5631. {
  5632. do
  5633. {
  5634. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5635. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  5636. {
  5637. // Get parameter 1 off the stack.
  5638. bool param1Valid;
  5639. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  5640. if (!param1Valid)
  5641. break;
  5642. Joint* instance = getInstance(state);
  5643. instance->transformPoint(param1);
  5644. return 0;
  5645. }
  5646. } while (0);
  5647. lua_pushstring(state, "lua_Joint_transformPoint - Failed to match the given parameters to a valid function signature.");
  5648. lua_error(state);
  5649. break;
  5650. }
  5651. case 3:
  5652. {
  5653. do
  5654. {
  5655. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5656. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  5657. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  5658. {
  5659. // Get parameter 1 off the stack.
  5660. bool param1Valid;
  5661. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  5662. if (!param1Valid)
  5663. break;
  5664. // Get parameter 2 off the stack.
  5665. bool param2Valid;
  5666. gameplay::ScriptUtil::LuaArray<Vector3> param2 = gameplay::ScriptUtil::getObjectPointer<Vector3>(3, "Vector3", false, &param2Valid);
  5667. if (!param2Valid)
  5668. break;
  5669. Joint* instance = getInstance(state);
  5670. instance->transformPoint(*param1, param2);
  5671. return 0;
  5672. }
  5673. } while (0);
  5674. lua_pushstring(state, "lua_Joint_transformPoint - Failed to match the given parameters to a valid function signature.");
  5675. lua_error(state);
  5676. break;
  5677. }
  5678. default:
  5679. {
  5680. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  5681. lua_error(state);
  5682. break;
  5683. }
  5684. }
  5685. return 0;
  5686. }
  5687. int lua_Joint_transformVector(lua_State* state)
  5688. {
  5689. // Get the number of parameters.
  5690. int paramCount = lua_gettop(state);
  5691. // Attempt to match the parameters to a valid binding.
  5692. switch (paramCount)
  5693. {
  5694. case 2:
  5695. {
  5696. do
  5697. {
  5698. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5699. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  5700. {
  5701. // Get parameter 1 off the stack.
  5702. bool param1Valid;
  5703. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", false, &param1Valid);
  5704. if (!param1Valid)
  5705. break;
  5706. Joint* instance = getInstance(state);
  5707. instance->transformVector(param1);
  5708. return 0;
  5709. }
  5710. } while (0);
  5711. lua_pushstring(state, "lua_Joint_transformVector - Failed to match the given parameters to a valid function signature.");
  5712. lua_error(state);
  5713. break;
  5714. }
  5715. case 3:
  5716. {
  5717. do
  5718. {
  5719. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5720. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  5721. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  5722. {
  5723. // Get parameter 1 off the stack.
  5724. bool param1Valid;
  5725. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  5726. if (!param1Valid)
  5727. break;
  5728. // Get parameter 2 off the stack.
  5729. bool param2Valid;
  5730. gameplay::ScriptUtil::LuaArray<Vector3> param2 = gameplay::ScriptUtil::getObjectPointer<Vector3>(3, "Vector3", false, &param2Valid);
  5731. if (!param2Valid)
  5732. break;
  5733. Joint* instance = getInstance(state);
  5734. instance->transformVector(*param1, param2);
  5735. return 0;
  5736. }
  5737. } while (0);
  5738. lua_pushstring(state, "lua_Joint_transformVector - Failed to match the given parameters to a valid function signature.");
  5739. lua_error(state);
  5740. break;
  5741. }
  5742. case 6:
  5743. {
  5744. do
  5745. {
  5746. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5747. lua_type(state, 2) == LUA_TNUMBER &&
  5748. lua_type(state, 3) == LUA_TNUMBER &&
  5749. lua_type(state, 4) == LUA_TNUMBER &&
  5750. lua_type(state, 5) == LUA_TNUMBER &&
  5751. (lua_type(state, 6) == LUA_TUSERDATA || lua_type(state, 6) == LUA_TTABLE || lua_type(state, 6) == LUA_TNIL))
  5752. {
  5753. // Get parameter 1 off the stack.
  5754. float param1 = (float)luaL_checknumber(state, 2);
  5755. // Get parameter 2 off the stack.
  5756. float param2 = (float)luaL_checknumber(state, 3);
  5757. // Get parameter 3 off the stack.
  5758. float param3 = (float)luaL_checknumber(state, 4);
  5759. // Get parameter 4 off the stack.
  5760. float param4 = (float)luaL_checknumber(state, 5);
  5761. // Get parameter 5 off the stack.
  5762. bool param5Valid;
  5763. gameplay::ScriptUtil::LuaArray<Vector3> param5 = gameplay::ScriptUtil::getObjectPointer<Vector3>(6, "Vector3", false, &param5Valid);
  5764. if (!param5Valid)
  5765. break;
  5766. Joint* instance = getInstance(state);
  5767. instance->transformVector(param1, param2, param3, param4, param5);
  5768. return 0;
  5769. }
  5770. } while (0);
  5771. lua_pushstring(state, "lua_Joint_transformVector - Failed to match the given parameters to a valid function signature.");
  5772. lua_error(state);
  5773. break;
  5774. }
  5775. default:
  5776. {
  5777. lua_pushstring(state, "Invalid number of parameters (expected 2, 3 or 6).");
  5778. lua_error(state);
  5779. break;
  5780. }
  5781. }
  5782. return 0;
  5783. }
  5784. int lua_Joint_translate(lua_State* state)
  5785. {
  5786. // Get the number of parameters.
  5787. int paramCount = lua_gettop(state);
  5788. // Attempt to match the parameters to a valid binding.
  5789. switch (paramCount)
  5790. {
  5791. case 2:
  5792. {
  5793. do
  5794. {
  5795. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5796. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  5797. {
  5798. // Get parameter 1 off the stack.
  5799. bool param1Valid;
  5800. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  5801. if (!param1Valid)
  5802. break;
  5803. Joint* instance = getInstance(state);
  5804. instance->translate(*param1);
  5805. return 0;
  5806. }
  5807. } while (0);
  5808. lua_pushstring(state, "lua_Joint_translate - Failed to match the given parameters to a valid function signature.");
  5809. lua_error(state);
  5810. break;
  5811. }
  5812. case 4:
  5813. {
  5814. do
  5815. {
  5816. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5817. lua_type(state, 2) == LUA_TNUMBER &&
  5818. lua_type(state, 3) == LUA_TNUMBER &&
  5819. lua_type(state, 4) == LUA_TNUMBER)
  5820. {
  5821. // Get parameter 1 off the stack.
  5822. float param1 = (float)luaL_checknumber(state, 2);
  5823. // Get parameter 2 off the stack.
  5824. float param2 = (float)luaL_checknumber(state, 3);
  5825. // Get parameter 3 off the stack.
  5826. float param3 = (float)luaL_checknumber(state, 4);
  5827. Joint* instance = getInstance(state);
  5828. instance->translate(param1, param2, param3);
  5829. return 0;
  5830. }
  5831. } while (0);
  5832. lua_pushstring(state, "lua_Joint_translate - Failed to match the given parameters to a valid function signature.");
  5833. lua_error(state);
  5834. break;
  5835. }
  5836. default:
  5837. {
  5838. lua_pushstring(state, "Invalid number of parameters (expected 2 or 4).");
  5839. lua_error(state);
  5840. break;
  5841. }
  5842. }
  5843. return 0;
  5844. }
  5845. int lua_Joint_translateForward(lua_State* state)
  5846. {
  5847. // Get the number of parameters.
  5848. int paramCount = lua_gettop(state);
  5849. // Attempt to match the parameters to a valid binding.
  5850. switch (paramCount)
  5851. {
  5852. case 2:
  5853. {
  5854. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5855. lua_type(state, 2) == LUA_TNUMBER)
  5856. {
  5857. // Get parameter 1 off the stack.
  5858. float param1 = (float)luaL_checknumber(state, 2);
  5859. Joint* instance = getInstance(state);
  5860. instance->translateForward(param1);
  5861. return 0;
  5862. }
  5863. lua_pushstring(state, "lua_Joint_translateForward - Failed to match the given parameters to a valid function signature.");
  5864. lua_error(state);
  5865. break;
  5866. }
  5867. default:
  5868. {
  5869. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5870. lua_error(state);
  5871. break;
  5872. }
  5873. }
  5874. return 0;
  5875. }
  5876. int lua_Joint_translateLeft(lua_State* state)
  5877. {
  5878. // Get the number of parameters.
  5879. int paramCount = lua_gettop(state);
  5880. // Attempt to match the parameters to a valid binding.
  5881. switch (paramCount)
  5882. {
  5883. case 2:
  5884. {
  5885. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5886. lua_type(state, 2) == LUA_TNUMBER)
  5887. {
  5888. // Get parameter 1 off the stack.
  5889. float param1 = (float)luaL_checknumber(state, 2);
  5890. Joint* instance = getInstance(state);
  5891. instance->translateLeft(param1);
  5892. return 0;
  5893. }
  5894. lua_pushstring(state, "lua_Joint_translateLeft - Failed to match the given parameters to a valid function signature.");
  5895. lua_error(state);
  5896. break;
  5897. }
  5898. default:
  5899. {
  5900. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5901. lua_error(state);
  5902. break;
  5903. }
  5904. }
  5905. return 0;
  5906. }
  5907. int lua_Joint_translateSmooth(lua_State* state)
  5908. {
  5909. // Get the number of parameters.
  5910. int paramCount = lua_gettop(state);
  5911. // Attempt to match the parameters to a valid binding.
  5912. switch (paramCount)
  5913. {
  5914. case 4:
  5915. {
  5916. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5917. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  5918. lua_type(state, 3) == LUA_TNUMBER &&
  5919. lua_type(state, 4) == LUA_TNUMBER)
  5920. {
  5921. // Get parameter 1 off the stack.
  5922. bool param1Valid;
  5923. gameplay::ScriptUtil::LuaArray<Vector3> param1 = gameplay::ScriptUtil::getObjectPointer<Vector3>(2, "Vector3", true, &param1Valid);
  5924. if (!param1Valid)
  5925. {
  5926. lua_pushstring(state, "Failed to convert parameter 1 to type 'Vector3'.");
  5927. lua_error(state);
  5928. }
  5929. // Get parameter 2 off the stack.
  5930. float param2 = (float)luaL_checknumber(state, 3);
  5931. // Get parameter 3 off the stack.
  5932. float param3 = (float)luaL_checknumber(state, 4);
  5933. Joint* instance = getInstance(state);
  5934. instance->translateSmooth(*param1, param2, param3);
  5935. return 0;
  5936. }
  5937. lua_pushstring(state, "lua_Joint_translateSmooth - Failed to match the given parameters to a valid function signature.");
  5938. lua_error(state);
  5939. break;
  5940. }
  5941. default:
  5942. {
  5943. lua_pushstring(state, "Invalid number of parameters (expected 4).");
  5944. lua_error(state);
  5945. break;
  5946. }
  5947. }
  5948. return 0;
  5949. }
  5950. int lua_Joint_translateUp(lua_State* state)
  5951. {
  5952. // Get the number of parameters.
  5953. int paramCount = lua_gettop(state);
  5954. // Attempt to match the parameters to a valid binding.
  5955. switch (paramCount)
  5956. {
  5957. case 2:
  5958. {
  5959. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5960. lua_type(state, 2) == LUA_TNUMBER)
  5961. {
  5962. // Get parameter 1 off the stack.
  5963. float param1 = (float)luaL_checknumber(state, 2);
  5964. Joint* instance = getInstance(state);
  5965. instance->translateUp(param1);
  5966. return 0;
  5967. }
  5968. lua_pushstring(state, "lua_Joint_translateUp - Failed to match the given parameters to a valid function signature.");
  5969. lua_error(state);
  5970. break;
  5971. }
  5972. default:
  5973. {
  5974. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  5975. lua_error(state);
  5976. break;
  5977. }
  5978. }
  5979. return 0;
  5980. }
  5981. int lua_Joint_translateX(lua_State* state)
  5982. {
  5983. // Get the number of parameters.
  5984. int paramCount = lua_gettop(state);
  5985. // Attempt to match the parameters to a valid binding.
  5986. switch (paramCount)
  5987. {
  5988. case 2:
  5989. {
  5990. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  5991. lua_type(state, 2) == LUA_TNUMBER)
  5992. {
  5993. // Get parameter 1 off the stack.
  5994. float param1 = (float)luaL_checknumber(state, 2);
  5995. Joint* instance = getInstance(state);
  5996. instance->translateX(param1);
  5997. return 0;
  5998. }
  5999. lua_pushstring(state, "lua_Joint_translateX - Failed to match the given parameters to a valid function signature.");
  6000. lua_error(state);
  6001. break;
  6002. }
  6003. default:
  6004. {
  6005. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  6006. lua_error(state);
  6007. break;
  6008. }
  6009. }
  6010. return 0;
  6011. }
  6012. int lua_Joint_translateY(lua_State* state)
  6013. {
  6014. // Get the number of parameters.
  6015. int paramCount = lua_gettop(state);
  6016. // Attempt to match the parameters to a valid binding.
  6017. switch (paramCount)
  6018. {
  6019. case 2:
  6020. {
  6021. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  6022. lua_type(state, 2) == LUA_TNUMBER)
  6023. {
  6024. // Get parameter 1 off the stack.
  6025. float param1 = (float)luaL_checknumber(state, 2);
  6026. Joint* instance = getInstance(state);
  6027. instance->translateY(param1);
  6028. return 0;
  6029. }
  6030. lua_pushstring(state, "lua_Joint_translateY - Failed to match the given parameters to a valid function signature.");
  6031. lua_error(state);
  6032. break;
  6033. }
  6034. default:
  6035. {
  6036. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  6037. lua_error(state);
  6038. break;
  6039. }
  6040. }
  6041. return 0;
  6042. }
  6043. int lua_Joint_translateZ(lua_State* state)
  6044. {
  6045. // Get the number of parameters.
  6046. int paramCount = lua_gettop(state);
  6047. // Attempt to match the parameters to a valid binding.
  6048. switch (paramCount)
  6049. {
  6050. case 2:
  6051. {
  6052. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  6053. lua_type(state, 2) == LUA_TNUMBER)
  6054. {
  6055. // Get parameter 1 off the stack.
  6056. float param1 = (float)luaL_checknumber(state, 2);
  6057. Joint* instance = getInstance(state);
  6058. instance->translateZ(param1);
  6059. return 0;
  6060. }
  6061. lua_pushstring(state, "lua_Joint_translateZ - Failed to match the given parameters to a valid function signature.");
  6062. lua_error(state);
  6063. break;
  6064. }
  6065. default:
  6066. {
  6067. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  6068. lua_error(state);
  6069. break;
  6070. }
  6071. }
  6072. return 0;
  6073. }
  6074. }