Fixed CGM values for AA and SH/BT

This commit is contained in:
OM 2023-05-23 00:08:12 +02:00
parent 6c874641d7
commit 55dc84d932
12 changed files with 249 additions and 163 deletions

View file

@ -541,7 +541,7 @@ void CG_ParseCGMessage()
// get the integer as string // get the integer as string
snprintf(cTmp, sizeof(cTmp), "%d", iLarge); snprintf(cTmp, sizeof(cTmp), "%d", iLarge);
if (iType == 23) { if (iType == 26) {
sEffect = "models/fx/crates/debris_"; sEffect = "models/fx/crates/debris_";
} }
else { else {

View file

@ -238,11 +238,11 @@ void BarrelObject::BarrelThink
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
{ {
gi.MSG_StartCGM( 15 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_1);
} }
else else
{ {
gi.MSG_StartCGM( 19 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_5);
} }
m_fFluidAmount -= 1.0f; m_fFluidAmount -= 1.0f;
@ -254,11 +254,11 @@ void BarrelObject::BarrelThink
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
{ {
gi.MSG_StartCGM( 16 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_2);
} }
else else
{ {
gi.MSG_StartCGM( 20 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_6);
} }
m_fFluidAmount -= 0.75f; m_fFluidAmount -= 0.75f;
@ -271,11 +271,11 @@ void BarrelObject::BarrelThink
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
{ {
gi.MSG_StartCGM( 17 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_3);
} }
else else
{ {
gi.MSG_StartCGM( 21 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_7);
} }
m_fFluidAmount -= 0.5f; m_fFluidAmount -= 0.5f;
@ -294,11 +294,11 @@ void BarrelObject::BarrelThink
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
{ {
gi.MSG_StartCGM( 17 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_3);
} }
else else
{ {
gi.MSG_StartCGM( 21 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_7);
} }
gi.MSG_WriteCoord( m_vLeaks[ i ][ 0 ] ); gi.MSG_WriteCoord( m_vLeaks[ i ][ 0 ] );
@ -506,18 +506,18 @@ void BarrelObject::BarrelDamaged
gi.SetBroadcastVisible( vHitPos, vHitPos ); gi.SetBroadcastVisible( vHitPos, vHitPos );
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
gi.MSG_StartCGM( 18 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_4);
else else
gi.MSG_StartCGM( 22 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_8);
} }
else else
{ {
gi.SetBroadcastVisible( vHitPos, vHitPos ); gi.SetBroadcastVisible( vHitPos, vHitPos );
if( m_iBarrelType == BARREL_OIL ) if( m_iBarrelType == BARREL_OIL )
gi.MSG_StartCGM( 17 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_3);
else else
gi.MSG_StartCGM( 21 ); gi.MSG_StartCGM(CGM_MAKE_EFFECT_7);
} }
gi.MSG_WriteCoord( vHitPos[ 0 ] ); gi.MSG_WriteCoord( vHitPos[ 0 ] );

View file

