Releases: markus-wa/demoinfocs-golang
v2.5.0
Operation Broken Fang Update
Operation Broken Fang brings with it some interesting new demo data!
There's a new event events.RoundImpactScoreData
, containing initial round conditions, kill events and objective events, each with new odds of winning the round per team.
This might be interesting if you're doing player impact analysis, anomaly detection for round wins/clutches and/or training some kind of AI system.
New Features / Changes
- Added
events.RoundImpactScoreData
which is dispatched at the end of every round (only demos after the "Operation Broken Fang" update)- Initial round conditions (equipment value) and odds
- Kills (+ damage) and how it affected odds
- Objective data and how it affected odds
v2.4.0
New Features / Changes
- Added
PlayerHurt.HealthDamageTaken
-HealthDamage
excluding over-damage (#247 - thanks @Julien2313) - Added
PlayerHurt.ArmorDamageTaken
-ArmorDamage
excluding over-damage (#247) - Added
Player.Color()
- returns the players color during the match (#248 / #250 - thanks @Julien2313) - Added
Player.IsDuckingInProgress()
- returns true if the player is currently in the progress of going from standing to crouched (#241 / #249) - Added
Player.IsUnDuckingInProgress()
- returns true if the player is currently in the progress of going from crouched to standing (#241 / #249) - Added
Player.IsStanding()
- returns true if the player is currently fully standing upright (#241 / #249)
Fixes
- Fixed
Player.IsDucking()
reporting wrong values
v2.3.0
v1.11.0
Please upgrade to v2.x
This is just a bugfix release, please upgrade to v2.x if you have the chance. As of the time of this release, the newest version is v2.2.0
Fixes
- Added
Parser.Close()
to fix a memory leak due to an unterminated goroutine (#216)
please make sure that this function is called before the parser is discarded,
for instance by callingdefer parser.Close()
afterdemoinfocs.NewParser()
v2.2.0
v2.1.0
v2.0.1
v2.0.0
Doc Links
The new docs are hosted on the fabulous new go.dev
page.
Package docs: https://pkg.go.dev/mod/github.com/markus-wa/demoinfocs-golang/[email protected]
API docs: https://pkg.go.dev/github.com/markus-wa/demoinfocs-golang/[email protected]/pkg/demoinfocs?tab=doc
Go Get
Watch out, there's a new module path for go get
and import
!
go get -u github.com/markus-wa/demoinfocs-golang/v2/pkg/demoinfocs
Upgrading from v1.x
If you are currently using version 1.x of this library, check out this wiki page for an upgrade guide.
Breaking Changes
- Import path base has changed from
github.com/markus-wa/demoinfocs-golang
togithub.com/markus-wa/demoinfocs-golang/v2/pkg/demoinfocs
- Replaced main public structs with interfaces (
Parser
,GameState
,Participants
,Entity
,Property
)- These interfaces already existed before but used to be prefixed with
I
(e.g.IParser
)
- These interfaces already existed before but used to be prefixed with
- Replaced many struct fields in package
common
with getter funcs - Replaced
Player.AdditionalPlayerInfo.XXX
with getter funcs on thePlayer
struct - Removed or replaced all previously deprecated methods, fields and events
- Renamed field
EquipmentElement.Weapon
toEquipmentElement.Type
- Renamed field
Player.RawWeapons
toPlayer.Inventory
- Renamed field
Player.SteamID
toPlayer.SteamID64
- Renamed func
Entity.PropertiesI()
toEntity.Properties()
- Renamed func
Entity.FindPropertyI()
toEntity.Property()
- Removed redundant funcs
common.EquipmentElementNames()
andcommon.GamePhaseNames()
EquipmentType.String()
andGamePhase.String()
will achieve the same result. - Removed obsolete func
ItemPickup.WeaponTraceable()
ItemPickup.Weapon
should now be identical (see #119) - Removed
Item{Pickup,Drop,Equip}.WeaponPtr
- Removed func
Entity.BindPosition()
- Changed type of
Item{Pickup,Drop,Equip}.Weapon
fromEquipment
struct to pointer of the same type - Changed type of
Equipment.ZoomLevel
fromint
toZoomLevel
- Changed receiver types of
DemoHeader
,TeamState
,Equipment
,GrenadeProjectile
andInferno
funcs from struct to pointer
New Features / Changes
- Added Bomb-Damage detection.
PlayerHurt.Weapon.Type
andKill.Weapon.Type
will now beEqBomb
- Added Fall-Damage detection.
PlayerHurt.Weapon.Type
andKill.Weapon.Type
will now beEqWorld
- Added field
RankUpdate.Player
(may be nil if the player has already disconnected) - Added utility function
Player.SteamID32()
which convertsSteamID64
to the 32-bit variant and returns the result - Added utility function
RankUpdate.SteamID64()
which convertsSteamID32
to the 64-bit variant and returns the result - Added utility functions
common.ConvertSteamID{TxtTo32,32To64,64To32}()
- Added constants
common.Zoom{None,Half,Full}
- Updated protobuf code (re-generated with new
protoc
version)
v2.0.0-beta.11
Doc Links
The new docs are hosted on the fabulous new go.dev
page.
Package docs: https://pkg.go.dev/mod/github.com/markus-wa/demoinfocs-golang/[email protected]
API docs: https://pkg.go.dev/github.com/markus-wa/demoinfocs-golang/[email protected]/pkg/demoinfocs?tab=doc
Go Get
Watch out, there's a new module path for go get
and import
!
go get -u github.com/markus-wa/demoinfocs-golang/v2/pkg/demoinfocs
Breaking Changes
- See v2.0.0-beta.10 for more breaking changes since
v1.x
- Changed receiver types of
DemoHeader
,TeamState
,Equipment
,GrenadeProjectile
andInferno
funcs from struct to pointer
v2.0.0-beta.10
Doc Links
The new docs are hosted on the fabulous new go.dev
page.
Package docs: https://pkg.go.dev/mod/github.com/markus-wa/demoinfocs-golang/[email protected]
API docs: https://pkg.go.dev/github.com/markus-wa/demoinfocs-golang/[email protected]/pkg/demoinfocs?tab=doc
Go Get
Watch out, there's a new module path for go get
and import
!
go get -u github.com/markus-wa/demoinfocs-golang/v2/pkg/demoinfocs
Breaking Changes
- See v2.0.0-beta.9 for more breaking changes since
v1.x
- Removed func
Entity.BindPosition()
- Removed func
PropertyValue.Float64Val()
- Changed type of
common.Zoom{None,Half,Full}
fromint
toZoomLevel
Fixes
- Fixed issue where
Entity.Property()
was not returning nil if the property wasn't found - Fixed nil-pointer de-reference error when trying to retrieve player data when there is no
Player.Entity