docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method SpawnAsPlayerObject

    SpawnAsPlayerObject(ulong, bool)

    Spawns a NetworkObject across the network and makes it the player object for the given client

    Declaration
    public void SpawnAsPlayerObject(ulong clientId, bool destroyWithScene = false)
    Parameters
    Type Name Description
    ulong clientId

    The clientId who's player object this is

    bool destroyWithScene

    Should the object be destroyed when the scene is changed

    In This Article
    Back to top
    Copyright © 2024 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)