summaryrefslogtreecommitdiffstats
path: root/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs
index d872cc1..7a7e3a1 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -64,7 +64,7 @@ impl GameState
pub fn new()
-> Self {
let timeman = TimeMan::new(0);
- let sol_system = match SolarSystem::new_from_known_star("sol")
+ let sol_system = match SolarSystem::new_from_known_star(0, "sol")
{
Ok(system) => system,
Err(e) => panic!("Unable to create sol system : {}", e)
@@ -139,9 +139,8 @@ impl ApplicationHandler for SystemicApp
self.last_render_time = now;
game_state.borrow_mut().update(delta_time);
- {
- window.update(game_state, delta_time);
- }
+ window.update(game_state, delta_time);
+
match window.render(game_state) {
Ok(_) => {}
Err(wgpu::SurfaceError::Outdated | wgpu::SurfaceError::Lost) => {
@@ -164,7 +163,7 @@ impl ApplicationHandler for SystemicApp
},
..
} => {
- window.keyboard_input(game_state, key_code, key_state);
+ window.keyboard_input(key_code, key_state);
}
_ => {}
}