大约有 32 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0026 秒)
...绿色 * 注:如相对移动速度过快,可能直接越过 */ public onTriggerEnter(other:Laya.PhysicsComponent):void { ((this.owner as Laya.MeshSprite3D).meshRenderer.sharedMaterial as BlinnPhongMaterial).albedoColor = new Laya.Vector4(0.0, 1.0, 0.0, 1.0); } /** * 当其他碰撞器进入绑...
来源: Laya2.0_文档 发布时间: 20210715
...相对移动速度过快,可能直接越过 */ override public function onTriggerEnter(other:PhysicsComponent):void { ((owner as MeshSprite3D).meshRenderer.sharedMaterial as BlinnPhongMaterial).albedoColor = new Vector4(0.0, 1.0, 0.0, 1.0); } /** * 当其他碰撞器进入绑定物体碰撞器后...
来源: Laya2.0_文档 发布时间: 20210714
...stanceJoint 与多个不同rigBody做距离关系绑定 代码片段: onTriggerEnter(other: any, self: any, contact: any) { let pointes = contact.getHitInfo().points; let potSelf = new Laya.Point(pointes[0].x, pointes[0].y); let potOther = new Laya.Point(pointes[0].x, pointes[0].y); self.ow...
来源: Laya_社区 发布时间: 20190609
... onStart():void {} /** * 开始触发时执行 */ public override function onTriggerEnter(other:PhysicsComponent):void {} /** * 持续触发时执行 */ public override function onTriggerStay(other:PhysicsComponent):void {} /** * 结束触发时执行 */ public override function onTriggerExit(other:...
来源: Laya2.0_文档 发布时间: 20210715
... public onTriggerStay(other: Laya.Collider): void{ console.log("触发:onTriggerEnter"); } (忽略了Rigidbody); 2018-07-16 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 Laya_Aaron 赞同来自: 已...
来源: Laya_社区 发布时间: 20180716
...cess(){ this.owner.removeSelf(); Laya.Pool.recover("flyCat", this.owner) } onTriggerEnter(other: any, self: any, contact: any): void { if (other.label === "cloud") { Laya.Tween.clearAll(this._sp) let effect: Laya.Animation = Laya.Pool.getItemByCreateFun("deathEffect", this.createEffect, this); effec...
来源: Laya_社区 发布时间: 20191019
...。可以控制碰撞什么层,不碰撞什么层。 我使用了 public onTriggerEnter(other: Laya.Collider): void { } 这个方法,发现不在同一个层级上的物体无法进入碰撞的这个回调方法。 请问如何可以检测碰撞到的所有的层的带Collider的物体 2018-05-2...
来源: Laya_社区 发布时间: 20180522
...is.rope.otherBody); } onEnable() { } onTriggerEnter(other: any, self: any, contact: any): void { //搜索黏贴在圆环上 } onUpdate(): void { } onDisable(): void { Laya.Pool.recover("friut",this.owner); } } 附件 : --> FruitMaster.z...
来源: Laya_社区 发布时间: 20220413
...后在这个新加的节点下加个脚本,里面做个侦测就行了 onTriggerEnter(other: any): void {} 2025-07-30 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 173*****903 相关问题 sprite旋转以后,但是原来碰...
来源: Laya_社区 发布时间: 20250730
...角度并不是特别小. a11a • 2020-03-09 14:18 你在FlyItem里添加 onTriggerEnter(other: any, self: any, contact: any): void { let rig: Laya.RigidBody = this.owner.getComponent(Laya.RigidBody) as Laya.RigidBody; let velocity = rig.linearVelocity; console.log(velocity) } 你把初始弹射改...
来源: Laya_社区 发布时间: 20200307