Skip to Content
The Alchemy Project

src/scene/lemuria_rooms.c

The rooms behind Lemuria's doors (SceneIdLemuriaRooms). More…

Macros

NameDescription
#defineFLAG_PIERS_VISITED_UNCLE 0x965Set once Piers has come home to his uncle (scLemuriaRoomsPiersVisitsUncle).
#defineFLAG_MIND_READ_NOTICED 0x967Set once a senator has felt Mind Read: "Was that some form of Psynergy?"
#defineROOM_WINDOW_TRANSITIONHow the rooms open: the Japanese edition opens them through a shape, the others from around the leader.
#defineBIRD_FLIGHT_TICKS 192Ticks of each of the bird's two loops round the room.

Enumerations

NameDescription
enumLEMURIA_ROOMS_ACTOR_ID { ACTOR_GIRL_WHO_NEVER_LEFT, ACTOR_WOMAN_AWAITING_PIERS_TALES, … }The placed actors, numbering the rows of ActorPlacements from ACTOR_FIRST_PLACED; the rows for Jenna, Sheba and Piers go to their party slots.
enumLEMURIA_ROOMS_METATILE_BEHAVIOR { METATILE_BEHAVIOR_UNCLES_DOORWAY, METATILE_BEHAVIOR_FOOT_OF_ … }The metatile behaviors the rooms' step and examine cues answer.
enumLEMURIA_ROOMS_WAY { WAY_HALL_WEST_ARCH, WAY_HALL_EAST_ARCH, WAY_WEST_BACK_ROOM, … }The ways between the rooms, each an exit and the entrance beside it, in pairs: each way leads to its partner's entrance and back.
enumanonymous enum { ANIM_WHITE_BIRD_PERCH, ANIM_WHITE_BIRD_FLAP }SPRITE_WHITE_BIRD's own animations: standing, now and then stirring, and beating its spread wings.

Functions

NameDescription
voidscLemuriaRoomsPiersVisitsUncle (void)Piers comes home to his uncle, who is relieved to find him alive, and learns that his mother has died; he runs out to her grave.
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.
voidscLemuriaRoomsTalkToPiersUncle (Sint32 actorId)Piers's uncle asks whether the party came with Piers, then, once Piers has visited him, is relieved Piers is alive, and later sends the party to Lunpa's tower.
voidscLemuriaRoomsMindReadPiersUncle (Sint32 unused, Sint32 id)Mind Read on Piers's uncle: his thoughts follow how far Piers's homecoming has gone.
voidscLemuriaRoomsAskFromBeyondSeaOfTime (Sint32 actorId)In the hall of the House of the Senate, an old senator asks whether the party came from beyond the Sea of Time, and scorns either answer.
voidscLemuriaRoomsAskAboutDraughts (Sint32 actorId)In a room behind the Senate hall's arches, a senator offers to tell of the draughts that kept Lemurians long-lived, and tells of them either way.
voidscLemuriaRoomsNoticeMindRead (Sint32 unused, Sint32 actorId)The first senator Mind Read touches turns on the party, asks whether that was Psynergy, and laughs it off: Lemurians are masters of Psynergy.
const CUE *scGetCues (void)The scene's cues: the rooms of names' for any entrance above ENTRANCE_NAMES_ABOVE, else the debug room's.
Sint32scInit (void)Sets the rooms up: once Piers is at his mother's grave his uncle stands where he sent his bird from, and once Lunpa has gone to the king his tower is empty.
Sint32scPrepareMap (void)Once Briggs is caught the pool has dried up: its colours take the dry ground's.
voidscLemuriaRoomsLeavePiersToMourn (void)Once Piers has gone to his mother's grave, his uncle stops the party on its way out, asks it to leave Piers to his mourning, tells of the mission the king gave Piers, and sends his bird with a letter so that Lunpa will see the party.
voidscLemuriaRoomsMeetLunpa (void)Lunpa comes to meet the party in his tower and asks after Piers, learns from Kraden that his old friend Babi has died and that his grandson Dodonpa rules the village he settled, hears Kraden's theory of the world's decay, and bursts his stuck door open to take the party to the king.

Variables

