Remove dead code and assignments

This commit is contained in:
Yamagi Burmeister 2012-06-01 17:05:40 +02:00
parent 40f8422f1b
commit 0e1520d29a
9 changed files with 14 additions and 37 deletions

View File

@ -1419,7 +1419,6 @@ void CL_FlyParticles (vec3_t origin, int count) {
angle = ltime * avelocities[i][1];
sp = (float)sin(angle);
cp = (float)cos(angle);
angle = ltime * avelocities[i][2];
forward[0] = cp*cy;
forward[1] = cp*sy;
@ -1508,7 +1507,6 @@ void CL_BfgParticles (entity_t *ent) {
angle = ltime * avelocities[i][1];
sp = (float)sin(angle);
cp = (float)cos(angle);
angle = ltime * avelocities[i][2];
forward[0] = cp*cy;
forward[1] = cp*sy;

View File

@ -216,13 +216,9 @@ void CL_PredictMovement (void) {
/* copy current state to pmove */
pm.trace = CL_PMTrace;
pm.pointcontents = CL_PMpointcontents;
pm_airaccelerate = atof(cl.configstrings[CS_AIRACCEL]);
pm.s = cl.frame.playerstate.pmove;
frame = 0;
VectorSet (pm.mins, -16, -16, -24);
VectorSet (pm.maxs, 16, 16, 32);

View File

@ -721,7 +721,6 @@ void DrawHUDString (char *string, int x, int y, int centerwidth, int xor) {
if (*string) {
string++; /* skip the \n */
x = margin;
y += 8;
}
}
@ -805,7 +804,6 @@ void SCR_ExecuteLayoutString (char *s) {
x = 0;
y = 0;
width = 3;
while (s) {
token = COM_Parse (&s);
@ -849,7 +847,6 @@ void SCR_ExecuteLayoutString (char *s) {
if (!strcmp(token, "pic")) {
/* draw a pic from a stat number */
token = COM_Parse (&s);
value = cl.frame.playerstate.stats[atoi(token)];
index = atoi(token);
if (index < 0 || index >= sizeof(cl.frame.playerstate.stats))

View File

@ -478,12 +478,12 @@ void CL_ParseSteam (void) {
s->nextthink = cl.time;
} else {
cnt = MSG_ReadByte (&net_message);
MSG_ReadByte (&net_message);
MSG_ReadPos (&net_message, pos);
MSG_ReadDir (&net_message, dir);
r = MSG_ReadByte (&net_message);
magnitude = MSG_ReadShort (&net_message);
magnitude = MSG_ReadLong (&net_message); /* really interval */
MSG_ReadByte (&net_message);
MSG_ReadShort (&net_message);
MSG_ReadLong (&net_message); /* really interval */
}
} else {

View File

@ -391,11 +391,9 @@ qboolean
OGG_Open ( ogg_seek_t type, int offset )
{
int size; /* File size. */
int pos; /* Absolute position. */
int pos = -1; /* Absolute position. */
int res; /* Error indicator. */
pos = -1;
switch ( type )
{
case ABS:

View File

@ -511,7 +511,6 @@ R_ResampleTexture ( unsigned *in, int inwidth, int inheight, unsigned *out, int
{
inrow = in + inwidth * (int) ( ( i + 0.25 ) * inheight / outheight );
inrow2 = in + inwidth * (int) ( ( i + 0.75 ) * inheight / outheight );
frac = fracstep >> 1;
for ( j = 0; j < outwidth; j++ )
{
@ -1085,7 +1084,7 @@ R_FindImage ( char *name, imagetype_t type )
else
{
/* Upload TGA */
image = R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
}
if( !pic )
@ -1104,7 +1103,7 @@ R_FindImage ( char *name, imagetype_t type )
}
else
{
/* Upload JPEG */
/* Upload JPEG or TGA */
image = R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
}
}
@ -1140,7 +1139,7 @@ R_FindImage ( char *name, imagetype_t type )
else
{
/* Upload TGA */
image = R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
}
if( !pic )
@ -1150,7 +1149,7 @@ R_FindImage ( char *name, imagetype_t type )
}
else
{
/* Upload JPEG */
/* Upload JPEG or TGA */
image = R_LoadPic( name, pic, width, realwidth, height, realheight, type, 32 );
}

View File

@ -294,13 +294,12 @@ R_DrawAliasFrameLerp ( dmdl_t *paliashdr, float backlerp )
void
R_DrawAliasShadow ( dmdl_t *paliashdr, int posenum )
{
int *order;
int *order;
vec3_t point;
float height, lheight;
float height = 0, lheight;
int count;
lheight = currententity->origin [ 2 ] - lightspot [ 2 ];
height = 0;
order = (int *) ( (byte *) paliashdr + paliashdr->ofs_glcmds );
height = -lheight + 0.1f;

View File

@ -149,9 +149,9 @@ SV_BroadcastCommand ( char *fmt, ... )
void
SV_Multicast ( vec3_t origin, multicast_t to )
{
client_t *client;
byte *mask;
int leafnum, cluster;
client_t *client;
byte *mask;
int leafnum = 0, cluster;
int j;
qboolean reliable;
int area1, area2;
@ -165,7 +165,6 @@ SV_Multicast ( vec3_t origin, multicast_t to )
}
else
{
leafnum = 0; /* just to avoid compiler warnings */
area1 = 0;
}
@ -180,7 +179,6 @@ SV_Multicast ( vec3_t origin, multicast_t to )
case MULTICAST_ALL_R:
reliable = true; /* intentional fallthrough */
case MULTICAST_ALL:
leafnum = 0;
mask = NULL;
break;

View File

@ -483,7 +483,6 @@ SV_PointContents ( vec3_t p )
int i, num;
int contents, c2;
int headnode;
float *angles;
/* get base contents from world */
contents = CM_PointContents( p, sv.models [ 1 ]->headnode );
@ -497,13 +496,6 @@ SV_PointContents ( vec3_t p )
/* might intersect, so do an exact clip */
headnode = SV_HullForEntity( hit );
angles = hit->s.angles;
if ( hit->solid != SOLID_BSP )
{
angles = vec3_origin; /* boxes don't rotate */
}
c2 = CM_TransformedPointContents( p, headnode, hit->s.origin, hit->s.angles );
contents |= c2;