~ubuntu-branches/ubuntu/lucid/warzone2100/lucid

« back to all changes in this revision

Viewing changes to src/radar.h

  • Committer: Bazaar Package Importer
  • Author(s): Christoph Egger, Paul Wise, Christoph Egger
  • Date: 2009-06-29 17:12:52 UTC
  • mfrom: (1.1.11 upstream) (2.1.7 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090629171252-5ddnlfg3zfchrega
Tags: 2.2.1+dfsg1-1
[ Paul Wise ]
* New upstream release (Closes: #534962)
* Adjust the flex build-depends to take account of the conflict
  with all the versions of flex 2.5.34 (LP: #372872)
* Make the -music Recommends more strict, 2.1 music doesn't work
  with 2.2.
* Upstream moved the downloads to sourceforge, update the watch file
* Bump Standards-Version, no changes needed
* Drop use of dh_desktop since it no longer does anything
* Recommend the new warzone2100-video package, version 2.2 or similar
* Mention the warzone2100 crash reports in the -dbg package description

[ Christoph Egger ]
* Replace CC-2.0 graphic from cybersphinx, create a new tarball
* Add myself to uploaders

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
        This file is part of Warzone 2100.
3
3
        Copyright (C) 1999-2004  Eidos Interactive
4
 
        Copyright (C) 2005-2007  Warzone Resurrection Project
 
4
        Copyright (C) 2005-2009  Warzone Resurrection Project
5
5
 
6
6
        Warzone 2100 is free software; you can redistribute it and/or modify
7
7
        it under the terms of the GNU General Public License as published by
18
18
        Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19
19
*/
20
20
 
 
21
/**
 
22
 *      @file radar.h
 
23
 *      Minimap code.
 
24
 *      @defgroup Minimap Minimap (radar) subsystem.
 
25
 *      @{
 
26
 */
 
27
 
21
28
#ifndef __INCLUDED_SRC_RADAR_H__
22
29
#define __INCLUDED_SRC_RADAR_H__
23
30
 
24
 
void radarColour(UDWORD tileNumber, uint8_t r, uint8_t g, uint8_t b);
25
 
 
26
 
#define MAX_RADARZOOM   1
27
 
 
28
 
/* Radar.h */
 
31
void radarColour(UDWORD tileNumber, uint8_t r, uint8_t g, uint8_t b);   ///< Set radar colour for given terrain type.
 
32
 
 
33
#define MAX_RADARZOOM   2.50f
 
34
#define MIN_RADARZOOM   0.75f
 
35
#define RADARZOOM_STEP  0.25f
 
36
 
29
37
extern void resetRadarRedraw(void);
30
 
extern BOOL InitRadar(void);
31
 
extern BOOL ShutdownRadar(void);
32
 
extern void     drawRadar(void);
33
 
extern void CalcRadarPosition(UDWORD mX,UDWORD mY,UDWORD *PosX,UDWORD *PosY);
34
 
extern void SetRadarZoom(UWORD ZoomLevel);
35
 
extern UDWORD GetRadarZoom(void);
36
 
extern BOOL CoordInRadar(int x,int y);
 
38
extern BOOL InitRadar(void);                            ///< Initialize minimap subsystem.
 
39
extern BOOL ShutdownRadar(void);                        ///< Shutdown minimap subsystem.
 
40
extern BOOL resizeRadar(void);                          ///< Recalculate minimap size. For initialization code only.
 
41
extern void drawRadar(void);                            ///< Draw the minimap on the screen.
 
42
extern void CalcRadarPosition(int mX, int mY, int *PosX, int *PosY);    ///< Given a position within the radar, returns a world coordinate.
 
43
extern void SetRadarZoom(float ZoomLevel);              ///< Set current zoom level. 1.0 is 1:1 resolution.
 
44
extern float GetRadarZoom(void);                        ///< Get current zoom level.
 
45
extern BOOL CoordInRadar(int x, int y);                 ///< Is screen coordinate inside minimap?
37
46
 
38
 
//different mini-map draw modes
 
47
/** Different mini-map draw modes. */
39
48
typedef enum _radar_draw_mode
40
49
{
41
 
        RADAR_MODE_TERRAIN,                                             //draw texture map
42
 
        RADAR_MODE_DEFAULT = RADAR_MODE_TERRAIN,
43
 
        RADAR_MODE_HEIGHT_MAP,                                  //draw height map
 
50
        RADAR_MODE_TERRAIN,                             ///< Draw terrain map
 
51
        RADAR_MODE_DEFAULT = RADAR_MODE_TERRAIN,        ///< Default is terrain map
 
52
        RADAR_MODE_HEIGHT_MAP,                          ///< Draw height map
44
53
        RADAR_MODE_COMBINED,
45
 
        RADAR_MODE_NO_TERRAIN,
 
54
        RADAR_MODE_NO_TERRAIN,                          ///< Only display objects
46
55
        NUM_RADAR_MODES
47
56
}RADAR_DRAW_MODE;
48
57
 
49
 
extern BOOL             bEnemyAllyRadarColor;           //enemy/ally radar color
50
 
extern RADAR_DRAW_MODE  radarDrawMode;          //current mini-map mode
 
58
extern BOOL             bEnemyAllyRadarColor;           ///< Enemy/ally minimap color
 
59
extern RADAR_DRAW_MODE  radarDrawMode;                  ///< Current minimap mode
 
60
extern BOOL rotateRadar;
51
61
 
52
 
extern void radarInitVars(void);
 
62
extern void radarInitVars(void);                        ///< Recalculate minimap variables. For initialization code only.
53
63
extern PIELIGHT clanColours[MAX_PLAYERS];
54
64
 
 
65
/** @} */
 
66
 
55
67
#endif // __INCLUDED_SRC_RADAR_H__