NameDescription
extern SCENE_REGIONSceneRegions []The tower's ways between floors: the top of the stairs in the room below, and the ladder down through the floor of the room above.
extern Uint32QuestionMarkScript []The script each "?" bubble runs: it is released once its ticks are up.
Uint32SceneExits []The room has no exits of its own.
ACTOR_PLACEActorPlacements []The room's people: the party's four rows, then PSYNERGY_TEST_ACTOR_ID's.
CUESceneCues []The ways out, the steps that start Piers's uncle's letter and Lunpa's talk, the people talked to and read, and the bookcases.

Description

The rooms behind Lemuria's doors (SceneIdLemuriaRooms). In the west of the city are Piers's uncle's house, where Piers comes home to learn that his mother has died and his uncle sends a bird to Lunpa with a letter; the house of a girl who has never left Lemuria; and the House of the Senate, whose hall and two back rooms hold the senators who would keep Alchemy sealed. In the east is Lunpa's tower, three rooms one above another, each with its own door to the city, joined by stairs and a ladder: in the bottom one, among his books, Lunpa hears the party out and bursts his stuck door open to take it to the king.

Macros in detail

FLAG_PIERS_VISITED_UNCLE

#define FLAG_PIERS_VISITED_UNCLE 0x965

Set once Piers has come home to his uncle (scLemuriaRoomsPiersVisitsUncle).

Referenced by scLemuriaRoomsLeavePiersToMourn(), scLemuriaRoomsMindReadPiersUncle(), scLemuriaRoomsPiersVisitsUncle() and scLemuriaRoomsTalkToPiersUncle().

Definition at line 22 of file lemuria_rooms.c.

FLAG_MIND_READ_NOTICED

#define FLAG_MIND_READ_NOTICED 0x967

Set once a senator has felt Mind Read: "Was that some form of Psynergy?"

Referenced by SceneCues and scLemuriaRoomsNoticeMindRead().

Definition at line 24 of file lemuria_rooms.c.

ROOM_WINDOW_TRANSITION

#define ROOM_WINDOW_TRANSITION

How the rooms open: the Japanese edition opens them through a shape, the others from around the leader.

Referenced by scInit().

Definition at line 118 of file lemuria_rooms.c.

BIRD_FLIGHT_TICKS

#define BIRD_FLIGHT_TICKS 192

Ticks of each of the bird's two loops round the room.

Referenced by scLemuriaRoomsLeavePiersToMourn().

Definition at line 590 of file lemuria_rooms.c.

Enumerations in detail

LEMURIA_ROOMS_ACTOR_ID

enum LEMURIA_ROOMS_ACTOR_ID

The placed actors, numbering the rows of ActorPlacements from ACTOR_FIRST_PLACED; the rows for Jenna, Sheba and Piers go to their party slots.

EnumeratorValueDescription
ACTOR_GIRL_WHO_NEVER_LEFTACTOR_FIRST_PLACED"I have never been outside of Lemuria."
ACTOR_WOMAN_AWAITING_PIERS_TALES"Now that Piers has returned, maybe he'll share his tales of the outside world with me."
ACTOR_PIERS_UNCLE"Piers! You are alive!"
ACTOR_BIRDThe uncle's white bird,
ACTOR_KRADENwhich carries his letter to Lunpa: "All I need is a bird to carry it to him in his tower."
ACTOR_OLD_MAN_ASKING_OF_THE_OUTSIDEThe senators, who hold to the sealing of Alchemy. "Are you the warriors from beyond the Sea of Time...?"
ACTOR_OLD_MAN_ON_ALCHEMYS_ABUSE"Long ago, the power of Alchemy was abused..."
ACTOR_OLD_MAN_ON_THE_RUMORS"And now, rumors abound of a group of fools..."
ACTOR_OLD_MAN_AGAINST_ALCHEMY"Come what may, I cannot approve of anyone setting Alchemy loose..."
ACTOR_OLD_MAN_DENYING_DECAY"Has Lemuria fallen into decay, I ask you!? Nay!"
ACTOR_LUNPA"But... Aren't you Lunpa, the Righteous Thief?"
ACTOR_OLD_MAN_ON_THE_DRAUGHTS"Do you seek to know more about the draughts...?"

Definition at line 29 of file lemuria_rooms.c.

