コード例 #1
0
ファイル: Player.cs プロジェクト: Alan-Baylis/VOX
 public void Recoill(Recoill recoill)
 {
     if (photonView.isMine)
     {
         mouseLook.Recoill(recoill);
     }
 }
コード例 #2
0
ファイル: PlayerMouseLook.cs プロジェクト: Alan-Baylis/VOX
        public void Recoill(Recoill recoill)
        {
            if (photonView.isMine)
            {
                this.recoill    += recoill.recoill * recoill.divider;
                recoillLerpSpeed = recoill.lerpSpeed;

                _xRot = Mathf.Clamp(_xRot - recoill.recoill * (1f - recoill.divider), -999f, 999f);
            }
        }