Skip to content

Commit

Permalink
Revert "StartingNotebook (#68)" (#69)
Browse files Browse the repository at this point in the history
This reverts commit 09d5cff.
  • Loading branch information
PhlexPlexico authored May 28, 2024
1 parent 09d5cff commit ab8bd0b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 24 deletions.
17 changes: 15 additions & 2 deletions code/include/rnd/settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ namespace rnd {
LOGIC_GLITCHED,
};

enum class KnowSetting : u8 {
KNOW_BASIC,
KNOW_ADVANCED,
// KNOW_COMPLETE,
};

enum class AmmoDropsSetting : u8 {
AMMODROPS_VANILLA,
AMMODROPS_BOMBCHU,
Expand Down Expand Up @@ -245,13 +251,20 @@ namespace rnd {
PLAY_ON_CITRA,
} PlayOption;

typedef enum {
REGION_NA,
REGION_EUR,
} Region;

typedef struct {
u8 hashIndexes[5];

u8 playOption;
u8 region;

u8 logic;
u8 locationsReachable;
u8 knowTheGame;

u8 shuffleDungeonEntrances;
u8 bombchusInLogic;
Expand Down Expand Up @@ -313,7 +326,6 @@ namespace rnd {

u8 startingConsumables;
u8 startingMaxRupees;
u8 startingNotebook;
u8 startingOcarina;
u8 startingHerosBow;
u8 startingFireArrows;
Expand Down Expand Up @@ -404,6 +416,7 @@ namespace rnd {
u8 enableFastOcarina;
u8 enableFastArrowSwap;
u8 twinmoldRestoration;
u8 enableNoAnimationTransform;

// Cutscene Skips
u8 skipHMSCutscenes;
Expand All @@ -416,7 +429,7 @@ namespace rnd {
u32 customMaskButton = 0;
u32 customNotebookButton = 0;
u32 customIngameSpoilerButton = 0;
u8 enableNoAnimationTransform;

// Extra MM Settings
u8 blastMaskCooldown;
} SettingsContext;
Expand Down
14 changes: 3 additions & 11 deletions code/source/rnd/savefile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ namespace rnd {
gSettingsContext.skipBombersMinigame = 1;
gSettingsContext.freeScarecrow = 1;
saveData.activate_dungeon_skip_portal_0xF0_for_all = 0xF0;
SaveFile_FillOverWorldMapData();
// SaveFile_FillOverWorldMapData();
saveData.inventory.collect_register.oath_to_order = 1;

// Boss Remains
Expand Down Expand Up @@ -366,7 +366,7 @@ namespace rnd {
// game::SaveData& saveBackupData = game::GetCommonData().save_backup;
game::SaveData& saveData = game::GetCommonData().save;
// give maps and compasses
if (gSettingsContext.mapsAndCompasses == (u8)MapsAndCompassesSetting::MAPSANDCOMPASSES_ANY_DUNGEON) {
if (gSettingsContext.mapsAndCompasses == (u8)MapsAndCompassesSetting::MAPSANDCOMPASSES_START_WITH) {
saveData.inventory.woodfall_dungeon_items.map = 1;
saveData.inventory.woodfall_dungeon_items.compass = 1;
saveData.inventory.snowhead_dungeon_items.map = 1;
Expand All @@ -376,9 +376,6 @@ namespace rnd {
saveData.inventory.stone_tower_dungeon_items.map = 1;
saveData.inventory.stone_tower_dungeon_items.compass = 1;
}
if (gSettingsContext.mapsAndCompasses == (u8)MapsAndCompassesSetting::MAPSANDCOMPASSES_OVERWORLD) {
SaveFile_FillOverWorldMapData();
}

// give small keys
if (gSettingsContext.keysanity == (u8)KeysanitySetting::KEYSANITY_START_WITH) {
Expand Down Expand Up @@ -468,7 +465,7 @@ namespace rnd {
} else {
saveData.inventory.inventory_count_register.quiver_upgrade = game::Quiver::NoQuiver;
#ifdef ENABLE_DEBUG
saveData.inventory.inventory_count_register.quiver_upgrade = game::Quiver::Quiver50;
// saveData.inventory.inventory_count_register.quiver_upgrade = game::Quiver::Quiver50;
// rnd::util::GetPointer<void(game::ItemId, int)>(0x21d440)(game::ItemId::Arrow, 0x1e);
#endif
}
Expand Down Expand Up @@ -779,11 +776,6 @@ namespace rnd {
if (gSettingsContext.startingSpinSettting == (u8)StartingSpinSetting::STARTINGSPIN_GREAT) {
saveData.has_great_spin_0x02 = 2;
}

//Notebook
if(gSettingsContext.startingNotebook > 0) {
saveData.inventory.collect_register.bombers_notebook = 1;
}
}

void SaveFile_ResetItemSlotsIfMatchesID(u8 itemSlot) {
Expand Down
14 changes: 3 additions & 11 deletions code/source/rnd/spoiler_data.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,22 +132,14 @@ namespace rnd {
if ((scene == 0x5E) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x22, flag);
}
// Snowhead Tingle Ranch Map (Winter) > Snowhead Tingle Ranch Map (Spring)
if ((scene == 0x5D) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
// Ranch Tingle Ranch Map > Snowhead Tingle Snowhead Map (Winter)
if ((scene == 0x22) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x5E, flag);
}
// Snowhead Tingle Ranch Map (Spring) > Snowhead Tingle Ranch Map (Winter)
if ((scene == 0x5E) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x5D, flag);
}
// Ranch Tingle Ranch Map > Snowhead Tingle Ranch Map (Winter)
// Ranch Tingle Ranch Map > Snowhead Tingle Snowhead Map (Spring)
if ((scene == 0x22) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x5D, flag);
}
// Ranch Tingle Ranch Map > Snowhead Tingle Ranch Map (Spring)
if ((scene == 0x22) && (flag == 0xB7) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x5E, flag);
}
// Ranch Tingle Great Bay Map > Great Bay Tingle Great Bay Map
if ((scene == 0x22) && (flag == 0xB8) && (type == ItemOverride_Type::OVR_BASE_ITEM)) {
SpoilerData_UpdateMultiLocations(type, 0x37, flag);
Expand Down

0 comments on commit ab8bd0b

Please sign in to comment.