|
Pokered Save Editor 2
Pokemon Red & Blue save file editor - Qt 6 C++/QML
|
The map-scripts database, keyed by name. More...
#include <scripts.h>
Public Member Functions | |
| const QVector< ScriptDBEntry * > | getStore () const |
| All scripts. | |
| const QHash< QString, ScriptDBEntry * > | getInd () const |
| Name->entry index. | |
| int | getStoreSize () const |
| Script count. | |
| ScriptDBEntry * | getStoreAt (int idx) const |
| Script by store index (for QML). | |
| ScriptDBEntry * | getIndAt (const QString &key) const |
| Script by name key (for QML). | |
| void | load () |
| Load scripts from JSON. | |
| void | index () |
| Build the name->entry index. | |
| void | deepLink () |
| Resolve each script's map links. | |
| void | qmlProtect (const QQmlEngine *const engine) const |
| Pin to C++ ownership. | |
Static Public Member Functions | |
| static ScriptsDB * | inst () |
| < Number of scripts. | |
The map-scripts database, keyed by name.
Standard DB-singleton with a name index and a deepLink() pass. See db.md.
| void ScriptsDB::deepLink | ( | ) |
Resolve each script's map links.
Definition at line 109 of file scripts.cpp.
|
nodiscard |
Name->entry index.
Definition at line 74 of file scripts.cpp.
| ScriptDBEntry * ScriptsDB::getIndAt | ( | const QString & | key | ) | const |
Script by name key (for QML).
Definition at line 83 of file scripts.cpp.
|
nodiscard |
All scripts.
Definition at line 73 of file scripts.cpp.
| ScriptDBEntry * ScriptsDB::getStoreAt | ( | int | idx | ) | const |
Script by store index (for QML).
Definition at line 77 of file scripts.cpp.
|
nodiscard |
Script count.
Definition at line 75 of file scripts.cpp.
| void ScriptsDB::index | ( | ) |
Build the name->entry index.
Definition at line 98 of file scripts.cpp.
|
static |
< Number of scripts.
The process-wide ScriptsDB singleton.
Definition at line 67 of file scripts.cpp.
Referenced by WorldScripts::load(), DB::qmlProtect(), WorldScripts::save(), and DB::scripts().
| void ScriptsDB::load | ( | ) |
Load scripts from JSON.
Definition at line 88 of file scripts.cpp.
References GameData::inst(), and GameData::json().
| void ScriptsDB::qmlProtect | ( | const QQmlEngine *const | engine | ) | const |
Pin to C++ ownership.
Definition at line 118 of file scripts.cpp.
References Utility::qmlProtectUtil().
Referenced by DB::qmlProtect().