Small world fixes
parent
d35b4381ec
commit
1b0951057d
|
@ -150,10 +150,10 @@ void game_init(game_kind play_mode, uint32_t num_viewers, int32_t seed, uint16_t
|
|||
world_setup_pkt_handlers(pkt_reader, game_mode == GAMEKIND_SINGLE ? sp_pkt_writer : mp_pkt_writer);
|
||||
world_init(seed, chunk_size, chunk_amount);
|
||||
if (is_dash_enabled) flecs_dash_init();
|
||||
//ecs_set_target_fps(world_ecs(), 60);
|
||||
|
||||
if (game_mode == GAMEKIND_HEADLESS) {
|
||||
network_server_start(0, 27000);
|
||||
ecs_set_target_fps(world_ecs(), 60);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -57,8 +57,8 @@ int32_t pkt_send_keystate_handler(pkt_header *header) {
|
|||
|
||||
Input *i = ecs_get_mut(world_ecs(), e, Input, NULL);
|
||||
if (i && !i->is_blocked) {
|
||||
i->x = table.x;
|
||||
i->y = table.y;
|
||||
i->x = zpl_clamp(table.x, -1.0f, 1.0f);
|
||||
i->y = zpl_clamp(table.y, -1.0f, 1.0f);
|
||||
i->mx = table.mx;
|
||||
i->my = table.my;
|
||||
i->use = table.use;
|
||||
|
|
|
@ -258,7 +258,7 @@ static void world_tracker_update(uint8_t ticker, uint32_t freq, uint8_t radius)
|
|||
|
||||
// TODO(zaklaus): SUPER TEMPORARY HOT !!! simulate variable radius queries
|
||||
{
|
||||
librg_entity_radius_set(world_tracker(), p[i].peer, radius);
|
||||
librg_entity_radius_set(world_tracker(), it.entities[i], radius);
|
||||
}
|
||||
// TODO(zaklaus): push radius once librg patch comes in
|
||||
int32_t result = librg_world_write(world_tracker(), it.entities[i], buffer, &datalen, NULL);
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
@echo off
|
||||
|
||||
call package.bat
|
||||
pkg\eco2d.exe -d %*
|
Loading…
Reference in New Issue