use std::time::Duration;
use nurtex::Bot;
use nurtex::protocol::packets::play::{ServersidePlayPacket, ServersideSwingArm};
use nurtex::protocol::types::RelativeHand;
#[tokio::main]
async fn main() -> std::io::Result<()> {
let mut bot = Bot::create("nurtex_bot");
bot.connect("localhost", 25565);
tokio::time::sleep(Duration::from_secs(3)).await;
for _ in 0..6 {
bot.send_packet(ServersidePlayPacket::SwingArm(ServersideSwingArm { hand: RelativeHand::MainHand }));
tokio::time::sleep(Duration::from_secs(1)).await;
}
Ok(())
}