| 75 | } |
| 76 | |
| 77 | void Scene_Menu::CreateCommandWindow() { |
| 78 | // Create Options Window |
| 79 | std::vector<std::string> options; |
| 80 | |
| 81 | if (Player::IsRPG2k()) { |
| 82 | command_options.push_back(Item); |
| 83 | command_options.push_back(Skill); |
| 84 | command_options.push_back(Equipment); |
| 85 | command_options.push_back(Save); |
| 86 | if (Player::player_config.settings_in_menu.Get()) { |
| 87 | command_options.push_back(Settings); |
| 88 | } |
| 89 | if (Player::debug_flag) { |
| 90 | command_options.push_back(Debug); |
| 91 | } |
| 92 | command_options.push_back(Quit); |
| 93 | } else { |
| 94 | for (std::vector<int16_t>::iterator it = lcf::Data::system.menu_commands.begin(); |
| 95 | it != lcf::Data::system.menu_commands.end(); ++it) { |
| 96 | switch (*it) { |
| 97 | case Row: |
| 98 | if (Feature::HasRow()) { |
| 99 | command_options.push_back((CommandOptionType)*it); |
| 100 | } |
| 101 | break; |
| 102 | case Wait: |
| 103 | if (Feature::HasRpg2k3BattleSystem()) { |
| 104 | command_options.push_back((CommandOptionType)*it); |
| 105 | } |
| 106 | break; |
| 107 | default: |
| 108 | command_options.push_back((CommandOptionType)*it); |
| 109 | break; |
| 110 | } |
| 111 | } |
| 112 | if (Player::player_config.settings_in_menu.Get()) { |
| 113 | command_options.push_back(Settings); |
| 114 | } |
| 115 | if (Player::debug_flag) { |
| 116 | command_options.push_back(Debug); |
| 117 | } |
| 118 | command_options.push_back(Quit); |
| 119 | } |
| 120 | |
| 121 | // Add all menu items |
| 122 | std::vector<CommandOptionType>::iterator it; |
| 123 | for (it = command_options.begin(); it != command_options.end(); ++it) { |
| 124 | switch(*it) { |
| 125 | case Item: |
| 126 | options.push_back(ToString(lcf::Data::terms.command_item)); |
| 127 | break; |
| 128 | case Skill: |
| 129 | options.push_back(ToString(lcf::Data::terms.command_skill)); |
| 130 | break; |
| 131 | case Equipment: |
| 132 | options.push_back(ToString(lcf::Data::terms.menu_equipment)); |
| 133 | break; |
| 134 | case Save: |
nothing calls this directly
no test coverage detected