@ -707,6 +707,51 @@ enum vmAnim_e {
VM_ANIM_IDLE_2, VM_ANIM_IDLE_2,
}; };
enum cg_message_e {
CGM_NONE,
CGM_BULLET_1,
CGM_BULLET_2,
CGM_BULLET_3,
CGM_BULLET_4,
CGM_BULLET_5,
CGM_BULLET_6,
CGM_BULLET_7,
CGM_BULLET_8,
CGM_BULLET_9,
CGM_BULLET_10,
CGM_BULLET_11,
CGM_MELEE_IMPACT,
CGM_EXPLOSION_EFFECT_1,
CGM_EXPLOSION_EFFECT_2,
CGM_EXPLOSION_EFFECT_3,
CGM_EXPLOSION_EFFECT_4,
CGM_PADDING_1,
CGM_MAKE_EFFECT_1,
CGM_MAKE_EFFECT_2,
CGM_MAKE_EFFECT_3,
CGM_MAKE_EFFECT_4,
CGM_MAKE_EFFECT_5,
CGM_MAKE_EFFECT_6,
CGM_MAKE_EFFECT_7,
CGM_MAKE_EFFECT_8,
CGM_MAKE_CRATE_DEBRIS,
CGM_MAKE_WINDOW_DEBRIS,
CGM_BULLET_NO_BARREL_1,
CGM_BULLET_NO_BARREL_2,
CGM_HUDDRAW_SHADER,
CGM_HUDDRAW_ALIGN,
CGM_HUDDRAW_RECT,
CGM_HUDDRAW_VIRTUALSIZE,
CGM_HUDDRAW_COLOR,
CGM_HUDDRAW_ALPHA,
CGM_HUDDRAW_STRING,
CGM_HUDDRAW_FONT,
CGM_NOTIFY_KILL,
CGM_NOTIFY_HIT,
CGM_VOICE_CHAT,
CGM_UNKNOWN_1,
};
#else #else
enum vmAnim_e { enum vmAnim_e {
@ -727,8 +772,79 @@ enum vmAnim_e {
VM_ANIM_DISABLED, VM_ANIM_DISABLED,
}; };
enum cg_message_e {
CGM_NONE,
CGM_BULLET_1,
CGM_BULLET_2,
CGM_BULLET_3,
CGM_BULLET_4,
CGM_BULLET_5,
CGM_BULLET_6,
CGM_BULLET_7,
CGM_BULLET_8,
CGM_BULLET_9,
CGM_BULLET_10,
CGM_MELEE_IMPACT,
CGM_EXPLOSION_EFFECT_1,
CGM_EXPLOSION_EFFECT_2,
CGM_PADDING_1,
CGM_MAKE_EFFECT_1,
CGM_MAKE_EFFECT_2,
CGM_MAKE_EFFECT_3,
CGM_MAKE_EFFECT_4,
CGM_MAKE_EFFECT_5,
CGM_MAKE_EFFECT_6,
CGM_MAKE_EFFECT_7,
CGM_MAKE_EFFECT_8,
CGM_MAKE_CRATE_DEBRIS,
CGM_MAKE_WINDOW_DEBRIS,
CGM_BULLET_NO_BARREL_1,
CGM_BULLET_NO_BARREL_2,
CGM_HUDDRAW_SHADER,
CGM_HUDDRAW_ALIGN,
CGM_HUDDRAW_RECT,
CGM_HUDDRAW_VIRTUALSIZE,
CGM_HUDDRAW_COLOR,
CGM_HUDDRAW_ALPHA,
CGM_HUDDRAW_STRING,
CGM_HUDDRAW_FONT,
CGM_NOTIFY_KILL,
CGM_NOTIFY_HIT,
CGM_VOICE_CHAT,
};
#endif #endif
/*
#define CGM_HUDDRAW_SHADER 27
#define CGM_HUDDRAW_ALIGN 28
#define CGM_HUDDRAW_RECT 29
#define CGM_HUDDRAW_VIRTUALSIZE 30
#define CGM_HUDDRAW_COLOR 31
#define CGM_HUDDRAW_ALPHA 32
#define CGM_HUDDRAW_STRING 33
#define CGM_HUDDRAW_FONT 34
#define CGM_HUDDRAW_TIMER 38
#define CGM_HUDDRAW_3D 39
#define CGM_HUDDRAW_BREAK3D 40
#define CGM_HUDDRAW_FADE 41
#define CGM_HUDDRAW_MOVE 42
#define CGM_HUDDRAW_SCALE 43
#define CGM_VIEWMODELANIM 44
#define CGM_VIEWMODELPREFIX 45
#define CGM_MODHEIGHTFLOAT 46
#define CGM_SETVMASPEED 47
#define CGM_HINTSTRING 48
#define CGM_PLAYLOCALSOUND 49
#define CGM_SETLOCALSOUNDRATE 50
#define CGM_STOPLOCALSOUND 51
#define CGM_HUDDRAW_RECTX 52
#define CGM_HUDDRAW_RECTY 53
#define CGM_HUDDRAW_RECTWH 54
#define CGM_REPLICATION 55
#define CGM_HUDDRAW_DELETE 56
*/
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif

View file

@ -465,7 +465,7 @@ void CrateObject::CrateKilled
// Tell clients around that a crate is destroyed // Tell clients around that a crate is destroyed
gi.SetBroadcastVisible( origin, origin ); gi.SetBroadcastVisible( origin, origin );
gi.MSG_StartCGM( 23 ); gi.MSG_StartCGM(CGM_MAKE_CRATE_DEBRIS);
gi.MSG_WriteCoord( vCenter[ 0 ] ); gi.MSG_WriteCoord( vCenter[ 0 ] );
gi.MSG_WriteCoord( vCenter[ 1 ] ); gi.MSG_WriteCoord( vCenter[ 1 ] );
gi.MSG_WriteCoord( vCenter[ 2 ] ); gi.MSG_WriteCoord( vCenter[ 2 ] );

View file

@ -6912,12 +6912,15 @@ void Entity::ProcessHint(gentity_t* client, bool bShow)
{ {
if (sv_reborn->integer) if (sv_reborn->integer)
{ {
// FIXME: delete
/*
gi.MSG_SetClient(client - g_entities); gi.MSG_SetClient(client - g_entities);
// Send the hint string once // Send the hint string once
gi.MSG_StartCGM(CGM_HINTSTRING); gi.MSG_StartCGM(CGM_HINTSTRING);
gi.MSG_WriteString(m_HintString); gi.MSG_WriteString(m_HintString);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
} }
else else

View file

@ -503,6 +503,7 @@ Hud::~Hud()
SetNon3D(); SetNon3D();
} }
/*
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
@ -510,6 +511,7 @@ Hud::~Hud()
WriteNumber(); WriteNumber();
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif #endif
*/
hudElements.RemoveObject( this ); hudElements.RemoveObject( this );
} }
@ -953,6 +955,8 @@ void Hud::FadeOverTime( float time )
fade_alpha_start = alpha; fade_alpha_start = alpha;
fade_alpha_target = alpha; fade_alpha_target = alpha;
// FIXME: delete
/*
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
@ -961,6 +965,7 @@ void Hud::FadeOverTime( float time )
gi.MSG_WriteFloat( time ); gi.MSG_WriteFloat( time );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif #endif
*/
} }
void Hud::MoveOverTime( float time ) void Hud::MoveOverTime( float time )
@ -982,6 +987,7 @@ void Hud::MoveOverTime( float time )
fade_move_x_target = x; fade_move_x_target = x;
fade_move_y_target = y; fade_move_y_target = y;
/*
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
@ -990,6 +996,7 @@ void Hud::MoveOverTime( float time )
gi.MSG_WriteFloat( time ); gi.MSG_WriteFloat( time );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif #endif
*/
} }
void Hud::Refresh( int clientNumber ) void Hud::Refresh( int clientNumber )
@ -1092,6 +1099,7 @@ void Hud::Refresh( int clientNumber )
{ {
SetBroadcast(); SetBroadcast();
/*
gi.MSG_StartCGM( CGM_HUDDRAW_3D ); gi.MSG_StartCGM( CGM_HUDDRAW_3D );
WriteNumber(); WriteNumber();
gi.MSG_WriteCoord( org[ 0 ] ); gi.MSG_WriteCoord( org[ 0 ] );
@ -1103,16 +1111,19 @@ void Hud::Refresh( int clientNumber )
gi.MSG_WriteBits( !!always_show, 1 ); gi.MSG_WriteBits( !!always_show, 1 );
gi.MSG_WriteBits( !!depth, 1 ); gi.MSG_WriteBits( !!depth, 1 );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
if( fade_alpha ) if( fade_alpha )
{ {
SetBroadcast(); SetBroadcast();
/*
gi.MSG_StartCGM( CGM_HUDDRAW_FADE ); gi.MSG_StartCGM( CGM_HUDDRAW_FADE );
WriteNumber(); WriteNumber();
gi.MSG_WriteFloat( fade_alpha_current ); gi.MSG_WriteFloat( fade_alpha_current );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
SetBroadcast(); SetBroadcast();
@ -1126,6 +1137,7 @@ void Hud::Refresh( int clientNumber )
{ {
SetBroadcast(); SetBroadcast();
/*
gi.MSG_StartCGM( CGM_HUDDRAW_MOVE ); gi.MSG_StartCGM( CGM_HUDDRAW_MOVE );
WriteNumber(); WriteNumber();
gi.MSG_WriteFloat( fade_move_current ); gi.MSG_WriteFloat( fade_move_current );
@ -1138,10 +1150,12 @@ void Hud::Refresh( int clientNumber )
gi.MSG_WriteShort( ( short )fade_move_x_target ); gi.MSG_WriteShort( ( short )fade_move_x_target );
gi.MSG_WriteShort( ( short )fade_move_y_target ); gi.MSG_WriteShort( ( short )fade_move_y_target );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
if( fade_timer_flags & TIMER_ACTIVE ) if( fade_timer_flags & TIMER_ACTIVE )
{ {
/*
SetBroadcast(); SetBroadcast();
gi.MSG_StartCGM( CGM_HUDDRAW_TIMER ); gi.MSG_StartCGM( CGM_HUDDRAW_TIMER );
@ -1156,6 +1170,7 @@ void Hud::Refresh( int clientNumber )
} }
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
} }
#endif #endif
@ -1182,7 +1197,8 @@ void Hud::ScaleOverTime( float time, short w, short h )
fade_scale_w_target = w; fade_scale_w_target = w;
fade_scale_h_target = h; fade_scale_h_target = h;
#ifdef GAME_DLL // FIXME: delete
/*
width = w; width = w;
height = h; height = h;
@ -1194,7 +1210,7 @@ void Hud::ScaleOverTime( float time, short w, short h )
gi.MSG_WriteShort( w ); gi.MSG_WriteShort( w );
gi.MSG_WriteShort( h ); gi.MSG_WriteShort( h );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif */
} }
#ifdef GAME_DLL #ifdef GAME_DLL
@ -1235,6 +1251,7 @@ void Hud::Set3D( Vector vector_or_offset, qboolean alwaysOnScreen, qboolean hasD
isDimensional = true; isDimensional = true;
/*
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
@ -1250,19 +1267,20 @@ void Hud::Set3D( Vector vector_or_offset, qboolean alwaysOnScreen, qboolean hasD
gi.MSG_WriteBits( !!hasDepth, 1 ); gi.MSG_WriteBits( !!hasDepth, 1 );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif #endif
*/
} }
void Hud::SetNon3D() void Hud::SetNon3D()
{ {
isDimensional = false; isDimensional = false;
#ifdef GAME_DLL // FIXME?
/*
SetBroadcast(); SetBroadcast();
gi.MSG_StartCGM( CGM_HUDDRAW_BREAK3D ); gi.MSG_StartCGM( CGM_HUDDRAW_BREAK3D );
WriteNumber(); WriteNumber();
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif */
} }
void Hud::SetAlignX( hudAlign_t align ) void Hud::SetAlignX( hudAlign_t align )
@ -1418,15 +1436,6 @@ void Hud::SetRectX( short value )
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
if( sv_reborn->integer )
{
gi.MSG_StartCGM( CGM_HUDDRAW_RECTX );
WriteNumber();
gi.MSG_WriteShort( ( short )value );
gi.MSG_EndCGM();
}
else
{
gi.MSG_StartCGM(CGM_HUDDRAW_RECT); gi.MSG_StartCGM(CGM_HUDDRAW_RECT);
WriteNumber(); WriteNumber();
gi.MSG_WriteShort((short)fade_move_x_target); gi.MSG_WriteShort((short)fade_move_x_target);
@ -1434,13 +1443,11 @@ void Hud::SetRectX( short value )
gi.MSG_WriteShort((short)width); gi.MSG_WriteShort((short)width);
gi.MSG_WriteShort((short)height); gi.MSG_WriteShort((short)height);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
}
#endif #endif
} }
void Hud::SetRectY( short value ) void Hud::SetRectY( short value )
{ {
//#ifdef CGAME_DLL
if( fade_move_y_first ) if( fade_move_y_first )
{ {
fade_move_y_target = value; fade_move_y_target = value;
@ -1451,22 +1458,10 @@ void Hud::SetRectY( short value )
y = value; y = value;
fade_move = false; fade_move = false;
} }
//#else
// y = value;
//#endif
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
if( sv_reborn->integer )
{
gi.MSG_StartCGM( CGM_HUDDRAW_RECTY );
WriteNumber();
gi.MSG_WriteShort( ( short )value );
gi.MSG_EndCGM();
}
else
{
gi.MSG_StartCGM(CGM_HUDDRAW_RECT); gi.MSG_StartCGM(CGM_HUDDRAW_RECT);
WriteNumber(); WriteNumber();
gi.MSG_WriteShort((short)fade_move_x_target); gi.MSG_WriteShort((short)fade_move_x_target);
@ -1474,7 +1469,6 @@ void Hud::SetRectY( short value )
gi.MSG_WriteShort((short)width); gi.MSG_WriteShort((short)width);
gi.MSG_WriteShort((short)height); gi.MSG_WriteShort((short)height);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
}
#endif #endif
} }
@ -1519,16 +1513,6 @@ void Hud::SetShader( const char * s, float w, float h )
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
if( sv_reborn->integer )
{
gi.MSG_StartCGM( CGM_HUDDRAW_RECTWH );
WriteNumber();
gi.MSG_WriteShort( ( short )width );
gi.MSG_WriteShort( ( short )height );
gi.MSG_EndCGM();
}
else
{
gi.MSG_StartCGM(CGM_HUDDRAW_RECT); gi.MSG_StartCGM(CGM_HUDDRAW_RECT);
WriteNumber(); WriteNumber();
gi.MSG_WriteShort((short)x); gi.MSG_WriteShort((short)x);
@ -1536,7 +1520,6 @@ void Hud::SetShader( const char * s, float w, float h )
gi.MSG_WriteShort((short)width); gi.MSG_WriteShort((short)width);
gi.MSG_WriteShort((short)height); gi.MSG_WriteShort((short)height);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
}
SetBroadcast(); SetBroadcast();
@ -1586,7 +1569,8 @@ void Hud::SetTimer( float time, float fade_at_time )
fade_timer_flags = TIMER_ACTIVE; fade_timer_flags = TIMER_ACTIVE;
#ifdef GAME_DLL // FIXME...
/*
SetBroadcast(); SetBroadcast();
gi.MSG_StartCGM( CGM_HUDDRAW_TIMER ); gi.MSG_StartCGM( CGM_HUDDRAW_TIMER );
@ -1595,7 +1579,7 @@ void Hud::SetTimer( float time, float fade_at_time )
gi.MSG_WriteFloat( fade_at_time ); gi.MSG_WriteFloat( fade_at_time );
gi.MSG_WriteBits( 0, 1 ); gi.MSG_WriteBits( 0, 1 );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif */
} }
void Hud::SetTimerUp( float time, float fade_at_time ) void Hud::SetTimerUp( float time, float fade_at_time )
@ -1612,6 +1596,7 @@ void Hud::SetTimerUp( float time, float fade_at_time )
fade_timer_flags = TIMER_ACTIVE | TIMER_UP; fade_timer_flags = TIMER_ACTIVE | TIMER_UP;
/*
#ifdef GAME_DLL #ifdef GAME_DLL
SetBroadcast(); SetBroadcast();
@ -1622,6 +1607,7 @@ void Hud::SetTimerUp( float time, float fade_at_time )
gi.MSG_WriteBits( 1, 1 ); gi.MSG_WriteBits( 1, 1 );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
#endif #endif
*/
} }
void Hud::SetVirtualSize( qboolean v ) void Hud::SetVirtualSize( qboolean v )

