World of Might and Magic  0.2.0
Open reimplementation of Might and Magic 6 7 8 game engine
Файл MapInfo.h

См. исходные тексты.

Классы

struct  MapInfo
 
struct  MapStats
 

Перечисления

enum  MAP_TYPE : uint32_t {
  MAP_INVALID = 0, MAP_EMERALD_ISLE = 1, MAP_HARMONDALE = 2, MAP_STEADWICK = 3,
  MAP_PIERPONT = 4, MAP_DEYJA = 5, MAP_BRAKADA_DESERT = 6, MAP_CELESTIA = 7,
  MAP_THE_PIT = 8, MAP_EVENMORN_ISLE = 9, MAP_MOUNT_NIGHON = 10, MAP_BARROW_DOWNS = 11,
  MAP_LAND_OF_GIANTS = 12, MAP_TATALIA = 13, MAP_AVLEE = 14, MAP_SHOALS = 15,
  MAP_ARENA = 76
}
 
enum  MapStartPoint : uint32_t {
  MapStartPoint_Party = 0, MapStartPoint_North = 1, MapStartPoint_South = 2, MapStartPoint_East = 3,
  MapStartPoint_West = 4
}
 

Функции

void TeleportToStartingPoint (MapStartPoint point)
 

Переменные

struct MapStatspMapStats
 
MapStartPoint uLevel_StartingPointType
 

Перечисления

◆ MAP_TYPE

Элементы перечислений
MAP_INVALID 
MAP_EMERALD_ISLE 
MAP_HARMONDALE 
MAP_STEADWICK 
MAP_PIERPONT 
MAP_DEYJA 
MAP_BRAKADA_DESERT 
MAP_CELESTIA 
MAP_THE_PIT 
MAP_EVENMORN_ISLE 
MAP_MOUNT_NIGHON 
MAP_BARROW_DOWNS 
MAP_LAND_OF_GIANTS 
MAP_TATALIA 
MAP_AVLEE 
MAP_SHOALS 
MAP_ARENA 

См. определение в файле MapInfo.h строка 5

5  : uint32_t {
6  MAP_INVALID = 0,
8  MAP_HARMONDALE = 2,
9  MAP_STEADWICK = 3,
10  MAP_PIERPONT = 4,
11  MAP_DEYJA = 5,
13  MAP_CELESTIA = 7,
14  MAP_THE_PIT = 8,
16  MAP_MOUNT_NIGHON = 10,
17  MAP_BARROW_DOWNS = 11,
18  MAP_LAND_OF_GIANTS = 12,
19  MAP_TATALIA = 13,
20  MAP_AVLEE = 14,
21  MAP_SHOALS = 15,
22  //...
23  MAP_ARENA = 76,
24  //...
25 };

◆ MapStartPoint

Элементы перечислений
MapStartPoint_Party 
MapStartPoint_North 
MapStartPoint_South 
MapStartPoint_East 
MapStartPoint_West 

См. определение в файле MapInfo.h строка 27

27  : uint32_t {
33 };

Функции

◆ TeleportToStartingPoint()

void TeleportToStartingPoint ( MapStartPoint  point)

См. определение в файле MapInfo.cpp строка 308

308  {
309  const char *model_name; // [sp-4h] [bp-84h]@6
310  char pName[128]; // [sp+8h] [bp-78h]@11
311 
312  switch (point) {
313  case MapStartPoint_Party:
314  model_name = "Party Start";
315  break;
316  case MapStartPoint_North:
317  model_name = "North Start";
318  break;
319  case MapStartPoint_South:
320  model_name = "South Start";
321  break;
322  case MapStartPoint_East:
323  model_name = "East Start";
324  break;
325  case MapStartPoint_West:
326  model_name = "West Start";
327  break;
328  default:
329  Error("Invalid enum value: %u", point);
330  }
331 
332  strcpy(pName, model_name);
333  if (pDecorationList->GetDecorIdByName(pName)) {
334  if (uNumLevelDecorations > 0) {
335  for (size_t i = 0; i < uNumLevelDecorations; ++i) {
336  if (pLevelDecorations[i].uDecorationDescID == pDecorationList->GetDecorIdByName(pName)) {
337  pParty->vPosition.x = pLevelDecorations[i].vPosition.x;
338  pParty->vPosition.y = pLevelDecorations[i].vPosition.y;
339  pParty->vPosition.z = pLevelDecorations[i].vPosition.z;
342  pLevelDecorations[i].field_1A) /
343  90;
344  if (pLevelDecorations[i].field_10_y_rot)
345  pParty->sRotationY =
346  pLevelDecorations[i].field_10_y_rot;
347  pParty->sRotationX = 0;
348  pParty->uFallSpeed = 0;
349  }
350  }
351  }
357  if (Party_Teleport_Z_Pos) {
360  }
361  if (Party_Teleport_Cam_Yaw != -1)
366  }
374  }
375 }

