v3f camera_pos, smooth_localcam;
v2f angles;
- m4x3f camera, camera_inverse;
/* animation */
double jump_time;
{
player_do_motion();
}
-
- player_audio(); /* FUTURE: can probably move this to post()
- BUT, it uses deltas from fixed step physics,
- AND this *might* be what we want for realtime
- audio, anyway. */
}
static void player_update_post(void)
if( freecam )
player_freecam();
- player_camera_update();
+ /* CAMERA POSITIONING: LAYER 0 */
+ v2_copy( player.angles, camera_angles );
+ v3_copy( player.camera_pos, camera_pos );
+ camera_update();
+
+ player_audio();
}
-static void draw_player(void) /* 3 */
+static void draw_player( m4x3f cam )
{
if( player.is_dead )
player_model_copy_ragdoll();
shader_viewchar_use();
vg_tex2d_bind( &tex_characters, 0 );
shader_viewchar_uTexMain( 0 );
- shader_viewchar_uCamera( player.camera[3] );
+ shader_viewchar_uCamera( cam[3] );
shader_viewchar_uPv( vg.pv );
shader_link_standard_ub( _shader_viewchar.id, 2 );
glUniformMatrix4x3fv( _uniform_viewchar_uTransforms,