def get_nums(numPath, pos): return im.Sprite(path + numPath, pos)
path = os.path.realpath(os.path.expanduser('res')) screen = pygame.display.set_mode(windowSize, pygame.NOFRAME) posDict = { "frame": (420, 310), "power": (width - 75, 75), "upload": (250, height - 140), "score": (585, height - 140), "tensDig": (width - 190, 275), "onesDig": (width - 90, 275) } background = pygame.image.load(path + "/Background.png") emptyFrame = im.Button(path + "/Empty_Picture_Frame.png", posDict["frame"], False) filledFrame = im.Sprite(path + "/Filled_Picture_Frame.png", (emptyFrame.pos)) imageFile = im.Sprite(path + "/Test_Image.jpg", (emptyFrame.pos)) powerButton = im.Button(path + "/buttons/Power.png", posDict["power"]) uploadButton = im.Button(path + "/buttons/Upload.png", posDict["upload"]) getScoreButton = im.Button(path + "/buttons/Get_Score.png", posDict["score"]) pressedGetScoreButton = im.Sprite(path + "/buttons/Pressed_Get_Score.png", (getScoreButton.pos)) pressedPowerButton = im.Sprite(path + "/buttons/Pressed_Power.png", (powerButton.pos)) pressedUploadButton = im.Sprite(path + "/buttons/Pressed_Upload.png", (uploadButton.pos)) numZero = im.Sprite(path + "/nums/Zero.png") numOne = im.Sprite(path + "/nums/One.png")