[LayaAir 2.0]Laya.Physics.rayCastAll 和 Laya.RaycastHit
这个两个东西
rayCastAll 在文档里能搜索到,但我在射线检测,这么写运行就提示没有该方法
Laya.Physics.rayCastAll(this.ray, this.outHitAllInfo, 30, 0);
RaycastHit 是在创建是时候就报错了
提示没有这个东西。
看官方网站介绍,该勾选的类库我都勾选了,运行还是不行。
rayCastAll 在文档里能搜索到,但我在射线检测,这么写运行就提示没有该方法
Laya.Physics.rayCastAll(this.ray, this.outHitAllInfo, 30, 0);
RaycastHit 是在创建是时候就报错了
提示没有这个东西。
看官方网站介绍,该勾选的类库我都勾选了,运行还是不行。
没有找到相关结果
已邀请:
要回复问题请先登录
1 个回复
源
赞同来自: kshell
let scene3d = new Laya.Scene3D();
let outHitInfoAll = new Laya.HitResult();
scene3d.physicsSimulation.rayCastAll(this.ray, outHitInfoAll, depth);