#include <src/Misc/SWTypes/Reveal.h>
List of all members.
Constructor & Destructor Documentation
SW_Reveal::SW_Reveal |
( |
| ) |
[inline] |
virtual SW_Reveal::~SW_Reveal |
( |
| ) |
[inline, virtual] |
Member Function Documentation
virtual const char* SW_Reveal::GetTypeString |
( |
| ) |
[inline, virtual] |
bool SW_Reveal::HandlesType |
( |
int |
type | ) |
[virtual] |
Reimplemented from NewSWType.
{
return (type == SuperWeaponType::PsychicReveal);
}
void SW_Reveal::Initialize |
( |
SWTypeExt::ExtData * |
pData, |
|
|
SuperWeaponTypeClass * |
pSW |
|
) |
| [virtual] |
bool SW_Reveal::Launch |
( |
SuperClass * |
pThis, |
|
|
CellStruct * |
pCoords, |
|
|
byte |
IsPlayer |
|
) |
| [virtual] |
Implements NewSWType.
{
SuperWeaponTypeClass *pSW = pThis->Type;
SWTypeExt::ExtData *pData = SWTypeExt::ExtMap.Find(pSW);
if(pThis->IsCharged) {
CellClass *pTarget = MapClass::Instance->GetCellAt(pCoords);
CoordStruct Crd;
pTarget->GetCoords(&Crd);
float width = pData->SW_WidthOrRange;
int height = pData->SW_Height;
Helpers::Alex::forEachCellInRange(pCoords, width, height,
[&](CellClass* pCell) -> bool {
CoordStruct Crd2;
pCell->GetCoords(&Crd2);
MapClass::Instance->RevealArea2(&Crd2, 1, pThis->Owner, 0, 0, 0, 0, 0);
MapClass::Instance->RevealArea2(&Crd2, 1, pThis->Owner, 0, 0, 0, 0, 1);
return true;
}
);
}
return true;
}
The documentation for this class was generated from the following files: