lvjincheng před 3 roky
rodič
revize
d210cfb5c3
1 změnil soubory, kde provedl 8 přidání a 6 odebrání
  1. 8 6
      Assets/BowArrow/Scripts/Entry.cs

+ 8 - 6
Assets/BowArrow/Scripts/Entry.cs

@@ -36,15 +36,11 @@ public class Entry : MonoBehaviour
                 //等场景加载完再提示
             } else {
                 SetTip("请安装最新版本软件", Color.yellow);
-                DoTweenUtil.CallDelay(2f, () => {
-                    Application.Quit();
-                });
+                DelayQuit();
             }
         } else {
             SetTip("读取服务端软件版本配置失败", Color.red);
-            DoTweenUtil.CallDelay(2f, () => {
-                Application.Quit();
-            });
+            DelayQuit();
         }
     }
 
@@ -75,4 +71,10 @@ public class Entry : MonoBehaviour
         tipText.text = text;
         tipText.color = color;
     }
+
+    void DelayQuit() {
+        DoTweenUtil.CallDelay(3f, () => {
+            Application.Quit();
+        });
+    }
 }