Created
November 19, 2011 20:39
-
-
Save orlp/1379323 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from __future__ import division, print_function | |
| import pyglet | |
| from pyglet.gl import * | |
| import function | |
| class Map(object): | |
| def __init__(self, game, mapname): | |
| self.mapname = mapname | |
| self.image = pyglet.sprite.Sprite(function.load_image("maps/" + mapname)) | |
| self.image.scale = 6 | |
| def draw(self, game): | |
| self.image.x = -game.xview | |
| self.image.y = -game.yview | |
| self.image.draw() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment