From: Rudolf Polzer Date: Sat, 9 Oct 2010 17:37:43 +0000 (+0200) Subject: .ase also works from .map! X-Git-Tag: xonotic-v0.5.0~185 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=8442ecbb1499b4c22827ab4a46862965a037665b;p=xonotic%2Fnetradiant.git .ase also works from .map! --- diff --git a/tools/quake3/q3map2/convert_map.c b/tools/quake3/q3map2/convert_map.c index 69418854..0f37665d 100644 --- a/tools/quake3/q3map2/convert_map.c +++ b/tools/quake3/q3map2/convert_map.c @@ -493,7 +493,10 @@ static void ConvertBrush( FILE *f, int num, bspBrush_t *brush, vec3_t origin, qb if(strncmp(buildSide->shaderInfo->shader, "textures/common/", 16)) if(strcmp(buildSide->shaderInfo->shader, "noshader")) if(strcmp(buildSide->shaderInfo->shader, "default")) + { fprintf(stderr, "no matching triangle for brushside using %s (hopefully nobody can see this side anyway)\n", buildSide->shaderInfo->shader); + texture = "common/WTF"; + } MakeNormalVectors( buildPlane->normal, vecs[ 0 ], vecs[ 1 ] ); VectorMA( vec3_origin, buildPlane->dist, buildPlane->normal, pts[ 0 ] ); diff --git a/tools/quake3/q3map2/main.c b/tools/quake3/q3map2/main.c index 55147b3a..062e4693 100644 --- a/tools/quake3/q3map2/main.c +++ b/tools/quake3/q3map2/main.c @@ -1508,14 +1508,14 @@ int ConvertBSPMain( int argc, char **argv ) int i; int (*convertFunc)( char * ); game_t *convertGame; - qboolean map_allowed; char ext[1024]; + qboolean map_allowed; /* set default */ convertFunc = ConvertBSPToASE; convertGame = NULL; - map_allowed = qfalse; + map_allowed = qtrue; /* arg checking */ if( argc < 1 ) @@ -1534,6 +1534,7 @@ int ConvertBSPMain( int argc, char **argv ) if( !Q_stricmp( argv[ i ], "ase" ) ) { convertFunc = ConvertBSPToASE; + map_allowed = qtrue; } else if( !Q_stricmp( argv[ i ], "map_bp" ) ) { @@ -1548,6 +1549,7 @@ int ConvertBSPMain( int argc, char **argv ) else { convertGame = GetGame( argv[ i ] ); + map_allowed = qfalse; if( convertGame == NULL ) Sys_Printf( "Unknown conversion format \"%s\". Defaulting to ASE.\n", argv[ i ] ); }