Behavior Designer 中CanSee Object与Within Distance的使用区别

两者区别

如上图,使用这两个条件时,注意区分关键不同,can see object 只能看一个物体,因为源码里用的是GameObject.FindGameObjectWithTag(),而Within Distance用的是GameObject.FindGameObjectsWithTag(),返回的是数组。因此使用时,注意一下。

发布了49 篇原创文章 · 获赞 8 · 访问量 1万+

猜你喜欢

转载自blog.csdn.net/qq_23158477/article/details/99681056