If I was offline when I first ran the game,what configuration will I read?

It seems that I will read the default value of the data structure.
Can I define a local default configuration?
Or I only can fill in the default values in the default parameters of the Get function?

Check on Remote Config, you can see they only fire Event with Switch case:
Cache / Fail / Success.
Just do what you want on that switch case.

// Retrieve and apply the current key-value pairs from the service on Awake:
    void Awake () {
        // Add a listener to apply settings when successfully retrieved:
        ConfigManager.FetchCompleted += ApplyRemoteSettings;
        // Fetch configuration setting from the remote service:
        ConfigManager.FetchConfigs<userAttributes, appAttributes>(new userAttributes(), new appAttributes());
    }
    void ApplyRemoteSettings (ConfigResponse configResponse) {
        // Conditionally update settings, depending on the response's origin:
        switch (configResponse.requestOrigin) {
            case ConfigOrigin.Default:
                Debug.Log ("Load fail! Use DEFAULT");
                break;
            case ConfigOrigin.Cached:
                Debug.Log ("Load fail! Use Cached");
                break;
            case ConfigOrigin.Remote:
                Debug.Log ("Success Load Settings From Server!");
                break;
        }
    }
2 Likes

@Sligh a local default config is something we’re exploring, but currently the best way would be to initialize the variables to the best default and pass that in as the default value.

Sorry to reopen this, but I wanted to know if you are still considering implementing a local default config so we can load a valid configuration solely through RemoteConfig even if the player is offline when they start up the game.

Do you plan to change the default values often? Otherwise the default GET values should work, can you show your code?