- Added compat_badangles to simulate Doom's incorrect sine table: Player

spawning and teleporting will be offset by one fineangle so they cannot
  face directly in one of the cardinal directions.



SVN r3308 (trunk)
This commit is contained in:
Randy Heit 2011-11-01 02:58:52 +00:00
commit e121bd7d92
10 changed files with 149 additions and 90 deletions

View file

@ -254,8 +254,8 @@ void level_info_t::Reset()
aircontrol = 0.f;
WarpTrans = 0;
airsupply = 20;
compatflags = 0;
compatmask = 0;
compatflags = compatflags2 = 0;
compatmask = compatmask2 = 0;
Translator = "";
RedirectType = 0;
RedirectMap[0] = 0;
@ -1272,6 +1272,7 @@ MapFlagHandlers[] =
{ "compat_light", MITYPE_COMPATFLAG, COMPATF_LIGHT, 0 },
{ "compat_polyobj", MITYPE_COMPATFLAG, COMPATF_POLYOBJ, 0 },
{ "compat_maskedmidtex", MITYPE_COMPATFLAG, COMPATF_MASKEDMIDTEX, 0 },
{ "compat_badangles", MITYPE_COMPATFLAG, 0, COMPATF2_BADANGLES },
{ "cd_start_track", MITYPE_EATNEXT, 0, 0 },
{ "cd_end1_track", MITYPE_EATNEXT, 0, 0 },
{ "cd_end2_track", MITYPE_EATNEXT, 0, 0 },
@ -1353,9 +1354,18 @@ void FMapInfoParser::ParseMapDefinition(level_info_t &info)
if (sc.CheckNumber()) set = sc.Number;
}
if (set) info.compatflags |= handler->data1;
else info.compatflags &= ~handler->data1;
if (set)
{
info.compatflags |= handler->data1;
info.compatflags2 |= handler->data2;
}
else
{
info.compatflags &= ~handler->data1;
info.compatflags2 &= ~handler->data2;
}
info.compatmask |= handler->data1;
info.compatmask2 |= handler->data2;
}
break;