LEMURIA_ROOMS_METATILE_BEHAVIOR

enum LEMURIA_ROOMS_METATILE_BEHAVIOR

The metatile behaviors the rooms' step and examine cues answer.

EnumeratorValueDescription
METATILE_BEHAVIOR_UNCLES_DOORWAY30Inside the door of Piers's uncle's house, where his uncle stops the party on its way out (scLemuriaRoomsLeavePiersToMourn).
METATILE_BEHAVIOR_FOOT_OF_LUNPAS_STAIRS31The foot of the stairs in Lunpa's tower, where Lunpa comes to meet the party (scLemuriaRoomsMeetLunpa).
METATILE_BEHAVIOR_GREAT_ADVENTURES_OF_LUNPA200The bookcases, by the book each holds, and the wardrobe of bathrobes.
METATILE_BEHAVIOR_LETTER_FROM_BABI
METATILE_BEHAVIOR_HISTORY_OF_LEMURIA
METATILE_BEHAVIOR_ELEMENTAL_LIGHTHOUSES
METATILE_BEHAVIOR_GREAT_LEMURIAN_PEOPLE
METATILE_BEHAVIOR_ALCHEMY_PART_I
METATILE_BEHAVIOR_ALCHEMY_PART_II
METATILE_BEHAVIOR_DIARY_OF_HYDROS
METATILE_BEHAVIOR_BATHROBES

Definition at line 65 of file lemuria_rooms.c.

LEMURIA_ROOMS_WAY

enum LEMURIA_ROOMS_WAY

The ways between the rooms, each an exit and the entrance beside it, in pairs: each way leads to its partner's entrance and back.

EnumeratorValueDescription
WAY_HALL_WEST_ARCH4To the senators' west back room.
WAY_HALL_EAST_ARCH5To the senators' east back room.
WAY_WEST_BACK_ROOM6To the hall's west arch.
WAY_EAST_BACK_ROOM7To the hall's east arch.
WAY_LUNPAS_STAIRS_WEST8The top of the stairs in Lunpa's room, its
WAY_LUNPAS_STAIRS_EAST9west and east halves, up to the tower's middle room.
WAY_MIDDLE_ROOM_WEST10Either side of the stairwell in the middle
WAY_MIDDLE_ROOM_EAST11room, down to Lunpa's.
WAY_MIDDLE_ROOM_STAIRS13The top of the middle room's stairs, up to the top room (SceneRegions).
WAY_TOP_ROOM_LADDER14The ladder down through the top room's floor (SceneRegions).

Definition at line 89 of file lemuria_rooms.c.

anonymous enum

enum { ANIM_WHITE_BIRD_PERCH, ANIM_WHITE_BIRD_FLAP }

SPRITE_WHITE_BIRD's own animations: standing, now and then stirring, and beating its spread wings.

EnumeratorValueDescription
ANIM_WHITE_BIRD_PERCH1
ANIM_WHITE_BIRD_FLAP3

Definition at line 110 of file lemuria_rooms.c.

Functions in detail

scLemuriaRoomsPiersVisitsUncle

void scLemuriaRoomsPiersVisitsUncle(void)

Piers comes home to his uncle, who is relieved to find him alive, and learns that his mother has died; he runs out to her grave.

