mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-10 23:01:50 +00:00
- Extend the changemap command to allow warping to next or nextsecret.
This commit is contained in:
parent
7a3d8bd0e5
commit
5a0dc4297f
1 changed files with 18 additions and 0 deletions
|
@ -363,6 +363,24 @@ CCMD (changemap)
|
|||
const char *mapname = argv[1];
|
||||
if (!strcmp(mapname, "*")) mapname = primaryLevel->MapName.GetChars();
|
||||
|
||||
if (strstr(mapname, "next") && !P_CheckMapData(mapname))
|
||||
{
|
||||
if (!strcmp(mapname, "next"))
|
||||
{
|
||||
if (primaryLevel->NextMap.Len() > 0 && primaryLevel->NextMap.Compare("enDSeQ", 6))
|
||||
{
|
||||
mapname = primaryLevel->NextMap.GetChars();
|
||||
}
|
||||
}
|
||||
else if (!strcmp(mapname, "nextsecret"))
|
||||
{
|
||||
if (primaryLevel->NextSecretMap.Len() > 0 && primaryLevel->NextSecretMap.Compare("enDSeQ", 6))
|
||||
{
|
||||
mapname = primaryLevel->NextSecretMap.GetChars();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
if (!P_CheckMapData(mapname))
|
||||
|
|
Loading…
Reference in a new issue