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

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

1. Getcomponent 报错Uncaught (in promise) TypeError: Right-hand side of 'instanceof' is not an object [ 100%]

Getcomponent 报错Uncaught (in promise) TypeError: Right-hand side of 'instanceof' is not an object 有复现工程  附件 : --> Laya2DTest.zip 2023-07-03 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个回复 layabox...

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

2. 关于Sprite回收 [ 87%]

...            var item = this.getChildAt(i);             if(item instanceof Item) {                 item.removeSelf();                 item.visible = true;                 Pool.recover("item", item);                 item.graphics.clear();             }...

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

3. 字节平台(抖音预览调试),因为一行代码导致无法启动问题 [ 84%]

...;(instance: T): T { if (instance == null) { return instance } if (instance instanceof Date) { return new Date(instance.getTime()) as any } if (instance instanceof Array) { var cloneArr = [] as any[] ;(instance as any[]).forEach((value) => { cloneArr.push(value) }) return cloneArr.map((value: any)...

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

4. JS版派发自定义事件出错。 [ 82%]

...件,请查明根本原因并修复 if (listener) { if(!(listener.method instanceof Function)&& listener.caller instanceof Function){ listener.method = listener.caller; } (data != null) ? listener.runWith(data) : listener.run(); } 2017-01-20 添加评论 免费帖 --> 分享 微博 QZONE ...

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

5. 聚光灯实时阴影(JavaScript-3D基础(JS)-LayaAir3D之灯光) [ 82%]

...childLength;i++) { var childSprite = scene3d.getChildAt(i); if(childSprite instanceof MeshSprite3D) { //设置精灵接收阴影 childSprite.meshRenderer.receiveShadow = true; //设置精灵可投射阴影 childSprite.meshRenderer.castShadow = true; } else if(childSprite instanceof SpotLight) { //...

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

6. laya 2.6.0 加载image报错 [ 82%]

...源的时候,data为Texture2D类型,前两个判断没走,(data instanceof ArrayBuffer) 和 (!(data instanceof Texture2D))。导致tex为undefined,结果就无法继续加载了。。 LayaAir 2.6.0 的JS版本   ps: 加载的是FairyGui打包的图集,png格式,使用laya 2....

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

7. 聚光灯实时阴影(TypeScript-3D基础(TS)-LayaAir3D之灯光) [ 81%]

...Length;i++) { var childSprite:Node = scene3d.getChildAt(i); if(childSprite instanceof MeshSprite3D) { //设置精灵接收阴影 childSprite.meshRenderer.receiveShadow = true; //设置精灵可投射阴影 childSprite.meshRenderer.castShadow = true; } else if(childSprite instanceof SpotLight) { //...

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

8. 聚光灯实时阴影(ActionScript-3D基础(AS3)-LayaAir3D之灯光) [ 81%]

...Length;i++) { var childSprite:Node = scene3d.getChildAt(i); if(childSprite instanceof MeshSprite3D) { //设置精灵接收阴影 childSprite.meshRenderer.receiveShadow = true; //设置精灵可投射阴影 childSprite.meshRenderer.castShadow = true; } else if(childSprite instanceof SpotLight) { //...

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

9. Laya.loader.load(xx) 当地址""的时候,会报错。 [ 81%]

...           let tex;                 if (data instanceof ArrayBuffer) {                     var ext = Utils.getFileExtension(this._url);                     let format;                     switch (ext) {...

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

10. ts怎么判断对象是否是某个类 [ 80%]

...相关的链接 提交 2 个回复 cuixueying 赞同来自: 用typeof或者instanceof去判断! 2017-03-28 0 0 分享 微博 QZONE 微信 zeorro 赞同来自: laya 会在多个frame中来回切换吗?应该不会吧?都是在 laya player 这个frame 中操作各种东西而已吧? 因为类...

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