Skip to content

Commit

Permalink
Removes some unneeded function definitions (some of which were alread…
Browse files Browse the repository at this point in the history
…y commented out).
  • Loading branch information
leggettc18 committed Jul 26, 2022
1 parent 0ed8c27 commit d0968a9
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 77 deletions.
2 changes: 0 additions & 2 deletions soh/soh/Enhancements/randomizer/randomizer.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,8 @@ class Randomizer {
std::string GetAdultAltarText() const;
std::string GetGanonText() const;
std::string GetGanonHintText() const;
//CustomMessageEntry GetHintFromCheck(RandomizerCheck check);
GetItemID GetRandomizedItemIdFromKnownCheck(RandomizerCheck randomizerCheck, GetItemID ogId);
GetItemID GetRandomizedItemId(GetItemID ogId, s16 actorId, s16 actorParams, s16 sceneNum);
//std::string GetCustomGetItemMessage(GlobalContext* globalCtx, GetItemID giid);
static void CreateCustomMessages();
};

Expand Down
72 changes: 0 additions & 72 deletions soh/soh/OTRGlobals.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1423,78 +1423,6 @@ extern "C" CustomMessageEntry Randomizer_CopyScrubMessage(u16 scrubTextId) {
return CustomMessageManager::Instance->RetrieveMessage(Randomizer::scrubMessageTableID, price);
}

extern "C" int CopyScrubMessage(u16 scrubTextId, char* buffer, const int maxBufferSize) {
std::string scrubText("");
int language = CVar_GetS32("gLanguages", 0);
int price = 0;
switch (scrubTextId) {
case 0x10A2:
price = 10;
break;
case 0x10DC:
case 0x10DD:
price = 40;
break;
}
switch (language) {
case 0: default:
scrubText += 0x12; // add the sound
scrubText += 0x38; // sound id
scrubText += 0x82; // sound id
scrubText += "All right! You win! In return for";
scrubText += 0x01; // newline
scrubText += "sparing me, I will sell you a";
scrubText += 0x01; // newline
scrubText += 0x05; // change the color
scrubText += 0x42; // green
scrubText += "mysterious item";
scrubText += 0x05; // change the color
scrubText += 0x40; // white
scrubText += "!";
scrubText += 0x01; // newline
scrubText += 0x05; // change the color
scrubText += 0x41; // red
scrubText += std::to_string(price);
scrubText += price > 1 ? " Rupees" : " Rupee";
scrubText += 0x05; // change the color
scrubText += 0x40; // white
scrubText += " it is!";
scrubText += 0x07; // go to a new message
scrubText += 0x10; // message id
scrubText += 0xA3; // message id
break;
case 2:
scrubText += 0x12; // add the sound
scrubText += 0x38; // sound id
scrubText += 0x82; // sound id
scrubText += "J'abandonne! Tu veux bien m'acheter";
scrubText += 0x01; // newline
scrubText += "un ";
scrubText += 0x05; // change the color
scrubText += 0x42; // green
scrubText += "objet myst\x96rieux";
//scrubText += ";
scrubText += 0x05; // change the color
scrubText += 0x40; // white
scrubText += "?";
scrubText += 0x01; // newline
scrubText += "\x84";
scrubText += "a fera ";
scrubText += 0x05; // change the color
scrubText += 0x41; // red
scrubText += std::to_string(price) + " Rubis";
scrubText += 0x05; // change the color
scrubText += 0x40; // white
scrubText += "!";
scrubText += 0x07; // go to a new message
scrubText += 0x10; // message id
scrubText += 0xA3; // message id
break;
}

return CopyStringToCharBuffer(scrubText, buffer, maxBufferSize);
}

extern "C" CustomMessageEntry Randomizer_CopyAltarMessage() {
return (LINK_IS_ADULT) ? CustomMessageManager::Instance->RetrieveMessage(Randomizer::hintMessageTableID, 0x7088)
: CustomMessageManager::Instance->RetrieveMessage(Randomizer::hintMessageTableID, 0x7040);
Expand Down
3 changes: 0 additions & 3 deletions soh/soh/OTRGlobals.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,6 @@ Sprite* GetSeedTexture(uint8_t index);
void Randomizer_LoadSettings(const char* spoilerFileName);
u8 Randomizer_GetSettingValue(RandomizerSettingKey randoSettingKey);
RandomizerCheck Randomizer_GetCheckFromActor(s16 actorId, s16 actorParams, s16 sceneNum);
int Randomizer_CopyAltarMessage(char* buffer, const int maxBufferSize);
int Randomizer_CopyGanonText(char* buffer, const int maxBufferSize);
int Randomizer_CopyGanonHintText(char* buffer, const int maxBufferSize);
void Randomizer_LoadHintLocations(const char* spoilerFileName);
void Randomizer_LoadItemLocations(const char* spoilerFileName, bool silent);
s16 Randomizer_GetItemModelFromId(s16 itemId);
Expand Down

0 comments on commit d0968a9

Please sign in to comment.