47#include "text/msg_ids.h"
59#define VALE_GARET_REUNION_Z 829
61#define VALE_GARET_REUNION_Z 827
65#define VALE_SOUTH_VILLAGER_Z 887
67#define VALE_SOUTH_VILLAGER_Z 889
72 const s32 *villagerActions);
74 s32 departureAnimationId,
77 s32 departureAnimationId,
121 if (((
struct GameState *)scene_state)->entrance == 16)
345 *message = *message + 2;
428 s32 cameraPosition[3];
442 savedOrigin = map->
origin;
443 map->
origin = cameraPosition;
447 cameraPosition[2] +=
PIXELS(2);
451 }
while (frame != 40);
457 cameraPosition[2] -=
PIXELS(2);
461 }
while (frame != 40);
463 map->
origin = savedOrigin;
477 msg = MsgValeRrruffRrrruff;
563 if (villager->
timer == 1) {
571 const s32 *villagerActions) {
572 const s32 *replyActions;
576 replyActions = villagerActions;
612 if (villager->
timer == 2) {
623 pause = villager->
timer;
626 }
else if (pause == 2) {
635 u8 leaderMotionFlags;
652 leaderMotionFlags = *leaderMotion;
968 Event_ShowTwoMessagesAndWait(
ACTOR_DORA, 14, 2, 24, 2,
GARET, 10, 14, 4, 14,
971 actor->sprite->flags = 0;
976 for (i = 0; i != 4; i++) {
1003 for (i = 0; i != 5; i++) {
1144 actor->
z.
part.pixel - 16);
1173 *leaderMotion = leaderMotionFlags;
1200 actor->
x.
fixed = 181 << 17;
1202 actor->
x.
fixed = 197 << 17;
1204 actor->
x.
fixed = 189 << 17;
1277 priority = ((
u32)(
u8)set >> 8) + 2;
1490 s32 departureAnimationId,
1492 s32 departureAnimation;
1493 s32 approachAnimation;
1498 restoreMotion = resumeMotion;
1499 approachAnimation = approachAnimationId;
1500 departureAnimation = departureAnimationId;
1502 sprite = actor->sprite;
1516 if (restoreMotion != 0) {
1526 s32 departureAnimationId,
1528 s32 departureAnimation;
1529 s32 approachAnimation;
1534 restoreMotion = resumeMotion;
1535 approachAnimation = approachAnimationId;
1536 departureAnimation = departureAnimationId;
1538 sprite = actor->sprite;
1553 if (restoreMotion != 0) {
1561 s32 selector = first;
1565 for (i = 0; i <
count; i++) {
1578 for (i = 0; i < count; i++) {
1595 s32 stoppedMotionFlags;
1636 message = MsgValeRepairCaption;
1730 for (i = 0; i < 60; i++) {
1739 stoppedMotionFlags = 0;
1744 dustEmitter->
facing = 0x8000;
1806 Event_ShowTwoMessagesAndWait(1, 1, 2, 25, 2, 5, 10, 14, 4, 14,
1807 stoppedMotionFlags);
1930 turned->
facing = turnBack;
1934 turned->
facing = turnSide;
1937 turned->
facing = turnSide;
1986 for (i = 0; i < 40; i++) {
2030 for (i = 0; i < 40; i++) {
2074 for (i = 0; i < 40; i++) {
2302 Event_ShowTwoMessagesAndWait(21, 14, 2, 24, 2, 1, 10, 14, 4, 14, none);
2305 actor->sprite->flags = none;
2310 for (i = 0; i != 4; i++) {
2312 actor->
scaleY += -0x1999;
2341 for (i = 0; i != 5; i++) {
2480 actor->
z.
part.pixel - 16);
2558 s32 *second_position) {
2559 s32 delta_x = (*first_position++ - *second_position++) >> 16;
2560 s32 delta_y = (*first_position++ - *second_position++) >> 16;
2561 s32 delta_z = (*first_position - *second_position) >> 16;
2562 s32 delta_x_squared = delta_x * delta_x;
2563 s32 delta_y_squared = delta_y * delta_y;
2564 s32 delta_z_squared = delta_z * delta_z;
2566 return Iwram_Sqrt(delta_x_squared + delta_y_squared + delta_z_squared);
2589 left = (angle - 0x1000) & 0xf000;
2590 right = (angle + 0x1000) & 0xf000;
2592 dir = obj->
facing & 0xf000;
2593 if (angle == dir || right == dir || left == dir || force != 0) {
2638 s32 spawnPosition[3];
2649 if (particle != 0) {
2652 particle->
wait = 12;
2658 s32 priorityFlags = ~12;
2659 priorityFlags &= ((
u8 *)&record->
image)[9];
2661 ((
u8 *)&record->
image)[9] = priorityFlags;
2674 for (frameCountdown = 30; frameCountdown >= 0; frameCountdown--) {
2677 emitter->
scaleX += -2048;
2678 emitter->
scaleY += -2048;
2682 for (frameCountdown = 7; frameCountdown >= 0; frameCountdown--) {
2686 if (particle != 0) {
2694 particle->
speed = verticalSpeed;
2720 s32 distance,
s32 angle) {
2722 if (particle != 0) {
2740 StagedActor_AdvancePair();
2760 column = actor->
x.
fixed >> 20;
2764 }
else if (column == 23) {
2791 if (pauseFlag == 0) {
2811 if (villager != 0) {
2847#define DIRECTION_STEP(dx, dz) (((dx) << 16) | ((dz) & 0xffff))
2860 207, 205, 228, 229, 298, 297,
3019 { 0,
CONDITION_ALWAYS, 167, 0, 1281,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3020 { 1,
CONDITION_ALWAYS, 256, 0, 440,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3021 { 2,
CONDITION_ALWAYS, 113, 0, 303,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3022 { 3,
CONDITION_ALWAYS, 38, 0, 636,
FACING_EAST, 0, -1, -1, -1, -1, 0 },
3023 { 4,
CONDITION_ALWAYS, 29, 0, 792,
FACING_EAST, 0, -1, -1, -1, -1, 0 },
3024 { 5,
CONDITION_ALWAYS, 458, 0, 1393,
FACING_WEST, 0, -1, -1, -1, -1, 0 },
3025 { 6,
CONDITION_ALWAYS, 406, 0, 743,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3026 { 7,
CONDITION_ALWAYS, 262, 0, 821,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3027 { 8,
CONDITION_ALWAYS, 340, 0, 904,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3028 { 9,
CONDITION_ALWAYS, 326, 0, 1142,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3029 { 10,
CONDITION_ALWAYS, 374, 0, 1254,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3030 { 11,
CONDITION_ALWAYS, 102, 0, 1222,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
3031 { 16,
CONDITION_ALWAYS, 400, 0, 852,
FACING_NORTH, 0, -1, -1, -1, -1, 0 },
3032 { 17,
CONDITION_ALWAYS, 400, 0, 852,
FACING_NORTH, 0, -1, -1, -1, -1, 0 },
Ability numbers, named from the English release.
void Object_RefreshSelectorById(u32 objectId)
Waits, at most 300 frames, for an actor's script to reach its end (command 0x10).
struct FieldActor * Object_GetById(s32 actor)
Returns an actor, or NULL if it does not exist.
s32 gStagedActor_DirectionSteps[]
Pixel step by direction: X in the upper halfword, Z in the lower.
s32 gStagedActor_FootprintBounds[]
#define DIRECTION_STEP(dx, dz)
Pixel step by direction: X in the upper halfword, Z in the lower.
u32 gStagedActor_FootprintKinds[]
Calls through a function pointer, by argument count.
void(*) SchedulerCallback(void)
static void Event_CatchNut(void)
Catch on the Nut circling in the first room: the party gets it.
The engine calls the debug menus import, and their palette swatch tiles.
The edition's language, for C to compare (LANGUAGE == LANGUAGE_GERMAN).
static s32 FieldScheduler_AddCallback(SchedulerCallback callback, s32 priority)
Registers a main-image scheduler callback.
void ObjectSystem_ResumeProjectionAndHideLayers(void)
Resumes the object camera updates and hides BG1-3 and the sprites.
void ObjectSystem_SuspendProjectionAndShowSprites(void)
Suspends the object camera updates, starts the palette back to normal and, a frame later,...
Field effects, their scripts and the flags that spawn them.
The scene script layer: the engine services a scene's events call, declared once (Engine_EventBegin,...
void Engine_ObjectSetPosition(struct FieldActor *object, s32 fixed_x, s32 fixed_y, s32 fixed_z)
#define SPEAKER_PORTRAIT_LEFT
static s32 Event_OpenMessage(s32 speaker, s32 flags)
void Engine_ActorFaceActor(s32 actor, s32 target, s32 frames)
static void Actor_SetDestination(s32 actor, s32 x, s32 z)
static void Actor_FaceDirection(s32 actor, s32 facing, s32 frames)
void Engine_ActorSetAnimationAndWait(s32 actor, s32 animation)
void Object_SetMode(struct FieldActor *object, s32 animation)
static void Map_AnimateCells(const u16 *steps, s32 destX, s32 destY)
#define SPEAKER_WINDOW_ABOVE
void Engine_ActorSetSpritePriority(s32 actor, s32 priority)
static void Event_ShowMessageAndWait(s32 speaker, s32 flags, s32 frames)
static void Actor_SetBuiltinAction(s32 actor, s32 action)
void Engine_PartyAddMembers(s32 first, s32 second)
s32 Engine_EventChooseYesNo(s32 actor, s32 flags)
void Engine_MessageShowCentered(s32 message, s32 flags)
void Engine_ObjectSetPartPalettes(struct FieldActor *object, s32 palette)
s32 Engine_PartyGiveItem(s32 item, s32 flags)
void Engine_EventShowMessageAndWait(s32 speaker, s32 flags, s32 frames)
#define SPEAKER_PORTRAIT_RIGHT
static void Actor_WalkToAndWait(s32 actor, s32 x, s32 z)
static void Camera_SetSpeed(s32 speed, s32 acceleration)
void Engine_ActorJump(s32 actor, s32 height, s32 frames)
static void Actor_MoveToAndWait(s32 actor, s32 x, s32 z)
#define MAP_CELL_STEP(srcX, srcY, width, height, frames)
void Engine_ItemShowFound(s32 item, s32 height)
void Engine_EventCloseScreen(void)
static void Actor_RunActionScriptAndWait(s32 actor, const s32 *script)
Runs a script, waiting at most 300 frames for its final command.
static void Map_CopyCellsTo(s32 srcX, s32 srcY, s32 destX, s32 destY, s32 width, s32 height)
void Engine_ActorWalkToAndWait(s32 actor, s32 x, s32 z)
static void Actor_FaceActor(s32 actor, s32 target, s32 frames)
#define SPEAKER_WINDOW_BELOW
static void Actor_WalkTo(s32 actor, s32 x, s32 z)
void Engine_EventWaitForScreen(void)
static void Actor_ShowEmote(s32 actor, s32 emote, s32 frames)
s32 Engine_EventAskYesNo(s32 speaker, s32 flags)
void Engine_ObjectSetScript(struct FieldActor *object, const s32 *script)
static void Event_ShowTwoMessagesAndWait(s32 speaker, s32 x, s32 y, s32 arg, s32 extra, s32 otherSpeaker, s32 otherX, s32 otherY, s32 otherArg, s32 otherExtra, s32 flags)
void Engine_EventOpenScreen(void)
s32 Engine_EventOpenMessage(s32 speaker, s32 flags)
void Engine_GameFlagSet(s32 flag)
void Engine_MapRenderWaitForValues(void)
void Engine_GameFlagClear(s32 flag)
void Engine_CameraWaitForMove(void)
static void Actor_SetActionScript(s32 actor, const s32 *script)
The engine encodes either a built-in action or an action-script address.
void Engine_ActorWaitForMove(s32 actor)
void Engine_CameraFollowActor(s32 actor, s32 keep_position)
static void Map_CopyCellAttributes(s32 srcX, s32 srcY, s32 width, s32 height, s32 destX, s32 destY)
void Engine_ActorRunRepeatedMotion(s32 actor, s32 repeats)
void Engine_ActorWalkTo(s32 actor, s32 x, s32 z)
static void Event_ShowMessage(s32 speaker, s32 flags)
static void Event_PlayCue(s32 cue)
static void Map_SetShake(s32 horizontal, s32 vertical, s32 decay)
Sets shake amplitudes in fixed-point pixels and the per-frame decay factor.
#define MAP_CELL_STEPS_END
static void Actor_SetChildValue(s32 actor, s32 value)
s32 Engine_GameFlagIsSet(s32 flag)
void Engine_MapAnimateCells(const u16 *steps, s32 destX, s32 destY)
void Engine_ActorStartRepeatedMotion(s32 actor, s32 repeats)
struct FieldActor * Engine_EventGetViewCenter(void)
static s32 Event_AskYesNo(s32 speaker, s32 flags)
static void Actor_SetSpeed(s32 actor, s32 speed, s32 acceleration)
void Engine_MapRedraw(void)
static void Camera_MoveTo(s32 fixed_x, s32 fixed_y, s32 fixed_z, s32 pan)
static void Actor_SetPosition(s32 actor, s32 fixed_x, s32 fixed_z)
void Engine_ActorFaceEachOther(s32 actor, s32 other, s32 frames)
void Engine_EventWait(s32 frames)
static void Actor_SetAttachedEffect(s32 actor, s32 effect)
static struct FieldActor * Actor_Get(s32 actor)
Field objects and actors, and the scene transition styles.
@ ACTOR_PRIORITY_AUTOMATIC
The sprite takes its priority from the map cell under it.
#define ACTOR_NO_TARGET
A target coordinate that is not set: the object has no target.
@ ACTOR_FACES_MOTION
turns toward its velocity, 1/16 turn a frame
The scene table formats: entrances, exits, placements and events, and the macros that write them.
#define SCENE_EXITS(scene)
#define SCENE_EXIT(exit, scene, entrance)
@ TALK_FACE_PARTY_AND_BACK
#define PSYNERGY_ON_ACTOR(ability)
#define EVENT_SCRIPT(script)
#define TOUCH_WALKING_INTO(facing)
The scene service layer: one typed inline for each engine service a scene calls by its own name,...
static s32 Task_AddCallback(void(*callback)(void), s32 priority)
Calls the main-image scheduler through engine_call.h.
static void FieldObject_SetPosition(struct FieldActor *object, s32 fixed_x, s32 fixed_y, s32 fixed_z)
16.16 fixed-point constants, sine and cosine, and the library division.
#define Q16_ONE
One in the engine's signed 16.16 fixed-point format.
Game flags, named where their meaning is shown.
#define FLAG_MET_SATUROS_AND_MENARDI
#define FLAG_SHOW_LOCATION_NAME
#define FLAG_VALE_ASKED_IF_JENNA_IS_BACK
Back from Kalay, a villager asked whether Jenna is back yet.
#define FLAG_REACHED_KALAY
Set whenever Kalay is entered; Vale's villagers then talk of the party's journey.
#define FLAG_SANCTUM_VISIT_PLANNED
#define FLAG_VALE_ASKED_IF_GOING_TO_KRADEN
A villager asked whether Isaac is going to Kraden's cottage.
#define FLAG_SCENE_TEMP_02
#define FLAG_KEEP_PARTY_POSITION
#define FLAG_VALE_ANGRY_VILLAGER_ARGUED
A villager has scolded Garet once.
#define FLAG_SCENE_TEMP_10
#define FLAG_VALE_WARNED_AGAINST_MT_ALEPH
A villager stopped Isaac and warned him off the mountain.
#define FLAG_SCENE_TEMP_04
#define FLAG_SCENE_TEMP_41
#define FLAG_MENU_OPEN
Set while the field menu is open; scenes hold their moving actors still.
volatile u32 gFrameCount
Frames WaitFrames has finished.
GameState, the game's state: play time, coins, the scene and the leader's position,...
struct GameState gGameState
The work slots of gWorkSlot, read through their own names.
The screen blend's globals and the graphics routines.
The main-image routines scene overlays import.
The IWRAM call layer: the routines the game keeps resident in IWRAM, each at its fixed address,...
static s32 Iwram_Sqrt(s32 value)
Small statement macros both games use for positions, velocities and bounds.
#define SET_VELOCITY(p, vx, vy, vz)
#define SET_VECTOR(v, x, y, z)
Sets the x, y and z of a three-part vector: a position about to be projected, a per-frame step,...
void Vector_AddPolarOffset(s32 radius, s32 angle, void *position)
Moves the point position by radius in direction angle on the ground plane: x by the cosine,...
s32 ArcTan2(s32 x, s32 y)
Returns the angle of the vector (x, y), in 1/65536 turns, measured from the y axis: 0 along +y,...
The heaps: allocating and freeing blocks.
The reel game's title lettering.
Field object scripts: one s32 command word, then its operands, as gScriptObject_CommandTable runs the...
#define SC_LABEL(n)
Branch destination.
#define SC_SET(w, v)
Write a work value.
#define SC_LOOP(n, to)
Repeat up to n times.
#define SC_POS(x, y, z)
Set position.
#define SC_SYNC
Wait for arrival.
#define SC_MOVE(x, y, z)
Move toward the target.
#define SC_WAIT(n)
Wait n frames.
#define SC_TOP
Script start.
#define SC_END
Return to the main script.
void PaletteGlow_Update(s32 phase, s32 brightness)
Sets the window colours (BG palette 15, colours 4 to 10) for a window hue (0 to 23) and brightness (0...
#define ACTOR_ACTION_IDLE
void BattleFx_SetQueuedSoundAndPlay(s32 soundId)
Plays SE_298, then soundId (SE_289 for -1), and remembers soundId for BattleFx_PlayQueuedSound in the...
void Audio_PlayCueFromEventWork(void)
Starts the current scene's field music, chosen by Scene_ResolveInteractionResult.
s32 Scheduler_RemoveCallback(SchedulerCallback callback)
Unschedules the task running callback: clears its routine and gives it order 0x7fff,...
Song and sound effect ids, indices into gSound_SongTable.
void Engine_ActorSetAnimation()
struct EventWork * gEventWork
void Engine_EventRequestExit()
void Engine_ActorSetPosition(u32 actor, s32 x, s32 z)
void Engine_EventEnd(void)
void Engine_AudioPlayCue()
void Engine_EventBegin(void)
void Engine_EventSetMessage()
void Engine_EventShowMessage()
Vale, its home, storm and Babi scenes, Sol Sanctum's eruption and Venus Lighthouse's aerie: Psynergy ...
void Scene_EndCutscenePsynergy(void)
Ends the cutscene's Psynergy and releases its effect work.
void Scene_BeginCutscenePsynergy(void)
Prepares the effect work and spark tiles of Move (ability 140) for the cutscene's Psynergy.
void Scene_FloatNut(s32 id)
Draws actor id as the Nut's icon and starts it floating, 32 pixels up unless the party returns to whe...
void WorldMap_CreateLinkedEffects(struct FieldActor *parent)
Attaches two rising particles to the actor, sharing the effect's cached tiles.
An animated sprite: its image and shadow, scale, rotation, size and up to four animation layers.
struct AnimationSpritePart image
u8 flags
bits: 1 outlined in ObjectSystemWork's edge and fill colours | 0 shadow drawn (set when created)
u8 count
layers in use, up to the last one present
s32 startTransition
SCENE_TRANSITION(style, variant).
s32 transitionFrames
frames
u16 message
the next message, advanced as each window opens
A field actor: a person or thing on the field with a position, motion toward a target,...
s16 timer
The parameter its action script reads (a follow distance or an angle to face), the player's frames to...
s32 speed
speed limit, 16.16 fixed-point pixels per frame
s32 targetX
16.16 fixed-point pixels; ACTOR_NO_TARGET when unset
u8 steeringFlags
ActorSteeringFlag bits.
u8 motionFlags
ActorMotionFlag bits; zero is free flight in 3D, and 3 is set on creation.
u8 riseCounter
not read by the engine; scene code's own counter
union FieldCoordinate x
16.16 fixed-point pixels
s32 targetZ
16.16 fixed-point pixels; ACTOR_NO_TARGET when unset
u8 paused
nonzero skips its script and motion, not its update
union FieldCoordinate y
16.16 fixed-point pixels
u8 priorityFlags
ActorPriorityFlag bits, read by the scrolling camera.
s32 terrainHeight
16.16 fixed-point pixels
s32 velocityY
16.16 fixed-point pixels per frame
s32 gravity
Taken off the vertical velocity each frame while it is above the ground, in 16.16 fixed-point pixels ...
union FieldCoordinate z
16.16 fixed-point pixels
s32 acceleration
Added toward the target each frame, or taken off the speed when there is none, in 16....
s32 targetY
16.16 fixed-point pixels; ACTOR_NO_TARGET when unset
s32 scaleX
16.16 fixed point, 0x10000 full size
s32 scaleY
16.16 fixed point, 0x10000 full size
void(*) update(union FieldObject *object)
Called each frame before the object's script, while the object is live.
u16 wait
the object script's wait, in frames (ScriptMotionObject)
u8 terrainId
The map layer (0 to 3) its ground height is read from, which the scrolling camera updates from the ce...
The game's state: play time, coins, the scene and the leader's position, the active party and the opt...
A scene entrance: where and facing which way the party arrives, and the camera's bounds there (-1 for...
A scene event: its kind and detail, the trigger it answers, its condition and its value (a message or...
An actor a scene places: its sprite, the condition for placing it, how it behaves,...
A scene's exit region: the box that, while its condition holds, takes the party leader out through it...
The system's routines and globals: interrupts, BIOS sound bias, random numbers and sleep.
static void Event_PushObject(void)
Walking into a pushable object pushes it along.
The integer types, TRUE, UNUSED and the fixed-address macros.
struct FieldCoordinate::@024321007066302143002254325121164243234242211074 part
s32 fixed
16.16 fixed-point pixels
An object on the field, read as an actor or as an effect.
static void Event_EnterFarSouthHouse(void)
Opens the far southern door and enters its interior.
static void Event_LeaveTowardHome(void)
Leaves through the exit leading back to the house.
static void Event_EnterIsaacsHouse(void)
Isaac's house: after the party has left and before Kalay, Dora will not open.
static void Event_EnterEastHouse(void)
Animates the eastern house door before entering.
static void Event_EnterSouthwestHouse(void)
Opens the southwestern door and enters its interior.
s32 gLeaderHammerAction[]
static void Event_GaretAsksToProtectFamily(void)
Back from Kalay, Garet asks a villager to protect his family.
static void Event_CatchNutAfterKalay(void)
The same Nut after Kalay, where it is actor 20.
const struct SceneRegion * Vale_GetRegions(void)
struct ScenePlacement gVale_Placements[]
static void Event_MendingTheRoof(void)
Arriving by entrance 16, the game's opening: Isaac is mending the roof.
static void Vale_HaveJennaStopTheAlephDetour(void)
Brings Jenna out to remind Isaac that Kraden is waiting.
static void Event_RepeatMtAlephWarningFromSecondApproach(void)
Repeats the warning when the villager reaches the second pause.
static void Vale_AskAboutSneakingToAleph(const s32 *leaderActions, const s32 *villagerActions)
Asks about the Aleph detour, then resumes each actor's response actions.
const struct ScenePlacement * Vale_GetPlacements(void)
Places the villagers for the story so far, or for the roof repair (entrance 16).
static void Event_SettleMovedObject(void)
After Move or a push, record the object's column in group flags 0x314 to 0x316 and block the cell it ...
static void Effect_ConfigureSpawnedParticle(union FieldObject *fieldObject)
Emits one dust particle below the moving source actor.
static void Event_GaretMeetsHisSister(void)
Back from Kalay, Garet meets his sister.
static void Event_LeaveByNorthPath(void)
The northern path toward Kraden's cottage.
static void Event_ReturnThroughSouthernPassage(void)
Moves back through the passage and restores its collision attributes.
struct SceneEvent gVale_EventsAfterLeaving[]
static void Vale_UpdateLeaderPaletteAndEffects(void)
Cycles the leader palette and periodically spawns attached effects.
static void Vale_MoveActorAlongHigherZPath(s32 actorId, s32 approachAnimationId, s32 departureAnimationId, s32 resumeMotion)
Traverses the passage toward higher Z and restores falling motion if requested.
static void Event_AskWhetherJennaHasReturned(void)
Back from Kalay, a villager asks whether Jenna is back.
static s32 Vale_HaveVillagerWatchTheLeader(union FieldObject *fieldObject)
static void Event_EnterNorthernPassage(void)
Changes the passage collision and moves through its northern end.
const struct SceneEntrance * Vale_GetEntrances(void)
static void Effect_SpawnRisingDustBurst(struct FieldActor *emitter)
Shrinks and raises the emitter, scatters dust, then clears its motion targets.
s32 gValeActor22WalkActions[]
static void Vale_CycleActor25Palette(void)
Cycles actor 25 palette during the repair scene.
static void Event_SearchTheLockedDoor(void)
Tells the player that this door will not open.
static void Vale_CycleSecondBoardPalette(void)
Cycles the second board palette while its repair effect runs.
static void Event_TalkAboutTheWeather(void)
A villager talks of the weather, differently right after the roof repair.
static UNUSED void HouseScene_RunRepairMorning(void)
static void Event_SetPathCellOverride(void)
Walking onto the upper path: its collision cells change, remembered in FLAG_SCENE_TEMP_10.
const u32 * Vale_GetExits(void)
static void Vale_CycleActorPaletteAndSpawnEffects(struct FieldActor *actor)
struct ScenePlacement gVale_RepairPlacements[]
static void Vale_SynchronizeAlephVillagerPause(void)
Pauses the Aleph villager while the corresponding event flag is set.
static void Event_ClearPathCellOverride(void)
Walking off the upper path restores its collision cells.
static void Event_ApproachMtAleph(void)
The mountain path: Jenna stops Isaac until Kraden has planned the visit.
static void Event_RoofMended(void)
Arriving by entrance 17 after the opening: Dora praises the mended roof.
struct ScenePlacement gVale_PlacementsAfterLeaving[]
static void Event_WarnAgainstSneakingUpMtAleph(void)
A villager jumps out in front of Isaac, then keeps watching him.
static void Event_ArgueWithTheAngryVillager(void)
A villager scolds Garet; afterwards the villager only threatens him.
#define VALE_GARET_REUNION_Z
static void Event_TurnBackFromThePuppies(void)
Shows the puppies message from the opposite approach.
static void Vale_CycleFirstBoardPalette(void)
Cycles the first board palette while its repair effect runs.
static void Event_ReactToAnotherTremor(void)
Shakes the view before the villager reacts to another tremor.
static void Event_WarnAboutGoingBeyondKradensCottage(void)
Warns about the mountain path, with a shorter repeat greeting.
#define VALE_SOUTH_VILLAGER_Z
static void Event_EnterSanctum(void)
Opens the sanctum door, walks inside and takes its scene exit.
static void Event_RepeatMtAlephWarningFromFirstApproach(void)
Repeats the warning when the villager reaches the first pause.
static void Vale_FlashActorAndSpawnEffects(struct FieldActor *actor)
static s32 Runtime_ComputeFixedPointDistance(s32 *first_position, s32 *second_position)
static void Event_EnterCentralHouse(void)
Animates the central house door before entering.
static void Effect_UpdateParticlePosition(struct FieldActor *particle, s32 distance, s32 angle)
Moves a particle outward in the horizontal plane without changing its height.
static void Vale_CycleActorPalette(struct FieldActor *actor)
struct SceneEvent gVale_EventsAfterKalay[]
static void Vale_AdjustVillagerPriorityForLeaderHeight(void)
Keeps raised villager priority consistent with the leader height.
struct SceneEvent gVale_Events[]
static void Event_LeaveBySouthPath(void)
The southern path toward Kraden's cottage.
static s32 Vale_TestFacing(struct FieldActor *obj, struct FieldActor *target, s32 range, s32 force)
static void SceneActor_ResetActorRun(s32 first, u32 count, s32 mode)
Resets consecutive repair actors to their staging position or hides them.
s32 gValeActor22Actions[]
static void Event_WatchThePuppies(void)
Pans down to the puppies and returns the camera to the leader.
static void Effect_PlayStepSound(void)
static void Event_TalkAboutTheMayorAndTremors(void)
Asks about the mayor before departure, or the tremors after returning.
static void Event_AskAboutTheLackOfTravelers(void)
Asks about the quiet roads after the eruption.
struct ScenePlacement gVale_PlacementsAfterKalay[]
static void Event_RepeatMtAlephWarningAtEitherPause(void)
Chooses the warning approach matching the current villager pause.
const struct SceneEvent * Vale_GetEvents(void)
The villagers talk of the story so far.
static void Vale_UpdateGaretPaletteAndEffects(void)
Cycles palettes on Garet and periodically spawns attached effects.
static void Vale_MoveActorAlongLowerZPath(s32 actorId, s32 approachAnimationId, s32 departureAnimationId, s32 resumeMotion)
Traverses the passage toward lower Z, changing animations at its lip.
s32 Vale_Initialize(void)
Arriving: play the roof mending (entrance 16) or its end (entrance 17, once), place the Nut and the m...
static void Vale_CycleVillagerNinePalette(void)
Cycles actor 9 palette during the repair scene.
static UNUSED void FieldScene_RunCompanionActorSequence(void)
s32 gValeLeaderWalkActions[]
static void Event_EnterSoutheastHouse(void)
Opens the southeastern door and enters its interior.
struct SceneEntrance gVale_Entrances[]
The sprite VRAM block cache and its owners.
void UiText_ShowCenteredMessage(s32 message, s32 mode, s32 yOffset)
Shows a message centred on the screen (yOffset tiles lower) and waits until it is typed out,...