Mercurial > projects > myrrdin
annotate src/tileset.d @ 0:a2d653eb9e99
first working version.
author | fred@reichbier.de |
---|---|
date | Thu, 17 Jul 2008 18:52:55 +0200 |
parents | |
children | fc2f936a961c |
rev | line source |
---|---|
0 | 1 module tileset; |
2 | |
3 import dsfml.window.all; | |
4 import dsfml.system.all; | |
5 import dsfml.graphics.all; | |
6 | |
7 import imagecache; | |
8 | |
9 class Tileset { | |
10 private Cache cache; | |
11 public Image[int] tiles; | |
12 | |
13 this(Cache cache) { | |
14 this.cache = cache; | |
15 } | |
16 | |
17 void add_tile(int id, char[] filename) { | |
18 this.tiles[id] = this.cache.get_image(filename); | |
19 } | |
20 } |