View file

@ -38,7 +38,7 @@ void HudWriteNumber( int num )
void HudDrawShader( int info, const char *name ) void HudDrawShader( int info, const char *name )
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x1B); gi.MSG_StartCGM(CGM_HUDDRAW_SHADER);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(name); // s = name (shader_name) gi.MSG_WriteString(name); // s = name (shader_name)
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -47,7 +47,7 @@ void HudDrawShader( int info, const char *name )
void HudDrawAlign( int info, int horizontalAlign, int verticalAlign ) void HudDrawAlign( int info, int horizontalAlign, int verticalAlign )
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x1C); gi.MSG_StartCGM(CGM_HUDDRAW_ALIGN);
HudWriteNumber( info ); // c = probably "info" HudWriteNumber( info ); // c = probably "info"
gi.MSG_WriteBits(horizontalAlign, 2); // value = 0,1,2 bits = 2 gi.MSG_WriteBits(horizontalAlign, 2); // value = 0,1,2 bits = 2
// 0 - left \ // 0 - left \
@ -66,7 +66,7 @@ void HudDrawAlign( int info, int horizontalAlign, int verticalAlign )
void HudDrawRect(int info, int x, int y, int width, int height) void HudDrawRect(int info, int x, int y, int width, int height)
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x1D); gi.MSG_StartCGM(CGM_HUDDRAW_RECT);
HudWriteNumber( info ); // c = probably "info" HudWriteNumber( info ); // c = probably "info"
gi.MSG_WriteShort(x); // c = probably "x" gi.MSG_WriteShort(x); // c = probably "x"
gi.MSG_WriteShort(y); // c = probably "y" gi.MSG_WriteShort(y); // c = probably "y"
@ -79,7 +79,7 @@ void HudDrawRect(int info, int x, int y, int width, int height)
void HudDrawVirtualSize(int info, int virtualScreen) void HudDrawVirtualSize(int info, int virtualScreen)
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x1E); gi.MSG_StartCGM(CGM_HUDDRAW_VIRTUALSIZE);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
/*__asm /*__asm
@ -116,7 +116,7 @@ void HudDrawColor(int info, float *color)
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x1F); gi.MSG_StartCGM(CGM_HUDDRAW_COLOR);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteByte(temp[0]); // c = color[2] gi.MSG_WriteByte(temp[0]); // c = color[2]
gi.MSG_WriteByte(temp[1]); // c = color[1] - Values can be messed up. To be tested. gi.MSG_WriteByte(temp[1]); // c = color[1] - Values can be messed up. To be tested.
@ -132,7 +132,7 @@ void HudDrawAlpha(int info, float alpha)
temp = (long int)(alpha*255.0f); temp = (long int)(alpha*255.0f);
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x20); gi.MSG_StartCGM(CGM_HUDDRAW_ALPHA);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteByte(temp); // c = alpha gi.MSG_WriteByte(temp); // c = alpha
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -144,7 +144,7 @@ void HudDrawAlpha(int info, float alpha)
void HudDrawString(int info, const char *string) void HudDrawString(int info, const char *string)
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x21); gi.MSG_StartCGM(CGM_HUDDRAW_STRING);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(string); // s = string (to show) gi.MSG_WriteString(string); // s = string (to show)
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -154,7 +154,7 @@ void HudDrawString(int info, const char *string)
void HudDrawFont(int info, const char *fontName) void HudDrawFont(int info, const char *fontName)
{ {
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM(0x22); gi.MSG_StartCGM(CGM_HUDDRAW_FONT);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(fontName); // s = fontName (to use) gi.MSG_WriteString(fontName); // s = fontName (to use)
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -163,6 +163,8 @@ void HudDrawFont(int info, const char *fontName)
void HudDraw3d( int index, vec3_t vector, int ent_num, qboolean bAlwaysShow, qboolean depth ) void HudDraw3d( int index, vec3_t vector, int ent_num, qboolean bAlwaysShow, qboolean depth )
{ {
// FIXME...
/*
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM( CGM_HUDDRAW_3D ); gi.MSG_StartCGM( CGM_HUDDRAW_3D );
@ -176,10 +178,12 @@ void HudDraw3d( int index, vec3_t vector, int ent_num, qboolean bAlwaysShow, qbo
gi.MSG_WriteByte( bAlwaysShow ); gi.MSG_WriteByte( bAlwaysShow );
gi.MSG_WriteByte( depth ); gi.MSG_WriteByte( depth );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void HudDrawTimer( int index, float duration, float fade_out_time ) void HudDrawTimer( int index, float duration, float fade_out_time )
{ {
/*
gi.SetBroadcastAll(); gi.SetBroadcastAll();
gi.MSG_StartCGM( CGM_HUDDRAW_TIMER ); gi.MSG_StartCGM( CGM_HUDDRAW_TIMER );
@ -187,12 +191,13 @@ void HudDrawTimer( int index, float duration, float fade_out_time )
gi.MSG_WriteFloat( duration ); gi.MSG_WriteFloat( duration );
gi.MSG_WriteFloat( fade_out_time ); gi.MSG_WriteFloat( fade_out_time );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void iHudDrawShader( int cl_num, int info, const char *name ) void iHudDrawShader( int cl_num, int info, const char *name )
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x1B); gi.MSG_StartCGM(CGM_HUDDRAW_SHADER);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(name); // s = name (shader_name) gi.MSG_WriteString(name); // s = name (shader_name)
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -202,7 +207,7 @@ void iHudDrawShader( int cl_num, int info, const char *name )
void iHudDrawAlign(int cl_num, int info, int horizontalAlign, int verticalAlign ) void iHudDrawAlign(int cl_num, int info, int horizontalAlign, int verticalAlign )
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x1C); gi.MSG_StartCGM(CGM_HUDDRAW_ALIGN);
HudWriteNumber( info ); // c = probably "info" HudWriteNumber( info ); // c = probably "info"
gi.MSG_WriteBits(horizontalAlign, 2); // value = 0,1,2 bits = 2 gi.MSG_WriteBits(horizontalAlign, 2); // value = 0,1,2 bits = 2
// 0 - left \ // 0 - left \
@ -221,7 +226,7 @@ void iHudDrawAlign(int cl_num, int info, int horizontalAlign, int verticalAlign
void iHudDrawRect(int cl_num, int info, int x, int y, int width, int height) void iHudDrawRect(int cl_num, int info, int x, int y, int width, int height)
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x1D); gi.MSG_StartCGM(CGM_HUDDRAW_RECT);
HudWriteNumber( info ); // c = probably "info" HudWriteNumber( info ); // c = probably "info"
gi.MSG_WriteShort(x); // c = probably "x" gi.MSG_WriteShort(x); // c = probably "x"
gi.MSG_WriteShort(y); // c = probably "y" gi.MSG_WriteShort(y); // c = probably "y"
@ -232,6 +237,7 @@ void iHudDrawRect(int cl_num, int info, int x, int y, int width, int height)
void iHudDraw3d( int cl_num, int index, vec3_t vector, int ent_num, qboolean bAlwaysShow, qboolean depth ) void iHudDraw3d( int cl_num, int index, vec3_t vector, int ent_num, qboolean bAlwaysShow, qboolean depth )
{ {
/*
gi.MSG_SetClient( cl_num ); gi.MSG_SetClient( cl_num );
gi.MSG_StartCGM( CGM_HUDDRAW_3D ); gi.MSG_StartCGM( CGM_HUDDRAW_3D );
@ -245,10 +251,12 @@ void iHudDraw3d( int cl_num, int index, vec3_t vector, int ent_num, qboolean bAl
gi.MSG_WriteByte( bAlwaysShow ); gi.MSG_WriteByte( bAlwaysShow );
gi.MSG_WriteByte( depth ); gi.MSG_WriteByte( depth );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void iHudDrawTimer( int cl_num, int index, float duration, float fade_out_time ) void iHudDrawTimer( int cl_num, int index, float duration, float fade_out_time )
{ {
/*
gi.MSG_SetClient( cl_num ); gi.MSG_SetClient( cl_num );
gi.MSG_StartCGM( CGM_HUDDRAW_TIMER ); gi.MSG_StartCGM( CGM_HUDDRAW_TIMER );
@ -256,12 +264,13 @@ void iHudDrawTimer( int cl_num, int index, float duration, float fade_out_time )
gi.MSG_WriteFloat( duration ); gi.MSG_WriteFloat( duration );
gi.MSG_WriteFloat( fade_out_time ); gi.MSG_WriteFloat( fade_out_time );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void iHudDrawVirtualSize(int cl_num, int info, int virtualScreen) void iHudDrawVirtualSize(int cl_num, int info, int virtualScreen)
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x1E); gi.MSG_StartCGM(CGM_HUDDRAW_VIRTUALSIZE);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteBits(!!virtualScreen, 1); // value = ? bits = 1 gi.MSG_WriteBits(!!virtualScreen, 1); // value = ? bits = 1
@ -285,7 +294,7 @@ void iHudDrawColor(int cl_num, int info, float *color)
temp[2] = (long int)(color[2]*255.0f); temp[2] = (long int)(color[2]*255.0f);
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x1F); gi.MSG_StartCGM(CGM_HUDDRAW_COLOR);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteByte(temp[0]); // c = color[2] gi.MSG_WriteByte(temp[0]); // c = color[2]
gi.MSG_WriteByte(temp[1]); // c = color[1] - Values can be messed up. To be tested. gi.MSG_WriteByte(temp[1]); // c = color[1] - Values can be messed up. To be tested.
@ -301,7 +310,7 @@ void iHudDrawAlpha(int cl_num, int info, float alpha)
temp = (long int)(alpha*255.0f); temp = (long int)(alpha*255.0f);
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x20); gi.MSG_StartCGM(CGM_HUDDRAW_ALPHA);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteByte(temp); // c = alpha gi.MSG_WriteByte(temp); // c = alpha
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -313,7 +322,7 @@ void iHudDrawAlpha(int cl_num, int info, float alpha)
void iHudDrawString( int cl_num, int info, const char *string ) void iHudDrawString( int cl_num, int info, const char *string )
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x21); gi.MSG_StartCGM(CGM_HUDDRAW_STRING);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(string); // s = string (to show) gi.MSG_WriteString(string); // s = string (to show)
gi.MSG_EndCGM(); gi.MSG_EndCGM();
@ -323,7 +332,7 @@ void iHudDrawString( int cl_num, int info, const char *string )
void iHudDrawFont( int cl_num, int info, const char *fontName ) void iHudDrawFont( int cl_num, int info, const char *fontName )
{ {
gi.MSG_SetClient(cl_num); gi.MSG_SetClient(cl_num);
gi.MSG_StartCGM(0x22); gi.MSG_StartCGM(CGM_HUDDRAW_FONT);
HudWriteNumber( info ); // c = info HudWriteNumber( info ); // c = info
gi.MSG_WriteString(fontName); // s = fontName (to use) gi.MSG_WriteString(fontName); // s = fontName (to use)
gi.MSG_EndCGM(); gi.MSG_EndCGM();

View file

@ -1149,6 +1149,8 @@ void Item::updatePrefix
return; return;
} }
// FIXME: delete
/*
Entity *ent = ev->GetEntity( 1 ); Entity *ent = ev->GetEntity( 1 );
gi.MSG_SetClient( ent->edict - g_entities ); gi.MSG_SetClient( ent->edict - g_entities );
@ -1157,6 +1159,7 @@ void Item::updatePrefix
gi.MSG_WriteString( item_name.c_str() ); gi.MSG_WriteString( item_name.c_str() );
gi.MSG_WriteString( m_sVMprefix.c_str() ); gi.MSG_WriteString( m_sVMprefix.c_str() );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
qboolean Item::IsItemCool qboolean Item::IsItemCool

View file

@ -5790,9 +5790,9 @@ void Player::Pain
{ {
gi.MSG_SetClient( attacker->edict - g_entities ); gi.MSG_SetClient( attacker->edict - g_entities );
if( IsDead() ) if( IsDead() )
gi.MSG_StartCGM( 36 ); gi.MSG_StartCGM(CGM_NOTIFY_KILL);
else else
gi.MSG_StartCGM( 35 ); gi.MSG_StartCGM(CGM_NOTIFY_HIT);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
} }
@ -6528,6 +6528,8 @@ void Player::ClientMove
{ {
m_bShowingHint = false; m_bShowingHint = false;
// FIXME: delete
/*
if (sv_reborn->integer) if (sv_reborn->integer)
{ {
gi.MSG_SetClient(edict - g_entities); gi.MSG_SetClient(edict - g_entities);
@ -6537,6 +6539,7 @@ void Player::ClientMove
gi.MSG_WriteString(""); gi.MSG_WriteString("");
gi.MSG_EndCGM(); gi.MSG_EndCGM();
} }
*/
} }
oldorigin = origin; oldorigin = origin;
@ -13221,7 +13224,7 @@ void Player::EventDMMessage
if( bInstaMessage ) if( bInstaMessage )
{ {
gi.MSG_SetClient( i ); gi.MSG_SetClient( i );
gi.MSG_StartCGM( 37 ); gi.MSG_StartCGM(CGM_VOICE_CHAT);
gi.MSG_WriteCoord( m_vViewPos[ 0 ] ); gi.MSG_WriteCoord( m_vViewPos[ 0 ] );
gi.MSG_WriteCoord( m_vViewPos[ 1 ] ); gi.MSG_WriteCoord( m_vViewPos[ 1 ] );
gi.MSG_WriteCoord( m_vViewPos[ 2 ] ); gi.MSG_WriteCoord( m_vViewPos[ 2 ] );
@ -14288,15 +14291,15 @@ void Player::ModifyHeightFloat
client->ps.pm_flags &= ~( PMF_DUCKED | PMF_VIEW_PRONE | PMF_VIEW_DUCK_RUN | PMF_VIEW_JUMP_START ); client->ps.pm_flags &= ~( PMF_DUCKED | PMF_VIEW_PRONE | PMF_VIEW_DUCK_RUN | PMF_VIEW_JUMP_START );
if( sv_reborn->integer ) // FIXME...
{ /*
gi.MSG_SetClient(edict - g_entities); gi.MSG_SetClient(edict - g_entities);
gi.MSG_StartCGM(CGM_MODHEIGHTFLOAT); gi.MSG_StartCGM(CGM_MODHEIGHTFLOAT);
gi.MSG_WriteLong(height); gi.MSG_WriteLong(height);
gi.MSG_WriteFloat(max_z); gi.MSG_WriteFloat(max_z);
gi.MSG_EndCGM(); gi.MSG_EndCGM();
} */
} }
void Player::PlayLocalSound void Player::PlayLocalSound
@ -14330,8 +14333,8 @@ void Player::PlayLocalSound
return; return;
} }
if( sv_reborn->integer ) // FIXME...
{ /*
gi.MSG_SetClient( client->ps.clientNum ); gi.MSG_SetClient( client->ps.clientNum );
gi.MSG_StartCGM( CGM_PLAYLOCALSOUND ); gi.MSG_StartCGM( CGM_PLAYLOCALSOUND );
@ -14342,7 +14345,7 @@ void Player::PlayLocalSound
gi.MSG_EndCGM(); gi.MSG_EndCGM();
return; return;
} */
if( loop ) if( loop )
{ {
@ -14499,11 +14502,14 @@ void Player::SetLocalSoundRate
gi.MSG_SetClient( client->ps.clientNum ); gi.MSG_SetClient( client->ps.clientNum );
// FIXME...
/*
gi.MSG_StartCGM( CGM_SETLOCALSOUNDRATE ); gi.MSG_StartCGM( CGM_SETLOCALSOUNDRATE );
gi.MSG_WriteString( found ); gi.MSG_WriteString( found );
gi.MSG_WriteFloat( rate ); gi.MSG_WriteFloat( rate );
gi.MSG_WriteFloat( time ); gi.MSG_WriteFloat( time );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void Player::SetSpeed void Player::SetSpeed
@ -14588,12 +14594,15 @@ void Player::SetVMASpeed
vma->name = name; vma->name = name;
vma->speed = speed; vma->speed = speed;
// FIXME...
/*
gi.MSG_SetClient( edict - g_entities ); gi.MSG_SetClient( edict - g_entities );
gi.MSG_StartCGM( CGM_SETVMASPEED ); gi.MSG_StartCGM( CGM_SETVMASPEED );
gi.MSG_WriteString( name ); gi.MSG_WriteString( name );
gi.MSG_WriteFloat( speed ); gi.MSG_WriteFloat( speed );
gi.MSG_EndCGM(); gi.MSG_EndCGM();
*/
} }
void Player::StopLocalSound void Player::StopLocalSound
@ -14621,21 +14630,9 @@ void Player::StopLocalSound
return; return;
} }
if( level.reborn )
{
gi.MSG_SetClient( client->ps.clientNum );
gi.MSG_StartCGM( CGM_STOPLOCALSOUND );
gi.MSG_WriteString( found );
gi.MSG_WriteFloat( time );
gi.MSG_EndCGM();
}
else
{
edict->s.loopSound = 0; edict->s.loopSound = 0;
gi.StopSound(entnum, CHAN_LOCAL); gi.StopSound(entnum, CHAN_LOCAL);
} }
}
void Player::UseHeld void Player::UseHeld
( (

View file

@ -1785,11 +1785,11 @@ void Explosion::MakeExplosionEffect
if( !sEffect.icmp( "grenade" ) ) if( !sEffect.icmp( "grenade" ) )
{ {
gi.MSG_StartCGM( 12 ); gi.MSG_StartCGM(CGM_EXPLOSION_EFFECT_1);
} }
else else
{ {
gi.MSG_StartCGM( 13 ); gi.MSG_StartCGM(CGM_EXPLOSION_EFFECT_2);
} }
gi.MSG_WriteCoord( origin[ 0 ] ); gi.MSG_WriteCoord( origin[ 0 ] );
@ -2034,7 +2034,7 @@ float BulletAttack
if( ent->edict->solid == 3 && trace.shaderNum >= 0 ) if( ent->edict->solid == 3 && trace.shaderNum >= 0 )
{ {
gi.SetBroadcastVisible( trace.endpos, 0 ); gi.SetBroadcastVisible( trace.endpos, 0 );
gi.MSG_StartCGM( 6 ); gi.MSG_StartCGM(CGM_BULLET_6);
gi.MSG_WriteCoord( trace.endpos[ 0 ] ); gi.MSG_WriteCoord( trace.endpos[ 0 ] );
gi.MSG_WriteCoord( trace.endpos[ 1 ] ); gi.MSG_WriteCoord( trace.endpos[ 1 ] );
gi.MSG_WriteCoord( trace.endpos[ 2 ] ); gi.MSG_WriteCoord( trace.endpos[ 2 ] );
@ -2192,7 +2192,7 @@ float BulletAttack
if( trace.contents > 0 && trace.surfaceFlags & 0xFFFE000 ) if( trace.contents > 0 && trace.surfaceFlags & 0xFFFE000 )
{ {
gi.SetBroadcastVisible( trace.endpos, NULL ); gi.SetBroadcastVisible( trace.endpos, NULL );
gi.MSG_StartCGM( 6 ); gi.MSG_StartCGM(CGM_BULLET_6);
gi.MSG_WriteCoord( trace.endpos[ 0 ] ); gi.MSG_WriteCoord( trace.endpos[ 0 ] );
gi.MSG_WriteCoord( trace.endpos[ 1 ] ); gi.MSG_WriteCoord( trace.endpos[ 1 ] );
gi.MSG_WriteCoord( trace.endpos[ 2 ] ); gi.MSG_WriteCoord( trace.endpos[ 2 ] );
@ -2203,7 +2203,7 @@ float BulletAttack
else if( trace.location >= 0 && ent->IsSubclassOfPlayer() ) else if( trace.location >= 0 && ent->IsSubclassOfPlayer() )
{ {
gi.SetBroadcastVisible( trace.endpos, NULL ); gi.SetBroadcastVisible( trace.endpos, NULL );
gi.MSG_StartCGM( 7 ); gi.MSG_StartCGM(CGM_BULLET_7);
gi.MSG_WriteCoord( trace.endpos[ 0 ] ); gi.MSG_WriteCoord( trace.endpos[ 0 ] );
gi.MSG_WriteCoord( trace.endpos[ 1 ] ); gi.MSG_WriteCoord( trace.endpos[ 1 ] );
gi.MSG_WriteCoord( trace.endpos[ 2 ] ); gi.MSG_WriteCoord( trace.endpos[ 2 ] );
@ -2250,7 +2250,7 @@ float BulletAttack
{ {
if( iTracerCount ) if( iTracerCount )
{ {
gi.MSG_StartCGM( 1 ); gi.MSG_StartCGM(CGM_BULLET_1);
gi.MSG_WriteCoord( vBarrel[ 0 ] ); gi.MSG_WriteCoord( vBarrel[ 0 ] );
gi.MSG_WriteCoord( vBarrel[ 1 ] ); gi.MSG_WriteCoord( vBarrel[ 1 ] );
@ -2258,7 +2258,7 @@ float BulletAttack
} }
else else
{ {
gi.MSG_StartCGM( 2 ); gi.MSG_StartCGM(CGM_BULLET_2);
} }
gi.MSG_WriteCoord( start[ 0 ] ); gi.MSG_WriteCoord( start[ 0 ] );
@ -2273,7 +2273,7 @@ float BulletAttack
{ {
if( iTracerCount ) if( iTracerCount )
{ {
gi.MSG_StartCGM( 3 ); gi.MSG_StartCGM(CGM_BULLET_3);
gi.MSG_WriteCoord( vBarrel[ 0 ] ); gi.MSG_WriteCoord( vBarrel[ 0 ] );
gi.MSG_WriteCoord( vBarrel[ 1 ] ); gi.MSG_WriteCoord( vBarrel[ 1 ] );
@ -2286,7 +2286,7 @@ float BulletAttack
} }
else else
{ {
gi.MSG_StartCGM( 4 ); gi.MSG_StartCGM(CGM_BULLET_4);
} }
gi.MSG_WriteCoord( start[ 0 ] ); gi.MSG_WriteCoord( start[ 0 ] );
@ -2349,7 +2349,7 @@ void FakeBulletAttack
( *piTracerCount )++; ( *piTracerCount )++;
if( *piTracerCount == iTracerFrequency ) if( *piTracerCount == iTracerFrequency )
{ {
gi.MSG_StartCGM( 25 ); gi.MSG_StartCGM(CGM_BULLET_NO_BARREL_1);
gi.MSG_WriteCoord( vBarrel[ 0 ] ); gi.MSG_WriteCoord( vBarrel[ 0 ] );
gi.MSG_WriteCoord( vBarrel[ 1 ] ); gi.MSG_WriteCoord( vBarrel[ 1 ] );
gi.MSG_WriteCoord( vBarrel[ 2 ] ); gi.MSG_WriteCoord( vBarrel[ 2 ] );
@ -2357,12 +2357,12 @@ void FakeBulletAttack
} }
else else
{ {
gi.MSG_StartCGM( 26 ); gi.MSG_StartCGM(CGM_BULLET_NO_BARREL_2);
} }
} }
else else
{ {
gi.MSG_StartCGM( 26 ); gi.MSG_StartCGM(CGM_BULLET_NO_BARREL_2);
} }
gi.MSG_WriteCoord( start[ 0 ] ); gi.MSG_WriteCoord( start[ 0 ] );

View file

@ -151,7 +151,7 @@ void WindowObject::WindowKilled( Event *ev )
vCenter = origin + mins + maxs; vCenter = origin + mins + maxs;
gi.SetBroadcastVisible( vCenter, vCenter ); gi.SetBroadcastVisible( vCenter, vCenter );
gi.MSG_StartCGM( 24 ); gi.MSG_StartCGM(CGM_MAKE_WINDOW_DEBRIS);
gi.MSG_WriteCoord( vCenter[ 0 ] ); gi.MSG_WriteCoord( vCenter[ 0 ] );
gi.MSG_WriteCoord( vCenter[ 1 ] ); gi.MSG_WriteCoord( vCenter[ 1 ] );
gi.MSG_WriteCoord( vCenter[ 2 ] ); gi.MSG_WriteCoord( vCenter[ 2 ] );

View file

@ -485,34 +485,6 @@ enum {
#define HUD_MESSAGE_CHAT_WHITE "\x02" #define HUD_MESSAGE_CHAT_WHITE "\x02"
#define HUD_MESSAGE_CHAT_RED "\x04" #define HUD_MESSAGE_CHAT_RED "\x04"
#define CGM_HUDDRAW_SHADER 27
#define CGM_HUDDRAW_ALIGN 28
#define CGM_HUDDRAW_RECT 29
#define CGM_HUDDRAW_VIRTUALSIZE 30
#define CGM_HUDDRAW_COLOR 31
#define CGM_HUDDRAW_ALPHA 32
#define CGM_HUDDRAW_STRING 33
#define CGM_HUDDRAW_FONT 34
#define CGM_HUDDRAW_TIMER 38
#define CGM_HUDDRAW_3D 39
#define CGM_HUDDRAW_BREAK3D 40
#define CGM_HUDDRAW_FADE 41
#define CGM_HUDDRAW_MOVE 42
#define CGM_HUDDRAW_SCALE 43
#define CGM_VIEWMODELANIM 44
#define CGM_VIEWMODELPREFIX 45
#define CGM_MODHEIGHTFLOAT 46
#define CGM_SETVMASPEED 47
#define CGM_HINTSTRING 48
#define CGM_PLAYLOCALSOUND 49
#define CGM_SETLOCALSOUNDRATE 50
#define CGM_STOPLOCALSOUND 51
#define CGM_HUDDRAW_RECTX 52
#define CGM_HUDDRAW_RECTY 53
#define CGM_HUDDRAW_RECTWH 54
#define CGM_REPLICATION 55
#define CGM_HUDDRAW_DELETE 56
extern vec4_t g_color_table[8]; extern vec4_t g_color_table[8];
#define MAKERGB( v, r, g, b ) v[0]=r;v[1]=g;v[2]=b #define MAKERGB( v, r, g, b ) v[0]=r;v[1]=g;v[2]=b