DDraceNetwork Docs
map_replace_area.cpp File Reference
#include <base/logger.h>
#include <base/system.h>
#include <engine/shared/datafile.h>
#include <engine/storage.h>
#include <game/mapitems.h>
Include dependency graph for map_replace_area.cpp:

Classes

class  CMapObject
 

Functions

bool ReplaceArea (IStorage *, const char[3][64], const float[][2][2])
 
bool OpenMaps (IStorage *, const char[3][64], CDataFileReader[2], CDataFileWriter &)
 
void SaveOutputMap (CDataFileReader &, CDataFileWriter &)
 
bool CompareLayers (const char[3][64], CDataFileReader[2])
 
void CompareGroups (const char[3][64], CDataFileReader[2])
 
const CMapItemGroupGetLayerGroup (CDataFileReader &, int)
 
void ReplaceAreaTiles (CDataFileReader[2], const float[][2][2], const CMapItemGroup *[2], CMapItemLayer *[2])
 
void RemoveDestinationTiles (CMapItemLayerTilemap *, CTile *, float[2][2])
 
void ReplaceDestinationTiles (CMapItemLayerTilemap *[2], CTile *[2], float[2][2][2])
 
bool AdaptVisibleAreas (const float[2][2][2], const CMapObject[2], float[2][2][2])
 
bool AdaptReplaceableAreas (const float[2][2][2], const float[2][2][2], const CMapObject[2], float[2][2][2])
 
void ReplaceAreaQuads (CDataFileReader[2], const float[][2][2], const CMapItemGroup *[2], CMapItemLayer *[2], int)
 
bool RemoveDestinationQuads (const float[2][2], const CQuad *, int, const CMapItemGroup *, CQuad *, int &)
 
bool InsertDestinationQuads (const float[2][2][2], const CQuad *, int, const CMapItemGroup *[2], CQuad *, int &)
 
bool AdaptVisiblePoint (const float[2][2][2], const float[2][2], const CMapObject[2], float[2])
 
CMapObject CreateMapObject (const CMapItemGroup *, int, int, int, int)
 
void SetExtendedArea (CMapObject &)
 
bool GetVisibleArea (const float[2][2], const CMapObject &, float[2][2]=0x0)
 
bool GetReplaceableArea (const float[2][2], const CMapObject &, float[2][2])
 
void GetGameAreaDistance (const float[2][2][2], const CMapObject[2], const float[2][2][2], float[2])
 
void GetGameAreaDistance (const float[2][2][2], const CMapObject[2], const float[2][2], float[2])
 
void GetSignificantScreenPos (const CMapObject &, const float[2][2], const float[2][2], float[2])
 
void ConvertToTiles (const float[2][2], int[2][2])
 
bool GetLineIntersection (const float[2], const float[2], float[2]=0x0)
 
bool GetLineIntersection (const float[2], float)
 
void SetInexistent (float *, int)
 
bool IsInexistent (const float *, int)
 
bool IsInexistent (float)
 
int main (int argc, const char *argv[])
 

Variables

void * g_apNewData [1024]
 
void * g_apNewItem [1024]
 
int g_aNewDataSize [1024]
 

Function Documentation

◆ AdaptReplaceableAreas()

bool AdaptReplaceableAreas ( const float  aaaGameAreas[2][2][2],
const float  aaaVisibleAreas[2][2][2],
const CMapObject  aObs[2],
float  aaaReplaceableAreas[2][2][2] 
)

◆ AdaptVisibleAreas()

bool AdaptVisibleAreas ( const float  aaaGameAreas[2][2][2],
const CMapObject  aObs[2],
float  aaaVisibleAreas[2][2][2] 
)

◆ AdaptVisiblePoint()

bool AdaptVisiblePoint ( const float  aaaGameAreas[2][2][2],
const float  aaVisibleArea[2][2],
const CMapObject  aObs[2],
float  aPos[2] 
)

◆ CompareGroups()

void CompareGroups ( const char  aaMapNames[3][64],
CDataFileReader  aInputMaps[2] 
)

◆ CompareLayers()

bool CompareLayers ( const char  aaMapNames[3][64],
CDataFileReader  aInputMaps[2] 
)

◆ ConvertToTiles()

void ConvertToTiles ( const float  aaArea[2][2],
int  aaTiles[2][2] 
)

◆ CreateMapObject()

