環境サポート
Learn how Analytics works with Unity Gaming Services environments, and how to initialize the SDK for different environments.
読み終わるまでの所要時間 1 分最終更新 7ヶ月前
環境は、プロジェクトに関連付けられたデータを含む Unity Game Services の論理パーティションです。Analytics では、UnityServices を初期化するときに に追加することで、さまざまな環境にイベントを送信できます。
InitializationOptionsusing UnityEngine;using Unity.Services.Core;using Unity.Services.Analytics;using System.Collections.Generic;using Unity.Services.Core.Environments;class InitWithEnvironment : MonoBehaviour { async void Awake() { var options = new InitializationOptions(); options.SetEnvironmentName("dev"); await UnityServices.InitializeAsync(options); }}
基礎となるキー:
com.unity.services.core.environment-name詳細については、環境のページ を参照してください。