Mercurial > rinkhals
view gamelib/cursors.py @ 267:9cc7bc5cd10c
Refactor sprite cursor a bit to make sub-classing easier. Add (unused) SmallSpriteCursor sub-class. Remove unnecessary pygame.font import.
author | Simon Cross <hodgestar@gmail.com> |
---|---|
date | Sat, 05 Sep 2009 14:02:04 +0000 |
parents | d564ae258471 |
children | cade64404997 |
line wrap: on
line source
"""Data for the in game cursors""" import pygame import data cursors = { 'arrow' : pygame.cursors.arrow, 'select' : pygame.cursors.broken_x, } for tag, filename in [ ('chicken', 'cursors/chkn.xbm'), ('sell', 'cursors/sell_cursor.xbm'), ]: path = data.filepath(filename) # pygame 1.8 needs the file twice to do the right thing # XXX: check behaviour with pygame 1.9 cursors[tag] = pygame.cursors.load_xbm(path, path)