Browse Source

拍照翻转

zhaoyang 3 years ago
parent
commit
94a77521b3
1 changed files with 2 additions and 1 deletions
  1. 2 1
      GameClient/Assets/Game/HotUpdate/Views/DressUp/PhotographView.cs

+ 2 - 1
GameClient/Assets/Game/HotUpdate/Views/DressUp/PhotographView.cs

@@ -221,7 +221,8 @@ namespace GFGGame
 
                 distance = Input.mousePosition - Camera.main.WorldToScreenPoint(hitGameObj.transform.position);
 
-                _ui.m_comSelectBox.target.rotation = -hitGameObj.transform.eulerAngles.z;
+                Vector3 localEulerAngles = hitGameObj.transform.localEulerAngles;
+                _ui.m_comSelectBox.target.rotation = localEulerAngles.y != 0 ? hitGameObj.transform.localEulerAngles.z : -hitGameObj.transform.localEulerAngles.z;
                 _ui.m_comSelectBox.target.size = SceneController.GetGameObjectSize(hitGameObj);
                 ControllerSelectBoxPos();
             }