Digimon World 3 decomp
The European version, SLES_039.36
Loading...
Searching...
No Matches
wstag575.c File Reference

WSTAG575: Bullet Valley, West Sector. More...

#include "common.h"
#include "field/stage.h"
#include "common/start_stage.inc.c"
Include dependency graph for wstag575.c:

Go to the source code of this file.

Macros

#define STAGE_CHILDREN_SIZE   4
 
#define STAGE_TEXT   TEXT_FILE(TEXT_TALKS_06)
 
#define EVENT_TEXT_FILE   (TEXT_EVENTS_500 - 1)
 
#define STAGE_FILE   0x481
 

Functions

void updateStage (StageTask *task, void **children)
 Creates the event object of story progress 0x10.
 
void endEvent422 (void)
 After event 422, with Numemon: keeps it from playing again.
 
void setupStage (void)
 Sets the stage up: its map, actors, battles and events, playing the ambience ENV_0017.
 

Variables

s16 script422 []
 
AreaBattle area0Battle0 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle1 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle2 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle3 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle4 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle5 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle6 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area0Battle7 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
BattleList area0Battles
 
AreaBattle area1Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle3 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle6 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area1Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
BattleList area1Battles
 
AreaBattle area2Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle3 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle6 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area2Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
BattleList area2Battles
 
AreaBattle area3Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle3 = { 329, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle6 = { 156, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }
 
AreaBattle area3Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }
 
BattleList area3Battles
 
FieldBattles stageBattles []
 
ActorImage stageImages []
 
FieldTalk actor0Talks []
 
u16 actor0Conditions [] = { (0x6000 | ( STORY_NUMEMON_FOUND )) , 1, 0xFFFF }
 
FieldActorEntry actor0 = { actor0Conditions, actor0Talks, 0x69, 4, 0, 0, 0 }
 
FieldActorEntry * stageActors []
 
StageTile stageObjects []
 The tables and color setupStage gives FIELDSTG_state (FieldState)
 
StageSlot stageSlots []
 
void(* stageFuncs [])(void)
 The stage's functions (common/start_stage.inc.c calls the first): a StageFuncs in the stages with a tween, which define STAGE_TWEEN before they include this file, and in the others an array of just setupStage.
 
FieldEvent stageEvents []
 

Detailed Description

WSTAG575: Bullet Valley, West Sector.

Definition in file wstag575.c.

Macro Definition Documentation

◆ STAGE_CHILDREN_SIZE

#define STAGE_CHILDREN_SIZE   4

Definition at line 25 of file wstag575.c.

◆ STAGE_TEXT

#define STAGE_TEXT   TEXT_FILE(TEXT_TALKS_06)

Definition at line 38 of file wstag575.c.

◆ EVENT_TEXT_FILE

#define EVENT_TEXT_FILE   (TEXT_EVENTS_500 - 1)

Definition at line 39 of file wstag575.c.

◆ STAGE_FILE

#define STAGE_FILE   0x481

Definition at line 40 of file wstag575.c.

Function Documentation

◆ updateStage()

void updateStage ( StageTask *  task,
void **  children 
)

Creates the event object of story progress 0x10.

< 0x40 0x00-0x40: FLAGS_00, GAME.flags02-flags40

Definition at line 9 of file wstag575.c.

Here is the call graph for this function:

◆ endEvent422()

void endEvent422 ( void  )

After event 422, with Numemon: keeps it from playing again.

< 0x40 0x00-0x40: FLAGS_00, GAME.flags02-flags40

Definition at line 29 of file wstag575.c.

◆ setupStage()

void setupStage ( void  )

Sets the stage up: its map, actors, battles and events, playing the ambience ENV_0017.

Sets the stage up: its map, actors, battles and events, playing KANRIBGM; BGM_0029 instead except at STORY_PRESIDENT_ARRESTED once flag 0x1A0A is set.

< ENV_0017: Bullet Valley, the Dum Dum Factory, its Duct Rooms and Operation Room

< ENV_0017: Bullet Valley, the Dum Dum Factory, its Duct Rooms and Operation Room

< a cell's value: a direction (3 bits) and a StageSlot (5)

< a cell's value: its battle area (FieldBattles), or 0

Definition at line 43 of file wstag575.c.

Variable Documentation

◆ script422

s16 script422[]

Definition at line 64 of file wstag575.c.

◆ area0Battle0

AreaBattle area0Battle0 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 138 of file wstag575.c.

◆ area0Battle1

AreaBattle area0Battle1 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 139 of file wstag575.c.

◆ area0Battle2

AreaBattle area0Battle2 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 140 of file wstag575.c.

◆ area0Battle3

