summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: db7f47c)
raw | patch | inline | side by side (parent: db7f47c)
author | DeaDDooMER <deaddoomer@deadsoftware.ru> | |
Tue, 4 Apr 2017 15:23:28 +0000 (18:23 +0300) | ||
committer | DeaDDooMER <deaddoomer@deadsoftware.ru> | |
Tue, 4 Apr 2017 15:23:28 +0000 (18:23 +0300) |
game.c | patch | blob | history | |
game.h | patch | blob | history |
index 896fb8eb25cdddf5a8de56e0b801df122877b1cd..4b1c345c43d2443572eb281bdb13533ce4197c47 100644 (file)
--- a/game.c
+++ b/game.c
#include "game.h"
-#define SPEED (0.000006 * TICK_DELAY)
-#define ROTATE (0.000006 * TICK_DELAY)
-#define BULL_SPEED (0.0008 * TICK_DELAY)
+#define SPEED (0.03 / TICK)
+#define ROTATE (0.03 / TICK)
+#define BULL_SPEED (0.4 / TICK)
Player g_player[MAX_PLAYERS];
Bullet g_bullet[MAX_BULLETS];
index 00b06cccfc30130de9f36ef98de92257200e363e..8568721dde2f1c01412effa93394b2157546286a 100644 (file)
--- a/game.h
+++ b/game.h
#define MAX_PLAYERS 32
#define MAX_BULLETS (MAX_PLAYERS * 8)
-#define TICK_DELAY (1000 / 20) // 20 World updates per second
-#define BULLET_TIME (TICK_DELAY * 6) // Bullet live time 6.0s
-#define PLAYER_SIZE 0.01785 // Palyer radius
-#define PLAYER_SHOOT (TICK_DELAY * 1) // Can shoot every 1.0s (less then 1s not work)
+#define TICK 24 // 24 World updates per second
+#define TICK_DELAY (1000 / TICK) // World freeze time ms
+#define BULLET_TIME (TICK * 6) // Bullet live time 6.0s
+#define PLAYER_SIZE 0.01785 // Palyer radius
+#define PLAYER_SHOOT (TICK * 0.8) // Can shoot every 1.0s (less then 1s not work)
typedef struct Player {
/* public */