shits fucked
[carveJwlIkooP6JGAAIwe30JlM.git] / player_skate.h
index e17e983641e8eb77e04076d7fdace839527d05d3..11c66e9d203ccc2c4493613cf289664eae8328e2 100644 (file)
@@ -3,6 +3,8 @@
 
 #include "player_api.h"
 
+#define SKATE_CCD
+
 struct player_skate
 {
    struct
@@ -16,20 +18,30 @@ struct player_skate
       activity,
       activity_prev;
 
-      float steery,
+      float /* steery,
             steerx,
             steery_s,
-            steerx_s,
+            steerx_s, */
             reverse,
             slip;
 
+      int manual_direction;
+
+      /* tricks */
       v3f   flip_axis;
       float flip_time,
             flip_rate;
 
+      v3f   trick_vel,     /* measured in units of TAU/s */
+            trick_euler;   /* measured in units of TAU */
+      float trick_time;
+
       m3x3f velocity_bias,
             velocity_bias_pstep;
       v3f apex;
+      v3f up_dir;
+
+      v3f head_position;
 
       int lift_frames;
 
@@ -47,14 +59,6 @@ struct player_skate
              cur_push;
 
       v3f prev_pos;
-
-      /* FIXME: Sensible names */
-
-      v3f vl;
-#if 0
-      v3f vl,          /* 1st */
-          posl, dirl;  /* 3rd */
-#endif
    }
    state,
    state_gate_storage;
@@ -89,8 +93,9 @@ struct player_skate
                         *anim_push,  *anim_push_reverse,
                         *anim_ollie, *anim_ollie_reverse,
                         *anim_grabs, *anim_stop;
-   rb_sphere sphere_front, sphere_back;
-   v3f board_offset;
+   v3f board_offset,
+       board_trick_residualv,
+       board_trick_residuald;
    v4f board_rotation;
 
    float blend_slide,
@@ -102,6 +107,9 @@ struct player_skate
          blend_jump,
          blend_airdir;
 
+   float substep,
+         substep_delta;
+
    v2f wobble;
 
    float debug_normal_pressure;
@@ -119,9 +127,7 @@ VG_STATIC void player__skate_post_animate ( player_instance *player );
 VG_STATIC void player__skate_reset        ( player_instance *player,
                                             struct respawn_point *rp );
 
-VG_STATIC void player__skate_transition   ( player_instance *player,
-                                            v3f init_velocity,
-                                            enum skate_activity init_acitivity 
-                                            );
-
+VG_STATIC void player__skate_clear_mechanics( player_instance *player );
+VG_STATIC void player__skate_reset_animator( player_instance *player );
+VG_STATIC void player__approximate_best_trajectory( player_instance *player );
 #endif /* PLAYER_SKATE_H */