public static UsdkCallBack Create() { GameObject callBackObj = new GameObject("UsdkCallBack"); UsdkCallBack callBack = callBackObj.AddComponent <UsdkCallBack> (); DontDestroyOnLoad(callBackObj); return(callBack); }
static UsdkApi() { //sdk api if (Application.platform == RuntimePlatform.Android) { api = new UsdkAndroidApi(); } else if (Application.platform == RuntimePlatform.IPhonePlayer) { api = new UsdkiOSApi(); } else { api = new UsdkWindowsApi(); } //sdk callback UsdkCallBack callBack = UsdkCallBack.Create(); callBack.OnCallBack = OnUsdkCallBack; }