File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import os
22import json
3+ from .icons import brawlers as br_icons
34
45__location__ = os .path .realpath (
56 os .path .join (os .getcwd (), os .path .dirname (__file__ )))
@@ -245,11 +246,8 @@ def __str__(self):
245246 return "{0.name} ({0.id})" .format (self )
246247
247248 def get_icon_url (self ):
248-
249- with open (os .path .join (__location__ , "brawler_icons.json" )) as icons :
250- data = json .load (icons )
251-
252- return data [str (self .id )]
249+
250+ return br_icons [str (self .id )]
253251
254252class PlayerBrawler :
255253
@@ -287,10 +285,7 @@ def __str__(self):
287285
288286 def get_icon_url (self ):
289287
290- with open (os .path .join (__location__ , "brawler_icons.json" )) as icons :
291- data = json .load (icons )
292-
293- return data [str (self .id )]
288+ return br_icons [str (self .id )]
294289
295290
296291class Gadget :
You can’t perform that action at this time.
0 commit comments