rename a file, fix error msg, dont spam persistence by default

This commit is contained in:
Marcel Märtens 2020-10-13 00:06:24 +02:00
parent 2668731a05
commit f1c9b959f4
6 changed files with 15 additions and 4 deletions

View File

@ -1,7 +1,7 @@
pub mod client;
pub mod ecs_packet;
pub mod server;
pub mod world_packet;
pub mod world_msg;
// Reexports
pub use self::{
@ -11,7 +11,7 @@ pub use self::{
CharacterInfo, DisconnectReason, InviteAnswer, Notification, PlayerInfo, PlayerListUpdate,
RegisterError, ServerGeneral, ServerInfo, ServerInit, ServerMsg, ServerRegisterAnswer,
},
world_packet::WorldMapMsg,
world_msg::WorldMapMsg,
};
use serde::{Deserialize, Serialize};

View File

@ -52,7 +52,7 @@ pub enum ServerInit {
time_of_day: state::TimeOfDay,
max_group_size: u32,
client_timeout: Duration,
world_map: crate::msg::world_packet::WorldMapMsg,
world_map: crate::msg::world_msg::WorldMapMsg,
recipe_book: RecipeBook,
},
}

View File

@ -18,6 +18,11 @@ pub fn init(basic: bool) {
.add_directive("uvth=warn".parse().unwrap())
.add_directive("tiny_http=warn".parse().unwrap())
.add_directive("mio::sys::windows=debug".parse().unwrap())
.add_directive(
"veloren_server::persistence::character=info"
.parse()
.unwrap(),
)
.add_directive(LevelFilter::INFO.into())
};

View File

@ -52,7 +52,8 @@ impl Client {
where
S: Into<ServerMsg>,
{
const ERR: &str = "Dont do that, thats only done once at the start, no via this class";
const ERR: &str =
"Don't do that. Sending these messages is only done ONCE at connect and not by this fn";
match msg.into() {
ServerMsg::Info(_) => panic!(ERR),
ServerMsg::Init(_) => panic!(ERR),

View File

@ -44,6 +44,11 @@ pub fn init(settings: &Settings) -> Vec<impl Drop> {
.add_directive("uvth=warn".parse().unwrap())
.add_directive("tiny_http=warn".parse().unwrap())
.add_directive("mio::sys::windows=debug".parse().unwrap())
.add_directive(
"veloren_server::persistence::character=info"
.parse()
.unwrap(),
)
.add_directive(LevelFilter::INFO.into())
};