mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-03-15 07:00:58 +00:00
Fixed loading empty ASE Models
This commit is contained in:
parent
72a737d992
commit
b60f3907fc
1 changed files with 6 additions and 2 deletions
|
@ -2272,8 +2272,12 @@ bool idRenderModelStatic::ConvertASEToModelSurfaces( const struct aseModel_s* as
|
|||
{
|
||||
object = ase->objects[objectNum];
|
||||
mesh = &object->mesh;
|
||||
material = ase->materials[object->materialRef];
|
||||
im1 = declManager->FindMaterial( material->name );
|
||||
//material = ase->materials[object->materialRef];
|
||||
//im1 = declManager->FindMaterial( material->name );
|
||||
//
|
||||
// caedes dhewm3 fix for ASE meshes without materials (a lot of Doom 3 mods have this issue) 05-18-2021
|
||||
material = (ase->materials.Num() > object->materialRef) ? ase->materials[object->materialRef] : NULL;
|
||||
im1 = declManager->FindMaterial(material ? material->name : NULL);
|
||||
|
||||
bool normalsParsed = mesh->normalsParsed;
|
||||
|
||||
|
|
Loading…
Reference in a new issue