mirror of
https://github.com/Mr-X-GTA/GTAV-Classes-1.git
synced 2024-12-22 22:47:32 +08:00
23 lines
236 B
C++
23 lines
236 B
C++
#pragma once
|
|
|
|
namespace rage
|
|
{
|
|
template <typename T>
|
|
struct atSingleton
|
|
{
|
|
private:
|
|
T* m_basePtr{};
|
|
|
|
public:
|
|
bool isValid() const
|
|
{
|
|
return m_basePtr != nullptr;
|
|
}
|
|
|
|
T* getInstance()
|
|
{
|
|
return m_basePtr;
|
|
}
|
|
};
|
|
}
|