diff --git a/scripts/buildAssets.ts b/scripts/buildAssets.ts index c4cae1de1..c9f6d2c1e 100644 --- a/scripts/buildAssets.ts +++ b/scripts/buildAssets.ts @@ -517,8 +517,8 @@ if (allTargets || targets?.includes('tankModels')) { // if (id !== 24609) continue; // concept 1b // if (id !== 4417) continue; // amx m4 mle // if (id !== 7297) continue; // 60tp - // if (id !== 1) continue; // t-34 - if (id !== 6753) continue; // type 71 + if (id !== 1) continue; // t-34 + // if (id !== 6753) continue; // type 71 // if (id !== 5137) continue; // tiger ii // if (id !== 6225) continue; // fv215b diff --git a/src/core/blitz/extractModel.ts b/src/core/blitz/extractModel.ts index d3e961a26..89279dea4 100644 --- a/src/core/blitz/extractModel.ts +++ b/src/core/blitz/extractModel.ts @@ -35,6 +35,8 @@ const vertexAttributeGltfVectorSizes = { [VertexAttribute.TANGENT]: 4, } as const; +const omitNames = ['chassis_chassis_', 'chassis_track_crash_', 'HP_']; + export async function extractModel( data: string, path: string, @@ -143,6 +145,8 @@ export async function extractModel( function parseHierarchies(hierarchies: Hierarchy[], parent: Scene | Node) { hierarchies.forEach((hierarchy) => { + if (omitNames.some((omit) => hierarchy.name.startsWith(omit))) return; + const node = document.createNode(hierarchy.name); const components = times( hierarchy.components.count, @@ -314,7 +318,7 @@ export async function extractModel( // rotate 90 degrees on the x axis const rootNode = document - .createNode() + .createNode('root') .setRotation([Math.cos(Math.PI / 4), 0, 0, -Math.sin(Math.PI / 4)]); scene.addChild(rootNode); diff --git a/src/core/streams/dds.ts b/src/core/streams/dds.ts index a8efb0423..9855b8bd2 100644 --- a/src/core/streams/dds.ts +++ b/src/core/streams/dds.ts @@ -277,6 +277,9 @@ export class DdsStream extends WindowsStream { resolveDxgiFormat(header: ReturnType) { switch (header.pf.fourCC) { + case 'DXT1': + return DxgiFormat.BC1_UNORM; + case 'DXT3': return DxgiFormat.BC2_UNORM;