...

Source file src/go.formulabun.club/srb2kart/lump/replay/struct.go

Documentation: go.formulabun.club/srb2kart/lump/replay

     1  package replay
     2  
     3  type ReplayRaw struct {
     4  	HeaderPreFileEntries
     5  	WadEntries
     6  	HeaderPostFileEntries
     7  	CVarEntries
     8  	PlayerEntries
     9  	PlayerListingEnd byte
    10  }
    11  
    12  type HeaderPreFileEntries struct {
    13  	DemoHeader  [12]byte
    14  	Version     uint8
    15  	SubVersion  uint8
    16  	DemoVersion uint16
    17  
    18  	Title    [64]byte
    19  	Checksum [16]byte
    20  
    21  	Play    [4]byte
    22  	GameMap uint16
    23  	MapMd5  [16]byte
    24  
    25  	DemoFlags uint8
    26  	GameType  uint8
    27  
    28  	FileCount byte
    29  }
    30  
    31  type WadEntries []WadEntry
    32  
    33  type WadEntry struct {
    34  	FileName string
    35  	WadMd5   [16]byte
    36  }
    37  
    38  type HeaderPostFileEntries struct {
    39  	Time uint32
    40  	Lap  uint32
    41  
    42  	Seed     uint32
    43  	Reserved uint32
    44  
    45  	CVarCount uint16
    46  }
    47  
    48  type CVarEntries []CVarEntry
    49  
    50  type CVarEntry struct {
    51  	CVarId uint16
    52  	Value  string
    53  	False  uint8
    54  }
    55  
    56  type PlayerEntries []PlayerEntry
    57  
    58  type PlayerEntry struct {
    59  	Spec uint8
    60  	PlayerEntryData
    61  }
    62  
    63  type PlayerEntryData struct {
    64  	Name   [16]byte
    65  	Skin   [16]byte
    66  	Color  [16]byte
    67  	Score  uint32
    68  	Speed  byte
    69  	Weight byte
    70  }
    71  

View as plain text