src/scene/west_lunpa_cave.c
West Lunpa Cave (SceneIdWestLunpaCave, area name West Lunpa Cave), the cave between the World Map and Lunpa, with a gate across it, where the party meets Bunza on the way out of Lunpa with Hammet. More…
#include "ability_ids.h"#include "flags.h"#include "sounds.h"#include "scene/walk_into_leader.h"#include "text/msg_ids.h"
Macros
| Name | Description | |
|---|---|---|
#define | FLAG_WEST_LUNPA_CAVE_GATE_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x00) | The gate's puddle is frozen into a pillar, propping the gate open. |
#define | FLAG_WEST_LUNPA_CAVE_GATE_LOWERED FLAG_SCENE_TEMP(0x01) | The lowering switch has lowered the gate. |
#define | FLAG_WEST_LUNPA_CAVE_GATE_RAISED FLAG_SCENE_TEMP(0x02) | The gate is raised, by the raising switch or the ice pillar under it. |
#define | FLAG_WEST_LUNPA_CAVE_NORTH_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x03) | The north puddle is frozen into a pillar. |
#define | FLAG_WEST_LUNPA_CAVE_SOUTH_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x04) | The puddle in the first chamber is frozen into a pillar. |
Enumerations
| Name | Description | |
|---|---|---|
enum | WEST_LUNPA_CAVE_METATILE_BEHAVIOR { METATILE_BEHAVIOR_WEST_LUNPA_CAVE_WORLD_MAP_PASSAGE, METATIL … } | The metatiles the cave's cues answer: the two ways out, the two switches and the spot where Bunza is seen. |
enum | WEST_LUNPA_CAVE_ACTOR_ID { ACTOR_UNUSED_PUDDLE, ACTOR_SOUTH_PUDDLE, ACTOR_GATE_PUDDLE, … } | The cave's actors, numbered in the order of WestLunpaCaveActorPlacements. |
enum | anonymous enum { GATE_PILLAR_PRIORITY } | The sprite priority the gate's puddle takes once the gate has come down. |
enum | SIGHTING_MESSAGE { SIGHTING_GARET_SAW_SOMEONE, SIGHTING_MIA_SAW_SOMETHING, SIGH … } | The party's lines as Bunza steps out behind them (scWestLunpaCaveHammetFindsBunza), in order. |
enum | RECOGNITION_MESSAGE { RECOGNITION_HAMMET_CALLS_OUT, RECOGNITION_HAMMET_NAMES_BUNZA … } | Hammet and Bunza recognizing each other (scWestLunpaCaveHammetFindsBunza), in order. |
enum | REUNION_MESSAGE { REUNION_BUNZA_ASKS_ABOUT_RELEASE, REUNION_HAMMET_CREDITS_IVA … } | The reunion's talk in the first chamber (scWestLunpaCaveHoldReunion), in order. |
enum | PLAN_MESSAGE { PLAN_HAMMET_ASKS_PLAN, PLAN_BUNZA_HAS_WAGON, PLAN_MIA_ASKS_A … } | Hammet asking Bunza's plan, and Bunza's wagon to Kalay, in order. |
enum | WAGON_MESSAGE { WAGON_BUNZA_LEADS_THE_WAY, WAGON_GARET_ASKS_TO_RIDE } | The lines before the wagon question (scWestLunpaCaveAskAboutWagon). |
enum | CONFUSION_MESSAGE { CONFUSION_IVAN_IS_CONFUSED, CONFUSION_GARET_ASKS_AGAIN } | Ivan, confused by Isaac's answers, and Garet asking the wagon question again. |
enum | WARNING_MESSAGE { WARNING_IVAN_ASKS_IF_STAYING, WARNING_BUNZA_CANNOT_WAIT, WAR … } | The lines of scWestLunpaCaveBunzaCannotWait. |
enum | FAREWELL_MESSAGE { FAREWELL_GARET_STAYS, FAREWELL_MIA_STAYS, FAREWELL_IVAN_STAY … } | The lines as the party stays behind (scWestLunpaCaveStayBehind). |
enum | DEPARTURE_MESSAGE { DEPARTURE_GARET_HEADS_FOR_KALAY, DEPARTURE_IVAN_THINKS_OF_LA … } | The lines as the party rides the wagon (scWestLunpaCaveRideWagon). |
Functions
| Name | Description | |
|---|---|---|
static void | scWestLunpaCaveHoldReunion (void) | The screen opens on everyone gathered in the first chamber. |
static void | scWestLunpaCaveAskAboutWagon (void) | Garet asks whether they should ride in the wagon too, and the questions go on until Isaac's answers settle it: the party rides to Kalay, or stays behind to finish its business in Lunpa (the walkthrough's No, Yes, Yes). |
static Uint8 | scWestLunpaCaveLeaderAnswersYes (void) | The yes-or-no menu answers 0 for Yes; this turns that into true or false. |
static Uint8 | scWestLunpaCaveGaretAsksIfNotRiding (void) | Garet asks, "Huh? |
static Uint8 | scWestLunpaCaveGaretAsksAboutUnfinishedBusiness (void) | Garet asks, "Do you have some unfinished business in Lunpa?" |
static Uint8 | scWestLunpaCaveConfirmStaying (void) | A step before the party stays that shows nothing and always agrees. |
static Uint8 | scWestLunpaCaveBunzaAsksAboutUnfinishedBusiness (void) | Bunza asks, "Do you have any unfinished business?" |
static Uint8 | scWestLunpaCaveGaretChecksNothingLeftToDo (void) | Garet asks, "Don't startle me! |
static Uint8 | scWestLunpaCaveMiaAsksIfRidingAfterAll (void) | Mia asks, "So, what? |
static Uint8 | scWestLunpaCaveBunzaCannotWait (void) | Ivan winces: so they won't ride in the wagon? |
static Uint8 | scWestLunpaCaveGaretAsksAboutThingsToDo (void) | Garet asks, "Are you saying you still have some things to do here in Lunpa?" |
static void | scWestLunpaCaveStayBehind (void) | The party stays: Garet, Mia and Ivan each say they'll stay with Isaac, Hammet lets Ivan go, and Hammet and Bunza walk off south out of the cave. |
static void | scWestLunpaCaveRideWagon (void) | The party rides: Garet says on to Kalay, Ivan and Hammet look forward to seeing Lady Layana, and everyone walks out of the cave to the south, where the World Map plays the wagon's departure. |
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) | The ways out: to the World Map, to Lunpa, and away in Bunza's wagon. |
const ACTOR_PLACE * | scGetActorPlacements (void) | The puddles, and Bunza, Hammet and the party for the reunion, kept off the stage until it plays. |
const CUE * | scGetCues (void) | The cave's scripts: its ways out, the two switches, Frost on each puddle and the spot where Bunza is seen. |
static void | scWestLunpaCaveUnusedFreezePuddle (void) | Unused: Frost on the fourth puddle, at the map's top-left corner (metatile (0, 0)) where the screen never goes, would freeze it, and no flag would remember it. |
static void | scWestLunpaCaveFreezeSouthPuddle (void) | Frost on the puddle by the rocks on the first chamber's west side (metatile (8, 32)) freezes it into a tall ice pillar against the wall. |
static void | scWestLunpaCaveGateDrawPropped (void) | The gate rises onto the ice pillar under it in steps of four ticks and stays up, and the way under it opens. |
static void | scWestLunpaCaveFreezeGatePuddle (void) | Frost on the puddle under the half-raised gate (metatile (21, 15)) freezes it into a tall ice pillar. |
static void | scWestLunpaCaveFreezeNorthPuddle (void) | Frost on the puddle in the passage north of the gate, east of the raising switch (metatile (26, 8)), freezes it into a tall ice pillar, which is still there when the party comes back. |
static void | scWestLunpaCaveGateLower (void) | The gate drops to the floor in steps of four ticks, over the puddle, and the way under it is shut. |
static void | scWestLunpaCaveFlipLoweringSwitch (void) | Isaac flips the switch on the wall east of the gate, on the World Map side (metatile (24, 15)): "Isaac flipped the switch." The gate drops to the floor, covering the puddle. |
static void | scWestLunpaCaveGateRaise (void) | The gate rises clear in steps of four ticks, and the way under it opens. |
static void | scWestLunpaCaveFlipRaisingSwitch (void) | Isaac flips the switch on the wall north of the gate, on the Lunpa side (metatile (21, 8)): "Isaac flipped the switch." The gate rises so the party can walk under it. |
static void | scWestLunpaCaveHammetFindsBunza (void) | On the way out of Lunpa with Hammet, as the party comes down the passage into the first chamber (metatile (11, 29)), Bunza steps out further up the passage behind them. |
Sint32 | scInit (void) | Draws the gate and the ice pillars as the party left them. |
Variables
| Name | Description | |
|---|---|---|
extern const SCENE_ENTRANCE | WestLunpaCaveEntrances [] | |
extern const Uint32 | WestLunpaCaveExits [] | |
extern const ACTOR_PLACE | WestLunpaCaveNoActorPlacements [] | |
extern const ACTOR_PLACE | WestLunpaCaveActorPlacements [] | |
extern const CUE | WestLunpaCaveCues [] | |
const CUE | WestLunpaCaveNoCues [] | Unused: an empty cue table nothing returns. |
Description
West Lunpa Cave (SceneIdWestLunpaCave, area name West Lunpa Cave), the cave
between the World Map and Lunpa, with a gate across it, where the party meets
Bunza on the way out of Lunpa with Hammet.
From the World Map the party comes in at the south end (metatile (10, 40)) into a round chamber, and goes north up a passage split by a column of rock. Further on, a green metal gate stands half raised across the way, with a puddle under it. Beyond the gate the cave runs on to Lunpa, whose passage leaves from the east (metatile (34, 21)).
Frost on the puddle under the gate, as the walkthrough says, freezes it into a tall ice pillar that pushes the gate up and opens the way. Two switches on the cave wall move the gate too. The one east of the gate, on the World Map side (metatile (24, 15)), drops it to the floor over the puddle; the one north of it, on the Lunpa side (metatile (21, 8)), raises it so the party can walk under. Each does nothing while the gate already stands where it would put it, and neither does anything once the ice pillar holds the gate up. Two more puddles freeze into ice pillars: one by the rocks on the first chamber's west side, and one in the passage north of the gate.
WEST_LUNPA_CAVE_FROM_LUNPA_UNUSED, which no exit names, repeats
WEST_LUNPA_CAVE_LUNPA with a shorter camera.
The gate and the pillars are kept in scene flags, which scInit redraws:
FLAG_WEST_LUNPA_CAVE_GATE_PUDDLE_FROZEN: the gate's puddle is frozen, propping the gate open.FLAG_WEST_LUNPA_CAVE_GATE_LOWERED: the lowering switch has lowered the gate.FLAG_WEST_LUNPA_CAVE_GATE_RAISED: the gate is raised.FLAG_WEST_LUNPA_CAVE_NORTH_PUDDLE_FROZEN: the north puddle is frozen.FLAG_WEST_LUNPA_CAVE_SOUTH_PUDDLE_FROZEN: the puddle in the first chamber is frozen into a pillar.
The reunion with Bunza, a Kalay merchant, plays here once
(FLAG_LUNPA_CAVE_REUNION_SEEN), after the party has brought Hammet out of
Lunpa Fortress (FLAG_DODONPA_LOCKED_UP). On the way back to the World Map, as
the party comes down the passage into the first chamber (metatile (11, 29)),
Bunza steps out further up the passage behind them and Hammet knows him
(scWestLunpaCaveHammetFindsBunza). They all talk in the first chamber
(scWestLunpaCaveHoldReunion), and Isaac's answers decide whether the party
rides home to Kalay in Bunza's wagon or stays behind
(scWestLunpaCaveAskAboutWagon).
Riding leaves by WEST_LUNPA_CAVE_BY_WAGON to WORLD_MAP_WEST_LUNPA_CAVE,
where world_map.c plays the departure. If the party stays, Hammet and Bunza
leave alone. Either way FLAG_BUNZAS_WAGON_LEFT is set, on the World Map or
here.
Unused: a fourth puddle is placed at the map's top-left corner, metatile (0,
0), where no part of the cave the screen shows reaches, so Frost can never be
cast on it (scWestLunpaCaveUnusedFreezePuddle).
Macros in detail
FLAG_WEST_LUNPA_CAVE_GATE_PUDDLE_FROZEN
#define FLAG_WEST_LUNPA_CAVE_GATE_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x00)
The gate's puddle is frozen into a pillar, propping the gate open.
Referenced by scInit(), scWestLunpaCaveFlipLoweringSwitch(), scWestLunpaCaveFlipRaisingSwitch() and scWestLunpaCaveFreezeGatePuddle().
Definition at line 226 of file west_lunpa_cave.c.
FLAG_WEST_LUNPA_CAVE_GATE_LOWERED
#define FLAG_WEST_LUNPA_CAVE_GATE_LOWERED FLAG_SCENE_TEMP(0x01)
The lowering switch has lowered the gate.
Referenced by scInit(), scWestLunpaCaveFlipLoweringSwitch() and scWestLunpaCaveFlipRaisingSwitch().
Definition at line 228 of file west_lunpa_cave.c.
FLAG_WEST_LUNPA_CAVE_GATE_RAISED
#define FLAG_WEST_LUNPA_CAVE_GATE_RAISED FLAG_SCENE_TEMP(0x02)
The gate is raised, by the raising switch or the ice pillar under it.
Referenced by scInit(), scWestLunpaCaveFlipLoweringSwitch(), scWestLunpaCaveFlipRaisingSwitch(), scWestLunpaCaveFreezeGatePuddle() and scWestLunpaCaveGateLower().
Definition at line 230 of file west_lunpa_cave.c.
FLAG_WEST_LUNPA_CAVE_NORTH_PUDDLE_FROZEN
#define FLAG_WEST_LUNPA_CAVE_NORTH_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x03)
The north puddle is frozen into a pillar.
Referenced by scInit() and scWestLunpaCaveFreezeNorthPuddle().
Definition at line 232 of file west_lunpa_cave.c.
FLAG_WEST_LUNPA_CAVE_SOUTH_PUDDLE_FROZEN
#define FLAG_WEST_LUNPA_CAVE_SOUTH_PUDDLE_FROZEN FLAG_SCENE_TEMP(0x04)
The puddle in the first chamber is frozen into a pillar.
Referenced by scInit() and scWestLunpaCaveFreezeSouthPuddle().
Definition at line 234 of file west_lunpa_cave.c.
Enumerations in detail
WEST_LUNPA_CAVE_METATILE_BEHAVIOR
enum WEST_LUNPA_CAVE_METATILE_BEHAVIOR
The metatiles the cave's cues answer: the two ways out, the two switches and the spot where Bunza is seen.
| Enumerator | Value | Description |
|---|---|---|
METATILE_BEHAVIOR_WEST_LUNPA_CAVE_WORLD_MAP_PASSAGE | 1 | |
METATILE_BEHAVIOR_WEST_LUNPA_CAVE_LUNPA_PASSAGE | 2 | |
METATILE_BEHAVIOR_WEST_LUNPA_CAVE_LOWERING_SWITCH | 3 | |
METATILE_BEHAVIOR_WEST_LUNPA_CAVE_RAISING_SWITCH | 4 | |
METATILE_BEHAVIOR_WEST_LUNPA_CAVE_BUNZA_HIDING_PLACE | 10 |
Definition at line 68 of file west_lunpa_cave.c.
WEST_LUNPA_CAVE_ACTOR_ID
enum WEST_LUNPA_CAVE_ACTOR_ID
The cave's actors, numbered in the order of WestLunpaCaveActorPlacements.
| Enumerator | Value | Description |
|---|---|---|
ACTOR_UNUSED_PUDDLE | ACTOR_FIRST_PLACED | Placed at the map's top-left corner, off every part of the cave the screen shows, so the player never sees it (scWestLunpaCaveUnusedFreezePuddle). |
ACTOR_SOUTH_PUDDLE | By the rocks on the first chamber's west side. | |
ACTOR_GATE_PUDDLE | Under the gate. | |
ACTOR_NORTH_PUDDLE | In the passage north of the gate. | |
ACTOR_BUNZA | ||
ACTOR_HAMMET |
Definition at line 78 of file west_lunpa_cave.c.
anonymous enum
enum { GATE_PILLAR_PRIORITY }
The sprite priority the gate's puddle takes once the gate has come down.
| Enumerator | Value | Description |
|---|---|---|
GATE_PILLAR_PRIORITY | 3 |
Definition at line 94 of file west_lunpa_cave.c.
SIGHTING_MESSAGE
enum SIGHTING_MESSAGE
The party's lines as Bunza steps out behind them
(scWestLunpaCaveHammetFindsBunza), in order.
| Enumerator | Value | Description |
|---|---|---|
SIGHTING_GARET_SAW_SOMEONE | ||
SIGHTING_MIA_SAW_SOMETHING | ||
SIGHTING_IVAN_ASKS_IF_FOUND | ||
SIGHTING_GARET_WILL_FIGHT | ||
SIGHTING_GARET_ASKS_WHAT_ELSE |
Definition at line 101 of file west_lunpa_cave.c.
RECOGNITION_MESSAGE
enum RECOGNITION_MESSAGE
Hammet and Bunza recognizing each other (scWestLunpaCaveHammetFindsBunza), in
order.
| Enumerator | Value | Description |
|---|---|---|
RECOGNITION_HAMMET_CALLS_OUT | ||
RECOGNITION_HAMMET_NAMES_BUNZA | ||
RECOGNITION_BUNZA_KNOWS_VOICE | ||
RECOGNITION_BUNZA_NAMES_HAMMET |
Definition at line 112 of file west_lunpa_cave.c.
REUNION_MESSAGE
enum REUNION_MESSAGE
The reunion's talk in the first chamber (scWestLunpaCaveHoldReunion), in
order.
| Enumerator | Value | Description |
|---|---|---|
REUNION_BUNZA_ASKS_ABOUT_RELEASE | ||
REUNION_HAMMET_CREDITS_IVAN | ||
REUNION_IVAN_CREDITS_LEADER | ||
REUNION_GARET_QUESTIONS_IVAN | ||
REUNION_IVAN_CREDITS_EVERYONE | ||
REUNION_HAMMET_THANKS_PARTY | ||
REUNION_HAMMET_THANKS_IVAN | ||
REUNION_MIA_PRAISES_BUNZA | ||
REUNION_HAMMET_PRAISES_BUNZA | ||
REUNION_BUNZA_CALLS_IT_CHANCE | ||
REUNION_BUNZA_AVOIDED_LUNPA | ||
REUNION_BUNZA_KNEW_OF_PRISON | ||
REUNION_GARET_ASKS_WHY_BUNZA_CAME | ||
REUNION_BUNZA_RECALLS_ADVICE | ||
REUNION_MIA_ASKS_ABOUT_TRADE | ||
REUNION_BUNZA_MEANS_WISDOM | ||
REUNION_HAMMET_ON_APPEARANCES | ||
REUNION_BUNZA_ON_UNPLEASANT_PLACES | ||
REUNION_HAMMET_ON_SELLING | ||
REUNION_IVAN_ASKS_ABOUT_SERVING | ||
REUNION_IVAN_ON_FATE | ||
REUNION_GARET_ASKS_ABOUT_ENTRY | ||
REUNION_BUNZA_WAS_REFUSED | ||
REUNION_MIA_ASKS_WHY_BUNZA_STILL_CAME | ||
REUNION_BUNZA_MENTIONS_COMMOTION | ||
REUNION_IVAN_EXPLAINS_COMMOTION | ||
REUNION_BUNZA_LINKS_COMMOTION | ||
REUNION_BUNZA_HAD_TO_KNOW | ||
REUNION_GARET_ASKS_ABOUT_CAVE | ||
REUNION_MIA_ON_GATE | ||
REUNION_BUNZA_HID | ||
REUNION_HAMMET_STARTLED_BUNZA | ||
REUNION_BUNZA_IS_GLAD | ||
REUNION_IVAN_ASKS_WHY | ||
REUNION_BUNZA_WARNS_OF_SEARCH | ||
REUNION_BUNZA_FEARS_CAPTURE | ||
REUNION_MIA_URGES_ESCAPE | ||
REUNION_IVAN_WANTS_STEALTH | ||
REUNION_GARET_ASKS_TO_FIGHT | ||
REUNION_BUNZA_DISCOURAGES_FIGHT | ||
REUNION_BUNZA_AGREES_NOT_TO_FIGHT |
Definition at line 122 of file west_lunpa_cave.c.
PLAN_MESSAGE
enum PLAN_MESSAGE
Hammet asking Bunza's plan, and Bunza's wagon to Kalay, in order.
| Enumerator | Value | Description |
|---|---|---|
PLAN_HAMMET_ASKS_PLAN | ||
PLAN_BUNZA_HAS_WAGON | ||
PLAN_MIA_ASKS_ABOUT_WAGON | ||
PLAN_BUNZA_OFFERS_RIDE | ||
PLAN_IVAN_DOUBTS_WAGON | ||
PLAN_BUNZA_REASSURES | ||
PLAN_GARET_AGREES | ||
PLAN_BUNZA_IS_UNSUSPECTED |
Definition at line 168 of file west_lunpa_cave.c.
WAGON_MESSAGE
enum WAGON_MESSAGE
The lines before the wagon question (scWestLunpaCaveAskAboutWagon).
| Enumerator | Value | Description |
|---|---|---|
WAGON_BUNZA_LEADS_THE_WAY | ||
WAGON_GARET_ASKS_TO_RIDE |
Definition at line 181 of file west_lunpa_cave.c.
CONFUSION_MESSAGE
enum CONFUSION_MESSAGE
Ivan, confused by Isaac's answers, and Garet asking the wagon question again.
| Enumerator | Value | Description |
|---|---|---|
CONFUSION_IVAN_IS_CONFUSED | ||
CONFUSION_GARET_ASKS_AGAIN |
Definition at line 188 of file west_lunpa_cave.c.
WARNING_MESSAGE
enum WARNING_MESSAGE
The lines of scWestLunpaCaveBunzaCannotWait.
| Enumerator | Value | Description |
|---|---|---|
WARNING_IVAN_ASKS_IF_STAYING | ||
WARNING_BUNZA_CANNOT_WAIT | ||
WARNING_MIA_ASKS_ABOUT_BUSINESS |
Definition at line 195 of file west_lunpa_cave.c.
FAREWELL_MESSAGE
enum FAREWELL_MESSAGE
The lines as the party stays behind (scWestLunpaCaveStayBehind).
| Enumerator | Value | Description |
|---|---|---|
FAREWELL_GARET_STAYS | ||
FAREWELL_MIA_STAYS | ||
FAREWELL_IVAN_STAYS | ||
FAREWELL_HAMMET_LETS_IVAN_GO | ||
FAREWELL_BUNZA_SAYS_GOODBYE | ||
FAREWELL_GARET_SIGHS | ||
FAREWELL_MIA_HOPES_FOR_SAFETY | ||
FAREWELL_IVAN_REASSURES | ||
FAREWELL_GARET_MOVES_ON |
Definition at line 203 of file west_lunpa_cave.c.
DEPARTURE_MESSAGE
enum DEPARTURE_MESSAGE
The lines as the party rides the wagon (scWestLunpaCaveRideWagon).
| Enumerator | Value | Description |
|---|---|---|
DEPARTURE_GARET_HEADS_FOR_KALAY | ||
DEPARTURE_IVAN_THINKS_OF_LAYANA | ||
DEPARTURE_HAMMET_LONGS_FOR_LAYANA | ||
DEPARTURE_BUNZA_SETS_OFF |
Definition at line 217 of file west_lunpa_cave.c.
Functions in detail
scWestLunpaCaveHoldReunion
static void scWestLunpaCaveHoldReunion(void)
The screen opens on everyone gathered in the first chamber. Bunza learns that Dodonpa never meant to free Hammet and that Ivan and his friends came to the rescue, tells how he came to be hiding in the cave, and offers them all a ride to Kalay in his wagon.
References fdActorFaceActor(), fdActorFaceDirection(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetAttachedEffect(), fdActorShowEmote(), fdActorStartRepeatedMotion(), fdActorTurnToFaceEachOther(), fdActorWaitForMoveById(), fdActorWalkTo(), fdCameraFollowActor(), fdMapGridCenterOnFollowedPoint(), fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptStartScreenTransition(), fdScriptWait(), fdScriptWaitTransitionTicks(), scWestLunpaCaveAskAboutWagon(), Sint32 and sySynch().
Referenced by scWestLunpaCaveHammetFindsBunza().
Definition at lines 236 and 579 of file west_lunpa_cave.c.
scWestLunpaCaveAskAboutWagon
static void scWestLunpaCaveAskAboutWagon(void)
Garet asks whether they should ride in the wagon too, and the questions go on until Isaac's answers settle it: the party rides to Kalay, or stays behind to finish its business in Lunpa (the walkthrough's No, Yes, Yes).
References fdActorFaceActor(), fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), scWestLunpaCaveBunzaAsksAboutUnfinishedBusiness(), scWestLunpaCaveBunzaCannotWait(), scWestLunpaCaveConfirmStaying(), scWestLunpaCaveGaretAsksAboutThingsToDo(), scWestLunpaCaveGaretAsksAboutUnfinishedBusiness(), scWestLunpaCaveGaretAsksIfNotRiding(), scWestLunpaCaveGaretChecksNothingLeftToDo(), scWestLunpaCaveLeaderAnswersYes(), scWestLunpaCaveMiaAsksIfRidingAfterAll(), scWestLunpaCaveRideWagon(), scWestLunpaCaveStayBehind() and Sint32.
Referenced by scWestLunpaCaveHoldReunion().
Definition at lines 237 and 881 of file west_lunpa_cave.c.
scWestLunpaCaveLeaderAnswersYes
static Uint8 scWestLunpaCaveLeaderAnswersYes(void)
The yes-or-no menu answers 0 for Yes; this turns that into true or false.
References fdScriptAskYesNoWithActorAnimation().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 238 and 954 of file west_lunpa_cave.c.
scWestLunpaCaveGaretAsksIfNotRiding
static Uint8 scWestLunpaCaveGaretAsksIfNotRiding(void)
Garet asks, "Huh? You don't want to ride in Bunza's wagon?"
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 239 and 960 of file west_lunpa_cave.c.
scWestLunpaCaveGaretAsksAboutUnfinishedBusiness
static Uint8 scWestLunpaCaveGaretAsksAboutUnfinishedBusiness(void)
Garet asks, "Do you have some unfinished business in Lunpa?"
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 240 and 969 of file west_lunpa_cave.c.
scWestLunpaCaveConfirmStaying
static Uint8 scWestLunpaCaveConfirmStaying(void)
A step before the party stays that shows nothing and always agrees.
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 241 and 978 of file west_lunpa_cave.c.
scWestLunpaCaveBunzaAsksAboutUnfinishedBusiness
static Uint8 scWestLunpaCaveBunzaAsksAboutUnfinishedBusiness(void)
Bunza asks, "Do you have any unfinished business?"
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 242 and 984 of file west_lunpa_cave.c.
scWestLunpaCaveGaretChecksNothingLeftToDo
static Uint8 scWestLunpaCaveGaretChecksNothingLeftToDo(void)
Garet asks, "Don't startle me! You don't have anything left to do, do you?"
scWestLunpaCaveAskAboutWagon takes the answer.
References fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 243 and 994 of file west_lunpa_cave.c.
scWestLunpaCaveMiaAsksIfRidingAfterAll
static Uint8 scWestLunpaCaveMiaAsksIfRidingAfterAll(void)
Mia asks, "So, what? You've changed your mind? You do want to go with them?"
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 244 and 1003 of file west_lunpa_cave.c.
scWestLunpaCaveBunzaCannotWait
static Uint8 scWestLunpaCaveBunzaCannotWait(void)
Ivan winces: so they won't ride in the wagon? Bunza shakes his head, he cannot safely wait any longer, and Mia asks whether they mean to stay and finish their business.
References fdActorFaceActor(), fdActorFaceDirection(), fdActorSetAnimationAndWait(), fdActorShowEmote(), fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptWait() and Sint32.
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 245 and 1014 of file west_lunpa_cave.c.
scWestLunpaCaveGaretAsksAboutThingsToDo
static Uint8 scWestLunpaCaveGaretAsksAboutThingsToDo(void)
Garet asks, "Are you saying you still have some things to do here in Lunpa?"
References fdScriptAskYesNoWithActorAnimation(), fdScriptOpenMessage() and fdScriptSetMessageId().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 246 and 1035 of file west_lunpa_cave.c.
scWestLunpaCaveStayBehind
static void scWestLunpaCaveStayBehind(void)
The party stays: Garet, Mia and Ivan each say they'll stay with Isaac, Hammet lets Ivan go, and Hammet and Bunza walk off south out of the cave. The others sigh after them, hope they reach Kalay safely, and fall in behind Isaac again.
References fdActorFaceActor(), fdActorFaceDirection(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetDestinationOffset(), fdActorShowEmote(), fdActorWaitForMoveById(), fdActorWalkTo(), fdCameraFollowActor(), fdCameraMoveToActorById(), fdCameraWaitForArrival(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptWait(), gmFlagSet(), scWalkIntoLeader() and Sint32.
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 247 and 1047 of file west_lunpa_cave.c.
scWestLunpaCaveRideWagon
static void scWestLunpaCaveRideWagon(void)
The party rides: Garet says on to Kalay, Ivan and Hammet look forward to seeing Lady Layana, and everyone walks out of the cave to the south, where the World Map plays the wagon's departure.
References fdActorFaceActor(), fdActorFaceDirection(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetDestinationOffset(), fdActorWaitForMoveById(), fdActorWalkTo(), fdCameraMoveToActorById(), fdScriptFinishScreenTransition(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptWait(), scWalkIntoLeader(), Sint32 and syImportScriptSetExitRequest().
Referenced by scWestLunpaCaveAskAboutWagon().
Definition at lines 248 and 1137 of file west_lunpa_cave.c.
scGetEntrances
const SCENE_ENTRANCE *scGetEntrances(void)
References WestLunpaCaveEntrances.
Definition at line 250 of file west_lunpa_cave.c.
scGetExitRegions
const SCENE_EXIT_REGION *scGetExitRegions(void)
Definition at line 255 of file west_lunpa_cave.c.
scGetExits
const Uint32 *scGetExits(void)
The ways out: to the World Map, to Lunpa, and away in Bunza's wagon.
References WestLunpaCaveExits.
Definition at line 261 of file west_lunpa_cave.c.
scGetActorPlacements
const ACTOR_PLACE *scGetActorPlacements(void)
The puddles, and Bunza, Hammet and the party for the reunion, kept off the stage until it plays.
References MainRoutineStateWork, WestLunpaCaveActorPlacements and WestLunpaCaveNoActorPlacements.
Definition at line 268 of file west_lunpa_cave.c.
scGetCues
const CUE *scGetCues(void)
The cave's scripts: its ways out, the two switches, Frost on each puddle and the spot where Bunza is seen.
References WestLunpaCaveCues.
Definition at line 279 of file west_lunpa_cave.c.
scWestLunpaCaveUnusedFreezePuddle
static void scWestLunpaCaveUnusedFreezePuddle(void)
Unused: Frost on the fourth puddle, at the map's top-left corner (metatile (0, 0)) where the screen never goes, would freeze it, and no flag would remember it. The player can never cast it there.
References fdActorGet() and fdActorSetSpriteFlags().
Referenced by WestLunpaCaveCues.
Definition at line 287 of file west_lunpa_cave.c.
scWestLunpaCaveFreezeSouthPuddle
static void scWestLunpaCaveFreezeSouthPuddle(void)
Frost on the puddle by the rocks on the first chamber's west side (metatile (8, 32)) freezes it into a tall ice pillar against the wall. It only stands in the way: walking into it from the east, Isaac stops beside it and does not climb onto it.
References fdActorGet(), fdMapGridCopyMetatileAttributes() and gmFlagSet().
Referenced by WestLunpaCaveCues.
Definition at line 302 of file west_lunpa_cave.c.
scWestLunpaCaveGateDrawPropped
static void scWestLunpaCaveGateDrawPropped(void)
The gate rises onto the ice pillar under it in steps of four ticks and stays up, and the way under it opens.
References fdActorGet(), fdActorSetAnimation(), fdActorSetSpriteFlags(), fdMapGridCopyMetatileAttributes(), fdMapGridCopyMetatiles() and sySynch().
Referenced by scInit() and scWestLunpaCaveFreezeGatePuddle().
Definition at line 321 of file west_lunpa_cave.c.
scWestLunpaCaveFreezeGatePuddle
static void scWestLunpaCaveFreezeGatePuddle(void)
Frost on the puddle under the half-raised gate (metatile (21, 15)) freezes it into a tall ice pillar. Unless the gate is already raised, the pillar pushes it up and the puzzle-solved tune plays: the way on is open.
References fdActorGet(), fdActorSetSpriteFlags(), fdScriptGetFlag(), gmFlagSet(), scWestLunpaCaveGateDrawPropped() and sySoundPlay().
Referenced by WestLunpaCaveCues.
Definition at line 349 of file west_lunpa_cave.c.
scWestLunpaCaveFreezeNorthPuddle
static void scWestLunpaCaveFreezeNorthPuddle(void)
Frost on the puddle in the passage north of the gate, east of the raising switch (metatile (26, 8)), freezes it into a tall ice pillar, which is still there when the party comes back.
References gmFlagSet().
Referenced by WestLunpaCaveCues.
Definition at line 372 of file west_lunpa_cave.c.
scWestLunpaCaveGateLower
static void scWestLunpaCaveGateLower(void)
The gate drops to the floor in steps of four ticks, over the puddle, and the way under it is shut.
References fdActorSetSpritePriority(), fdMapGridCopyMetatileAttributes(), fdMapGridCopyMetatiles(), gmFlagGet() and sySynch().
Referenced by scInit() and scWestLunpaCaveFlipLoweringSwitch().
Definition at line 379 of file west_lunpa_cave.c.
scWestLunpaCaveFlipLoweringSwitch
static void scWestLunpaCaveFlipLoweringSwitch(void)
Isaac flips the switch on the wall east of the gate, on the World Map side (metatile (24, 15)): "Isaac flipped the switch." The gate drops to the floor, covering the puddle. Nothing happens while the gate is already down or the ice pillar holds it up.
References fdScriptGetFlag(), gmFlagClear(), gmFlagGet(), gmFlagSet(), mnFieldMessageShow(), scWestLunpaCaveGateLower() and sySoundPlay().
Referenced by WestLunpaCaveCues.
Definition at line 408 of file west_lunpa_cave.c.
scWestLunpaCaveGateRaise
static void scWestLunpaCaveGateRaise(void)
The gate rises clear in steps of four ticks, and the way under it opens.
References fdMapGridCopyMetatileAttributes(), fdMapGridCopyMetatiles() and sySynch().
Referenced by scInit() and scWestLunpaCaveFlipRaisingSwitch().
Definition at line 424 of file west_lunpa_cave.c.
scWestLunpaCaveFlipRaisingSwitch
static void scWestLunpaCaveFlipRaisingSwitch(void)
Isaac flips the switch on the wall north of the gate, on the Lunpa side (metatile (21, 8)): "Isaac flipped the switch." The gate rises so the party can walk under it. Nothing happens while the gate is already raised or the ice pillar holds it up.
References fdScriptGetFlag(), gmFlagClear(), gmFlagGet(), gmFlagSet(), mnFieldMessageShow(), scWestLunpaCaveGateRaise() and sySoundPlay().
Referenced by WestLunpaCaveCues.
Definition at line 443 of file west_lunpa_cave.c.
scWestLunpaCaveHammetFindsBunza
static void scWestLunpaCaveHammetFindsBunza(void)
On the way out of Lunpa with Hammet, as the party comes down the passage into the first chamber (metatile (11, 29)), Bunza steps out further up the passage behind them. Garet and Mia saw someone, and Ivan asks whether Dodonpa's henchmen have found them. Whatever Isaac answers, Hammet calls out, "Is that you, Bunza?", and Bunza knows his voice: "It's Hammet!" The screen closes for the talk that follows.
References fdActorFaceActor(), fdActorFaceDirection(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorShowEmote(), fdActorStartRepeatedMotion(), fdActorWaitForMoveById(), fdActorWalkBy(), fdActorWalkTo(), fdScriptAskYesNoWithActorAnimation(), fdScriptEnd(), fdScriptFinishScreenTransition(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptWait(), fdScriptWaitTransitionTicks(), gmFlagGet(), gmFlagSet(), scPlaceAtLeader(), scWestLunpaCaveHoldReunion() and Sint32.
Referenced by WestLunpaCaveCues.
Definition at line 464 of file west_lunpa_cave.c.
scInit
Sint32 scInit(void)
Draws the gate and the ice pillars as the party left them.
References fdActorGet(), fdActorSetAnimation(), fdActorSetSpriteFlags(), gmFlagGet(), MainRoutineStateWork, scWestLunpaCaveGateDrawPropped(), scWestLunpaCaveGateLower(), scWestLunpaCaveGateRaise() and Sint32.
Definition at line 1210 of file west_lunpa_cave.c.
Variables in detail
WestLunpaCaveEntrances
extern const SCENE_ENTRANCE WestLunpaCaveEntrances[]
const SCENE_ENTRANCE WestLunpaCaveEntrances[]
Referenced by scGetEntrances().
Definition at lines 60 and 1246 of file west_lunpa_cave.c.
WestLunpaCaveExits
extern const Uint32 WestLunpaCaveExits[]
const Uint32 WestLunpaCaveExits[]
Referenced by scGetExits().
Definition at lines 61 and 1257 of file west_lunpa_cave.c.
WestLunpaCaveNoActorPlacements
extern const ACTOR_PLACE WestLunpaCaveNoActorPlacements[]
const ACTOR_PLACE WestLunpaCaveNoActorPlacements[]
Referenced by scGetActorPlacements().
Definition at lines 62 and 1265 of file west_lunpa_cave.c.
WestLunpaCaveActorPlacements
extern const ACTOR_PLACE WestLunpaCaveActorPlacements[]
const ACTOR_PLACE WestLunpaCaveActorPlacements[]
Referenced by scGetActorPlacements().
Definition at lines 63 and 1269 of file west_lunpa_cave.c.
WestLunpaCaveCues
extern const CUE WestLunpaCaveCues[]
const CUE WestLunpaCaveCues[]
References scWestLunpaCaveFlipLoweringSwitch(), scWestLunpaCaveFlipRaisingSwitch(), scWestLunpaCaveFreezeGatePuddle(), scWestLunpaCaveFreezeNorthPuddle(), scWestLunpaCaveFreezeSouthPuddle(), scWestLunpaCaveHammetFindsBunza() and scWestLunpaCaveUnusedFreezePuddle().
Referenced by scGetCues().
Definition at lines 64 and 1296 of file west_lunpa_cave.c.
WestLunpaCaveNoCues
const CUE WestLunpaCaveNoCues[]
Unused: an empty cue table nothing returns.
Definition at line 1292 of file west_lunpa_cave.c.