Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice
  3. Dismiss Notice

Fetch rules from client

Discussion in 'Unity Remote Config' started by Gridpop, Sep 16, 2020.

  1. Gridpop

    Gridpop

    Joined:
    May 29, 2014
    Posts:
    9
    Recently learned about Remote Config, I absolutely love the feature!

    Is there a way to get access to the rules currently active within a game? I'd like to implement an event (say double XP weekend), and notify players affected by the rule through a popup inside the game.
    I would only need to know if the rule is active at the moment, as I would hard code the content of the popup into the game and display it if applicable.

    Is that possible?

    Thanks,
    Dan
     
  2. SamOYUnity3D

    SamOYUnity3D

    Unity Technologies

    Joined:
    May 12, 2019
    Posts:
    626
    Glad to hear you love Remote Config. You can add a boolean key that defaults to false and set it to true when the rule is enabled, then you can get this key at runtime to determine whether the rule is enabled.

    upload_2020-9-17_12-27-52.png

    upload_2020-9-17_12-28-17.png
     
  3. Gridpop

    Gridpop

    Joined:
    May 29, 2014
    Posts:
    9
    Awesome, that makes sense. Thanks for the quick reply!
     
    SamOYUnity3D likes this.