From c0ba553a85b4790802522a8d250d876f6bda244d Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 8 Dec 2020 01:37:35 -0500 Subject: [PATCH] convert more class members to new naming convention --- include/d/d_save/d_save/d_save.h | 112 ++++++++-------- src/d/d_save/d_save.cpp | 218 +++++++++++++++---------------- 2 files changed, 164 insertions(+), 166 deletions(-) diff --git a/include/d/d_save/d_save/d_save.h b/include/d/d_save/d_save/d_save.h index 6d7dedffc24..5190ca29b40 100644 --- a/include/d/d_save/d_save/d_save.h +++ b/include/d/d_save/d_save/d_save.h @@ -7,11 +7,12 @@ #define DEFAULT_SELECT_ITEM_INDEX 0 #define MAX_SELECT_ITEM 3 #define MAX_EVENTS 256 - -static const int MAX_ITEM_SLOTS = 24; -static const int ITEM_XY_MAX_DUMMY = 8; -static const int LIGHT_DROP_STAGE = 4; -static const int LETTER_INFO_BIT = 64; +#define MAX_ITEM_SLOTS 24 +#define ITEM_XY_MAX_DUMMY 8 +#define LIGHT_DROP_STAGE 4 +#define LETTER_INFO_BIT 64 +#define BOMB_BAG_MAX 3 +#define BOTTLE_MAX 4 enum Wallets { WALLET, @@ -414,14 +415,14 @@ class cXyz { class dSv_horse_place_c { public: void init(void); - void set(const char*, const cXyz&, short, s8); + void set(const char*, const cXyz&, s16, s8); private: cXyz mPosition; u16 mXRotation; - char current_stage[8]; - u8 spawn_id; - u8 room_id; + char mCurrentStage[8]; + u8 mSpawnId; + u8 mRoomId; }; class dSv_player_return_place_c { @@ -430,9 +431,9 @@ class dSv_player_return_place_c { void set(const char*, s8, u8); private: - char current_stage[8]; - u8 spawn_id; - u8 room_id; + char mCurrentStage[8]; + u8 mSpawnId; + u8 mRoomId; u8 unk10; u8 unk11; }; @@ -442,30 +443,30 @@ class dSv_player_field_last_stay_info_c { void init(void); BOOL isRegionBit(int unk) const; void onRegionBit(int unk); - void set(const char*, const cXyz&, short, s8, u8); + void set(const char*, const cXyz&, s16, s8, u8); private: - cXyz last_position; - short last_angle; - char last_stage[8]; - u8 last_spawn_id; - u8 last_room_id; + cXyz mLastPosition; + s16 mLastAngle; + char mLastStage[8]; + u8 mLastSpawnId; + u8 mLastRoomId; u8 unk24; - u8 last_region; + u8 mLastRegion; u8 unk26[2]; }; class dSv_player_last_mark_info_c { public: void init(void); - void setWarpItemData(const char*, const cXyz&, short, s8, u8, u8); + void setWarpItemData(const char*, const cXyz&, s16, s8, u8, u8); private: - cXyz ooccoo_position; - s16 ooccoo_angle; - char ooccoo_stage[8]; - u8 ooccoo_spawn_id; - u8 ooccoo_room_id; + cXyz mOoccooPosition; + s16 mOoccooXRotation; + char mOoccooStage[8]; + u8 mOoccooSpawnId; + u8 mOoccooRoomId; char unk24; u8 unk25[3]; }; @@ -497,12 +498,9 @@ class dSv_player_item_c { void setRodTypeLevelUp(void); void setBaitItem(u8); - static const int BOMB_BAG_MAX = 3; - static const int BOTTLE_MAX = 4; - private: - u8 items[24]; - u8 item_slots[24]; + u8 mItems[24]; + u8 mItemSlots[24]; }; class dSv_player_get_item_c { @@ -513,8 +511,8 @@ class dSv_player_get_item_c { int isFirstBit(u8) const; private: - u32 pause_menu_bit_fields[4]; - u8 ok[16]; + u32 mPauseMenuBitFields[4]; + u8 padding[16]; }; class dSv_player_item_record_c { @@ -523,16 +521,16 @@ class dSv_player_item_record_c { void setBombNum(u8, u8); u8 getBombNum(u8) const; void setBottleNum(u8, u8); - u8 addBottleNum(u8, short); + u8 addBottleNum(u8, s16); u8 getBottleNum(u8) const; - void setBowAmount(u8 amount) { bow = amount; } + void setBowAmount(u8 amount) { mBow = amount; } private: - u8 bow; - u8 bomb_bags[3]; - u8 bottles[4]; - u8 slingshot; + u8 mBow; + u8 mBombBags[3]; + u8 mBottles[4]; + u8 mSlingshot; u8 unk5[3]; }; @@ -542,10 +540,10 @@ class dSv_player_item_max_c { void setBombNum(u8, u8); u8 getBombNum(u8) const; - void setBowCapacity(u8 max) { item_capacities[0] = max; } + void setBowCapacity(u8 max) { mItemCapacities[0] = max; } private: - u8 item_capacities[8]; + u8 mItemCapacities[8]; }; class dSv_player_collect_c { @@ -558,15 +556,15 @@ class dSv_player_collect_c { void onCollectMirror(u8); BOOL isCollectMirror(u8) const; - u8 getPoeCount() { return poe_count; } + u8 getPoeCount() { return mPoeCount; } private: u8 unk0[8]; u8 unk8; - u8 crystal; - u8 mirror; + u8 mCrystal; + u8 mMirror; u8 unk11; - u8 poe_count; + u8 mPoeCount; u8 padding[3]; }; @@ -588,8 +586,8 @@ class dSv_light_drop_c { BOOL isLightDropGetFlag(u8) const; private: - u8 light_drop_counts[4]; - u8 light_drop_get_flag; + u8 mLightDropCounts[4]; + u8 mLightDropGetFlag; u8 unk5[3]; }; @@ -602,8 +600,8 @@ class dSv_letter_info_c { int isLetterReadFlag(int) const; private: - u32 letter_get_bitfields[2]; - u32 letter_read_bitfields[2]; + u32 mLetterGetBitfields[2]; + u32 mLetterReadBitfields[2]; u8 unk16[64]; }; @@ -613,7 +611,7 @@ class dSv_fishing_info_c { void addFishCount(u8); // merged with init in the assembly private: - u16 fish_count[16]; + u16 mFishCount[16]; u8 unk32[16]; u8 padding[4]; }; @@ -650,9 +648,9 @@ class dSv_player_config_c { private: u8 unk0; - u8 sound_mode; + u8 mSoundMode; u8 unk2; - u8 vibration_status; + u8 mVibrationStatus; u8 unk4; u8 unk5; u16 unk6; @@ -665,7 +663,7 @@ class dSv_player_config_c { class dSv_player_c { public: void init(void); - dSv_player_info_c& getPlayerInfo() { return player_info; } + dSv_player_info_c& getPlayerInfo() { return mPlayerInfo; } dSv_player_status_a_c& getPlayerStatusA() { return player_status_a; } dSv_player_item_c& getPlayerItem() { return player_item; } dSv_player_collect_c& getPlayerCollect() { return player_collect; } @@ -693,7 +691,7 @@ class dSv_player_c { dSv_light_drop_c light_drop; dSv_letter_info_c letter_info; dSv_fishing_info_c fishing_info; - dSv_player_info_c player_info; + dSv_player_info_c mPlayerInfo; dSv_player_config_c player_config; }; @@ -852,24 +850,24 @@ class dSv_zone_c { class dSv_restart_c { public: - void setRoom(const cXyz&, short, s8); + void setRoom(const cXyz&, s16, s8); private: u8 unk0; u8 unk1[5]; - short mXRotation; + s16 mXRotation; cXyz mPosition; u8 padding20[16]; }; class dSv_turnRestart_c { public: - void set(const cXyz&, short, s8, u32); + void set(const cXyz&, s16, s8, u32); private: cXyz mPosition; u32 unk12; - short mXRotation; + s16 mXRotation; s8 unk18; }; diff --git a/src/d/d_save/d_save.cpp b/src/d/d_save/d_save.cpp index efe4cd7bb4a..0ba6acfd019 100644 --- a/src/d/d_save/d_save.cpp +++ b/src/d/d_save/d_save.cpp @@ -132,53 +132,53 @@ void dSv_horse_place_c::init(void) { f32 position_val; char* default_stage; - default_stage = strcpy((char*)current_stage, (char*)lbl_80379234); + default_stage = strcpy(mCurrentStage, (char*)lbl_80379234); position_val = lbl_80451D5C; this->mPosition.x = lbl_80451D5C; this->mPosition.y = position_val; this->mPosition.z = position_val; this->mXRotation = 0; - this->spawn_id = 0; - this->room_id = 0; + this->mSpawnId = 0; + this->mRoomId = 0; } void dSv_horse_place_c::set(const char* i_name, const cXyz& i_position, s16 i_x_rot, signed char i_room_id) { - strcpy(current_stage, i_name); + strcpy(mCurrentStage, i_name); this->mPosition.x = i_position.x; this->mPosition.y = i_position.y; this->mPosition.z = i_position.z; this->mXRotation = i_x_rot; - this->room_id = i_room_id; + this->mRoomId = i_room_id; } void dSv_player_return_place_c::init(void) { - strcpy(current_stage, (char*)lbl_80379234 + 1); - this->room_id = 1; - this->spawn_id = 0; + strcpy(mCurrentStage, (char*)lbl_80379234 + 1); + this->mRoomId = 1; + this->mSpawnId = 0; this->unk10 = 21; this->unk11 = 0; } void dSv_player_return_place_c::set(const char* i_name, s8 i_room_id, u8 i_spawn_id) { - strcpy(current_stage, i_name); - this->room_id = i_room_id; - this->spawn_id = i_spawn_id; + strcpy(mCurrentStage, i_name); + this->mRoomId = i_room_id; + this->mSpawnId = i_spawn_id; } void dSv_player_field_last_stay_info_c::init() { f32 position_val; - strcpy(last_stage, (char*)lbl_80379234); + strcpy(mLastStage, (char*)lbl_80379234); position_val = lbl_80451D5C; - this->last_position.x = lbl_80451D5C; - this->last_position.y = position_val; - this->last_position.z = position_val; - this->last_angle = 0; - this->last_spawn_id = 0; - this->last_room_id = 1; + this->mLastPosition.x = lbl_80451D5C; + this->mLastPosition.y = position_val; + this->mLastPosition.z = position_val; + this->mLastAngle = 0; + this->mLastSpawnId = 0; + this->mLastRoomId = 1; this->unk24 = 0; - this->last_region = 0; + this->mLastRegion = 0; for (int i = 0; i < 2; i++) { this->unk26[i] = 0; @@ -186,12 +186,12 @@ void dSv_player_field_last_stay_info_c::init() { } void dSv_player_field_last_stay_info_c::set(const char* i_name, const cXyz& i_last_position, s16 i_last_angle, signed char i_last_spawn_id, u8 i_last_room_id) { - strcpy(last_stage, i_name); + strcpy(mLastStage, i_name); - this->last_position = i_last_position; - this->last_angle = i_last_angle; - this->last_spawn_id = i_last_spawn_id; - this->last_room_id = i_last_room_id; + this->mLastPosition = i_last_position; + this->mLastAngle = i_last_angle; + this->mLastSpawnId = i_last_spawn_id; + this->mLastRoomId = i_last_room_id; } void dSv_player_field_last_stay_info_c::onRegionBit(int i_region_bit) { @@ -201,12 +201,12 @@ void dSv_player_field_last_stay_info_c::onRegionBit(int i_region_bit) { if (8 <= i_region_bit) { return; } - this->last_region |= (u8)(1 << i_region_bit); + this->mLastRegion |= (u8)(1 << i_region_bit); } BOOL dSv_player_field_last_stay_info_c::isRegionBit(int param_1) const { if ((param_1 >= 0) && (param_1 < 8)) { - return (last_region & (u8)(1 << param_1)) ? TRUE : FALSE; + return (mLastRegion & (u8)(1 << param_1)) ? TRUE : FALSE; } return false; } @@ -214,14 +214,14 @@ BOOL dSv_player_field_last_stay_info_c::isRegionBit(int param_1) const { void dSv_player_last_mark_info_c::init(void) { f32 position; - strcpy(ooccoo_stage, (char*)lbl_80379234); + strcpy(mOoccooStage, (char*)lbl_80379234); position = lbl_80451D5C; - this->ooccoo_position.x = lbl_80451D5C; - this->ooccoo_position.y = position; - this->ooccoo_position.z = position; - this->ooccoo_angle = 0; - this->ooccoo_room_id = 0; - this->ooccoo_spawn_id = 0; + this->mOoccooPosition.x = lbl_80451D5C; + this->mOoccooPosition.y = position; + this->mOoccooPosition.z = position; + this->mOoccooXRotation = 0; + this->mOoccooRoomId = 0; + this->mOoccooSpawnId = 0; this->unk24 = -1; for (int i = 0; i < 3; i++) { @@ -230,22 +230,22 @@ void dSv_player_last_mark_info_c::init(void) { } void dSv_player_last_mark_info_c::setWarpItemData(const char* i_ooccoo_stage, const cXyz& i_ooccoo_position, s16 i_ooccoo_angle, s8 i_ooccoo_room_id, u8 unk1, u8 unk2) { - strcpy(ooccoo_stage, i_ooccoo_stage); - this->ooccoo_position = i_ooccoo_position; - this->ooccoo_angle = i_ooccoo_angle; - this->ooccoo_room_id = i_ooccoo_room_id; + strcpy(mOoccooStage, i_ooccoo_stage); + this->mOoccooPosition = i_ooccoo_position; + this->mOoccooXRotation = i_ooccoo_angle; + this->mOoccooRoomId = i_ooccoo_room_id; } void dSv_player_item_c::init(void) { for (int i = 0; i < 24; i++) { - this->items[i] = NO_ITEM; - this->item_slots[i] = NO_ITEM; + this->mItems[i] = NO_ITEM; + this->mItemSlots[i] = NO_ITEM; } } void dSv_player_item_c::setItem(int current_items_index, u8 new_items_index) { if (current_items_index < MAX_ITEM_SLOTS) { - this->items[current_items_index] = new_items_index; + this->mItems[current_items_index] = new_items_index; this->setLineUpItem(); } @@ -356,7 +356,7 @@ asm void dSv_player_item_c::setLineUpItem(void) { u8 dSv_player_item_c::getLineUpItem(int slot_number) const { if (slot_number < MAX_ITEM_SLOTS) { - return this->item_slots[slot_number]; + return this->mItemSlots[slot_number]; } return NO_ITEM; } @@ -431,7 +431,7 @@ u8 dSv_player_item_c::checkBottle(u8 i_item_id) { item_id = dSv_item_rename(i_item_id); for (int i = 0; i < BOTTLE_MAX; i++) { - if (item_id == items[i + 0xb]) { + if (item_id == this->mItems[i + SLOT_11]) { num_bottles++; } } @@ -448,7 +448,7 @@ u8 dSv_player_item_c::checkEmptyBottle(void) { for (int i = 0; i < BOTTLE_MAX; i++) { // Loop through the bottle slots (11 - 14) and increment counter for every empty bottle - if (items[i + SLOT_11] == EMPTY_BOTTLE) { + if (this->mItems[i + SLOT_11] == EMPTY_BOTTLE) { num++; } } @@ -506,7 +506,7 @@ u8 dSv_player_item_c::checkBombBag(u8 param_1) { for (int i = 0; i < BOMB_BAG_MAX; i++) { // Loop through the bomb bag slots (15 - 17) and increment counter for every match - if (param_1 == this->items[i + SLOT_15]) { + if (param_1 == this->mItems[i + SLOT_15]) { counter++; } } @@ -519,19 +519,19 @@ asm void dSv_player_item_c::setWarashibeItem(u8) { } void dSv_player_item_c::setRodTypeLevelUp(void) { - int current_fishing_rod_item_id = this->items[SLOT_20]; + int current_fishing_rod_item_id = this->mItems[SLOT_20]; switch (current_fishing_rod_item_id) { case BEE_ROD: { - this->items[SLOT_20] = JEWEL_BEE_ROD; + this->mItems[SLOT_20] = JEWEL_BEE_ROD; break; } case WORM_ROD: { - this->items[SLOT_20] = JEWEL_WORM_ROD; + this->mItems[SLOT_20] = JEWEL_WORM_ROD; break; } case FISHING_ROD_1: { - this->items[SLOT_20] = JEWEL_ROD; + this->mItems[SLOT_20] = JEWEL_ROD; break; } } @@ -546,15 +546,15 @@ void dSv_player_item_c::setRodTypeLevelUp(void) { void dSv_player_item_c::setBaitItem(u8 param_1) { switch (param_1) { case BEE_CHILD: { - isFirstBit(61) ? this->items[SLOT_20] = JEWEL_BEE_ROD : this->items[SLOT_20] = BEE_ROD; + isFirstBit(61) ? this->mItems[SLOT_20] = JEWEL_BEE_ROD : this->mItems[SLOT_20] = BEE_ROD; break; } case WORM: { - isFirstBit(61) ? this->items[SLOT_20] = JEWEL_WORM_ROD : this->items[SLOT_20] = WORM_ROD; + isFirstBit(61) ? this->mItems[SLOT_20] = JEWEL_WORM_ROD : this->mItems[SLOT_20] = WORM_ROD; break; } case NO_ITEM: { - isFirstBit(61) ? this->items[SLOT_20] = JEWEL_ROD : this->items[SLOT_20] = FISHING_ROD_1; + isFirstBit(61) ? this->mItems[SLOT_20] = JEWEL_ROD : this->mItems[SLOT_20] = FISHING_ROD_1; break; } } @@ -572,7 +572,7 @@ asm void dSv_player_item_c::setBaitItem(u8 param_1) { void dSv_player_get_item_c::init(void) { for (int i = 0; i < 8; i++) { - this->pause_menu_bit_fields[i] = 0; + this->mPauseMenuBitFields[i] = 0; } } @@ -580,7 +580,7 @@ void dSv_player_get_item_c::init(void) { #ifdef NONMATCHING void dSv_player_get_item_c::onFirstBit(u8 i_itemno) { int uVar1 = ((int)i_itemno & 0xe0) >> 0x3; - this->pause_menu_bit_fields[uVar1] |= (u32)(1 << (i_itemno & 0x1F)); + this->mPauseMenuBitFields[uVar1] |= (u32)(1 << (i_itemno & 0x1F)); } #else asm void dSv_player_get_item_c::onFirstBit(u8) { @@ -600,17 +600,17 @@ asm BOOL dSv_player_get_item_c::isFirstBit(u8) const { } void dSv_player_item_record_c::init(void) { - this->bow = 0; + this->mBow = 0; for (int i = 0; i < 3; i++) { - this->bomb_bags[i] = 0; + this->mBombBags[i] = 0; } for (int i = 0; i < 4; i++) { - this->bottles[i] = 0; + this->mBottles[i] = 0; } - this->slingshot = 0; + this->mSlingshot = 0; for (int i = 0; i < 3; i++) { this->unk5[i] = 0; @@ -618,56 +618,56 @@ void dSv_player_item_record_c::init(void) { } void dSv_player_item_record_c::setBombNum(u8 i_bagIdx, u8 bag_id) { - this->bomb_bags[i_bagIdx] = bag_id; + this->mBombBags[i_bagIdx] = bag_id; } u8 dSv_player_item_record_c::getBombNum(u8 i_bagIdx) const { - return this->bomb_bags[i_bagIdx]; + return this->mBombBags[i_bagIdx]; } void dSv_player_item_record_c::setBottleNum(u8 i_bottleIdx, u8 bottle_num) { - this->bottles[i_bottleIdx] = bottle_num; + this->mBottles[i_bottleIdx] = bottle_num; } u8 dSv_player_item_record_c::addBottleNum(u8 i_bottleIdx, s16 param_2) { - int iVar3 = this->bottles[i_bottleIdx] + param_2; + int iVar3 = this->mBottles[i_bottleIdx] + param_2; g_dComIfG_gameInfo.save_file.getPlayerItem().getItem((u8)(i_bottleIdx + 0xB), true); if (iVar3 < 0) { - this->bottles[i_bottleIdx] = 0; + this->mBottles[i_bottleIdx] = 0; } else if (iVar3 > dComIfGs_getBottleMax()) { - this->bottles[i_bottleIdx] = dComIfGs_getBottleMax(); + this->mBottles[i_bottleIdx] = dComIfGs_getBottleMax(); } else { - this->bottles[i_bottleIdx] = iVar3; + this->mBottles[i_bottleIdx] = iVar3; } - return this->bottles[i_bottleIdx]; + return this->mBottles[i_bottleIdx]; } u8 dSv_player_item_record_c::getBottleNum(u8 i_bottleIdx) const { - return this->bottles[i_bottleIdx]; + return this->mBottles[i_bottleIdx]; } void dSv_player_item_max_c::init(void) { for (int i = 0; i < 7; i++) { - this->item_capacities[i] = 30; + this->mItemCapacities[i] = 30; } setBombNum(NORMAL_BOMB, 30); setBombNum(WATER_BOMB, 15); setBombNum(POKE_BOMB, 10); - this->item_capacities[7] = 0; + this->mItemCapacities[7] = 0; } void dSv_player_item_max_c::setBombNum(u8 bomb_id, u8 bomb_max) { switch (bomb_id) { case NORMAL_BOMB: - this->item_capacities[1] = bomb_max; + this->mItemCapacities[1] = bomb_max; return; case WATER_BOMB: - this->item_capacities[2] = bomb_max; + this->mItemCapacities[2] = bomb_max; return; case POKE_BOMB: - this->item_capacities[6] = bomb_max; + this->mItemCapacities[6] = bomb_max; return; } } @@ -682,11 +682,11 @@ u8 dSv_player_item_max_c::getBombNum(u8 param_1) const { switch (param_1) { case NORMAL_BOMB: - return (u8)(this->item_capacities[0x1] * iVar3); + return (u8)(this->mItemCapacities[0x1] * iVar3); case WATER_BOMB: - return (u8)(this->item_capacities[0x2] * iVar3); + return (u8)(this->mItemCapacities[0x2] * iVar3); case POKE_BOMB: - return (u8)(this->item_capacities[0x6] * iVar3); + return (u8)(this->mItemCapacities[0x6] * iVar3); default: return 0; } @@ -698,10 +698,10 @@ void dSv_player_collect_c::init(void) { } this->unk8 = 0; - this->crystal = 0; - this->mirror = 0; + this->mCrystal = 0; + this->mMirror = 0; this->unk11 = 0xFF; - this->poe_count = 0; + this->mPoeCount = 0; } void dSv_player_collect_c::setCollect(int param_1, u8 i_item) { @@ -713,19 +713,19 @@ BOOL dSv_player_collect_c::isCollect(int param_1, u8 i_item) const { } void dSv_player_collect_c::onCollectCrystal(u8 i_item) { - this->crystal |= (u8)(1 << i_item); + this->mCrystal |= (u8)(1 << i_item); } BOOL dSv_player_collect_c::isCollectCrystal(u8 i_item) const { - return this->crystal & (u8)(1 << i_item) ? TRUE : FALSE; + return this->mCrystal & (u8)(1 << i_item) ? TRUE : FALSE; } void dSv_player_collect_c::onCollectMirror(u8 i_item) { - this->mirror |= (u8)(1 << i_item); + this->mMirror |= (u8)(1 << i_item); } BOOL dSv_player_collect_c::isCollectMirror(u8 i_item) const { - return this->mirror & (u8)(1 << i_item) ? TRUE : FALSE; + return this->mMirror & (u8)(1 << i_item) ? TRUE : FALSE; } void dSv_player_wolf_c::init(void) { @@ -738,10 +738,10 @@ void dSv_player_wolf_c::init(void) { void dSv_light_drop_c::init(void) { for (int i = 0; i < 4; i++) { - this->light_drop_counts[i] = 0; + this->mLightDropCounts[i] = 0; } - this->light_drop_get_flag = 0; + this->mLightDropGetFlag = 0; for (int i = 0; i < 3; i++) { this->unk5[i] = 0; @@ -750,7 +750,7 @@ void dSv_light_drop_c::init(void) { void dSv_light_drop_c::setLightDropNum(u8 i_nowLevel, u8 param_2) { if ((i_nowLevel < LIGHT_DROP_STAGE) || (i_nowLevel > 6)) { - this->light_drop_counts[i_nowLevel] = param_2; + this->mLightDropCounts[i_nowLevel] = param_2; } } @@ -758,12 +758,12 @@ u8 dSv_light_drop_c::getLightDropNum(u8 i_nowLevel) const { if ((i_nowLevel >= LIGHT_DROP_STAGE) && (i_nowLevel <= 6)) { return 0; } - return this->light_drop_counts[i_nowLevel]; + return this->mLightDropCounts[i_nowLevel]; } void dSv_light_drop_c::onLightDropGetFlag(u8 i_nowLevel) { if ((i_nowLevel < LIGHT_DROP_STAGE) || (i_nowLevel > 6)) { - this->light_drop_get_flag |= (u8)(1 << i_nowLevel); + this->mLightDropGetFlag |= (u8)(1 << i_nowLevel); } } @@ -771,13 +771,13 @@ BOOL dSv_light_drop_c::isLightDropGetFlag(u8 i_nowLevel) const { if ((i_nowLevel >= LIGHT_DROP_STAGE) && (i_nowLevel <= 6)) { return 0; } - return this->light_drop_get_flag & (u8)(1 << i_nowLevel) ? TRUE : FALSE; + return this->mLightDropGetFlag & (u8)(1 << i_nowLevel) ? TRUE : FALSE; } void dSv_letter_info_c::init(void) { for (int i = 0; i < 2; i++) { - this->letter_get_bitfields[i] = 0; - this->letter_read_bitfields[i] = 0; + this->mLetterGetBitfields[i] = 0; + this->mLetterReadBitfields[i] = 0; } for (int i = 0; i < LETTER_INFO_BIT; i++) { @@ -786,31 +786,31 @@ void dSv_letter_info_c::init(void) { } void dSv_letter_info_c::onLetterGetFlag(int i_no) { - this->letter_get_bitfields[i_no >> 0x5] |= 0x1 << (i_no & 0x1F); + this->mLetterGetBitfields[i_no >> 0x5] |= 0x1 << (i_no & 0x1F); } BOOL dSv_letter_info_c::isLetterGetFlag(int i_no) const { - return this->letter_get_bitfields[i_no >> 0x5] & (1 << (i_no & 0x1F)) ? TRUE : FALSE; + return this->mLetterGetBitfields[i_no >> 0x5] & (1 << (i_no & 0x1F)) ? TRUE : FALSE; } void dSv_letter_info_c::onLetterReadFlag(int i_no) { - this->letter_read_bitfields[i_no >> 0x5] |= 0x1 << (i_no & 0x1F); + this->mLetterReadBitfields[i_no >> 0x5] |= 0x1 << (i_no & 0x1F); } BOOL dSv_letter_info_c::isLetterReadFlag(int i_no) const { - return this->letter_read_bitfields[i_no >> 5] & 1 << (i_no & 0x1F) ? TRUE : FALSE; + return this->mLetterReadBitfields[i_no >> 5] & 1 << (i_no & 0x1F) ? TRUE : FALSE; } void dSv_fishing_info_c::init(void) { for (int i = 0; i < 16; i++) { - this->fish_count[i] = 0; + this->mFishCount[i] = 0; this->unk32[i] = 0; } } void dSv_fishing_info_c::addFishCount(u8 fish_index) { - if (this->fish_count[fish_index] < 999) { - this->fish_count[fish_index] += 1; + if (this->mFishCount[fish_index] < 999) { + this->mFishCount[fish_index] += 1; } } @@ -855,20 +855,20 @@ asm void dSv_player_info_c::init(void) { #endif void dSv_player_config_c::init(void) { - OSSoundMode os_sound_mode; + OSSoundMode os_mSoundMode; this->unk0 = 1; - os_sound_mode = OSGetSoundMode(); - if (os_sound_mode == SOUND_MODE_MONO) { - this->sound_mode = 0; + os_mSoundMode = OSGetSoundMode(); + if (os_mSoundMode == SOUND_MODE_MONO) { + this->mSoundMode = 0; Z2AudioMgr_NS_setOutputMode(lbl_80451368, 0); } else { - this->sound_mode = 1; + this->mSoundMode = 1; Z2AudioMgr_NS_setOutputMode(lbl_80451368, 1); } this->unk2 = 0; - this->vibration_status = 1; + this->mVibrationStatus = 1; this->unk4 = 0; this->unk5 = 0; this->unk9 = 0; @@ -891,19 +891,19 @@ asm u32 dSv_player_config_c::checkVibration(void) const { #endif u8 dSv_player_config_c::getSound(void) { - return this->sound_mode; + return this->mSoundMode; } -void dSv_player_config_c::setSound(u8 i_sound_mode) { - this->sound_mode = i_sound_mode; +void dSv_player_config_c::setSound(u8 i_mSoundMode) { + this->mSoundMode = i_mSoundMode; } u8 dSv_player_config_c::getVibration(void) { - return this->vibration_status; + return this->mVibrationStatus; } -void dSv_player_config_c::setVibration(u8 i_vibration_status) { - this->vibration_status = i_vibration_status; +void dSv_player_config_c::setVibration(u8 i_mVibrationStatus) { + this->mVibrationStatus = i_mVibrationStatus; } void dSv_player_c::init(void) { @@ -922,7 +922,7 @@ void dSv_player_c::init(void) { light_drop.init(); letter_info.init(); fishing_info.init(); - player_info.init(); + mPlayerInfo.init(); player_config.init(); }