Search Results for

    Show / Hide Table of Contents

    Struct WeaponAsset

    Implements
    IEquatable<WeaponAsset>
    INativeValue
    Inherited Members
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: GTA
    Assembly: ScriptHookVDotNet3.dll
    Syntax
    public struct WeaponAsset : IEquatable<WeaponAsset>, INativeValue

    Constructors

    | Improve this Doc View Source

    WeaponAsset(WeaponHash)

    Declaration
    public WeaponAsset(WeaponHash hash)
    Parameters
    Type Name Description
    WeaponHash hash
    | Improve this Doc View Source

    WeaponAsset(Int32)

    Declaration
    public WeaponAsset(int hash)
    Parameters
    Type Name Description
    Int32 hash
    | Improve this Doc View Source

    WeaponAsset(UInt32)

    Declaration
    public WeaponAsset(uint hash)
    Parameters
    Type Name Description
    UInt32 hash

    Properties

    | Improve this Doc View Source

    DisplayName

    Declaration
    public readonly string DisplayName { get; }
    Property Value
    Type Description
    String
    | Improve this Doc View Source

    Hash

    Gets the hash for this WeaponAsset.

    Declaration
    public int Hash { readonly get; }
    Property Value
    Type Description
    Int32
    | Improve this Doc View Source

    IsLoaded

    Gets a value indicating whether this WeaponAsset is loaded so it can be spawned.

    Declaration
    public readonly bool IsLoaded { get; }
    Property Value
    Type Description
    Boolean
    | Improve this Doc View Source

    IsValid

    Gets a value indicating whether this WeaponAsset is valid as a weapon or a ammo hash.

    Declaration
    public readonly bool IsValid { get; }
    Property Value
    Type Description
    Boolean
    | Improve this Doc View Source

    IsValidAsWeaponHash

    Gets a value indicating whether this WeaponAsset is valid as a weapon hash.

    Declaration
    public readonly bool IsValidAsWeaponHash { get; }
    Property Value
    Type Description
    Boolean
    | Improve this Doc View Source

    LocalizedName

    Declaration
    public readonly string LocalizedName { get; }
    Property Value
    Type Description
    String
    | Improve this Doc View Source

    NativeValue

    Gets the native representation of this WeaponAsset.

    Declaration
    public ulong NativeValue { get; set; }
    Property Value
    Type Description
    UInt64

    Methods

    | Improve this Doc View Source

    Equals(WeaponAsset)

    Declaration
    public bool Equals(WeaponAsset weaponAsset)
    Parameters
    Type Name Description
    WeaponAsset weaponAsset
    Returns
    Type Description
    Boolean
    | Improve this Doc View Source

    Equals(Object)

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    Object obj
    Returns
    Type Description
    Boolean
    Overrides
    ValueType.Equals(Object)
    | Improve this Doc View Source

    GetHashCode()

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    Int32
    Overrides
    ValueType.GetHashCode()
    | Improve this Doc View Source

    MarkAsNoLongerNeeded()

    Tells the game we have finished using this WeaponAsset and it can be freed from memory.

    Declaration
    public void MarkAsNoLongerNeeded()
    | Improve this Doc View Source

    Request()

    Attempts to load this WeaponAsset into memory.

    Declaration
    public void Request()
    | Improve this Doc View Source

    Request(Int32)

    Attempts to load this WeaponAsset into memory for a given period of time.

    Declaration
    public bool Request(int timeout)
    Parameters
    Type Name Description
    Int32 timeout

    The time (in milliseconds) before giving up trying to load this WeaponAsset.

    Returns
    Type Description
    Boolean

    true if this WeaponAsset is loaded; otherwise, false.

    | Improve this Doc View Source

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    String
    Overrides
    ValueType.ToString()

    Operators

    | Improve this Doc View Source

    Equality(WeaponAsset, WeaponAsset)

    Declaration
    public static bool operator ==(WeaponAsset left, WeaponAsset right)
    Parameters
    Type Name Description
    WeaponAsset left
    WeaponAsset right
    Returns
    Type Description
    Boolean
    | Improve this Doc View Source

    Implicit(WeaponAsset to InputArgument)

    Declaration
    public static implicit operator InputArgument(WeaponAsset value)
    Parameters
    Type Name Description
    WeaponAsset value
    Returns
    Type Description
    InputArgument
    | Improve this Doc View Source

    Implicit(WeaponHash to WeaponAsset)

    Declaration
    public static implicit operator WeaponAsset(WeaponHash hash)
    Parameters
    Type Name Description
    WeaponHash hash
    Returns
    Type Description
    WeaponAsset
    | Improve this Doc View Source

    Implicit(Int32 to WeaponAsset)

    Declaration
    public static implicit operator WeaponAsset(int hash)
    Parameters
    Type Name Description
    Int32 hash
    Returns
    Type Description
    WeaponAsset
    | Improve this Doc View Source

    Implicit(UInt32 to WeaponAsset)

    Declaration
    public static implicit operator WeaponAsset(uint hash)
    Parameters
    Type Name Description
    UInt32 hash
    Returns
    Type Description
    WeaponAsset
    | Improve this Doc View Source

    Inequality(WeaponAsset, WeaponAsset)

    Declaration
    public static bool operator !=(WeaponAsset left, WeaponAsset right)
    Parameters
    Type Name Description
    WeaponAsset left
    WeaponAsset right
    Returns
    Type Description
    Boolean

    Implements

    System.IEquatable<T>
    INativeValue
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX