Half-Life: Let items trigger targets. Required for Hazard Course at least.

This commit is contained in:
Marco Cawthorne 2019-09-01 10:08:59 +02:00
parent afa60a0482
commit 3dee62271f

View file

@ -15,7 +15,7 @@
*/
/* PICKUP ITEMS */
class item_pickup:CBaseEntity
class item_pickup:CBaseTrigger
{
int id;
void() item_pickup;
@ -35,6 +35,8 @@ void item_pickup::touch(void)
sound(other, CHAN_ITEM, "items/gunpickup2.wav", 1, ATTN_NORM);
Weapons_AddItem((player)other, id);
CBaseTrigger::UseTargets();
if (cvar("sv_playerslots") == 1) {
remove(self);
} else {
@ -74,6 +76,6 @@ void item_pickup::Respawn(void)
void item_pickup::item_pickup(void)
{
precache_sound("items/suitchargeok1.wav");
CBaseEntity::CBaseEntity();
CBaseTrigger::CBaseTrigger();
Respawn();
}