大约有 41 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0029 秒)
...进行射线检测。效果如(图5) ```typescript this.point.x = Laya.MouseManager.instance.mouseX; this.point.y = Laya.MouseManager.instance.mouseY; //产生射线 this.camera.viewportPointToRay(this.point,this._ray); //拿到射线碰撞的物体 this.scene.physicsSimulation.rayCast(this._ray...
来源: Laya2.0_文档 发布时间: 20210715
...,进行射线检测。效果如(图5) ```typescript this.point.x = MouseManager.instance.mouseX; this.point.y = MouseManager.instance.mouseY; //产生射线 this._camera.viewportPointToRay(this.point,this._ray); //拿到射线碰撞的物体 this._scene.physicsSimulation.rayCast(this._ray,this...
来源: Laya2.0_文档 发布时间: 20210715
this.scene.physicsSimulation.rayCastAll 报错 this.point.x = Laya.MouseManager.instance.mouseX; this.point.y = Laya.MouseManager.instance.mouseY; //产生射线 this.camera.viewportPointToRay(this.point,this.ray); /// Laya.PhysicsSimulation.rayCast(this.ray, this.outHitResult, 30, 0) //拿到...
来源: Laya_社区 发布时间: 20190523
...a.Vector3(0, 0, 0)) let pointVec2 = new Laya.Vector2( ) pointVec2.x = Laya.MouseManager.instance.mouseX; pointVec2.y = Laya.MouseManager.instance.mouseY; this.sceneCamera.viewportPointToRay(pointVec2, this.originRay) // 摄像机发出射线检测的碰撞体 let cameraHitResult = new Laya.HitResult...
来源: Laya_社区 发布时间: 20200617
...nction checkHit() { //从屏幕空间生成射线 point.elements[0] = Laya.MouseManager.instance.mouseX; point.elements[1] = Laya.MouseManager.instance.mouseY; camera.viewportPointToRay(point, ray); //射线检测获取所有检测碰撞到的物体 Laya.Physics.rayCastAll(ray, _outHitAllInfo, 30, 0...
来源: Laya_示例 发布时间: 20241118
...UI点击穿透的问题 //从屏幕空间生成射线 point.elements[0] = MouseManager.instance.mouseX; point.elements[1] = MouseManager.instance.mouseY; camera.viewportPointToRay(point, ray); //射线检测获取所有检测碰撞到的物体 Physics.rayCastAll(ray, _outHitAll...
来源: Laya_社区 发布时间: 20180120
...); var outHitResult: Laya.HitResult = new Laya.HitResult(); point.x = Laya.MouseManager.instance.mouseX; point.y = Laya.MouseManager.instance.mouseY; console.log("rayPoint111 pointx:"+ point.x+" pointy:"+point.y+ " ray.origin.x:"+ray.origin.x+ " ray.origin.y:"+ray.origin.y+ " ray.origin.z:"+ray.orig...
来源: Laya_社区 发布时间: 20191219
...e onMouseDown():void{ this.camera.viewportPointToRay(new Laya.Vector2(Laya.MouseManager.instance.mouseX,Laya.MouseManager.instance.mouseY),this.ray); Laya.Physics.rayCast(this.ray,this.hit); console.log("当前射线碰撞的信息是:" + this.hit.sprite3D.name); //摄像机位置 var position:Laya....
来源: Laya_社区 发布时间: 20181020
...ript mouseDown(){ //获取鼠标点击位置的屏幕坐标 this.point.x = MouseManager.instance.mouseX; this.point.y = MouseManager.instance.mouseY; //由点击的屏幕坐标产生射线 this.camera.viewportPointToRay(this.point, this.ray); //创建CannonHitResult对象来存储射线检测结果 ...
来源: Laya2.0_文档 发布时间: 20210715
...请: 与内容相关的链接 提交 1 个回复 cuixueying 赞同来自: MouseManager.instance.disableMouseEvent//禁用所有鼠标事件 2017-05-17 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 choe 相关问题 请问有没有方法...
来源: Laya_社区 发布时间: 20170517