M&B: Bannerlord 1.0.0
The horns sound, the ravens gather.
Loading...
Searching...
No Matches
TaleWorlds.ObjectSystem.MBGUID Struct Reference

Represents the ID and type of an object, packed in 32 bits

Inherits IComparable, and IEquatable< MBGUID >.

Public Member Functions

 MBGUID (uint id)
 Initializes a new instance of the MMOGUID struct. Should contain 4 bits of type information, then 28 bits of sub ID. More...
 
 MBGUID (uint objType, uint subId)
 Initializes a new instance of the MMOGUID struct. More...
 
int CompareTo (object a)
 Compares an object with this MMOGUID More...
 
uint GetTypeIndex ()
 
override int GetHashCode ()
 Hash code override More...
 
override string ToString ()
 
override bool Equals (object obj)
 Compares an object with this MMOGUID More...
 
bool Equals (MBGUID other)
 

Static Public Member Functions

static bool operator== (MBGUID id1, MBGUID id2)
 Compares two MMOGUIDS More...
 
static bool operator!= (MBGUID id1, MBGUID id2)
 Compares two MMOGUIDS More...
 
static bool operator< (MBGUID id1, MBGUID id2)
 
static bool operator> (MBGUID id1, MBGUID id2)
 
static bool operator<= (MBGUID id1, MBGUID id2)
 
static bool operator>= (MBGUID id1, MBGUID id2)
 
static long GetHash2 (MBGUID id1, MBGUID id2)
 

Properties

uint InternalValue [get]
 Gets the internal int value More...
 
uint SubId [get]
 Gets the ID of the object. More...
 

Constructor & Destructor Documentation

◆ MBGUID() [1/2]

TaleWorlds.ObjectSystem.MBGUID.MBGUID ( uint  id)
Parameters
idinternal ID of the object

◆ MBGUID() [2/2]

TaleWorlds.ObjectSystem.MBGUID.MBGUID ( uint  objType,
uint  subId 
)
Parameters
objTypeType of the object
subIdID of the object

Member Function Documentation

◆ operator==()

static bool TaleWorlds.ObjectSystem.MBGUID.operator== ( MBGUID  id1,
MBGUID  id2 
)
static
Parameters
id1An MMOGUID object 1
id2An MMOGUID object 2
Returns
True if type and ID is equal, false otherwise

◆ operator!=()

static bool TaleWorlds.ObjectSystem.MBGUID.operator!= ( MBGUID  id1,
MBGUID  id2 
)
static
Parameters
id1An MMOGUID object 1
id2An MMOGUID object 2
Returns
False if type and ID is equal, true otherwise

◆ operator<()

static bool TaleWorlds.ObjectSystem.MBGUID.operator< ( MBGUID  id1,
MBGUID  id2 
)
static

◆ operator>()

static bool TaleWorlds.ObjectSystem.MBGUID.operator> ( MBGUID  id1,
MBGUID  id2 
)
static

◆ operator<=()

static bool TaleWorlds.ObjectSystem.MBGUID.operator<= ( MBGUID  id1,
MBGUID  id2 
)
static

◆ operator>=()

static bool TaleWorlds.ObjectSystem.MBGUID.operator>= ( MBGUID  id1,
MBGUID  id2 
)
static

◆ GetHash2()

static long TaleWorlds.ObjectSystem.MBGUID.GetHash2 ( MBGUID  id1,
MBGUID  id2 
)
static

◆ CompareTo()

int TaleWorlds.ObjectSystem.MBGUID.CompareTo ( object  a)
Parameters
aMMOGUID object to be compared
Returns
0 if equal, 1 if greater, -1 if less. Throws if object is not MMOGUID

◆ GetTypeIndex()

uint TaleWorlds.ObjectSystem.MBGUID.GetTypeIndex ( )

◆ GetHashCode()

override int TaleWorlds.ObjectSystem.MBGUID.GetHashCode ( )
Returns
Hash code of the object

◆ ToString()

override string TaleWorlds.ObjectSystem.MBGUID.ToString ( )

◆ Equals() [1/2]

override bool TaleWorlds.ObjectSystem.MBGUID.Equals ( object  obj)
Parameters
objMMOGUID object to be compared
Returns
True if equal, false otherwise. Throws if object is not MMOGUID

◆ Equals() [2/2]

bool TaleWorlds.ObjectSystem.MBGUID.Equals ( MBGUID  other)

Property Documentation

◆ InternalValue

uint TaleWorlds.ObjectSystem.MBGUID.InternalValue
get

◆ SubId

uint TaleWorlds.ObjectSystem.MBGUID.SubId
get