Implement IsMultiplayer() into HLGameRules class.

Improve player network-culling
This commit is contained in:
Marco Cawthorne 2022-05-01 17:03:38 -07:00
parent 6f0df5845f
commit 45a52e1bf6
Signed by: eukara
GPG Key ID: C196CD8BA993248A
3 changed files with 21 additions and 5 deletions

View File

@ -16,6 +16,12 @@
var int autocvar_sv_playerkeepalive = TRUE;
bool
HLGameRules::IsMultiplayer(void)
{
return true;
}
/* we check what fields have changed over the course of the frame and network
* only the ones that have actually changed */
void

View File

@ -474,13 +474,11 @@ player::SendEntity
float
player::SendEntity(entity ePEnt, float fChanged)
{
if (health <= 0 && ePEnt != this) {
/* don't broadcast invisible players */
if (IsFakeSpectator() && ePEnt != this)
return (0);
}
if (clienttype(ePEnt) != CLIENTTYPE_REAL) {
if (!GetModelindex() && ePEnt != this)
return (0);
}
if (ePEnt != self) {
fChanged &= ~PLAYER_ITEMS;

View File

@ -45,3 +45,15 @@ seta "maxplayers" "8"
seta "con_color" "0 255 0"
seta "vgui_color" "0 255 0"
seta "cross_color" "0 255 0"
// disable some nuclide niceties
seta v_muzzledlight 0
// config compat
alias mp_timelimit timelimit
alias mp_fraglimit fraglimit
// video settings
seta gl_overbright 0
seta gl_ldr 1
seta r_lightmap_format rgb8