mirror of
https://github.com/DrBeef/Raze.git
synced 2025-01-18 23:21:43 +00:00
- added the resource file name to the listmaps printout.
This commit is contained in:
parent
c17808d789
commit
25d79285a3
2 changed files with 11 additions and 2 deletions
|
@ -1446,7 +1446,7 @@ const char *FileSystem::GetResourceFileName (int rfnum) const noexcept
|
||||||
|
|
||||||
name = Files[rfnum]->FileName;
|
name = Files[rfnum]->FileName;
|
||||||
slash = strrchr (name, '/');
|
slash = strrchr (name, '/');
|
||||||
return slash != NULL ? slash+1 : name;
|
return (slash != NULL && slash[1] != 0) ? slash+1 : name;
|
||||||
}
|
}
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
|
@ -55,7 +55,16 @@ CCMD(listmaps)
|
||||||
{
|
{
|
||||||
for (unsigned int i = 0; i < numUsedSlots; i++)
|
for (unsigned int i = 0; i < numUsedSlots; i++)
|
||||||
{
|
{
|
||||||
Printf("%s - %s\n", mapList[i].fileName.GetChars(), mapList[i].DisplayName());
|
int lump = fileSystem.FindFile(mapList[i].fileName);
|
||||||
|
if (lump >= 0)
|
||||||
|
{
|
||||||
|
int rfnum = fileSystem.GetFileContainer(lump);
|
||||||
|
Printf("%s - %s (%s)\n", mapList[i].fileName.GetChars(), mapList[i].DisplayName(), fileSystem.GetResourceFileName(rfnum));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Printf("%s - %s (defined but does not exist)\n", mapList[i].fileName.GetChars(), mapList[i].DisplayName());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue