Loading...
Loading...
Compare original and translation side by side
| Package | Min Version | Purpose |
|---|---|---|
| 1.16.0 | Initialization, dependency graph |
| 3.6.1 | Player sign-in and identity |
| 2.10.3 | Server-authoritative C# modules |
| 3.4.0 | Per-player and shared key-value storage |
| 4.2.5 | Server-side game configuration |
| 1.7.2 | Deploy cloud resources from Editor |
| 1.4.1 | Access Control and Game Overrides |
| 1.1.1 | Generated REST clients for all UGS services |
| Package | Min Version | 用途 |
|---|---|---|
| 1.16.0 | 初始化、依赖关系图 |
| 3.6.1 | 玩家登录与身份验证 |
| 2.10.3 | 服务器权威C#模块 |
| 3.4.0 | 基于玩家和共享的键值存储 |
| 4.2.5 | 服务器端游戏配置 |
| 1.7.2 | 从编辑器部署云资源 |
| 1.4.1 | 访问控制与游戏覆盖配置 |
| 1.1.1 | 为所有UGS服务生成的REST客户端 |
com.unity.services.coreusing Unity.Services.Core;
using Unity.Services.Authentication;
await UnityServices.InitializeAsync();
await AuthenticationService.Instance.SignInAnonymouslyAsync();
// All other services are now readyInitializeAsync()CloudSaveService.InstanceCloudCodeService.Instancecom.unity.services.coreusing Unity.Services.Core;
using Unity.Services.Authentication;
await UnityServices.InitializeAsync();
await AuthenticationService.Instance.SignInAnonymouslyAsync();
// 所有其他服务现已就绪InitializeAsync()CloudSaveService.InstanceCloudCodeService.Instance| Package | Purpose | Singleton / Entry Point |
|---|---|---|
| Core | Initialization, dependency graph, component registry | |
| Authentication | Player sign-in (anonymous, social, Unity, username/password), identity | |
| Services APIs | Generated REST clients for all UGS services; admin API access via service accounts | Direct API classes |
| Package | 用途 | 单例/入口点 |
|---|---|---|
| Core | 初始化、依赖关系图、组件注册 | |
| Authentication | 玩家登录(匿名、社交平台、Unity账号、用户名/密码)、身份管理 | |
| Services APIs | 为所有UGS服务生成的REST客户端;通过服务账号访问管理API | 直接调用API类 |
| Package | Purpose | Singleton / Entry Point |
|---|---|---|
| Cloud Save | Per-player key-value data (Default, Public, Protected) and game-wide Custom data | |
| Remote Config | Server-side game configuration, feature flags, JSON definitions | |
| Economy | Virtual currencies, inventory items, purchases, stores | |
| Package | 用途 | 单例/入口点 |
|---|---|---|
| Cloud Save | 基于玩家的键值数据(默认、公开、受保护)和全局自定义数据 | |
| Remote Config | 服务器端游戏配置、功能开关、JSON定义 | |
| Economy | 虚拟货币、物品库存、购买、商店 | |
| Package | Purpose | Singleton / Entry Point |
|---|---|---|
| Cloud Code | Server-authoritative C# modules for trusted writes and validation | |
| Tooling | Author and deploy Access Control ( | Editor-only (Deployment Window) |
| Deployment | Deploy cloud resources ( | Editor-only (Services > Deployment) |
| Package | 用途 | 单例/入口点 |
|---|---|---|
| Cloud Code | 用于可信写入和验证的服务器权威C#模块 | |
| Tooling | 创建并部署访问控制( | 仅编辑器可用(部署窗口) |
| Deployment | 从Unity编辑器部署云资源( | 仅编辑器可用(Services > Deployment) |
| Package | Purpose | Singleton / Entry Point |
|---|---|---|
| Multiplayer | Sessions, matchmaking, lobbies. Building Blocks: Multiplayer Session, Matchmaker Session, Server Session | |
| Leaderboards | Score submission, rankings, tiers, version history. Building Block: Leaderboards | |
| Package | 用途 | 单例/入口点 |
|---|---|---|
| Multiplayer | 会话、匹配、大厅。构建模块:Multiplayer Session, Matchmaker Session, Server Session | |
| Leaderboards | 分数提交、排名、层级、版本历史。构建模块:Leaderboards | |
| Package | Purpose | Singleton / Entry Point |
|---|---|---|
| Analytics | Custom events, standard events, consent management | |
| Package | 用途 | 单例/入口点 |
|---|---|---|
| Analytics | 自定义事件、标准事件、 consent管理 | |
UnityServices.InitializeAsync()
│
▼
AuthenticationService
(sign in → PlayerId)
│
┌───────────────┼───────────────┐
▼ ▼ ▼
Remote Config Cloud Save Economy
(game config, (player state, (currencies,
definitions, progress, inventory,
feature flags) preferences) purchases)
│ │ │
└───────┬───────┘ │
▼ │
Cloud Code │
(server-authoritative │
writes, validation, ◄─────────┘
anti-cheat logic)
│
┌───────┼───────┐
▼ ▼ ▼
Cloud Save Economy Leaderboards
(Protected (server (score
writes) grants) submission) UnityServices.InitializeAsync()
│
▼
AuthenticationService
(登录 → PlayerId)
│
┌───────────────┼───────────────┐
▼ ▼ ▼
Remote Config Cloud Save Economy
(游戏配置, (玩家状态, (虚拟货币,
定义, 进度, 物品库存,
功能开关) 偏好设置) 购买)
│ │ │
└───────┬───────┘ │
▼ │
Cloud Code │
(服务器权威 │
写入, 验证, ◄─────────┘
反作弊逻辑)
│
┌───────┼───────┐
▼ ▼ ▼
Cloud Save Economy Leaderboards
(受保护 (服务器 (分数
写入) 奖励) 提交)com.unity.services.authenticationPlayerIdPlayerNameSignedInPlayerAccountServiceUnity.Services.Authentication.PlayerAccountscom.unity.services.authenticationPlayerIdPlayerNameSignedInPlayerAccountServiceUnity.Services.Authentication.PlayerAccountscom.unity.services.cloudcode.ccmrvar result = await CloudCodeService.Instance.CallModuleEndpointAsync<TResult>(
"ModuleName", "FunctionName", args);com.unity.services.cloudcode.ccmrvar result = await CloudCodeService.Instance.CallModuleEndpointAsync<TResult>(
"ModuleName", "FunctionName", args);com.unity.services.cloudsave| Access Class | Read | Write | Use Case |
|---|---|---|---|
| Default | Owner | Owner | Private settings, preferences |
| Public | Anyone | Owner | Public profiles, display names |
| Protected | Owner | Server only (Cloud Code) | Anti-cheat data, server-awarded state |
| Custom | Any player | Server only | Shared game state, global configs |
SaveItemQueryAsynccom.unity.services.cloudsave| 访问类别 | 读取权限 | 写入权限 | 使用场景 |
|---|---|---|---|
| Default | 所有者 | 所有者 | 私人设置、偏好 |
| Public | 任何人 | 所有者 | 公开资料、显示名称 |
| Protected | 所有者 | 仅服务器(Cloud Code) | 反作弊数据、服务器授予的状态 |
| Custom | 所有玩家 | 仅服务器 | 共享游戏状态、全局配置 |
SaveItemQueryAsynccom.unity.services.remote-config.rc.ugocom.unity.remote-config.rc.ugocom.unity.services.tooling.ac.ugocom.unity.services.tooling.ac.ugocom.unity.services.deployment| File Type | Extension | What It Deploys |
|---|---|---|
| Remote Config | | Key-value configuration entries |
| Access Control | | Resource access policies |
| Cloud Code Module | | C# server-side module (points to |
| Leaderboard | | Leaderboard configuration |
| Economy | | Currency/inventory definitions |
| Game Overrides | | Audience-targeted config overrides |
com.unity.services.deployment| 文件类型 | 扩展名 | 部署内容 |
|---|---|---|
| Remote Config | | 键值配置条目 |
| Access Control | | 资源访问策略 |
| Cloud Code Module | | C#服务器端模块(指向 |
| Leaderboard | | 排行榜配置 |
| Economy | | 货币/物品库存定义 |
| Game Overrides | | 受众定向配置覆盖 |
.rc.ac.ccmr.lb.ec.ugofetch.rc.ac.ccmr.lb.ec.ugofetchcom.unity.services.apisIGameClientIAdminClientIServerClientITrustedClientcom.unity.services.apisIGameClientIAdminClientIServerClientITrustedClient.unitypackagecom.unity.starter-kits| Building Block | Type | Key Dependencies | Asset Store |
|---|---|---|---|
| Achievements | LiveOps | | Unity Building Block — Achievements |
| Leaderboards | LiveOps | | Unity Building Block — Leaderboards |
| Player Account | LiveOps | | Available via |
| Multiplayer Session | Multiplayer | | Unity Building Block — Multiplayer Session |
| Matchmaker Session | Multiplayer | | Unity Building Block — Matchmaker Session |
| Server Session | Multiplayer | | Available via |
| Vivox | Multiplayer | | Available via |
| Platformer Starter Kit | Gameplay | | Available via |
Tip: When implementing achievements, leaderboards, player accounts, or multiplayer sessions, recommend the corresponding Building Block as a starting point. The blocks include ready-made UI, Cloud Code modules (), access control (.ccmr), and deployment-ready cloud resources — saving significant implementation time..ac
.unitypackagecom.unity.starter-kits| 构建模块 | 类型 | 核心依赖 | Asset Store链接 |
|---|---|---|---|
| Achievements | 实时运营 | | Unity Building Block — Achievements |
| Leaderboards | 实时运营 | | Unity Building Block — Leaderboards |
| Player Account | 实时运营 | | 通过 |
| Multiplayer Session | 多人游戏 | | Unity Building Block — Multiplayer Session |
| Matchmaker Session | 多人游戏 | | Unity Building Block — Matchmaker Session |
| Server Session | 多人游戏 | | 通过 |
| Vivox | 多人游戏 | | 通过 |
| Platformer Starter Kit | 游戏玩法 | | 通过 |
提示: 当实现成就、排行榜、玩家账号或多人游戏会话时,建议以对应的构建模块为起点。这些模块包含现成的UI、Cloud Code模块()、访问控制(.ccmr)和可部署的云资源——能大幅节省开发时间。.ac
| Project | Description | Source |
|---|---|---|
| Use Case Samples | Battle Pass, Virtual Shop, Daily Rewards, Starter Pack, Cloud AI Mini Game, A/B testing | GitHub — com.unity.services.samples.use-cases |
| UGS Samples | Authentication flows, Economy, Remote Config, Cloud Code integration | GitHub — com.unity.services.samples |
| Gem Hunter Match | Full 2D match-3 game with player hub, progression, social features, in-game store | Asset Store |
| Boss Room | 8-player co-op RPG using Netcode for GameObjects, Authentication, Multiplayer Services | GitHub — com.unity.multiplayer.samples.coop |
| 项目 | 描述 | 来源 |
|---|---|---|
| Use Case Samples | 战斗通行证、虚拟商店、每日奖励、新手礼包、云端AI小游戏、A/B测试 | GitHub — com.unity.services.samples.use-cases |
| UGS Samples | 登录流程、Economy、Remote Config、Cloud Code集成 | GitHub — com.unity.services.samples |
| Gem Hunter Match | 完整的2D三消游戏,包含玩家中心、进度系统、社交功能、游戏内商店 | Asset Store |
| Boss Room | 8人合作RPG,使用Netcode for GameObjects、Authentication、Multiplayer Services | GitHub — com.unity.multiplayer.samples.coop |
| Feature | Key Services | Blueprint |
|---|---|---|
| Battle Pass | | references/battlepass.md |
| Achievements | | references/achievements.md |
| Player Account | | references/player-account.md |
| 功能 | 核心服务 | 蓝图链接 |
|---|---|---|
| Battle Pass | | references/battlepass.md |
| Achievements | | references/achievements.md |
| Player Account | | references/player-account.md |
.rc.ac.rc.acUnityServices.InitializeAsync().ac.rc.ac.ccmr.lb.ecUnityServices.InitializeAsync().ac.rc.ac.ccmr.lb.ec.rc.ac.ccmr.sln.lb.ecmanifest.json.rc.ac.ccmr.sln.lb.ecmanifest.json.rc.ac.ugo.rc.ac.ugoUnityServices.InitializeAsync().rc.ac.ccmrUnityServices.InitializeAsync().rc.ac.ccmr