Minor fix for newer Unity versions.

pull/413/head
Brad Nelson 2019-07-13 21:05:42 +00:00
parent 1dc2b604e2
commit 1bc5bab70b
1 changed files with 7 additions and 2 deletions

View File

@ -638,9 +638,14 @@ namespace UnityEngine.UI.Extensions {
usesNewRendering = false; usesNewRendering = false;
if (Application.unityVersion.StartsWith("2019.1.")) { if (Application.unityVersion.StartsWith("2019.1.")) {
int number = Convert.ToInt32(Application.unityVersion[7].ToString()); if (!Char.IsDigit(Application.unityVersion[8])) {
int number = Convert.ToInt32(Application.unityVersion[7].ToString());
if (number > 4) { if (number > 4) {
usesNewRendering = true;
}
}
else {
usesNewRendering = true; usesNewRendering = true;
} }
} }