This commit is contained in:
Rachael Alexanderson 2016-12-15 20:07:10 -05:00
commit 0b4fd6c766
2 changed files with 34 additions and 26 deletions

View file

@ -1365,6 +1365,12 @@ void APlayerPawn::GiveDefaultInventory ()
{ {
PClassActor *ti = PClass::FindActor (di->Name); PClassActor *ti = PClass::FindActor (di->Name);
if (ti) if (ti)
{
if (!ti->IsDescendantOf(RUNTIME_CLASS(AInventory)))
{
Printf(TEXTCOLOR_ORANGE "%s is not an inventory item and cannot be given to a player as start item.\n", ti->TypeName.GetChars());
}
else
{ {
AInventory *item = FindInventory(ti); AInventory *item = FindInventory(ti);
if (item != NULL) if (item != NULL)
@ -1404,6 +1410,7 @@ void APlayerPawn::GiveDefaultInventory ()
player->ReadyWeapon = player->PendingWeapon = static_cast<AWeapon *> (item); player->ReadyWeapon = player->PendingWeapon = static_cast<AWeapon *> (item);
} }
} }
}
di = di->Next; di = di->Next;
} }
} }

View file

@ -183,6 +183,7 @@ namespace swrenderer
{ {
identitymap[i] = i; identitymap[i] = i;
} }
identitycolormap.Maps = identitymap;
} }
void R_InitFuzzTable(int fuzzoff) void R_InitFuzzTable(int fuzzoff)