Reserve 3 SRC'04 rendermodes, implement RM_DONTRENDER.
This commit is contained in:
parent
fd05c2419c
commit
9fa091db43
4 changed files with 17 additions and 16 deletions
|
@ -419,13 +419,6 @@ CSQC_UpdateView(float w, float h, float focus)
|
|||
}
|
||||
}
|
||||
|
||||
#if 1
|
||||
if (pl.flags & FL_INVEHICLE) {
|
||||
CBaseVehicle veh = (CBaseVehicle)pl.vehicle;
|
||||
PointMessage_StringAtPos(veh.origin, sprintf("Speed: %d", vlen(veh.velocity)));
|
||||
}
|
||||
#endif
|
||||
|
||||
if (self.classname == "player")
|
||||
Predict_PlayerPostFrame((player)self);
|
||||
else if (self.classname == "spectator")
|
||||
|
|
|
@ -17,13 +17,16 @@
|
|||
#ifdef GS_RENDERFX
|
||||
enum
|
||||
{
|
||||
RM_NORMAL,
|
||||
RM_COLOR,
|
||||
RM_TEXTURE,
|
||||
RM_GLOW,
|
||||
RM_SOLID,
|
||||
RM_ADDITIVE,
|
||||
RM_FULLBRIGHT,
|
||||
RM_NORMAL = 0,
|
||||
RM_COLOR = 1,
|
||||
RM_TEXTURE = 2,
|
||||
RM_GLOW = 3,
|
||||
RM_SOLID = 4,
|
||||
RM_ADDITIVE = 5,
|
||||
RM_FULLBRIGHT = 6,
|
||||
RM_ADDFRAC = 7, /* Source 2004 */
|
||||
RM_WORLDGLOW = 9, /* Source 2004 */
|
||||
RM_DONTRENDER = 10, /* Source 2004 */
|
||||
RM_TRIGGER
|
||||
};
|
||||
|
||||
|
|
|
@ -58,6 +58,7 @@ CBaseEntity::RenderFXPass(void)
|
|||
}
|
||||
break;
|
||||
case RM_GLOW:
|
||||
case RM_WORLDGLOW: /* TODO: Figure out what this does differently */
|
||||
if (checkpvs(vecPlayer, this) == FALSE)
|
||||
alpha -= clframetime;
|
||||
|
||||
|
@ -84,6 +85,7 @@ CBaseEntity::RenderFXPass(void)
|
|||
alpha = 1.0f;
|
||||
break;
|
||||
case RM_ADDITIVE:
|
||||
case RM_ADDFRAC: /* TODO: Figure out what this does differently */
|
||||
effects = EF_ADDITIVE;
|
||||
if (autocvar_rm_unlit_additive == 0) {
|
||||
drawflags = 0;
|
||||
|
@ -107,6 +109,9 @@ CBaseEntity::RenderFXPass(void)
|
|||
alpha = 0.0f;
|
||||
}
|
||||
break;
|
||||
case RM_DONTRENDER:
|
||||
/* prevent addentity() from being called */
|
||||
alpha = 0.0f;
|
||||
}
|
||||
|
||||
/* messy hologram imitation */
|
||||
|
|
|
@ -56,7 +56,7 @@ base_player::ReceiveEntity(float new, float fl)
|
|||
v_angle[1] = readshort() / (32767 / 360);
|
||||
}
|
||||
if (fl & PLAYER_COLORMAP)
|
||||
colormap = readfloat();
|
||||
colormap = readbyte();
|
||||
|
||||
if (fl & PLAYER_VELOCITY) {
|
||||
velocity[0] = readcoord();
|
||||
|
@ -317,7 +317,7 @@ base_player::SendEntity(entity ePEnt, float fChanged)
|
|||
WriteShort(MSG_ENTITY, v_angle[1] * 32767 / 360);
|
||||
}
|
||||
if (fChanged & PLAYER_COLORMAP)
|
||||
WriteFloat(MSG_ENTITY, colormap);
|
||||
WriteByte(MSG_ENTITY, colormap);
|
||||
|
||||
/* similar as with origin, we separate x/y from z */
|
||||
if (fChanged & PLAYER_VELOCITY) {
|
||||
|
|
Loading…
Reference in a new issue