Skip to content

Releases: markus-wa/demoinfocs-golang

v1.2.1

08 Jul 18:52
Compare
Choose a tag to compare

Deprecation Notices

  • Player.CashSpentThisRound() has been deprecated, use Player.AdditionalPlayerInformation.CashSpentThisRound instead.
  • Player.CashSpentTotal() has been deprecated, use Player.AdditionalPlayerInformation.TotalCashSpent instead.

Fixes

  • Fixed Player.CashSpentThisRound() & Player.CashSpentTotal()

v1.2.0

04 Jul 19:56
Compare
Choose a tag to compare

Deprecation Notices

  • Entity.FindProperty() has been deprecated, use Entity.FindPropertyI() instead which returns IProperty instead of *Property
  • Entity.Properties() has been deprecated, use Entity.PropertiesI() instead which returns []IProperty instead of []Property
  • TickDone has been deprecated, use FrameDone instead (#120)

New Features / Changes

  • Added PlayerSpottersChanged event (#114)
  • Added helper functions to common.Player (#114):
    • IsSpottedBy(*Player) bool
    • HasSpotted(*Player) bool
  • Added helper functions to Participants (#114):
    • SpottersOf(*Player) []*Player
    • SpottedBy(*Player) []*Player
  • Added helper functions to common.Player for easily retrieving additional data (#115):
    • Player.IsInBombZone()
    • Player.IsInBuyZone()
    • Player.IsWalking()
    • Player.IsScoped()
    • Player.CashSpentThisRound()
    • Player.CashSpentTotal()
  • Added helper functions to common.TeamState for retrieving information over all members of a team:
    • TeamState.Members()
    • TeamState.CurrentEquipmentValue()
    • TeamState.RoundStartEquipmentValue()
    • TeamState.FreezeTimeEndEquipmentValue()
    • TeamState.CashSpentThisRound()
    • TeamState.CashSpentTotal()
  • Updated protobuf descriptions (allows parsing of new data)

Fixes

  • Added missing events.RankUpdate parsing and dispatching (#112 - thanks @allenymin)
  • Fixed EquipmentElement.String() returning M4A1 for EqM4A4 (#124 - thanks @xavier-rodet)

v1.1.1

08 Apr 14:16
Compare
Choose a tag to compare

New Features / Changes

Fixes

  • Fixed devision by 0 in DemoHeader.FrameTime() if Header.PlaybackFrames is zero (#108 - thanks @marksamman)

v1.1.0

30 Mar 12:37
8f7845c
Compare
Choose a tag to compare

New Features / Changes

  • Added Player.FlashDurationTimeRemaining() utility function - returns the remaining duration of the flash as of the current tick
  • Added Participants.Connected() function, returns all currently connected players & spectators
  • Changed Participants.All() to return all currently known players of the demo, including disconnected ones
  • Improved Participants godoc (#100)
  • Improved performance (~ 5-10%)

Fixes

  • Updated outdated information in metadata package (#103 - thanks @o40)
  • Fixed Player.IsBlinded() false positives (#96)
  • Fixed Participants returning kicked bots (and possibly disconnected players) in some cases (#98)
  • Fixed Player=nil for some events after player disconnected (#69)
  • Fixed Player.IsBot false negatives
  • Fixed potential memory leak in Parser.ParseNextFrame()
  • Fixed Participants.ByEntityID() becoming outdated in some cases

v1.0.1

28 Feb 19:52
Compare
Choose a tag to compare

New Features / Changes

  • Added Player.TeamState field as shortcut / utility (#89)

Fixes

  • Fixed TeamState.Opponent containing the wrong reference and therefore never being updated (#90)
  • Fixed EOF panicing, changed to returning ErrUnexpectedEndOfDemo (#93 - thanks @micvbang)

v1.0.0

25 Jan 17:15
Compare
Choose a tag to compare

API Breaking Changes

  • Changed return types of Inferno.ConvexHull2D() and Inferno.ConvexHull3D() from *s2.Loop to []r2.Point and quickhull.ConvexHull respectively

New Features / Changes

  • Added BombDefuseAborted event (dispatched when the property CCSPlayer.m_bIsDefusing of the player from the last bomb_defuse event changes from 1 to 0) (#74)
  • Added GameState.Team(common.Team) helper to retrieve the TeamState corresponding to a team (#76)
  • Added TeamState.Team() helper function, returns the common.TeamTerrorists or common.TeamCounterTerrorists (#76)
  • Added TeamState.Opponent utility link to TeamState of the opponent
  • Added TeamState fields to events.RoundEnd & events.PlayerTeamChange (#76)
  • Added Player.IsBlinded() helper function
  • Added Player.FlashDurationTime() helper function (returns time.Duration instead of float32 like Player.FlashDuration)
  • Added PlayerFlashed.Attacker field (#70)
  • Added PlayerFlashed.FlashDuration() helper function (#70)

Fixes

Contributors

Thanks to @quancore & @micvbang for various feature requests and bug reports.

v1.0.0-beta.5

28 Nov 08:55
Compare
Choose a tag to compare
v1.0.0-beta.5 Pre-release
Pre-release

API Breaking Changes

  • Migrated from dep to Go Modules (aka vgo) as dependency management system (#61)
  • Changed return type of Parser.GameState() from GameState to IGameState (#66)
  • Changed return type of GameState.Participants() from Participants to IParticipants (#66)
  • Moved type TeamState to package common (#55)
  • Removed ParserConfig.AdditionalEventEmitters and package fuzzy since there are now good team/side-switching events (#21).

New Features / Changes

  • Mockable API (#66)
  • Automatic parsing of header if not done manually - this means Parser.ParseHeader() no longer needs to be called if the header is not needed.
  • Added Equipment.ZoomLevel field to indicate how zoomed-in the player is on his weapon (#60)
  • Added ScoreUpdated event and moved TeamState to package common (#55)
  • Added events TeamSideSwitch, GameHalfEnd, GamePhaseChanged (#62)
  • Added GameState.IsWarmupPeriod(), GameState.MatchStarted() and events IsWarmupPeriodChanged & MatchStartedChanged (#63 & #64)

Fixes

  • Fixed some implementations of io.Reader not working as demo sources (when the reader returns less than the requested number of bytes before EOF).
  • Fixed no events being dispatched in some demos when there should be (#56)
  • Fixed bad Inferno.ConvexHull2D() (#58)
  • Fixed Inferno.IsBurning not always being set to true when it should be (#59)

Contributors

Thanks to @micvbang for the various contributions to this release.

Roadmap

See https://github.com/markus-wa/demoinfocs-golang/wiki/v1.0.0-Roadmap

v0.5.8

04 Nov 16:32
Compare
Choose a tag to compare

Fixes

  • Fixed no events being dispatched in some demos when there should be (#56 - thanks @micvbang)

v1.0.0-beta.4

05 Oct 19:14
Compare
Choose a tag to compare
v1.0.0-beta.4 Pre-release
Pre-release

API Breaking Changes

  • Changed type of DemoHeader.PlaybackTime from float32 to time.Duration
  • Changed return type of DemoHeader.FrameRate() & DemoHeader.TickRate() from float32 to float64

Fixes

  • Fixed Inferno.Active() always returning the full original Inferno.
  • Added missing weapon mapping for Scout (#53 - thanks @micvbang)
  • Added missing Inferno.UniqueID() function.

Roadmap

See https://github.com/markus-wa/demoinfocs-golang/wiki/v1.0.0-Roadmap

v0.5.7

05 Oct 18:46
Compare
Choose a tag to compare

Fixes

  • Added missing weapon mapping for Scout (#53 - thanks @micvbang)