Make sure strncpy always keeps one byte untouched for NUL
[neverball] / ball / game_common.h
index d0254da..ac502a2 100644 (file)
 
 /*---------------------------------------------------------------------------*/
 
-#define GAME_NONE 0
-#define GAME_TIME 1
-#define GAME_GOAL 2
-#define GAME_FALL 3
+enum
+{
+    GAME_NONE = 0,
+
+    GAME_TIME,
+    GAME_GOAL,
+    GAME_FALL,
+
+    GAME_MAX
+};
 
 const char *status_to_str(int);
 
@@ -62,7 +68,7 @@ struct game_tilt
 
 void game_tilt_init(struct game_tilt *);
 void game_tilt_axes(struct game_tilt *, float view_e[3][3]);
-void game_comp_grav(float h[3], const float g[3], const struct game_tilt *);
+void game_tilt_grav(float h[3], const float g[3], const struct game_tilt *);
 
 /*---------------------------------------------------------------------------*/