Hosting courtesy of Sourceforge

SourceForge Logo
Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

Game::GameMap Class Reference

#include <GameMap.h>

Collaboration diagram for Game::GameMap:

Collaboration graph
[legend]
List of all members.

Public Methods

bool runGame (SDL_Surface *screen)
bool tileIsPassable (int x, int y) const
void explodeTile (int x, int y)
void addPlayer (const std::string &blpFile, const std::string &cfgFile)

Detailed Description

Class that provides both the ability to test for collosions between players and tiles as well as well as the ability to draw itself.

Definition at line 82 of file GameMap.h.


Constructor & Destructor Documentation

GameMap::GameMap  
 

Definition at line 77 of file GameMap.cpp.

GameMap::~GameMap  
 

Definition at line 87 of file GameMap.cpp.


Member Function Documentation

void GameMap::addPlayer const std::string &    blpFileName,
const std::string &    cfgFileName
 

Add player to the game

Parameters:
blpFile  file containing player animation data
cfgFile  file containing input data (keys/joystick)

Definition at line 152 of file GameMap.cpp.

void GameMap::explodeTile int    x,
int    y
 

Tells the tile at x,y to blow up, whether it has any effect on the tile is up to the tile

Definition at line 200 of file GameMap.cpp.

void GameMap::readMap std::istream &    input
 

Definition at line 105 of file GameMap.cpp.

bool GameMap::runGame SDL_Surface *    screen
 

Run a single iteration through the game loop, getting input, moving players, drawing, etc

Returns:
true if done

Definition at line 299 of file GameMap.cpp.

bool GameMap::tileIsPassable int    x,
int    y
const
 

Tells whether a tile in the map is passable

Parameters:
x  row the queried tile is in
y  column that the queried tile is in
Returns:
false if either x or y is out of range, else, if the given valid tile is passable

Definition at line 127 of file GameMap.cpp.


Friends And Related Function Documentation

friend class BombPairAtPred [friend]
 

Definition at line 136 of file GameMap.h.


The documentation for this class was generated from the following files:
Generated on Tue May 21 07:26:52 2002 for BomberLAN by doxygen1.2.12 written by Dimitri van Heesch, © 1997-2001