diff options
Diffstat (limited to 'src/code')
| -rw-r--r-- | src/code/m_cockroach.c | 4 | ||||
| -rw-r--r-- | src/code/m_start_data_init.c | 74 | ||||
| -rw-r--r-- | src/code/m_submenu.c | 28 |
3 files changed, 53 insertions, 53 deletions
diff --git a/src/code/m_cockroach.c b/src/code/m_cockroach.c index da38126..b774da9 100644 --- a/src/code/m_cockroach.c +++ b/src/code/m_cockroach.c @@ -102,7 +102,7 @@ s32 mCkRh_PlussGokiN_NowRoom(s32 count) { s32 pad[1] UNUSED; if (FI_IS_PLAYER_ROOM(fieldId)) { - player = common_data.player_no; + player = common_data.playerNumber; housefieldId = FI_GET_PLAYER_ROOM_NO(fieldId); homeId = mHS_get_arrange_idx(player) & 3; if ((player < PLAYER_NUM) && (housefieldId == homeId)) { @@ -124,7 +124,7 @@ s32 mCkRh_MinusGokiN_NowRoom(s32 count) { s32 pad[1] UNUSED; if (FI_IS_PLAYER_ROOM(fieldId)) { - player = common_data.player_no; + player = common_data.playerNumber; housefieldId = FI_GET_PLAYER_ROOM_NO(fieldId); homeId = mHS_get_arrange_idx(player) & 3; if ((player < PLAYER_NUM) && (housefieldId == homeId)) { diff --git a/src/code/m_start_data_init.c b/src/code/m_start_data_init.c index 380a8d1..ebd8701 100644 --- a/src/code/m_start_data_init.c +++ b/src/code/m_start_data_init.c @@ -41,7 +41,7 @@ #include "m_flashrom.h" void famicom_emu_initial_common_data(void) { - FamicomEmuCommonData* famicom = &common_data.famicom_emu_common_data; + FamicomEmuCommonData* famicom = &common_data.famicomEmuCommonData; famicom->unk00 = 0; famicom->unk02 = 0x3E8; @@ -113,7 +113,7 @@ void mSDI_ClearMoneyPlayerHomeStationBlock(void) { block_x = block_num[i][0]; depositOffset = block_num[i][1] * FG_BLOCK_X_NUM + block_x; - items = common_data.fg[block_z][block_x].items[0]; + items = common_data.foreground[block_z][block_x].items[0]; if (items != NULL) { for (ut_z = 0; ut_z < UT_Z_NUM; ut_z++) { @@ -154,12 +154,12 @@ void mSDI_PullTreeBlock(u16* items_p, s32 ut) { } void mSDI_PullTree(void) { - mFM_fg_c* fg_block; + Foreground* fg_block; s32 block_z; for (block_z = 0; block_z < FG_BLOCK_Z_NUM; block_z++) { /* Clear trees against the cliffs on the left and right town cliff borders */ - fg_block = &common_data.fg[block_z][0]; + fg_block = &common_data.foreground[block_z][0]; mSDI_PullTreeBlock(fg_block->items[0], 0); mSDI_PullTreeBlock((fg_block + FG_BLOCK_X_NUM - 1)->items[0], UT_X_NUM - 1); } @@ -177,7 +177,7 @@ void mSDI_PullTreeUnderPlayerBlock(void) { * ... **/ - u16* items = &common_data.fg[2][2].items[0][0]; + u16* items = &common_data.foreground[2][2].items[0][0]; mSDI_PullTreeUT(&items[7]); mSDI_PullTreeUT(&items[8]); @@ -187,20 +187,20 @@ void mSDI_PullTreeUnderPlayerBlock(void) { s32 mSDI_StartInitNew(Game* game2, s32 player_no, s32 malloc_flag) { Game_Play* game_play = (Game_Play*)game2; - Private_c* priv; - Private_c* priv_p; + PrivateInfo* priv; + PrivateInfo* priv_p; Game* game = NULL; s32 i; UNUSED s32 pad[2]; - common_data.scene_from_title_demo = SCENE_START_DEMO; + common_data.sceneFromTitleDemo = SCENE_START_DEMO; lbRTC_GetTime(&common_data.time.rtcTime); - priv = &common_data.private[player_no]; - common_data.now_private = priv; - common_data.player_no = player_no; + priv = &common_data.saveFilePrivateInfo[player_no]; + common_data.privateInfo = priv; + common_data.playerNumber = player_no; - common_data.now_private->gender = mPr_SEX_MALE; + common_data.privateInfo->gender = mPr_SEX_MALE; decide_fruit(&common_data.fruit); if (malloc_flag == 0) { @@ -215,11 +215,11 @@ s32 mSDI_StartInitNew(Game* game2, s32 player_no, s32 malloc_flag) { mFM_SetBlockKindLoadCombi(game); mAGrw_ChangeTree2FruitTree(); - priv_p = &common_data.private[0]; + priv_p = &common_data.saveFilePrivateInfo[0]; mMld_SetDefaultMelody(); mLd_LandDataInit(); - mEv_ClearEventSaveInfo(&common_data.event_save_data); + mEv_ClearEventSaveInfo(&common_data.eventSaveInfo); mEv_init(&game_play->event); mNpc_InitNpcAllInfo(malloc_flag); @@ -248,13 +248,13 @@ s32 mSDI_StartInitNew(Game* game2, s32 player_no, s32 malloc_flag) { common_data.homes[i].unk_024 = i; } - common_data.station_type = RANDOM_F(15); + common_data.stationType = RANDOM_F(15); for (i = 0; i < PLAYER_NUM; i++) { - mPr_ClearMotherMailInfo(&common_data.mother_mail[i]); + mPr_ClearMotherMailInfo(&common_data.motherMailInfo[i]); } - mPr_SetPossessionItem(common_data.now_private, 0, ITM_MONEY_1000, mPr_ITEM_COND_QUEST); + mPr_SetPossessionItem(common_data.privateInfo, 0, ITM_MONEY_1000, mPr_ITEM_COND_QUEST); mCkRh_InitGokiSaveData_InitNewPlayer(); mEv_2nd_init(&game_play->event); famicom_emu_initial_common_data(); @@ -263,7 +263,7 @@ s32 mSDI_StartInitNew(Game* game2, s32 player_no, s32 malloc_flag) { s32 mSDI_StartInitFrom(Game* game2, s32 player_no, s32 malloc_flag) { Game_Play* game_play = (Game_Play*)game2; - Private_c* priv; + PrivateInfo* priv; Game* game = game2; s32 res = FALSE; @@ -271,15 +271,15 @@ s32 mSDI_StartInitFrom(Game* game2, s32 player_no, s32 malloc_flag) { game = NULL; } - common_data.scene_from_title_demo = SCENE_FG; + common_data.sceneFromTitleDemo = SCENE_FG; lbRTC_GetTime(&common_data.time.rtcTime); if (mFRm_CheckSaveData() == TRUE) { - priv = &common_data.private[player_no]; + priv = &common_data.saveFilePrivateInfo[player_no]; if (mPr_CheckPrivate(priv) == TRUE) { if (priv->exists == TRUE) { - common_data.now_private = priv; - common_data.player_no = player_no; + common_data.privateInfo = priv; + common_data.playerNumber = player_no; mFM_SetBlockKindLoadCombi(game); mEv_init_force(&game_play->event); mHsRm_GetHuusuiRoom(game, player_no); @@ -291,8 +291,8 @@ s32 mSDI_StartInitFrom(Game* game2, s32 player_no, s32 malloc_flag) { } else { common_data.player_decoy_flag = TRUE; priv->exists = TRUE; - common_data.now_private = priv; - common_data.player_no = player_no; + common_data.privateInfo = priv; + common_data.playerNumber = player_no; mFM_SetBlockKindLoadCombi(game); mHsRm_GetHuusuiRoom(game, player_no); mSP_ExchangeLineUp_InGame(game); @@ -316,21 +316,21 @@ s32 mSDI_StartInitFrom(Game* game2, s32 player_no, s32 malloc_flag) { s32 mSDI_StartInitNewPlayer(Game* game, s32 player_no, s32 malloc_flag) { Game_Play* game_play = (Game_Play*)game; - Private_c* priv; + PrivateInfo* priv; s32 res = FALSE; UNUSED s32 pad; - common_data.scene_from_title_demo = SCENE_START_DEMO2; + common_data.sceneFromTitleDemo = SCENE_START_DEMO2; lbRTC_GetTime(&common_data.time.rtcTime); - priv = &common_data.private[player_no]; + priv = &common_data.saveFilePrivateInfo[player_no]; if (mFRm_CheckSaveData() == TRUE) { if (mPr_CheckPrivate(priv) != TRUE) { mPr_InitPrivateInfo(priv); - common_data.now_private = priv; - mPr_SetPossessionItem(common_data.now_private, 0, ITM_MONEY_1000, mPr_ITEM_COND_QUEST); - common_data.player_no = player_no; - common_data.now_private->gender = mPr_SEX_MALE; + common_data.privateInfo = priv; + mPr_SetPossessionItem(common_data.privateInfo, 0, ITM_MONEY_1000, mPr_ITEM_COND_QUEST); + common_data.playerNumber = player_no; + common_data.privateInfo->gender = mPr_SEX_MALE; if (malloc_flag == 0) { mFM_SetBlockKindLoadCombi(game); mEv_init_force(&game_play->event); @@ -360,7 +360,7 @@ s32 mSDI_StartInitPak(Game* game2, s32 player_no, s32 malloc_flag) { } if (player_no < 5) { - common_data.scene_from_title_demo = SCENE_FG; + common_data.sceneFromTitleDemo = SCENE_FG; } if (mFRm_CheckSaveData() == TRUE) { @@ -389,8 +389,8 @@ s32 mSDI_StartInitErr(UNUSED Game* game, UNUSED s32 player_no, UNUSED s32 malloc void mSDI_StartInitAfter(Game* game, s32 renewal_reserve_flag, s32 malloc_flag) { Game_Play* game_play = (Game_Play*)game; - common_data.house_owner_name = -1; - common_data.last_field_id = -1; + common_data.houseOwnerName = -1; + common_data.lastFieldId = -1; mHm_SetNowHome(); mNpc_RenewalAnimalMemory(); @@ -416,17 +416,17 @@ void mSDI_StartInitAfter(Game* game, s32 renewal_reserve_flag, s32 malloc_flag) mHm_CheckRehouseOrder(); decide_fish_location(&common_data.fish_location); mTRC_init(game_play); - common_data.goki_shocked_flag = FALSE; + common_data.gokiShockedFlag = FALSE; func_800A6548_jp(); func_800B9B2C_jp(); func_800A91DC_jp(); - mPr_SendForeingerAnimalMail(common_data.now_private); + mPr_SendForeingerAnimalMail(common_data.privateInfo); mPr_StartSetCompleteTalkInfo(); mMsm_SendInformationMail(); func_8008DCF8_jp(); func_800A4D10_jp(); mSN_decide_msg(); - mPr_RenewalMapInfo(common_data.now_private->maps, mPr_FOREIGN_MAP_COUNT, &common_data.land_info); + mPr_RenewalMapInfo(common_data.privateInfo->maps, mPr_FOREIGN_MAP_COUNT, &common_data.landInfo); } typedef s32 (*mSDI_INIT_PROC)(Game*, s32, s32); diff --git a/src/code/m_submenu.c b/src/code/m_submenu.c index 8e2c46f..efffce6 100644 --- a/src/code/m_submenu.c +++ b/src/code/m_submenu.c @@ -471,7 +471,7 @@ void mSM_move_LINKWait(Submenu* submenu) { if (submenu->unk_00 != 4) { if (((submenu->programId == SUBMENU_PROGRAM_LEDIT) && (submenu->unk_10 == 0)) || - (common_data.now_private->gender == 0)) { + (common_data.privateInfo->gender == 0)) { sAdo_SpecChange(5); } else { sAdo_SpecChange(6); @@ -551,11 +551,11 @@ void mSM_submenu_draw(Submenu* submenu, struct Game_Play* game_play) { } s32 mSM_check_item_for_furniture(s32 index, UNUSED s32 arg1) { - u16 temp_v0 = common_data.now_private->inventory.pockets[index]; + u16 temp_v0 = common_data.privateInfo->inventory.pockets[index]; if (((temp_v0 & 0xF000) >> 0xC) == 2) { if ((((temp_v0 & 0xF00) >> 8) != 3) && (((temp_v0 & 0xF00) >> 8) != 0xF) && (((temp_v0 & 0xF00) >> 8) != 0xD)) { - if (!((common_data.now_private->inventory.item_conditions >> (index << 1)) & 3)) { + if (!((common_data.privateInfo->inventory.item_conditions >> (index << 1)) & 3)) { if (temp_v0 != 0) { return true; } @@ -566,8 +566,8 @@ s32 mSM_check_item_for_furniture(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_sell(s32 index, UNUSED s32 arg1) { - u16 temp_v0 = common_data.now_private->inventory.pockets[index]; - Private_c* private = common_data.now_private; + u16 temp_v0 = common_data.privateInfo->inventory.pockets[index]; + PrivateInfo* private = common_data.privateInfo; if (!((private->inventory.item_conditions >> (index << 1)) & 3)) { if (temp_v0 != 0) { @@ -580,7 +580,7 @@ s32 mSM_check_item_for_sell(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_give(s32 index, UNUSED s32 arg1) { - Private_c* private = common_data.now_private; + PrivateInfo* private = common_data.privateInfo; if (!((private->inventory.item_conditions >> (index << 1)) & 3)) { if (private->inventory.pockets[index] != 0) { @@ -591,8 +591,8 @@ s32 mSM_check_item_for_give(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_take(s32 index, s32 arg1) { - u16 temp_v0 = common_data.now_private->inventory.pockets[index]; - Private_c* private = common_data.now_private; + u16 temp_v0 = common_data.privateInfo->inventory.pockets[index]; + PrivateInfo* private = common_data.privateInfo; if (temp_v0 != 0) { if (!((private->inventory.item_conditions >> (index << 1)) & 3)) { @@ -607,8 +607,8 @@ s32 mSM_check_item_for_take(s32 index, s32 arg1) { } s32 mSM_check_item_for_minidisk(s32 index, UNUSED s32 arg1) { - u16 temp_v0 = common_data.now_private->inventory.pockets[index]; - Private_c* private = common_data.now_private; + u16 temp_v0 = common_data.privateInfo->inventory.pockets[index]; + PrivateInfo* private = common_data.privateInfo; if (((temp_v0 & 0xF000) >> 0xC) == 2) { if (!((private->inventory.item_conditions >> (index << 1)) & 3)) { @@ -621,7 +621,7 @@ s32 mSM_check_item_for_minidisk(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_shrine(s32 index, UNUSED s32 arg1) { - if (((common_data.now_private->inventory.item_conditions >> (index * 2)) & 3) == 2) { + if (((common_data.privateInfo->inventory.item_conditions >> (index * 2)) & 3) == 2) { if (mQst_CheckLimitbyPossessionIdx(index) != 0) { return true; } @@ -631,8 +631,8 @@ s32 mSM_check_item_for_shrine(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_entrust(s32 index, UNUSED s32 arg1) { - u16 temp_v0 = common_data.now_private->inventory.pockets[index]; - Private_c* temp_v1 = common_data.now_private; + u16 temp_v0 = common_data.privateInfo->inventory.pockets[index]; + PrivateInfo* temp_v1 = common_data.privateInfo; if ((temp_v0 == 0) || (!((temp_v1->inventory.item_conditions >> (index << 1)) & 3) && ((((temp_v0 & 0xF000) >> 0xC) != 2) || (((temp_v0 & 0xF00) >> 8) != 1)))) { @@ -643,7 +643,7 @@ s32 mSM_check_item_for_entrust(s32 index, UNUSED s32 arg1) { } s32 mSM_check_item_for_exchange(s32 index, s32 arg1) { - Private_c* temp_v0 = common_data.now_private; + PrivateInfo* temp_v0 = common_data.privateInfo; u16 temp_v1 = temp_v0->inventory.pockets[index]; UNUSED s32 pad; |
