32#include "text/msg_ids.h"
41#define MCCOY_GARDEN_SET_ACTOR_POSITION Engine_ActorSetPosition
43#define MCCOY_GARDEN_SET_ACTOR_POSITION ((s32 (*)())Engine_ActorSetPosition)
242 actor->sprite->image.priority = 1;
385 MAP_CELL_STEP(34, 25, 1, 3, 5),
MAP_CELL_STEP(35, 25, 1, 3, 5),
MAP_CELL_STEP(36, 25, 1, 3, 5),
MAP_CELL_STEPS_END,
390 SC_CALL(Scene_TurnTowardTarget),
395 { 1,
CONDITION_ALWAYS, 320, 0, 328,
FACING_NORTH, 0, -1, -1, -1, -1, 0 },
396 { 2,
CONDITION_ALWAYS, 328, 0, 272,
FACING_SOUTH, 0, -1, -1, -1, -1, 0 },
Ability numbers, named from the English release.
struct FieldActor * Object_GetById(s32 actor)
Returns an actor, or NULL if it does not exist.
const struct ScenePlacement * Scene_GetPlacements(void)
const struct SceneEntrance * Scene_GetEntrances(void)
const struct SceneEvent * Scene_GetEvents(void)
const u32 * Scene_GetExits(void)
Both scenes share one exit table.
const struct SceneRegion * Scene_GetRegions(void)
s32 Scene_Initialize(void)
Sets up whichever scene is being entered and runs its arrival events.
Calls through a function pointer, by argument count.
The engine calls the debug menus import, and their palette swatch tiles.
FacingObject, the view of an object that turns to face a target.
The scene script layer: the engine services a scene's events call, declared once (Engine_EventBegin,...
static void Actor_FaceDirection(s32 actor, s32 facing, s32 frames)
void Engine_ActorSetAnimationAndWait(s32 actor, s32 animation)
s32 Engine_EventChooseYesNo(s32 actor, s32 flags)
void Engine_MessageShowCentered(s32 message, s32 flags)
s32 Engine_PartyGiveItem(s32 item, s32 flags)
void Engine_EventShowMessageAndWait(s32 speaker, s32 flags, s32 frames)
void Engine_CameraSetSpeed(s32 speed, s32 acceleration)
static void Actor_WalkToAndWait(s32 actor, s32 x, s32 z)
void Engine_CameraMoveTo(s32 fixed_x, s32 fixed_y, s32 fixed_z, s32 pan)
#define MAP_CELL_STEP(srcX, srcY, width, height, frames)
void Engine_ItemShowFound(s32 item, s32 height)
void Engine_ActorSetSpeed(s32 actor, s32 speed, s32 acceleration)
void Engine_ActorFaceDirection(s32 actor, s32 facing, s32 frames)
void Engine_EventCloseScreen(void)
void Engine_ActorWalkToAndWait(s32 actor, s32 x, s32 z)
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_EventOpenScreen(void)
s32 Engine_EventOpenMessage(s32 speaker, s32 flags)
void Engine_GameFlagSet(s32 flag)
void Engine_GameFlagClear(s32 flag)
void Engine_ActorWaitForMove(s32 actor)
void Engine_ActorRunRepeatedMotion(s32 actor, s32 repeats)
#define MAP_CELL_STEPS_END
s32 Engine_GameFlagIsSet(s32 flag)
void Engine_MapAnimateCells(const u16 *steps, s32 destX, s32 destY)
void Engine_ActorStartRepeatedMotion(s32 actor, s32 repeats)
static void Actor_CenterAndWalk(s32 actor, s32 priority, s32 dz)
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_EventWait(s32 frames)
static void Actor_SetAttachedEffect(s32 actor, s32 effect)
@ TRANSITION_BACKDROP_FADE
#define SCENE_TRANSITION(style, variant)
@ 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 void FieldObject_SetTargetAndCallback(s32 object, s32 target, const s32 *actions)
Game flags, named where their meaning is shown.
#define FLAG_MCCOY_PALACE_REWARD_TAKEN
#define FLAG_MCCOY_PALACE_GARDEN_NUT_CAUGHT
the floating nut
#define FLAG_MCCOY_PALACE_PARTY_REWARDED
The escort has seen the party off after McCoy's reward.
#define FLAG_MCCOY_PALACE_ADMITTED
The gate guards have let the party into the palace.
#define FLAG_SCENE_TEMP_00
#define FLAG_MCCOY_PALACE_BARRICADE_HINT
After McCoy turned the party away, his escort let slip that the barricade may not need a key.
#define FLAG_KEEP_PARTY_POSITION
#define FLAG_KOLIMA_CURSE_LIFTED
#define FLAG_SCENE_TEMP_01
GameState, the game's state: play time, coins, the scene and the leader's position,...
struct GameState gGameState
The screen blend's globals and the graphics routines.
static void Event_TalkToWestGuard(void)
The west guard of the town asks whether the party wants in.
static void Event_SearchWell(void)
static void Event_TalkToEastGuard(void)
The east guard: wants authorization, or once the guards suspect Kalay, asks twice whether the party c...
static void Event_CatchFloatingNut(void)
Catch on the nut floating over the town: the party gets it.
u32 gMcCoyPalaceGardenExits[]
static void Event_GuardsArrestParty(void)
Kolima's curse is lifted: the guards stop the party, ask whether they broke the holy tree's curse unt...
struct SceneEvent gMcCoyPalaceGardenEventsOther[]
s32 gGuardWatchesParty[]
A guard turns to keep facing the party.
static void Event_TalkToNorthWorker(void)
The north worker asks whether the party has seen the barricade.
struct SceneEntrance gMcCoyPalaceGardenEntrances[]
static void Event_TalkToMcCoy(void)
McCoy asks whether the palace work makes him responsible for the curse.
struct SceneEvent gMcCoyPalaceGardenEvents[]
struct ScenePlacement gMcCoyPalaceGardenPlacements[]
static void Garden_ApplyProgress(void)
The guards stand where the party left them; once the curse is lifted, McCoy waits in the garden and,...
static void Garden_OpenPalaceGate(void)
The palace gate swings open.
struct ScenePlacement gMcCoyPalaceGardenPlacementsOther[]
#define MCCOY_GARDEN_SET_ACTOR_POSITION
static void Event_EnterPalace(void)
Walking into the palace gate: it opens if still shut and the leader walks in.
u16 gPalaceGateOpenSteps[]
The gate opening: three steps of cells, 5 frames each.
The reel game's title lettering.
Field object scripts: one s32 command word, then its operands, as gScriptObject_CommandTable runs the...
#define SC_LOOP(n, to)
Repeat up to n times.
#define SC_TOP
Script start.
Scene numbers, named after their places.
char SceneId_McCoyPalaceGarden
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_ActorShowEmote()
void Engine_EventSetMessage()
void Engine_EventShowMessage()
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...
The running scene's event work: its placement and event tables, its actors, the triggers and exit it ...
s32 startTransition
SCENE_TRANSITION(style, variant).
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,...
u8 steeringFlags
ActorSteeringFlag bits.
u8 priorityFlags
ActorPriorityFlag bits, read by the scrolling camera.
u16 work
The side of the player's next footprint (2 after a stop), or scene scratch.
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,...
u8 talkFacing
enum ActorTalkFacing; 3 follows the leader afterwards
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.
The integer types, TRUE, UNUSED and the fixed-address macros.