#include <CWall.h>
Public Member Functions | |
CWall (void) | |
Constructor (initialize the base class). | |
virtual | ~CWall (void) |
Destructor (uninitialize the base class). | |
void | Create (int BlockX, int BlockY, EWallType Type) |
Initialize the wall. | |
void | Destroy (void) |
Uninitialize the wall. | |
bool | Update (float DeltaTime) |
Update the wall. Return whether the element should be deleted by the arena. | |
void | Display (void) |
Display the wall. | |
void | OnWriteSnapshot (CArenaSnapshot &Snapshot) |
void | OnReadSnapshot (CArenaSnapshot &Snapshot) |
void | Burn (void) |
Make the wall react when it is burnt by an explosion. | |
void | Crush (void) |
Make the wall react when it is crushed by another wall. | |
int | GetBlockX (void) |
Return the block position X of the wall. | |
int | GetBlockY (void) |
Return the block position Y of the wall. | |
bool | IsBurning (void) |
Return whether the wall is burning. | |
int | GetType (void) |
Return the type of the wall. | |
Private Attributes | |
int | m_iX |
Integer position X (in pixels) in the arena. | |
int | m_iY |
Integer position Y (in pixels) in the arena. | |
float | m_fX |
Float position X (in pixels) in the arena (only used for falling walls because they move). | |
float | m_fY |
Float position Y (in pixels) in the arena (only used for falling walls because they move). | |
int | m_BlockX |
Position X (in blocks) in the arena grid. | |
int | m_BlockY |
Position Y (in blocks) in the arena grid. | |
int | m_Sprite |
Current sprite to use when displaying. | |
float | m_Timer |
Time counter for animation. | |
bool | m_Dead |
Is the wall dead? (can it be deleted by the arena?). | |
bool | m_Burning |
Is the wall burning? | |
EWallType | m_Type |
Type of the wall. |
CWall::CWall | ( | void | ) |
Constructor (initialize the base class).
CWall::~CWall | ( | void | ) | [virtual] |
Destructor (uninitialize the base class).
void CWall::Create | ( | int | BlockX, | |
int | BlockY, | |||
EWallType | Type | |||
) |
Initialize the wall.
void CWall::Destroy | ( | void | ) |
Uninitialize the wall.
Reimplemented from CElement.
bool CWall::Update | ( | float | DeltaTime | ) | [virtual] |
Update the wall. Return whether the element should be deleted by the arena.
Implements CElement.
void CWall::Display | ( | void | ) | [virtual] |
Display the wall.
Implements CElement.
void CWall::OnWriteSnapshot | ( | CArenaSnapshot & | Snapshot | ) | [virtual] |
void CWall::OnReadSnapshot | ( | CArenaSnapshot & | Snapshot | ) | [virtual] |
void CWall::Burn | ( | void | ) |
Make the wall react when it is burnt by an explosion.
void CWall::Crush | ( | void | ) |
Make the wall react when it is crushed by another wall.
int CWall::GetBlockX | ( | void | ) | [inline] |
Return the block position X of the wall.
int CWall::GetBlockY | ( | void | ) | [inline] |
Return the block position Y of the wall.
bool CWall::IsBurning | ( | void | ) | [inline] |
Return whether the wall is burning.
int CWall::GetType | ( | void | ) | [inline] |
Return the type of the wall.
int CWall::m_iX [private] |
Integer position X (in pixels) in the arena.
int CWall::m_iY [private] |
Integer position Y (in pixels) in the arena.
float CWall::m_fX [private] |
Float position X (in pixels) in the arena (only used for falling walls because they move).
float CWall::m_fY [private] |
Float position Y (in pixels) in the arena (only used for falling walls because they move).
int CWall::m_BlockX [private] |
Position X (in blocks) in the arena grid.
int CWall::m_BlockY [private] |
Position Y (in blocks) in the arena grid.
int CWall::m_Sprite [private] |
Current sprite to use when displaying.
float CWall::m_Timer [private] |
Time counter for animation.
bool CWall::m_Dead [private] |
Is the wall dead? (can it be deleted by the arena?).
bool CWall::m_Burning [private] |
Is the wall burning?
EWallType CWall::m_Type [private] |
Type of the wall.