Struct NetworkSceneId | Multiplayer HLAPI | 1.0.8
docs.unity3d.com
    Show / Hide Table of Contents

    Struct NetworkSceneId

    This is used to identify networked objects in a scene. These values are allocated in the editor and are persistent for the lifetime of the object in the scene.

    Namespace: UnityEngine.Networking
    Syntax
    [Serializable]
    [Obsolete("The high level API classes are deprecated and will be removed in the future.")]
    public struct NetworkSceneId : IEquatable<NetworkSceneId>

    Constructors

    NetworkSceneId(UInt32)

    Declaration
    public NetworkSceneId(uint value)
    Parameters
    Type Name Description
    UInt32 value

    Properties

    Value

    The internal value for this object.

    Declaration
    public uint Value { get; }
    Property Value
    Type Description
    UInt32

    Methods

    Equals(Object)

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    Object obj
    Returns
    Type Description
    Boolean
    Overrides
    ValueType.Equals(Object)

    Equals(NetworkSceneId)

    Declaration
    public bool Equals(NetworkSceneId other)
    Parameters
    Type Name Description
    NetworkSceneId other
    Returns
    Type Description
    Boolean

    GetHashCode()

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    Int32
    Overrides
    ValueType.GetHashCode()

    IsEmpty()

    Returns true if the value is zero. Non-scene objects - ones which are spawned at runtime will have a sceneId of zero.

    Declaration
    public bool IsEmpty()
    Returns
    Type Description
    Boolean

    True if zero.

    ToString()

    Returns a string like SceneId:value.

    Declaration
    public override string ToString()
    Returns
    Type Description
    String

    String representation of this object.

    Overrides
    ValueType.ToString()

    Operators

    Equality(NetworkSceneId, NetworkSceneId)

    Declaration
    public static bool operator ==(NetworkSceneId c1, NetworkSceneId c2)
    Parameters
    Type Name Description
    NetworkSceneId c1
    NetworkSceneId c2
    Returns
    Type Description
    Boolean

    Inequality(NetworkSceneId, NetworkSceneId)

    Declaration
    public static bool operator !=(NetworkSceneId c1, NetworkSceneId c2)
    Parameters
    Type Name Description
    NetworkSceneId c1
    NetworkSceneId c2
    Returns
    Type Description
    Boolean
    In This Article
    • Constructors
      • NetworkSceneId(UInt32)
    • Properties
      • Value
    • Methods
      • Equals(Object)
      • Equals(NetworkSceneId)
      • GetHashCode()
      • IsEmpty()
      • ToString()
    • Operators
      • Equality(NetworkSceneId, NetworkSceneId)
      • Inequality(NetworkSceneId, NetworkSceneId)
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023