3
我一直在研究sidescroller射擊遊戲。香港專業教育學院得到了我的sidescroller射手性格與這些環顧四周:讓斯萊普工作就像LookAt(x,Vector3.Right)一樣
chest.LookAt(mousepos, Vector3.right);
&
chest.LookAt(mousepos, Vector3.left);
(左當一個字符轉向左邊和右邊當一個字符向右轉)
所以它不會瞄準任何其他軸......但是當鼠標穿過角色的中間而不是圍繞它時,它會獲得旋轉以在幀之間進行小型運輸,並且它不會一直到達那裏它只會傳送到它的公司rect旋轉像LookAt應該。
那麼問題是,我如何得到任何與Time.deltTime一起工作的四元數slerp與LookAt(x,Vector3.Right)一樣工作?我必須有Vector3.right並且離開,所以它會移動槽1軸。
非常感謝任何幫助我的人。 :)