CMapObject CreateMapObject ( const CMapItemGroup pLayerGroup,
int  PosX,
int  PosY,
int  Width,
int  Height 
)

◆ GetGameAreaDistance() [1/2]

void GetGameAreaDistance ( const float  aaaGameAreas[2][2][2],
const CMapObject  aObs[2],
const float  aaVisibleArea[2][2],
float  aDistance[2] 
)

◆ GetGameAreaDistance() [2/2]

void GetGameAreaDistance ( const float  aaaGameAreas[2][2][2],
const CMapObject  aObs[2],
const float  aaaVisibleAreas[2][2][2],
float  aDistance[2] 
)

◆ GetLayerGroup()

const CMapItemGroup * GetLayerGroup ( CDataFileReader InputMap,
int  LayerNumber 
)

◆ GetLineIntersection() [1/2]

bool GetLineIntersection ( const float  aLine1[2],
const float  aLine2[2],
float  aIntersection[2] = 0x0 
)

◆ GetLineIntersection() [2/2]

bool GetLineIntersection ( const float  aLine[2],
float  Point 
)

◆ GetReplaceableArea()

bool GetReplaceableArea ( const float  aaVisibleArea[2][2],
const CMapObject Ob,
float  aaReplaceableArea[2][2] 
)

◆ GetSignificantScreenPos()

void GetSignificantScreenPos ( const CMapObject Ob,
const float  aaVisibleArea[2][2],
const float  aaReplaceableArea[2][2],
float  aScreen[2] 
)

◆ GetVisibleArea()

bool GetVisibleArea ( const float  aaGameArea[2][2],
const CMapObject Ob,
float  aaVisibleArea[2][2] = 0x0 
)

◆ InsertDestinationQuads()

bool InsertDestinationQuads ( const float  aaaGameAreas[2][2][2],
const CQuad pQuads,
int  NumQuads,
const CMapItemGroup apLayerGroups[2],
CQuad pDestQuads,
int &  QuadsCounter 
)

◆ IsInexistent() [1/2]

bool IsInexistent ( const float *  pArray,
int  Count 
)

◆ IsInexistent() [2/2]

bool IsInexistent ( float  Value)

◆ main()

int main ( int  argc,
const char *  argv[] 
)

◆ OpenMaps()

bool OpenMaps ( IStorage pStorage,
const char  aaMapNames[3][64],
CDataFileReader  aInputMaps[2],
CDataFileWriter OutputMap 
)

◆ RemoveDestinationQuads()

bool RemoveDestinationQuads ( const float  aaGameArea[2][2],
const CQuad pQuads,
int  NumQuads,
const CMapItemGroup pLayerGroup,
CQuad pDestQuads,
int &  QuadsCounter 
)

◆ RemoveDestinationTiles()

void RemoveDestinationTiles ( CMapItemLayerTilemap pTilemap,
CTile pTile,
float  aaReplaceableArea[2][2] 
)

◆ ReplaceArea()

bool ReplaceArea ( IStorage pStorage,
const char  aaMapNames[3][64],
const float  aaaGameAreas[][2][2] 
)

◆ ReplaceAreaQuads()

void ReplaceAreaQuads ( CDataFileReader  aInputMaps[2],
const float  aaaGameAreas[][2][2],
const CMapItemGroup apLayerGroups[2],
CMapItemLayer apItem[2],
int  ItemNumber 
)

◆ ReplaceAreaTiles()

void ReplaceAreaTiles ( CDataFileReader  aInputMaps[2],
const float  aaaGameAreas[][2][2],
const CMapItemGroup apLayerGroups[2],
CMapItemLayer apItem[2] 
)

◆ ReplaceDestinationTiles()

void ReplaceDestinationTiles ( CMapItemLayerTilemap apTilemap[2],
CTile apTile[2],
float  aaaReplaceableAreas[2][2][2] 
)

◆ SaveOutputMap()

void SaveOutputMap ( CDataFileReader InputMap,
CDataFileWriter OutputMap 
)

◆ SetExtendedArea()

void SetExtendedArea ( CMapObject Ob)

◆ SetInexistent()

void SetInexistent ( float *  pArray,
int  Count 
)

Variable Documentation

◆ g_aNewDataSize

int g_aNewDataSize[1024]

◆ g_apNewData

void* g_apNewData[1024]

◆ g_apNewItem

void* g_apNewItem[1024]