mirror of
https://github.com/Noratrieb/game-wip-dontplay.git
synced 2026-01-16 12:25:02 +01:00
Display player speed in km/h
This commit is contained in:
parent
9b4d0c8cf7
commit
05c516e210
3 changed files with 26 additions and 4 deletions
|
|
@ -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
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue