Display player speed in km/h

This commit is contained in:
crumblingstatue 2023-04-04 20:18:27 +02:00
parent 9b4d0c8cf7
commit 05c516e210
3 changed files with 26 additions and 4 deletions

View file

@ -5,6 +5,8 @@ use sfml::{
};
use sfml_xt::graphics::RenderWindowExt;
use crate::math::FPS_TARGET;
pub struct ScreenRes {
pub w: i16,
pub h: i16,
@ -44,7 +46,7 @@ pub fn make_window() -> RenderWindow {
Style::CLOSE,
&ContextSettings::default(),
);
rw.set_framerate_limit(60);
rw.set_framerate_limit(FPS_TARGET.into());
rw.center();
rw
}