I updated my original post to clarify that I am trying to teleport player A directly in front of player B and make player A face player B. Okay, I think I understand the first part, angles - origin = direction, but I'm lost on the rest of it. What is offset, a vector? How do you determine the values to put in the offset? If I wanted to teleport the person 45 units in front of the other, would that be {45.0f, 45.0f, 0}? As far as the parameters go:
void _VectorAdd( const vec3_t veca, const vec3_t vecb, vec3_t out ) {
out[0] = veca[0]+vecb[0];
out[1] = veca[1]+vecb[1];
out[2] = veca[2]+vecb[2];
}
void _VectorSubtract( const vec3_t veca, const vec3_t vecb, vec3_t out ) {
out[0] = veca[0]-vecb[0];
out[1] = veca[1]-vecb[1];
out[2] = veca[2]-vecb[2];
}
void _VectorMA( const vec3_t veca, float scale, const vec3_t vecb, vec3_t vecc) {
vecc[0] = veca[0] + scale*vecb[0];
vecc[1] = veca[1] + scale*vecb[1];
vecc[2] = veca[2] + scale*vecb[2];
}