liblcf
rpg_saveinventory.h
Go to the documentation of this file.
1 /* !!!! GENERATED FILE - DO NOT EDIT !!!!
2  * --------------------------------------
3  *
4  * This file is part of liblcf. Copyright (c) 2020 liblcf authors.
5  * https://github.com/EasyRPG/liblcf - https://easyrpg.org
6  *
7  * liblcf is Free/Libre Open Source Software, released under the MIT License.
8  * For the full copyright and license information, please view the COPYING
9  * file that was distributed with this source code.
10  */
11 
12 #ifndef LCF_RPG_SAVEINVENTORY_H
13 #define LCF_RPG_SAVEINVENTORY_H
14 
15 // Headers
16 #include <stdint.h>
17 #include <vector>
18 
22 namespace RPG {
23  class SaveInventory {
24  public:
25  void Setup();
26  std::vector<int16_t> party;
27  std::vector<int16_t> item_ids;
28  std::vector<uint8_t> item_counts;
29  std::vector<uint8_t> item_usage;
30  int32_t gold = 0;
31  int32_t timer1_frames = 0;
32  bool timer1_active = false;
33  bool timer1_visible = false;
34  bool timer1_battle = false;
35  int32_t timer2_frames = 0;
36  bool timer2_active = false;
37  bool timer2_visible = false;
38  bool timer2_battle = false;
39  int32_t battles = 0;
40  int32_t defeats = 0;
41  int32_t escapes = 0;
42  int32_t victories = 0;
43  int32_t turns = 0;
44  int32_t steps = 0;
45  };
46 
47  inline bool operator==(const SaveInventory& l, const SaveInventory& r) {
48  return l.party == r.party
49  && l.item_ids == r.item_ids
50  && l.item_counts == r.item_counts
51  && l.item_usage == r.item_usage
52  && l.gold == r.gold
61  && l.battles == r.battles
62  && l.defeats == r.defeats
63  && l.escapes == r.escapes
64  && l.victories == r.victories
65  && l.turns == r.turns
66  && l.steps == r.steps;
67  }
68 
69  inline bool operator!=(const SaveInventory& l, const SaveInventory& r) {
70  return !(l == r);
71  }
72 }
73 
74 #endif
RPG::operator==
bool operator==(const Actor &l, const Actor &r)
Definition: rpg_actor.h:64
RPG::SaveInventory
Definition: rpg_saveinventory.h:23
RPG::SaveInventory::timer1_active
bool timer1_active
Definition: rpg_saveinventory.h:32
RPG::SaveInventory::timer1_battle
bool timer1_battle
Definition: rpg_saveinventory.h:34
RPG
Definition: rpg_actor.h:26
RPG::SaveInventory::timer1_visible
bool timer1_visible
Definition: rpg_saveinventory.h:33
RPG::SaveInventory::battles
int32_t battles
Definition: rpg_saveinventory.h:39
RPG::SaveInventory::turns
int32_t turns
Definition: rpg_saveinventory.h:43
RPG::SaveInventory::timer1_frames
int32_t timer1_frames
Definition: rpg_saveinventory.h:31
RPG::SaveInventory::escapes
int32_t escapes
Definition: rpg_saveinventory.h:41
RPG::SaveInventory::victories
int32_t victories
Definition: rpg_saveinventory.h:42
RPG::SaveInventory::timer2_frames
int32_t timer2_frames
Definition: rpg_saveinventory.h:35
RPG::SaveInventory::Setup
void Setup()
Definition: rpg_setup.cpp:59
RPG::SaveInventory::timer2_active
bool timer2_active
Definition: rpg_saveinventory.h:36
RPG::operator!=
bool operator!=(const Actor &l, const Actor &r)
Definition: rpg_actor.h:98
RPG::SaveInventory::steps
int32_t steps
Definition: rpg_saveinventory.h:44
RPG::SaveInventory::item_counts
std::vector< uint8_t > item_counts
Definition: rpg_saveinventory.h:28
RPG::SaveInventory::party
std::vector< int16_t > party
Definition: rpg_saveinventory.h:26
RPG::SaveInventory::gold
int32_t gold
Definition: rpg_saveinventory.h:30
RPG::SaveInventory::defeats
int32_t defeats
Definition: rpg_saveinventory.h:40
RPG::SaveInventory::item_usage
std::vector< uint8_t > item_usage
Definition: rpg_saveinventory.h:29
RPG::SaveInventory::item_ids
std::vector< int16_t > item_ids
Definition: rpg_saveinventory.h:27
RPG::SaveInventory::timer2_battle
bool timer2_battle
Definition: rpg_saveinventory.h:38
RPG::SaveInventory::timer2_visible
bool timer2_visible
Definition: rpg_saveinventory.h:37