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

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

661. matter中有没有类似于unity中的OnCollision碰撞检测函数呀,用js怎么写 [ 48%]

... console.log("碰撞了..");  var home = _gamePage._mainPage._playPage;  for(var i = 0; i < event.pairs.length; i++) {  var pair = event.pairs[i];  if(!(pair.bodyA.label === 'gun' || pair.bodyB.label == "gun")) continue;  var other;  if (pair.bodyA.label === 'gun') { other = pair.bodyB; } e...

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

662. 3D场景里面怎么画线条 [ 48%]

...List.length);         this.mainScene.addChild(pl);         for (let i = 1; i < wayList.length; i++) {             pl.addLine(wayList[i - 1], wayList[i], Laya.Color.RED, Laya.Color.RED);         } 2019-11-19 0 2 分享 微博 QZONE 微信 为什么...

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

663. 如何把加载好的二进制数据转成Texture? [ 48%]

...会释放 res.bin = null; // createFrames? let len = imgInfoList.length; for (let i = 0; i < len; i++) { let image: ImageInfo = imgInfoList[i]; image.texture = Texture.create(res.texture, image.u, image.v, image.w, image.h, image.x, image.y); } res.state = Res.STATE_OK; }); } var blobType = { typ...

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

664. Texture如何转换成Texture2D有人搞过吗 [ 48%]

....split(":")[1] .split(";")[0]; var ia = new Uint8Array(byteString.length); for (var i = 0; i < byteString.length; i++) { ia[i] = byteString.charCodeAt(i); } return new Browser.window.Blob([ia], { type: mimeStringp }); };4.这时就有个新生成的URL,因为这个URL没有后缀,所以加载...

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

665. 用xml描述创建一个clip,interval字段妖孽无效 [ 48%]

...fig.xml");             xml = xml.firstChild;             for (var node:XML = xml.firstChild; node != null; node = node.nextSibling)             {                 var id:Number = node.getAttribute("id");                              ...

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

666. BlinnPhong材质详解(TypeScript-3D基础(TS)-模型材质详解) [ 48%]

...(0) as Laya.SkinnedMeshSprite3D; //历遍蒙皮网格节点的材质列表 for (var i:int = 0; i (图6)

来源: Laya2.0_文档 发布时间: 20210714

667. laya.d3.webxr.core.WebXRSessionManager_API3.0 [ 48%]

...de(): any Defined in laya/d3/WebXR/core/WebXRSessionManager.ts:69 The mode for the managed XR session Returns any supportedFrameRates get supportedFrameRates(): Float32Array | undefined Defined in laya/d3/WebXR/core/WebXRSessionManager.ts:239 A list of supported frame rates (only available in-sessio...

来源: Laya3.0_api 发布时间: 20231115

668. uglify压缩后的错误堆栈解析 [ 48%]

...tacktracey(errorStack); // 解析错误信息 const { readFileSync } = fs; for(const frame of tracey.items) {  // frame.fileName const sourceMapContent = JSON.parse(readFileSync(mapFilePath, 'utf8')); const consumer = await new sourceMap.SourceMapConsumer(sourceMapContent); // console.log(frame); /...

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

669. httpRequest send返回Request failed Status:0 [ 48%]

...unction () { function GameMain() { //初始化引擎 Laya.init(1136, 640); for (var i = 0; i < 4; i++) { var sp = new Laya.Sprite(); var xhr = new Laya.HttpRequest(); var url = "http://thirdqq.qlogo.cn/g%3Fb% ... 3B%3B xhr.once(Laya.Event.COMPLETE, this, this.completeHandler, [url, 1]); xhr.once(...

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

670. ReferenceError: Loading_fly is not defined [ 48%]

...age.width; this.diango.height = Laya.stage.height; var loading_array = []; for(var i = 1; i < 28; i++ ){ loading_array.push('loading/'+ i +'@2x.png',) } Laya.Animation.createFrames(loading_array, 'loading') this.fly = new Laya.Animation(); this.fly.play(0, true, 'loading') this.bounds = this.fly....

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