X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=skaterift.c;h=e0d8a316aad848bd3d22a220f354698cb0333330;hb=0136a935c00e3ea1f231fd88b38b44982fd409ac;hp=b0324cc7facb93a1fcc64f15f8d40d143ddeba7e;hpb=192990d6d24e53749ca046fef808a63cf162ab8a;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/skaterift.c b/skaterift.c index b0324cc..e0d8a31 100644 --- a/skaterift.c +++ b/skaterift.c @@ -257,17 +257,16 @@ VG_STATIC void vg_load(void) world_audio_init(); /* 'systems' are completely loaded now */ -#if 0 - strcpy( world.world_name, "maps/mp_mtzero.mdl" ); - strcpy( world.world_name, "maps/mp_gridmap.mdl" ); -#endif /* load home world */ world_load( &world_global.worlds[0], "maps/mp_home.mdl" ); + +#if 0 world_load( &world_global.worlds[1], "maps/mp_gridmap.mdl" ); world_load( &world_global.worlds[2], "maps/mp_mtzero.mdl" ); world_link_nonlocal_gates( 0, 1 ); world_link_nonlocal_gates( 0, 2 ); +#endif vg_console_load_autos(); } @@ -335,6 +334,14 @@ VG_STATIC void vg_update_post(void) player__post_update( &localplayer ); + /* FIXME: TEMP */ + audio_lock(); + v3f ears = { 1.0f,0.0f,0.0f }; + m3x3_mulv( main_camera.transform, ears, ears ); + v3_copy( ears, vg_audio.listener_ears ); + v3_copy( main_camera.transform[3], vg_audio.listener_pos ); + audio_unlock(); + #if 0 menu_update(); vehicle_update_post(); @@ -522,11 +529,13 @@ VG_STATIC void vg_render(void) glClear( GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT ); render_main_game(); + + m4x4_copy( main_camera.mtx.pv, vg.pv ); /* Other shite */ glDisable(GL_BLEND); glDisable( GL_DEPTH_TEST ); - vg_lines_drawall( (float *)main_camera.mtx.pv ); + vg_lines_drawall(); glViewport( 0,0, vg.window_x, vg.window_y ); }