1 /* 2 * This file is part of EasyRPG Player. 3 * 4 * EasyRPG Player is free software: you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation, either version 3 of the License, or 7 * (at your option) any later version. 8 * 9 * EasyRPG Player is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with EasyRPG Player. If not, see <http://www.gnu.org/licenses/>. 16 */ 17 18 #ifndef EP_SCENE_EQUIP_H 19 #define EP_SCENE_EQUIP_H 20 21 // Headers 22 #include <vector> 23 #include "scene.h" 24 #include "window_equipitem.h" 25 #include "window_equip.h" 26 #include "window_equipstatus.h" 27 #include "window_help.h" 28 29 /** 30 * Scene Equip class. 31 * Displays the equipment of a hero. 32 */ 33 class Scene_Equip : public Scene { 34 35 public: 36 /** 37 * Constructor. 38 * 39 * @param actor actor in the party. 40 * @param equip_index selected equipment. 41 */ 42 Scene_Equip(Game_Actor& actor, int equip_index = 0); 43 44 void Start() override; 45 void Update() override; 46 47 /** 48 * Updates the item windows. 49 */ 50 void UpdateItemWindows(); 51 52 /** 53 * Updates the equip window. 54 */ 55 void UpdateEquipWindow(); 56 57 /** 58 * Updates the status window. 59 */ 60 void UpdateStatusWindow(); 61 62 /** 63 * Updates the equip window. 64 */ 65 void UpdateEquipSelection(); 66 67 /** 68 * Updates the item window. 69 */ 70 void UpdateItemSelection(); 71 72 private: 73 /** Actor in the party whose equipment is displayed. */ 74 Game_Actor& actor; 75 /** Selected equipment on startup. */ 76 int equip_index; 77 78 /** Displays available items in a category. */ 79 std::vector<std::shared_ptr<Window_EquipItem> > item_windows; 80 /** Current active item window. */ 81 std::shared_ptr<Window_EquipItem> item_window; 82 /** Displays stats of the hero/item. */ 83 std::unique_ptr<Window_EquipStatus> equipstatus_window; 84 /** Displays currently equipped items. */ 85 std::unique_ptr<Window_Equip> equip_window; 86 /** Displays description about the selected item. */ 87 std::unique_ptr<Window_Help> help_window; 88 }; 89 90 #endif 91