📄Cargo.toml
[dependencies]
bedrock-client = { git = "https://github.com/ismaileke/bedrock-client.git", branch = "master" }
tokio = "1.43.0"
📄main.rs
use bedrock_client::client;
#[tokio::main]
async fn main() {
let mut client = client::create(
"127.0.0.1".to_string(), // target address
19132, // target port
"1.21.60".to_string(), // client version
false, // debug mode
|code, url| {
// If you turn on debug, the login code and url will already appear in the console, but you can use this if you want to edit it yourself.
println!("You can log in with the code {} at {}", code, url);
}
).await.unwrap();
client.set_packet_callback(|packet_name| {
// It can be used to try different things with incoming packages. Different features will be added later.
println!("New packet received: {}", packet_name);
});
client.connect().expect("Target IP Connection Error");
}
Note
This project is mainly designed for Abyssal Eclipse, but you can get ideas and develop something from the code I wrote.
It is still in development. I can't develop the project because I don't have time. Access to the servers is generally successful. I need to create the Chunk system for Abyssal Eclipse.