References fdActorFaceDirection(), fdActorGetById(), fdActorJump(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetAttachedEffect(), fdActorSetDestination(), fdActorShowEmote(), fdActorStartRepeatedMotion(), fdActorStop(), fdActorWaitForMoveById(), fdActorWalkByAndWait(), fdActorWalkToAndWait(), fdActorWatchAndSetScript(), fdScriptEnd(), fdScriptEndLastingPsynergy(), fdScriptOpenMessage(), fdScriptSetFlag(), fdScriptSetMessageId(), fdScriptShowMessageThenWait(), fdScriptStart(), fdScriptWait(), gmPartyRemoveMember(), MainRoutineStateWork, scFieldActorLaunchFromLeader(), scFieldScriptAskYesNoWithActorAnimation(), scFieldScriptShowMessageThenWait() and Sint32.

Referenced by scLemuriaRoomsTalkToPiersUncle().

Definition at lines 123 and 348 of file lemuria_rooms.c.

scGetEntrances

const SCENE_ENTRANCE *scGetEntrances(void)

References SceneEntrances.

Definition at line 128 of file lemuria_rooms.c.

scGetExitRegions

const SCENE_REGION *scGetExitRegions(void)

References SceneRegions.

Definition at line 133 of file lemuria_rooms.c.

scGetExits

const Uint32 *scGetExits(void)

References SceneExits.

Definition at line 138 of file lemuria_rooms.c.

scGetActorPlacements

const ACTOR_PLACE *scGetActorPlacements(void)

References ActorPlacements.

Definition at line 143 of file lemuria_rooms.c.

scLemuriaRoomsTalkToPiersUncle

void scLemuriaRoomsTalkToPiersUncle(Sint32 actorId)

Piers's uncle asks whether the party came with Piers, then, once Piers has visited him, is relieved Piers is alive, and later sends the party to Lunpa's tower.

References fdActorFaceDirection(), fdActorWatchAndSetScript(), fdScriptEnd(), fdScriptEndLastingPsynergy(), fdScriptGetFlag(), fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptWait(), scFieldPartyGetLeaderActor(), scFieldScriptAskYesNoWithActorAnimation(), scLemuriaRoomsPiersVisitsUncle() and Sint32.

Referenced by SceneCues.

Definition at line 151 of file lemuria_rooms.c.

scLemuriaRoomsMindReadPiersUncle

void scLemuriaRoomsMindReadPiersUncle(Sint32 unused, Sint32 id)

Mind Read on Piers's uncle: his thoughts follow how far Piers's homecoming has gone.

References fdScriptGetFlag(), fdScriptSetMessageId(), fdScriptShowMessage() and Sint32.

Referenced by SceneCues.

Definition at line 195 of file lemuria_rooms.c.

scLemuriaRoomsAskFromBeyondSeaOfTime

void scLemuriaRoomsAskFromBeyondSeaOfTime(Sint32 actorId)

In the hall of the House of the Senate, an old senator asks whether the party came from beyond the Sea of Time, and scorns either answer.

References fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptWait(), scFieldPartyGetLeaderActor(), scFieldScriptAskYesNoWithActorAnimation() and Sint32.

Referenced by SceneCues.

Definition at line 221 of file lemuria_rooms.c.

scLemuriaRoomsAskAboutDraughts

void scLemuriaRoomsAskAboutDraughts(Sint32 actorId)

In a room behind the Senate hall's arches, a senator offers to tell of the draughts that kept Lemurians long-lived, and tells of them either way.

References fdScriptOpenMessage(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptWait(), scFieldPartyGetLeaderActor(), scFieldScriptAskYesNoWithActorAnimation() and Sint32.

Referenced by SceneCues.

Definition at line 247 of file lemuria_rooms.c.

scLemuriaRoomsNoticeMindRead

void scLemuriaRoomsNoticeMindRead(Sint32 unused, Sint32 actorId)

The first senator Mind Read touches turns on the party, asks whether that was Psynergy, and laughs it off: Lemurians are masters of Psynergy.

References fdActorFaceActor(), fdActorFaceDirection(), fdActorGetById(), fdActorShowEmote(), fdScriptEnd(), fdScriptEndLastingPsynergy(), fdScriptOpenMessage(), fdScriptSetFlag(), fdScriptSetMessageId(), fdScriptShowMessage(), fdScriptStart(), fdScriptWait(), scFieldPartyGetLeaderActor(), scFieldScriptAskYesNoWithActorAnimation() and Sint32.

Referenced by SceneCues.

Definition at line 272 of file lemuria_rooms.c.

scGetCues

const CUE *scGetCues(void)

References SceneCues.

Definition at line 305 of file lemuria_rooms.c.

scInit

Sint32 scInit(void)

Sets the rooms up: once Piers is at his mother's grave his uncle stands where he sent his bird from, and once Lunpa has gone to the king his tower is empty.

References fdActorGetById(), fdActorSetSpritePriority(), fdActorWalkToAndWait(), fdScriptGetFlag(), Sint32 and sySynch().

Definition at line 313 of file lemuria_rooms.c.

scPrepareMap

Sint32 scPrepareMap(void)

References Sint32.

Definition at line 341 of file lemuria_rooms.c.

scLemuriaRoomsLeavePiersToMourn

void scLemuriaRoomsLeavePiersToMourn(void)

Once Piers has gone to his mother's grave, his uncle stops the party on its way out, asks it to leave Piers to his mourning, tells of the mission the king gave Piers, and sends his bird with a letter so that Lunpa will see the party.

References fdActorFaceDirection(), fdActorGetById(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetAttachedEffect(), fdActorShowEmote(), fdActorWalkByAndWait(), fdActorWalkToAndWait(), fdScriptAskYesNoWithActorAnimation(), fdScriptEnd(), fdScriptGetFlag(), fdScriptOpenMessage(), fdScriptPlaySound(), fdScriptSetFlag(), fdScriptSetMessageId(), fdScriptStart(), result, scFieldActorSetSpritePriority(), scFieldActorStartRepeatedMotion(), scFieldScriptEndLastingPsynergy(), scFieldScriptShowMessageThenWait(), scFieldScriptWait(), Sint32, sySin(), sySynch() and syVectorAddPolarOffset().

Referenced by SceneCues.

Definition at line 596 of file lemuria_rooms.c.

scLemuriaRoomsMeetLunpa

void scLemuriaRoomsMeetLunpa(void)

Lunpa comes to meet the party in his tower and asks after Piers, learns from Kraden that his old friend Babi has died and that his grandson Dodonpa rules the village he settled, hears Kraden's theory of the world's decay, and bursts his stuck door open to take the party to the king.

References fdActorFaceDirection(), fdActorGetById(), fdActorJump(), fdActorRunRepeatedMotion(), fdActorSetAnimation(), fdActorSetAnimationAndWait(), fdActorSetAttachedEffect(), fdActorSetDestination(), fdActorSetSpriteFlags(), fdActorShowEmote(), fdActorStartRepeatedMotion(), fdActorWaitForMoveById(), fdActorWalkByAndWait(), fdActorWalkToAndWait(), fdCameraWaitForArrival(), fdScriptEnd(), fdScriptEndLastingPsynergy(), fdScriptOpenMessage(), fdScriptPlaySound(), fdScriptSetFlag(), fdScriptSetMessageId(), fdScriptShowMessageThenWait(), fdScriptStart(), fdScriptWait(), MainRoutineStateWork, result, scActorCyclePictures(), scActorPopQuestionMarks(), scFieldActorLaunchFromLeader(), scFieldActorShowEmote(), scFieldScriptAskYesNoWithActorAnimation(), scFieldScriptShowMessageThenWait(), Sint32 and sySynch().

Referenced by SceneCues.

Definition at line 907 of file lemuria_rooms.c.

Variables in detail

SceneRegions

extern SCENE_REGION SceneRegions[]

SCENE_REGION SceneRegions[]

The tower's ways between floors: the top of the stairs in the room below, and the ladder down through the floor of the room above.

Referenced by scGetExitRegions().

Definition at lines 125 and 1594 of file lemuria_rooms.c.

QuestionMarkScript

extern Uint32 QuestionMarkScript[]

Uint32 QuestionMarkScript[]

The script each "?" bubble runs: it is released once its ticks are up.

Referenced by scQuestionMarkPop().

Definition at lines 126 and 1839 of file lemuria_rooms.c.

SceneExits

Uint32 SceneExits[]

Referenced by scGetExits().

Definition at line 1600 of file lemuria_rooms.c.

ActorPlacements

ACTOR_PLACE ActorPlacements[]

Referenced by scGetActorPlacements().

Definition at line 1662 of file lemuria_rooms.c.

SceneCues

CUE SceneCues[]

The ways out, the steps that start Piers's uncle's letter and Lunpa's talk, the people talked to and read, and the bookcases.

References scLemuriaRoomsAskAboutDraughts(), scLemuriaRoomsAskFromBeyondSeaOfTime(), scLemuriaRoomsLeavePiersToMourn(), scLemuriaRoomsMeetLunpa(), scLemuriaRoomsMindReadPiersUncle(), scLemuriaRoomsNoticeMindRead() and scLemuriaRoomsTalkToPiersUncle().

Referenced by scGetCues().

Definition at line 1699 of file lemuria_rooms.c.