X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=ent_objective.c;h=97e33d8cb5c54caf922fc167348a3b595c6f10eb;hb=fbc68c65e01838feb77f47b30994b45fcc39ebaf;hp=0cf5790a70c0ce690011c56abc5239302c83e6fb;hpb=22f62f001f21d1b91fefd9fc495c122d9ddf205a;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/ent_objective.c b/ent_objective.c index 0cf5790..97e33d8 100644 --- a/ent_objective.c +++ b/ent_objective.c @@ -21,13 +21,17 @@ static void ent_objective_pass( world_instance *world, ent_objective_pass( world, next ); else{ vg_info( "pass challenge point\n" ); + audio_lock(); audio_oneshot_3d( &audio_challenge[0], localplayer.rb.co, 30.0f, 1.0f ); + audio_unlock(); } } else { vg_success( "challenge win\n" ); + audio_lock(); audio_oneshot( &audio_challenge[2], 1.0f, 0.0f ); + audio_unlock(); world_static.challenge_target = NULL; world_static.challenge_timer = 0.0f; world_static.focused_entity = 0; @@ -107,8 +111,10 @@ static void ent_objective_call( world_instance *world, ent_call *call ){ ent_objective_pass( world, objective ); } else { + audio_lock(); audio_oneshot_3d( &audio_challenge[6], localplayer.rb.co, 30.0f, 1.0f ); + audio_unlock(); vg_error( "challenge failed\n" ); world_static.challenge_target = NULL; world_static.challenge_timer = 0.0f;