/[projectaxis]/projectaxis/IsoEngine/TileEngineTest.cpp
ViewVC logotype

Diff of /projectaxis/IsoEngine/TileEngineTest.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5 by vovansim, Sat Jun 7 03:55:54 2003 UTC revision 1.6 by vovansim, Sat Sep 13 21:40:20 2003 UTC
# Line 32  bool click = false; Line 32  bool click = false;
32    
33  int theMap[MAP_HEIGHT][MAP_WIDTH];  int theMap[MAP_HEIGHT][MAP_WIDTH];
34    
35  //rendering functionprototype  //rendering function prototype
36  void RenderFunc(SDL_Surface* dst, RECT* clipRect, int xDst, int yDst, int xMap, int yMap);  void RenderFunc(SDL_Surface* dst, RECT* clipRect, int xDst, int yDst, int xMap, int yMap);
37    
38  void loadTileSets() {  void loadTileSets() {
# Line 44  void loadTileSets() { Line 44  void loadTileSets() {
44    
45  void initializeEngine() {  void initializeEngine() {
46          //load in the mousemap          //load in the mousemap
47          mouseMap.create(tsBack.getTileList()[0].rcSrc.right - tsBack.getTileList()[0].rcSrc.left, tsBack.getTileList()[0].rcSrc.bottom - tsBack.getTileList()[0].rcSrc.top);          //mouseMap.create(tsBack.getTileList()[0].rcSrc.right - tsBack.getTileList()[0].rcSrc.left, tsBack.getTileList()[0].rcSrc.bottom - tsBack.getTileList()[0].rcSrc.top);
48            mouseMap.load("MouseMap.bmp");
49    
50          //set up the tile plotter          //set up the tile plotter
51            //tilePlotter.setMapType(ISOMAP_RECTANGULAR);
52            tilePlotter.setMapType(ISOMAP_STAGGERED);
53          tilePlotter.setTileSize(mouseMap.getWidth(), mouseMap.getHeight());          tilePlotter.setTileSize(mouseMap.getWidth(), mouseMap.getHeight());
54    
55            //set up tile walker to diamond mode
56            //tileWalker.setMapType(ISOMAP_RECTANGULAR);
57            tileWalker.setMapType(ISOMAP_STAGGERED);
58    
59          //set up screeen space          //set up screeen space
60          RECT temp;          RECT temp;
61          setRect(&temp, 0, 0, 640, 480);          setRect(&temp, 0, 0, 640, 480);
# Line 205  void programLoop() { Line 212  void programLoop() {
212  void testEngine() {  void testEngine() {
213    
214          /* Seed the random-number generator with current time so that          /* Seed the random-number generator with current time so that
215          * the map will be different every time we run. */           * the map will be different every time we run. */
216          srand((unsigned)time(NULL));          srand((unsigned)time(NULL));
217    
218          loadTileSets();          loadTileSets();

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26