diff --git a/gameview.py b/gameview.py index 5de0703..710f753 100644 --- a/gameview.py +++ b/gameview.py @@ -293,15 +293,17 @@ class AOCharMovie(QtGui.QLabel): def findSprite(self, char, emote, prefix): bases = [ - "{char}/{prefix}{emote}", - "{char}/{emote}", - "{char}/{prefix}/{emote}" + u"{char}/{prefix}{emote}", + u"{char}/{emote}", + u"{char}/{prefix}/{emote}" ] - exts = [".apng", ".png", ".gif", ".webp"] + exts = [u".apng", u".png", u".gif", u".webp"] + + base_path = unicode(BASE_PATH) for base in bases: for ext in exts: - path = BASE_PATH + "characters/" + base.format(char=char, prefix=prefix, emote=emote) + ext + path = base_path + u"characters/" + base.format(char=char, prefix=prefix, emote=emote) + ext if exists(path): return path, ext return None, None