docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Control how Unity initializes a Multiplayer service

    When you enter Play Mode in a project that uses multiplayer widgets, Unity does the following by default:

    • Initializes UnityServices.
    • Initializes Vivox if it already exists in your project.
    • Uses the anonymous sign-in to authenticate a user.

    If your project uses another authentication method, or you want to initialize these features at another time, override the default initialization behavior. To do this:

    • In the main menu, go to Edit > Project Settings.
    • Select Widgets.
    • Enable Use Custom Service Initialization.

    When you enable this property, you need to manually initialize the following services for Widgets to work:

    • Unity Gaming Services (UGS)
    • Authentication
    • Vivox Service, when the Vivox Package exists in your Project.

    When you enable Use Custom Service Initialization Unity creates a ScriptableObject in the Assets folder under Assets > Multiplayer Widgets > Resources > MultiplayerWidgetsSettings. To tell multiplayer widgets that you have initialized one or more of these services, call WidgetServiceInitialization.ServicesInitialized in the MultiplayerWidgetsSettings script.

    Additional resources

    • Get started with UGS
    • Configure a session
    • Widget configuration reference
    • Game Server Hosting (Multiplay)
    • Welcome to Voice and Text Chat (Vivox)
    In This Article
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)