Photon Fusion 2.0.0

Classes | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Properties | List of all members
NetworkPrefabRef Struct Reference

NetworkPrefabRef. More...

Inherits INetworkStruct, IEquatable< NetworkPrefabRef >, and IComparable< NetworkPrefabRef >.

Classes

class  EqualityComparer
 EqualityComparer for NetworkPrefabRef. More...
 

Public Member Functions

int CompareTo (NetworkPrefabRef other)
 Compare the NetworkPrefabRef to another NetworkPrefabRef.
 
bool Equals (NetworkPrefabRef other)
 Check if the NetworkPrefabRef is equal to another NetworkPrefabRef.
 
override bool Equals (object obj)
 Check if the NetworkPrefabRef is equal to another object.
 
override int GetHashCode ()
 Get the hashcode for a NetworkPrefabRef.
 
 NetworkPrefabRef (byte *guid)
 Create a NetworkPrefabRef from a byte*.
 
 NetworkPrefabRef (byte[] guid)
 Create a NetworkPrefabRef from a byte array.
 
 NetworkPrefabRef (long data0, long data1)
 Create a new NetworkPrefabRef.
 
 NetworkPrefabRef (string guid)
 Create a new NetworkPrefabRef.
 
override string ToString ()
 Returns a string representation of the NetworkPrefabRef.
 
string ToString (string format)
 Returns a string representation of the NetworkPrefabRef.
 
string ToUnityGuidString ()
 Returns a string representation of the NetworkPrefabRef.
 

Static Public Member Functions

static implicit operator Guid (NetworkPrefabRef guid)
 Implicit conversion from NetworkPrefabRef to Guid.
 
static operator NetworkObjectGuid (NetworkPrefabRef t)
 Explicit conversion from NetworkPrefabRef to NetworkObjectGuid.
 
static implicit operator NetworkPrefabRef (Guid guid)
 Implicit conversion from Guid to NetworkPrefabRef.
 
static bool operator!= (NetworkPrefabRef a, NetworkPrefabRef b)
 Compare two NetworkPrefabRef.
 
static bool operator== (NetworkPrefabRef a, NetworkPrefabRef b)
 Compare two NetworkPrefabRef.
 
static NetworkPrefabRef Parse (string str)
 Parse a NetworkPrefabRef from a string.
 
static bool TryParse (string str, out NetworkPrefabRef guid)
 Try to parse a string into a NetworkPrefabRef.
 

Public Attributes

fixed long RawGuidValue [2]
 The Raw Guid Value of the NetworkPrefabRef.
 

Static Public Attributes

const int ALIGNMENT = 4
 The alignment of the NetworkPrefabRef.
 
const int SIZE = 16
 The Size of the NetworkPrefabRef in bytes.
 

Properties

static NetworkPrefabRef Empty [get]
 The default value of a NetworkPrefabRef.
 
bool IsValid [get]
 Signal if the NetworkPrefabRef is valid.
 

Detailed Description

NetworkPrefabRef.

A decoupled NetworkObject prefab reference. Internally stored as a GUID.

Constructor & Destructor Documentation

◆ NetworkPrefabRef() [1/4]

NetworkPrefabRef ( string  guid)

Create a new NetworkPrefabRef.

Parameters
guidThe guid to use

◆ NetworkPrefabRef() [2/4]

NetworkPrefabRef ( long  data0,
long  data1 
)

Create a new NetworkPrefabRef.

Parameters
data0Data0 of the Guid
data1Data1 of the Guid

◆ NetworkPrefabRef() [3/4]

NetworkPrefabRef ( byte[]  guid)

Create a NetworkPrefabRef from a byte array.

Parameters
guidThe byte array to create the NetworkPrefabRef from

◆ NetworkPrefabRef() [4/4]

NetworkPrefabRef ( byte *  guid)

Create a NetworkPrefabRef from a byte*.

Parameters
guidThe byte* to create the NetworkPrefabRef from

Member Function Documentation

◆ CompareTo()

int CompareTo ( NetworkPrefabRef  other)

Compare the NetworkPrefabRef to another NetworkPrefabRef.

Parameters
otherThe other NetworkPrefabRef to compare against
Returns
0 if the NetworkPrefabRef are equal, -1 if this NetworkPrefabRef is less than the other, 1 if this NetworkPrefabRef is greater than the other

◆ Equals() [1/2]

bool Equals ( NetworkPrefabRef  other)

Check if the NetworkPrefabRef is equal to another NetworkPrefabRef.

Parameters
otherThe other NetworkPrefabRef to check against
Returns
True if the NetworkPrefabRefs are equal, false otherwise

◆ Equals() [2/2]

override bool Equals ( object  obj)

Check if the NetworkPrefabRef is equal to another object.

Parameters
objThe other object to check against
Returns
True if the objects are equal, false otherwise

◆ operator Guid()

static implicit operator Guid ( NetworkPrefabRef  guid)
static

Implicit conversion from NetworkPrefabRef to Guid.

Parameters
guidNetworkPrefabRef to convert from
Returns
Guid

◆ operator NetworkObjectGuid()

static operator NetworkObjectGuid ( NetworkPrefabRef  t)
explicitstatic

Explicit conversion from NetworkPrefabRef to NetworkObjectGuid.

Parameters
tNetworkPrefabRef to convert from
Returns
NetworkObjectGuid

◆ operator NetworkPrefabRef()

static implicit operator NetworkPrefabRef ( Guid  guid)
static

Implicit conversion from Guid to NetworkPrefabRef.

Parameters
guidGuid to convert from
Returns
NetworkPrefabRef

◆ operator!=()

static bool operator!= ( NetworkPrefabRef  a,
NetworkPrefabRef  b 
)
static

Compare two NetworkPrefabRef.

Returns
True if the NetworkPrefabRef are not equal, false otherwise

◆ operator==()

static bool operator== ( NetworkPrefabRef  a,
NetworkPrefabRef  b 
)
static

Compare two NetworkPrefabRef.

Returns
True if the NetworkPrefabRef are equal, false otherwise

◆ Parse()

static NetworkPrefabRef Parse ( string  str)
static

Parse a NetworkPrefabRef from a string.

Parameters
strThe string to parse.
Returns
The parsed NetworkPrefabRef.

◆ TryParse()

static bool TryParse ( string  str,
out NetworkPrefabRef  guid 
)
static

Try to parse a string into a NetworkPrefabRef.

Parameters
strString to parse
guidParsed NetworkPrefabRef
Returns
True if the string was parsed successfully, false otherwise