设备连接页面检测定位服务

This commit is contained in:
Caiyanpeng committed 2021-10-13 11:29:09 +08:00
1 parent efd1795e63
commit 9be2e77ae5
6 files changed
+14 -3

No files matched your search

+7
View File
@@ -191,6 +191,13 @@ namespace Assets.Scripts
loading.GetComponent<LoadingPf>().Show();
}
public static void CallAndroidMethod(string methodName,params object[] args)
{
AndroidJavaClass jc = new AndroidJavaClass("com.unity3d.player.UnityPlayer");
var activity = jc.GetStatic<AndroidJavaObject>("currentActivity");
activity.Call(methodName, args);
}
public static void showLoadingExtension(this GameObject game)
{
game.SetActive(true);