diff options
| author | kuchenmitsahne <25233413+kuchenmitsahne@users.noreply.github.com> | 2025-06-04 19:38:23 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-04 16:38:23 -0700 |
| commit | a4d5910cdb9bed05fa5aea4476a3cf4ef178be06 (patch) | |
| tree | 017ad9a1547e3206190c216d8a7ddd2e95ff327c /include/m_field_info.h | |
| parent | 8c6ae625aef6d07741cd8925f422f43ae24b198c (diff) | |
m_random_field OK (#241)
* 25 functions OK
* 10 functions OK
* Add block type and block kind enums/defines
* Formatting/style pass
* Move `FieldMakeBlockType` to `m_field_make`
* Remove unused/duplicate defines
* Split data out for `m_quest` and `m_random_field`; rename data symbols
* Generate `m_random_field.c` and rename function symbols.
* mRF_BlockTypeDirect2GateType, mRF_BlockTypeDirect2GateData OK
* mRF_Type2BlockInfo, mRF_Info2BlockType, mRF_GateType2GateCount, mRF_SearchPond, mRF_Attr2BeastRoadAttr, mRF_CheckBeastRoad OK
* mFI_GetUnitCol OK; mRF_PrintDebug and mRF_BlockInf2CheckBeastRoad OK (pending data import).
* Fix `m_random_field` code split; all newly included functions OK
* Fix mRF_Malloc return type; formatting pass
* Name m_random_field_ovl
* Rename data symbols (m_random_field_ovl).
* Rename symbols (all functions named)
* Import data
* Declare overlay segment; rename symbols
* mRF_MakeRandomField OK (all functions matching).
* Extract asset `data_combi_table`
* Clean up mRF_MakeRandomField; document m_field_make.h
* Rename mCoBG_unkStruct->unk6 as unitAttribute
* Misc cleanup and formatting.
* Rename additional data symbols (m_random_field_ovl).
* Formatting pass
* Improve documentation of BackgroundAttribute enum.
* Formatting pass; add omitted attribute.
Diffstat (limited to 'include/m_field_info.h')
| -rw-r--r-- | include/m_field_info.h | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/include/m_field_info.h b/include/m_field_info.h index a061f1a..56c13d6 100644 --- a/include/m_field_info.h +++ b/include/m_field_info.h @@ -40,6 +40,7 @@ struct Game; #define FI_BK_WORLDSIZE_HALF_X_F (FI_BK_WORLDSIZE_X_F / 2.0f) #define FI_BK_WORLDSIZE_HALF_Z_F (FI_BK_WORLDSIZE_Z_F / 2.0f) +#define mFI_NUM_SOUND_SOURCES 6 typedef enum FieldType { /* 0 */ FI_FIELDTYPE_FG, @@ -49,10 +50,10 @@ typedef enum FieldType { /* 4 */ FI_FIELDTYPE_NPC_ROOM, /* 5 */ FI_FIELDTYPE_DEMO, /* 6 */ FI_FIELDTYPE_PLAYER_ROOM, + /* 7 */ FI_FIELDTYPE_NUM } FieldType; - #define FI_TO_FIELD_ID(type, index) (((type) << 12) | (index)) #define FI_GET_TYPE(id) ((id) & 0xF000) @@ -83,6 +84,16 @@ typedef enum FieldDirection { /* 5 */ FI_MOVEDIR_MAX } FieldDirection; +// TODO: confirm 0 through 2 (POND and NUM confirmed) +typedef enum FieldSoundSource { + /* 0 */ mFI_SOUND_SOURCE_NONE, + /* 1 */ mFI_SOUND_SOURCE_RIVER, + /* 2 */ mFI_SOUND_SOURCE_OCEAN, + /* 3 */ mFI_SOUND_SOURCE_POND, + + /* 4 */ mFI_SOUND_SOURCE_NUM +} FieldSoundSource; + #define FI_GET_PLAYER_ROOM_NO(fieldId) (((fieldId)-FI_FIELD_PLAYER0_ROOM) & 3) #define FI_IS_PLAYER_ROOM(fieldId) \ ((fieldId) == FI_FIELD_PLAYER0_ROOM || (fieldId) == FI_FIELD_PLAYER1_ROOM || \ @@ -151,10 +162,10 @@ mCoBG_unkStructUnion* mFI_UtNum2UtCol(s32 utX, s32 utZ); // void func_80089698_jp(); // void func_80089704_jp(); // void func_800897D0_jp(); -// void func_80089888_jp(); +mCoBG_unkStructUnion* mFI_GetUnitCol(xyz_t wpos); // void func_800898F4_jp(); // void func_800899CC_jp(); -// void func_80089A34_jp(); +struct FieldMakeBGSoundSource* mFI_GetSoundSourcePBlockNum(s32 blockX, s32 blockZ); // void func_80089AAC_jp(); // void func_80089B1C_jp(); // void func_80089B94_jp(); |
