Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
//UnityEditorのゲームビューでカーソルを非表示にしておくスクリプト
//録画したときにカーソルが映り込むのを防止
public class GameViewHiddenCursor : MonoBehaviour
{
private void OnEnable()
{
Cursor.visible = false;
}
private void OnApplicationFocus(bool hasFocus)
{
if (hasFocus)
{
Cursor.visible = false;
}
else
{
Cursor.visible = true;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.