Base script for the various tests in the training mission. A locked object is inactive. When a test is successfully completed, the next test object will be unlocked. The next test to be executed is linked from this object using ScriptParams with the data set to Preceeds. Voice-overs are played by sending the message VoiceOver to the object named VOManager. The first data parameter of the message is the description of the schema to play. When a key mapping is displayed, the command to describe is read from the file PlayCmd.str and the description is read from PlayAct.str.
Plays schemas as directed by training tests. Listens for the message VoiceOver with the first data parameter set to the description of a schema. If a schema is currently playing, new ones will be queued and played back sequentially. An introduction schema will cause the queue to be cleared. The message Flush will also clear the queue. The mappings from description to schema name are: STALL/ke1tr001, BAD/ke1tr002, INTRO-GREET/ke1tr003, INTRO-GENERAL/ke1tr004, SIGHT-GENERAL/ke1tr005, SIGHT-RETRY/ke1tr006, FROBBING-GENERAL/ke1tr007, FROBBING-SUCCESS/ke1tr008, FROBBING-EXIT-GENERAL/ke1tr009, SOUND-INTRO/ke1tr010, SOUND-GENERAL/ke1tr011, SOUND-RETRY/ke1tr012, SOUND-EXIT-GENERAL/ke1tr013, WEAPONS-GENERAL/ke1tr014, WEAPONS-READYWEAPON/ke1tr015, WEAPONS-EXIT-GENERAL/ke1tr016, BOW-GENERAL/ke1tr017, BOW-SUCCESS/ke1tr018, BOW-EXIT-GENERAL/ke1tr019, SWORD-GENERAL/ke1tr020, SWORD-SUCCESS/ke1tr021, REALSWORD-BAD/ke1tr022, REALSWORD-SUCCESS/ke1tr023, REALSWORD-END/ke1tr024, INVENTORY-INTRO/ke1tr025, INVENTORY-GET-GENERAL/ke1tr026, INVENTORY-USE-GENERAL/ke1tr027, INVENTORY-KEY/ke1tr028, INVENTORY-KEY-GENERAL/ke1tr029, INVENTORY-KEY-SUCECSS/ke1tr030, EXIT-INVENTORY-GENERAL/ke1tr031, ROPE-INTRO/ke1tr032, ROPE-START-GENERAL/ke1tr033, ROPE-CLIMB-GENERAL/ke1tr034, ROPE-SUCCESS/ke1tr035, JUMPING-GENERAL/ke1tr036, JUMPING-FAILURE/ke1tr037, JUMPING-SUCCESS/ke1tr038, MANTELLING-INTRO/ke1tr039, MANTELLING-GENERAL/ke1tr040, MANTELLING-SUCCESS/ke1tr041, FINAL-SUCCESS/ke1tr042, BOW-EXTRAGOOD/ke1tr043.
Begins at Sim start. The voice-overs INTRO-GREET and INTRO-GENERAL are played. After 12 seconds, TurnOn is sent to the object named IntroDoor.
Begins when the object named SightEntranceway sends PlayerRoomEnter. The voice-over SIGHT-GENERAL is played and TurnOff is sent to the objects named IntroLight1 and IntroLight2. Does other stuff.
Oh, hell... This is more tedious than room brushing. If you want to use these scripts, you may as well just open up the mission in Dromed and copy what you see there.
On PlayerRoomEnter, displays the key bindings for displaying the automap.
Responds to the message TakeOff by instructing the AI to go to the object specified (by id number) in the first data parameter.
On PlayerRoomEnter, the script reads the first ControlDevice link from the object. The destination of the link has the Engine Features\Locked property turned on, the RegionMask field of Engine Features\KeyDst set to 0, and the message TurnOff is sent to it.
Plays the schema gartr001 in response to PlayerRoomEnter. On SchemaDone, the first objective is completed.
Responds to the message Reset by clearing the alertness state of the AI.
Sends messages to an object that is linked to using ScriptParams and has the data set to Coordinator. On FrobWorldEnd, the message ScrFrobWorldEnd is sent. WorldSelect will send the message ScrWorldSelect.
Relays the message Alertness along a ScriptParams link that has the data set to Coordinator.
Relays PlayerRoomEnter and PlayerRoomExit to a coordinator.
On DoorOpening, sends Flush to the object named VOManager and sends DoorOpen to a coordinator.
Relays PhysContactCreate to a coordinator, and sends PokeStim in response to PokeStimStimulus.
On Damage, the message ScrDamage is sent to the object named PartnerSwordTest. If the damage type is SlashStim, then the hit counter is incremented. The object is then damaged using a RestoreStim with the opposite intensity of the original damage. Resurrects the object if it is Slain. The script will reply to HitsTaken? with the value of the hit counter.
Inherits from Legible. Displays the book text in response to WorldSelect, then sets a flag so it won't be shown again. On Slain, sets the quest variable GOAL_STATE_1 to "failed".
A derivative of StdGauge. The gauge has three stages: rising, overflow, and falling. When rising, the first joint settings are "(1.7, 0, 100)". The overflow settings are "(0.3, 96, 120)". Falling is "(30, 0, 120)". When switching from rising to overflow stage, the message Full is sent to ScriptParams links with the data set to Mold. When the tweq reaches the on position, TurnOn is sent along ControlDevice links. The script will halt the joint tweq when it receives a Halt message.
The base script for old-style conversations.
A generic speaker for old-style conversations. The conversation is stopped on Damage, Slain, or Alertness with a moderate or high alert. This script halts the schemas on the object when it receives ConvInterrupt.
Mission-specific conversation controller. Along with the normal conversation steps, reveals objective number 4, and slays the conversation actor.
Mission-specific conversation controller for "Cutty". On Slain, will reveal objectives 2, 8, and 10 if objective 4 has been revealed. Otherwise, failes objectives 1, 7, and 9. Sends Ow to the host conversation on Damage.
Mission-specific conversation controller for the player. On Sim start, creates an OldConversation link to itself from the object named CuttyConv. Sends TurnOff to the conversation on Slain, and sends Ow on Damage.
On PlayerRoomEnter, sends Presence along its ControlDevice links. Sends Absence on PlayerRoomExit.
Responds to CreatureRoomEnter and CreatureRoomExit. Only activates if the creature is a type of Hammerite. Sends Instrusion and Privacy along ControlDevice links.
Responds to ConvOver. Turns on AI\Ability Settings\Patrol: Does patrol.
Sets a Timer with the name of any message it receives. Whenever a timer expires, a message with the name of the Timer is sent along ControlDevice links. The delay, in seconds, is specified in the data of a ScriptParams link from the object to itself.
Not all messages will be relayed. The most common messages will be ignored. TurnOn and TurnOff will be handled. Obviously, it doesn't delay Timer messages.
When attacked (messages Damage, Slain, or KnockoutStimulus) by Player, removes the meta-property M-Swaying Burrick from all creatures.
On Contained, removes the meta-property M-Swaying Burrick from all creatures, and removes the AmbientHacked property from itself.
When Slain, sends the message BoneSlain to the objects that have an Owns link to this one. On PhysCollision, will slay itself if there is an Owns from the colliding object to this object.
Listens for the message BoneSlain. When there are no Owns links from this object it will send TurnOn to all ControlDevice linked objects.
On TurnOn, sends the message WakeyWakey along ControlDevice links.
Listens for the message WakeyWakey. Will set AI\State\Current mode to Normal.
Sends TurnOn and TurnOff in response to DoorOpen and DoorClose, respectively.
When Slain, turns off the Renderer\Anim Light, sends TurnOff to the object named ConsSword, disables the location and rotation controls of Physics\Model\Controls, then teleports ConsSword to the location of the object named ConsSwordTeleportLoc.
I bet you've just been dying to use this script in your own mission now, haven't you?
On Contained, removes the object named OrigSword from whatever container it happens to be in.
The script doesn't bother to make the sword invisible.
Plays the ambient schema eye01 in response to SeePlayer. Changes some quest variables when the schema finishes.
Marks objective 0 as "complete" on PlayerRoomEnter.
Responds to NowUnlocked. A model tweq on the object is activated, the schema coindrop is played, and objective 7 is marked as "complete".
Attempts to unlock another object using this one on FrobToolEnd. If successful, the script object is destroyed.
On FrobWorldEnd, sends the message ScrFrobWorldEnd to the object named Player.
Toggles the Renderer\Render Type property. TurnOn sets it to Unlit. TurnOff sets it to Normal.
Sets a Timer named MaskCheck on Sim start. The timer will expire after the loadout screen is exited. The script checks if an object named MaskTip is contained by ItemStore. If it is, the meta-property M-MaskLoot is added to this object.
Destroys the key when it successfully unlocks an object.
Activates a model tweq when the object is unlocked.
Sends TurnOn along ControlDevice links when the object is Contained.
Most scripts, when they send TurnOn or TurnOff, the message will have "0" in the first data parameter. This one doesn't. Not that it matters.
Acts as a require-all relay that is controlled by levers. When all the levers that are linked to the object with ControlDevice are turned on, a TurnOn message is sent to all ScriptParams linked objects. The data of the first ScriptParams link is the length of a Timer, in seconds (as a floating-point number), after the first lever is turned on that all the levers will revert to the off position. The levers are reset by sending the message GoBackward to all objects that link to this one with ControlDevice. The ambient schema switch_succ is played when all the levers are turned on, and switch_fail when they are reset.
A room script. On PlayerRoomEnter, looks for a ControlDevice link to this object. If the source of the link is in the player's inventory, then TurnOn is sent along ControlDevice links from this object.
A room script. When the script receives TurnOn while the player is in the room, then TurnOn will be sent along ControlDevice links.
Sends TurnOn along ControlDevice links in response to FrobInvEnd.
Listens for TurnOn. Will remove the meta-property FrobInert from the object, and sends the message Sepukku to all objects that link to this one with ParticleAttachement.
Activates an emitter tweq on FrobWorldEnd. Will destroy itself when it receives the message Sepukku.
On FrobInvEnd, if the object is in a room that it has a Route link to, then TurnOn is sent along ControlDevice links. The script will only activate once.
Identical to MagicScroll.
Identical to MagicScroll.
A variation of GoMissing. Along with the MissingLoot object, a Marker with the meta-property M-RedHandedObj is created at the location of the object and AIWatchObj links are added from every Human to it. A flicker tweq is activated on the marker.
Listens for the message HoldIt and responds with non-zero until a flicker tweq has completed. The object will be destroyed 15 seconds after the tweq completes.
A variation of TemporaryWatch. The script will respond to HoldIt with zero initially. On FrobWorldEnd, the meta-property M-PinkHandedObj is added to the object and AIWatchObj links are created to the object from all Human type objects. The flicker tweq on the object will be reset and activated. When the tweq completes and the object has not been frobbed again for 15 seconds, then all AIWatchObj links to the object are destroyed and the meta-property M-PinkHandedObj is removed.
Closes a door 7.5 seconds after it is opened or halted. Will delay the timer if there is an AIDoor link to the object.
Derives from StdKey. When the key is successfully used on a lock it is destroyed.
On NowUnlocked, the model tweq of the object is activated. The first time any object with this script is unlocked, the ambient schema eye02 is played.
On PlayerRoomEnter, if goal_state_0 is 0 then the ambient schema eye06 is played. Only triggers once.
On AIAlertness to level 3, sends the message EarlySpring to the object named Eye.
Listens for the message Preparation. Will teleport the object to the destination of the first ControlDevice link.
On Slain, sends the message DeadHaunt to the object named Brother Murus.
On PhysCollision sends TurnOn to itself.
On FrobWorldEnd, sets the quest variable goal_state_1 to complete.
Sets the Gold field of Dark Gamesys\Loot to the value of the quest variable total_loot, and the Gems and Art to 0. If the total loot is 0, the object is destroyed. Activates on Difficulty.
When the object receives Damage from Player, or is stimulated with KOGas, and the Difficulty is at least 2, then the voice-over schema garm1408 is played and objective 7 is revealed. When the object is Slain, instances of the BugBeast object are tallied, and if they all have a non-zero Game\Damage Model\Death Stage property, then objective 7 is marked as complete.
On TurnOn, sets Renderer\Render Type to Normal, AI\AI Core\Team to Bad 1, AI\Attributes\Vision and AI\Attributes\Hearing to Average. Then sets a Timer named Sepukku for 45 seconds. When the timer expires, or when it receives TurnOff, the object slays itself.
Responds to the message AlertPseudo. If there is an AIAwareness link to Player with a high awareness level, and there are no AIAttack links to the object named HostagePriest, then it replies with "1". Otherwise, it replies with "0".