2016-04-07 07:10:08 +00:00
|
|
|
#include "CDecalManager.hpp"
|
|
|
|
#include "CDecalDescription.hpp"
|
|
|
|
|
|
|
|
namespace urde
|
|
|
|
{
|
|
|
|
bool CDecalManager::m_PoolInitialized = false;
|
|
|
|
s32 CDecalManager::m_FreeIndex = 63;
|
|
|
|
float CDecalManager::m_DeltaTimeSinceLastDecalCreation = 0.f;
|
|
|
|
s32 CDecalManager::m_LastDecalCreatedIndex = -1;
|
2016-04-14 21:42:47 +00:00
|
|
|
ResId CDecalManager::m_LastDecalCreatedAssetId = -1;
|
2016-04-15 20:42:40 +00:00
|
|
|
rstl::reserved_vector<CDecalManager::SDecal, 64> CDecalManager::m_DecalPool;
|
|
|
|
rstl::reserved_vector<s32, 64> CDecalManager::m_ActiveIndexList;
|
2016-04-07 07:10:08 +00:00
|
|
|
|
|
|
|
void CDecalManager::Initialize()
|
|
|
|
{
|
|
|
|
if (m_PoolInitialized)
|
|
|
|
return;
|
|
|
|
|
|
|
|
m_DecalPool.clear();
|
|
|
|
m_DecalPool.resize(64);
|
|
|
|
|
|
|
|
m_FreeIndex = 63;
|
|
|
|
m_PoolInitialized = true;
|
|
|
|
m_DeltaTimeSinceLastDecalCreation = 0.f;
|
|
|
|
m_LastDecalCreatedIndex = -1;
|
|
|
|
m_LastDecalCreatedAssetId = -1;
|
|
|
|
}
|
|
|
|
}
|