Telarin
I'm working on a first person project in Unity. When a user opens a GUI screen, for instance Inventory, by pressing I, I switch the mouse out of FPS mode so that they can interact with the GUI, by doing the following:

Cursor.lockState = CursorLockMode.None;
Cursor.visible = true;

And when they close said GUI window, I reverse the operation to put the mouse back into first person Mouse Look mode:

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

This all works great as long as the Voxel Farm Plugin is not present. As soon as the Voxel Farm Plugin is added, these mouse picks up an odd behavior when it is unlocked for GUI interaction. Any time the left or right mouse buttons are clicked, the cursor immediately snaps to the center of the screen. I've looked through the voxelfarm_client.cs script, and don't see anything handling mouse input, so I'm wondering if there is something buried deeper in the Plugin code that is causing the problem.

If you need more info to replicate the issue, let me know and I can provide the scripts I am using in full.
0 0
voxelfarmtorres
In order to disable the cursor behavior, you will need to comment all code in OnEnable() and LateUpdate() of voxelfarm_clientSubscriber script.
0 0