little cleanup and synch on templates and config

This commit is contained in:
aap
2020-12-18 13:50:26 +01:00
parent 1af5065df7
commit a7050458ae
16 changed files with 91 additions and 83 deletions

View File

@ -88,7 +88,7 @@ CBaseModelInfo::Add2dEffect(C2dEffect *fx)
if(m_2dEffectsID >= 0)
m_num2dEffects++;
else{
m_2dEffectsID = CModelInfo::Get2dEffectStore().getIndex(fx);
m_2dEffectsID = CModelInfo::Get2dEffectStore().GetIndex(fx);
m_num2dEffects = 1;
}
}
@ -97,7 +97,7 @@ C2dEffect*
CBaseModelInfo::Get2dEffect(int n)
{
if(m_2dEffectsID >= 0)
return CModelInfo::Get2dEffectStore().getItem(m_2dEffectsID+n);
return CModelInfo::Get2dEffectStore().GetItem(m_2dEffectsID+n);
else
return nil;
}

View File

@ -33,13 +33,13 @@ CModelInfo::Initialise(void)
for(i = 0; i < MODELINFOSIZE; i++)
ms_modelInfoPtrs[i] = nil;
ms_2dEffectStore.clear();
ms_simpleModelStore.clear();
ms_timeModelStore.clear();
ms_weaponModelStore.clear();
ms_clumpModelStore.clear();
ms_pedModelStore.clear();
ms_vehicleModelStore.clear();
ms_2dEffectStore.Clear();
ms_simpleModelStore.Clear();
ms_timeModelStore.Clear();
ms_weaponModelStore.Clear();
ms_clumpModelStore.Clear();
ms_pedModelStore.Clear();
ms_vehicleModelStore.Clear();
m = AddSimpleModel(MI_CAR_DOOR);
m->SetColModel(&CTempColModels::ms_colModelDoor1);
@ -109,20 +109,20 @@ CModelInfo::ShutDown(void)
for(i = 0; i < ms_2dEffectStore.allocPtr; i++)
ms_2dEffectStore.store[i].Shutdown();
ms_2dEffectStore.clear();
ms_simpleModelStore.clear();
ms_timeModelStore.clear();
ms_weaponModelStore.clear();
ms_pedModelStore.clear();
ms_clumpModelStore.clear();
ms_vehicleModelStore.clear();
ms_2dEffectStore.Clear();
ms_simpleModelStore.Clear();
ms_timeModelStore.Clear();
ms_weaponModelStore.Clear();
ms_pedModelStore.Clear();
ms_clumpModelStore.Clear();
ms_vehicleModelStore.Clear();
}
CSimpleModelInfo*
CModelInfo::AddSimpleModel(int id)
{
CSimpleModelInfo *modelinfo;
modelinfo = CModelInfo::ms_simpleModelStore.alloc();
modelinfo = CModelInfo::ms_simpleModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->Init();
return modelinfo;
@ -132,7 +132,7 @@ CTimeModelInfo*
CModelInfo::AddTimeModel(int id)
{
CTimeModelInfo *modelinfo;
modelinfo = CModelInfo::ms_timeModelStore.alloc();
modelinfo = CModelInfo::ms_timeModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->Init();
return modelinfo;
@ -142,7 +142,7 @@ CWeaponModelInfo*
CModelInfo::AddWeaponModel(int id)
{
CWeaponModelInfo *modelinfo;
modelinfo = CModelInfo::ms_weaponModelStore.alloc();
modelinfo = CModelInfo::ms_weaponModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->Init();
return modelinfo;
@ -152,7 +152,7 @@ CClumpModelInfo*
CModelInfo::AddClumpModel(int id)
{
CClumpModelInfo *modelinfo;
modelinfo = CModelInfo::ms_clumpModelStore.alloc();
modelinfo = CModelInfo::ms_clumpModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->m_clump = nil;
return modelinfo;
@ -162,7 +162,7 @@ CPedModelInfo*
CModelInfo::AddPedModel(int id)
{
CPedModelInfo *modelinfo;
modelinfo = CModelInfo::ms_pedModelStore.alloc();
modelinfo = CModelInfo::ms_pedModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->m_clump = nil;
return modelinfo;
@ -172,7 +172,7 @@ CVehicleModelInfo*
CModelInfo::AddVehicleModel(int id)
{
CVehicleModelInfo *modelinfo;
modelinfo = CModelInfo::ms_vehicleModelStore.alloc();
modelinfo = CModelInfo::ms_vehicleModelStore.Alloc();
CModelInfo::ms_modelInfoPtrs[id] = modelinfo;
modelinfo->m_clump = nil;
modelinfo->m_vehicleType = -1;
@ -251,7 +251,7 @@ CModelInfo::IsPlaneModel(int32 id)
void
CModelInfo::ReInit2dEffects()
{
ms_2dEffectStore.clear();
ms_2dEffectStore.Clear();
for (int i = 0; i < MODELINFOSIZE; i++) {
if (ms_modelInfoPtrs[i])