修复:未设置材质时,无法发送吊顶到渲染器

pull/2362/MERGE
ChenX 1 year ago
parent 0629d55bfb
commit 2dd054b210

@ -855,7 +855,7 @@ export function ConverBulkheadCeiling2Data(ent: BulkheadCeiling)
for (let i = 0; i < cd.Materials.length; i++)
{
let mtl = cd.OverWriteMaterial?.get(i) ?? cd.Materials[i];
materials.push(mtl.Index);
materials.push(mtl?.Index ?? 71);
}
}
ed.Materials = materials;

@ -274,14 +274,14 @@ async function ParseModel(model: KJL_ParamModel,
en.HardwareOption.comments = hmodel.modelProductNumber ?? "";
ParseHardwareParam(en, hmodel);
}
en.ApplyMatrix(new Matrix4().premultiply(mtx));
en.ApplyMatrix(mtx);
}
return template;
}
else
{
let hw = CreateHardware(hmodel, roomName, gName);
hw.ApplyMatrix(new Matrix4().premultiply(mtx));
hw.ApplyMatrix(mtx);
app.Database.ModelSpace.Append(hw);
return hw;
}

Loading…
Cancel
Save