mirror of
https://codeberg.org/demostf/parser.git
synced 2026-06-03 18:24:05 +02:00
update to bitstream_reader 0.7
This commit is contained in:
parent
2f32240613
commit
b7c3baee17
12 changed files with 32 additions and 66 deletions
12
Cargo.lock
generated
12
Cargo.lock
generated
|
|
@ -67,17 +67,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bitstream_reader"
|
name = "bitstream_reader"
|
||||||
version = "0.6.9"
|
version = "0.7.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bitstream_reader_derive 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"bitstream_reader_derive 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"memchr 2.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
"memchr 2.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"num-traits 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
"num-traits 0.2.10 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bitstream_reader_derive"
|
name = "bitstream_reader_derive"
|
||||||
version = "0.6.0"
|
version = "0.7.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)",
|
"proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
|
@ -577,7 +577,7 @@ name = "tf-demo-parser"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"better-panic 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"better-panic 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"bitstream_reader 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)",
|
"bitstream_reader 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"enumflags2 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"enumflags2 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"err-derive 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
"err-derive 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"jemallocator 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"jemallocator 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
|
@ -652,8 +652,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
"checksum backtrace-sys 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)" = "5d6575f128516de27e3ce99689419835fce9643a9b215a14d2b5b685be018491"
|
"checksum backtrace-sys 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)" = "5d6575f128516de27e3ce99689419835fce9643a9b215a14d2b5b685be018491"
|
||||||
"checksum better-panic 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "64714970eb2081691f85a923b78a490fd7c3e256dcc83c7a5177314586563356"
|
"checksum better-panic 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "64714970eb2081691f85a923b78a490fd7c3e256dcc83c7a5177314586563356"
|
||||||
"checksum bitflags 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"
|
"checksum bitflags 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"
|
||||||
"checksum bitstream_reader 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)" = "a6f78e68e2469e11c8526688f80bdc3f9bb1a4470f48d20186a86e0c0a1be9ce"
|
"checksum bitstream_reader 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e61dbc828db189cc9b8bcde3ad5510f3ec8f116082619254091cfcc44d20ac0c"
|
||||||
"checksum bitstream_reader_derive 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "14e4573210a0cc968772847e1db9705e546f60cc1525c5cbfbf470dfa1fa391c"
|
"checksum bitstream_reader_derive 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "cc94bb155011c3a16833c511d95d1b99868749a8cd3693b7f6fab375691a5064"
|
||||||
"checksum byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a7c3dd8985a7111efc5c80b44e23ecdd8c007de8ade3b96595387e812b957cf5"
|
"checksum byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a7c3dd8985a7111efc5c80b44e23ecdd8c007de8ade3b96595387e812b957cf5"
|
||||||
"checksum cc 1.0.49 (registry+https://github.com/rust-lang/crates.io-index)" = "e450b8da92aa6f274e7c6437692f9f2ce6d701fb73bacfcf87897b3f89a4c20e"
|
"checksum cc 1.0.49 (registry+https://github.com/rust-lang/crates.io-index)" = "e450b8da92aa6f274e7c6437692f9f2ce6d701fb73bacfcf87897b3f89a4c20e"
|
||||||
"checksum cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"
|
"checksum cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ name = "parse_demo"
|
||||||
path = "src/bin/main.rs"
|
path = "src/bin/main.rs"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
bitstream_reader = { version = "0.6.7" }
|
bitstream_reader = "0.7"
|
||||||
num_enum = "0.4"
|
num_enum = "0.4"
|
||||||
num-traits = "0.2"
|
num-traits = "0.2"
|
||||||
enumflags2 = "0.6"
|
enumflags2 = "0.6"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use bitstream_reader::{BitRead, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, LittleEndian};
|
||||||
|
|
||||||
use crate::demo::sendprop::read_bit_coord;
|
use crate::demo::sendprop::read_bit_coord;
|
||||||
use crate::demo::vector::Vector;
|
use crate::demo::vector::Vector;
|
||||||
|
|
@ -44,5 +44,3 @@ impl BitRead<LittleEndian> for BSPDecalMessage {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for BSPDecalMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use bitstream_reader::{BitRead, BitReadSized, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, BitReadSized, LittleEndian};
|
||||||
|
|
||||||
use crate::demo::message::stringtable::log_base2;
|
use crate::demo::message::stringtable::log_base2;
|
||||||
use crate::{ReadResult, Stream};
|
use crate::{ReadResult, Stream};
|
||||||
|
|
@ -40,5 +40,3 @@ impl BitRead<LittleEndian> for ClassInfoMessage {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for ClassInfoMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
use std::iter::FromIterator;
|
use std::iter::FromIterator;
|
||||||
|
|
||||||
use bitstream_reader::{BitRead, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, LittleEndian};
|
||||||
|
|
||||||
use crate::demo::gameevent_gen::GameEventType;
|
use crate::demo::gameevent_gen::GameEventType;
|
||||||
use crate::demo::gamevent::{
|
use crate::demo::gamevent::{
|
||||||
|
|
@ -117,5 +117,3 @@ impl BitRead<LittleEndian> for GameEventListMessage {
|
||||||
Ok(GameEventListMessage { event_list })
|
Ok(GameEventListMessage { event_list })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for GameEventListMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
use crate::Stream;
|
use crate::Stream;
|
||||||
/// Messages that consists only of primitives and string and can be derived
|
/// Messages that consists only of primitives and string and can be derived
|
||||||
use bitstream_reader::{BitRead, BitSize, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, LittleEndian};
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
|
|
||||||
#[derive(BitRead, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
|
|
@ -10,9 +10,7 @@ pub struct FileMessage {
|
||||||
pub requested: bool,
|
pub requested: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for FileMessage {}
|
#[derive(BitRead, Debug)]
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
|
||||||
pub struct NetTickMessage {
|
pub struct NetTickMessage {
|
||||||
pub tick: u32,
|
pub tick: u32,
|
||||||
pub frame_time: u16,
|
pub frame_time: u16,
|
||||||
|
|
@ -24,9 +22,7 @@ pub struct StringCmdMessage {
|
||||||
pub command: String,
|
pub command: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for StringCmdMessage {}
|
#[derive(BitRead, Debug)]
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
|
||||||
pub struct SigOnStateMessage {
|
pub struct SigOnStateMessage {
|
||||||
pub state: u8,
|
pub state: u8,
|
||||||
pub count: u32,
|
pub count: u32,
|
||||||
|
|
@ -37,8 +33,6 @@ pub struct PrintMessage {
|
||||||
pub value: String,
|
pub value: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for PrintMessage {}
|
|
||||||
|
|
||||||
#[derive(BitRead, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
pub struct ServerInfoMessage {
|
pub struct ServerInfoMessage {
|
||||||
pub version: u16,
|
pub version: u16,
|
||||||
|
|
@ -60,20 +54,18 @@ pub struct ServerInfoMessage {
|
||||||
pub replay: bool,
|
pub replay: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for ServerInfoMessage {}
|
#[derive(BitRead, Debug)]
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
|
||||||
pub struct SetPauseMessage {
|
pub struct SetPauseMessage {
|
||||||
pub pause: bool,
|
pub pause: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
pub struct SetViewMessage {
|
pub struct SetViewMessage {
|
||||||
#[size = 11]
|
#[size = 11]
|
||||||
pub index: u16,
|
pub index: u16,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
pub struct FixAngleMessage {
|
pub struct FixAngleMessage {
|
||||||
pub relative: bool,
|
pub relative: bool,
|
||||||
pub x: u16,
|
pub x: u16,
|
||||||
|
|
@ -94,9 +86,7 @@ pub struct EntityMessage {
|
||||||
pub data: Stream,
|
pub data: Stream,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for EntityMessage {}
|
#[derive(BitRead, Debug)]
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug)]
|
|
||||||
pub struct PreFetchMessage {
|
pub struct PreFetchMessage {
|
||||||
#[size = 14]
|
#[size = 14]
|
||||||
pub index: u16,
|
pub index: u16,
|
||||||
|
|
@ -111,16 +101,12 @@ pub struct MenuMessage {
|
||||||
pub index: Stream,
|
pub index: Stream,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for MenuMessage {}
|
|
||||||
|
|
||||||
#[derive(BitRead, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
pub struct GetCvarValueMessage {
|
pub struct GetCvarValueMessage {
|
||||||
pub cookie: u32,
|
pub cookie: u32,
|
||||||
pub value: String,
|
pub value: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for GetCvarValueMessage {}
|
|
||||||
|
|
||||||
#[derive(BitRead, Debug)]
|
#[derive(BitRead, Debug)]
|
||||||
#[endianness = "LittleEndian"]
|
#[endianness = "LittleEndian"]
|
||||||
pub struct CmdKeyValuesMessage {
|
pub struct CmdKeyValuesMessage {
|
||||||
|
|
@ -128,5 +114,3 @@ pub struct CmdKeyValuesMessage {
|
||||||
#[size = "length * 8"]
|
#[size = "length * 8"]
|
||||||
pub data: Stream,
|
pub data: Stream,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for CmdKeyValuesMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use bitstream_reader::{BitRead, BitReadSized, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, BitReadSized, LittleEndian};
|
||||||
|
|
||||||
use crate::demo::message::stringtable::log_base2;
|
use crate::demo::message::stringtable::log_base2;
|
||||||
use crate::{ReadResult, Stream};
|
use crate::{ReadResult, Stream};
|
||||||
|
|
@ -24,5 +24,3 @@ impl BitRead<LittleEndian> for SetConVarMessage {
|
||||||
Ok(SetConVarMessage { vars })
|
Ok(SetConVarMessage { vars })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for SetConVarMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -98,13 +98,11 @@ impl BitRead<LittleEndian> for UserMessage {
|
||||||
};
|
};
|
||||||
Ok(message)
|
Ok(message)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
impl ParseBitSkip for UserMessage {
|
fn skip(stream: &mut Stream) -> ReadResult<()> {
|
||||||
fn parse_skip(stream: &mut Stream) -> Result<()> {
|
|
||||||
stream.skip_bits(8)?;
|
stream.skip_bits(8)?;
|
||||||
let length: u32 = stream.read_int(11)?;
|
let length: u32 = stream.read_int(11)?;
|
||||||
stream.skip_bits(length as usize).map_err(ParseError::from)
|
stream.skip_bits(length as usize)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use bitstream_reader::{BitRead, BitSkip, LittleEndian};
|
use bitstream_reader::{BitRead, LittleEndian};
|
||||||
|
|
||||||
use crate::{ReadResult, Stream};
|
use crate::{ReadResult, Stream};
|
||||||
|
|
||||||
|
|
@ -30,8 +30,6 @@ impl BitRead<LittleEndian> for VoiceInitMessage {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for VoiceInitMessage {}
|
|
||||||
|
|
||||||
#[derive(BitRead, Debug, Clone)]
|
#[derive(BitRead, Debug, Clone)]
|
||||||
#[endianness = "LittleEndian"]
|
#[endianness = "LittleEndian"]
|
||||||
pub struct VoiceDataMessage {
|
pub struct VoiceDataMessage {
|
||||||
|
|
@ -42,8 +40,6 @@ pub struct VoiceDataMessage {
|
||||||
data: Stream,
|
data: Stream,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for VoiceDataMessage {}
|
|
||||||
|
|
||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
pub struct ParseSoundsMessage {
|
pub struct ParseSoundsMessage {
|
||||||
pub reliable: bool,
|
pub reliable: bool,
|
||||||
|
|
@ -71,5 +67,3 @@ impl BitRead<LittleEndian> for ParseSoundsMessage {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSkip<LittleEndian> for ParseSoundsMessage {}
|
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,10 @@
|
||||||
use bitstream_reader::{BitRead, BitSize, Endianness, LazyBitRead, LittleEndian};
|
use bitstream_reader::{bit_size_of, BitRead, Endianness, LazyBitRead, LittleEndian};
|
||||||
|
|
||||||
use crate::demo::message::{Message, MessageType};
|
use crate::demo::message::{Message, MessageType};
|
||||||
use crate::demo::vector::Vector;
|
use crate::demo::vector::Vector;
|
||||||
use crate::{Parse, ParserState, ReadResult, Result, Stream};
|
use crate::{Parse, ParserState, ReadResult, Result, Stream};
|
||||||
|
|
||||||
#[derive(Debug, BitRead, BitSize)]
|
#[derive(Debug, BitRead)]
|
||||||
pub struct MessagePacketMeta {
|
pub struct MessagePacketMeta {
|
||||||
pub flags: u32, // TODO
|
pub flags: u32, // TODO
|
||||||
pub view_angles: ViewAngles,
|
pub view_angles: ViewAngles,
|
||||||
|
|
@ -26,12 +26,6 @@ pub struct ViewAngles {
|
||||||
pub local_angles: (Vector, Vector),
|
pub local_angles: (Vector, Vector),
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BitSize for ViewAngles {
|
|
||||||
fn bit_size() -> usize {
|
|
||||||
Vector::bit_size() * 6
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
impl<E: Endianness> BitRead<E> for ViewAngles {
|
impl<E: Endianness> BitRead<E> for ViewAngles {
|
||||||
fn read(stream: &mut bitstream_reader::BitStream<E>) -> ReadResult<Self> {
|
fn read(stream: &mut bitstream_reader::BitStream<E>) -> ReadResult<Self> {
|
||||||
let view_origin_1 = Vector::read(stream)?;
|
let view_origin_1 = Vector::read(stream)?;
|
||||||
|
|
@ -46,6 +40,10 @@ impl<E: Endianness> BitRead<E> for ViewAngles {
|
||||||
local_angles,
|
local_angles,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn bit_size() -> Option<usize> {
|
||||||
|
Some(bit_size_of::<Vector>().unwrap() * 6)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Parse for MessagePacket {
|
impl Parse for MessagePacket {
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use bitstream_reader::{BitRead, BitSkip, FromUtf8Error, LittleEndian, ReadError};
|
use bitstream_reader::{BitRead, FromUtf8Error, LittleEndian, ReadError};
|
||||||
|
|
||||||
pub use self::messagetypeanalyser::MessageTypeAnalyser;
|
pub use self::messagetypeanalyser::MessageTypeAnalyser;
|
||||||
use crate::demo::gamevent::{GameEventValue, GameEventValueType};
|
use crate::demo::gamevent::{GameEventValue, GameEventValueType};
|
||||||
|
|
@ -38,7 +38,7 @@ pub trait ParseBitSkip {
|
||||||
fn parse_skip(stream: &mut Stream) -> Result<()>;
|
fn parse_skip(stream: &mut Stream) -> Result<()>;
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<T: BitSkip<LittleEndian>> ParseBitSkip for T {
|
impl<T: BitRead<LittleEndian>> ParseBitSkip for T {
|
||||||
#[inline(always)]
|
#[inline(always)]
|
||||||
fn parse_skip(stream: &mut Stream) -> Result<()> {
|
fn parse_skip(stream: &mut Stream) -> Result<()> {
|
||||||
Self::skip(stream).map_err(ParseError::from)
|
Self::skip(stream).map_err(ParseError::from)
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
use bitstream_reader::{BitRead, BitSize};
|
use bitstream_reader::BitRead;
|
||||||
use parse_display::Display;
|
use parse_display::Display;
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug, Clone, Copy, Default, Serialize, Deserialize, Display)]
|
#[derive(BitRead, Debug, Clone, Copy, Default, Serialize, Deserialize, Display)]
|
||||||
#[display("({x}, {y}, {z})")]
|
#[display("({x}, {y}, {z})")]
|
||||||
pub struct Vector {
|
pub struct Vector {
|
||||||
pub x: f32,
|
pub x: f32,
|
||||||
|
|
@ -16,7 +16,7 @@ impl PartialEq for Vector {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(BitRead, BitSize, Debug, Clone, Copy, Default, Serialize, Deserialize, Display)]
|
#[derive(BitRead, Debug, Clone, Copy, Default, Serialize, Deserialize, Display)]
|
||||||
#[display("({x}, {y})")]
|
#[display("({x}, {y})")]
|
||||||
pub struct VectorXY {
|
pub struct VectorXY {
|
||||||
pub x: f32,
|
pub x: f32,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue