comparison pytouhou/ui/gamerunner.pyx @ 426:5d7bb2fd74f7

Never keep texture on the host when it has been uploaded, and prevent them from being decoded again.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Tue, 16 Jul 2013 21:11:35 +0200
parents f4d76d3d6f2a
children 0604f4fbbe3c
comparison
equal deleted inserted replaced
425:1104dc2553ee 426:5d7bb2fd74f7
54 54
55 def load_game(self, game=None, background=None, bgms=None, replay=None, save_keystates=None): 55 def load_game(self, game=None, background=None, bgms=None, replay=None, save_keystates=None):
56 self.game = game 56 self.game = game
57 self.background = background 57 self.background = background
58 58
59 self.texture_manager.preload(game.resource_loader.instanced_anms.values()) 59 self.texture_manager.load(game.resource_loader.instanced_anms.values())
60 60
61 if background: 61 if background:
62 self.background_renderer = BackgroundRenderer(self.texture_manager, self.use_fixed_pipeline) 62 self.background_renderer = BackgroundRenderer(self.use_fixed_pipeline)
63 self.background_renderer.prerender(background) 63 self.background_renderer.prerender(background)
64 64
65 self.set_input(replay) 65 self.set_input(replay)
66 if replay and replay.levels[game.stage - 1]: 66 if replay and replay.levels[game.stage - 1]:
67 game.players[0].state.lives = self.replay_level.lives 67 game.players[0].state.lives = self.replay_level.lives