diff --git a/src/g_items.c b/src/g_items.c index 759f131..b519153 100644 --- a/src/g_items.c +++ b/src/g_items.c @@ -584,7 +584,7 @@ Pickup_Nuke(edict_t *ent, edict_t *other) return false; } - if ((coop->value) && (ent->item->flags & IT_STAY_COOP) && (quantity > 0)) + if ((coop->value) && (ent->item->flags & IT_STAY_COOP)) { return false; } @@ -1209,6 +1209,11 @@ Drop_Ammo(edict_t *ent, gitem_t *item) void MegaHealth_think(edict_t *self) { + if (!self) + { + return; + } + if (self->owner->health > self->owner->max_health) { self->nextthink = level.time + 1; @@ -1216,11 +1221,6 @@ MegaHealth_think(edict_t *self) return; } - if (!self) - { - return; - } - if (!(self->spawnflags & DROPPED_ITEM) && (deathmatch->value)) { SetRespawn(self, 20);