docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Constructor DistributedUIDGenerator

    DistributedUIDGenerator()

    Create a default instance which uses the current time as the CustomEpoch the machines physical address as MachineId.

    Declaration
    public DistributedUIDGenerator()

    DistributedUIDGenerator(long)

    Creates an instance with a defined CustomEpoch.

    Declaration
    public DistributedUIDGenerator(long customEpoch)
    Parameters
    Type Name Description
    long customEpoch

    The custom epoch is used to calculate the timestamp by taking the current time and subtracting the CustomEpoch. The value is then stored in 41 bits giving it a maximum time of 69 years.

    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)