src/scene/mercury_lighthouse.c
The base of Mercury Lighthouse in Imil, near the end of the game: as the last beacon, Mars Lighthouse's, is lit, two of Imil's children hear the voices of the heroes far away, glints of light rising round them.
#include "field/script_inline.h"#include "game/game.h"#include "field/field_sprite.h"#include "field/actor_script.h"#include "field/field_engine.h"#include "field/field_engine_script.h"#include "scene/scene.h"#include "text/msg_ids.h"#include "macros.h"#include "shared/scene_entrances_default.c"
Enumerations
| Name | Description | |
|---|---|---|
enum | anonymous enum { ENTRANCE_UNUSED_WHITE_FADE, EXIT_BACK_TO_THE_VOICES } | |
enum | anonymous enum { ACTOR_BOY, ACTOR_GIRL, ACTOR_WOMAN, ACTOR_OLD_MAN, ACTOR_OLD … } | The actors at the lighthouse, by the rows of ActorPlacements; Mia's, Garet's and Sheba's rows go to their party slots. |
Functions
| Name | Description | |
|---|---|---|
void | scMercuryLighthouseHearVoices (void) | As the Mars beacon is lit, two children of Imil at the base of Mercury Lighthouse hear Mia and her friends far away, each of their lines carried on a Mind Read wave, until Sheba knows who sent the children there: "The... |
Sint32 | scMercuryLighthouseFlickerGlint (ACTOR *actor) | A glint's script call: it flickers, hidden and white by turns every two ticks. |
void | scMercuryLighthouseLookAround (ACTOR *actor) | An Imil villager's update while the voices talk: every 40 to 120 ticks it turns between two headings, as if looking around for them. |
const SCENE_ENTRANCE * | scGetEntrances (void) | Where the party can enter: the cave under the spring has its own entrances. |
const SCENE_REGION * | scGetExitRegions (void) | The regions of the rooms whose exits are rectangles: the Chestbeaters' room and the stream room. |
const Uint32 * | scGetExits (void) | The dock's ways lead back the way the party came into Lemuria, which the harbour and the shore of Ancient Lemuria note in FLAG_LEMURIA_OTHER_WAY_IN. |
const ACTOR_PLACE * | scGetActorPlacements (void) | The scene's actor placements: a room of names for its entrance, else the debug room's. |
const CUE * | scGetCues (void) | The scene's cues: the rooms of names' for any entrance above ENTRANCE_NAMES_ABOVE, else the debug room's. |
void | scMercuryLighthouseSpawnGlints (void) | The event scMercuryLighthouseHearVoices starts: every 16 ticks it starts a flickering glint (SPRITE_GLINT) at a random spot in front of the lighthouse, and it counts the ticks in MercuryLighthouseGlintTicks. |
Sint32 | scInit (void) | Opens the room through the window transition, and in the debug room draws the cat 1.7 times its size. |
Sint32 | scPrepareMap (void) | Once Briggs is caught the pool has dried up: its colours take the dry ground's. |
Variables
| Name | Description | |
|---|---|---|
extern Sint32 | MercuryLighthouseGlintScript [] | |
Uint32 | MercuryLighthouseGlintTicks | |
Uint32 | SceneExits [] | The room has no exits of its own. |
ACTOR_PLACE | ActorPlacements [] | The room's people: the party's four rows, then PSYNERGY_TEST_ACTOR_ID's. |
CUE | SceneCues [] | The room's scripts: talking to its people, Mind Read on them, the metatiles examined, and the field Psynergy each spot answers. |
Description
The base of Mercury Lighthouse in Imil, near the end of the game: as the last beacon, Mars Lighthouse's, is lit, two of Imil's children hear the voices of the heroes far away, glints of light rising round them.
Enumerations in detail
anonymous enum
enum { ENTRANCE_UNUSED_WHITE_FADE, EXIT_BACK_TO_THE_VOICES }
| Enumerator | Value | Description |
|---|---|---|
ENTRANCE_UNUSED_WHITE_FADE | 12 | Unused: an entrance no exit leads to, which the map does not have. By it the screen fades to white to SE_ASCEND, as the Mars Lighthouse aerie does before it sends the party here, and the party comes in again by EXIT_BACK_TO_THE_VOICES. |
EXIT_BACK_TO_THE_VOICES | 9 | Back into this scene by the entrance where the voices begin. |
Definition at line 20 of file mercury_lighthouse.c.
anonymous enum
enum { ACTOR_BOY, ACTOR_GIRL, ACTOR_WOMAN, ACTOR_OLD_MAN, … }
The actors at the lighthouse, by the rows of ActorPlacements; Mia's, Garet's
and Sheba's rows go to their party slots.
| Enumerator | Value | Description |
|---|---|---|
ACTOR_BOY | ACTOR_FIRST_PLACED | Two of Imil's children, who hear the |
ACTOR_GIRL | party: "Hey! I know that voice! It's Mia, I just know it!" and "Of course it's us! We can hear you, Mia!" | |
ACTOR_WOMAN | Placed at the map's corner, out of sight; nothing uses her. | |
ACTOR_OLD_MAN | "I don't know. They've been standing here telling everyone to leave..." | |
ACTOR_OLD_WOMAN | "Who are those two kids talking to?" | |
ACTOR_VOICES_SOURCE | Two unseen actors the voices' Mind Read | |
ACTOR_VOICES_TARGET | wave runs between. |
Definition at line 106 of file mercury_lighthouse.c.
Functions in detail
scMercuryLighthouseHearVoices
void scMercuryLighthouseHearVoices(void)
As the Mars beacon is lit, two children of Imil at the base of Mercury Lighthouse hear Mia and her friends far away, each of their lines carried on a Mind Read wave, until Sheba knows who sent the children there: "The... The Wise One!" The party then returns to the aerie, its beacon burning.
References fdActorFaceDirection(), fdActorFaceDirectionAndWait(), fdActorGetById(), fdActorJump(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetSpritePriority(), fdActorShowEmote(), fdPsynergyStartMindReadWave(), fdPsynergyStopMindReadWave(), fdScriptEndLastingPsynergy(), fdScriptFinishScreenTransition(), fdScriptSetFlag(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptStartScreenTransition(), fdScriptWait(), fdScriptWaitTransitionTicks(), MainRoutineStateWork, MercuryLighthouseGlintTicks, scFieldActorSetSpriteColor(), scFieldActorShowEmote(), scFieldScriptSetExitRequest(), scMercuryLighthouseLookAround(), scMercuryLighthouseSpawnGlints(), sySetEvent() and sySynch().
Referenced by scInit().
Definition at lines 15 and 161 of file mercury_lighthouse.c.
scMercuryLighthouseFlickerGlint
Sint32 scMercuryLighthouseFlickerGlint(ACTOR *actor)
A glint's script call: it flickers, hidden and white by turns every two ticks.
References MercuryLighthouseGlintTicks, scFieldActorSetSpriteColor() and Sint32.
Referenced by MercuryLighthouseGlintScript.
Definition at line 35 of file mercury_lighthouse.c.
scMercuryLighthouseLookAround
void scMercuryLighthouseLookAround(ACTOR *actor)
An Imil villager's update while the voices talk: every 40 to 120 ticks it turns between two headings, as if looking around for them.
Referenced by scMercuryLighthouseHearVoices().
Definition at line 46 of file mercury_lighthouse.c.
scGetEntrances
const SCENE_ENTRANCE *scGetEntrances(void)
References SceneEntrances.
Definition at line 79 of file mercury_lighthouse.c.
scGetExitRegions
const SCENE_REGION *scGetExitRegions(void)
Definition at line 84 of file mercury_lighthouse.c.
scGetExits
const Uint32 *scGetExits(void)
References SceneExits.
Definition at line 89 of file mercury_lighthouse.c.
scGetActorPlacements
const ACTOR_PLACE *scGetActorPlacements(void)
References ActorPlacements.
Definition at line 94 of file mercury_lighthouse.c.
scGetCues
const CUE *scGetCues(void)
References SceneCues.
Definition at line 99 of file mercury_lighthouse.c.
scMercuryLighthouseSpawnGlints
void scMercuryLighthouseSpawnGlints(void)
The event scMercuryLighthouseHearVoices starts: every 16 ticks it starts a
flickering glint (SPRITE_GLINT) at a random spot in front of the lighthouse,
and it counts the ticks in MercuryLighthouseGlintTicks.
References fdActorGetById(), fdActorSelectAnimation(), fdActorSetSpriteFlags(), fdActorSetSpritePriority(), fdActorStartScript(), MainRoutineStateWork, MercuryLighthouseGlintScript, MercuryLighthouseGlintTicks, syImportActorCreate(), syRandom() and TickCount.
Referenced by scMercuryLighthouseHearVoices().
Definition at line 126 of file mercury_lighthouse.c.
scInit
Sint32 scInit(void)
References fdPaletteFadeSetTarget(), fdPaletteFadeStartInterpolation(), fdScriptEndLastingPsynergy(), fdScriptPlaySound(), fdScriptStart(), fdScriptStartScreenTransition(), fdScriptWaitTransitionTicks(), MainRoutineStateWork, scFieldScriptSetExitRequest(), scMercuryLighthouseHearVoices(), Sint32 and sySynch().
Definition at line 286 of file mercury_lighthouse.c.
scPrepareMap
Sint32 scPrepareMap(void)
References Sint32.
Definition at line 307 of file mercury_lighthouse.c.
Variables in detail
MercuryLighthouseGlintScript
extern Sint32 MercuryLighthouseGlintScript[]
Sint32 MercuryLighthouseGlintScript[]
References scMercuryLighthouseFlickerGlint() and Sint32.
Referenced by scMercuryLighthouseSpawnGlints().
Definition at lines 17 and 312 of file mercury_lighthouse.c.
MercuryLighthouseGlintTicks
Uint32 MercuryLighthouseGlintTicks
Referenced by scMercuryLighthouseFlickerGlint(), scMercuryLighthouseHearVoices() and scMercuryLighthouseSpawnGlints().
Definition at line 18 of file mercury_lighthouse.c.
SceneExits
Uint32 SceneExits[]
Referenced by scGetExits().
Definition at line 330 of file mercury_lighthouse.c.
ActorPlacements
ACTOR_PLACE ActorPlacements[]
Referenced by scGetActorPlacements().
Definition at line 345 of file mercury_lighthouse.c.
SceneCues
CUE SceneCues[]
Referenced by scGetCues().
Definition at line 370 of file mercury_lighthouse.c.