Merge bfbeb19113
into 67ee5f8d0e
This commit is contained in:
commit
d6e0dae5dd
|
@ -287,7 +287,7 @@ Text AutoFormatHintText(const Text& unformattedHintText, const std::vector<std::
|
|||
strings[i] = textStr;
|
||||
}
|
||||
|
||||
return {strings[0], strings[1], ""/*spanish*/, strings[2]};
|
||||
return {strings[0], strings[2], ""/*spanish*/, strings[1]};
|
||||
}
|
||||
|
||||
std::array<DungeonHintInfo, 10> dungeonInfoData;
|
||||
|
@ -615,6 +615,7 @@ void CreateGanonAndSheikText() {
|
|||
}
|
||||
|
||||
ctx->AddHint(RH_GANONDORF_HINT, AutoFormatHintText(ganonHintText), lightArrowLocation[0], HINT_TYPE_STATIC, "Static", lightArrowArea);
|
||||
ctx->AddHint(RH_GANONDORF_NOHINT, AutoFormatHintText(ganonText), lightArrowLocation[0], HINT_TYPE_STATIC, "Static", lightArrowArea);
|
||||
|
||||
if (!ctx->GetOption(RSK_TRIAL_COUNT).Is(0)) {
|
||||
sheikText = ::Hint(RHT_SHEIK_LIGHT_ARROW_HINT).GetText() + LightArrowAreaText + "%w.";
|
||||
|
@ -963,7 +964,7 @@ static void DistributeHints(std::vector<uint8_t>& selected, size_t stoneCount, s
|
|||
for (uint8_t distribution = 0; distribution < distTable.size(); distribution++){
|
||||
currentWeight -= distTable[distribution].weight;
|
||||
if (currentWeight <= 0){
|
||||
if (stoneCount >= distTable[distribution].copies){
|
||||
if (stoneCount >= distTable[distribution].copies || distTable[distribution].copies == 0){
|
||||
selected[distribution] += 1;
|
||||
stoneCount -= distTable[distribution].copies;
|
||||
break;
|
||||
|
@ -1074,8 +1075,9 @@ void CreateStoneHints() {
|
|||
|
||||
while(totalStones != 0){
|
||||
totalStones = PlaceHints(selectedHints, distTable);
|
||||
if (totalStones != 0){
|
||||
while (totalStones != 0){
|
||||
DistributeHints(selectedHints, totalStones, distTable, hintSetting.junkWeight, false);
|
||||
totalStones = PlaceHints(selectedHints, distTable);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -13,13 +13,19 @@ public:
|
|||
: english(std::move(english_)),
|
||||
french(std::move(french_)),
|
||||
spanish(std::move(spanish_)),
|
||||
german(std::move("")) {}
|
||||
german(std::move("")) {
|
||||
// german defaults to english text until a translation is provided.
|
||||
german = english;
|
||||
}
|
||||
Text(std::string english_, std::string french_, std::string spanish_, std::string german_)
|
||||
: english(std::move(english_)),
|
||||
french(std::move(french_)),
|
||||
spanish(std::move(spanish_)),
|
||||
german(std::move(german_)) {}
|
||||
Text(std::string english_) : english(std::move(english_)), french(std::move("")), spanish(std::move("")), german(std::move("")) {}
|
||||
Text(std::string english_) : english(std::move(english_)), french(std::move("")), spanish(std::move("")), german(std::move("")) {
|
||||
// default unprovided languages to english text
|
||||
french = spanish = german = english;
|
||||
}
|
||||
|
||||
const std::string& GetEnglish() const {
|
||||
return english;
|
||||
|
|
|
@ -47,6 +47,10 @@ const std::string& Hint::GetDistribution() {
|
|||
|
||||
void Hint::ResetVariables() {
|
||||
hintedLocation = RC_UNKNOWN_CHECK;
|
||||
text = Text{};
|
||||
distribution = "";
|
||||
hintedArea = RA_NONE;
|
||||
hintType = HINT_TYPE_STATIC;
|
||||
addedToPool = false;
|
||||
}
|
||||
}
|
|
@ -271,7 +271,7 @@ void Randomizer::LoadHintMessages() {
|
|||
CustomMessage(ctx->GetHint(RH_GANONDORF_HINT)->GetText()));
|
||||
CustomMessageManager::Instance->CreateMessage(
|
||||
Randomizer::hintMessageTableID, TEXT_GANONDORF_NOHINT,
|
||||
CustomMessage(ctx->GetHint(RH_SARIA)->GetText()));//RANDOTODO: Change to RH_BLANK or remove {{message}} replacment
|
||||
CustomMessage(ctx->GetHint(RH_GANONDORF_NOHINT)->GetText()));
|
||||
CustomMessageManager::Instance->CreateMessage(
|
||||
Randomizer::hintMessageTableID, TEXT_SHEIK_NEED_HOOK,
|
||||
CustomMessage("{{message}}", "{{message}}", "{{message}}"));
|
||||
|
|
Loading…
Reference in New Issue