This repository has been archived on 2021-10-11. You can view files and clone it, but cannot push or open issues or pull requests.

27 lines
759 B
Rust

use game::{GameConfig, StaticGameData, game_begin};
#[tokio::main]
async fn main() {
// Enable logging
tracing_subscriber::fmt::init();
// Load the general config for the game
// This happens here so we can properly track sentry events
let mut game_config = GameConfig::load(
StaticGameData::get("configs/application.json").expect("Failed to load application.json"),
).unwrap();
// Connect to sentry
let _sentry_guard = sentry::init((
game_config.sentry_dsn.clone(),
sentry::ClientOptions {
release: sentry::release_name!(),
attach_stacktrace: true,
..Default::default()
},
));
// Start the game
game_begin(&mut game_config).await.unwrap();
}