- Changed A_ChangeFlag so that it doesn't need to alter the flag
string. With strings being passed as names this is unsafe. - Removed unused parameter types from the function parameter parser for DECORATE. - Changed: All actor name parameters in DECORATE are now passed as FNames, not as strings. - Fixed: The MAPINFO parser stored the RedirectType as a type pointer. But at this point DECORATE hasn't been read yet so this was limited to the internal classes. - Fixed: TXT_NEED_IDCARD wasn't terminated with a ';'. - Fixed: Strife's DeadRebel was missing its DoomEdNum. - With names as type identifiers it is no longer necessary to remap the monster types to internal constants in A_BossDeath. - Fixed: A_BossDeath got the string from a name - just to get a name from the string. Using the name directly is sufficient. SVN r103 (trunk)
This commit is contained in:
parent
032526340a
commit
159c548c5a
14 changed files with 115 additions and 120 deletions
|
|
@ -772,12 +772,14 @@ static void ParseMapInfoLower (MapInfoHandler *handlers,
|
|||
|
||||
case MITYPE_REDIRECT:
|
||||
SC_MustGetString ();
|
||||
levelinfo->RedirectType = PClass::FindClass (sc_String);
|
||||
levelinfo->RedirectType = sc_String;
|
||||
/*
|
||||
if (levelinfo->RedirectType == NULL ||
|
||||
!(levelinfo->RedirectType->IsDescendantOf (RUNTIME_CLASS(AInventory))))
|
||||
{
|
||||
SC_ScriptError ("%s is not an inventory item", sc_String);
|
||||
}
|
||||
*/
|
||||
// Intentional fall-through
|
||||
|
||||
case MITYPE_MAPNAME: {
|
||||
|
|
@ -2168,18 +2170,22 @@ level_info_t *FindLevelByNum (int num)
|
|||
|
||||
level_info_t *CheckLevelRedirect (level_info_t *info)
|
||||
{
|
||||
if (info->RedirectType != NULL)
|
||||
if (info->RedirectType != NAME_None)
|
||||
{
|
||||
for (int i = 0; i < MAXPLAYERS; ++i)
|
||||
const PClass *type = PClass::FindClass(info->RedirectType);
|
||||
if (type != NULL)
|
||||
{
|
||||
if (playeringame[i] && players[i].mo->FindInventory (info->RedirectType))
|
||||
for (int i = 0; i < MAXPLAYERS; ++i)
|
||||
{
|
||||
level_info_t *newinfo = FindLevelInfo (info->RedirectMap);
|
||||
if (newinfo != NULL)
|
||||
if (playeringame[i] && players[i].mo->FindInventory (type))
|
||||
{
|
||||
info = newinfo;
|
||||
level_info_t *newinfo = FindLevelInfo (info->RedirectMap);
|
||||
if (newinfo != NULL)
|
||||
{
|
||||
info = newinfo;
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue