completed all glider stuff
[carveJwlIkooP6JGAAIwe30JlM.git] / testing.c
index ad98cce5e3c051f73972dd59254dd6abd2e9aa6d..103f62cafeb106fb397ef7475763cc9cd8c0cbd5 100644 (file)
--- a/testing.c
+++ b/testing.c
@@ -1,4 +1,7 @@
-#include "rigidbody.h"
+#pragma once
+#include "vg/vg_m.h"
+#include "vg/vg_rigidbody.h"
+#include "scene_rigidbody.h"
 
 struct {
    rigidbody rb;
@@ -11,6 +14,9 @@ static baller = {
 };
 
 static void testing_update(void){
+   if( !vg_console.cheats )
+      return;
+
    if( vg_getkey( SDLK_9 ) ){
       v3_add( localplayer.rb.co, (v3f){0,1,0}, baller.rb.co );
       v3_zero( baller.rb.w );
@@ -18,6 +24,13 @@ static void testing_update(void){
       q_identity( baller.rb.q );
       rb_update_matrices( &baller.rb );
    }
+
+   if( vg_getkey( SDLK_8 ) ){
+      localplayer.have_glider = 1;
+      localplayer.glider_orphan = 0;
+      player_glide.t = -1.0f;
+   }
+
    vg_line_boxf_transformed( baller.rb.to_world, baller.box, VG__RED );
 
    world_instance *world = world_current_instance();