mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-11-15 14:05:06 -05:00
Clarify comments
This commit is contained in:
parent
ea9db56914
commit
0a744cde01
@ -143,7 +143,8 @@ void EnBomBowMan_BlinkAwake(EnBomBowlMan* this, GlobalContext* globalCtx) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for Bomb Bag or Bombchus if Rando is enabled, depending on whether bombchus are considered in logic
|
// In randomizer, only check for bomb bag when bombchus aren't in logic
|
||||||
|
// and only check for bombchus when bombchus are in logic
|
||||||
if (gSaveContext.n64ddFlag) {
|
if (gSaveContext.n64ddFlag) {
|
||||||
u8 bombchusInLogic = Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC);
|
u8 bombchusInLogic = Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC);
|
||||||
if ((!bombchusInLogic && INV_CONTENT(ITEM_BOMB) == ITEM_NONE) ||
|
if ((!bombchusInLogic && INV_CONTENT(ITEM_BOMB) == ITEM_NONE) ||
|
||||||
@ -178,13 +179,14 @@ void EnBomBowMan_CheckBeatenDC(EnBomBowlMan* this, GlobalContext* globalCtx) {
|
|||||||
this->eyeMode = CHU_GIRL_EYES_AWAKE;
|
this->eyeMode = CHU_GIRL_EYES_AWAKE;
|
||||||
this->blinkTimer = (s16)Rand_ZeroFloat(60.0f) + 20;
|
this->blinkTimer = (s16)Rand_ZeroFloat(60.0f) + 20;
|
||||||
|
|
||||||
// Check if beaten Dodongo's Cavern if not rando'd
|
|
||||||
// check for bomb bag or bombchus if rando'd depending on whether chus are in logic
|
|
||||||
bool bombchuBowlingClosed;
|
bool bombchuBowlingClosed;
|
||||||
if (gSaveContext.n64ddFlag) {
|
if (gSaveContext.n64ddFlag) {
|
||||||
|
// when rando'd, check if we have bombchus if chus are in logic
|
||||||
|
// and check if we have a bomb bag if chus aren't in logic
|
||||||
u8 explosive = Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC) ? ITEM_BOMBCHU : ITEM_BOMB;
|
u8 explosive = Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC) ? ITEM_BOMBCHU : ITEM_BOMB;
|
||||||
bombchuBowlingClosed = (INV_CONTENT(explosive) == ITEM_NONE);
|
bombchuBowlingClosed = (INV_CONTENT(explosive) == ITEM_NONE);
|
||||||
} else {
|
} else {
|
||||||
|
// if not rando'd, check if we have beaten Dodongo's Cavern
|
||||||
bombchuBowlingClosed = !((gSaveContext.eventChkInf[2] & 0x20) || BREG(2));
|
bombchuBowlingClosed = !((gSaveContext.eventChkInf[2] & 0x20) || BREG(2));
|
||||||
}
|
}
|
||||||
if (bombchuBowlingClosed) {
|
if (bombchuBowlingClosed) {
|
||||||
|
@ -871,9 +871,12 @@ void EnGirlA_BuyEvent_ZoraTunic(GlobalContext* globalCtx, EnGirlA* this) {
|
|||||||
void EnGirlA_BuyEvent_ObtainBombchuPack(GlobalContext* globalCtx, EnGirlA* this) {
|
void EnGirlA_BuyEvent_ObtainBombchuPack(GlobalContext* globalCtx, EnGirlA* this) {
|
||||||
Rupees_ChangeBy(-this->basePrice);
|
Rupees_ChangeBy(-this->basePrice);
|
||||||
|
|
||||||
|
// Normally, buying a bombchu pack sets a flag indicating the pack is now sold out
|
||||||
|
// If they're in logic for rando, skip setting that flag so they can be purchased repeatedly
|
||||||
if (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC)) {
|
if (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (this->actor.params) {
|
switch (this->actor.params) {
|
||||||
case SI_BOMBCHU_10_2:
|
case SI_BOMBCHU_10_2:
|
||||||
gSaveContext.itemGetInf[0] |= 0x40;
|
gSaveContext.itemGetInf[0] |= 0x40;
|
||||||
@ -1065,6 +1068,7 @@ void EnGirlA_InitializeItemAction(EnGirlA* this, GlobalContext* globalCtx) {
|
|||||||
this->canBuyFunc = itemEntry->canBuyFunc;
|
this->canBuyFunc = itemEntry->canBuyFunc;
|
||||||
this->itemGiveFunc = itemEntry->itemGiveFunc;
|
this->itemGiveFunc = itemEntry->itemGiveFunc;
|
||||||
this->buyEventFunc = itemEntry->buyEventFunc;
|
this->buyEventFunc = itemEntry->buyEventFunc;
|
||||||
|
// If chus are in logic, make the 10 pack affordable without a wallet upgrade
|
||||||
if (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC) &&
|
if (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_BOMBCHUS_IN_LOGIC) &&
|
||||||
this->getItemId == GI_BOMBCHUS_10) {
|
this->getItemId == GI_BOMBCHUS_10) {
|
||||||
this->basePrice = 99;
|
this->basePrice = 99;
|
||||||
|
Loading…
Reference in New Issue
Block a user