1 #ifndef PLAYER_RAGDOLL_H
2 #define PLAYER_RAGDOLL_H
4 #include "player_api.h"
7 #include "player_render.h"
13 /* Collider transform relative to bone */
30 rb_constr_pos position_constraints
[32];
31 u32 position_constraints_count
;
33 rb_constr_swingtwist cone_constraints
[32];
34 u32 cone_constraints_count
;
39 static float k_ragdoll_floatyiness
= 20.0f
,
40 k_ragdoll_floatydrag
= 1.0f
,
41 k_ragdoll_limit_scale
= 1.0f
;
43 static int k_ragdoll_div
= 1,
45 k_ragdoll_debug_collider
= 1,
46 k_ragdoll_debug_constraints
= 0;
48 static void player_ragdoll_init(void);
49 static void player_init_ragdoll_bone_collider( struct skeleton_bone
*bone
,
50 struct ragdoll_part
*rp
);
51 static u32
ragdoll_bone_parent( struct player_ragdoll
*rd
, u32 bone_id
);
52 static void setup_ragdoll_from_skeleton( struct skeleton
*sk
,
53 struct player_ragdoll
*rd
);
54 static void copy_ragdoll_pose_to_localplayer( struct player_ragdoll
*rd
);
55 static void copy_localplayer_to_ragdoll( struct player_ragdoll
*rd
, v3f v
);
56 static void player_debug_ragdoll(void);
57 static void player_ragdoll_iter( struct player_ragdoll
*rd
);
59 #endif /* PLAYER_RAGDOLL_H */