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

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

1. RopeJoint代码动态创建 无法设置otherbody等属性 [ 100%]

... Laya.stage.addChild(img2); sp=img2; img2.addComponent(BoxCollider); (img2.getComponent(BoxCollider) as BoxCollider).width=256; (img2.getComponent(BoxCollider) as BoxCollider).height=256; img2.addComponent(RigidBody); img.addComponent(BoxCollider); (img.getComponent(BoxCollider) as BoxCollider).widt...

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

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

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

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

3. Laya2D碰撞问题 [ 92%]

...Laya.RigidBody['objs'][i]; if(element) if(element.owner){ if(element.owner.getComponent(Laya.CircleCollider)){return} if(element.owner.getComponent(Laya.BoxCollider)){ element['_sysPosToPhysic'](); element.owner.getComponent(Laya.BoxCollider)['resetShape'](); element['resetCollider'](); element.owne...

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

4. laya2 物理引擎好多问题 [ 91%]

...ggerEnter(e:Laya.RigidBody):void{  var cil:Laya.CircleCollider=this.owner.getComponent(Laya.CircleCollider); var rig:Laya.RigidBody=this.owner.getComponent(Laya.RigidBody); cil.enabled=false; rig.enabled=false; var self:Laya.Sprite= this.owner as Laya.Sprite; var ni:Laya.Animation=new Laya.Animatio...

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

5. RopeJoint代码动态创建 无法设置otherbody [ 88%]

...     }      onAwake() {         let rig:Laya.RigidBody=this.owner.getComponent(Laya.RigidBody);         var lala=UIcontrol.FUI.bg.getComponent(Laya.RigidBody);         this.rope=this.owner.getComponent(Laya.RopeJoint);         this.rope.otherBody=lala;         console.log(la...

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

6. 添加或修改物理ChainCollider属性points时,报错 [ 87%]

...llider,使用代码更改属性points,则报错 var chains=this.sprite.getComponent(Laya.ChainCollider); (chains as Laya.ChainCollider).points="25,25,50,50"; 2018-11-28 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个...

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

7. 播放动画(JavaScript-3D基础(JS)-LayaAir3D之Animator动画) [ 84%]

...怎么控制动画的播放呢? LayaAir 3D引擎的Sprite3D类提供了 `getComponent()` 方法来获取模型上的组件。带动画的模型在加载创建时引擎默认赋予了Animator动画组件,因此我们可以获取它,参考以下代码。 ```typescript //获取角色动画组件 ...

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

8. 播放动画(TypeScript-3D基础(TS)-LayaAir3D之Animator动画) [ 84%]

...怎么控制动画的播放呢? LayaAir 3D引擎的Sprite3D类提供了 `getComponent()` 方法来获取模型上的组件。带动画的模型在加载创建时引擎默认赋予了Animator动画组件,因此我们可以获取它,参考以下代码。 ```typescript //获取角色动画组件 ...

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

9. 播放动画(ActionScript-3D基础(AS3)-LayaAir3D之Animator动画) [ 84%]

...怎么控制动画的播放呢? LayaAir 3D引擎的Sprite3D类提供了 `getComponent()` 方法来获取模型上的组件。带动画的模型在加载创建时引擎默认赋予了Animator动画组件,因此我们可以获取它,参考以下代码。 ```typescript //获取角色动画组件 ...

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

10. 2.0使用addComponent的组件,怎么删除?没有removeComponent [ 78%]

...scale TS项目使用matter.js库无智能提示 使用3D时候,Property 'getComponentByType' does not exist on type 'Node'. 微信小游戏:HTMLDivElement的使用 LayaAirIDE下如何使用mask? 微信小游戏如何使用ttf字体? 请问2.0的版本开始,我用ts编写的相关内容,...

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