mirror of
https://github.com/yquake2/xatrix.git
synced 2025-04-19 16:51:30 +00:00
Fix original xatrix bug that made DF_QUADFIRE_DROP not work correctly
This commit is contained in:
parent
527f3d9845
commit
dc38e968ff
1 changed files with 12 additions and 22 deletions
|
@ -1272,31 +1272,21 @@ Touch_Item(edict_t *ent, edict_t *other, cplane_t *plane, csurface_t *surf)
|
|||
{
|
||||
if ((((int)dmflags->value & DF_INSTANT_ITEMS) &&
|
||||
(ent->item->flags & IT_INSTANT_USE)) ||
|
||||
((ent->item->use == Use_Quad) &&
|
||||
(((ent->item->use == Use_Quad) || (ent->item->use == Use_QuadFire)) &&
|
||||
(ent->spawnflags & DROPPED_PLAYER_ITEM)))
|
||||
{
|
||||
if ((ent->item->use == Use_Quad) &&
|
||||
(ent->spawnflags & DROPPED_PLAYER_ITEM))
|
||||
if (ent->spawnflags & DROPPED_PLAYER_ITEM)
|
||||
{
|
||||
quad_drop_timeout_hack =
|
||||
(ent->nextthink - level.time) / FRAMETIME;
|
||||
}
|
||||
|
||||
if (ent->item->use)
|
||||
{
|
||||
ent->item->use(other, ent->item);
|
||||
}
|
||||
}
|
||||
else if ((((int)dmflags->value & DF_INSTANT_ITEMS) &&
|
||||
(ent->item->flags & IT_INSTANT_USE)) ||
|
||||
((ent->item->use == Use_QuadFire) &&
|
||||
(ent->spawnflags & DROPPED_PLAYER_ITEM)))
|
||||
{
|
||||
if ((ent->item->use == Use_QuadFire) &&
|
||||
(ent->spawnflags & DROPPED_PLAYER_ITEM))
|
||||
{
|
||||
quad_fire_drop_timeout_hack =
|
||||
(ent->nextthink - level.time) / FRAMETIME;
|
||||
if (ent->item->use == Use_Quad)
|
||||
{
|
||||
quad_drop_timeout_hack =
|
||||
(ent->nextthink - level.time) / FRAMETIME;
|
||||
}
|
||||
else if (ent->item->use == Use_QuadFire)
|
||||
{
|
||||
quad_fire_drop_timeout_hack =
|
||||
(ent->nextthink - level.time) / FRAMETIME;
|
||||
}
|
||||
}
|
||||
|
||||
if (ent->item->use)
|
||||
|
|
Loading…
Reference in a new issue