Перекрестные ссылки DecorationList::GetDecorIdByName(), MapStartPoint_East, MapStartPoint_North, MapStartPoint_Party, MapStartPoint_South, MapStartPoint_West, Party_Teleport_Cam_Pitch, Party_Teleport_Cam_Yaw, Party_Teleport_X_Pos, Party_Teleport_Y_Pos, Party_Teleport_Z_Pos, Party_Teleport_Z_Speed, pDecorationList, pLevelDecorations, pParty, Party::sRotationX, Party::sRotationY, Start_Party_Teleport_Flag, stru_5C6E00, Party::uFallSpeed, Party::uFallStartY, stru193_math::uIntegerHalfPi, uNumLevelDecorations и Party::vPosition.

Используется в Application::Game::EventLoop(), PrepareToLoadBLV() и PrepareToLoadODM().

+ Граф вызовов:
+ Граф вызова функции:

Переменные

◆ pMapStats

◆ uLevel_StartingPointType

Party::vPosition
Vec3_int_ vPosition
Definition: Party.h:250
pLevelDecorations
std::array< LevelDecoration, 3000 > pLevelDecorations
Definition: Decoration.cpp:8
Party::uFallSpeed
int uFallSpeed
Definition: Party.h:259
Start_Party_Teleport_Flag
int Start_Party_Teleport_Flag
Definition: mm7_data.cpp:628
Party_Teleport_Y_Pos
int Party_Teleport_Y_Pos
Definition: mm7_data.cpp:623
MAP_CELESTIA
@ MAP_CELESTIA
Definition: MapInfo.h:13
Party::sRotationX
int sRotationX
Definition: Party.h:252
MAP_TATALIA
@ MAP_TATALIA
Definition: MapInfo.h:19
stru193_math::uIntegerHalfPi
static const unsigned int uIntegerHalfPi
Definition: OurMath.h:89
MAP_PIERPONT
@ MAP_PIERPONT
Definition: MapInfo.h:10
MAP_STEADWICK
@ MAP_STEADWICK
Definition: MapInfo.h:9
DecorationList::GetDecorIdByName
uint16_t GetDecorIdByName(const char *pName)
Definition: DecorationList.cpp:60
MAP_HARMONDALE
@ MAP_HARMONDALE
Definition: MapInfo.h:8
MapStartPoint_North
@ MapStartPoint_North
Definition: MapInfo.h:29
MAP_AVLEE
@ MAP_AVLEE
Definition: MapInfo.h:20
Party::uFallStartY
int uFallStartY
Definition: Party.h:265
MAP_EMERALD_ISLE
@ MAP_EMERALD_ISLE
Definition: MapInfo.h:7
MAP_BARROW_DOWNS
@ MAP_BARROW_DOWNS
Definition: MapInfo.h:17
MAP_INVALID
@ MAP_INVALID
Definition: MapInfo.h:6
MapStartPoint_East
@ MapStartPoint_East
Definition: MapInfo.h:31
pParty
Party * pParty
Definition: Party.cpp:30
Party_Teleport_Cam_Pitch
int Party_Teleport_Cam_Pitch
Definition: mm7_data.cpp:626
MAP_SHOALS
@ MAP_SHOALS
Definition: MapInfo.h:21
Party_Teleport_X_Pos
int Party_Teleport_X_Pos
Definition: mm7_data.cpp:622
MAP_THE_PIT
@ MAP_THE_PIT
Definition: MapInfo.h:14
Party_Teleport_Cam_Yaw
int Party_Teleport_Cam_Yaw
Definition: mm7_data.cpp:625
MapStartPoint_South
@ MapStartPoint_South
Definition: MapInfo.h:30
uNumLevelDecorations
size_t uNumLevelDecorations
Definition: Decoration.cpp:9
MAP_DEYJA
@ MAP_DEYJA
Definition: MapInfo.h:11
MapStartPoint_West
@ MapStartPoint_West
Definition: MapInfo.h:32
Party_Teleport_Z_Speed
int Party_Teleport_Z_Speed
Definition: mm7_data.cpp:627
MAP_LAND_OF_GIANTS
@ MAP_LAND_OF_GIANTS
Definition: MapInfo.h:18
stru_5C6E00
struct stru193_math * stru_5C6E00
Definition: mm7_data.cpp:19
MAP_ARENA
@ MAP_ARENA
Definition: MapInfo.h:23
MAP_EVENMORN_ISLE
@ MAP_EVENMORN_ISLE
Definition: MapInfo.h:15
MAP_BRAKADA_DESERT
@ MAP_BRAKADA_DESERT
Definition: MapInfo.h:12
MAP_MOUNT_NIGHON
@ MAP_MOUNT_NIGHON
Definition: MapInfo.h:16
uint32_t
unsigned __int32 uint32_t
Definition: SDL_config.h:39
Party_Teleport_Z_Pos
int Party_Teleport_Z_Pos
Definition: mm7_data.cpp:624
Party::sRotationY
int sRotationY
Definition: Party.h:251
MapStartPoint_Party
@ MapStartPoint_Party
Definition: MapInfo.h:28
pDecorationList
struct DecorationList * pDecorationList
Definition: DecorationList.cpp:11