Files
rust-engine/src/main.rs
2021-10-31 16:12:32 +01:00

31 lines
676 B
Rust

extern crate serde_json;
use vulkan::gameobject::GameObject;
use crate::config::{LogConfig, RenderConfig};
use crate::game::TestGame;
use crate::vulkan::VulkanRenderer;
mod vulkan;
mod input;
mod config;
mod game;
mod tests;
mod text;
mod util;
mod perf;
fn main() {
let log_config = LogConfig::from_file("config/log.toml");
let mut game = TestGame::new("config/input.toml", log_config);
let (mut renderer, event_loop) = VulkanRenderer::init(
log_config.vulkan_validation_layers,
RenderConfig::from_file("config/graphics.toml")
);
game.game_start(&mut renderer);
vulkan::start_event_loop(renderer, Box::new(game), event_loop);
}