OpenMW
|
#include <globalscripts.hpp>
Public Member Functions | |
GlobalScripts (const MWWorld::ESMStore &store) | |
void | addScript (const std::string &name, const std::string &targetId="") |
void | removeScript (const std::string &name) |
bool | isRunning (const std::string &name) const |
void | run () |
run all active global scripts More... | |
void | clear () |
void | addStartup () |
Add startup script. More... | |
int | countSavedGameRecords () const |
void | write (ESM::ESMWriter &writer, Loading::Listener &progress) const |
bool | readRecord (ESM::ESMReader &reader, uint32_t type) |
Locals & | getLocals (const std::string &name) |
Private Attributes | |
const MWWorld::ESMStore & | mStore |
std::map< std::string, GlobalScriptDesc > | mScripts |
MWScript::GlobalScripts::GlobalScripts | ( | const MWWorld::ESMStore & | store | ) |
void MWScript::GlobalScripts::addScript | ( | const std::string & | name, |
const std::string & | targetId = "" |
||
) |
void MWScript::GlobalScripts::addStartup | ( | ) |
Add startup script.
void MWScript::GlobalScripts::clear | ( | ) |
int MWScript::GlobalScripts::countSavedGameRecords | ( | ) | const |
Locals & MWScript::GlobalScripts::getLocals | ( | const std::string & | name | ) |
If the script name has not been added as a global script yet, it is added automatically, but is not set to running state.
bool MWScript::GlobalScripts::isRunning | ( | const std::string & | name | ) | const |
bool MWScript::GlobalScripts::readRecord | ( | ESM::ESMReader & | reader, |
uint32_t | type | ||
) |
Records for variables that do not exist are dropped silently.
void MWScript::GlobalScripts::removeScript | ( | const std::string & | name | ) |
void MWScript::GlobalScripts::run | ( | ) |
run all active global scripts
void MWScript::GlobalScripts::write | ( | ESM::ESMWriter & | writer, |
Loading::Listener & | progress | ||
) | const |
|
private |
|
private |