AreaBattle area0Battle3 = { 149, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 141 of file wstag575.c.

◆ area0Battle4

AreaBattle area0Battle4 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 142 of file wstag575.c.

◆ area0Battle5

AreaBattle area0Battle5 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 143 of file wstag575.c.

◆ area0Battle6

AreaBattle area0Battle6 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 144 of file wstag575.c.

◆ area0Battle7

AreaBattle area0Battle7 = { 70, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 145 of file wstag575.c.

◆ area0Battles

BattleList area0Battles
Initial value:
= {
3,
}
AreaBattle area0Battle7
Definition wstag575.c:145
AreaBattle area0Battle1
Definition wstag575.c:139
AreaBattle area0Battle6
Definition wstag575.c:144
AreaBattle area0Battle3
Definition wstag575.c:141
AreaBattle area0Battle5
Definition wstag575.c:143
AreaBattle area0Battle0
Definition wstag575.c:138
AreaBattle area0Battle2
Definition wstag575.c:140
AreaBattle area0Battle4
Definition wstag575.c:142

Definition at line 146 of file wstag575.c.

◆ area1Battle0

AreaBattle area1Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 151 of file wstag575.c.

◆ area1Battle1

AreaBattle area1Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 152 of file wstag575.c.

◆ area1Battle2

AreaBattle area1Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 153 of file wstag575.c.

◆ area1Battle3

AreaBattle area1Battle3 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 154 of file wstag575.c.

◆ area1Battle4

AreaBattle area1Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 155 of file wstag575.c.

◆ area1Battle5

AreaBattle area1Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 156 of file wstag575.c.

◆ area1Battle6

AreaBattle area1Battle6 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 157 of file wstag575.c.

◆ area1Battle7

AreaBattle area1Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 158 of file wstag575.c.

◆ area1Battles

BattleList area1Battles
Initial value:
= {
0,
}
AreaBattle area1Battle6
Definition wstag575.c:157
AreaBattle area1Battle2
Definition wstag575.c:153
AreaBattle area1Battle4
Definition wstag575.c:155
AreaBattle area1Battle5
Definition wstag575.c:156
AreaBattle area1Battle3
Definition wstag575.c:154
AreaBattle area1Battle0
Definition wstag575.c:151
AreaBattle area1Battle1
Definition wstag575.c:152
AreaBattle area1Battle7
Definition wstag575.c:158

Definition at line 159 of file wstag575.c.

◆ area2Battle0

AreaBattle area2Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 164 of file wstag575.c.

◆ area2Battle1

AreaBattle area2Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 165 of file wstag575.c.

◆ area2Battle2

AreaBattle area2Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 166 of file wstag575.c.

◆ area2Battle3

AreaBattle area2Battle3 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 167 of file wstag575.c.

◆ area2Battle4

AreaBattle area2Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 168 of file wstag575.c.

◆ area2Battle5

AreaBattle area2Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 169 of file wstag575.c.

◆ area2Battle6

AreaBattle area2Battle6 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 170 of file wstag575.c.

◆ area2Battle7

AreaBattle area2Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 171 of file wstag575.c.

◆ area2Battles

BattleList area2Battles
Initial value:
= {
0,
}
AreaBattle area2Battle7
Definition wstag575.c:171
AreaBattle area2Battle6
Definition wstag575.c:170
AreaBattle area2Battle0
Definition wstag575.c:164
AreaBattle area2Battle4
Definition wstag575.c:168
AreaBattle area2Battle2
Definition wstag575.c:166
AreaBattle area2Battle1
Definition wstag575.c:165
AreaBattle area2Battle5
Definition wstag575.c:169
AreaBattle area2Battle3
Definition wstag575.c:167

Definition at line 172 of file wstag575.c.

◆ area3Battle0

AreaBattle area3Battle0 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 177 of file wstag575.c.

◆ area3Battle1

AreaBattle area3Battle1 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 178 of file wstag575.c.

◆ area3Battle2

AreaBattle area3Battle2 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 179 of file wstag575.c.

◆ area3Battle3

AreaBattle area3Battle3 = { 329, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 180 of file wstag575.c.

◆ area3Battle4

AreaBattle area3Battle4 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 181 of file wstag575.c.

◆ area3Battle5

AreaBattle area3Battle5 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 182 of file wstag575.c.

◆ area3Battle6

AreaBattle area3Battle6 = { 156, 3, (0x60000000 | ( 2 ) << 18 | ( 0 )) }

Definition at line 183 of file wstag575.c.

◆ area3Battle7

AreaBattle area3Battle7 = { 0, 0, (0x60000000 | ( 1 ) << 18 | ( 0 )) }

Definition at line 184 of file wstag575.c.

◆ area3Battles

BattleList area3Battles
Initial value:
= {
0,
}
AreaBattle area3Battle4
Definition wstag575.c:181
AreaBattle area3Battle3
Definition wstag575.c:180
AreaBattle area3Battle0
Definition wstag575.c:177
AreaBattle area3Battle2
Definition wstag575.c:179
AreaBattle area3Battle1
Definition wstag575.c:178
AreaBattle area3Battle6
Definition wstag575.c:183
AreaBattle area3Battle5
Definition wstag575.c:182
AreaBattle area3Battle7
Definition wstag575.c:184

Definition at line 185 of file wstag575.c.

◆ stageBattles

FieldBattles stageBattles[]
Initial value:
= {
}
BattleList area3Battles
Definition wstag575.c:185
BattleList area1Battles
Definition wstag575.c:159
BattleList area2Battles
Definition wstag575.c:172
BattleList area0Battles
Definition wstag575.c:146

Definition at line 190 of file wstag575.c.

Referenced by setupStage().

◆ stageImages

ActorImage stageImages[]
Initial value:
= {
{ 0x200, 0x100, 0x21C, 0x1A6, 0x70, 0xA6, 0x230, 0x1FE },
{ 0x200, 0x100, 0x200, 0x100, 0, 0, 0x220, 0x1FE },
{ 0x200, 0x100, 0x216, 0x138, 0x58, 0x38, 0x200, 0x1FD },
{ 0x200, 0x100, 0x208, 0x1BC, 0x20, 0xBC, 0x210, 0x1FD },
{ 0x200, 0x100, 0x210, 0x1BC, 0x40, 0xBC, 0x220, 0x1FD },
{ 0x200, 0x100, 0x200, 0x1BC, 0, 0xBC, 0x230, 0x1FD },
{ 0x140, 0x100, 0x172, 0x118, 0xC8, 0x18, 0x150, 0x1FF },
}

Definition at line 193 of file wstag575.c.

Referenced by setupStage().

◆ actor0Talks

FieldTalk actor0Talks[]
Initial value:
= {
{ ((void *)0) , ((void *)0) , 0x310 },
{ ((void *)0) , ((void *)0) , 0 },
}

Definition at line 202 of file wstag575.c.

◆ actor0Conditions

u16 actor0Conditions[] = { (0x6000 | ( STORY_NUMEMON_FOUND )) , 1, 0xFFFF }

Definition at line 206 of file wstag575.c.

◆ actor0

FieldActorEntry actor0 = { actor0Conditions, actor0Talks, 0x69, 4, 0, 0, 0 }

Definition at line 207 of file wstag575.c.

◆ stageActors

FieldActorEntry* stageActors[]
Initial value:
= {
((void *)0) ,
}
FieldActorEntry actor0
Definition wstag575.c:207

Definition at line 208 of file wstag575.c.

Referenced by setupStage().

◆ stageObjects

StageTile stageObjects[]

The tables and color setupStage gives FIELDSTG_state (FieldState)

Definition at line 212 of file wstag575.c.

Referenced by setupStage().

◆ stageSlots

StageSlot stageSlots[]
Initial value:
= {
{ { { 0xFFFF , 0 }, { 0xFFFF , 0 } }, 1 , 0x24A, 0x5D8, 0x104, 1, 0, 0, 0 },
{ { { 0xFFFF , 0 }, { 0xFFFF , 0 } }, 1 , 0x24D, 0x88, 0x3F4, 5, 0, 0, 0 },
{ { { (0x7000 | ( 0x94 )) , 1 }, { 0xFFFF , 0 } }, 9 , 0x2E8, 0x240, 0xD0, 1, 0, 0x10, 1 },
{ { { 0xFFFF , 0 }, { 0xFFFF , 0 } }, 4 , 8, 0, 0, 0, 0, 0, 0 },
{ { { 0xFFFF , 0 }, { 0xFFFF , 0 } }, 0, 0, 0, 0, 0, 0, 0, 0 },
}

Definition at line 255 of file wstag575.c.

Referenced by setupStage().

◆ stageFuncs

void(* stageFuncs[])(void) ( void  )
Initial value:
= {
}
void setupStage(void)
Sets the stage up: its map, actors, battles and events, playing the ambience ENV_0017.
Definition wstag575.c:43

The stage's functions (common/start_stage.inc.c calls the first): a StageFuncs in the stages with a tween, which define STAGE_TWEEN before they include this file, and in the others an array of just setupStage.

Definition at line 262 of file wstag575.c.

◆ stageEvents

FieldEvent stageEvents[]
Initial value:
= {
{ 422, script422, ( ( 0x13D - 1) << 16 | ( 5 )), ((void *)0) , endEvent422 },
{ -1, ((void *)0) , 0, ((void *)0) , ((void *)0) },
}
s16 script422[]
Definition wstag575.c:64
void endEvent422(void)
After event 422, with Numemon: keeps it from playing again.
Definition wstag575.c:29

Definition at line 265 of file wstag575.c.

Referenced by setupStage().