Debian Codegraph @

engine/include/minimap.h

raw
1 // ____ _ __
2 // / __ )____ _____ | | / /___ ___________
3 // / __ / __ \/ ___/ | | /| / / __ `/ ___/ ___/
4 // / /_/ / /_/ (__ ) | |/ |/ / /_/ / / (__ )
5 // /_____/\____/____/ |__/|__/\__,_/_/ /____/
6 //
7 // A futuristic real-time strategy game.
8 // This file is part of Bos Wars.
9 //
10 /**@name minimap.h - The minimap headerfile. */
11 //
12 // (c) Copyright 1998-2008 by Lutz Sammer and Jimmy Salmon
13 //
14 // This program is free software; you can redistribute it and/or modify
15 // it under the terms of the GNU General Public License as published by
16 // the Free Software Foundation; only version 2 of the License.
17 //
18 // This program is distributed in the hope that it will be useful,
19 // but WITHOUT ANY WARRANTY; without even the implied warranty of
20 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 // GNU General Public License for more details.
22 //
23 // You should have received a copy of the GNU General Public License
24 // along with this program; if not, write to the Free Software
25 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
26 // 02111-1307, USA.
27
28 #ifndef __MINIMAP_H__
29 #define __MINIMAP_H__
30
31 //@{
32
33 /*----------------------------------------------------------------------------
34 -- Declarations
35 ----------------------------------------------------------------------------*/
36
37 class CMinimap
38 {
39 public:
40 CMinimap() : X(0), Y(0), W(0), H(0), XOffset(0), YOffset(0),
41 WithTerrain(false), ShowSelected(false), Transparent(false) {}
42
43 void UpdateTerrain();
44 void Update();
45 void Create();
46 void FreeOpenGL();
47 void Reload();
48 void Destroy();
49 void Draw(int vx, int vy);
50 void DrawCursor(int vx, int vy);
51 void AddEvent(int x, int y);
52
53 int Screen2MapX(int x);
54 int Screen2MapY(int y);
55
56 int X;
57 int Y;
58 int W;
59 int H;
60 int XOffset;
61 int YOffset;
62 bool WithTerrain;
63 bool ShowSelected;
64 bool Transparent;
65 };
66
67 //@}
68
69 #endif // !__MINIMAP_H__