reduced shader bind code dupe & adjust skate uprighter strenght
[carveJwlIkooP6JGAAIwe30JlM.git] / skaterift.c
index b5029c4ca30745d85ce619c4e0e045e118d1ed2a..388e37ebeac21af80f77375cad69cecfb0cc9b85 100644 (file)
 static struct player_avatar localplayer_avatar;
 
 int main( int argc, char *argv[] ){
+#if 0
+   u8 buf[ 512 ];
+   bitpack_ctx ctx = {
+      .buffer = buf,
+      .buffer_len = 512,
+      .bytes = 0,
+      .mode = k_bitpack_compress
+   };
+
+   v4f q = {  0.388, -0.565, 0.515, 0.515 };
+   vg_info( "q: %f %f %f %f\n", q[0], q[1], q[2], q[3] );
+
+   /* compress */
+   bitpack_qquat( &ctx, q );
+
+   vg_info( "compressed bytes: %u\n", ctx.bytes );
+
+   /* decompress */
+   ctx.bytes = 0;
+   ctx.mode = k_bitpack_decompress;
+
+   bitpack_qquat( &ctx, q );
+   vg_info( "q: %f %f %f %f\n", q[0], q[1], q[2], q[3] );
+
+   return 0;
+#endif
+
    vg_mem.use_libc_malloc = 0;
    vg_set_mem_quota( 160*1024*1024 );
    vg_enter( argc, argv, "Voyager Game Engine" ); 
@@ -84,6 +111,7 @@ vg_info("            '        ' '--' [] '----- '----- '     ' '---'  "
 
    steam_init();
    vg_loader_step( NULL, steam_end );
+   vg_loader_step( remote_players_init, NULL );
    vg_loader_step( network_init, network_end );
 }
 
@@ -324,6 +352,7 @@ static void vg_pre_update(void){
    player__pre_update();
    world_entity_focus_preupdate();
    skaterift_replay_pre_update();
+   remote_sfx_pre_update();
 
    world_update( world_current_instance(), localplayer.rb.co );
    audio_ambient_sprites_update( world_current_instance(), localplayer.rb.co );
@@ -455,6 +484,7 @@ static void render_player_transparent(void){
 
    /* Draw player to window buffer and blend background ontop */
    player__render( &small_cam );
+   render_remote_players_tags( localplayer.viewable_world, &skaterift.cam );
 }
 
 static void render_scene(void){