minor tweaks

This commit is contained in:
Garux 2020-01-24 02:47:33 +03:00
parent 854eb14a69
commit 09953b82be
4 changed files with 10 additions and 16 deletions

View File

@ -31,7 +31,7 @@
#include "ident.h"
#include "md3normals.h"
// the maximum size of game reletive pathnames
// the maximum size of game relative pathnames
#define MAX_QPATH 64
/*

View File

@ -113,7 +113,7 @@ void ExpandWildcards( int *argc, char ***argv ){
int handle;
int i;
char filename[1024];
char filebase[1024];
char filepath[1024];
char *path;
ex_argc = 0;
@ -131,11 +131,11 @@ void ExpandWildcards( int *argc, char ***argv ){
return;
}
ExtractFilePath( path, filebase );
ExtractFilePath( path, filepath );
do
{
sprintf( filename, "%s%s", filebase, fileinfo.name );
sprintf( filename, "%s%s", filepath, fileinfo.name );
ex_argv[ex_argc++] = copystring( filename );
} while ( _findnext( handle, &fileinfo ) != -1 );
@ -751,14 +751,11 @@ void DefaultExtension( char *path, const char *extension ){
void DefaultPath( char *path, const char *basepath ){
char temp[128];
if ( path[ 0 ] == '/' || path[ 0 ] == '\\' ) {
return; // absolute path location
if( !path_is_absolute( path ) ){
char* temp = strdup( path );
sprintf( path, "%s%s", basepath, temp );
free( temp );
}
strcpy( temp,path );
strcpy( path,basepath );
strcat( path,temp );
}

View File

@ -69,7 +69,7 @@ packheader_t pakheader;
==============
ReleaseFile
Filename should be gamedir reletive.
Filename should be gamedir relative.
Either copies the file to the release dir, or adds it to
the pak file.
==============

View File

@ -1010,7 +1010,7 @@ int ConvertBSPToMap_Ext( char *bspName, qboolean brushPrimitives ){
entity_t *e;
vec3_t origin;
const char *value;
char name[ 1024 ], base[ 1024 ];
char name[ 1024 ];
/* note it */
@ -1022,9 +1022,6 @@ int ConvertBSPToMap_Ext( char *bspName, qboolean brushPrimitives ){
strcat( name, "_converted.map" );
Sys_Printf( "writing %s\n", name );
ExtractFileBase( bspName, base );
strcat( base, ".bsp" );
/* open it */
f = fopen( name, "wb" );
if ( f == NULL ) {