From 56b80cb0ab37ff6e7d4f58bf75c9e096d854ef89 Mon Sep 17 00:00:00 2001 From: aap Date: Mon, 24 Aug 2020 17:21:45 +0200 Subject: fixes to zones and vehicle comp rules --- src/modelinfo/VehicleModelInfo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/modelinfo') diff --git a/src/modelinfo/VehicleModelInfo.cpp b/src/modelinfo/VehicleModelInfo.cpp index 68673458..5d69a921 100644 --- a/src/modelinfo/VehicleModelInfo.cpp +++ b/src/modelinfo/VehicleModelInfo.cpp @@ -211,7 +211,7 @@ CVehicleModelInfo::CreateInstance(void) clumpframe = RpClumpGetFrame(clump); comp1 = ChooseComponent(); - if(comp1 != -1){ + if(comp1 != -1 && m_comps[comp1]){ atomic = RpAtomicClone(m_comps[comp1]); f = RwFrameCreate(); RwFrameTransform(f, @@ -224,7 +224,7 @@ CVehicleModelInfo::CreateInstance(void) ms_compsUsed[0] = comp1; comp2 = ChooseSecondComponent(); - if(comp2 != -1){ + if(comp2 != -1 && m_comps[comp2]){ atomic = RpAtomicClone(m_comps[comp2]); f = RwFrameCreate(); RwFrameTransform(f, -- cgit v1.2.3