Commit 96ac4767 authored by Unicorn369's avatar Unicorn369

fix

parent 2e8f2762
...@@ -95,9 +95,9 @@ public class Menu : WindowServantSP ...@@ -95,9 +95,9 @@ public class Menu : WindowServantSP
Program.I().quit(); Program.I().quit();
Program.Running = false; Program.Running = false;
TcpHelper.SaveRecord(); TcpHelper.SaveRecord();
#if !UNITY_EDITOR || UNITY_ANDROID || UNITY_IPHONE // IL2CPP 使用此方法才能退出 #if !UNITY_EDITOR && (UNITY_ANDROID || UNITY_IPHONE) // IL2CPP 使用此方法才能退出
Application.Quit(); Application.Quit();
#elif #else
Process.GetCurrentProcess().Kill(); Process.GetCurrentProcess().Kill();
#endif #endif
} }
...@@ -134,10 +134,10 @@ public class Menu : WindowServantSP ...@@ -134,10 +134,10 @@ public class Menu : WindowServantSP
void onClickJoinQQ() void onClickJoinQQ()
{ {
#if !UNITY_EDITOR || UNITY_ANDROID //Android #if !UNITY_EDITOR && UNITY_ANDROID //Android
AndroidJavaObject jo = new AndroidJavaObject("cn.unicorn369.library.API"); AndroidJavaObject jo = new AndroidJavaObject("cn.unicorn369.library.API");
jo.Call("doJoinQQGroup", "UHm3h3hSrmgp-iYqMiZcc2zO5J1Q8OyW"); jo.Call("doJoinQQGroup", "UHm3h3hSrmgp-iYqMiZcc2zO5J1Q8OyW");
#elif #else
Application.OpenURL("https://jq.qq.com/?_wv=1027&k=50MZVQA"); Application.OpenURL("https://jq.qq.com/?_wv=1027&k=50MZVQA");
#endif #endif
} }
......
...@@ -9,6 +9,7 @@ public class WindowServant2D : Servant ...@@ -9,6 +9,7 @@ public class WindowServant2D : Servant
UIHelper.clearITWeen(gameObject); UIHelper.clearITWeen(gameObject);
iTween.MoveTo(gameObject, Program.camera_main_2d.ScreenToWorldPoint(new Vector3(Screen.width / 2, Screen.height * 1.5f, 0)), 0.6f); iTween.MoveTo(gameObject, Program.camera_main_2d.ScreenToWorldPoint(new Vector3(Screen.width / 2, Screen.height * 1.5f, 0)), 0.6f);
} }
resize();
} }
public override void applyShowArrangement() public override void applyShowArrangement()
...@@ -18,6 +19,23 @@ public class WindowServant2D : Servant ...@@ -18,6 +19,23 @@ public class WindowServant2D : Servant
UIHelper.clearITWeen(gameObject); UIHelper.clearITWeen(gameObject);
iTween.MoveTo(gameObject, Program.camera_main_2d.ScreenToWorldPoint(new Vector3(Screen.width / 2, Screen.height / 2, 0)), 0.6f); iTween.MoveTo(gameObject, Program.camera_main_2d.ScreenToWorldPoint(new Vector3(Screen.width / 2, Screen.height / 2, 0)), 0.6f);
} }
resize();
}
void resize()
{
if (gameObject != null)
{
if (Program.I().setting.setting.resize.value)
{
float f = Screen.height / 700f;
gameObject.transform.localScale = new Vector3(f, f, f);
}
else
{
gameObject.transform.localScale = new Vector3(1, 1, 1);
}
}
} }
public override void hide() public override void hide()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment