기술 자료

​
​

Development

User Acquisition

Monetization

산업 분야

Multiplayer Services SDK

All Services

Multiplayer Services SDK

이 페이지는 선택한 언어로 제공되지 않습니다.
Multiplayer
​
​
Multiplayer Services SDK
  • Overview
  • Get started
  • Use multiplayer sessions
  • Manage sessions
  • Connect players through a relay
  • Networking
  • Matchmaking
  • Monitor and debug sessions
  • Tutorials
  • Reference
    • Privacy and consent
    • Support
    • Glossary
    • Frequently asked questions
    • Multiplayer Services Building Blocks
    • Reference
  1. Multiplayer Services SDK

Frequently asked questions

Common questions concerning the Multiplayer Services SDK.
읽는 시간 3분
최근 업데이트: 15일 전

What is the purpose of sessions, and how do they relate to the individual services?

The Unity Multiplayer SDK uses Sessions as a comprehensive wrapper to simplify the integration of Unity Gaming Services (UGS) backend features, such as Lobby, Relay, and Matchmaker into multiplayer games. This single interface reduces boilerplate code and standardizes UGS usage, automatically managing features like Lobby heartbeating and, when enabled, the Lobby/Relay integration, allowing developers to focus on unique game features.

How does the Sessions API compare to the direct services API?

The following table compares the high level view for P2P Matchmaking when using Matchmaker, Lobby, and Relay individually versus using the Sessions API.

Direct services APIs

Sessions API equivalent

Host1. Create a Matchmaker ticket
2. Wait for the ticket to find a match
3. Create a lobby
4. Continuously heartbeat the Lobby
5. Create a Relay allocation
6. Add the Relay allocation ID to the Lobby host player
7. Start the NetworkManager
1. Start Matchmaking with Relay
Joining player1. Create a Matchmaker ticket
2. Wait for the ticket to find a match
3. Join the lobby based on the match ID
4. Join the Relay allocation
5. Add the Relay allocation ID to the Lobby player
6. Start NetworkManager
1. Start Matchmaking

Which APIs are deprecated?

The following standalone SDKs are depreacted:
  • Lobby:
    com.unity.services.lobby
  • Relay:
    com.unity.services.relay
  • Matchmaker:
    com.unity.services.matchmaker
The standalone SDKs are deprecated in favor of
com.unity.services.multiplayer
, their functionalities are still accessible within
com.unity.services.multiplayer
. Upgrade to the Multiplayer Services SDK by following the migration guide.

How does the session interact with the network?

Starting with version
1.2.0-pre.1
of
com.unity.services.multiplayer
, you can now choose when to start the network connection in your game flow. This isn't available with Matchmaking.
If you make the host use
WithRelayNetwork
,
WithDirectNetwork
or
WithDistributedAuthorityNetwork
when creating the session, then the network starts automatically as soon as the session is created. Any player joining this same session is pulled into the network connection automatically.
If you don't make the host use
WithRelayNetwork
,
WithDirectNetwork
or
WithDistributedAuthorityNetwork
when creating the session, then no network connection is automatically established. You can then execute any pre-match setup such as choosing a character or waiting for all players to be ready before establishing the network connection. No network is created for any player joining this session at that point. When the host is ready, they can use
StartRelayNetwork
,
StartDirectNetwork
or
StartDistributedAuthorityNetwork
to start the network. Any player joining this session after the network start is pulled into the network connection automatically.

Are there WebGL limitations?

The Multiplayer SDK supports the WebGL target, however, User Datagram Protocol isn't supported for this platform, consequently, Quality of service isn't available, neither is the Datagram Transport Layer Security encryption protocol for Relay. Broader limitations remain, even those unrelated to the Multiplayer SDK, such as restrictions on multithreading including the use of
Task.Delay
.

How is the Sessions API priced?

The Session API wraps multiple services into a single SDK. This includes Relay, Distributed Authority, Lobby, and Matchmaker and therefore contributes to the billing of each of those services.
Refer to the Unity Gaming Services pricing page for complete details.

How do you enable verbose logging?

Set the
ENABLE_UNITY_MULTIPLAYER_VERBOSE_LOGGING
scriptable define under Script Compilation in the Player window of the Untiy Editor.

Would it be possible to matchmake to a session based on the best latency?

Quality of service (QoS) measurements are automatically used in the Sessions API when a player calls
MatchmakeSessionAsync
.

Copyright © 2026 Unity Technologies
법률 정보개인정보 처리방침쿠키Documentation Terms of Use개인 정보 판매 또는 공유 금지개인정보 보호 선택(쿠키 설정)

'Unity', Unity 로고 및 기타 Unity 상표는 미국 및 기타 지역 내 Unity Technologies 또는 그 계열사의 상표 또는 등록상표입니다(자세한 내용은 여기에서 확인하세요). 기타 명칭 또는 브랜드는 해당 소유자의 상표입니다.

일부 페이지는 편의를 위해 기계 번역되었으며 부정확한 내용이 있을 수 있습니다. 정보가 상충되는 경우, 영어 버전을 우선으로 참조하세요.

  • 보고 있는 페이지
    • What is the purpose of sessions, and how do they relate to the individual services?

    • How does the Sessions API compare to the direct services API?

    • Which APIs are deprecated?

    • How does the session interact with the network?

    • Are there WebGL limitations?

    • How is the Sessions API priced?

    • How do you enable verbose logging?

    • Would it be possible to matchmake to a session based on the best latency?


이 페이지의 문제 보고