| 81 | } |
| 82 | |
| 83 | void Window_ShopBuy::UpdateHelp() { |
| 84 | std::string help_text = ""; |
| 85 | if (!data.empty()) { |
| 86 | const lcf::rpg::Item* item = lcf::ReaderUtil::GetElement(lcf::Data::items, data[index]); |
| 87 | if (item) { |
| 88 | help_text = ToString(item->description); |
| 89 | } else { |
| 90 | help_text = "??? BAD ITEM ???"; |
| 91 | } |
| 92 | } |
| 93 | |
| 94 | help_window->SetText(std::move(help_text)); |
| 95 | } |
| 96 | |
| 97 | bool Window_ShopBuy::CheckEnable(int item_id) { |
| 98 | const lcf::rpg::Item* item = lcf::ReaderUtil::GetElement(lcf::Data::items, item_id); |