Digimon World 3 decomp
The European version, SLES_039.36
Loading...
Searching...
No Matches
wstag537.c
Go to the documentation of this file.
1/*
2 * WSTAG537: Catacomb, South Sector: from STORY_BULBMON_FOUND. The Jungle
3 * Shrine (WSTAG530) leads here (mode 580) from GAME.progress 0x1A on; it has
4 * the way to the Bug Maze (540).
5 */
6
7#include "common.h"
8#include "field/stage.h"
9
10/* Creates the event object of flags 0x40CB and 0x40CC */
11void updateStage(StageTask *task, void **children) {
12 switch (task->state) {
13 case TASK_INIT:
14 default:
15 if (FLAGS_00.checkCondition(FLAG(0x40, 0xCB), 1) && FLAGS_00.checkCondition(FLAG(0x40, 0xCC), 0)) {
16 children[0] = FIELDSTG_startEvent(0x5B0);
17 }
18 task->nextState(task);
19 break;
20 case TASK_RUN:
21 case TASK_DONE:
22 case TASK_KILL:
23 break;
24 }
25}
26
27#define STAGE_CHILDREN_SIZE 4
29
30/* After event 700, with Suzaku Leader: keeps it from playing again */
34
35/* After event 1455, with Zanbamon: lets event 1456 start and starts the stage's event battle 0 */
36void endEvent1455(void) {
37 FLAGS_00.applyAction(FLAG(0x40, 0xCB), 1);
39}
40
41/*
42 * After event 1456, with Zanbamon: gives the player the Rusty Katana and
43 * keeps it from playing again
44 */
45void endEvent1456(void) {
46 FLAGS_00.applyAction(FLAG(0x40, 0xCC), 1);
47 FLAGS_00.applyAction(ITEM(3, 0x66), 1);
48}
49
50#if VERSION_US || VERSION_JP
51#define STAGE_TEXT TEXT_FILE(TEXT_TALKS_06)
52#define EVENT_TEXT_FILE (TEXT_EVENTS_500 - 1)
53#define STAGE_FILE 0x544
54#elif VERSION_EU
55#define STAGE_TEXT TEXT_FILE(TEXT_TALKS_06)
56#define EVENT_TEXT_FILE (TEXT_EVENTS_500 - 1)
57#define STAGE_FILE 0x554
58#endif
59/* Sets the stage up: its map, actors, battles and events, playing BGM_0015 */
80
82 SCRIPT_POSE(2, 1, 7),
83 SCRIPT_PLACE(0x8D, 0x374, 0x17A),
84 SCRIPT_POSE(0x8D, 1, 7),
85 SCRIPT_COMMAND(0x323, 0x325, 2),
87 SCRIPT_WAIT(0x3C),
88 SCRIPT_COMMAND(0x323, 0x326, 2),
89 SCRIPT_WAIT(0x1E),
90 SCRIPT_WALK(2, 0x354, 0x16A, 7),
92 SCRIPT_POSE(2, 1, 7),
93 SCRIPT_COMMAND(0x323, 0x325, 0x8D),
94 SCRIPT_WAIT(0x3C),
95 SCRIPT_POSE(0x8D, 1, 3),
96 SCRIPT_COMMAND(0x323, 0x326, 0x8D),
97 SCRIPT_WAIT(0x1E),
98 SCRIPT_TALK(0, 1, 0x8D, 3),
100 SCRIPT_POSE(2, 1, 6),
101 SCRIPT_POSE(0x8D, 1, 6),
102 SCRIPT_COMMAND(0x323, 0x325, 2),
103 SCRIPT_WAIT(0x3C),
104 SCRIPT_LOOK_AT(0, 0x3D2, 0x1A2),
105 SCRIPT_COMMAND(0x323, 0x326, 2),
106 SCRIPT_WAIT(0x3C),
107 SCRIPT_WAIT(0xB4),
108 SCRIPT_FOLLOW(0, 2),
109 SCRIPT_TALK(0, 2, 2, 2),
110 SCRIPT_POSE(2, 7, 6),
112 SCRIPT_POSE(2, 1, 6),
113 SCRIPT_WAIT(0x1E),
114 SCRIPT_TALK(0, 3, 0x8D, 3),
115 SCRIPT_POSE(2, 1, 7),
116 SCRIPT_POSE(0x8D, 1, 3),
118 SCRIPT_WAIT(0x1E),
120 SCRIPT_WAIT(0x78),
121 SCRIPT_POSE(2, 1, 6),
122 SCRIPT_POSE(0x8D, 1, 6),
123 SCRIPT_COMMAND(0x323, 0x325, 2),
124 SCRIPT_COMMAND(0x324, 0x325, 0x8D),
125 SCRIPT_WAIT(0x3C),
126 SCRIPT_COMMAND(0x323, 0x326, 2),
127 SCRIPT_COMMAND(0x324, 0x326, 0x8D),
128 SCRIPT_WAIT(0x1E),
129 SCRIPT_TALK(0, 4, 2, 0),
131 SCRIPT_WAIT(0x1E),
132 SCRIPT_TALK(0, 0xA, 2, 0),
134 SCRIPT_WALK(2, 0x35C, 0x16E, 7),
136 SCRIPT_COMMAND(0x323, 0x325, 0x8D),
137 SCRIPT_WAIT(0x3C),
138 SCRIPT_COMMAND(0x323, 0x326, 0x8D),
139 SCRIPT_WAIT(0x1E),
140 SCRIPT_TALK(0, 5, 0x8D, 3),
141 SCRIPT_POSE(0x8D, 1, 3),
143 SCRIPT_WAIT(0x1E),
144 SCRIPT_TALK(0, 6, 2, 0),
145 SCRIPT_POSE(2, 7, 7),
147 SCRIPT_POSE(2, 1, 7),
148 SCRIPT_WAIT(0x1E),
149 SCRIPT_TALK(0, 7, 0x8D, 3),
151 SCRIPT_COMMAND(0x323, 0x327, 0x8D),
152 SCRIPT_WAIT(0x3C),
153 SCRIPT_COMMAND(0x323, 0x326, 0x8D),
154 SCRIPT_WAIT(0x1E),
155 SCRIPT_TALK(0, 8, 0x8D, 3),
157 SCRIPT_WAIT(0x1E),
158 SCRIPT_WALK(0x8D, 0x3B0, 0x15D, 5),
159 SCRIPT_WAIT_WALK(0x8D),
160 SCRIPT_WALK(2, 0x374, 0x17A, 7),
161 SCRIPT_POSE(0x8D, 1, 1),
163 SCRIPT_TALK(0, 0xB, 2, 3),
164 SCRIPT_POSE(2, 7, 5),
166 SCRIPT_POSE(2, 1, 5),
167 SCRIPT_WAIT(0x1E),
168 SCRIPT_TALK(0, 0xC, 0x8D, 0),
170 SCRIPT_WAIT(0x1E),
171 SCRIPT_TALK(0, 9, 2, 3),
173 SCRIPT_WAIT(0x1E),
174 SCRIPT_WALK(2, 0x394, 0x18A, 7),
176 SCRIPT_POSE(2, 1, 7),
177 SCRIPT_WAIT(0x1E),
179};
181 SCRIPT_FOLLOW(1, 2),
182 SCRIPT_WALK(2, 0x357, 0x93, 5),
183 SCRIPT_PLACE(0x85, 0x377, 0x85),
184 SCRIPT_POSE(0x85, 1, 1),
187 SCRIPT_POSE(2, 1, 5),
188 SCRIPT_WAIT(0x24),
189 SCRIPT_TALK(0, 1, 2, 3),
190 SCRIPT_POSE(2, 7, 5),
192 SCRIPT_POSE(2, 1, 5),
193 SCRIPT_WAIT(0x1E),
194 SCRIPT_TALK(0, 2, 0x85, 0),
196 SCRIPT_WAIT(0x1E),
197 SCRIPT_TALK(0, 3, 2, 3),
198 SCRIPT_POSE(2, 7, 5),
200 SCRIPT_POSE(2, 1, 5),
201 SCRIPT_WAIT(0x1E),
202 SCRIPT_TALK(0, 4, 0x85, 0),
204 SCRIPT_WAIT(0x1E),
206};
208 SCRIPT_FOLLOW(1, 2),
209 SCRIPT_PLACE(2, 0x357, 0x93),
210 SCRIPT_POSE(2, 1, 5),
211 SCRIPT_PLACE(0x85, 0x377, 0x85),
212 SCRIPT_POSE(0x85, 1, 1),
213 SCRIPT_WAIT(0x78),
214 SCRIPT_TALK(0, 1, 0x85, 0),
216 SCRIPT_WAIT(0x1E),
217 SCRIPT_TALK(0, 2, 2, 3),
218 SCRIPT_POSE(2, 7, 5),
220 SCRIPT_POSE(2, 1, 5),
221 SCRIPT_WAIT(0x1E),
222 SCRIPT_TALK(0, 3, 0x85, 0),
225 SCRIPT_WAIT(0x3C),
226 SCRIPT_TALK(0, 4, 2, 3),
227 SCRIPT_POSE(2, 7, 5),
229 SCRIPT_POSE(2, 1, 5),
230 SCRIPT_WAIT(0x1E),
231 SCRIPT_TALK(0, 5, 0x85, 0),
233 SCRIPT_WAIT(0x3C),
235};
249AreaBattle area1Battle0 = { 0, 0, MUSIC(1, 0) };
250AreaBattle area1Battle1 = { 0, 0, MUSIC(1, 0) };
251AreaBattle area1Battle2 = { 0, 0, MUSIC(1, 0) };
252AreaBattle area1Battle3 = { 0, 0, MUSIC(1, 0) };
253AreaBattle area1Battle4 = { 0, 0, MUSIC(1, 0) };
254AreaBattle area1Battle5 = { 0, 0, MUSIC(1, 0) };
255AreaBattle area1Battle6 = { 0, 0, MUSIC(1, 0) };
256AreaBattle area1Battle7 = { 0, 0, MUSIC(1, 0) };
262AreaBattle area2Battle0 = { 0, 0, MUSIC(1, 0) };
263AreaBattle area2Battle1 = { 0, 0, MUSIC(1, 0) };
264AreaBattle area2Battle2 = { 0, 0, MUSIC(1, 0) };
265AreaBattle area2Battle3 = { 0, 0, MUSIC(1, 0) };
266AreaBattle area2Battle4 = { 0, 0, MUSIC(1, 0) };
267AreaBattle area2Battle5 = { 0, 0, MUSIC(1, 0) };
268AreaBattle area2Battle6 = { 0, 0, MUSIC(1, 0) };
269AreaBattle area2Battle7 = { 0, 0, MUSIC(1, 0) };
277AreaBattle area3Battle2 = { 0, 0, MUSIC(1, 0) };
278AreaBattle area3Battle3 = { 0, 0, MUSIC(1, 0) };
279AreaBattle area3Battle4 = { 0, 0, MUSIC(1, 0) };
280AreaBattle area3Battle5 = { 0, 0, MUSIC(1, 0) };
281AreaBattle area3Battle6 = { 0, 0, MUSIC(1, 0) };
282AreaBattle area3Battle7 = { 0, 0, MUSIC(1, 0) };
292 { 0x200, 0x100, 0x21C, 0x1A6, 0x70, 0xA6, 0x230, 0x1FE },
293 { 0x200, 0x100, 0x200, 0x100, 0, 0, 0x220, 0x1FE },
294 { 0x200, 0x100, 0x216, 0x138, 0x58, 0x38, 0x200, 0x1FD },
295 { 0x200, 0x100, 0x208, 0x1BC, 0x20, 0xBC, 0x210, 0x1FD },
296 { 0x200, 0x100, 0x210, 0x1BC, 0x40, 0xBC, 0x220, 0x1FD },
297 { 0x200, 0x100, 0x200, 0x1BC, 0, 0xBC, 0x230, 0x1FD },
298 { 0x140, 0x100, 0x140, 0x100, 0, 0, 0x170, 0x1FC },
299 { 0x140, 0x100, 0x14E, 0x100, 0x38, 0, 0x140, 0x1FB },
300};
366 { actor0Talk1Conditions, NULL, 0x1F0 },
367 { NULL, NULL, 0 },
368};
371 { actor1Talk1Conditions, NULL, 0x1F0 },
372 { NULL, NULL, 0 },
373};
376 { actor2Talk1Conditions, NULL, 0x1EF },
377 { NULL, NULL, 0 },
378};
381 { actor3Talk1Conditions, NULL, 0x1EC },
382 { NULL, NULL, 0 },
383};
386 { actor4Talk1Conditions, NULL, 0x1ED },
387 { NULL, NULL, 0 },
388};
391 { actor5Talk1Conditions, NULL, 0x1EE },
392 { NULL, NULL, 0 },
393};
396 { actor6Talk1Conditions, NULL, 0x1EB },
397 { NULL, NULL, 0 },
398};
401 { actor7Talk1Conditions, NULL, 0x1F0 },
402 { NULL, NULL, 0 },
403};
406 { actor8Talk1Conditions, NULL, 0x1EC },
407 { NULL, NULL, 0 },
408};
411 { actor9Talk1Conditions, NULL, 0x1EC },
412 { NULL, NULL, 0 },
413};
416 { actor10Talk1Conditions, NULL, 0x1F0 },
417 { NULL, NULL, 0 },
418};
421 { actor11Talk1Conditions, NULL, 0x1F0 },
422 { NULL, NULL, 0 },
423};
426 { actor12Talk1Conditions, NULL, 0x1F0 },
427 { NULL, NULL, 0 },
428};
431 { actor13Talk1Conditions, NULL, 0x1F0 },
432 { NULL, NULL, 0 },
433};
440 { NULL, NULL, 0x1F3 },
441 { NULL, NULL, 0 },
442};
449 { NULL, NULL, 0x1F3 },
450 { NULL, NULL, 0 },
451};
468 { NULL, NULL, 0x1F3 },
469 { NULL, NULL, 0 },
470};
477 { NULL, NULL, 0x1F3 },
478 { NULL, NULL, 0 },
479};
481 { NULL, NULL, 0x1F3 },
482 { NULL, NULL, 0 },
483};
550 &actor0,
551 &actor1,
552 &actor2,
553 &actor3,
554 &actor4,
555 &actor5,
556 &actor6,
557 &actor7,
558 &actor8,
559 &actor9,
560 &actor10,
561 &actor11,
562 &actor12,
563 &actor13,
564 &actor14,
565 &actor15,
566 &actor16,
567 &actor17,
568 &actor18,
569 &actor19,
570 &actor20,
571 &actor21,
572 &actor22,
573 &actor23,
574 &actor24,
575 &actor25,
576 NULL,
577};
579 { 1, 0, 0x40, 2, 0, 0, 0, 0, 0, 0, 999, 303, 0, 0 },
580 { 1, 0, 0x40, 6, 0x38, 2, 0, 3, 6, 0, 613, 221, 0, 0 },
581 { 1, 0, 0x40, 6, 0x38, 2, 0, 3, 6, 0, 725, 165, 0, 0 },
582 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 258, 102, 0, 0 },
583 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 531, 190, 0, 0 },
584 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 758, 111, 0, 0 },
585 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 806, 87, 0, 0 },
586 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 827, 275, 0, 0 },
587 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 859, 292, 0, 0 },
588 { 1, 0, 0x40, 6, 0x39, 2, 0, 3, 4, 0, 1002, 301, 0, 0 },
589 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 266, 105, 0, 0 },
590 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 539, 193, 0, 0 },
591 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 621, 224, 0, 0 },
592 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 733, 168, 0, 0 },
593 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 766, 114, 0, 0 },
594 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 814, 90, 0, 0 },
595 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 835, 279, 0, 0 },
596 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 867, 295, 0, 0 },
597 { 1, 0, 0x40, 6, 0x3A, 2, 0, 3, 4, 0, 1010, 304, 0, 0 },
598 { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
599};
601 { { { CODES_END, 0 }, { CODES_END, 0 } }, SLOT_EXIT, 0x242, 0x3E0, 0x1B0, 3, 0, 0, 0 },
602 { { { CODES_END, 0 }, { CODES_END, 0 } }, SLOT_EXIT, 0x245, 0x78, 0x21C, 5, 0, 0, 0 },
603 { { { CODES_END, 0 }, { CODES_END, 0 } }, SLOT_CLIMB_DOWN, 5, 0x3A0, 0x190, 0, 0, 0, 0 },
604 { { { CODES_END, 0 }, { CODES_END, 0 } }, SLOT_CLIMB_UP, 5, 0x3B0, 0x1E8, 0, 0, 0, 0 },
605 { { { PROGRESS(STORY_BULBMON_FOUND), 1 }, { FLAG_ZHU_QUE_CHIEF_WIN_SEEN, 0 } }, SLOT_EVENT, 0x2BC, 0, 0, 0, 0, 0, 0 },
606 { { { CODES_END, 0 }, { CODES_END, 0 } }, 0, 0, 0, 0, 0, 0, 0, 0 },
607};
608void (*stageFuncs[])(void) = {
610};
612 { 700, script700, EVENT_TEXT(0x1D), NULL, endEvent700 },
613 { 1455, script1455, EVENT_TEXT(0x24), NULL, endEvent1455 },
614 { 1456, script1456, EVENT_TEXT(0x25), NULL, endEvent1456 },
615 { -1, NULL, 0, NULL, NULL },
616};
#define NULL
Definition common.h:17
signed short s16
Definition common.h:9
unsigned short u16
Definition common.h:10
GameFlags FLAGS_00
The flag bitset FLAGS_00 and the event functions.
Definition events.c:701
#define TASK_RUN
Definition task.h:35
#define TASK_KILL
Definition task.h:37
#define TASK_INIT
Tasks: every game object is a task, a heap block that starts with this header and is updated once per...
Definition task.h:34
#define TASK_DONE
Definition task.h:36
EventTask * FIELDSTG_startEvent(s32 id)
Starts the event id of FieldState.events: its script, start and end, and its text; the player stands ...
Definition event.c:250
The stage overlays (AAA/PRO/WSTAG###.PRO), loaded at 0x800A4CA4 on top of FIELDSTG.
#define EVENT_TEXT(n)
An entry of the stage's events' text file, for FieldEvent.text.
Definition stage.h:732
void updateStage()
The names every stage defines, each its own (config/<version>/stages/<stage>.txt).
#define SLOT_CLIMB_UP
Definition field_map.h:256
#define SCRIPT_WAIT_WALK(id)
until the character gets to its goal
Definition field_map.h:168
#define FIELD_COMMAND_HALT_PARTNERS
The field commands, which an event script hands FIELD_TASK_COMMANDS as the first argument of a pose c...
Definition field_map.h:41
#define SCRIPT_END
The commands of an event script (FieldEvent.script), as FIELDSTG_runEvent reads them: a halfword kind...
Definition field_map.h:156
#define SCRIPT_LOOK_AT(snap, x, y)
FIELDSTG_pointCamera.
Definition field_map.h:172
#define SCRIPT_COMMAND(id, command, arg)
the same word for a script command's id: FIELDSTG_setEventPose creates its task if none runs and hand...
Definition field_map.h:161
#define SCRIPT_FOLLOW(snap, id)
FIELDSTG_followWithCamera.
Definition field_map.h:171
#define FIELD_MAP_FLOOR0
Some of FieldMap's maps (files): those of the floors the player walks on come first,...
Definition field_map.h:85
#define FIELD_COMMAND_ICON3
its substate 3, with ITEM_GET
Definition field_map.h:44
#define SLOT_CLIMB_DOWN
Definition field_map.h:257
#define SLOT_EVENT
starts the event arg
Definition field_map.h:262
#define SCRIPT_WALK(id, x, y, dir)
Actor.setGoal: walks to (x, y), then faces dir.
Definition field_map.h:162
#define SCRIPT_WAIT_BOX
until box 0 closes
Definition field_map.h:167
#define SLOT_EXIT
The kinds of StageSlot (type).
Definition field_map.h:255
#define FIELD_MAP_AREAS
a cell's value: its battle area (FieldBattles), or 0
Definition field_map.h:87
#define FIELD_COMMAND_PLAY_BULB_003
Definition field_map.h:71
#define SCRIPT_POSE(id, set, dir)
Actor.setPose: its animation set, facing dir.
Definition field_map.h:158
#define FIELD_MAP_TRIGGERS
a cell's value: a direction (3 bits) and a StageSlot (5)
Definition field_map.h:88
#define SCRIPT_WAIT(frames)
Definition field_map.h:166
#define FIELD_TASK_COMMANDS
script command 813 (FIELDSTG_startCommandTask): the field commands
Definition field_map.h:33
#define SCRIPT_PLACE(id, x, y)
puts a character at (x, y)
Definition field_map.h:157
#define SCRIPT_TALK(box, entry, id, kind)
box of the event's boxes shows the event text's entry: a talk box at the corner kind next to the char...
Definition field_map.h:165
FieldMap FIELDSTG_map
Definition fieldstg.c:3660
FieldState FIELDSTG_state
Definition fieldstg.c:2641
#define START_EVENT(index)
action: FIELDSTG_startListedEvent
Definition game_state.h:81
#define EVENT_BATTLE(id)
action: FIELDSTG_battleFuncs.startEventBattle
Definition game_state.h:72
#define CODES_END
Definition game_state.h:83
#define ITEM(kind, id)
an item, in the bag or equipped; kind (bits 9-11) isn't read, and the scripts set it after the item's...
Definition game_state.h:80
#define PROGRESS(n)
GAME.progress is n.
Definition game_state.h:69
#define FLAG(group, id)
The codes of the (code, value) pairs that FLAGS_00 checks as conditions and applies as actions (event...
Definition game_state.h:68
#define MUSIC_BATTLE
BATL0000: the maps' random battles (AreaBattle, nearly all of them)
Definition sound.h:76
#define MUSIC_JUNGLE_SHRINE
BGM_0015: the Jungle Grave, the Jungle Shrine and the Catacomb.
Definition sound.h:91
#define MUSIC_BOSS
BOSS_000: the sectors' boss battles.
Definition sound.h:108
#define MUSIC(bank, n)
A field's or a battle's music (FieldState.music, Battle.music): track (SEP) n of the first sequence o...
Definition sound.h:70
#define MUSIC_BANK(music)
The sound bank of a music, which a stage loads for it (FieldState.soundBank)
Definition sound.h:148
FIELDSTG's start of the stage (StageEntry.init in FIELDSTG_stages): the stage's task,...
@ STORY_BLACK_ID_PASS
WSTAG756 (Battle Gate), event 911: the Black ID Pass.
Definition story.h:131
@ STORY_WHITE_ID_PASS
WSTAG676 (Bai Hu Dome), event 901: the General says the A.o.A came on Bulbmon (the White ID Pass)
Definition story.h:129
@ STORY_PRESIDENT_ARRESTED
WSTAG226 (Login Room, Amaterasu City), event 935, after the President of MAGAMI gives himself up (WST...
Definition story.h:136
@ STORY_BULBMON_FOUND
WSTAG520 (Suzaku Hall), event 695: another earthquake; Bulbmon digs the holes.
Definition story.h:103
@ STORY_BLUE_ID_PASS
WSTAG421 (Qing Long City), event 743: with the Blue ID Pass a Trooper takes the player for the Qing L...
Definition story.h:109
@ STORY_AMATERASU_BRIDGE
WSTAG206 (Amaterasu Bridge), event 922: an Attacker holds the bridge.
Definition story.h:133
@ STORY_BULBMON_BEATEN
WSTAG521 (Zhu Que Hall), event 751: Bulbmon is beaten (the Red ID Pass); its hole leads on to the Ama...
Definition story.h:112
@ STORY_JUNGLE_SOUND
WSTAG545 (Bug Maze Pit), event 711: Patamon heard a weird sound from the jungle, where its leader wen...
Definition story.h:106
@ STORY_WAY_TO_AMATERASU
WSTAG305, events 893 and 895: the way into Amaterasu City, the A.o.A's headquarters,...
Definition story.h:126
@ STORY_DE_KNOWLEDGE
WSTAG526 (Zhu Que UG Lake), event 760: the fight with Zanbamon (the DE Knowledge)
Definition story.h:115
@ STORY_MOVIE_BATTLES
WSTAG820, event 1080, with Snatchmon: each encounter plays MODE_BATTLE_MOVIE first.
Definition story.h:146
@ STORY_GENBU_BADGE
WSTAG755 (Battle Gate), event 781: the Xuen Wu Chief, who holds the Black ID Pass,...
Definition story.h:118
@ STORY_NETWORK_OFFLINE
WSTAG750, event 886: the news say the Optical Network is offline.
Definition story.h:123
#define SPECIAL_STORY_ASUKA_HEADQUARTERS_TO_OPERATION_SIGMA
GAME.progress is from STORY_ASUKA_HEADQUARTERS to STORY_OPERATION_SIGMA (PROGRESS_RANGES[0x13])
Definition story.h:1920
#define FLAG_ZHU_QUE_CHIEF_WIN_SEEN
wstag537 event 700: "I won against Zhu Que Chief!", the player gets the Red ID Pass; set at its end,...
Definition story.h:1318
#define FLAG_ZANBAMON_BEATEN
wstag535/537 Catacomb: set with Zanbamon's event 1262/1455 ("I lost...", gives the Rusty Katana); tes...
Definition story.h:615
Where an actor's frames go in VRAM: one of the records after the FieldImage (Actor....
Definition field_map.h:114
A battle of an area's BattleList, which can start on the field (see FIELDSTG_startEncounter); FIGHTST...
Definition field_map.h:402
The battles of an area of the map (its cells' value at FieldMap.files[4]), one picked at random.
Definition field_map.h:411
A character of the field (FieldState.actors, a list of pointers up to NULL), which FIELDSTG_updateFie...
Definition field_map.h:194
The battles of a place (FieldState.battles), by area of the map: the fourth area's are also the ones ...
Definition field_map.h:422
An event of the table FieldState.events, up to the first id -1, which FIELDSTG_startEvent starts.
Definition field_map.h:141
void(* setFile)(s32 index, s32 file)
FIELDSTG_setMapFile.
Definition field_map.h:100
void(* setFirstMap)(s32 index)
FIELDSTG_setFirstMap: the map the player starts on (GAME.mapIndex), when the mode is new.
Definition field_map.h:104
s32 sheetEntry
the stage's sprite sheet, loaded before the field starts, or 0
Definition field_map.h:445
FieldEvent * events
up to the first id -1
Definition field_map.h:451
s32 soundBank
SOUND.loadBank's, or 0.
Definition field_map.h:459
StageTile * objects
the map objects, up to the first margin 0
Definition field_map.h:446
s32 imageFile
or an image archive file, or 0
Definition field_map.h:449
FieldBattles * battles
Definition field_map.h:450
Vec2 start
where the player starts
Definition field_map.h:456
StageSlot * slots
up to the first type 0
Definition field_map.h:447
ActorImage * actors
then the actors', from actors[2]
Definition field_map.h:454
s32 mapFile
the file of the map's tiles (FIELDSTG_createMapStreamer)
Definition field_map.h:444
s32 startDir
and its direction
Definition field_map.h:457
s32 textFile
the stage's text file, for the talks
Definition field_map.h:461
union FieldState::@12 images
s32 music
SOUND.playSound's, or 0.
Definition field_map.h:460
What a character says (FIELDSTG_runActorAction): the first whose conditions hold, or the last,...
Definition field_map.h:176
void(* applyAction)(s32 code, s32 value)
Definition game_state.h:52
s32(* checkCondition)(u16 code, u16 value)
Definition game_state.h:53
What the player can trigger on a map (FIELDSTG_updateTriggers): a record of the table at FieldState....
Definition field_map.h:276
The task a stage starts (startStage), updated by its updateStage.
Definition stage.h:26
void(* nextState)(struct StageTask *task)
Definition stage.h:27
s32 state
Definition stage.h:27
An object of a map, which FIELDSTG draws: a record of the table at FieldState.objects,...
Definition field_map.h:208
Definition gfx.h:352
u16 actor1Conditions[]
Definition wstag537.c:490
u16 actor0Talk0Actions[]
Definition wstag537.c:302
AreaBattle area2Battle7
Definition wstag537.c:269
u16 actor6Talk0Actions[]
Definition wstag537.c:320
FieldActorEntry actor0
Definition wstag537.c:523
void(* stageFuncs[])(void)
The stage's functions (common/start_stage.inc.c calls the first): a StageFuncs in the stages with a t...
Definition wstag537.c:608
FieldActorEntry actor6
Definition wstag537.c:529
u16 actor7Talk1Conditions[]
Definition wstag537.c:324
u16 actor11Conditions[]
Definition wstag537.c:500
u16 actor0Talk0Conditions[]
Definition wstag537.c:301
FieldTalk actor2Talks[]
Definition wstag537.c:374
AreaBattle area2Battle6
Definition wstag537.c:268
u16 actor8Talk1Conditions[]
Definition wstag537.c:327
void endEvent700(void)
After event 700, with Suzaku Leader: keeps it from playing again.
Definition wstag537.c:31
s16 script700[]
Definition wstag537.c:81
s16 script1456[]
Definition wstag537.c:207
u16 actor0Talk1Conditions[]
Definition wstag537.c:303
u16 actor2Talk1Conditions[]
Definition wstag537.c:309
u16 actor10Conditions[]
Definition wstag537.c:499
FieldActorEntry actor25
Definition wstag537.c:548
u16 actor25Talk0Actions[]
Definition wstag537.c:362
FieldActorEntry actor24
Definition wstag537.c:547
u16 actor18Conditions[]
Definition wstag537.c:507
FieldActorEntry actor17
Definition wstag537.c:540
void endEvent1455(void)
After event 1455, with Zanbamon: lets event 1456 start and starts the stage's event battle 0.
Definition wstag537.c:36
u16 actor20Talk1Conditions[]
Definition wstag537.c:357
u16 actor5Talk0Conditions[]
Definition wstag537.c:316
FieldTalk actor14Talks[]
Definition wstag537.c:434
u16 actor24Conditions[]
Definition wstag537.c:517
FieldActorEntry actor18
Definition wstag537.c:541
FieldTalk actor5Talks[]
Definition wstag537.c:389
AreaBattle area1Battle6
Definition wstag537.c:255
u16 actor25Talk0Conditions[]
Definition wstag537.c:361
u16 actor19Talk0Actions[]
Definition wstag537.c:353
u16 actor11Talk1Conditions[]
Definition wstag537.c:336
FieldActorEntry actor5
Definition wstag537.c:528
u16 actor1Talk1Conditions[]
Definition wstag537.c:306
u16 actor22Conditions[]
Definition wstag537.c:511
AreaBattle area0Battle7
Definition wstag537.c:243
FieldActorEntry actor2
Definition wstag537.c:525
u16 actor9Talk0Conditions[]
Definition wstag537.c:328
u16 actor6Talk1Conditions[]
Definition wstag537.c:321
u16 actor3Talk0Conditions[]
Definition wstag537.c:310
AreaBattle area3Battle4
Definition wstag537.c:279
AreaBattle area3Battle3
Definition wstag537.c:278
AreaBattle area0Battle1
Definition wstag537.c:237
FieldActorEntry actor23
Definition wstag537.c:546
FieldActorEntry actor19
Definition wstag537.c:542
AreaBattle area2Battle0
Definition wstag537.c:262
u16 actor9Conditions[]
Definition wstag537.c:498
u16 actor7Talk0Conditions[]
Definition wstag537.c:322
FieldActorEntry * stageActors[]
Definition wstag537.c:549
u16 actor19Talk0Conditions[]
Definition wstag537.c:352
u16 actor7Talk0Actions[]
Definition wstag537.c:323
AreaBattle area1Battle2
Definition wstag537.c:251
u16 actor23Conditions[]
Definition wstag537.c:516
AreaBattle area3Battle0
Definition wstag537.c:275
u16 actor10Talk1Conditions[]
Definition wstag537.c:333
u16 actor11Talk0Conditions[]
Definition wstag537.c:334
u16 actor4Talk1Conditions[]
Definition wstag537.c:315
u16 actor12Talk0Actions[]
Definition wstag537.c:338
FieldActorEntry actor22
Definition wstag537.c:545
AreaBattle area0Battle6
Definition wstag537.c:242
u16 actor18Talk1Conditions[]
Definition wstag537.c:351
u16 actor16Talk0Actions[]
Definition wstag537.c:347
u16 actor10Talk0Conditions[]
Definition wstag537.c:331
FieldTalk actor1Talks[]
Definition wstag537.c:369
u16 actor13Conditions[]
Definition wstag537.c:502
u16 actor22Talk1Conditions[]
Definition wstag537.c:360
AreaBattle area3Battle2
Definition wstag537.c:277
u16 actor13Talk0Conditions[]
Definition wstag537.c:340
u16 actor1Talk0Conditions[]
Definition wstag537.c:304
FieldTalk actor0Talks[]
Definition wstag537.c:364
AreaBattle area3Battle1
Definition wstag537.c:276
u16 actor25Talk1Conditions[]
Definition wstag537.c:363
FieldTalk actor21Talks[]
Definition wstag537.c:467
AreaBattle area0Battle3
Definition wstag537.c:239
FieldTalk actor20Talks[]
Definition wstag537.c:462
void endEvent1456(void)
After event 1456, with Zanbamon: gives the player the Rusty Katana and keeps it from playing again.
Definition wstag537.c:45
FieldActorEntry actor10
Definition wstag537.c:533
u16 actor3Talk1Conditions[]
Definition wstag537.c:312
u16 actor2Talk0Actions[]
Definition wstag537.c:308
u16 actor19Conditions[]
Definition wstag537.c:508
FieldTalk actor4Talks[]
Definition wstag537.c:384
u16 actor4Conditions[]
Definition wstag537.c:493
u16 actor20Talk0Actions[]
Definition wstag537.c:356
FieldActorEntry actor4
Definition wstag537.c:527
u16 actor3Conditions[]
Definition wstag537.c:492
AreaBattle area3Battle6
Definition wstag537.c:281
FieldTalk actor17Talks[]
Definition wstag537.c:448
FieldTalk actor11Talks[]
Definition wstag537.c:419
FieldActorEntry actor8
Definition wstag537.c:531
ActorImage stageImages[]
Definition wstag537.c:291
u16 actor14Talk1Conditions[]
Definition wstag537.c:345
FieldTalk actor6Talks[]
Definition wstag537.c:394
void setupStage(void)
Sets the stage up: its map, actors, battles and events, playing BGM_0015.
Definition wstag537.c:60
FieldTalk actor25Talks[]
Definition wstag537.c:484
u16 actor12Talk0Conditions[]
Definition wstag537.c:337
u16 actor13Talk0Actions[]
Definition wstag537.c:341
FieldTalk actor19Talks[]
Definition wstag537.c:457
AreaBattle area2Battle4
Definition wstag537.c:266
u16 actor10Talk0Actions[]
Definition wstag537.c:332
u16 actor4Talk0Conditions[]
Definition wstag537.c:313
FieldTalk actor23Talks[]
Definition wstag537.c:476
u16 actor16Conditions[]
Definition wstag537.c:505
StageTile stageObjects[]
The tables and color setupStage gives FIELDSTG_state (FieldState)
Definition wstag537.c:578
u16 actor16Talk1Conditions[]
Definition wstag537.c:348
FieldActorEntry actor9
Definition wstag537.c:532
u16 actor8Conditions[]
Definition wstag537.c:497
FieldActorEntry actor20
Definition wstag537.c:543
s16 script1455[]
Definition wstag537.c:180
u16 actor9Talk1Conditions[]
Definition wstag537.c:330
u16 actor5Conditions[]
Definition wstag537.c:494
FieldTalk actor10Talks[]
Definition wstag537.c:414
u16 actor22Talk0Conditions[]
Definition wstag537.c:358
FieldTalk actor3Talks[]
Definition wstag537.c:379
FieldTalk actor9Talks[]
Definition wstag537.c:409
BattleList area3Battles
Definition wstag537.c:283
AreaBattle area3Battle5
Definition wstag537.c:280
AreaBattle area0Battle5
Definition wstag537.c:241
BattleList area1Battles
Definition wstag537.c:257
FieldTalk actor15Talks[]
Definition wstag537.c:439
u16 actor5Talk0Actions[]
Definition wstag537.c:317
BattleList area2Battles
Definition wstag537.c:270
u16 actor2Talk0Conditions[]
Definition wstag537.c:307
FieldActorEntry actor15
Definition wstag537.c:538
FieldActorEntry actor12
Definition wstag537.c:535
FieldActorEntry actor16
Definition wstag537.c:539
u16 actor15Conditions[]
Definition wstag537.c:504
AreaBattle area1Battle4
Definition wstag537.c:253
u16 actor6Talk0Conditions[]
Definition wstag537.c:319
u16 actor6Conditions[]
Definition wstag537.c:495
AreaBattle area2Battle2
Definition wstag537.c:264
u16 actor12Talk1Conditions[]
Definition wstag537.c:339
u16 actor14Talk0Actions[]
Definition wstag537.c:344
AreaBattle area1Battle5
Definition wstag537.c:254
u16 actor14Conditions[]
Definition wstag537.c:503
FieldActorEntry actor7
Definition wstag537.c:530
u16 actor22Talk0Actions[]
Definition wstag537.c:359
StageSlot stageSlots[]
Definition wstag537.c:600
AreaBattle area2Battle1
Definition wstag537.c:263
u16 actor1Talk0Actions[]
Definition wstag537.c:305
u16 actor5Talk1Conditions[]
Definition wstag537.c:318
FieldActorEntry actor13
Definition wstag537.c:536
u16 actor8Talk0Actions[]
Definition wstag537.c:326
FieldTalk actor24Talks[]
Definition wstag537.c:480
AreaBattle area1Battle3
Definition wstag537.c:252
AreaBattle area1Battle0
Definition wstag537.c:249
FieldActorEntry actor11
Definition wstag537.c:534
u16 actor25Conditions[]
Definition wstag537.c:518
u16 actor16Talk0Conditions[]
Definition wstag537.c:346
FieldActorEntry actor1
Definition wstag537.c:524
FieldActorEntry actor21
Definition wstag537.c:544
AreaBattle area0Battle0
Definition wstag537.c:236
u16 actor9Talk0Actions[]
Definition wstag537.c:329
AreaBattle area0Battle2
Definition wstag537.c:238
FieldTalk actor13Talks[]
Definition wstag537.c:429
#define STAGE_FILE
Definition wstag537.c:57
AreaBattle area2Battle5
Definition wstag537.c:267
u16 actor4Talk0Actions[]
Definition wstag537.c:314
u16 actor19Talk1Conditions[]
Definition wstag537.c:354
AreaBattle area1Battle1
Definition wstag537.c:250
u16 actor11Talk0Actions[]
Definition wstag537.c:335
u16 actor7Conditions[]
Definition wstag537.c:496
AreaBattle area2Battle3
Definition wstag537.c:265
u16 actor2Conditions[]
Definition wstag537.c:491
u16 actor13Talk1Conditions[]
Definition wstag537.c:342
FieldTalk actor18Talks[]
Definition wstag537.c:452
u16 actor20Talk0Conditions[]
Definition wstag537.c:355
FieldTalk actor7Talks[]
Definition wstag537.c:399
u16 actor20Conditions[]
Definition wstag537.c:509
AreaBattle area0Battle4
Definition wstag537.c:240
#define STAGE_TEXT
Definition wstag537.c:55
u16 actor3Talk0Actions[]
Definition wstag537.c:311
FieldTalk actor8Talks[]
Definition wstag537.c:404
u16 actor18Talk0Conditions[]
Definition wstag537.c:349
FieldTalk actor12Talks[]
Definition wstag537.c:424
AreaBattle area3Battle7
Definition wstag537.c:282
u16 actor21Conditions[]
Definition wstag537.c:510
u16 actor18Talk0Actions[]
Definition wstag537.c:350
BattleList area0Battles
Definition wstag537.c:244
u16 actor8Talk0Conditions[]
Definition wstag537.c:325
AreaBattle area1Battle7
Definition wstag537.c:256
FieldTalk actor16Talks[]
Definition wstag537.c:443
u16 actor17Conditions[]
Definition wstag537.c:506
FieldActorEntry actor3
Definition wstag537.c:526
FieldBattles stageBattles[]
Definition wstag537.c:288
FieldActorEntry actor14
Definition wstag537.c:537
FieldEvent stageEvents[]
Definition wstag537.c:611
u16 actor12Conditions[]
Definition wstag537.c:501
FieldTalk actor22Talks[]
Definition wstag537.c:471
u16 actor14Talk0Conditions[]
Definition wstag537.c:343
u16 actor0Conditions[]
Definition wstag537.c:489