mirror of
https://codeberg.org/demostf/parser.git
synced 2026-06-04 02:24:12 +02:00
more state updates
This commit is contained in:
parent
8fba325db8
commit
8183ac5b65
4 changed files with 57 additions and 15 deletions
|
|
@ -5,24 +5,24 @@ use crate::{Parse, ParseError, ParserState, Result, Stream};
|
|||
|
||||
#[derive(BitRead, Debug)]
|
||||
pub struct ServerClass {
|
||||
id: u16,
|
||||
name: String,
|
||||
data_table: String,
|
||||
pub id: u16,
|
||||
pub name: String,
|
||||
pub data_table: String,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct SendTable {
|
||||
name: String,
|
||||
props: Vec<SendPropDefinition>,
|
||||
needs_decoder: bool,
|
||||
flattened_props: Option<Vec<SendPropDefinition>>,
|
||||
pub name: String,
|
||||
pub props: Vec<SendPropDefinition>,
|
||||
pub needs_decoder: bool,
|
||||
pub flattened_props: Option<Vec<SendPropDefinition>>,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct DataTablePacket {
|
||||
tick: u32,
|
||||
tables: Vec<SendTable>,
|
||||
server_classes: Vec<ServerClass>,
|
||||
pub tick: u32,
|
||||
pub tables: Vec<SendTable>,
|
||||
pub server_classes: Vec<ServerClass>,
|
||||
}
|
||||
|
||||
impl Parse for DataTablePacket {
|
||||
|
|
|
|||
|
|
@ -87,8 +87,8 @@ impl fmt::Debug for StringTableEntry {
|
|||
|
||||
#[derive(Debug)]
|
||||
pub struct StringTablePacket {
|
||||
tick: u32,
|
||||
tables: Vec<StringTable>,
|
||||
pub tick: u32,
|
||||
pub tables: Vec<StringTable>,
|
||||
}
|
||||
|
||||
impl Parse for StringTablePacket {
|
||||
|
|
|
|||
|
|
@ -2,5 +2,5 @@ use bitstream_reader::BitRead;
|
|||
|
||||
#[derive(BitRead, Debug)]
|
||||
pub struct SyncTickPacket {
|
||||
tick: u32,
|
||||
pub tick: u32,
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue