Skip to content

Commit 6231b92

Browse files
committed
Revives the player.color_hex attribute temporarily until other options are explored
1 parent 198aa3d commit 6231b92

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sc2reader/readers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ def read(self, buffer, replay):
8383

8484
color = [pdata['color'][i] for i in sorted(pdata['color'].keys())]
8585
color = dict(zip(('a','r','g','b',), color))
86-
color_rgb = "%(r)02X%(g)02X%(b)02X" % color
87-
player.color = COLOR_CODES.get(color_rgb, color_rgb)
86+
player.color_hex = "%(r)02X%(g)02X%(b)02X" % color
87+
player.color = COLOR_CODES.get(player.color_hex, player.color_hex)
8888
player.color_rgba = color
8989

9090
player.outcome = pdata['outcome']

0 commit comments

Comments
 (0)