mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 02:42:22 +01:00
fix s3, fix health + backpack bug on 1.11, change replciation, fix 7.20 & 12.61, fix backpack on >S9, probably some other stuff i forgot
36 lines
622 B
C++
36 lines
622 B
C++
#pragma once
|
|
|
|
template< class ObjectType>
|
|
class TSharedPtr
|
|
{
|
|
public:
|
|
ObjectType* Object;
|
|
|
|
int32 SharedReferenceCount;
|
|
int32 WeakReferenceCount;
|
|
|
|
FORCEINLINE ObjectType* Get()
|
|
{
|
|
return Object;
|
|
}
|
|
FORCEINLINE ObjectType* Get() const
|
|
{
|
|
return Object;
|
|
}
|
|
FORCEINLINE ObjectType& operator*()
|
|
{
|
|
return *Object;
|
|
}
|
|
FORCEINLINE const ObjectType& operator*() const
|
|
{
|
|
return *Object;
|
|
}
|
|
FORCEINLINE ObjectType* operator->()
|
|
{
|
|
return Object;
|
|
}
|
|
FORCEINLINE ObjectType* operator->() const
|
|
{
|
|
return Object;
|
|
}
|
|
}; |