- Moved IF_ALWAYSPICKUP and GiveQuest into CallTryPickup so that they are

automatically used by all inventory classes.
- The previous change made it necessary to replace all TryPickup calls with
  another function that just calls TryPickup.
- Fixed: AInventory::TryPickup can change the toucher so this must be reported
  to subclasses calling the super function. Changed TryPickup to pass the
  toucher pointer by reference.


SVN r1221 (trunk)
This commit is contained in:
Christoph Oelckers 2008-09-13 22:08:41 +00:00
commit 2cad1c2c19
28 changed files with 107 additions and 89 deletions

View file

@ -1213,7 +1213,7 @@ static void DoGiveInventory(AActor * self, AActor * receiver, DECLARE_PARAMINFO)
item->flags&=~MF_COUNTITEM;
level.total_items--;
}
if (!item->TryPickup (receiver))
if (!item->CallTryPickup (receiver))
{
item->Destroy ();
res = false;