diff --git a/code/game/src/world/world.c b/code/game/src/world/world.c index 8b462d3..a56fe2b 100644 --- a/code/game/src/world/world.c +++ b/code/game/src/world/world.c @@ -255,7 +255,7 @@ int32_t world_destroy(void) { #define WORLD_LIBRG_BUFSIZ 2000000 -static void world_tracker_update(uint8_t ticker, uint32_t freq, uint8_t radius) { +static void world_tracker_update(uint8_t ticker, float freq, uint8_t radius) { if (world.tracker_update[ticker] > (float)zpl_time_rel()) return; world.tracker_update[ticker] = (float)zpl_time_rel() + freq; @@ -301,9 +301,9 @@ int32_t world_update() { ecs_progress(world.ecs, 0.0f); } - uint32_t fast_ms = WORLD_TRACKER_UPDATE_FAST_MS; - uint32_t normal_ms = WORLD_TRACKER_UPDATE_NORMAL_MS; - uint32_t slow_ms = WORLD_TRACKER_UPDATE_SLOW_MS; + float fast_ms = WORLD_TRACKER_UPDATE_FAST_MS; + float normal_ms = WORLD_TRACKER_UPDATE_NORMAL_MS; + float slow_ms = WORLD_TRACKER_UPDATE_SLOW_MS; if (game_get_kind() != GAMEKIND_SINGLE) { fast_ms = WORLD_TRACKER_UPDATE_MP_FAST_MS; diff --git a/code/game/src/world/world.h b/code/game/src/world/world.h index 438a883..f4ba77b 100644 --- a/code/game/src/world/world.h +++ b/code/game/src/world/world.h @@ -17,11 +17,11 @@ #define WORLD_LAYERING 0 #define WORLD_TRACKER_LAYERS 3 #define WORLD_TRACKER_UPDATE_FAST_MS 0 -#define WORLD_TRACKER_UPDATE_NORMAL_MS 50 -#define WORLD_TRACKER_UPDATE_SLOW_MS 100 -#define WORLD_TRACKER_UPDATE_MP_FAST_MS 50 -#define WORLD_TRACKER_UPDATE_MP_NORMAL_MS 150 -#define WORLD_TRACKER_UPDATE_MP_SLOW_MS 300 +#define WORLD_TRACKER_UPDATE_NORMAL_MS 0.05f +#define WORLD_TRACKER_UPDATE_SLOW_MS 0.1f +#define WORLD_TRACKER_UPDATE_MP_FAST_MS 0.05f +#define WORLD_TRACKER_UPDATE_MP_NORMAL_MS 0.15f +#define WORLD_TRACKER_UPDATE_MP_SLOW_MS 0.3f #define WORLD_BLOCK_SIZE 64 #define WORLD_PKT_READER(name) int32_t name(void* data, uint32_t datalen, void *udata)