From: hgn Date: Thu, 29 May 2025 17:22:00 +0000 (+0100) Subject: AAAAAAAAAAAAAAAAAAAAAAAAAAAA X-Git-Url: https://harrygodden.com/git/?a=commitdiff_plain;h=1c49523cb711e8393e455551796817a5607a2969;p=carveJwlIkooP6JGAAIwe30JlM.git AAAAAAAAAAAAAAAAAAAAAAAAAAAA --- diff --git a/content_skaterift/maps/dev_tutorial/main.mdl b/content_skaterift/maps/dev_tutorial/main.mdl index 9b6ec4b..7484dce 100644 Binary files a/content_skaterift/maps/dev_tutorial/main.mdl and b/content_skaterift/maps/dev_tutorial/main.mdl differ diff --git a/content_skaterift/maps/mp_line1/main.mdl b/content_skaterift/maps/mp_line1/main.mdl index 79141db..dac746d 100644 Binary files a/content_skaterift/maps/mp_line1/main.mdl and b/content_skaterift/maps/mp_line1/main.mdl differ diff --git a/content_skaterift/maps/mp_mtzero/before.mdl b/content_skaterift/maps/mp_mtzero/before.mdl index 640bbf3..23b5945 100644 Binary files a/content_skaterift/maps/mp_mtzero/before.mdl and b/content_skaterift/maps/mp_mtzero/before.mdl differ diff --git a/content_skaterift/maps/mp_mtzero/main.mdl b/content_skaterift/maps/mp_mtzero/main.mdl index 3134faf..e31185d 100644 Binary files a/content_skaterift/maps/mp_mtzero/main.mdl and b/content_skaterift/maps/mp_mtzero/main.mdl differ diff --git a/content_skaterift/maps/mp_spawn/main.mdl b/content_skaterift/maps/mp_spawn/main.mdl index 58b4d7d..3b401b8 100644 Binary files a/content_skaterift/maps/mp_spawn/main.mdl and b/content_skaterift/maps/mp_spawn/main.mdl differ diff --git a/content_skaterift/sound/bell.ogg b/content_skaterift/sound/bell.ogg new file mode 100644 index 0000000..3c5d7eb Binary files /dev/null and b/content_skaterift/sound/bell.ogg differ diff --git a/src/metascene.c b/src/metascene.c index 8e8856e..3ebb161 100644 --- a/src/metascene.c +++ b/src/metascene.c @@ -44,7 +44,10 @@ struct cs_instance *_cutscene_get_first_model_instance( const char *mdl_name ) void _cutscene_unload(void) { vg_info( "Unloading cutscene\n" ); + vg_audio_lock(); vg_audio_fadeout_flagged_audio( AUDIO_FLAG_CUTSCENE, 1.0f ); + vg_audio_set_flagged_pause( AUDIO_FLAG_CUTSCENE, 0 ); + vg_audio_unlock(); for( u32 i=0; i<_cutscene.unique_refs; i ++ ) mdl_sync_std_unload( &_cutscene.refs[i].mdl ); @@ -465,7 +468,16 @@ void cutscene_update( f32 delta ) if( _cutscene.state == k_cutscene_state_unloading ) { if( !vg_audio_flagged_stopped( AUDIO_FLAG_CUTSCENE ) ) + { + static u32 ticker = 0; + ticker ++; + if( ticker > 50 ) + { + vg_low( "waiting for audio to stop...\n" ); + ticker = 0; + } return; + } vg_allocator_free( _cutscene.arena ); _cutscene.arena = NULL; @@ -473,6 +485,7 @@ void cutscene_update( f32 delta ) _cutscene.marker_this_frame = NULL; _cutscene.subtitle = NULL; _cutscene.raiser_entity = 0; + vg_info( "Finished unloading cutscene\n" ); return; } diff --git a/src/world_load.c b/src/world_load.c index 4ff46c8..528aec8 100644 --- a/src/world_load.c +++ b/src/world_load.c @@ -520,7 +520,10 @@ void skaterift_load_world_start( addon_id addon_id, bool preview ) if( (_cutscene.state != k_cutscene_state_none) && (_cutscene.state != k_cutscene_state_unloading) ) _cutscene_unload(); + vg_audio_lock(); vg_audio_fadeout_flagged_audio( AUDIO_FLAG_WORLD, 1.0f ); + vg_audio_set_flagged_pause( AUDIO_FLAG_WORLD, 0 ); + vg_audio_unlock(); } _world.loader_instance = world;