diff --git a/Editor/ProjectResourceFactory.cpp b/Editor/ProjectResourceFactory.cpp index eb70c4513..9e5fedd05 100644 --- a/Editor/ProjectResourceFactory.cpp +++ b/Editor/ProjectResourceFactory.cpp @@ -46,6 +46,7 @@ std::unique_ptr ProjectResourceFactory::Build(const pshag::SObjectT if (search == m_resPaths.end()) return {}; + fprintf(stderr, "Loading resource %s\n", search->second.getRelativePath().c_str()); Athena::io::FileReader fr(search->second.getAbsolutePath(), 32 * 1024, false); if (fr.hasError()) return {}; diff --git a/Runtime/Particle/CParticleGlobals.cpp b/Runtime/Particle/CParticleGlobals.cpp index f15e24408..c23c94ee4 100644 --- a/Runtime/Particle/CParticleGlobals.cpp +++ b/Runtime/Particle/CParticleGlobals.cpp @@ -13,6 +13,6 @@ int CParticleGlobals::g_ParticleLifetimePercentage = 0; float CParticleGlobals::g_ParticleLifetimePercentageReal = 0.0; float CParticleGlobals::g_ParticleLifetimePercentageRemainder = 0.0; -float* CParticleGlobals::g_papValues = nullptr; +float CParticleGlobals::g_papValues[8] = { 0.f }; CParticleGlobals::SParticleSystem* CParticleGlobals::g_currentParticleSystem = nullptr; } diff --git a/Runtime/Particle/CParticleGlobals.hpp b/Runtime/Particle/CParticleGlobals.hpp index 98feb7b76..33b4c2c42 100644 --- a/Runtime/Particle/CParticleGlobals.hpp +++ b/Runtime/Particle/CParticleGlobals.hpp @@ -38,7 +38,7 @@ public: g_ParticleLifetimePercentageRemainder = g_ParticleLifetimePercentageReal - g_ParticleLifetimePercentage; } - static float* g_papValues; + static float g_papValues[8]; struct SParticleSystem { diff --git a/Runtime/Particle/CRealElement.cpp b/Runtime/Particle/CRealElement.cpp index bb3936798..8258cec0f 100644 --- a/Runtime/Particle/CRealElement.cpp +++ b/Runtime/Particle/CRealElement.cpp @@ -1,6 +1,7 @@ #include "CRealElement.hpp" #include "CParticleGlobals.hpp" #include "CRandom16.hpp" +#include "CElementGen.hpp" #include namespace pshag @@ -228,63 +229,63 @@ bool CRECompareEquals::GetValue(int frame, float& valOut) const return false; } -bool CREParticleAccessParam1::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam1::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[0]; + valOut = CParticleGlobals::g_papValues[0]; return false; } -bool CREParticleAccessParam2::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam2::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[1]; + valOut = CParticleGlobals::g_papValues[1]; return false; } -bool CREParticleAccessParam3::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam3::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[2]; + valOut = CParticleGlobals::g_papValues[2]; return false; } -bool CREParticleAccessParam4::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam4::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[3]; + valOut = CParticleGlobals::g_papValues[3]; return false; } -bool CREParticleAccessParam5::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam5::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[4]; + valOut = CParticleGlobals::g_papValues[4]; return false; } -bool CREParticleAccessParam6::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam6::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[5]; + valOut = CParticleGlobals::g_papValues[5]; return false; } -bool CREParticleAccessParam7::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam7::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[6]; + valOut = CParticleGlobals::g_papValues[6]; return false; } -bool CREParticleAccessParam8::GetValue(int frame, float& valOut) const +bool CREParticleAccessParam8::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_papValues[7]; + valOut = CParticleGlobals::g_papValues[7]; return false; } -bool CREPSLL::GetValue(int frame, float& valOut) const +bool CREPSLL::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_particleMetrics->x2c_psll; + valOut = CElementGen::g_currentParticle->x2c_lineLengthOrSize; return false; } -bool CREPRLW::GetValue(int frame, float& valOut) const +bool CREPRLW::GetValue(int /*frame*/, float& valOut) const { - //valOut = CParticleGlobals::g_particleMetrics->x30_prlw; + valOut = CElementGen::g_currentParticle->x30_lineWidthOrRota; return false; }