Input polling still happens every frame.
e->mod_shift = mod_shift;
e->mod_alt = mod_alt;
e->mod_ctrl = mod_ctrl;
- e->mod_super = mod_super;
+ e->mod_super = mod_super;
}
u32 i;
struct lrts_config *c = lrts_cfg();
struct i_input_map_ent *e;
- p_poll_events();
i_input_update();
/*
p_render_init_framebuffer();
while (!lrts_cfg()->exit) {
- i_input_poll();
+ p_poll_events();
t_sim_update();
r_render_frame();
}
void r_render_debug(void) {
struct lrts_state *state = lrts_state();
- u_debug_draw_text(0, 0, "FPS: %02d", state->fps);
+ u_debug_draw_text(0, 0, "FPS: %02d, Tick: %d", state->fps, state->tick_count);
}
void r_render_frame(void) {
t_updates_this_interval++;
state->tick_count++;
+
+ i_input_poll();
/* update game simulation */
}