mirror of
https://github.com/halpz/re3.git
synced 2025-07-22 00:09:45 +00:00
Use original names
This commit is contained in:
@ -54,8 +54,8 @@ public:
|
||||
bool IsClump(void) { return m_type == MITYPE_CLUMP || m_type == MITYPE_PED || m_type == MITYPE_VEHICLE ||
|
||||
m_type == MITYPE_MLO || m_type == MITYPE_XTRACOMPS; // unused but what the heck
|
||||
}
|
||||
char *GetName(void) { return m_name; }
|
||||
void SetName(const char *name) { strncpy(m_name, name, MAX_MODEL_NAME); }
|
||||
char *GetModelName(void) { return m_name; }
|
||||
void SetModelName(const char *name) { strncpy(m_name, name, MAX_MODEL_NAME); }
|
||||
void SetColModel(CColModel *col, bool owns = false){
|
||||
m_colModel = col; m_bOwnsColModel = owns; }
|
||||
CColModel *GetColModel(void) { return m_colModel; }
|
||||
|
@ -112,7 +112,7 @@ CClumpModelInfo::SetClump(RpClump *clump)
|
||||
}
|
||||
RpHAnimHierarchySetFlags(hier, (RpHAnimHierarchyFlag)(rpHANIMHIERARCHYUPDATEMODELLINGMATRICES|rpHANIMHIERARCHYUPDATELTMS));
|
||||
}
|
||||
if(strcmp(GetName(), "playerh") == 0){
|
||||
if(strcmp(GetModelName(), "playerh") == 0){
|
||||
// playerh is incompatible with the xbox player skin
|
||||
// so check if player model is skinned and only apply skin to head if it isn't
|
||||
CPedModelInfo *body = (CPedModelInfo*)CModelInfo::GetModelInfo(MI_PLAYER);
|
||||
@ -120,7 +120,7 @@ CClumpModelInfo::SetClump(RpClump *clump)
|
||||
RpClumpForAllAtomics(clump, SetAtomicRendererCB, (void*)CVisibilityPlugins::RenderPlayerCB);
|
||||
}
|
||||
#else
|
||||
if(strcmp(GetName(), "playerh") == 0){
|
||||
if(strcmp(GetModelName(), "playerh") == 0){
|
||||
RpClumpForAllAtomics(clump, SetAtomicRendererCB, (void*)CVisibilityPlugins::RenderPlayerCB);
|
||||
#endif
|
||||
}
|
||||
|
@ -192,7 +192,7 @@ CModelInfo::GetModelInfo(const char *name, int *id)
|
||||
CBaseModelInfo *modelinfo;
|
||||
for(int i = 0; i < MODELINFOSIZE; i++){
|
||||
modelinfo = CModelInfo::ms_modelInfoPtrs[i];
|
||||
if(modelinfo && !CGeneral::faststricmp(modelinfo->GetName(), name)){
|
||||
if(modelinfo && !CGeneral::faststricmp(modelinfo->GetModelName(), name)){
|
||||
if(id)
|
||||
*id = i;
|
||||
return modelinfo;
|
||||
|
@ -97,7 +97,7 @@ CPedModelInfo::SetClump(RpClump *clump)
|
||||
#endif
|
||||
#ifdef PED_SKIN
|
||||
// CB has to be set here before atomics are detached from clump
|
||||
if(strcmp(GetName(), "player") == 0)
|
||||
if(strcmp(GetModelName(), "player") == 0)
|
||||
RpClumpForAllAtomics(clump, SetAtomicRendererCB, (void*)CVisibilityPlugins::RenderPlayerCB);
|
||||
if(IsClumpSkinned(clump)){
|
||||
LimbCBarg limbs = { this, clump, { 0, 0, 0 } };
|
||||
@ -108,7 +108,7 @@ CPedModelInfo::SetClump(RpClump *clump)
|
||||
if(m_hitColModel == nil && !IsClumpSkinned(clump))
|
||||
CreateHitColModel();
|
||||
// And again because CClumpModelInfo resets it
|
||||
if(strcmp(GetName(), "player") == 0)
|
||||
if(strcmp(GetModelName(), "player") == 0)
|
||||
RpClumpForAllAtomics(m_clump, SetAtomicRendererCB, (void*)CVisibilityPlugins::RenderPlayerCB);
|
||||
else if(IsClumpSkinned(clump))
|
||||
// skinned peds have no low detail version, so they don't have the right render Cb
|
||||
@ -118,7 +118,7 @@ CPedModelInfo::SetClump(RpClump *clump)
|
||||
SetFrameIds(m_pPedIds);
|
||||
if(m_hitColModel == nil)
|
||||
CreateHitColModel();
|
||||
if(strcmp(GetName(), "player") == 0)
|
||||
if(strcmp(GetModelName(), "player") == 0)
|
||||
RpClumpForAllAtomics(m_clump, SetAtomicRendererCB, (void*)CVisibilityPlugins::RenderPlayerCB);
|
||||
#endif
|
||||
}
|
||||
|
@ -143,7 +143,7 @@ CSimpleModelInfo::FindRelatedModel(void)
|
||||
for(i = 0; i < MODELINFOSIZE; i++){
|
||||
mi = CModelInfo::GetModelInfo(i);
|
||||
if(mi && mi != this &&
|
||||
!CGeneral::faststrcmp(GetName()+3, mi->GetName()+3)){
|
||||
!CGeneral::faststrcmp(GetModelName()+3, mi->GetModelName()+3)){
|
||||
assert(mi->IsSimple());
|
||||
this->SetRelatedModel((CSimpleModelInfo*)mi);
|
||||
return;
|
||||
|
@ -11,7 +11,7 @@ CTimeModelInfo::FindOtherTimeModel(void)
|
||||
char *p;
|
||||
int i;
|
||||
|
||||
strcpy(name, GetName());
|
||||
strcpy(name, GetModelName());
|
||||
// change _nt to _dy
|
||||
if(p = strstr(name, "_nt"))
|
||||
strncpy(p, "_dy", 4);
|
||||
@ -24,7 +24,7 @@ CTimeModelInfo::FindOtherTimeModel(void)
|
||||
for(i = 0; i < MODELINFOSIZE; i++){
|
||||
CBaseModelInfo *mi = CModelInfo::GetModelInfo(i);
|
||||
if (mi && mi->GetModelType() == MITYPE_TIME &&
|
||||
!CGeneral::faststrncmp(name, mi->GetName(), MAX_MODEL_NAME)){
|
||||
!CGeneral::faststrncmp(name, mi->GetModelName(), MAX_MODEL_NAME)){
|
||||
m_otherTimeModelID = i;
|
||||
return (CTimeModelInfo*)mi;
|
||||
}
|
||||
|
Reference in New Issue
Block a user