diff options
Diffstat (limited to 'pkg/messages/types/svcUpdateStringTable.go')
| -rw-r--r-- | pkg/messages/types/svcUpdateStringTable.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkg/messages/types/svcUpdateStringTable.go b/pkg/messages/types/svcUpdateStringTable.go index c606141..9a3cbe0 100644 --- a/pkg/messages/types/svcUpdateStringTable.go +++ b/pkg/messages/types/svcUpdateStringTable.go | |||
| @@ -3,18 +3,18 @@ package messages | |||
| 3 | import "github.com/pektezol/bitreader" | 3 | import "github.com/pektezol/bitreader" |
| 4 | 4 | ||
| 5 | type SvcUpdateStringTable struct { | 5 | type SvcUpdateStringTable struct { |
| 6 | TableId int8 | 6 | TableId uint8 |
| 7 | NumChangedEntries int16 | 7 | NumChangedEntries uint16 |
| 8 | Length int32 | 8 | Length int32 |
| 9 | Data []byte | 9 | Data []byte |
| 10 | } | 10 | } |
| 11 | 11 | ||
| 12 | func ParseSvcUpdateStringTable(reader *bitreader.Reader) SvcUpdateStringTable { | 12 | func ParseSvcUpdateStringTable(reader *bitreader.Reader) SvcUpdateStringTable { |
| 13 | svcUpdateStringTable := SvcUpdateStringTable{ | 13 | svcUpdateStringTable := SvcUpdateStringTable{ |
| 14 | TableId: int8(reader.TryReadBits(5)), | 14 | TableId: reader.TryReadUInt8(), |
| 15 | } | 15 | } |
| 16 | if reader.TryReadBool() { | 16 | if reader.TryReadBool() { |
| 17 | svcUpdateStringTable.NumChangedEntries = int16(reader.TryReadBits(16)) | 17 | svcUpdateStringTable.NumChangedEntries = reader.TryReadUInt16() |
| 18 | } | 18 | } |
| 19 | svcUpdateStringTable.Length = int32(reader.TryReadBits(20)) | 19 | svcUpdateStringTable.Length = int32(reader.TryReadBits(20)) |
| 20 | svcUpdateStringTable.Data = reader.TryReadBitsToSlice(uint64(svcUpdateStringTable.Length)) | 20 | svcUpdateStringTable.Data = reader.TryReadBitsToSlice(uint64(svcUpdateStringTable.Length)) |