From 00d08b1e801d6b14fbfc07243271404cc7252e35 Mon Sep 17 00:00:00 2001 From: hgn Date: Wed, 21 Jun 2023 16:08:51 +0100 Subject: [PATCH] reverts --- player_skate.c | 6 +++++- player_skate.h | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/player_skate.c b/player_skate.c index 48d24bb..0362b93 100644 --- a/player_skate.c +++ b/player_skate.c @@ -851,6 +851,10 @@ VG_STATIC void skate_apply_steering_model( player_instance *player ) rate = 35.0f; top = 1.5f; } + + if( grab < 0.5f ){ + top *= 1.0f+v3_length( s->state.throw_v )*k_mmthrow_steer; + } } float current = v3_dot( player->rb.to_world[1], player->rb.w ), @@ -978,7 +982,7 @@ VG_STATIC void skate_apply_jump_model( player_instance *player ) s->state.jump_time = vg.time; audio_lock(); - audio_oneshot_3d( &audio_jumps[vg_randu32()%2], player->rb.co, 40.0f, 1.0f ); + audio_oneshot_3d( &audio_jumps[vg_randu32()%2], player->rb.co,40.0f,1.0f); audio_unlock(); } } diff --git a/player_skate.h b/player_skate.h index 5177763..b529a48 100644 --- a/player_skate.h +++ b/player_skate.h @@ -184,6 +184,7 @@ VG_STATIC float k_cog_damp = 0.02f, k_cog_mass_ratio = 0.9f, + k_mmthrow_steer = 1.0f, k_mmthrow_scale = 6.0f, k_mmcollect_lat = 2.0f, k_mmcollect_vert = 0.0f, @@ -244,6 +245,7 @@ VG_STATIC void player__skate_register(void) VG_VAR_F32( k_mmcollect_lat, flags=VG_VAR_CHEAT ); VG_VAR_F32( k_mmcollect_vert, flags=VG_VAR_CHEAT ); VG_VAR_F32( k_mmdecay, flags=VG_VAR_CHEAT ); + VG_VAR_F32( k_mmthrow_steer, flags=VG_VAR_CHEAT ); } VG_STATIC void player__skate_bind ( player_instance *player ); -- 2.25.1