- adapted AActor to use TFlags

This commit is contained in:
Teemu Piippo 2015-04-04 19:40:43 +03:00
commit ca012bc9be
17 changed files with 127 additions and 92 deletions

View file

@ -1135,31 +1135,31 @@ static int PatchThing (int thingy)
// triggering line effects and can teleport when the missile flag is removed.
info->flags2 &= ~MF2_NOTELEPORT;
}
info->flags = value[0];
info->flags = ActorFlags::FromInt (value[0]);
}
if (vchanged[1])
{
info->flags2 = value[1];
info->flags2 = ActorFlags2::FromInt (value[1]);
if (info->flags2 & 0x00000004) // old BOUNCE1
{
info->flags2 &= ~4;
info->flags2 &= ActorFlags2::FromInt (~4);
info->BounceFlags = BOUNCE_DoomCompat;
}
// Damage types that once were flags but now are not
if (info->flags2 & 0x20000000)
{
info->DamageType = NAME_Ice;
info->flags2 &= ~0x20000000;
info->flags2 &= ActorFlags2::FromInt (~0x20000000);
}
if (info->flags2 & 0x10000)
{
info->DamageType = NAME_Fire;
info->flags2 &= ~0x10000;
info->flags2 &= ActorFlags2::FromInt (~0x10000);
}
if (info->flags2 & 1)
{
info->gravity = FRACUNIT/4;
info->flags2 &= ~1;
info->flags2 &= ActorFlags2::FromInt (~1);
}
}
if (vchanged[2])