22 #ifndef MM1_MAPS_MAPS_H 23 #define MM1_MAPS_MAPS_H 25 #include "common/array.h" 26 #include "common/rect.h" 27 #include "graphics/managed_surface.h" 28 #include "mm/mm1/maps/map.h" 35 NO_TOWN = 0, SORPIGAL = 1, PORTSMITH = 2,
36 ALGARY = 3, DUSK = 4, ERLIQUIN = 5
40 DIRMASK_N = 0xC0, DIRMASK_E = 0x30,
41 DIRMASK_S = 0xC, DIRMASK_W = 3
45 SFLAG_SPELLS_DISALLOWED = 2
49 VISITED_NONE = 0, VISITED_NORMAL = 1, VISITED_SPECIAL = 2,
50 VISITED_EXIT = 3, VISITED_BUSINESS = 4
66 uint getIndex(uint16
id, byte section);
71 void load(uint mapId);
97 void updateMasksOffsets();
101 uint _mapId = (uint)-1;
104 Map *_currentMap =
nullptr;
105 byte _currentWalls = 0;
106 byte _currentState = 0;
107 int _colorOffset = 0;
109 DirMask _forwardMask = DIRMASK_N,
110 _leftMask = DIRMASK_W,
111 _rightMask = DIRMASK_E,
112 _backwardsMask = DIRMASK_S;
113 int8 _forwardOffset = 0, _leftOffset = 0;
114 int8 _rightOffset = 0, _backwardsOffset = 0;
117 int _loadSection = 0;
136 void select(uint16
id, byte section);
141 void display(uint16
id, byte section = 1);
Map * getMap(uint mapId) const
Definition: maps.h:151
void synchronize(Common::Serializer &s)
void select(uint16 id, byte section)
void step(const Common::Point &delta)
void synchronizeCurrent(Common::Serializer &s)
static Common::Point getMoveDelta(byte mask)
Definition: serializer.h:79
void display(uint16 id, byte section=1)
void changeMap(uint16 id, byte section)
void loadTown(TownId townId)
Definition: detection.h:27