Fixes deathmatch/map caching for loc files (still needs 'deathmatch' set to load locs automagically).

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2164 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2006-04-05 21:52:22 +00:00
parent c574d3d6f3
commit 6b8fac1fa4
1 changed files with 6 additions and 2 deletions

View File

@ -1910,11 +1910,15 @@ void TP_NewMap (void)
if (strcmp(host_mapname.string, last_map))
{ // map name has changed
loc_numentries = 0; // clear loc file
if (tp_loadlocs.value && cl.deathmatch && !cls.demoplayback) {
if (tp_loadlocs.value && cl.deathmatch && !cls.demoplayback)
{
Q_snprintfz (locname, sizeof(locname), "%s.loc", host_mapname.string);
TP_LoadLocFile (locname, true);
strlcpy (last_map, host_mapname.string, sizeof(last_map));
}
strlcpy (last_map, host_mapname.string, sizeof(last_map));
else
strlcpy (last_map, "", sizeof(last_map));
}
TP_ExecTrigger ("f_newmap");