- Fixed: SNDINFO must be loaded before the textures. However, this required

some changes to the MAPINFO parser which tried to access the texture manager
  to check if the level name patches exist. That check had to be moved to
  where the intermission screen is set up.
- Fixed: 'bloodcolor' ignored the first parameter value when given a list
  of integers.
  Please note that this creates an incompatibility between old and new 
  versions so if you want to create something that works with both 2.2.0
  and current versions better use the string format version for the color
  parameter!
- Rewrote the DECORATE property parser so that the parser is completely
  separated from the property handlers. This should allow reuse of all 
  the handler code for a new format if Doomscript requires one.
- Fixed: PClass::InitializeActorInfo copied too many bytes if a subclass's
  defaults were larger than the parent's.
- Moved A_ChangeFlag to thingdef_codeptr.cpp.
- Moved translation related code from thingdef_properties.cpp to r_translate.cpp
  and rewrote the translation parser to use FScanner instead of strtol.
- replaced DECORATE's 'alpha default' by 'defaultalpha' for consistency.
  Since this was never used outside zdoom.pk3 it's not critical.
- Removed support for game specific pickup messages because the only thing
  this was ever used for - Raven's invulnerability item - has already been
  split up into a Heretic and Hexen version.

SVN r1240 (trunk)
This commit is contained in:
Christoph Oelckers 2008-09-21 18:02:38 +00:00
commit 6227906072
38 changed files with 2123 additions and 2129 deletions

View file

@ -123,97 +123,6 @@ static const char *RenderStyles[] =
NULL
};
static const char *FlagNames1[] =
{
"*",
"Solid",
"*",
"NoSector",
"NoBlockmap",
"*",
"*",
"*",
"SpawnCeiling",
"NoGravity",
"*",
"*",
"*",
"*",
"*",
"*",
"*",
"*",
"Shadow",
"NoBlood",
"*",
"*",
"*",
"CountItem",
NULL
};
static const char *FlagNames2[] =
{
"LowGravity",
"WindThrust",
"*",
"*",
"*",
"FloorClip",
"SpawnFloat",
"NoTeleport",
"Ripper",
"Pushable",
"SlidesOnWalls",
"*",
"CanPass",
"CannotPush",
"ThruGhost",
"*",
"FireDamage",
"NoDamageThrust",
"Telestomp",
"FloatBob",
"*",
"ActivateImpact",
"CanPushWalls",
"ActivateMCross",
"ActivatePCross",
"*",
"*",
"*",
"*",
"*",
"*",
"Reflective",
NULL
};
static const char *FlagNames3[] =
{
"FloorHugger",
"CeilingHugger",
"*",
"*",
"*",
"*",
"DontSplash",
NULL
};
// CODE --------------------------------------------------------------------
//==========================================================================
@ -243,65 +152,8 @@ void ParseOldDecoration(FScanner &sc, EDefinitionType def)
info->GameFilter = 0x80;
MakeStateDefines(parent->ActorInfo->StateList);
// There isn't a single WAD out there which uses game filters with old style
// decorations so this may as well be disabled. Without this option is is much
// easier to detect incorrect declarations
#if 0
sc.MustGetString ();
while (!sc.Compare ("{"))
{
if (sc.Compare ("Doom"))
{
info->GameFilter |= GAME_Doom;
}
else if (sc.Compare ("Heretic"))
{
info->GameFilter |= GAME_Heretic;
}
else if (sc.Compare ("Hexen"))
{
info->GameFilter |= GAME_Hexen;
}
else if (sc.Compare ("Raven"))
{
info->GameFilter |= GAME_Raven;
}
else if (sc.Compare ("Strife"))
{
info->GameFilter |= GAME_Strife;
}
else if (sc.Compare ("Any"))
{
info->GameFilter = GAME_Any;
}
else
{
if (def != DEF_Decoration || info->GameFilter != 0x80)
{
sc.ScriptError ("Unknown game type %s in %s", sc.String, typeName.GetChars());
}
else
{
// If this is a regular decoration (without preceding keyword) and no game
// filters defined this is more likely a general syntax error so output a
// more meaningful message.
sc.ScriptError ("Syntax error: Unknown identifier '%s'", typeName.GetChars());
}
}
sc.MustGetString ();
}
if (info->GameFilter == 0x80)
{
info->GameFilter = GAME_Any;
}
else
{
info->GameFilter &= ~0x80;
}
#else
info->GameFilter = GAME_Any;
sc.MustGetStringName("{");
#endif
states.Clear ();
memset (&extra, 0, sizeof(extra));
@ -724,23 +576,9 @@ static void ParseInsideDecoration (FActorInfo *info, AActor *defaults,
}
else if (sc.String[0] != '*')
{
int bit = sc.MatchString (FlagNames1);
if (bit != -1)
{
defaults->flags |= 1 << bit;
}
else if ((bit = sc.MatchString (FlagNames2)) != -1)
{
defaults->flags2 |= 1 << bit;
}
else if ((bit = sc.MatchString (FlagNames3)) != -1)
{
defaults->flags3 |= 1 << bit;
}
else
{
sc.ScriptError (NULL);
}
Baggage bag;
bag.Info = info;
HandleActorFlag(sc, bag, sc.String, NULL, '+');
}
else
{