- Fixed: ACS translations were loaded into the wrong slot after restoring a

savegame.
- Fixed exploit: Dropping ammo at baby and nightmare skill levels would give
  you back more than you dropped.


SVN r706 (trunk)
This commit is contained in:
Randy Heit 2008-01-15 04:57:25 +00:00
parent c15a3a8614
commit d36d4aa863
4 changed files with 25 additions and 5 deletions

View File

@ -1,3 +1,9 @@
January 14, 2008
- Fixed: ACS translations were loaded into the wrong slot after restoring a
savegame.
- Fixed exploit: Dropping ammo at baby and nightmare skill levels would give
you back more than you dropped.
January 13, 2008 (Changes by Graf Zahl) January 13, 2008 (Changes by Graf Zahl)
- Moved A_Punch from Inventory to Actor. Apparently there are WADs that use it - Moved A_Punch from Inventory to Actor. Apparently there are WADs that use it
for monsters. The function works fine for monsters as it is. for monsters. The function works fine for monsters as it is.

View File

@ -2744,15 +2744,11 @@ void G_SerializeLevel (FArchive &arc, bool hubLoad)
{ {
while (arc << w, w != 0xffff) while (arc << w, w != 0xffff)
{ {
if (w >= MAX_ACS_TRANSLATIONS)
{ // hack hack to avoid crashing
w = 0;
}
trans = translationtables[TRANSLATION_LevelScripted].GetVal(w); trans = translationtables[TRANSLATION_LevelScripted].GetVal(w);
if (trans == NULL) if (trans == NULL)
{ {
trans = new FRemapTable; trans = new FRemapTable;
translationtables[TRANSLATION_LevelScripted].SetVal(t, trans); translationtables[TRANSLATION_LevelScripted].SetVal(w, trans);
} }
trans->Serialize(arc); trans->Serialize(arc);
} }

View File

@ -160,6 +160,23 @@ AInventory *AAmmo::CreateCopy (AActor *other)
return copy; return copy;
} }
//===========================================================================
//
// AAmmo :: CreateTossable
//
//===========================================================================
AInventory *AAmmo::CreateTossable()
{
AInventory *copy = Super::CreateTossable();
if (copy != NULL)
{ // Do not increase ammo by dropping it and picking it back up at
// certain skill levels.
copy->ItemFlags |= IF_IGNORESKILL;
}
return copy;
}
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// //
// FUNC P_GiveBody // FUNC P_GiveBody

View File

@ -190,6 +190,7 @@ public:
AInventory *CreateCopy (AActor *other); AInventory *CreateCopy (AActor *other);
bool HandlePickup (AInventory *item); bool HandlePickup (AInventory *item);
const PClass *GetParentAmmo () const; const PClass *GetParentAmmo () const;
AInventory *CreateTossable ();
int BackpackAmount, BackpackMaxAmount; int BackpackAmount, BackpackMaxAmount;
}; };