src/scene/vault.c
Vault (SceneIdVault), "the town at the heart of Angara", as the party first finds it after Mt. More…
#include "scene/vault.h"#include "ability_ids.h"#include "flags.h"#include "item_ids.h"#include "battle/battle.h"#include "debug/debug.h"#include "graphics/graphics.h"#include "scene/vault_range.h"#include "scene/walk_into_leader.h"#include "text/msg_ids.h"#include "shared/field_effect_create.c"#include "shared/field_effect_spawn.c"#include "shared/vault_nearby.c"#include "shared/vault_djinn.c"#include "shared/vault_talk.c"#include "shared/vault_toggle.c"#include "shared/vault_door_exit.c"#include "shared/vault_doors.c"#include "shared/vault_map_metatiles.c"#include "shared/vault_jail_door.c"#include "shared/position_distance.c"#include "shared/vault_range.c"#include "shared/field_effect_duration_scripts.c"#include "shared/vault_well_routes.c"#include "shared/vault_door_metatiles.c"
Macros
| Name | Description | |
|---|---|---|
#define | VAULT_GEM_OWNERS_HOUSE_EXIT VAULT_LOG_ROOMS_A_EAST_SOUTHEAST | The rooms behind the town's doors (shared/vault_doors.c). |
#define | VAULT_CHILDS_HOUSE_EXIT VAULT_LOG_ROOMS_A_SOUTHEAST | |
#define | VAULT_INN_EXIT VAULT_LOG_ROOMS_A_SOUTHWEST | |
#define | VAULT_ITEM_SHOP_EXIT VAULT_LOG_ROOMS_A_EAST | |
#define | VAULT_WEAPON_AND_ARMOR_SHOP_EXIT VAULT_LOG_ROOMS_A_NORTH_NORTHEAST | |
#define | VAULT_MAYORS_HOUSE_EXIT VAULT_LOG_ROOMS_A_NORTHWEST | |
#define | VAULT_JAIL_EXIT VAULT_STONE_ROOMS | |
#define | DRIFT_DAMPING 28 | A drifting sprite loses this share of each rate a tick: a 28th. |
Enumerations
| Name | Description | |
|---|---|---|
enum | anonymous enum { VAULT_DRIFT_RATE } | The unit of the unused drift's random speeds: a tenth of a pixel a tick. |
enum | anonymous enum { ACTOR_WELCOMING_YOUNG_MAN, ACTOR_ERUPTION_WITNESS, ACTOR_VIL … } | The townspeople, named by what they say. |
Functions
| Name | Description | |
|---|---|---|
static void | scVaultShowStandingActorMessage (Sint32 actorId) | Stops an actor, faces the leader and shows the current message. |
static void | scVaultShowMessageAndWait (Sint32 actorId, Sint32 delay) | |
static void | scVaultFaceEachOtherAndWait (Sint32 actorId, Sint32 other, Sint32 delay) | |
static UNREAD_RESULT | scVaultUpdateWomanWantingRoofFixed (ACTOR *woman) | The woman wanting the roof fixed paces in front of the inn looking for the man who should be fixing it, and stops when Isaac comes up in front of her, or while he talks to someone or reads a mind. |
const SCENE_ENTRANCE * | scGetEntrances (void) | The six rooms share one entrance table. |
const SCENE_EXIT_REGION * | scGetExitRegions (void) | The scene has no exit regions: its regions entry returns none. |
const Uint32 * | scGetExits (void) | Both scenes share one exit table. |
const ACTOR_PLACE * | scGetActorPlacements (void) | Some villagers only turn back after talking once the flood is over or their family has gone home. |
static int | scVaultGetIvanVenusDjinnCount (void) | Counts the Venus Djinn that must leave Ivan before he leaves the party. |
static void | scVaultIvanStaysBehind (void) | While Ivan is helping look for the rod, leaving Vault by the path north, past the bell tower (metatiles (13, 7) and (14, 7)), or the path south, under the rope bridge (metatiles (24, 30) and (25, 30)), Ivan steps out of the party and stays behind. |
static void | scVaultPeerIntoWell (void) | Isaac peers into the well in the south-west of Vault (metatiles (7, 24) to (8, 25)): "You can hear water rumbling down there." |
const CUE * | scGetCues (void) | The first water beast's cave changes its cues once the first drain has lowered its water: the beast is gone and its two puddles can be frozen. |
static inline void | scVaultAskYesNoAndShowAnswer (Sint32 speaker) | Asks the question in the current message, then shows the reply to Yes or, after a No, the message after it. |
static void | scVaultAskAboutEruption (void) | While the rod is missing, the fair-haired woman east of the six gravestones asks, "Wasn't the eruption of Mt. Aleph incredible?", and answers Isaac's yes or no. |
static void | scVaultAskAboutFleeingTravelers (void) | While the rod is missing, the old woman east of the inn's door says some travelers left in a big hurry, as if on the run, and asks whether the party saw them coming in. |
static void | scVaultThiefDeniesStealing (void) | The purple-haired thief standing beside the Sanctum's door asks, "Are you accusing us of stealing Hammet's treasured Shaman's Rod?" |
static void | scVaultAskAboutAdventure (void) | While the rod is missing, the robed traveler beside the Sanctum's door asks, "Hmm, off on an adventure, are you?" |
static void | scVaultTalkOfStealingInEruption (void) | While the rod is missing, the woman in green north of the inn stops and says some folks got robbed during the chaos of the eruption. |
static void | scVaultStrongmanOnWatchSuspectsOutsiders (void) | While the rod is missing, the strongman by the rope bridge stops and says nobody steals on his watch, so the thieves must be from out of town. |
static void | scVaultTalkToDog (void) | While the rod is missing, the dog among the six gravestones turns to Isaac and barks. |
static void | scVaultPityIvan (void) | While the rod is missing, the boy walking round the well stops: poor Ivan was left at the mayor's to look for the stolen rod. |
static void | scVaultTalkOfHammetsCaravan (void) | While the rod is missing, the girl walking round the well stops: Master Hammet's caravan left town as soon as the eruption stopped. |
static void | scVaultLookForManFixingRoof (void) | Once the suspects' minds are read, the woman pacing in front of the inn turns to Isaac, cross, and says the young man should be fixing the roof but she can't find him anywhere; he's probably slacking off again. |
static void | scVaultAskAboutLeavingAgain (void) | Once the thieves are jailed, the young man outside the house in the east asks, "So, you're hitting the road again?" |
static void | scVaultPraiseThievesCapture (void) | Once the thieves are jailed, the woman in green north of the inn says, "It's great that you caught those thieves!" |
static void | scVaultTalkAboutIvan (void) | Once the thieves are jailed, the old man east of the jail's door says that Hammet's servant, Ivan, went out to Lunpa. |
static void | scVaultTalkOfDamagedRoads (void) | Once the thieves are jailed, the old woman east of the inn's door says the eruption devastated roads throughout Angara, and the way to Kalay waits on the southern bridge's repair. |
static void | scVaultAskWhetherIvanWentToLunpa (void) | Once the thieves are jailed, the boy walking round the well asks, "Ivan didn't go to Lunpa all alone, did he?" With Ivan in the party he laughs that he shouldn't have worried, and asks when Ivan joined up with Isaac. |
static void | scVaultThankForCapturingThieves (void) | Once the thieves are jailed, the girl walking round the well stops: everyone is grateful the party captured the thieves. |
static void | scVaultAskAboutPrisoners (void) | Once the thieves are jailed, the strongman by the rope bridge asks about the prisoners. |
static void | scVaultAskWhoCapturedThieves (void) | Once the thieves are jailed, the robed traveler beside the Sanctum's door asks, "Are you the ones who captured the thieves?" |
static void | scVaultTalkToDogAfterCapture (void) | Once the thieves are jailed, the dog south of the six gravestones barks. |
static void | scVaultThankBeforeDeparture (void) | Once the thieves are jailed, the young man back at the foot of the inn's ladder nods and thanks the party for the other day, and will pray for their safety. |
static void | scVaultReadMindOnStealing (void) | Mind Read on the woman in green north of the inn: no man should steal during the panic of an eruption, it's unforgivable. |
static void | scVaultReadMindOnTravelers (void) | Mind Read on the old woman east of the inn's door: that group of travelers was a strange bunch, seemingly heading for the north-eastern Goma Range. |
static void | scVaultReadMindOnIvan (void) | Mind Read on the boy walking round the well: "I bet it was those three creeps at the inn who stole the rod." Once the thieves are jailed he wonders where Ivan went all by himself, or, with Ivan in the party, "But when did they join Ivan?" |
static void | scVaultReadMindOnWealth (void) | Mind Read on the girl walking round the well: it doesn't matter how rich you are if it can't save you from a volcano. |
static void | scVaultReadMindOnSuspects (void) | Mind Read on the strongman by the rope bridge: everyone knows the three at the inn stole the rod. |
static void | scVaultReadDogMind (void) | Mind Read on the dog among the six gravestones. |
static void | scVaultReadWomanWantingTheRoofFixedMind (void) | Mind Read on the woman pacing in front of the inn: "That sneak... |
static void | scVaultClimbIntoInnLoft (void) | Isaac climbs the ladder against the inn's west wall to the hole in its roof (metatile (9, 16) at the top) and goes in, into the inn's loft, the room with the crate (VAULT_LOG_ROOMS_A_WEST). |
static void | scVaultJumpActorToAndWait (Sint32 actorId, Sint32 x, Sint32 z, Sint32 verticalSpeed) | Moves an actor through a jump and waits up to sixty ticks for it to settle. |
static void | scVaultRingBell (void) | Up on the bell tower, Isaac rings the bell (metatile (17, 8)). |
static void | scVaultGiveBoneToDog (void) | Given a Bone, the dog runs into the middle of the six gravestones and jumps there three times, where Reveal later finds the way down to Vault Cave. |
Sint32 | scInit (void) | Arriving in Vault puts everyone where the story has them. |
static void | scVaultUpdateDriftingEffect (ACTOR *effect) | Applies drift and gradually damps both rates toward zero. |
static void | scVaultSpawnDriftingEffect (Sint32 flags) | Spawns a drifting sprite near the dog, sharing its drawing priority. |
Variables
| Name | Description | |
|---|---|---|
extern SCENE_ENTRANCE | VaultEntrances [] | |
extern Uint32 | VaultExits [] | |
extern ACTOR_PLACE | VaultActorPlacements [] | |
extern ACTOR_PLACE | VaultActorPlacementsAfterThieves [] | |
extern CUE | VaultCues [] | |
extern CUE | VaultCuesAfterThieves [] | |
extern Sint32 | VaultDriftScriptA [] | How long an unused drifting sprite lasts before it is released: about 120 ticks, or about 40. |
extern Sint32 | VaultDriftScriptB [] | |
const Sint32 * | FieldEffectDurationScripts [] | The resident copy of the scripts EFFECT_SCRIPT_MASK picks, by enum EFFECT_DURATION. |
Sint32 | VaultWomanWantingTheRoofFixedRoute [] | ACTOR_WOMAN_WANTING_THE_ROOF_FIXED's search for the young man fixing the roof, in front of the inn's west end. |
Description
Vault (SceneIdVault), "the town at the heart of Angara", as the party first
finds it after Mt. Aleph's eruption.
This scene is its streets, with the townspeople, Ivan, the bell and the dog.
The houses, the inn and its loft, where the search for Hammet's stolen
Shaman's Rod plays out, are log_rooms_a.c.
scGetActorPlacements and scGetCues choose their tables by
FLAG_VAULT_THIEVES_JAILED. Once the party has reached Kalay
(FLAG_KALAY_REACHED), scInit sends it straight on to the town's later scene
(VAULT_TO_VAULT_REVISIT, SceneIdVaultRevisit, vault_revisit.c).
The story flags change the streets in order:
- While the rod is missing, the townspeople talk of the eruption, the theft
and the travelers who left in a hurry. Mind Read on them blames the three
strangers staying at the inn. One of the three loiters in town until the
party has confronted them in the loft (
FLAG_VAULT_THIEVES_ATTACKED). Once the suspects' minds have been read (FLAG_VAULT_SUSPECTS_MIND_READ), the young man fixing a roof is missing, and a woman walks about looking for him. - While Ivan is helping the search (
FLAG_VAULT_IVAN_JOINED_ROD_SEARCH), leaving by either path has him stay behind (scVaultIvanStaysBehind).scInithas him rejoin when the party comes back in by a path or out of the Vault Sanctum. - Once the thieves are jailed, the townspeople thank the party. The dog,
given a Bone (
scVaultGiveBoneToDog,FLAG_VAULT_DOG_SHOWN_PASSAGE), runs to a spot and jumps there three times. The passage it shows opens only in the later scene.
Sap, a Venus Djinni, hides in the tree east of the bell tower. The first ring
since the party came in by a path (FLAG_VAULT_SAP_CALLED_BY_BELL) calls it
out: it leaps onto the cliff top above the cave mouth beyond the tree. It
joins only in the later scene.
The well in the south-west rumbles with water, and the wooden box beside the mayor's house in the north-west holds a Nut.
The town lies on terraces. Its paths leave north, past the bell tower, and south, under the rope bridge in the south-east. The mayor's house is the big house in the north-west, with the jail's iron door in the cliff below it and the Sanctum's double door further south in the same cliff. The inn stands in the middle, a ladder against its west wall up to the hole a fiery rock burnt in its roof. East of it are a house, the weapon and armor shop's door in the cliff under the bell tower, the item shop's door in the cliff further east, and the house by the rope bridge. Six gravestones stand south of the inn, where the dog sits.
The doors open with an animation (Vault*DoorMetatiles). They lead into the
houses, shops and inn (SceneIdLogRoomsA), the jail (SceneIdStoneRooms) and
the Vault Sanctum (VAULT_SANCTUM). The metatile behaviors the scripts
answer are VAULT_METATILE_BEHAVIOR (vault.h).
The rope bridge in the town's south-east spans the path that runs south under
it. Stepping onto either end of it or off its west end switches the metatiles
beneath it between the deck and the path (shared/vault_toggle.c).
Macros in detail
VAULT_GEM_OWNERS_HOUSE_EXIT
#define VAULT_GEM_OWNERS_HOUSE_EXIT VAULT_LOG_ROOMS_A_EAST_SOUTHEAST
The rooms behind the town's doors (shared/vault_doors.c).
Referenced by scVaultEnterGemOwnersHouse().
Definition at line 719 of file vault.c.
VAULT_CHILDS_HOUSE_EXIT
#define VAULT_CHILDS_HOUSE_EXIT VAULT_LOG_ROOMS_A_SOUTHEAST
Referenced by scVaultEnterChildsHouse().
Definition at line 720 of file vault.c.
VAULT_INN_EXIT
#define VAULT_INN_EXIT VAULT_LOG_ROOMS_A_SOUTHWEST
Referenced by scVaultEnterInn().
Definition at line 721 of file vault.c.
VAULT_ITEM_SHOP_EXIT
#define VAULT_ITEM_SHOP_EXIT VAULT_LOG_ROOMS_A_EAST
Referenced by scVaultEnterItemShop().
Definition at line 722 of file vault.c.
VAULT_WEAPON_AND_ARMOR_SHOP_EXIT
#define VAULT_WEAPON_AND_ARMOR_SHOP_EXIT VAULT_LOG_ROOMS_A_NORTH_NORTHEAST
Referenced by scVaultEnterWeaponAndArmorShop().
Definition at line 723 of file vault.c.
VAULT_MAYORS_HOUSE_EXIT
#define VAULT_MAYORS_HOUSE_EXIT VAULT_LOG_ROOMS_A_NORTHWEST
Referenced by scVaultEnterMayorsHouse().
Definition at line 724 of file vault.c.
VAULT_JAIL_EXIT
#define VAULT_JAIL_EXIT VAULT_STONE_ROOMS
Referenced by scVaultEnterJail().
Definition at line 729 of file vault.c.
DRIFT_DAMPING
#define DRIFT_DAMPING 28
A drifting sprite loses this share of each rate a tick: a 28th.
Referenced by scVaultUpdateDriftingEffect().
Definition at line 978 of file vault.c.
Enumerations in detail
anonymous enum
enum { VAULT_DRIFT_RATE }
The unit of the unused drift's random speeds: a tenth of a pixel a tick.
| Enumerator | Value | Description |
|---|---|---|
VAULT_DRIFT_RATE | toFIXED(1) / 10 |
Definition at line 78 of file vault.c.
anonymous enum
enum { ACTOR_WELCOMING_YOUNG_MAN, ACTOR_ERUPTION_WITNESS, ACTOR_VILLAGER_ON_HAMMET, ACTOR_WOMAN_ON_STEALING, … }
The townspeople, named by what they say. Both placement tables number their
rows from ACTOR_FIRST_PLACED in this order, Ivan keeping his own party slot.
| Enumerator | Value | Description |
|---|---|---|
ACTOR_WELCOMING_YOUNG_MAN | ACTOR_FIRST_PLACED | A young man with brown hair outside the house in the east, by the rope bridge. "Welcome to Vault, the town at the heart of Angara." |
ACTOR_ERUPTION_WITNESS | A woman with fair hair who asks about the eruption, east of the six gravestones. | |
ACTOR_VILLAGER_ON_HAMMET | A burly grey-haired man up on the bell tower, beside the bell. | |
ACTOR_WOMAN_ON_STEALING | A woman in a green dress who wanders north of the inn. | |
ACTOR_OLD_MAN_ON_HAMMETS_SERVANT | An old man with a cane, east of the jail's door. | |
ACTOR_OLD_WOMAN_ON_THE_TRAVELERS | An old woman who wanders east of the inn's door. | |
ACTOR_BOY_ROUND_THE_WELL | The two children who walk round the | |
ACTOR_GIRL_ROUND_THE_WELL | well, half a circle apart (VaultBoyRoundTheWellRoute, VaultGirlRoundTheWellRoute). | |
ACTOR_STRONGMAN_ON_WATCH | A stocky, muscular man who wanders near the west end of the rope bridge. | |
ACTOR_THIEF_IN_TOWN | One of the three thieves, drawn with long purple hair as in the loft, standing beside the Sanctum's door until the party confronts them (FLAG_VAULT_THIEVES_ATTACKED). | |
ACTOR_STRANDED_TRAVELER | A bearded man in a long robe beside the Sanctum's door. | |
ACTOR_VAULT_DOG | The dog that sits among the six gravestones. | |
ACTOR_YOUNG_MAN_FIXING_THE_ROOF | A young man at the foot of the ladder against the inn's west wall, who is meant to fix the roof and is later found tied up in the inn's loft. | |
ACTOR_WOMAN_WANTING_THE_ROOF_FIXED | A woman with fair hair who paces in front of the inn's west end, looking for ACTOR_YOUNG_MAN_FIXING_THE_ROOF. | |
ACTOR_SAP | ACTOR_WOMAN_WANTING_THE_ROOF_FIXED + 2 | Sap, a Venus Djinni, hiding in the tree east of the bell tower until the bell calls it. The row before it is an ivy nothing shows. |
Definition at line 85 of file vault.c.
Functions in detail
scVaultShowStandingActorMessage
static void scVaultShowStandingActorMessage(Sint32 actorId)
Stops an actor, faces the leader and shows the current message.
References fdActorSetAnimation(), fdScriptEnd(), fdScriptShowMessage(), fdScriptStart(), scVaultFaceEachOtherAndWait() and Sint32.
Referenced by scVaultPraiseThievesCapture(), scVaultStrongmanOnWatchSuspectsOutsiders(), scVaultTalkAboutIvan(), scVaultTalkOfDamagedRoads() and scVaultTalkOfStealingInEruption().
Definition at lines 135 and 430 of file vault.c.
scVaultShowMessageAndWait
static void scVaultShowMessageAndWait(Sint32 actorId, Sint32 delay)
References fdScriptShowMessage(), fdScriptWait() and Sint32.
Referenced by scVaultAskWhetherIvanWentToLunpa(), scVaultPityIvan(), scVaultTalkOfHammetsCaravan() and scVaultThankForCapturingThieves().
Definition at lines 136 and 964 of file vault.c.
scVaultFaceEachOtherAndWait
static void scVaultFaceEachOtherAndWait(Sint32 actorId, Sint32 other, Sint32 delay)
References fdActorTurnToFaceEachOther(), fdScriptWait() and Sint32.
Referenced by scVaultAskAboutAdventure(), scVaultAskAboutEruption(), scVaultAskAboutFleeingTravelers(), scVaultAskAboutLeavingAgain(), scVaultAskAboutPrisoners(), scVaultAskWhetherIvanWentToLunpa(), scVaultAskWhoCapturedThieves(), scVaultLookForManFixingRoof(), scVaultPityIvan(), scVaultShowStandingActorMessage(), scVaultTalkOfHammetsCaravan(), scVaultTalkToDog(), scVaultTalkToDogAfterCapture(), scVaultThankBeforeDeparture(), scVaultThankForCapturingThieves() and scVaultThiefDeniesStealing().
Definition at lines 137 and 970 of file vault.c.
scVaultUpdateWomanWantingRoofFixed
static UNREAD_RESULT scVaultUpdateWomanWantingRoofFixed(ACTOR *woman)
The woman wanting the roof fixed paces in front of the inn looking for the man who should be fixing it, and stops when Isaac comes up in front of her, or while he talks to someone or reads a mind.
References fdActorGet(), scVaultStopIfFacingNear(), Sint32 and state.
Referenced by scInit().
Definition at line 148 of file vault.c.
scGetEntrances
const SCENE_ENTRANCE *scGetEntrances(void)
References VaultEntrances.
Definition at line 169 of file vault.c.
scGetExitRegions
const SCENE_EXIT_REGION *scGetExitRegions(void)
Definition at line 174 of file vault.c.
scGetExits
const Uint32 *scGetExits(void)
References VaultExits.
Definition at line 179 of file vault.c.
scGetActorPlacements
const ACTOR_PLACE *scGetActorPlacements(void)
References gmFlagGet(), VaultActorPlacements and VaultActorPlacementsAfterThieves.
Definition at line 184 of file vault.c.
scVaultGetIvanVenusDjinnCount
static int scVaultGetIvanVenusDjinnCount(void)
Counts the Venus Djinn that must leave Ivan before he leaves the party.
References gmUnitGet().
Referenced by scVaultIvanStaysBehind().
Definition at line 192 of file vault.c.
scVaultIvanStaysBehind
static void scVaultIvanStaysBehind(void)
While Ivan is helping look for the rod, leaving Vault by the path north, past the bell tower (metatiles (13, 7) and (14, 7)), or the path south, under the rope bridge (metatiles (24, 30) and (25, 30)), Ivan steps out of the party and stays behind. "Are you leaving? I'm still worried about the rod, so I'll just wait here until you two return."
Before he joins, or once the thieves are jailed, the party simply leaves. If Ivan holds Flint, he gives it back to Isaac first.
References fdActorGet(), fdActorSetAnimationAndWait(), fdActorSetPosFX(), fdActorTurnToFaceEachOther(), fdActorWalkToAndWait(), fdCameraWaitForArrival(), fdPartyRemoveMemberRestored(), fdScriptEnd(), fdScriptFinishScreenTransition(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptShowMessageThenWait(), fdScriptStart(), fdScriptWait(), fdScriptWaitTransitionTicks(), gmFlagGet(), scVaultGetIvanVenusDjinnCount(), scVaultReturnIsaacsDjinni(), state, syImportScriptSetExitRequest() and sySynch().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 207 of file vault.c.
scVaultPeerIntoWell
static void scVaultPeerIntoWell(void)
Isaac peers into the well in the south-west of Vault (metatiles (7, 24) to (8, 25)): "You can hear water rumbling down there."
References fdScriptEnd(), fdScriptStart() and mnFieldMessageShow().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 266 of file vault.c.
scGetCues
const CUE *scGetCues(void)
References gmFlagGet(), VaultCues and VaultCuesAfterThieves.
Definition at line 274 of file vault.c.
scVaultAskYesNoAndShowAnswer
static inline void scVaultAskYesNoAndShowAnswer(Sint32 speaker)
Asks the question in the current message, then shows the reply to Yes or, after a No, the message after it.
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage(), fdScriptShowMessage() and Sint32.
Referenced by scVaultAskAboutAdventure(), scVaultAskAboutEruption(), scVaultAskAboutFleeingTravelers(), scVaultAskAboutLeavingAgain(), scVaultAskAboutPrisoners(), scVaultAskWhoCapturedThieves() and scVaultThiefDeniesStealing().
Definition at line 283 of file vault.c.
scVaultAskAboutEruption
static void scVaultAskAboutEruption(void)
While the rod is missing, the fair-haired woman east of the six gravestones asks, "Wasn't the eruption of Mt. Aleph incredible?", and answers Isaac's yes or no.
References fdActorFaceDirection(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 294 of file vault.c.
scVaultAskAboutFleeingTravelers
static void scVaultAskAboutFleeingTravelers(void)
While the rod is missing, the old woman east of the inn's door says some travelers left in a big hurry, as if on the run, and asks whether the party saw them coming in.
References fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 307 of file vault.c.
scVaultThiefDeniesStealing
static void scVaultThiefDeniesStealing(void)
The purple-haired thief standing beside the Sanctum's door asks, "Are you accusing us of stealing Hammet's treasured Shaman's Rod?"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 320 of file vault.c.
scVaultAskAboutAdventure
static void scVaultAskAboutAdventure(void)
While the rod is missing, the robed traveler beside the Sanctum's door asks, "Hmm, off on an adventure, are you?"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 331 of file vault.c.
scVaultTalkOfStealingInEruption
static void scVaultTalkOfStealingInEruption(void)
While the rod is missing, the woman in green north of the inn stops and says some folks got robbed during the chaos of the eruption.
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart() and scVaultShowStandingActorMessage().
Referenced by VaultCues.
Definition at line 342 of file vault.c.
scVaultStrongmanOnWatchSuspectsOutsiders
static void scVaultStrongmanOnWatchSuspectsOutsiders(void)
While the rod is missing, the strongman by the rope bridge stops and says nobody steals on his watch, so the thieves must be from out of town.
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart() and scVaultShowStandingActorMessage().
Referenced by VaultCues.
Definition at line 352 of file vault.c.
scVaultTalkToDog
static void scVaultTalkToDog(void)
While the rod is missing, the dog among the six gravestones turns to Isaac and barks. "Ruff! Rrruff!!"
References fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 362 of file vault.c.
scVaultPityIvan
static void scVaultPityIvan(void)
While the rod is missing, the boy walking round the well stops: poor Ivan was left at the mayor's to look for the stolen rod.
References fdActorGet(), fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultFaceEachOtherAndWait(), scVaultShowMessageAndWait() and sySynch().
Referenced by VaultCues.
Definition at line 374 of file vault.c.
scVaultTalkOfHammetsCaravan
static void scVaultTalkOfHammetsCaravan(void)
While the rod is missing, the girl walking round the well stops: Master Hammet's caravan left town as soon as the eruption stopped.
References fdActorGet(), fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultFaceEachOtherAndWait(), scVaultShowMessageAndWait() and sySynch().
Referenced by VaultCues.
Definition at line 394 of file vault.c.
scVaultLookForManFixingRoof
static void scVaultLookForManFixingRoof(void)
Once the suspects' minds are read, the woman pacing in front of the inn turns to Isaac, cross, and says the young man should be fixing the roof but she can't find him anywhere; he's probably slacking off again.
References fdActorShowEmote(), fdScriptEnd(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptStart(), fdScriptWait() and scVaultFaceEachOtherAndWait().
Referenced by VaultCues.
Definition at line 415 of file vault.c.
scVaultAskAboutLeavingAgain
static void scVaultAskAboutLeavingAgain(void)
Once the thieves are jailed, the young man outside the house in the east asks, "So, you're hitting the road again?"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCuesAfterThieves.
Definition at line 443 of file vault.c.
scVaultPraiseThievesCapture
static void scVaultPraiseThievesCapture(void)
Once the thieves are jailed, the woman in green north of the inn says, "It's great that you caught those thieves!"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart() and scVaultShowStandingActorMessage().
Referenced by VaultCuesAfterThieves.
Definition at line 455 of file vault.c.
scVaultTalkAboutIvan
static void scVaultTalkAboutIvan(void)
Once the thieves are jailed, the old man east of the jail's door says that Hammet's servant, Ivan, went out to Lunpa. With Ivan in the party: "I see, Ivan... I guess it was impossible to rescue Master Hammet."
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowStandingActorMessage().
Referenced by VaultCuesAfterThieves.
Definition at line 466 of file vault.c.
scVaultTalkOfDamagedRoads
static void scVaultTalkOfDamagedRoads(void)
Once the thieves are jailed, the old woman east of the inn's door says the eruption devastated roads throughout Angara, and the way to Kalay waits on the southern bridge's repair.
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart() and scVaultShowStandingActorMessage().
Referenced by VaultCuesAfterThieves.
Definition at line 481 of file vault.c.
scVaultAskWhetherIvanWentToLunpa
static void scVaultAskWhetherIvanWentToLunpa(void)
Once the thieves are jailed, the boy walking round the well asks, "Ivan didn't go to Lunpa all alone, did he?" With Ivan in the party he laughs that he shouldn't have worried, and asks when Ivan joined up with Isaac.
References fdActorGet(), fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet(), scVaultFaceEachOtherAndWait(), scVaultShowMessageAndWait() and sySynch().
Referenced by VaultCuesAfterThieves.
Definition at line 492 of file vault.c.
scVaultThankForCapturingThieves
static void scVaultThankForCapturingThieves(void)
Once the thieves are jailed, the girl walking round the well stops: everyone is grateful the party captured the thieves.
References fdActorGet(), fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultFaceEachOtherAndWait(), scVaultShowMessageAndWait() and sySynch().
Referenced by VaultCuesAfterThieves.
Definition at line 514 of file vault.c.
scVaultAskAboutPrisoners
static void scVaultAskAboutPrisoners(void)
Once the thieves are jailed, the strongman by the rope bridge asks about the prisoners. "Those men you captured... They're in jail now?"
References fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCuesAfterThieves.
Definition at line 534 of file vault.c.
scVaultAskWhoCapturedThieves
static void scVaultAskWhoCapturedThieves(void)
Once the thieves are jailed, the robed traveler beside the Sanctum's door asks, "Are you the ones who captured the thieves?"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), scVaultAskYesNoAndShowAnswer() and scVaultFaceEachOtherAndWait().
Referenced by VaultCuesAfterThieves.
Definition at line 547 of file vault.c.
scVaultTalkToDogAfterCapture
static void scVaultTalkToDogAfterCapture(void)
Once the thieves are jailed, the dog south of the six gravestones barks. "Ruff! Rrruff!!" If Isaac carries a Bone and the dog has not yet shown its spot, the field menu opens so that he can give it one.
References fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), gmFlagGet(), gmPartyInventoryFindMember() and scVaultFaceEachOtherAndWait().
Referenced by VaultCuesAfterThieves.
Definition at line 559 of file vault.c.
scVaultThankBeforeDeparture
static void scVaultThankBeforeDeparture(void)
Once the thieves are jailed, the young man back at the foot of the inn's ladder nods and thanks the party for the other day, and will pray for their safety.
References fdActorSetAnimationAndWait(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptWait() and scVaultFaceEachOtherAndWait().
Referenced by VaultCuesAfterThieves.
Definition at line 578 of file vault.c.
scVaultReadMindOnStealing
static void scVaultReadMindOnStealing(void)
Mind Read on the woman in green north of the inn: no man should steal during the panic of an eruption, it's unforgivable. Once the thieves are jailed she wonders how to punish them: "Public humiliation? Or perhaps a beating!"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowThought().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 593 of file vault.c.
scVaultReadMindOnTravelers
static void scVaultReadMindOnTravelers(void)
Mind Read on the old woman east of the inn's door: that group of travelers was a strange bunch, seemingly heading for the north-eastern Goma Range. Once the thieves are jailed she thinks that, with the road out, the only way on is the cave in the Goma Range.
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowThought().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 608 of file vault.c.
scVaultReadMindOnIvan
static void scVaultReadMindOnIvan(void)
Mind Read on the boy walking round the well: "I bet it was those three creeps at the inn who stole the rod." Once the thieves are jailed he wonders where Ivan went all by himself, or, with Ivan in the party, "But when did they join Ivan?"
References fdActorGet(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowThought().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 627 of file vault.c.
scVaultReadMindOnWealth
static void scVaultReadMindOnWealth(void)
Mind Read on the girl walking round the well: it doesn't matter how rich you are if it can't save you from a volcano. Once the thieves are jailed, the party must be stronger than they look.
References fdActorGet(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowThought().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 649 of file vault.c.
scVaultReadMindOnSuspects
static void scVaultReadMindOnSuspects(void)
Mind Read on the strongman by the rope bridge: everyone knows the three at the inn stole the rod. Once the thieves are jailed he feels much better.
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart(), gmFlagGet() and scVaultShowThought().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 664 of file vault.c.
scVaultReadDogMind
static void scVaultReadDogMind(void)
Mind Read on the dog among the six gravestones. While the rod is missing: "Stealing in the midst of a volcanic eruption... Humans value money more than they value their own lives." Once the thieves are jailed: "If you bring me a bone, I'll tell you something useful." Once it has had one: "A careful search will reveal a passage leading underground nearby."
References fdActorGet(), fdActorSetAnimation(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptWait() and gmFlagGet().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 680 of file vault.c.
scVaultReadWomanWantingTheRoofFixedMind
static void scVaultReadWomanWantingTheRoofFixedMind(void)
Mind Read on the woman pacing in front of the inn: "That sneak... He's just wasting time instead of fixing the roof!"
References fdScriptEnd(), fdScriptSetMessageId(), fdScriptStart() and scVaultShowThought().
Referenced by VaultCues.
Definition at line 706 of file vault.c.
scVaultClimbIntoInnLoft
static void scVaultClimbIntoInnLoft(void)
Isaac climbs the ladder against the inn's west wall to the hole in its roof
(metatile (9, 16) at the top) and goes in, into the inn's loft, the room with
the crate (VAULT_LOG_ROOMS_A_WEST).
The young man who should be fixing the roof stands at the ladder's foot until the suspects' minds have been read.
References scVaultWalkThroughExit() and sySoundPlay().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 738 of file vault.c.
scVaultJumpActorToAndWait
static void scVaultJumpActorToAndWait(Sint32 actorId, Sint32 x, Sint32 z, Sint32 verticalSpeed)
Moves an actor through a jump and waits up to sixty ticks for it to settle.
References fdActorGet(), fdActorMoveToAndWait(), fdActorSetSpriteFlags(), Sint32 and sySynch().
Referenced by scVaultRingBell().
Definition at line 745 of file vault.c.
scVaultRingBell
static void scVaultRingBell(void)
Up on the bell tower, Isaac rings the bell (metatile (17, 8)). The first time since the party came in by a path, Sap the Venus Djinni pops up, startled, on top of the tree east of the tower, hops twice and leaps away north-east onto the cliff top above the cave mouth.
References fdActorJump(), fdActorSetAttachedEffect(), fdActorWalkToAndWait(), fdScriptEnd(), fdScriptGetFlag(), fdScriptStart(), fdScriptWait(), gmFlagSet(), scVaultJumpActorToAndWait() and sySoundPlay().
Referenced by VaultCues and VaultCuesAfterThieves.
Definition at line 773 of file vault.c.
scVaultGiveBoneToDog
static void scVaultGiveBoneToDog(void)
Given a Bone, the dog runs into the middle of the six gravestones and jumps there three times, where Reveal later finds the way down to Vault Cave.
References fdActorFaceDirection(), fdActorJump(), fdActorRunRepeatedMotion(), fdActorWalkToAndWait(), fdScriptEnd(), fdScriptStart(), fdScriptWait(), gmFlagSet() and gmPartyInventoryDiscard().
Referenced by VaultCuesAfterThieves.
Definition at line 797 of file vault.c.
scInit
Sint32 scInit(void)
Arriving in Vault puts everyone where the story has them. Coming back in by either path, or out of the Sanctum, while Ivan waits in town, he greets the party, "Welcome back, you two! Let's go find the rod!", and joins again.
References fdActorGet(), fdActorRunRepeatedMotion(), fdActorSetAnimationAndWait(), fdActorSetPosFX(), fdActorTurnToFaceEachOther(), fdMapGridCopyMetatileAttributes(), fdScriptAddPartyMember(), fdScriptEnd(), fdScriptSetMessageId(), fdScriptShowMessageThenWait(), fdScriptStart(), fdScriptStartScreenTransition(), fdScriptWait(), fdScriptWaitTransitionTicks(), gmFlagClear(), gmFlagGet(), MainRoutineStateWork, scVaultUpdateWalkingVillager(), scVaultUpdateWomanWantingRoofFixed(), scWalkIntoLeader(), Sint32 and syImportScriptSetExitRequest().
Definition at line 823 of file vault.c.
scVaultUpdateDriftingEffect
static void scVaultUpdateDriftingEffect(ACTOR *effect)
Applies drift and gradually damps both rates toward zero.
References Sint32 and syMathDivide().
Referenced by scVaultSpawnDriftingEffect().
Definition at line 981 of file vault.c.
scVaultSpawnDriftingEffect
static void scVaultSpawnDriftingEffect(Sint32 flags)
Spawns a drifting sprite near the dog, sharing its drawing priority.
References fdActorCreate(), fdActorGet(), fdActorSelectAnimation(), fdActorStartScript(), scVaultUpdateDriftingEffect(), Sint32, syRandomNext(), VaultDriftScriptA and VaultDriftScriptB.
Definition at line 1011 of file vault.c.
Variables in detail
VaultEntrances
extern SCENE_ENTRANCE VaultEntrances[]
SCENE_ENTRANCE VaultEntrances[]
Referenced by scGetEntrances().
Definition at lines 68 and 1169 of file vault.c.
VaultExits
extern Uint32 VaultExits[]
Uint32 VaultExits[]
Referenced by scGetExits().
Definition at lines 69 and 1193 of file vault.c.
VaultActorPlacements
extern ACTOR_PLACE VaultActorPlacements[]
ACTOR_PLACE VaultActorPlacements[]
References Sint32, VaultBoyRoundTheWellRoute, VaultGirlRoundTheWellRoute and VaultWomanWantingTheRoofFixedRoute.
Referenced by scGetActorPlacements().
Definition at lines 70 and 1214 of file vault.c.
VaultActorPlacementsAfterThieves
extern ACTOR_PLACE VaultActorPlacementsAfterThieves[]
ACTOR_PLACE VaultActorPlacementsAfterThieves[]
References Sint32, VaultBoyRoundTheWellRoute, VaultGirlRoundTheWellRoute and VaultWomanWantingTheRoofFixedRoute.
Referenced by scGetActorPlacements().
Definition at lines 71 and 1256 of file vault.c.
VaultCues
extern CUE VaultCues[]
CUE VaultCues[]
References scVaultAskAboutAdventure(), scVaultAskAboutEruption(), scVaultAskAboutFleeingTravelers(), scVaultClimbIntoInnLoft(), scVaultEnterChildsHouse(), scVaultEnterGemOwnersHouse(), scVaultEnterInn(), scVaultEnterItemShop(), scVaultEnterJail(), scVaultEnterMayorsHouse(), scVaultEnterWeaponAndArmorShop(), scVaultIvanStaysBehind(), scVaultLookForManFixingRoof(), scVaultLowerPathUnderBridge(), scVaultOpenDoorwayAndEnter(), scVaultPeerIntoWell(), scVaultPityIvan(), scVaultRaisePathToBridge(), scVaultReadDogMind(), scVaultReadMindOnIvan(), scVaultReadMindOnStealing(), scVaultReadMindOnSuspects(), scVaultReadMindOnTravelers(), scVaultReadMindOnWealth(), scVaultReadWomanWantingTheRoofFixedMind(), scVaultRingBell(), scVaultStrongmanOnWatchSuspectsOutsiders(), scVaultTalkOfHammetsCaravan(), scVaultTalkOfStealingInEruption(), scVaultTalkToDog() and scVaultThiefDeniesStealing().
Referenced by scGetCues().
Definition at lines 72 and 1293 of file vault.c.
VaultCuesAfterThieves
extern CUE VaultCuesAfterThieves[]
CUE VaultCuesAfterThieves[]
References scVaultAskAboutLeavingAgain(), scVaultAskAboutPrisoners(), scVaultAskWhetherIvanWentToLunpa(), scVaultAskWhoCapturedThieves(), scVaultClimbIntoInnLoft(), scVaultEnterChildsHouse(), scVaultEnterGemOwnersHouse(), scVaultEnterInn(), scVaultEnterItemShop(), scVaultEnterJail(), scVaultEnterMayorsHouse(), scVaultEnterWeaponAndArmorShop(), scVaultGiveBoneToDog(), scVaultIvanStaysBehind(), scVaultLowerPathUnderBridge(), scVaultOpenDoorwayAndEnter(), scVaultPeerIntoWell(), scVaultPraiseThievesCapture(), scVaultRaisePathToBridge(), scVaultReadDogMind(), scVaultReadMindOnIvan(), scVaultReadMindOnStealing(), scVaultReadMindOnSuspects(), scVaultReadMindOnTravelers(), scVaultReadMindOnWealth(), scVaultRingBell(), scVaultTalkAboutIvan(), scVaultTalkOfDamagedRoads(), scVaultTalkToDogAfterCapture(), scVaultThankBeforeDeparture() and scVaultThankForCapturingThieves().
Referenced by scGetCues().
Definition at lines 73 and 1419 of file vault.c.
VaultDriftScriptA
extern Sint32 VaultDriftScriptA[]
Sint32 VaultDriftScriptA[]
How long an unused drifting sprite lasts before it is released: about 120 ticks, or about 40.
References Sint32.
Referenced by scVaultSpawnDriftingEffect().
Definition at lines 74 and 1545 of file vault.c.
VaultDriftScriptB
extern Sint32 VaultDriftScriptB[]
Sint32 VaultDriftScriptB[]
References Sint32.
Referenced by scVaultSpawnDriftingEffect().
Definition at lines 75 and 1551 of file vault.c.
FieldEffectDurationScripts
const Sint32 *FieldEffectDurationScripts[]
References FieldEffectLongScript, FieldEffectMediumScript, FieldEffectShortScript and Sint32.
Definition at line 1098 of file vault.c.
VaultWomanWantingTheRoofFixedRoute
Sint32 VaultWomanWantingTheRoofFixedRoute[]
ACTOR_WOMAN_WANTING_THE_ROOF_FIXED's search for the young man fixing the
roof, in front of the inn's west end. She walks to one end of her
two-metatile path and the other, looks west and east, then shakes her head,
for as long as the party stays on the map.
References Sint32.
Referenced by VaultActorPlacements and VaultActorPlacementsAfterThieves.
Definition at line 1108 of file vault.c.