- if (modelname[0])
- sprintf (name, "%s%s", gamedir, modelname);
- else
- sprintf (name, "%s/tris.md2", cddir);
- printf ("saving to %s\n", name);
- CreatePath (name);
- modelouthandle = SafeOpenWrite (name);
-
- WriteModelFile (modelouthandle);
-
- printf ("%3dx%3d skin\n", model.skinwidth, model.skinheight);
- printf ("%4d vertexes\n", model.num_xyz);
- printf ("%4d triangles\n", model.num_tris);
- printf ("%4d frame\n", model.num_frames);
- printf ("%4d glverts\n", numglverts);
- printf ("%4d glcmd\n", model.num_glcmds);
- printf ("%4d skins\n", model.num_skins);
- printf ("file size: %d\n", (int)ftell (modelouthandle) );
- printf ("---------------------\n");
-
- fclose (modelouthandle);
+ if ( modelname[0] ) {
+ sprintf( name, "%s%s", gamedir, modelname );
+ }
+ else{
+ sprintf( name, "%s/tris.md2", cddir );
+ }
+ printf( "saving to %s\n", name );
+ CreatePath( name );
+ modelouthandle = SafeOpenWrite( name );
+
+ WriteModelFile( modelouthandle );
+
+ printf( "%3dx%3d skin\n", model.skinwidth, model.skinheight );
+ printf( "%4d vertexes\n", model.num_xyz );
+ printf( "%4d triangles\n", model.num_tris );
+ printf( "%4d frame\n", model.num_frames );
+ printf( "%4d glverts\n", numglverts );
+ printf( "%4d glcmd\n", model.num_glcmds );
+ printf( "%4d skins\n", model.num_skins );
+ printf( "file size: %d\n", (int)ftell( modelouthandle ) );
+ printf( "---------------------\n" );
+
+ fclose( modelouthandle );