Skip to main content

GameOps

A/B Testing

To get the value of A/B testing id or variant id use the following methods:

// A/B testing id
String abTestingId = await GameAnalytics.getABTestingId();

// A/B testing variant id
String abTestingVariantId = await GameAnalytics.getABTestingVariantId();

Remember the A/B testing ids are first available when the Remote Configs are ready.

Custom Dimensions

GameAnalytics supports the use of up to 3 custom dimensions.

  • Custom01
  • Custom02
  • Custom03

During the game it is possible to set the active value for each custom dimension dynamically. Once a dimension is set it will be persisted across sessions/game-start and automatically be added to all event categories. Remember you have to set the custom dimensions before initialzing the SDK (but after setting the available custom dimensions) to be able to add the dimensions to the first session start event.

An example setting each custom dimension. To reset a set custom dimension simply just set it to empty string.

GameAnalytics.setCustomDimension01("ninja");
GameAnalytics.setCustomDimension02("dolphin");
GameAnalytics.setCustomDimension03("horde");

GameAnalytics.setCustomDimension03("");
FieldTypeDescriptionExample
customDimensionstringOne of the available dimension values set in the configuration phase. Will persist cross session. Set to empty string to reset.ninja
tip

Read more about custom dimensions here.