Skip to content

Commit

Permalink
fix(Battlegrounds): crash in UpdateBattlegroundsPlayerTriples
Browse files Browse the repository at this point in the history
  • Loading branch information
beheh committed Apr 23, 2024
1 parent cdfde2c commit 45af072
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Hearthstone Deck Tracker/Hearthstone/GameV2.cs
Expand Up @@ -411,7 +411,10 @@ public void UpdateBattlegroundsPlayerTechLevel(int id, int value)

public void UpdateBattlegroundsPlayerTriples(int id, int value)
{
var heroCurrentTier = Entities[id].GetTag(GameTag.PLAYER_TECH_LEVEL);
if(!Entities.TryGetValue(id, out var entity))
return;

var heroCurrentTier = entity.GetTag(GameTag.PLAYER_TECH_LEVEL);
if(!_battlegroundsHeroTriplesByTier.ContainsKey(id))
_battlegroundsHeroTriplesByTier[id] = new Dictionary<int, int>();

Expand Down

0 comments on commit 45af072

Please sign in to comment.