1786005198
This commit is contained in:
@@ -38,6 +38,7 @@ impl Trekstor {
|
||||
pub fn update(&mut self, update: UpdateFn) {
|
||||
loop {
|
||||
self.input.handle_event();
|
||||
self.current_time = Instant::now();
|
||||
let dt = self.current_time - self.last_time;
|
||||
|
||||
println!("Frame");
|
||||
@@ -58,7 +59,6 @@ impl Trekstor {
|
||||
dbg!(dt, self.update_timestep);
|
||||
|
||||
self.last_time = self.current_time;
|
||||
self.current_time = Instant::now();
|
||||
sleep(wait_time);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user