- Make changemap use + for next and +$ for nextsecret maps.

This commit is contained in:
drfrag 2021-07-29 09:47:04 +02:00 committed by Christoph Oelckers
parent 5a0dc4297f
commit f89e6950c3

View file

@ -361,25 +361,18 @@ CCMD (changemap)
if (argv.argc() > 1)
{
const char *mapname = argv[1];
if (!strcmp(mapname, "*")) mapname = primaryLevel->MapName.GetChars();
if (strstr(mapname, "next") && !P_CheckMapData(mapname))
if (!strcmp(mapname, "*"))
{
if (!strcmp(mapname, "next"))
{
if (primaryLevel->NextMap.Len() > 0 && primaryLevel->NextMap.Compare("enDSeQ", 6))
mapname = primaryLevel->MapName.GetChars();
}
else if (!strcmp(mapname, "+") && 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))
else if (!strcmp(mapname, "+$") && primaryLevel->NextSecretMap.Len() > 0 && primaryLevel->NextSecretMap.Compare("enDSeQ", 6))
{
mapname = primaryLevel->NextSecretMap.GetChars();
}
}
}
try
{