omit "./" prefix from media file paths in map config files

Ignore it, if "./" prefixes a media path given with a texture, mapmodel
or mapsound command. It's useless and prevents comparing path names.
This commit is contained in:
ac-stef
2016-09-06 19:15:26 +02:00
parent a5470d5ea0
commit 423df0c66f
3 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -128,7 +128,7 @@ void mapmodel(int *rad, int *h, int *zoff, char *scale, char *name)
mmi.m = NULL;
filtertext(name, name, FTXT__MEDIAFILEPATH);
formatstring(mmi.name)("%s%s", mmpath, name);
formatstring(mmi.name)("%s%s", mmpath, name[0] == '.' && name[1] == '/' ? name + 2 : name);
mapmodelchanged = 1;
flagmapconfigchange();
}