Skip to content

Commit 2f9606c

Browse files
committed
Safe wrap resolution.
1 parent c13941d commit 2f9606c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Assets/JCSUnity/Scripts/JCS_Screen.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,5 +40,12 @@ public static int height
4040
#endif
4141
}
4242
}
43+
44+
public static void SetResolution(int width, int height, bool fullscreen, int preferredRefreshRate = 0)
45+
{
46+
#if !(UNITY_IOS || UNITY_ANDROID)
47+
Screen.SetResolution(width, height, fullscreen, preferredRefreshRate);
48+
#endif
49+
}
4350
}
4451
}

0 commit comments

Comments
 (0)