further prototyping of #1
This commit is contained in:
parent
b93d52645c
commit
9815c3d200
7
log.txt
7
log.txt
@ -371,3 +371,10 @@
|
||||
2020-07-08 22:08:49 [INFO] - Next state: Status
|
||||
2020-07-08 22:08:49 [INFO] - Ping number: MCLong { value: 3528562 }
|
||||
2020-07-08 22:08:49 [INFO] - Client at 192.168.0.88:55891 closed connection
|
||||
2020-07-08 22:15:19 [INFO] - Network thread started
|
||||
2020-07-08 22:15:19 [IMPORTANT] - Started server on 0.0.0.0:25565
|
||||
2020-07-08 22:15:39 [INFO] - Got a client!
|
||||
2020-07-08 22:15:39 [INFO] - Handshake { protocol_version: MCVarInt { value: 578 }, server_address: MCString { value: "192.168.0.98" }, server_port: MCUnsignedShort { value: 25565 }, next_state: MCVarInt { value: 1 } }
|
||||
2020-07-08 22:15:39 [INFO] - Next state: Status
|
||||
2020-07-08 22:15:39 [INFO] - Ping number: MCLong { value: 3938584 }
|
||||
2020-07-08 22:15:39 [INFO] - Client at 192.168.0.88:55909 closed connection
|
||||
|
@ -1,3 +1,8 @@
|
||||
// main.rs
|
||||
// authors: Garen Tyler, Danton Hou
|
||||
// description:
|
||||
// Main Game loop, config handler.
|
||||
|
||||
#![allow(non_snake_case)]
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
@ -31,12 +36,14 @@ fn main() {
|
||||
pub struct Config {
|
||||
pub port: u16,
|
||||
pub protocol_version: u16,
|
||||
pub max_players: u32,
|
||||
}
|
||||
impl Config {
|
||||
pub fn default() -> Config {
|
||||
Config {
|
||||
port: 25565,
|
||||
protocol_version: 578,
|
||||
max_players: 250,
|
||||
}
|
||||
}
|
||||
pub fn from_file(filename: &str) -> Config {
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user