xoreos
0.0.5
|
#include <container.h>
Public Member Functions | |
ScriptContainer () | |
~ScriptContainer () | |
const Common::UString & | getScript (Script script) const |
bool | hasScript (Script script) const |
bool | runScript (Script script, const Aurora::NWScript::ObjectReference owner=Aurora::NWScript::ObjectReference(), const Aurora::NWScript::ObjectReference triggerer=Aurora::NWScript::ObjectReference()) |
Static Public Member Functions | |
static bool | runScript (const Common::UString &script, const Aurora::NWScript::ObjectReference owner=Aurora::NWScript::ObjectReference(), const Aurora::NWScript::ObjectReference triggerer=Aurora::NWScript::ObjectReference()) |
static bool | runScript (const Common::UString &script, const Aurora::NWScript::ScriptState &state, const Aurora::NWScript::ObjectReference owner=Aurora::NWScript::ObjectReference(), const Aurora::NWScript::ObjectReference triggerer=Aurora::NWScript::ObjectReference()) |
Protected Member Functions | |
void | clearScripts () |
void | readScripts (const Aurora::GFF3Struct &gff, bool clear=true) |
void | readScripts (const ScriptContainer &container) |
Private Attributes | |
Common::UString | _scripts [kScriptMAX] |
Definition at line 47 of file container.h.
Engines::KotOR::ScriptContainer::ScriptContainer | ( | ) |
Definition at line 113 of file container.cpp.
Engines::KotOR::ScriptContainer::~ScriptContainer | ( | ) |
Definition at line 116 of file container.cpp.
|
protected |
Definition at line 129 of file container.cpp.
References _scripts, and Engines::KotOR::kScriptMAX.
Referenced by readScripts().
const Common::UString & Engines::KotOR::ScriptContainer::getScript | ( | Script | script | ) | const |
Definition at line 119 of file container.cpp.
References _scripts, and Engines::KotOR::kScriptMAX.
Referenced by hasScript(), and runScript().
bool Engines::KotOR::ScriptContainer::hasScript | ( | Script | script | ) | const |
Definition at line 125 of file container.cpp.
References Common::UString::empty(), and getScript().
Referenced by Engines::KotOR::Door::click(), and Engines::KotOR::Creature::click().
|
protected |
Definition at line 134 of file container.cpp.
References _scripts, ARRAYSIZE, clearScripts(), Common::UString::empty(), Aurora::GFF3Struct::getString(), Engines::KotOR::kScriptNames, Engines::KotOR::ScriptName::name, and Engines::KotOR::ScriptName::script.
Referenced by Engines::KotOR::Placeable::load(), Engines::KotOR::Area::loadARE(), Engines::KotOR::Trigger::loadBlueprint(), Engines::KotOR::Module::loadIFO(), Engines::KotOR::Waypoint::loadProperties(), Engines::KotOR::Situated::loadProperties(), and Engines::KotOR::Creature::loadProperties().
|
protected |
Definition at line 153 of file container.cpp.
References _scripts, and Engines::KotOR::kScriptMAX.
bool Engines::KotOR::ScriptContainer::runScript | ( | Script | script, |
const Aurora::NWScript::ObjectReference | owner = Aurora::NWScript::ObjectReference() , |
||
const Aurora::NWScript::ObjectReference | triggerer = Aurora::NWScript::ObjectReference() |
||
) |
Definition at line 158 of file container.cpp.
References getScript().
Referenced by Engines::KotOR::Placeable::activate(), Engines::KotOR::Door::click(), Engines::KotOR::Creature::click(), Engines::KotOR::Module::clickObject(), Engines::KotOR::Door::close(), Engines::KotOR::Placeable::close(), Engines::KotOR::Placeable::deactivate(), Engines::KotOR::Module::enterArea(), Engines::KotOR::Area::evaluateTriggers(), Engines::KotOR::Module::handleActions(), Engines::KotOR::Module::leaveArea(), Engines::KotOR::Door::open(), Engines::KotOR::Placeable::open(), runScript(), and Engines::KotOR::Functions::showPartySelectionGUI().
|
static |
Definition at line 164 of file container.cpp.
References Aurora::NWScript::NCSFile::getEmptyState(), and runScript().
|
static |
Definition at line 171 of file container.cpp.
References Common::UString::c_str(), Common::UString::empty(), Common::exceptionDispatcherWarning(), Aurora::NWScript::Variable::getFloat(), Aurora::NWScript::Variable::getInt(), Aurora::NWScript::Variable::getType(), Aurora::NWScript::kTypeFloat, Aurora::NWScript::kTypeInt, and Aurora::NWScript::NCSFile::run().
|
private |
Definition at line 75 of file container.h.
Referenced by clearScripts(), getScript(), and readScripts().