【发布时间】:2022-11-19 07:37:29
【问题描述】:
我想获取enter image description here这个参数。我正在尝试使用此代码 FirebaseRemoteConfig.GetInstance(Firebase.FirebaseApp.DefaultInstance).GetValue("VERSION").ToString() 执行此操作,但它不返回任何内容。我也尝试使用 FirebaseRemoteConfig.DefaultInstance.GetValue 获取它,但结果相同。
using UnityEngine;
using UnityEngine.SceneManagement;
using Firebase.RemoteConfig;
public class GameOpening : MonoBehaviour
{
Firebase.DependencyStatus dependencyStatus = Firebase.DependencyStatus.UnavailableOther;
// Use this for initialization
void Start()
{
Firebase.FirebaseApp.CheckAndFixDependenciesAsync().ContinueWith(task => {
dependencyStatus = task.Result;
if (dependencyStatus == Firebase.DependencyStatus.Available)
{
Debug.Log(FirebaseRemoteConfig.DefaultInstance.GetValue("VERSION"));
}
else
{
Debug.LogError(
"Could not resolve all Firebase dependencies: " + dependencyStatus);
}
});
}
}
【问题讨论】:
-
现在它只能在 pc 上运行,当我在 android 上运行它时没有任何反应
标签: firebase unity3d firebase-remote-config