Fix dialogue choices being displayed in incorrect order

deque
scrawl 10 years ago
parent be7839873a
commit ac97a0f99d

@ -509,7 +509,7 @@ namespace MWGui
const MyGUI::Colour linkHot (223/255.f, 201/255.f, 159/255.f);
const MyGUI::Colour linkNormal (150/255.f, 50/255.f, 30/255.f);
const MyGUI::Colour linkActive (243/255.f, 237/255.f, 221/255.f);
for (std::map<std::string, int>::reverse_iterator it = mChoices.rbegin(); it != mChoices.rend(); ++it)
for (std::vector<std::pair<std::string, int> >::iterator it = mChoices.begin(); it != mChoices.end(); ++it)
{
Choice* link = new Choice(it->second);
mLinks.push_back(link);
@ -600,7 +600,7 @@ namespace MWGui
void DialogueWindow::addChoice(const std::string& choice, int id)
{
mChoices[choice] = id;
mChoices.push_back(std::make_pair(choice, id));
updateHistory();
}

@ -161,7 +161,7 @@ namespace MWGui
bool mGoodbye;
std::vector<DialogueText*> mHistoryContents;
std::map<std::string, int> mChoices;
std::vector<std::pair<std::string, int> > mChoices;
std::vector<Link*> mLinks;
std::map<std::string, Link*> mTopicLinks;

Loading…
Cancel
Save