#include <riven_scripts.h>
Public Member Functions | |
void | addCommand (RivenCommandPtr command) |
bool | empty () const |
void | run (RivenScriptManager *scriptManager) |
void | dumpScript (byte tabs) |
void | applyCardPatches (MohawkEngine_Riven *vm, uint32 cardGlobalId, uint16 scriptType, uint16 hotspotId) |
RivenScript & | operator+= (const RivenScript &other) |
Static Public Member Functions | |
static const char * | getTypeName (uint16 type) |
Scripts in Riven are a list of Commands
This class should only be used through the RivenScriptPtr type to ensure the underlying memory is not freed when changing card.
void Mohawk::RivenScript::addCommand | ( | RivenCommandPtr | command | ) |
Append a command to the script
bool Mohawk::RivenScript::empty | ( | ) | const |
True if the script does not contain any command
void Mohawk::RivenScript::run | ( | RivenScriptManager * | scriptManager | ) |
Run the script
Script execution must go through the ScriptManager, this method should not be called directly.
void Mohawk::RivenScript::dumpScript | ( | byte | tabs | ) |
Print script details to the standard output
void Mohawk::RivenScript::applyCardPatches | ( | MohawkEngine_Riven * | vm, |
uint32 | cardGlobalId, | ||
uint16 | scriptType, | ||
uint16 | hotspotId | ||
) |
Apply patches to card script to fix bugs in the original game scripts
RivenScript& Mohawk::RivenScript::operator+= | ( | const RivenScript & | other | ) |
Append the commands of the other script to this script
|
static |
Get a caption for a script type