diff options
Diffstat (limited to 'engines/xeen/scripts.h')
-rw-r--r-- | engines/xeen/scripts.h | 95 |
1 files changed, 95 insertions, 0 deletions
diff --git a/engines/xeen/scripts.h b/engines/xeen/scripts.h index 15550dd9c0..f41be1b7c6 100644 --- a/engines/xeen/scripts.h +++ b/engines/xeen/scripts.h @@ -155,30 +155,99 @@ private: Common::String _message; Common::String _displayMessage; + /** + * Handles executing a given script command + */ void doOpcode(MazeEvent &event); + + /** + * Display a msesage on-screen + */ void cmdDisplay1(Common::Array<byte> ¶ms); + + /** + * Displays a door text message using the small font + */ void cmdDoorTextSml(Common::Array<byte> ¶ms); + + /** + * Displays a door text message using the large font + */ void cmdDoorTextLrg(Common::Array<byte> ¶ms); + + /** + * Show a sign text on-screen + */ void cmdSignText(Common::Array<byte> ¶ms); void cmdNPC(Common::Array<byte> ¶ms); + + /** + * Play a sound FX + */ void cmdPlayFX(Common::Array<byte> ¶ms); void cmdTeleport(Common::Array<byte> ¶ms); + + /** + * Do a conditional check + */ void cmdIf(Common::Array<byte> ¶ms); + + /** + * Moves the position of an object + */ void cmdMoveObj(Common::Array<byte> ¶ms); void cmdTakeOrGive(Common::Array<byte> ¶ms); + + /** + * Move to the next line of the script + */ void cmdNoAction(Common::Array<byte> ¶ms); void cmdRemove(Common::Array<byte> ¶ms); + + /** + * Set the currently active character for other script operations + */ void cmdSetChar(Common::Array<byte> ¶ms); + + /** + * Spawn a monster + */ void cmdSpawn(Common::Array<byte> ¶ms); void cmdDoTownEvent(Common::Array<byte> ¶ms); + + /** + * Stop executing the script + */ void cmdExit(Common::Array<byte> ¶ms); + + /** + * Changes the value for the wall on a given cell + */ void cmdAlterMap(Common::Array<byte> ¶ms); void cmdGiveExtended(Common::Array<byte> ¶ms); void cmdConfirmWord(Common::Array<byte> ¶ms); void cmdDamage(Common::Array<byte> ¶ms); + + /** + * Jump if a random number matches a given value + */ void cmdJumpRnd(Common::Array<byte> ¶ms); + + /** + * Alter an existing event + */ void cmdAlterEvent(Common::Array<byte> ¶ms); + + /** + * Stores the current location and line for later resuming, and set up to execute + * a script at a given location + */ void cmdCallEvent(Common::Array<byte> ¶ms); + + /** + * Return from executing a script to the script location that previously + * called the script + */ void cmdReturn(Common::Array<byte> ¶ms); void cmdSetVar(Common::Array<byte> ¶ms); void cmdCutsceneEndClouds(Common::Array<byte> ¶ms); @@ -195,15 +264,38 @@ private: void cmdSelRndChar(Common::Array<byte> ¶ms); void cmdGiveEnchanted(Common::Array<byte> ¶ms); void cmdItemType(Common::Array<byte> ¶ms); + + /** + * Disable all the scripts at the party's current position + */ void cmdMakeNothingHere(Common::Array<byte> ¶ms); void cmdCheckProtection(Common::Array<byte> ¶ms); + + /** + * Given a number of options, and a list of line numbers associated with + * those options, jumps to whichever line for the option the user selects + */ void cmdChooseNumeric(Common::Array<byte> ¶ms); void cmdDisplayBottomTwoLines(Common::Array<byte> ¶ms); void cmdDisplayLarge(Common::Array<byte> ¶ms); + + /** + * Exchange the positions of two objects in the maze + */ void cmdExchObj(Common::Array<byte> ¶ms); void cmdFallToMap(Common::Array<byte> ¶ms); void cmdDisplayMain(Common::Array<byte> ¶ms); + + /** + * Jumps to a given line number if the surface at relative cell position 1 matches + * a specified surface. + * @remarks This opcode is apparently never actually used + */ void cmdGoto(Common::Array<byte> ¶ms); + + /** + * Pick a random value from the parameter list and jump to that line number + */ void cmdGotoRandom(Common::Array<byte> ¶ms); void cmdCutsceneEndDarkside(Common::Array<byte> ¶ms); void cmdCutsceneEdWorld(Common::Array<byte> ¶ms); @@ -220,6 +312,9 @@ private: void doEnding(const Common::String &endStr, int v2); + /** + * This monstrosity handles doing the various types of If checks on various data + */ bool ifProc(int action, uint32 mask, int mode, int charIndex); bool copyProtectionCheck(); |