1import{Da as s,Db as L,Fb as u,Ib as f,Kb as M,Lb as x,Mb as C,Nb as o,Oa as k,Ob as i,Pb as V,Tb as P,Vb as b,Wb as p,ba as E,cc as j,db as n,dc as z,fc as r,gc as h,hc as m,hd as B,kb as T,ma as d,na as g,pb as F,ta as w,uc as I,vb as v,vc as A}from"./chunk-5SAOKRHL.js";import{g as y}from"./chunk-NZN5XTIE.js";var $=["lienzo"],R=(t,c)=>c.archivo,D=(t,c)=>c.key;function H(t,c){if(t&1){let e=P();o(0,"button",10),b("click",function(){d(e);let a=p().$implicit,_=p(2);return g(_.elige(a.archivo))}),r(1),i()}if(t&2){let e=p().$implicit,l=p(2);u("is-on",l.pieza()===e.archivo),n(),m(" ",e.nombre," ")}}function Y(t,c){if(t&1&&v(0,H,2,3,"button",9),t&2){let e=c.$implicit,l=p().$implicit;f(e.grupo===l?0:-1)}}function N(t,c){if(t&1&&(o(0,"p",8),r(1),i(),x(2,Y,1,1,null,null,R)),t&2){let e=c.$implicit,l=p();n(),h(e),n(),C(l.catalogo)}}function J(t,c){if(t&1&&(o(0,"section")(1,"p",11),r(2),i()()),t&2){let e=p();n(2),h(e.error())}}function q(t,c){if(t&1){let e=P();o(0,"button",10),b("click",function(){let a=d(e).$implicit,_=p(2);return g(_.reproduce(a))}),r(1),i()}if(t&2){let e=c.$implicit,l=p(2);u("is-on",l.clip()===e),n(),h(e)}}function G(t,c){if(t&1){let e=P();o(0,"section")(1,"h2"),r(2),i(),o(3,"div",12),x(4,q,2,3,"button",9,M),i(),o(6,"label",13),r(7),o(8,"input",14),b("input",function(a){d(e);let _=p();return g(_.setVelocidad(+a.target.value))}),i()()()}if(t&2){let e=p();n(2),m("Animaciones (",e.clips().length,")"),n(2),C(e.clips()),n(3),m(" Velocidad \xB7 ",e.velocidad(),"\xD7 "),n(),L("value",e.velocidad())}}function Q(t,c){if(t&1&&(o(0,"dt"),r(1),i(),o(2,"dd"),r(3),i()),t&2){let e=c.$implicit;n(),h(e.key),n(2),h(e.value)}}function U(t,c){if(t&1&&(o(0,"section")(1,"h2"),r(2,"Ficha"),i(),o(3,"dl",15),x(4,Q,4,2,null,null,D),I(6,"keyvalue"),i()()),t&2){let e=p();n(4),C(A(6,0,e.info()))}}function K(t,c){if(t&1&&(o(0,"code"),r(1),i()),t&2){let e=c.$implicit;u("is-mano",e.includes("Hand")&&!e.includes("Thumb")&&!e.includes("Index")),n(),h(e)}}function W(t,c){if(t&1&&(o(0,"section")(1,"h2"),r(2),i(),o(3,"p",5),r(4," Los nombres importan: el arma se emparenta al hueso de la mano y se ajusta con un offset, as\xED sigue a la mano sola. "),i(),o(5,"div",16),x(6,K,2,3,"code",17,M),i()()),t&2){let e=p();n(2),m("Huesos (",e.huesos().length,")"),n(4),C(e.huesos())}}function X(t,c){t&1&&(o(0,"p",7),r(1,"CARGANDO\u2026"),i())}var S=[{grupo:"Del juego",nombre:"Recogibles (c\xF3digo)",archivo:""},{grupo:"H\xE9roe",nombre:"H\xE9roe (reparado)",archivo:"heroe-reparado.glb"},{grupo:"H\xE9roe",nombre:"H\xE9roe (sin reparar)",archivo:"heroe-con-animaciones2.glb"},{grupo:"H\xE9roe",nombre:"H\xE9roe (6 clips)",archivo:"heroe-con-animaciones.glb"},{grupo:"Armas",nombre:"Pistola",archivo:"pistola.glb"},{grupo:"Armas",nombre:"Escopeta",archivo:"escopeta.glb"},{grupo:"Armas",nombre:"Fusil",archivo:"fusil.glb"},{grupo:"Armas",nombre:"Aspiradora",archivo:"aspiradora.glb"},{grupo:"Armas",nombre:"Todas juntas",archivo:"armas.glb"},{grupo:"Recogibles",nombre:"Coraz\xF3n",archivo:"corazon.glb"},{grupo:"Recogibles",nombre:"Caja escopeta",archivo:"caja-escopeta.glb"},{grupo:"Recogibles",nombre:"Caja fusil",archivo:"caja-fusil.glb"},{grupo:"Recogibles",nombre:"Todos juntos",archivo:"objetos.glb"},{grupo:"Enemigos",nombre:"Tornado",archivo:"tornado.glb"},{grupo:"Enemigos",nombre:"Tornado jefe",archivo:"tornado-jefe.glb"}],oe=(()=>{class t{constructor(){this.catalogo=S,this.grupos=[...new Set(S.map(e=>e.grupo))],this.cargando=s(!0),this.error=s(""),this.pieza=s(S[0].archivo),this.clips=s([]),this.clip=s(""),this.huesos=s([]),this.info=s({}),this.velocidad=s(1),this.filtroPS1=s(!0),this.tinte=s(!0),this.camaraJuego=s(!0),this.rejilla=s(!0),this.volteoY=s(!0),this.lienzo=T.required("lienzo"),this.destroyRef=E(w),this.motor=null,k(()=>void this.arranca())}elige(e){return y(this,null,function*(){this.pieza.set(e),yield this.carga()})}reproduce(e){this.clip.set(e),this.motor?.reproduce(e)}cambia(e){this[e].update(l=>!l),this.aplicaOpciones()}setVelocidad(e){this.velocidad.set(e),this.motor?.setVelocidad(e)}arranca(){return y(this,null,function*(){try{let{LabEscena:e}=yield import("./chunk-7HKYINJJ.js");this.motor=new e(this.lienzo().nativeElement),this.destroyRef.onDestroy(()=>this.motor?.dispose()),this.aplicaOpciones(),yield this.carga()}catch(e){this.error.set(e instanceof Error?e.message:String(e)),this.cargando.set(!1)}})}carga(){return y(this,null,function*(){if(this.motor){this.cargando.set(!0),this.error.set("");try{let e=this.pieza(),l=e?yield this.motor.carga(`/gamestudio/glb/${e}`):this.motor.procedural();this.clips.set(l.clips),this.huesos.set(l.huesos),this.info.set(l.info),this.clip.set(l.clips[0]??"")}catch(e){this.error.set(e instanceof Error?e.message:String(e))}finally{this.cargando.set(!1)}}})}aplicaOpciones(){this.motor?.opciones({camaraJuego:this.camaraJuego(),filtroPS1:this.filtroPS1(),rejilla:this.rejilla(),tinte:this.tinte(),volteoY:this.volteoY()})}static{this.\u0275fac=function(l){return new(l||t)}}static{this.\u0275cmp=F({type:t,selectors:[["wbt-lab"]],viewQuery:function(l,a){l&1&&j(a.lienzo,$,5),l&2&&z()},decls:38,vars:20,consts:[["lienzo",""],[1,"lab"],[1,"lab__panel"],[1,"lab__cab"],["type","button",1,"lab__toggle",3,"click"],[1,"lab__nota"],[1,"lab__vista"],[1,"lab__cargando"],[1,"lab__grupo"],["type","button",1,"lab__item",3,"is-on"],["type","button",1,"lab__item",3,"click"],[1,"lab__error"],[1,"lab__clips"],[1,"lab__rango"],["type","range","min","0.1","max","2","step","0.1",3,"input","value"],[1,"lab__ficha"],[1,"lab__huesos"],[3,"is-mano"]],template:function(l,a){if(l&1){let _=P();o(0,"div",1)(1,"aside",2)(2,"header",3)(3,"h1"),r(4,"BTG \xB7 LAB"),i(),o(5,"p"),r(6,"Herramienta de desarrollo. No se publica."),i()(),o(7,"section")(8,"h2"),r(9,"Modelo"),i(),x(10,N,4,1,null,null,M),i(),v(12,J,3,1,"section")(13,G,9,3,"section"),o(14,"section")(15,"h2"),r(16,"Vista"),i(),o(17,"button",4),b("click",function(){return d(_),g(a.cambia("c
1amaraJuego"))}),r(18),i(),o(19,"button",4),b("click",function(){return d(_),g(a.cambia("filtroPS1"))}),r(20),i(),o(21,"button",4),b("click",function(){return d(_),g(a.cambia("tinte"))}),r(22),i(),o(23,"button",4),b("click",function(){return d(_),g(a.cambia("volteoY"))}),r(24),i(),o(25,"button",4),b("click",function(){return d(_),g(a.cambia("rejilla"))}),r(26),i(),o(27,"p",5),r(28," El mundo del juego tiene la "),o(29,"strong"),r(30,"Y hacia abajo"),i(),r(31,". Un modelo exportado de Blender entra del rev\xE9s y hay que compensarlo \u2014 apaga ese interruptor para ver c\xF3mo viene el fichero de origen. "),i()(),v(32,U,7,2,"section")(33,W,8,1,"section"),i(),o(34,"main",6),v(35,X,2,0,"p",7),V(36,"canvas",null,0),i()()}l&2&&(n(10),C(a.grupos),n(2),f(a.error()?12:-1),n(),f(a.clips().length?13:-1),n(4),u("is-on",a.camaraJuego()),n(),m(" ",a.camaraJuego()?"C\xE1mara del juego":"C\xE1mara libre (orbita)"," "),n(),u("is-on",a.filtroPS1()),n(),m(" Filtro PS1 \xB7 ",a.filtroPS1()?"ON":"OFF"," "),n(),u("is-on",a.tinte()),n(),m(" Te\xF1ido a la rampa \xB7 ",a.tinte()?"ON":"OFF"," "),n(),u("is-on",a.volteoY()),n(),m(" Compensar Y-abajo \xB7 ",a.volteoY()?"ON":"OFF"," "),n(),u("is-on",a.rejilla()),n(),m(" Rejilla del suelo \xB7 ",a.rejilla()?"ON":"OFF"," "),n(6),f(a.info().tri\u00E1ngulos?32:-1),n(),f(a.huesos().length?33:-1),n(2),f(a.cargando()?35:-1))},dependencies:[B],styles:['@charset "UTF-8";.lab[_ngcontent-%COMP%]{position:fixed;inset:0;display:grid;grid-template-columns:320px 1fr;background:#050a10;color:#d6ffe8c7;font-family:ui-monospace,Menlo,monospace;font-size:12px}@media (max-width: 720px){.lab[_ngcontent-%COMP%]{grid-template-columns:1fr;grid-template-rows:45vh 1fr}}.lab__panel[_ngcontent-%COMP%]{overflow-y:auto;padding:16px;background:#070f17;border-right:3px solid #1d793c}.lab__panel[_ngcontent-%COMP%] section[_ngcontent-%COMP%]{margin-bottom:22px}.lab__panel[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0 0 10px;font-family:"Press Start 2P",monospace;font-size:9px;color:#35ff7a}.lab__cab[_ngcontent-%COMP%]{margin-bottom:22px;padding-bottom:14px;border-bottom:2px solid #1d793c}.lab__cab[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{margin:0 0 6px;font-family:"Press Start 2P",monospace;font-size:13px;color:#fff}.lab__cab[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;font-size:11px;color:#d6ffe880}.lab__grupo[_ngcontent-%COMP%]{margin:12px 0 6px;font-size:10px;letter-spacing:.08em;color:#d6ffe873;text-transform:uppercase}.lab__item[_ngcontent-%COMP%], .lab__toggle[_ngcontent-%COMP%]{display:block;width:100%;margin-bottom:4px;padding:8px 10px;font-family:inherit;font-size:12px;text-align:left;color:#e5fff2;background:#050a10;border:2px solid #1d793c;cursor:pointer}.lab__item[_ngcontent-%COMP%]:hover, .lab__toggle[_ngcontent-%COMP%]:hover{border-color:#35ff7a;color:#35ff7a}.lab__item.is-on[_ngcontent-%COMP%], .lab__toggle.is-on[_ngcontent-%COMP%]{color:#050a10;background:#35ff7a;border-color:#35ff7a}.lab__clips[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:4px}.lab__clips[_ngcontent-%COMP%] .lab__item[_ngcontent-%COMP%]{margin:0;font-size:11px}.lab__rango[_ngcontent-%COMP%]{display:block;margin-top:12px;font-size:11px}.lab__rango[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{display:block;width:100%;margin-top:6px;accent-color:#35ff7a}.lab__nota[_ngcontent-%COMP%]{margin:10px 0 0;font-size:11px;line-height:1.6;color:#d6ffe880}.lab__nota[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:#35ff7a}.lab__error[_ngcontent-%COMP%]{padding:10px;color:#ffb4b4;background:#ff50501a;border:2px solid #a33}.lab__ficha[_ngcontent-%COMP%]{display:grid;grid-template-columns:auto 1fr;gap:4px 12px;margin:0}.lab__ficha[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{color:#d6ffe880}.lab__ficha[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;color:#35ff7a}.lab__huesos[_ngcontent-%COMP%]{display:grid;gap:2px;max-height:260px;overflow-y:auto}.lab__huesos[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{padding:3px 6px;font-size:11px;color:#d6ffe899;background:#050a10}.lab__huesos[_ngcontent-%COMP%] code.is-mano[_ngcontent-%COMP%]{color:#050a10;background:#35ff7a}.lab__vista[_ngcontent-%COMP%]{position:relative;min-width:0}.lab__vista[_ngcontent-%COMP%] canvas[_ngcontent-%COMP%]{display:block;width:100%;height:100%}.lab__cargando[_ngcontent-%COMP%]{position:absolute;top:50%;left:50%;margin:0;transform:translate(-50%,-50%);font-family:"Press Start 2P",monospace;font-size:10px;color:#35ff7a}'],changeDetection:0})}}return t})();export{oe as LabComponent};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.