Clean up deps

This commit is contained in:
Evan Pratten 2021-04-25 19:22:46 -04:00
parent d729ae811e
commit e4ae9b18b3
3 changed files with 2 additions and 18 deletions

View File

@ -13,9 +13,4 @@ serialstudio = "0.1.0"
serde = "1.0.125"
serde_json = "1.0.64"
failure = "0.1.8"
parry2d = "0.4.0"
log = "0.4.14"
env_logger = "0.8.3"
nalgebra = "0.26.1"
rand = "0.8.3"
tiled = "0.9.4"

View File

@ -5,15 +5,13 @@ use std::{fmt, fs::File, io::BufReader};
use raylib::{
camera::Camera2D, math::Vector2, prelude::RaylibDrawHandle, RaylibHandle, RaylibThread,
};
use failure::Error;
use crate::{
player::{Player, PlayerInventory},
resources::GlobalResources,
world::World,
};
use failure::Error;
use log::debug;
use serde::{Deserialize, Serialize};
/// Overall states for the game
@ -26,7 +24,7 @@ pub enum GameState {
InGame,
GameEnd,
InShop,
WinGame
WinGame,
}
impl fmt::Display for GameState {
@ -80,7 +78,6 @@ impl GameProgress {
}
pub fn update(&mut self, new_progress: &GameProgress) {
// Bring in new data
self.coins = new_progress.coins;
self.inventory = new_progress.inventory.clone();
@ -92,7 +89,6 @@ impl GameProgress {
if result.is_err() {
println!("Could not save game state. Holding in RAM");
}
}
}
@ -152,8 +148,6 @@ impl GameCore {
}
pub fn switch_state(&mut self, new_state: GameState, draw_handle: Option<&RaylibDrawHandle>) {
debug!("Switching global state to: {}", new_state);
self.last_state = self.state;
self.state = new_state;

View File

@ -10,7 +10,6 @@ mod world;
use gamecore::{GameCore, GameProgress, GameState};
use lib::{utils::profiler::GameProfiler, wrappers::audio::player::AudioPlayer};
use log::info;
use logic::{
gameend::GameEndScreen, ingame::InGameScreen, loadingscreen::LoadingScreen,
mainmenu::MainMenuScreen, pausemenu::PauseMenuScreen, screen::Screen, shop::ShopScreen,
@ -28,9 +27,6 @@ const WINDOW_TITLE: &str = r"One Breath";
const MAX_FPS: u32 = 60;
fn main() {
// Configure the logger
env_logger::init();
// Configure a window
let (mut raylib, raylib_thread) = raylib::init()
.size(
@ -146,7 +142,6 @@ fn main() {
// For now, just quit
// This also throws a SEGFAULT.. yay for unsafe code..
info!("User quit game");
unsafe {
raylib::ffi::CloseWindow();
}