utils: mdldec: boneweights fix.

This commit is contained in:
Andrey Akhmichin 2024-02-29 05:57:15 +05:00 committed by Alibek Omarov
parent 24f23908be
commit 505b6cc264
1 changed files with 6 additions and 4 deletions

View File

@ -601,6 +601,12 @@ void WriteQCScript( void )
fputs( "$scale 1.0\n", fp ); fputs( "$scale 1.0\n", fp );
fputs( "\n", fp ); fputs( "\n", fp );
if( model_hdr->flags & STUDIO_HAS_BONEINFO )
{
if( model_hdr->flags & STUDIO_HAS_BONEWEIGHTS )
fputs( "$boneweights\n\n", fp );
}
WriteBodyGroupInfo( fp ); WriteBodyGroupInfo( fp );
fprintf( fp, "$flags %u\n\n", model_hdr->flags &~( STUDIO_HAS_BONEINFO | STUDIO_HAS_BONEWEIGHTS ) ); fprintf( fp, "$flags %u\n\n", model_hdr->flags &~( STUDIO_HAS_BONEINFO | STUDIO_HAS_BONEWEIGHTS ) );
@ -611,10 +617,6 @@ void WriteQCScript( void )
WriteSkinFamilyInfo( fp ); WriteSkinFamilyInfo( fp );
WriteTextureRenderMode( fp ); WriteTextureRenderMode( fp );
if( model_hdr->flags & ( STUDIO_HAS_BONEINFO | STUDIO_HAS_BONEWEIGHTS ) )
fputs( "$boneweights\n\n", fp );
WriteAttachmentInfo( fp ); WriteAttachmentInfo( fp );
fprintf( fp, "$bbox %f %f %f", model_hdr->min[0], model_hdr->min[1], model_hdr->min[2] ); fprintf( fp, "$bbox %f %f %f", model_hdr->min[0], model_hdr->min[1], model_hdr->min[2] );