mirror of
https://codeberg.org/icewind/vbsp.git
synced 2026-06-03 10:44:07 +02:00
fold BspVersion into Header, use binrw magic for FourCC
This commit is contained in:
parent
f0c226044d
commit
d0a1666539
2 changed files with 9 additions and 19 deletions
|
|
@ -69,13 +69,18 @@ impl Index<LumpType> for Directories {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq, BinRead)]
|
||||
#[br(little)]
|
||||
#[brw(repr=u32)]
|
||||
pub enum BspVersion {
|
||||
Version20 = 20,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq, BinRead)]
|
||||
#[br(little)]
|
||||
pub struct Header {
|
||||
pub v: u8,
|
||||
pub b: u8,
|
||||
pub s: u8,
|
||||
pub p: u8,
|
||||
#[brw(magic = b"VBSP")]
|
||||
pub version: BspVersion,
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, Default, BinRead)]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue