Merge branch 'VitaminCpp-replication_hashing_fix'
This commit is contained in:
@@ -152,12 +152,12 @@ struct NetworkReplicatedObject
|
|||||||
|
|
||||||
bool operator==(const NetworkReplicatedObject& other) const
|
bool operator==(const NetworkReplicatedObject& other) const
|
||||||
{
|
{
|
||||||
return Object == other.Object;
|
return ObjectId == other.ObjectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool operator==(const ScriptingObject* other) const
|
bool operator==(const ScriptingObject* other) const
|
||||||
{
|
{
|
||||||
return Object == other;
|
return other && ObjectId == other->GetID();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool operator==(const Guid& other) const
|
bool operator==(const Guid& other) const
|
||||||
@@ -176,6 +176,11 @@ inline uint32 GetHash(const NetworkReplicatedObject& key)
|
|||||||
return GetHash(key.ObjectId);
|
return GetHash(key.ObjectId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline uint32 GetHash(const ScriptingObject* key)
|
||||||
|
{
|
||||||
|
return key ? GetHash(key->GetID()) : 0;
|
||||||
|
}
|
||||||
|
|
||||||
struct Serializer
|
struct Serializer
|
||||||
{
|
{
|
||||||
NetworkReplicator::SerializeFunc Methods[2];
|
NetworkReplicator::SerializeFunc Methods[2];
|
||||||
|
|||||||
Reference in New Issue
Block a user