diff options
| author | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2024-06-15 13:58:30 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-06-15 13:58:30 +0300 |
| commit | 77e4b066cb8d506b4bc944ab4eb2d6e4679e2202 (patch) | |
| tree | 1d549eca619ed36cb881e487cb054c4643ac8376 /pkg/messages/types/svcPaintmapData.go | |
| parent | change project name to sdp.go (diff) | |
| download | sdp.go-77e4b066cb8d506b4bc944ab4eb2d6e4679e2202.tar.gz sdp.go-77e4b066cb8d506b4bc944ab4eb2d6e4679e2202.tar.bz2 sdp.go-77e4b066cb8d506b4bc944ab4eb2d6e4679e2202.zip | |
enable multithreading with goroutines (#20)
Diffstat (limited to 'pkg/messages/types/svcPaintmapData.go')
| -rw-r--r-- | pkg/messages/types/svcPaintmapData.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pkg/messages/types/svcPaintmapData.go b/pkg/messages/types/svcPaintmapData.go index 10f8031..2455f83 100644 --- a/pkg/messages/types/svcPaintmapData.go +++ b/pkg/messages/types/svcPaintmapData.go | |||
| @@ -2,19 +2,19 @@ package messages | |||
| 2 | 2 | ||
| 3 | import ( | 3 | import ( |
| 4 | "github.com/pektezol/bitreader" | 4 | "github.com/pektezol/bitreader" |
| 5 | "github.com/pektezol/sdp.go/pkg/writer" | 5 | "github.com/pektezol/sdp.go/pkg/types" |
| 6 | ) | 6 | ) |
| 7 | 7 | ||
| 8 | type SvcPaintmapData struct { | 8 | type SvcPaintmapData struct { |
| 9 | Length uint32 | 9 | Length uint32 `json:"length"` |
| 10 | Data []byte | 10 | Data []byte `json:"data"` |
| 11 | } | 11 | } |
| 12 | 12 | ||
| 13 | func ParseSvcPaintmapData(reader *bitreader.Reader) SvcPaintmapData { | 13 | func ParseSvcPaintmapData(reader *bitreader.Reader, demo *types.Demo) SvcPaintmapData { |
| 14 | svcPaintmapData := SvcPaintmapData{ | 14 | svcPaintmapData := SvcPaintmapData{ |
| 15 | Length: reader.TryReadUInt32(), | 15 | Length: reader.TryReadUInt32(), |
| 16 | } | 16 | } |
| 17 | svcPaintmapData.Data = reader.TryReadBitsToSlice(uint64(svcPaintmapData.Length)) | 17 | svcPaintmapData.Data = reader.TryReadBitsToSlice(uint64(svcPaintmapData.Length)) |
| 18 | writer.TempAppendLine("\t\tData: %v", svcPaintmapData.Data) | 18 | demo.Writer.TempAppendLine("\t\tData: %v", svcPaintmapData.Data) |
| 19 | return svcPaintmapData | 19 | return svcPaintmapData |
| 20 | } | 20 | } |