mirror of
https://git.code.sf.net/p/quake/prozac-qfcc
synced 2025-02-17 09:32:08 +00:00
Fixing spy-related bugs,
1) invis only being set on first connect on first map, dur 2) double- or triple-remove in regeneratecells (shaka, I want to smack you).
This commit is contained in:
parent
c6927c6b53
commit
83edfbc033
2 changed files with 23 additions and 5 deletions
14
client.qc
14
client.qc
|
@ -460,6 +460,9 @@ void() DecodeLevelParms =
|
|||
allow_hook = 0;
|
||||
invis_only = SPY_INVIS_ONLY;
|
||||
|
||||
sprint (self, PRINT_HIGH, "check1, SPY_INVIS_ONLY? " + ftos (SPY_INVIS_ONLY) + " invis_only? "
|
||||
+ ftos (invis_only) + "\n");
|
||||
|
||||
if (coop || !deathmatch)
|
||||
toggleflags = toggleflags | TFLAG_CLASS_PERSIST;
|
||||
|
||||
|
@ -474,8 +477,10 @@ void() DecodeLevelParms =
|
|||
if (ent)
|
||||
{
|
||||
// Turn on Teamplay
|
||||
if (teamplay == 0)
|
||||
if (teamplay == 0) {
|
||||
cvar_set("teamplay","21?TeamFortress");
|
||||
teamplay = 21;
|
||||
}
|
||||
|
||||
// Parse the rest of the Detection details
|
||||
ParseTFDetect(ent);
|
||||
|
@ -495,8 +500,10 @@ void() DecodeLevelParms =
|
|||
CTF_Map = TRUE;
|
||||
|
||||
// Turn on Teamplay
|
||||
if (teamplay == 0)
|
||||
if (teamplay == 0) {
|
||||
cvar_set("teamplay","21?TeamFortress");
|
||||
teamplay = 21;
|
||||
}
|
||||
|
||||
// Setup the CTF FlagCheck Timer
|
||||
ent = spawn();
|
||||
|
@ -681,6 +688,9 @@ void() DecodeLevelParms =
|
|||
if (!teamplay)
|
||||
invis_only = TRUE;
|
||||
|
||||
sprint (self, PRINT_HIGH, "check2, st? " + st + " teamplay? " + ftos (teamplay) + " invis_only? "
|
||||
+ ftos (invis_only) + "\n");
|
||||
|
||||
// RespawnDelay
|
||||
st = infokey(NIL, "rd");
|
||||
if (!st)
|
||||
|
|
14
tfort.qc
14
tfort.qc
|
@ -3559,12 +3559,20 @@ void() TeamFortress_RegenerateCells =
|
|||
{
|
||||
//WK Borrow this code from TF, since there's no reason to
|
||||
// duplicate it.
|
||||
if (!(self.owner.job & JOB_THIEF))
|
||||
// Griev - HEY FUCKTARD, REMOVING MORE THAN ONCE IS IDIOTIC!
|
||||
if (!(self.owner.job & JOB_THIEF)) {
|
||||
dremove(self);
|
||||
if (!(self.owner.job & JOB_ACTIVE))
|
||||
return;
|
||||
}
|
||||
if (!(self.owner.job & JOB_ACTIVE)) {
|
||||
dremove(self);
|
||||
if (self.owner.health <= 0)
|
||||
return;
|
||||
}
|
||||
if (self.owner.health <= 0) {
|
||||
dremove(self);
|
||||
return;
|
||||
}
|
||||
|
||||
self.nextthink = time + PC_SPY_CELL_REGEN_TIME;
|
||||
if (self.owner.job & JOB_ACTIVE)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue