All pastes #519658 Raw Edit

Unnamed

public c v1 · immutable
#519658 ·published 2007-05-29 18:47 UTC
rendered paste body
				if ( seth.value[VAR_AIMPREDICT] ){					// predict back to last snapshot					vec3_t dir;					if( !VectorCompare(  eth.entities[target].origin, vec3_origin ) &&						!VectorCompare(  history[target][0].trPos, vec3_origin ))					{																VectorSubtract( eth.entities[target].origin, history[target][0].trPos, dir );						float s = VectorLength( dir ) * seth.value[VAR_AIMPREDICT];						if( s < 50.0 ){							VectorScale( dir, seth.value[VAR_AIMPREDICT], dir ); 							//VectorNormalize2( dir, dir );							VectorAdd( eth.entities[target].head_visible_pt, dir, eth.entities[target].head_visible_pt );							VectorNormalize2( dir, dir );							printf("Moving %i %.4f back along {%.3f, %.3f, %.3f}\n", target, s, dir[0], dir[1], dir[2] );						} else							printf("s too big, ignoring\n");					} else						printf("null, ignoring\n");					//VectorCopy(eth.entities[target].head_visible_pt				}