- Added an IF_KEEPDEPLETED flag for inventory items to keep them in the
player's inventory even when they have been used up. If the item also has an inventory bar icon, it will be drawn darkened when it is depleted. SVN r497 (trunk)
This commit is contained in:
parent
560d4f8140
commit
e01ff5707c
12 changed files with 52 additions and 22 deletions
|
|
@ -17,6 +17,7 @@
|
|||
static FRandom pr_restore ("RestorePos");
|
||||
|
||||
IMPLEMENT_STATELESS_ACTOR (AAmmo, Any, -1, 0)
|
||||
PROP_Inventory_FlagsSet (IF_KEEPDEPLETED)
|
||||
PROP_Inventory_PickupSound ("misc/ammo_pkup")
|
||||
END_DEFAULTS
|
||||
|
||||
|
|
@ -668,7 +669,7 @@ AInventory *AInventory::CreateTossable ()
|
|||
{
|
||||
return NULL;
|
||||
}
|
||||
if (Amount == 1 && !IsKindOf (RUNTIME_CLASS(AAmmo)))
|
||||
if (Amount == 1 && !(ItemFlags & IF_KEEPDEPLETED))
|
||||
{
|
||||
BecomePickup ();
|
||||
DropTime = 30;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue