• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 603 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0046 秒)

181. 请问如何获取MeshSprite3D模型中的点和面信息. [ 70%]

...7:27 你好,我尝试理解了下不知道对不对,【因为positions.length%3!=0,那么如果要表示一个面的话,应该用 positions[0],positions[1],positions[2],第二个面的话是positions[1],positions[2],positions[3]】,直到结尾,面的个数应该是positions.length-2? ym...

来源: Laya_社区 发布时间: 20171020

182. 为什么字符串不能连接? [ 70%]

...; let str:String="#"; for(let i:number=0;i<6;i++){ let index:number=arr.length*Math.random(); str+=arr[index];//在IDE里面这句报错 [ts] Operator '+' cannot be applied to types 'String' and 'String'. } return str; }   2017-11-18 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有...

来源: Laya_社区 发布时间: 20171118

183. DOM元素-表单输入 [ 70%]

...; return input; } function fitDOMElements(){ for (var i = 0; i < arguments.length; i++) { var dom = arguments[i]; Laya.Utils.fitDOMElementInArea(dom, this.form, 100, i * (this.rowSpacing + this.rowHeight), 150, this.rowHeight); } }class DOM_Form{ private form:Laya.Sprite; private rowHeight:number = ...

来源: Laya_示例 发布时间: 20251209

184. Text.as中parseLines方法里的问题 [ 70%]

...text.replace(/\r\n/g, "\n").split("\n"); for (var i:int = 0, n:int = lines.length; i &lt; n; i++) { var line:String = lines[i]; // 开启了自动换行需要计算换行位置 // overflow为hidden需要计算截断位置 if (needWordWrapOrTruncate) parseLine(line, wordWrapWidth); else { _lineWidths...

来源: Laya_社区 发布时间: 20190213

185. VR的demo有没有加载3D场景的啊,实在不知怎么加 [ 70%]

...ull, function(sprite) { //console.log(scene.numChildren+","+sprite._childs.length); setMeshParams(sprite, Laya.StandardMaterial.RENDERMODE_OPAQUE, new Laya.Vector4(3.5, 3.5, 3.5, 1.0), new Laya.Vector3(0.6823, 0.6549, 0.6352), new Laya.Vector2(25.0, 25.0), "TERRAIN"); //setMeshParams(sprite, Laya.St...

来源: Laya_社区 发布时间: 20170707

186. 同时使用雾和粒子系统,粒子的颜色变成雾的颜色 [ 70%]

...#ifdef FOG   vec3 toEye=u_CameraPosition-v_PositionWorld;   float toEyeLength=length(toEye);   toEye/=toEyeLength;      float lerpFact=clamp((toEyeLength-u_FogStart)/u_FogRange,0.0,1.0);   #ifdef ADDTIVEFOG    gl_FragColor.rgb=mix(gl_FragColor.rgb,vec3(0.0,0.0,0.0),lerpFact);   #els...

来源: Laya_社区 发布时间: 20190802

187. laya的socket怎么跟flash的socket不一样 [ 70%]

...2-14 11:49 flash.utils.ByteArray.readBytes(bytes:ByteArray, offset:uint=0, length:uint=0):void 从字节流中读取 length 参数指定的数据字节数。从 offset 指定的位置开始,将字节读入 bytes 参数指定的 ByteArray 对象中,并将字节写入目标 ByteArray 中。 这个...

来源: Laya_社区 发布时间: 20161214

188. DOM元素-表单输入 [ 70%]

...ld(input); return input; } fitDOMElements(){ for (let i = 0; i < arguments.length; i++) { let dom = arguments[i]; Laya.Utils.fitDOMElementInArea(dom, this.form, 100, i * (this.rowSpacing + this.rowHeight), 150, this.rowHeight); } } } new DOM_Form();class DOM_Form{ private form:Laya.Sprite; private r...

来源: Laya2.0_示例 发布时间: 20251209

189. 引擎socket类_onMessage bug [ 70%]

...data);             return;         }         if (this._input.length &gt; 0 &amp;&amp; this._input.bytesAvailable &lt; 1) {             this._input.clear();             this._addInputPosition = 0;         }         var pre: number = this._input.pos;         !this...

来源: Laya_社区 发布时间: 20220822

190. sprite3D可以设置碰撞体吗 [ 70%]

...吧,然后我按照我网上的方法,报了一个Cannot set property 'length' of undefined的错,是说我rayCastAll方法获得射线物体的length找不到是为什么诶 Laya_Aaron • 2018-07-13 11:35 调试跟踪一下看看射线碰撞到的对象是什么,然后看这个对象属性...

来源: Laya_社区 发布时间: 20180712