CMap Class Reference

Holds tile information and performs collision detection with the tiles. More...

#include <class.map.hh>

Collaboration diagram for CMap:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 CMap ()
 ~CMap ()
bool Init (const char *szMapFilePath, SDL_Surface *pTargetSurface)
void Cleanup ()
bool CheckPixelBoundsXY (int x, int y)
 Tests if coordinates are out of bounds.
bool CheckMapBoundsXY (int x, int y)
 Tests if coordinates are out of bounds.
bool CollisionXY (int x, int y)
 Tests for collisions with the tiles.

Public Attributes

bool mbInit
CSpritempTiles [G_MAP_WIDTH][G_MAP_HEIGHT]
SDL_Surface * mpTargetSurface
CMusicmpMusic


Detailed Description

Holds tile information and performs collision detection with the tiles.

Constructor & Destructor Documentation

CMap::CMap (  ) 

CMap::~CMap (  ) 


Member Function Documentation

bool CMap::Init ( const char *  szMapFilePath,
SDL_Surface *  pTargetSurface 
)

void CMap::Cleanup (  ) 

bool CMap::CheckPixelBoundsXY ( int  x,
int  y 
)

Tests if coordinates are out of bounds.

Parameters:
x The X position is in pixels.
y The Y position is in pixels.

bool CMap::CheckMapBoundsXY ( int  x,
int  y 
)

Tests if coordinates are out of bounds.

Parameters:
x The X position is in map coordinates.
y The Y position is in map coordinates.

bool CMap::CollisionXY ( int  x,
int  y 
)

Tests for collisions with the tiles.

Parameters:
x The X position is in map coordinates.
y The Y position is in map coordinates.


Member Data Documentation

CSprite* CMap::mpTiles[G_MAP_WIDTH][G_MAP_HEIGHT]

SDL_Surface* CMap::mpTargetSurface


The documentation for this class was generated from the following files:

Generated on Fri Feb 22 09:36:53 2008 for Mega Maryo by  doxygen 1.5.5