mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-08 13:44:56 +00:00
Proper CRandom16 usage
More CScriptGunTurret imps
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
namespace urde
|
||||
{
|
||||
CRandom16 CDecal::sDecalRandom(99);
|
||||
CRandom16 CDecal::sDecalRandom;
|
||||
bool CDecal::sMoveRedToAlphaBuffer = false;
|
||||
|
||||
CDecal::CDecal(const TToken<CDecalDescription>& desc, const zeus::CTransform& xf)
|
||||
|
||||
@@ -33,7 +33,7 @@ CDecalDescription* CDecalDataFactory::CreateGeneratorDescription(CInputStream& i
|
||||
|
||||
bool CDecalDataFactory::CreateDPSM(CDecalDescription* desc, CInputStream& in, CSimplePool* resPool)
|
||||
{
|
||||
CRandom16 rand{99};
|
||||
CRandom16 rand;
|
||||
CGlobalRandom gr{rand};
|
||||
FourCC clsId = CPF::GetClassID(in);
|
||||
|
||||
|
||||
@@ -70,6 +70,7 @@ CElementGen::CElementGen(const TToken<CGenDescription>& gen,
|
||||
if (desc->x58_x44_TIND)
|
||||
desc->x58_x44_TIND->GetValueTexture(0).GetObj();
|
||||
|
||||
CGlobalRandom globRnd(x27c_randState);
|
||||
if (CIntElement* seedElem = desc->x1c_x10_SEED.get())
|
||||
{
|
||||
int seedVal;
|
||||
|
||||
@@ -858,7 +858,7 @@ CGenDescription* CParticleDataFactory::CreateGeneratorDescription(CInputStream&
|
||||
bool CParticleDataFactory::CreateGPSM(CGenDescription* fillDesc, CInputStream& in,
|
||||
std::vector<CAssetId>& tracker, CSimplePool* resPool)
|
||||
{
|
||||
CRandom16 rand{99};
|
||||
CRandom16 rand;
|
||||
CGlobalRandom gr(rand);
|
||||
FourCC clsId = GetClassID(in);
|
||||
while (clsId != SBIG('_END'))
|
||||
|
||||
@@ -34,7 +34,7 @@ CElectricDescription* CParticleElectricDataFactory::CreateElectricDescription(CI
|
||||
|
||||
bool CParticleElectricDataFactory::CreateELSM(CElectricDescription* desc, CInputStream& in, CSimplePool* resPool)
|
||||
{
|
||||
CRandom16 rand{99};
|
||||
CRandom16 rand;
|
||||
CGlobalRandom gr{rand};
|
||||
|
||||
FourCC clsId = CPF::GetClassID(in);
|
||||
|
||||
@@ -33,7 +33,7 @@ CSwooshDescription* CParticleSwooshDataFactory::CreateGeneratorDescription(CInpu
|
||||
|
||||
bool CParticleSwooshDataFactory::CreateWPSM(CSwooshDescription* desc, CInputStream& in, CSimplePool* resPool)
|
||||
{
|
||||
CRandom16 rand{99};
|
||||
CRandom16 rand;
|
||||
FourCC clsId = CPF::GetClassID(in);
|
||||
while (clsId != SBIG('_END'))
|
||||
{
|
||||
|
||||
@@ -34,7 +34,7 @@ CWeaponDescription* CProjectileWeaponDataFactory::CreateGeneratorDescription(CIn
|
||||
|
||||
bool CProjectileWeaponDataFactory::CreateWPSM(CWeaponDescription* desc, CInputStream& in, CSimplePool* resPool)
|
||||
{
|
||||
CRandom16 rand{99};
|
||||
CRandom16 rand;
|
||||
CGlobalRandom gr{rand};
|
||||
FourCC clsId = CPF::GetClassID(in);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user