mirror of
https://github.com/NotAKidoS/NAK_CVR_Mods.git
synced 2025-09-02 14:29:25 +00:00
[ThirdPerson] Fix for game issue, reset player camera culling mask to default on world load.
This commit is contained in:
parent
afb44fc3a7
commit
53c369b950
4 changed files with 66 additions and 47 deletions
|
@ -22,13 +22,14 @@ public class ThirdPerson : MelonMod
|
|||
if (!Input.GetKey(KeyCode.LeftControl))
|
||||
{
|
||||
// Prevents scrolling while in Menus or UnityExplorer
|
||||
if (State && Cursor.lockState == CursorLockMode.Locked)
|
||||
{
|
||||
float scroll = Input.GetAxis("Mouse ScrollWheel");
|
||||
if (scroll != 0f) ScrollDist(Mathf.Sign(scroll));
|
||||
}
|
||||
if (!State || Cursor.lockState != CursorLockMode.Locked)
|
||||
return;
|
||||
|
||||
float scroll = Input.GetAxis("Mouse ScrollWheel");
|
||||
if (scroll != 0f) ScrollDist(Mathf.Sign(scroll));
|
||||
return;
|
||||
}
|
||||
|
||||
if (Input.GetKeyDown(KeyCode.T)) State = !State;
|
||||
if (!State || !Input.GetKeyDown(KeyCode.Y)) return;
|
||||
RelocateCam((CameraLocation)(((int)CurrentLocation + (Input.GetKey(KeyCode.LeftShift) ? -1 : 1) + Enum.GetValues(typeof(CameraLocation)).Length) % Enum.GetValues(typeof(CameraLocation)).Length), true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue