mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-26 22:40:50 +00:00
Merge pull request #906 from BjossiAlfreds/powercubes
Fix coop power cube related bugs
This commit is contained in:
commit
0b67676535
2 changed files with 4 additions and 2 deletions
|
@ -1638,7 +1638,7 @@ SpawnItem(edict_t *ent, gitem_t *item)
|
|||
}
|
||||
}
|
||||
|
||||
if (coop->value && (strcmp(ent->classname, "key_power_cube") == 0))
|
||||
if (coop->value && !(ent->spawnflags & ITEM_NO_TOUCH) && (strcmp(ent->classname, "key_power_cube") == 0))
|
||||
{
|
||||
ent->spawnflags |= (1 << (8 + level.power_cubes));
|
||||
level.power_cubes++;
|
||||
|
|
|
@ -132,13 +132,15 @@ BeginIntermission(edict_t *targ)
|
|||
}
|
||||
|
||||
/* strip players of all keys between units */
|
||||
for (n = 0; n < MAX_ITEMS; n++)
|
||||
for (n = 0; n < game.num_items; n++)
|
||||
{
|
||||
if (itemlist[n].flags & IT_KEY)
|
||||
{
|
||||
client->client->pers.inventory[n] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
client->client->pers.power_cubes = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue