X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=player_model.h;h=a4a626c666cfe7db46d171d571d4251d66efccca;hb=0cf7e0563088708f2749f7dacd26ffdf1391dccc;hp=652753c81d71a23335f7c13dd2d65381a169b26c;hpb=4a883ac1b2506032f9dddab342712de46f2ca734;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/player_model.h b/player_model.h index 652753c..a4a626c 100644 --- a/player_model.h +++ b/player_model.h @@ -10,6 +10,9 @@ #include "skeleton_animator.h" #include "shaders/viewchar.h" +static float k_ragdoll_floatyiness = 10.0f, + k_ragdoll_floatydrag = 1.0f; + vg_tex2d tex_characters = { .path = "textures/ch_gradient.qoi" }; static void character_register(void) @@ -239,6 +242,10 @@ static void character_ragdoll_iter( struct character *ch ) rb_debug_constraint_limits( &pj->rb, &pp->rb, lca, pj->limits ); } } + + v4f plane = {0.0f,1.0f,0.0f,0.0f}; + rb_effect_simple_bouyency( &pj->rb, plane, k_ragdoll_floatyiness, + k_ragdoll_floatydrag ); } /* CONSTRAINTS */