Remove an unnecessary engine function call, may save a bit of performance when lots of projectiles are bouncing off eachother
AuditLists();
}
-float RegisterTeam(entity Team)
+void RegisterTeam(entity Team)
{
assert_once(Team.team, eprint(Team));
entity tm;
if(Team.team && Team.team != NUM_SPECTATOR)
++team_count;
AuditLists();
- return true;
}
void RemoveTeam(entity Team)
return tm;
}
-.float has_team;
+.bool has_team;
bool SetTeam(entity o, int Team)
{
TC(int, Team);
{
tm = GetTeam(o.team, false);
tm.team_size -= 1;
- o.has_team = 0;
+ o.has_team = false;
return true;
}
}
o.team = Team;
tm = GetTeam(Team, true);
tm.team_size += 1;
- o.has_team = 1;
+ o.has_team = true;
return true;
}
else if(Team != o.team)
void MoveToLast(entity e);
-float RegisterTeam(entity Team);
+void RegisterTeam(entity Team);
void RemoveTeam(entity Team);
#ifdef GAMEQC // menu doesn't use any globals
// compile time switches in case perf is an issue
-#define DEGLOB_LOGGING 1
+#define DEGLOB_LOGGING 0
#define DEGLOB_CLEAR 1
const int DEGLOB_ORIGINAL = 1;
if(trace_dphitcontents == 0)
{
LOG_TRACEF("A hit from a projectile happened with no hit contents! DEBUG THIS, this should never happen for projectiles! Projectile will self-destruct. (edict: %i, classname: %s, origin: %v)", this, this.classname, this.origin);
- checkclient(this); // TODO: .health is checked in the engine with this, possibly replace with a QC function?
}
if (trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOIMPACT)
return true;