|
Pokered Save Editor 2
Pokemon Red & Blue save file editor - Qt 6 C++/QML
|
One map's complete static definition – the root of the MapDBEntry family. More...
#include <mapdbentry.h>
Public Member Functions | |
| const QString | bestName () const |
| < Best display name (modern/internal). | |
| int | height2X2 () const |
| Height x2 (derived; see note). | |
| int | width2X2 () const |
| Width x2 (derived; see note). | |
| const QString | getName () const |
| int | getInd () const |
| bool | getGlitch () const |
| bool | getSpecial () const |
| const QVector< MapDBEntryWarpOut * > | getWarpOut () const |
| Outgoing warps. | |
| int | getWarpOutSize () const |
| const MapDBEntryWarpOut * | getWarpOutAt (const int ind) const |
Outgoing warp ind (for QML). | |
| const QVector< MapDBEntryWarpIn * > | getWarpIn () const |
| Incoming warps. | |
| int | getWarpInSize () const |
| const MapDBEntryWarpIn * | getWarpInAt (const int ind) const |
Incoming warp ind (for QML). | |
| const QVector< MapDBEntrySign * > | getSigns () const |
| Signs on the map. | |
| int | getSignsSize () const |
| const MapDBEntrySign * | getSignsAt (const int ind) const |
Sign ind (for QML). | |
| const QVector< MapDBEntrySprite * > | getSprites () const |
| Sprites on the map. | |
| int | getSpritesSize () const |
| const MapDBEntrySprite * | getSpritesAt (const int ind) const |
Sprite ind (for QML). | |
| const QHash< int, MapDBEntryConnect * > | getConnect () const |
| Edge connections by direction. | |
| const MapDBEntryConnect * | getConnectAt (const int val) const |
Connection in direction val (for QML). | |
| int | getMonRate () const |
| int | getMonRateWater () const |
| const QVector< MapDBEntryWildMon * > | getMonsRed () const |
| Red-version wild encounters. | |
| int | getMonsRedSize () const |
| const MapDBEntryWildMon * | getMonsRedAt (const int ind) const |
Red wild ind (for QML). | |
| const QVector< MapDBEntryWildMon * > | getMonsBlue () const |
| Blue-version wild encounters. | |
| int | getMonsBlueSize () const |
| const MapDBEntryWildMon * | getMonsBlueAt (const int ind) const |
Blue wild ind (for QML). | |
| const QVector< MapDBEntryWildMon * > | getMonsWater () const |
| Water wild encounters. | |
| int | getMonsWaterSize () const |
| const MapDBEntryWildMon * | getMonsWaterAt (const int ind) const |
Water wild ind (for QML). | |
| int | getSpriteSet () const |
| SpriteSetDBEntry * | getToSpriteSet () const |
| int | getBorder () const |
| int | getBank () const |
| int | getDataPtr () const |
| int | getScriptPtr () const |
| int | getTextPtr () const |
| int | getWidth () const |
| int | getHeight () const |
| const QString | getMusic () const |
| const QString | getTileset () const |
| const QString | getModernName () const |
| const QString | getIncomplete () const |
| MusicDBEntry * | getToMusic () const |
| TilesetDBEntry * | getToTileset () const |
| MapDBEntry * | getToComplete () const |
| const QVector< EventDBEntry * > | getToEvents () const |
| Events associated with this map. | |
| int | getToEventsSize () const |
| const EventDBEntry * | getToEventsAt (const int ind) const |
Associated event ind (for QML). | |
| FlyDBEntry * | getToFlyDestination () const |
| const QVector< HiddenItemDBEntry * > | getToHiddenItems () const |
| Hidden items on this map. | |
| int | getToHiddenItemsSize () const |
| const HiddenItemDBEntry * | getToHiddenItemsAt (const int ind) const |
Hidden item ind (for QML). | |
| ScriptDBEntry * | getToScript () const |
| void | qmlProtect (const QQmlEngine *const engine) const |
| Pin to C++ ownership. | |
Protected Member Functions | |
| MapDBEntry () | |
| Empty entry (built by MapsDB). | |
| MapDBEntry (const QJsonValue &data) | |
| Build from a JSON value. | |
| void | deepLink () |
| Resolve the full cross-reference web. | |
| void | qmlRegister () const |
| Register with QML. | |
Protected Attributes | |
| QString | name = "" |
| Backing field (read via getName()). | |
| int | ind = -1 |
| Backing field (read via getInd()). | |
| bool | glitch = false |
| Backing field (read via getGlitch()). | |
| bool | special = false |
| Backing field (read via getSpecial()). | |
| QVector< MapDBEntryWarpOut * > | warpOut |
| Outgoing warps. | |
| QVector< MapDBEntryWarpIn * > | warpIn |
| Incoming warps. | |
| QVector< MapDBEntrySign * > | signs |
| Signs. | |
| QVector< MapDBEntrySprite * > | sprites |
| Sprites. | |
| QHash< int, MapDBEntryConnect * > | connect |
| Edge connections by direction. | |
| int | monRate = -1 |
| Land encounter rate. | |
| int | monRateWater = -1 |
| Water encounter rate. | |
| QVector< MapDBEntryWildMon * > | monsRed |
| Red-version land encounters. | |
| QVector< MapDBEntryWildMon * > | monsBlue |
| Blue-version land encounters. | |
| QVector< MapDBEntryWildMon * > | monsWater |
| Water encounters (shared; see note). | |
| int | spriteSet = -1 |
| Sprite-set index. | |
| SpriteSetDBEntry * | toSpriteSet = nullptr |
| Resolved sprite set (deepLink). | |
| int | border = -1 |
| Border block number. | |
| int | bank = -1 |
| Map data bank. | |
| int | dataPtr = -1 |
| Map data pointer. | |
| int | scriptPtr = -1 |
| Map script pointer. | |
| int | textPtr = -1 |
| Map text pointer. | |
| int | width = -1 |
| Width (blocks). | |
| int | height = -1 |
| Height (blocks). | |
| QString | music = "" |
| Music name. | |
| QString | tileset = "" |
| Tileset name. | |
| QString | modernName = "" |
| Modern display name. | |
| QString | incomplete = "" |
| Incomplete-map marker. | |
| MusicDBEntry * | toMusic = nullptr |
| TilesetDBEntry * | toTileset = nullptr |
| MapDBEntry * | toComplete = nullptr |
| QVector< EventDBEntry * > | toEvents |
| FlyDBEntry * | toFlyDestination = nullptr |
| QVector< HiddenItemDBEntry * > | toHiddenItems |
| ScriptDBEntry * | toScript = nullptr |
| Resolved script (deepLink). | |
Friends | |
| class | MapsDB |
| class | MapSearch |
| struct | EventDBEntry |
| struct | FlyDBEntry |
| struct | HiddenItemDBEntry |
| struct | ScriptDBEntry |
One map's complete static definition – the root of the MapDBEntry family.
The DB counterpart to the save's Area: everything canonical about a map. It owns the map's warps (in/out), signs, sprites, edge connections, and wild-encounter tables (red/blue/water), plus its pointers, sprite-set, music, and tileset. deepLink() then resolves a wide web of cross-references (the to* members): music, tileset, the "complete" version of an incomplete map, associated events, fly destination, hidden items, and script.
Sub-lists are surfaced to QML via the ...Size + invokable ...At() accessor workaround. This is the largest entry family in the project; the sub-types (warps, sign, sprite + its 4 subclasses, connect, wildmon) each have their own header. See db.md.
Definition at line 56 of file mapdbentry.h.
|
protected |
Empty entry (built by MapsDB).
Definition at line 50 of file mapdbentry.cpp.
References qmlRegister().
Referenced by getToComplete().
|
protected |
Build from a JSON value.
Definition at line 55 of file mapdbentry.cpp.
References bank, border, connect, dataPtr, MapDBEntryConnect::EAST, glitch, height, incomplete, ind, modernName, monRate, monRateWater, monsBlue, monsRed, monsWater, music, name, MapDBEntryConnect::NORTH, scriptPtr, signs, MapDBEntryConnect::SOUTH, special, sprites, spriteSet, textPtr, tileset, warpIn, warpOut, MapDBEntryConnect::WEST, and width.
| const QString MapDBEntry::bestName | ( | ) | const |
< Best display name (modern/internal).
Height in 2x2 units (derived). Width in 2x2 units (derived). Internal name. Map index. Glitch map. Special map. Number of outgoing warps. Number of incoming warps. Number of signs. Number of sprites. Land encounter rate. Water encounter rate. Red-version wild count. Blue-version wild count. Water wild count. Sprite-set index. Resolved sprite set. Border block number. Map data bank. Map data pointer. Map script pointer. Map text pointer. Width (blocks). Height (blocks). Music track name. Tileset name. Modern display name. Incomplete-map marker. Resolved music. Resolved tileset. Resolved complete-map version. Number of associated events. Resolved fly destination. Number of hidden items here. Resolved script.
Definition at line 592 of file mapdbentry.cpp.
References modernName, and name.
|
protected |
Resolve the full cross-reference web.
Definition at line 216 of file mapdbentry.cpp.
References connect, MapDBEntryConnect::EAST, MapsDB::getInd(), MusicDB::getIndAt(), SpriteSetDB::getIndAt(), TilesetDB::getIndAt(), incomplete, MapsDB::inst(), MusicDB::inst(), SpriteSetDB::inst(), TilesetDB::inst(), monsBlue, monsRed, monsWater, music, name, MapDBEntryConnect::NORTH, MapDBEntryConnect::SOUTH, sprites, spriteSet, tileset, toComplete, toMusic, toSpriteSet, toTileset, warpOut, and MapDBEntryConnect::WEST.
| int MapDBEntry::getBank | ( | ) | const |
| int MapDBEntry::getBorder | ( | ) | const |
Definition at line 411 of file mapdbentry.cpp.
References border.
Referenced by AreaMap::randomize().
| const QHash< int, MapDBEntryConnect * > MapDBEntry::getConnect | ( | ) | const |
Edge connections by direction.
Definition at line 490 of file mapdbentry.cpp.
References connect.
Referenced by AreaMap::randomize().
| const MapDBEntryConnect * MapDBEntry::getConnectAt | ( | const int | val | ) | const |
Connection in direction val (for QML).
Definition at line 495 of file mapdbentry.cpp.
References connect.
| int MapDBEntry::getDataPtr | ( | ) | const |
Definition at line 401 of file mapdbentry.cpp.
References dataPtr.
Referenced by AreaMap::randomize().
| bool MapDBEntry::getGlitch | ( | ) | const |
| int MapDBEntry::getHeight | ( | ) | const |
Definition at line 381 of file mapdbentry.cpp.
References height.
Referenced by AreaMap::randomize().
| const QString MapDBEntry::getIncomplete | ( | ) | const |
Definition at line 361 of file mapdbentry.cpp.
References incomplete.
| int MapDBEntry::getInd | ( | ) | const |
Definition at line 582 of file mapdbentry.cpp.
References ind.
Referenced by WarpData::load(), MapConnData::loadFromData(), AreaMap::randomize(), and AreaGeneral::setTo().
| const QString MapDBEntry::getModernName | ( | ) | const |
Definition at line 366 of file mapdbentry.cpp.
References modernName.
| int MapDBEntry::getMonRate | ( | ) | const |
Definition at line 485 of file mapdbentry.cpp.
References monRate.
Referenced by AreaPokemon::setTo().
| int MapDBEntry::getMonRateWater | ( | ) | const |
Definition at line 480 of file mapdbentry.cpp.
References monRateWater.
Referenced by AreaPokemon::setTo().
| const QVector< MapDBEntryWildMon * > MapDBEntry::getMonsBlue | ( | ) | const |
Blue-version wild encounters.
Definition at line 444 of file mapdbentry.cpp.
References monsBlue.
Referenced by AreaPokemon::setTo().
| const MapDBEntryWildMon * MapDBEntry::getMonsBlueAt | ( | const int | ind | ) | const |
Blue wild ind (for QML).
Definition at line 454 of file mapdbentry.cpp.
| int MapDBEntry::getMonsBlueSize | ( | ) | const |
Definition at line 449 of file mapdbentry.cpp.
References monsBlue.
| const QVector< MapDBEntryWildMon * > MapDBEntry::getMonsRed | ( | ) | const |
Red-version wild encounters.
Definition at line 462 of file mapdbentry.cpp.
References monsRed.
Referenced by AreaPokemon::setTo().
| const MapDBEntryWildMon * MapDBEntry::getMonsRedAt | ( | const int | ind | ) | const |
| int MapDBEntry::getMonsRedSize | ( | ) | const |
| const QVector< MapDBEntryWildMon * > MapDBEntry::getMonsWater | ( | ) | const |
Water wild encounters.
Definition at line 426 of file mapdbentry.cpp.
References monsWater.
Referenced by AreaPokemon::setTo().
| const MapDBEntryWildMon * MapDBEntry::getMonsWaterAt | ( | const int | ind | ) | const |
Water wild ind (for QML).
Definition at line 436 of file mapdbentry.cpp.
| int MapDBEntry::getMonsWaterSize | ( | ) | const |
Definition at line 431 of file mapdbentry.cpp.
References monsWater.
| const QString MapDBEntry::getMusic | ( | ) | const |
| const QString MapDBEntry::getName | ( | ) | const |
| int MapDBEntry::getScriptPtr | ( | ) | const |
Definition at line 396 of file mapdbentry.cpp.
References scriptPtr.
Referenced by AreaMap::randomize().
| const QVector< MapDBEntrySign * > MapDBEntry::getSigns | ( | ) | const |
Signs on the map.
Definition at line 518 of file mapdbentry.cpp.
References signs.
Referenced by AreaSign::randomize(), and AreaSign::setTo().
| const MapDBEntrySign * MapDBEntry::getSignsAt | ( | const int | ind | ) | const |
| int MapDBEntry::getSignsSize | ( | ) | const |
| bool MapDBEntry::getSpecial | ( | ) | const |
| const QVector< MapDBEntrySprite * > MapDBEntry::getSprites | ( | ) | const |
Sprites on the map.
Definition at line 500 of file mapdbentry.cpp.
References sprites.
Referenced by AreaSprites::setTo().
| const MapDBEntrySprite * MapDBEntry::getSpritesAt | ( | const int | ind | ) | const |
| int MapDBEntry::getSpriteSet | ( | ) | const |
| int MapDBEntry::getSpritesSize | ( | ) | const |
| int MapDBEntry::getTextPtr | ( | ) | const |
Definition at line 391 of file mapdbentry.cpp.
References textPtr.
Referenced by AreaMap::randomize().
| const QString MapDBEntry::getTileset | ( | ) | const |
| MapDBEntry * MapDBEntry::getToComplete | ( | ) | const |
Definition at line 346 of file mapdbentry.cpp.
References MapDBEntry(), and toComplete.
| const QVector< EventDBEntry * > MapDBEntry::getToEvents | ( | ) | const |
Events associated with this map.
Definition at line 328 of file mapdbentry.cpp.
References toEvents.
| const EventDBEntry * MapDBEntry::getToEventsAt | ( | const int | ind | ) | const |
Associated event ind (for QML).
Definition at line 338 of file mapdbentry.cpp.
References EventDBEntry, ind, and toEvents.
| int MapDBEntry::getToEventsSize | ( | ) | const |
Definition at line 333 of file mapdbentry.cpp.
References toEvents.
| FlyDBEntry * MapDBEntry::getToFlyDestination | ( | ) | const |
Definition at line 323 of file mapdbentry.cpp.
References FlyDBEntry, and toFlyDestination.
| const QVector< HiddenItemDBEntry * > MapDBEntry::getToHiddenItems | ( | ) | const |
| const HiddenItemDBEntry * MapDBEntry::getToHiddenItemsAt | ( | const int | ind | ) | const |
Hidden item ind (for QML).
Definition at line 315 of file mapdbentry.cpp.
References HiddenItemDBEntry, ind, and toHiddenItems.
| int MapDBEntry::getToHiddenItemsSize | ( | ) | const |
Definition at line 310 of file mapdbentry.cpp.
References toHiddenItems.
| MusicDBEntry * MapDBEntry::getToMusic | ( | ) | const |
Definition at line 356 of file mapdbentry.cpp.
References toMusic.
Referenced by AreaAudio::setTo().
| ScriptDBEntry * MapDBEntry::getToScript | ( | ) | const |
Definition at line 295 of file mapdbentry.cpp.
References ScriptDBEntry, and toScript.
| SpriteSetDBEntry * MapDBEntry::getToSpriteSet | ( | ) | const |
Definition at line 416 of file mapdbentry.cpp.
References toSpriteSet.
Referenced by AreaLoadedSprites::randomize(), and AreaLoadedSprites::setTo().
| TilesetDBEntry * MapDBEntry::getToTileset | ( | ) | const |
Definition at line 351 of file mapdbentry.cpp.
References toTileset.
Referenced by AreaTileset::loadFromData().
| const QVector< MapDBEntryWarpIn * > MapDBEntry::getWarpIn | ( | ) | const |
| const MapDBEntryWarpIn * MapDBEntry::getWarpInAt | ( | const int | ind | ) | const |
Incoming warp ind (for QML).
Definition at line 546 of file mapdbentry.cpp.
| int MapDBEntry::getWarpInSize | ( | ) | const |
| const QVector< MapDBEntryWarpOut * > MapDBEntry::getWarpOut | ( | ) | const |
Outgoing warps.
Definition at line 554 of file mapdbentry.cpp.
References warpOut.
Referenced by AreaWarps::randomize(), and AreaWarps::setTo().
| const MapDBEntryWarpOut * MapDBEntry::getWarpOutAt | ( | const int | ind | ) | const |
Outgoing warp ind (for QML).
Definition at line 564 of file mapdbentry.cpp.
| int MapDBEntry::getWarpOutSize | ( | ) | const |
| int MapDBEntry::getWidth | ( | ) | const |
Definition at line 386 of file mapdbentry.cpp.
References width.
Referenced by MapConnData::loadFromData(), and AreaMap::randomize().
| int MapDBEntry::height2X2 | ( | ) | const |
Height x2 (derived; see note).
Definition at line 600 of file mapdbentry.cpp.
References height.
Referenced by AreaMap::randomize().
| void MapDBEntry::qmlProtect | ( | const QQmlEngine *const | engine | ) | const |
Pin to C++ ownership.
Definition at line 300 of file mapdbentry.cpp.
References Utility::qmlProtectUtil().
|
protected |
| int MapDBEntry::width2X2 | ( | ) | const |
Width x2 (derived; see note).
Definition at line 608 of file mapdbentry.cpp.
References width.
Referenced by AreaMap::randomize().
|
friend |
Definition at line 246 of file mapdbentry.h.
References EventDBEntry.
Referenced by EventDBEntry, and getToEventsAt().
|
friend |
Definition at line 247 of file mapdbentry.h.
References FlyDBEntry.
Referenced by FlyDBEntry, and getToFlyDestination().
|
friend |
Definition at line 248 of file mapdbentry.h.
References HiddenItemDBEntry.
Referenced by getToHiddenItemsAt(), and HiddenItemDBEntry.
|
friend |
|
friend |
|
friend |
Definition at line 249 of file mapdbentry.h.
References ScriptDBEntry.
Referenced by getToScript(), and ScriptDBEntry.
|
protected |
Map data bank.
Definition at line 223 of file mapdbentry.h.
Referenced by getBank(), and MapDBEntry().
|
protected |
Border block number.
Definition at line 221 of file mapdbentry.h.
Referenced by getBorder(), and MapDBEntry().
|
protected |
Edge connections by direction.
Definition at line 203 of file mapdbentry.h.
Referenced by deepLink(), getConnect(), getConnectAt(), and MapDBEntry().
|
protected |
Map data pointer.
Definition at line 224 of file mapdbentry.h.
Referenced by getDataPtr(), and MapDBEntry().
|
protected |
Backing field (read via getGlitch()).
Definition at line 187 of file mapdbentry.h.
Referenced by getGlitch(), and MapDBEntry().
|
protected |
Height (blocks).
Definition at line 228 of file mapdbentry.h.
Referenced by getHeight(), height2X2(), and MapDBEntry().
|
protected |
Incomplete-map marker.
Definition at line 233 of file mapdbentry.h.
Referenced by deepLink(), getIncomplete(), and MapDBEntry().
|
protected |
Backing field (read via getInd()).
Definition at line 185 of file mapdbentry.h.
Referenced by getInd(), getMonsBlueAt(), getMonsRedAt(), getMonsWaterAt(), getSignsAt(), getSpritesAt(), getToEventsAt(), getToHiddenItemsAt(), getWarpInAt(), getWarpOutAt(), and MapDBEntry().
|
protected |
Modern display name.
Definition at line 232 of file mapdbentry.h.
Referenced by bestName(), getModernName(), and MapDBEntry().
|
protected |
Land encounter rate.
Definition at line 210 of file mapdbentry.h.
Referenced by getMonRate(), and MapDBEntry().
|
protected |
Water encounter rate.
Definition at line 211 of file mapdbentry.h.
Referenced by getMonRateWater(), and MapDBEntry().
|
protected |
Blue-version land encounters.
Definition at line 213 of file mapdbentry.h.
Referenced by deepLink(), getMonsBlue(), getMonsBlueAt(), getMonsBlueSize(), and MapDBEntry().
|
protected |
Red-version land encounters.
Definition at line 212 of file mapdbentry.h.
Referenced by deepLink(), getMonsRed(), getMonsRedAt(), getMonsRedSize(), and MapDBEntry().
|
protected |
Water encounters (shared; see note).
Definition at line 214 of file mapdbentry.h.
Referenced by deepLink(), getMonsWater(), getMonsWaterAt(), getMonsWaterSize(), and MapDBEntry().
|
protected |
Music name.
Definition at line 230 of file mapdbentry.h.
Referenced by deepLink(), getMusic(), and MapDBEntry().
|
protected |
Backing field (read via getName()).
Definition at line 184 of file mapdbentry.h.
Referenced by bestName(), deepLink(), getName(), and MapDBEntry().
|
protected |
Map script pointer.
Definition at line 225 of file mapdbentry.h.
Referenced by getScriptPtr(), and MapDBEntry().
|
protected |
Signs.
Definition at line 197 of file mapdbentry.h.
Referenced by getSigns(), getSignsAt(), getSignsSize(), and MapDBEntry().
|
protected |
Backing field (read via getSpecial()).
Definition at line 188 of file mapdbentry.h.
Referenced by getSpecial(), and MapDBEntry().
|
protected |
Sprites.
Definition at line 200 of file mapdbentry.h.
Referenced by deepLink(), getSprites(), getSpritesAt(), getSpritesSize(), and MapDBEntry().
|
protected |
Sprite-set index.
Definition at line 217 of file mapdbentry.h.
Referenced by deepLink(), getSpriteSet(), and MapDBEntry().
|
protected |
Map text pointer.
Definition at line 226 of file mapdbentry.h.
Referenced by getTextPtr(), and MapDBEntry().
|
protected |
Tileset name.
Definition at line 231 of file mapdbentry.h.
Referenced by deepLink(), getTileset(), and MapDBEntry().
|
protected |
Definition at line 238 of file mapdbentry.h.
Referenced by deepLink(), and getToComplete().
|
protected |
Definition at line 239 of file mapdbentry.h.
Referenced by getToEvents(), getToEventsAt(), and getToEventsSize().
|
protected |
Definition at line 240 of file mapdbentry.h.
Referenced by getToFlyDestination().
|
protected |
Definition at line 241 of file mapdbentry.h.
Referenced by getToHiddenItems(), getToHiddenItemsAt(), and getToHiddenItemsSize().
|
protected |
Definition at line 236 of file mapdbentry.h.
Referenced by deepLink(), and getToMusic().
|
protected |
Resolved script (deepLink).
Definition at line 242 of file mapdbentry.h.
Referenced by getToScript().
|
protected |
Resolved sprite set (deepLink).
Definition at line 218 of file mapdbentry.h.
Referenced by deepLink(), and getToSpriteSet().
|
protected |
Definition at line 237 of file mapdbentry.h.
Referenced by deepLink(), and getToTileset().
|
protected |
Incoming warps.
Definition at line 194 of file mapdbentry.h.
Referenced by getWarpIn(), getWarpInAt(), getWarpInSize(), and MapDBEntry().
|
protected |
Outgoing warps.
Definition at line 191 of file mapdbentry.h.
Referenced by deepLink(), getWarpOut(), getWarpOutAt(), getWarpOutSize(), and MapDBEntry().
|
protected |
Width (blocks).
Definition at line 227 of file mapdbentry.h.
Referenced by getWidth(), MapDBEntry(), and width2X2().