/[projectaxis]/projectaxis/projectAxis/src/visual/mapwindow.cpp
ViewVC logotype

Diff of /projectaxis/projectAxis/src/visual/mapwindow.cpp

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

revision 1.4 by leiavoia, Wed Aug 20 18:25:14 2003 UTC revision 1.5 by leiavoia, Sun Sep 14 01:05:00 2003 UTC
# Line 13  Line 13 
13  #include "uiscreen_main.h"  #include "uiscreen_main.h"
14    
15    
16    
17    
18    
19  //CONSTANTS  //CONSTANTS
20  static const int RECENTER_BUFFER = 3; // the buffer space in tiles that a pod must be outside of to warrant recentering the map  static const int RECENTER_BUFFER = 3; // the buffer space in tiles that a pod must be outside of to warrant recentering the map
21    static const long TIMING_LOOP_DELAY = 75; // ticks per re-display in MovePod()
22    
23    
24    
   
25  PG_MapWindow::PG_MapWindow(PG_Widget *parent, const PG_Rect &r):  PG_MapWindow::PG_MapWindow(PG_Widget *parent, const PG_Rect &r):
26          PG_Widget(parent, r, 0) // yes we do want an object drawing surface          PG_Widget(parent, r, 0) // yes we do want an object drawing surface
27          {          {
# Line 92  void PG_MapWindow::MovePod(int x1, int y Line 92  void PG_MapWindow::MovePod(int x1, int y
92                  tile_array[x2 - bg_x][y2 - bg_y]->SetCoordsAndDraw(x2,y2);                  tile_array[x2 - bg_x][y2 - bg_y]->SetCoordsAndDraw(x2,y2);
93                  }                  }
94    
95            SDL_Delay(TIMING_LOOP_DELAY);
96    
97          }          }
98    
99    
# Line 100  void PG_MapWindow::MovePod(int x1, int y Line 102  void PG_MapWindow::MovePod(int x1, int y
102    
103  void PG_MapWindow::CenterMap(int x, int y) {  void PG_MapWindow::CenterMap(int x, int y) {
104    
105          int tile_size = rm->GetTileSize();          //int tile_size = rm->GetTileSize();
106          int maprows = themap->GetRows();          int maprows = themap->GetRows();
107          int mapcols = themap->GetCols();          int mapcols = themap->GetCols();
108          int v_dist = rows; // we need these temps in case screen is larger than whole map          int v_dist = rows; // we need these temps in case screen is larger than whole map

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

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