прозрел
This commit is contained in:
parent
97b00dfc7e
commit
c9974e4140
9
src/d.rs
9
src/d.rs
@ -34,3 +34,12 @@ impl Buffer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub trait Sas {
|
||||||
|
fn ts(&mut self);
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Sas for Buffer {
|
||||||
|
fn ts(&mut self) {
|
||||||
|
self.index += 1;
|
||||||
|
}
|
||||||
|
}
|
@ -6,11 +6,11 @@ use d::*;
|
|||||||
|
|
||||||
use std::thread;
|
use std::thread;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let a = Buffer::new(vec![0x01,0xFF,0x33], 0);
|
let mut a = Buffer::new(vec![0x01,0xFF,0x33], 0);
|
||||||
let b = a;
|
a.ts();
|
||||||
let x = a.read(1);
|
|
||||||
let x2 = a.read(1);
|
|
||||||
|
|
||||||
// let Ok(server) = Server::new("127.0.0.1:25565") else {
|
// let Ok(server) = Server::new("127.0.0.1:25565") else {
|
||||||
// println!("Не удалось забиндить сервер"); return;
|
// println!("Не удалось забиндить сервер"); return;
|
||||||
|
Loading…
Reference in New Issue
Block a user