mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-11-25 19:02:19 -05:00
Check Tracker
- Adds support for merchants - Fixes #7 for Bomchu Salesman - Fixes #12 for Medigoron
This commit is contained in:
parent
65b4125c7c
commit
b4d9b4cad2
@ -83,7 +83,7 @@ void LocationTable_Init() {
|
||||
|
||||
//Haunted Wasteland
|
||||
locationTable[WASTELAND_CHEST] = ItemLocation::Chest (RC_WASTELAND_CHEST, 0x5E, 0x00, "Wasteland Chest", WASTELAND_CHEST, PURPLE_RUPEE, {Category::cHauntedWasteland,}, SpoilerCollectionCheckGroup::GROUP_GERUDO_VALLEY);
|
||||
locationTable[WASTELAND_BOMBCHU_SALESMAN] = ItemLocation::Base (RC_WASTELAND_BOMBCHU_SALESMAN, 0x5E, 0x03, "Wasteland Carpet Salesman", WASTELAND_BOMBCHU_SALESMAN, BOMBCHU_10, {Category::cHauntedWasteland, Category::cMerchant,}, SpoilerCollectionCheck::EventChkInf(0x34), SpoilerCollectionCheckGroup::GROUP_GERUDO_VALLEY);
|
||||
locationTable[WASTELAND_BOMBCHU_SALESMAN] = ItemLocation::Base (RC_WASTELAND_BOMBCHU_SALESMAN, 0x5E, 0x03, "Wasteland Carpet Salesman", WASTELAND_BOMBCHU_SALESMAN, BOMBCHU_10, {Category::cHauntedWasteland, Category::cMerchant,}, SpoilerCollectionCheck::Merchant(0x5E, 0x86), SpoilerCollectionCheckGroup::GROUP_GERUDO_VALLEY);
|
||||
|
||||
//Desert Colossus
|
||||
locationTable[COLOSSUS_FREESTANDING_POH] = ItemLocation::Collectable(RC_COLOSSUS_FREESTANDING_POH, 0x5C, 0x0D, "Colossus Freestanding PoH", COLOSSUS_FREESTANDING_POH, PIECE_OF_HEART, {Category::cDesertColossus,}, SpoilerCollectionCheckGroup::GROUP_GERUDO_VALLEY);
|
||||
@ -153,7 +153,7 @@ void LocationTable_Init() {
|
||||
locationTable[GC_DEKU_SCRUB_GROTTO_LEFT] = ItemLocation::GrottoScrub(RC_GC_DEKU_SCRUB_GROTTO_LEFT, 0xFB, 0x30, "GC Deku Scrub Grotto Left", GC_DEKU_SCRUB_GROTTO_LEFT, BUY_DEKU_NUT_5, {Category::cGoronCity, Category::cDekuScrub, Category::cGrotto}, SpoilerCollectionCheck::Scrub(0x25, 0x01), SpoilerCollectionCheckGroup::GROUP_GORON_CITY);
|
||||
locationTable[GC_DEKU_SCRUB_GROTTO_RIGHT] = ItemLocation::GrottoScrub(RC_GC_DEKU_SCRUB_GROTTO_RIGHT, 0xFB, 0x37, "GC Deku Scrub Grotto Right", GC_DEKU_SCRUB_GROTTO_RIGHT, BUY_BOMBS_535, {Category::cGoronCity, Category::cDekuScrub, Category::cGrotto}, SpoilerCollectionCheck::Scrub(0x25, 0x06), SpoilerCollectionCheckGroup::GROUP_GORON_CITY);
|
||||
locationTable[GC_DEKU_SCRUB_GROTTO_CENTER] = ItemLocation::GrottoScrub(RC_GC_DEKU_SCRUB_GROTTO_CENTER, 0xFB, 0x33, "GC Deku Scrub Grotto Center", GC_DEKU_SCRUB_GROTTO_CENTER, BUY_ARROWS_30, {Category::cGoronCity, Category::cDekuScrub, Category::cGrotto}, SpoilerCollectionCheck::Scrub(0x25, 0x04), SpoilerCollectionCheckGroup::GROUP_GORON_CITY);
|
||||
locationTable[GC_MEDIGORON] = ItemLocation::Base (RC_GC_MEDIGORON, 0x62, 0x51, "GC Medigoron", GC_MEDIGORON, GIANTS_KNIFE, {Category::cGoronCity, Category::cMerchant,}, SpoilerCollectionCheck::EventChkInf(0x35), SpoilerCollectionCheckGroup::GROUP_GORON_CITY);
|
||||
locationTable[GC_MEDIGORON] = ItemLocation::Base (RC_GC_MEDIGORON, 0x62, 0x51, "GC Medigoron", GC_MEDIGORON, GIANTS_KNIFE, {Category::cGoronCity, Category::cMerchant,}, SpoilerCollectionCheck::Merchant(0x62, 0x87), SpoilerCollectionCheckGroup::GROUP_GORON_CITY);
|
||||
|
||||
//Death Mountain Crater
|
||||
locationTable[DMC_UPPER_GROTTO_CHEST] = ItemLocation::Chest (RC_DMC_UPPER_GROTTO_CHEST, 0x3E, 0x1A, "DMC Upper Grotto Chest", DMC_UPPER_GROTTO_CHEST, BOMBS_20, {Category::cDeathMountainCrater, Category::cDeathMountain, Category::cGrotto}, SpoilerCollectionCheckGroup::GROUP_DEATH_MOUNTAIN);
|
||||
|
@ -83,7 +83,7 @@ enum class ItemLocationType {
|
||||
};
|
||||
|
||||
class SpoilerCollectionCheck {
|
||||
public:
|
||||
public:
|
||||
SpoilerCollectionCheckType type = SpoilerCollectionCheckType::SPOILER_CHK_NONE;
|
||||
uint8_t scene = 0;
|
||||
uint8_t flag = 0;
|
||||
@ -150,6 +150,10 @@ public:
|
||||
static auto MagicBeans(uint8_t scene, uint8_t flag) {
|
||||
return SpoilerCollectionCheck(SpoilerCollectionCheckType::SPOILER_CHK_MAGIC_BEANS, scene, flag);
|
||||
}
|
||||
|
||||
static auto Merchant(int8_t scene, uint8_t flag) {
|
||||
return SpoilerCollectionCheck(SpoilerCollectionCheckType::SPOILER_CHK_MERCHANT, scene, flag);
|
||||
}
|
||||
};
|
||||
|
||||
class ItemLocation {
|
||||
@ -591,6 +595,9 @@ static std::unordered_map<RandomizerCheck, RandomizerInf> randomizerFlagLookup =
|
||||
{ RC_MARKET_BOMBCHU_SHOP_ITEM_6, RAND_INF_SHOP_ITEMS_MARKET_BOMBCHU_SHOP_ITEM_6 },
|
||||
{ RC_MARKET_BOMBCHU_SHOP_ITEM_7, RAND_INF_SHOP_ITEMS_MARKET_BOMBCHU_SHOP_ITEM_7 },
|
||||
{ RC_MARKET_BOMBCHU_SHOP_ITEM_8, RAND_INF_SHOP_ITEMS_MARKET_BOMBCHU_SHOP_ITEM_8 },
|
||||
|
||||
{ RC_WASTELAND_BOMBCHU_SALESMAN, RAND_INF_MERCHANTS_CARPET_SALESMAN },
|
||||
{ RC_GC_MEDIGORON, RAND_INF_MERCHANTS_MEDIGORON },
|
||||
};
|
||||
|
||||
|
||||
|
@ -24,6 +24,7 @@ typedef enum {
|
||||
SPOILER_CHK_POE_POINTS,
|
||||
SPOILER_CHK_SHOP_ITEM,
|
||||
SPOILER_CHK_MAGIC_BEANS,
|
||||
SPOILER_CHK_MERCHANT,
|
||||
} SpoilerCollectionCheckType;
|
||||
|
||||
// Location groups for checks, used to group the checks by logical location
|
||||
|
@ -663,6 +663,7 @@ bool HasItemBeenCollected(RandomizerCheckObject obj) {
|
||||
return gSaveContext.sceneFlags[scene].chest & (1 << flag);
|
||||
case SpoilerCollectionCheckType::SPOILER_CHK_COLLECTABLE:
|
||||
return gSaveContext.sceneFlags[scene].collect & (1 << flag);
|
||||
case SpoilerCollectionCheckType::SPOILER_CHK_MERCHANT:
|
||||
case SpoilerCollectionCheckType::SPOILER_CHK_SHOP_ITEM:
|
||||
case SpoilerCollectionCheckType::SPOILER_CHK_COW:
|
||||
case SpoilerCollectionCheckType::SPOILER_CHK_SCRUB:
|
||||
|
Loading…
Reference in New Issue
Block a user