X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=player_audio.h;h=757f495a1b761e3d94da2bafad365d5828cad33a;hb=a98ce96041b248580c0447bf87d4c6106483cade;hp=f46d67084171c38961fb437aa4931aa257fa3018;hpb=d00b1df8f80e4714dc2f9aa2189d242bb4d09a2f;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/player_audio.h b/player_audio.h index f46d670..757f495 100644 --- a/player_audio.h +++ b/player_audio.h @@ -26,7 +26,7 @@ static void player_audio(void) audio_lock(); - double revert_delta = vg_time - last_revert; + double revert_delta = vg.time - last_revert; if( phys->on_board && (!_air && l2) && (fabsf(phys->slip) > 0.5f) && (revert_delta > 0.7) ) { @@ -35,11 +35,11 @@ static void player_audio(void) audio_player_set_vol( &audio_player_extra, 2.0f ); audio_player_playclip( &audio_player_extra, &audio_lands[rand()%5] ); - last_revert = vg_time; + last_revert = vg.time; } static float air = 0.0f; - air = vg_lerpf(air, phys->in_air? 1.0f: 0.0f, 5.0f*ktimestep); + air = vg_lerpf(air, phys->in_air? 1.0f: 0.0f, 5.0f*VG_TIMESTEP_FIXED ); /* Spacial info */ v3f ears = { 1.0f,0.0f,0.0f };