示例#1
0
 private void OnHudChange(SystemControls.HudStates state)
 {
     if (state == SystemControls.HudStates.Menu)
     {
         transform.position = new Vector3(42, transform.position.y, transform.position.z);
     }
     else
     {
         transform.position = new Vector3(-25, transform.position.y, transform.position.z);
     }
 }
示例#2
0
    private void OnHudChange(SystemControls.HudStates state)
    {
        if (state == SystemControls.HudStates.Menu)
        {
            Cursor.lockState = CursorLockMode.None;
            Cursor.visible   = true;
            enabled          = true;
        }
        else
        {
            EndDrag();
            infoPanelManager.gameObject.SetActive(false);

            Cursor.lockState = CursorLockMode.Locked;
            Cursor.visible   = false;
            enabled          = false;
        }
    }