LD45/src/main.rs

32 lines
810 B
Rust
Raw Normal View History

2023-02-21 07:53:36 +00:00
use agnostic_interface::raylib_impl::RaylibGame;
use faux_quicksilver::Window;
use original_impl::GameState;
2023-02-13 09:53:04 +00:00
mod agnostic_interface;
2023-02-13 08:49:38 +00:00
mod faux_quicksilver;
2023-02-19 06:25:27 +00:00
mod original_impl;
mod shaders;
2019-10-05 00:28:41 +00:00
2023-02-21 07:53:36 +00:00
fn will_close() -> bool {
unsafe { agnostic_interface::raylib_impl::ffi::WindowShouldClose() }
}
2019-10-05 00:28:41 +00:00
fn main() {
2023-02-14 09:55:36 +00:00
// TODO
//run::<GameState>(
// "One And All - a Ludum Dare 45 compo entry",
// Vector::new(800, 600),
// Settings::default(),
//);
2023-02-21 07:53:36 +00:00
let game_interface = RaylibGame::new_boxed(800, 600);
let mut window = Window::new(game_interface);
let mut game_state = GameState::new(&mut window).unwrap();
while !will_close() {
window.update_music().unwrap();
game_state.update(&mut window).unwrap();
game_state.draw(&mut window).unwrap();
}
2019-10-05 00:28:41 +00:00
}