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

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

51. CPU优化方式(JavaScript-2D进阶篇(JS)-性能优化) [ 82%]

...可以使用局部变量来保存它: ```javascript function foo() { var prop = target.prop; // 使用prop process1(prop); process2(prop); process3(prop); } ``` ### 二、计时器 LayaAir提供两种计时器循环来执行代码块。 1. `Laya.timer.frameLoop`执行频率依赖于帧频率,可...

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

52. laya.utils.ClassUtils [ 82%]

...ationAll Packages | All Classes | Index | Frames No Frames ClassUtilsProperties | Methods Packagelaya.utilsClasspublic class ClassUtilsInheritanceClassUtils Object ClassUtils 是一个类工具类。 Public Properties PropertyDefined By  _classMap : Object[static] ClassUtils  getClass :...

来源: laya_api 发布时间: 20170929

53. CPU优化方式(TypeScript-2D进阶篇(TS)-性能优化) [ 81%]

...性值,可以使用局部变量来保存它: ```typescript foo() { var prop=this.target.prop; //使用prop this.process1(prop); this.process2(prop); this.process3(prop); } ``` ### 二、计时器 LayaAir提供两种计时器循环来执行代码块。 1. `Laya.timer.frameLoop`执行频率依赖...

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

54. runtime运行报错! [ 81%]

...如下:  View.getCompInstance=function(json){       var runtime=json.props ? json.props.runtime :"";       var compClass=runtime ? (View.viewClassMap[runtime] || Laya["__classmap"][runtime]):View.uiClassMap[json.type];      return compClass ? new compClass():null;  } 这第2句代码貌...

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

55. 获取lh动画控制失败【已解决】 [ 80%]

...     zombieAnimator.stop();   错误提示:TypeError: Cannot read property 'getComponentByType' of undefined 看例程关于层级的不是很详细,自己也不是很理解这个关系,麻烦给看下是什么问题呢,谢谢。 以是LH文件内容: {     "type":"Sprite3D",   ...

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

56. 自定义组件如何实现图片资源拖动获取路径 [ 79%]

...x" groups="公用,常用,宽高及位置,旋转及缩放" drag="3"> <prop name="x" tips="X轴坐标" type="number" default="" group="宽高及位置" /> <prop name="y" tips="Y轴坐标" type="number" default="" group="宽高及位置" /> <prop name="name" tips="组件名称" type="...

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

57. 关于HttpRequest [ 78%]

...tils.urlEncode(param[i], k, encode); } } // var paramStr = ""; // for (var prop in param) { // paramStr += prop + "=" + param[prop] + "&"; // } // paramStr = paramStr.substring(0, paramStr.length - 1); return paramStr; }; var obj: Object = { name: "stone", list: [1, 2, 3], items: [ { id: 1, coun...

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

58. 请问一下怎样动态加载prefab [ 78%]

...,结局依然是undefined。 laya.components.Script 里面定义了 /** @prop {name:poker,tips:"prefab",type:Prefab}*/ private mPokerObj: laya.components.Prefab 然后再编辑模式里面手动拖拽事先编辑好的prefab 然后再代码中 laya.utils.Pool.getItemByCreateFun("poker", this.mPoke...

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

59. 构建好android studio项目后,debug出错 [ 77%]

... function, class) not yet supported outside strict mode let runtime = json.props.runtime; ^^^ SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode at eval (native) at Document._downloadOk (apploader.js:6059:20) at apploader.js:6038:20 at FileRead...

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

60. 为什么创建的脚本 变量在编辑模式赋值后 运行时为undfined [ 76%]

...载操作吗? 我所见对于预制体的操作只有这些啊: /** @prop {name:dropBox,tips:"掉落容器预制体对象",type:Prefab}*/ dropBox: Laya.Prefab; 其他还有哪做了加载? 一位不愿意透露姓名的无头像者 • 2018-10-25 15:13 @Laya_Aaron:我要使用脚本...

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