docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class SteamStructLayout

    Checks that StructPackSize, chosen from compile-time platform symbols, matches the pack Valve's binaries use on the running OS (8 on Windows, 4 elsewhere). A mismatch misreads every callback payload without crashing, so InitEx(out string, SteamDispatchMode) refuses to initialize instead.

    Inheritance
    object
    SteamStructLayout
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Unity.Steamworks.Interop
    Assembly: Unity.Steamworks.Interop.dll
    Syntax
    public static class SteamStructLayout

    Properties

    ExpectedPackSize

    The pack size Valve's binaries use on the OS this process is running on.

    Declaration
    public static int ExpectedPackSize { get; }
    Property Value
    Type Description
    int

    Methods

    Validate(out string)

    Checks the compiled pack size against the running OS, and that the generated structs actually apply it.

    Declaration
    public static bool Validate(out string error)
    Parameters
    Type Name Description
    string error

    Describes the first mismatch found, or null on success.

    Returns
    Type Description
    bool

    true when the pack size is correct.

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