test network 1
[carveJwlIkooP6JGAAIwe30JlM.git] / network.h
index 6121f0fb8b22a460df51483aa1caf4ca4bb141af..066b9f82f3e1bc245ce3a3fbe63fa6a3331ec03c 100644 (file)
--- a/network.h
+++ b/network.h
@@ -11,7 +11,7 @@
 #include "network_msg.h"
 #include "highscores.h"
 
-VG_STATIC int network_scores_updated = 0;
+static int network_scores_updated = 0;
 
 /* 
  * Interface
@@ -19,25 +19,24 @@ VG_STATIC int network_scores_updated = 0;
 //#define SR_USE_LOCALHOST
 
 /* Call it at start; Connects us to the gameserver */
-VG_STATIC void network_init(void);
+static void network_init(void);
 
 /* Run this from main loop */
-VG_STATIC void network_update(void);
+static void network_update(void);
 
 /* Call it at shutdown */
-VG_STATIC void network_end(void);
+static void network_end(void);
 
 /* 
  * Can buffer up a bunch of these by calling many times, they will be
  * sent at the next connection 
  */
-VG_STATIC void network_submit_highscore( u32 trackid, u16 points, u16 time );
+static void network_submit_highscore( u32 trackid, u16 points, u16 time );
 
 /*
  * Game endpoints are provided with the same names to allow running without a
  * network connection.
  */
-#ifdef SR_NETWORKED
 
 struct {
    u8 app_symmetric_key[ 1024 ];
@@ -51,6 +50,8 @@ struct {
 
    f64 last_attempt, last_frame;
    u32 retries;
+
+   i32 network_info;
 }
 static network_client = {
    .state = k_ESteamNetworkingConnectionState_None,
@@ -58,11 +59,4 @@ static network_client = {
    .name_update = 1
 };
 
-#else /* SR_NETWORKED */
-
-VG_STATIC void network_init(void){}
-VG_STATIC void network_update(void){}
-VG_STATIC void network_end(void){}
-
-#endif /* SR_NETWORKED */
 #endif /* NETWORK_H */