unity 使用RotateAround的使用注意
1.对于一个固定的点,围绕它进行旋转。需要注意区分世界坐标还是本地坐标
RotateAround(GameObject.Find("Cave").transform.position, transform.right, Time.deltaTime * 10);
SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。RotateAround(GameObject.Find("Cave").transform.position, new Vector(0,0,1), Time.deltaTime * 10);
RotateAround(GameObject.Find("Cave").transform.position, GameObject.Find("Cave").transform.right, Time.deltaTime * 10);
上面是不一样的效果,假如围绕的点会进行移动的话,第一个世界坐标,第二个自身的朝向,第三个围绕的点的朝向。

更多精彩