Example #1
0
/*
* G_DropItem
*/
void G_DropItem( edict_t *ent, gsitem_t *it )
{
	if( !it || !( it->flags & ITFLAG_DROPABLE ) )
		return;

	if( !G_Gametype_CanDropItem( it, qfalse ) )
		return;

	if( it->type & IT_WEAPON )
	{
		Drop_Weapon( ent, it );
	}
	else if( it->type & IT_AMMO )
	{
		Drop_Ammo( ent, it );
	}
	else
	{
		Drop_General( ent, it );
	}
}
Example #2
0
void Drop_PowerArmor (edict_t *ent, gitem_t *item)
{
	if ((ent->flags & FL_POWER_ARMOR) && (ent->client->pers.inventory[ITEM_INDEX(item)] == 1))
		Use_PowerArmor (ent, item);
	Drop_General (ent, item);
}