My question today is, if there is a not to complicated (still a coding dope

Code: Select all
refdef_t refdef;
memset( &refdef, 0, sizeof( refdef ) );
VectorCopy( origin, refdef.vieworigin );
AnglesToAxis( angles, refdef.viewaxis );
refdef.fov_x = 30;
refdef.fov_y = 30;
refdef.x = 0;
refdef.y = 0;
refdef.width = 128;
refdef.height = 128;
refdef.time = cg.time;
trap_R_ClearScene();
//What you want to render goes here, for example here we render just about everything
CG_AddPacketEntities();
CG_AddMarks();
CG_AddParticles ();
CG_AddLocalEntities();
trap_R_RenderScene( &refdef );
Code: Select all
yourEntity->r.svFlags = SVF_PORTAL|SVF_BROADCAST;
VectorCopy(location,yourEntity->s.origin2);
//where location is a vec3_t.