Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into s2
Browse files Browse the repository at this point in the history
  • Loading branch information
markus-wa committed Sep 1, 2023
2 parents 2e45e53 + 8eb0227 commit f219996
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 8 deletions.
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# demoinfocs-golang - CS:GO Demo Parser
# demoinfocs-golang - CS:GO & CS2 Demo Parser

A blazing fast, feature complete and production ready Go library for parsing and analysing of Counter Strike: Global Offensive (CS:GO) demos (aka replays).
A blazing fast, feature complete and production ready Go library for parsing and analysing of Counter-Strike: Global Offensive (CS:GO) demos (aka replays).

Counter-Strike 2 support is experimental.

[![Stand With Ukraine](https://raw.githubusercontent.com/vshymanskyy/StandWithUkraine/main/badges/StandWithUkraine.svg)](https://vshymanskyy.github.io/StandWithUkraine)

Expand All @@ -21,8 +23,14 @@ For business inquiries please use the contact information found on the [GitHub p

## Go Get

### CS2 - ⚠️ Experimental

go get -u github.com/markus-wa/demoinfocs-golang/v4/pkg/demoinfocs

### CS:GO

go get -u github.com/markus-wa/demoinfocs-golang/v3/pkg/dem

## Table of Contents

- [Requirements](https://github.com/markus-wa/demoinfocs-golang#requirements)
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ require (
github.com/pkg/errors v0.9.1
github.com/stretchr/testify v1.8.0
golang.org/x/exp v0.0.0-20220713135740-79cabaa25d75
google.golang.org/protobuf v1.30.0
google.golang.org/protobuf v1.31.0
)

require (
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw=
google.golang.org/protobuf v1.30.0 h1:kPPoIgf3TsEvrm0PFe15JQ+570QVxYzEvvHqChK+cng=
google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8=
google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
Expand Down
2 changes: 1 addition & 1 deletion pkg/demoinfocs/game_events.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ func newGameEventHandler(parser *parser, ignoreBombsiteIndexNotFound bool) gameE
delayIfNoPlayers := func(f gameEventHandlerFunc) gameEventHandlerFunc {
return func(data map[string]*msg.CSVCMsg_GameEventKeyT) {
if len(parser.gameState.playersByUserID) == 0 {
delay(f)
delay(f)(data)
} else {
f(data)
}
Expand Down
4 changes: 2 additions & 2 deletions pkg/demoinfocs/sendtables/fake/entity.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ func NewEntityWithProperty(name string, val st.PropertyValue) *Entity {
prop.On("Value").Return(val)
entity.On("Property", name).Return(prop)

entity.On("PropertyValue").Return(val, true)
entity.On("PropertyValueMust").Return(val)
entity.On("PropertyValue", name).Return(val, true)
entity.On("PropertyValueMust", name).Return(val)

return entity
}
Expand Down

0 comments on commit f219996

Please sign in to comment.