1
0
Fork 0
mirror of https://codeberg.org/demostf/parser.git synced 2026-06-04 02:24:12 +02:00

entity fixes and test

This commit is contained in:
Robin Appelman 2019-08-28 12:44:33 +02:00
commit 0df7d0b394
10 changed files with 626 additions and 46 deletions

View file

@ -30,10 +30,19 @@ impl From<u16> for ClassId {
}
}
#[derive(BitRead, PartialEq, Eq, Hash, Debug, Serialize, Deserialize, Clone, Display)]
pub struct ServerClassName(Rc<String>);
impl From<String> for ServerClassName {
fn from(value: String) -> Self {
Self(Rc::new(value))
}
}
#[derive(BitRead, Debug, Clone)]
pub struct ServerClass {
pub id: ClassId,
pub name: String,
pub name: ServerClassName,
pub data_table: SendTableName,
}