Fix some minor typos
This commit is contained in:
1 parent
43fbb6a68d
commit
1a21290e0f
14 files changed
+27
-27
No files matched your search
@@ -65,7 +65,7 @@ pub struct Client {
|
||||
|
||||
pub protocol_version: i32,
|
||||
pub connection_state: ConnectionState,
|
||||
pub encrytion: bool,
|
||||
pub encryption: bool,
|
||||
pub closed: bool,
|
||||
pub token: Rc<Token>,
|
||||
pub connection: TcpStream,
|
||||
@@ -89,7 +89,7 @@ impl Client {
|
||||
connection,
|
||||
enc: PacketEncoder::default(),
|
||||
dec: PacketDecoder::default(),
|
||||
encrytion: true,
|
||||
encryption: true,
|
||||
closed: false,
|
||||
client_packets_queue: VecDeque::new(),
|
||||
}
|
||||
@@ -105,7 +105,7 @@ impl Client {
|
||||
&mut self,
|
||||
shared_secret: &[u8], // decrypted
|
||||
) -> Result<(), EncryptionError> {
|
||||
self.encrytion = true;
|
||||
self.encryption = true;
|
||||
let crypt_key: [u8; 16] = shared_secret
|
||||
.try_into()
|
||||
.map_err(|_| EncryptionError::SharedWrongLength)?;
|
||||
@@ -379,7 +379,7 @@ impl Client {
|
||||
.unwrap_or_else(|_| self.close());
|
||||
}
|
||||
_ => {
|
||||
log::warn!("Cant't kick in {:?} State", self.connection_state)
|
||||
log::warn!("Can't kick in {:?} State", self.connection_state)
|
||||
}
|
||||
}
|
||||
self.close()
|
||||
|
||||
@@ -15,7 +15,7 @@ pub mod resource_pack;
|
||||
const CURRENT_BASE_VERSION: &str = "1.0.0";
|
||||
|
||||
#[derive(Deserialize, Serialize)]
|
||||
/// The idea is that Pumpkin should very customizable, You can Enable or Disable Features depning on your needs.
|
||||
/// The idea is that Pumpkin should very customizable, You can Enable or Disable Features depending on your needs.
|
||||
/// This also allows you get some Performance or Resource boosts.
|
||||
/// Important: The Configuration should match Vanilla by default
|
||||
pub struct AdvancedConfiguration {
|
||||
@@ -182,7 +182,7 @@ impl AdvancedConfiguration {
|
||||
if path.as_ref().exists() {
|
||||
let toml = std::fs::read_to_string(path).expect("Couldn't read configuration");
|
||||
let config: AdvancedConfiguration =
|
||||
toml::from_str(toml.as_str()).expect("Couldn't parse features.toml, Proberbly old config, Replacing with a new one or just delete it");
|
||||
toml::from_str(toml.as_str()).expect("Couldn't parse features.toml, Probably old config, Replacing with a new one or just delete it");
|
||||
config.validate();
|
||||
config
|
||||
} else {
|
||||
@@ -202,7 +202,7 @@ impl BasicConfiguration {
|
||||
pub fn load<P: AsRef<Path>>(path: P) -> BasicConfiguration {
|
||||
if path.as_ref().exists() {
|
||||
let toml = std::fs::read_to_string(path).expect("Couldn't read configuration");
|
||||
let config: BasicConfiguration = toml::from_str(toml.as_str()).expect("Couldn't parse configuration.toml, Proberbly old config, Replacing with a new one or just delete it");
|
||||
let config: BasicConfiguration = toml::from_str(toml.as_str()).expect("Couldn't parse configuration.toml, Probably old config, Replacing with a new one or just delete it");
|
||||
config.validate();
|
||||
config
|
||||
} else {
|
||||
@@ -219,7 +219,7 @@ impl BasicConfiguration {
|
||||
self.config_version, CURRENT_BASE_VERSION,
|
||||
"Config version does not match used Config version. Please update your config"
|
||||
);
|
||||
assert!(self.view_distance >= 2, "View distance must be atleast 2");
|
||||
assert!(self.view_distance >= 2, "View distance must be at least 2");
|
||||
assert!(
|
||||
self.view_distance <= 32,
|
||||
"View distance must be less than 32"
|
||||
|
||||
@@ -7,7 +7,7 @@ pub struct ResourcePackConfig {
|
||||
pub resource_pack_url: String,
|
||||
/// The SHA1 hash (40) of the resource pack.
|
||||
pub resource_pack_sha1: String,
|
||||
/// Custom propmt Text component, Leave blank for none
|
||||
/// Custom prompt Text component, Leave blank for none
|
||||
pub prompt_message: String,
|
||||
/// Will force the Player to accept the resource pack
|
||||
pub force: bool,
|
||||
|
||||
Reference in new issue
Block a user