liblcf
Loading...
Searching...
No Matches
rpg_saveactor.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_SAVEACTOR_H
13#define LCF_RPG_SAVEACTOR_H
14
15// Headers
16#include <stdint.h>
17#include <string>
18#include <vector>
19#include "enum_tags.h"
20
24namespace RPG {
25 class SaveActor {
26 public:
27 enum RowType {
29 RowType_back = 1
30 };
31 static constexpr auto kRowTypeTags = makeEnumTags<RowType>(
32 "front",
33 "back"
34 );
35
36 void Setup(int actor_id);
37 void Fixup(int actor_id);
38 void UnFixup();
39 int ID = 0;
40 std::string name;
41 std::string title;
42 std::string sprite_name;
43 int32_t sprite_id = 0;
44 int32_t transparency = 0;
45 std::string face_name;
46 int32_t face_id = 0;
47 int32_t level = -1;
48 int32_t exp = -1;
49 int32_t hp_mod = -1;
50 int32_t sp_mod = -1;
51 int32_t attack_mod = 0;
52 int32_t defense_mod = 0;
53 int32_t spirit_mod = 0;
54 int32_t agility_mod = 0;
55 int32_t skills_size = -1;
56 std::vector<int16_t> skills;
57 std::vector<int16_t> equipped;
58 int32_t current_hp = -1;
59 int32_t current_sp = -1;
60 std::vector<int32_t> battle_commands;
61 std::vector<int16_t> status;
63 int32_t class_id = -1;
64 int32_t row = 0;
65 bool two_weapon = false;
66 bool lock_equipment = false;
67 bool auto_battle = false;
68 bool super_guard = false;
69 int32_t battler_animation = 0;
70 };
71
72 inline bool operator==(const SaveActor& l, const SaveActor& r) {
73 return l.name == r.name
74 && l.title == r.title
75 && l.sprite_name == r.sprite_name
76 && l.sprite_id == r.sprite_id
78 && l.face_name == r.face_name
79 && l.face_id == r.face_id
80 && l.level == r.level
81 && l.exp == r.exp
82 && l.hp_mod == r.hp_mod
83 && l.sp_mod == r.sp_mod
84 && l.attack_mod == r.attack_mod
85 && l.defense_mod == r.defense_mod
86 && l.spirit_mod == r.spirit_mod
87 && l.agility_mod == r.agility_mod
88 && l.skills_size == r.skills_size
89 && l.skills == r.skills
90 && l.equipped == r.equipped
91 && l.current_hp == r.current_hp
92 && l.current_sp == r.current_sp
94 && l.status == r.status
96 && l.class_id == r.class_id
97 && l.row == r.row
98 && l.two_weapon == r.two_weapon
100 && l.auto_battle == r.auto_battle
101 && l.super_guard == r.super_guard
103 }
104
105 inline bool operator!=(const SaveActor& l, const SaveActor& r) {
106 return !(l == r);
107 }
108}
109
110#endif
std::string face_name
Definition: rpg_saveactor.h:45
std::vector< int32_t > battle_commands
Definition: rpg_saveactor.h:60
int32_t current_hp
Definition: rpg_saveactor.h:58
int32_t spirit_mod
Definition: rpg_saveactor.h:53
int32_t sprite_id
Definition: rpg_saveactor.h:43
void Setup(int actor_id)
Definition: rpg_setup.cpp:21
int32_t battler_animation
Definition: rpg_saveactor.h:69
int32_t agility_mod
Definition: rpg_saveactor.h:54
int32_t current_sp
Definition: rpg_saveactor.h:59
std::vector< int16_t > status
Definition: rpg_saveactor.h:61
void Fixup(int actor_id)
Definition: rpg_fixup.cpp:33
std::vector< int16_t > equipped
Definition: rpg_saveactor.h:57
std::string sprite_name
Definition: rpg_saveactor.h:42
void UnFixup()
Definition: rpg_fixup.cpp:59
std::vector< int16_t > skills
Definition: rpg_saveactor.h:56
int32_t skills_size
Definition: rpg_saveactor.h:55
int32_t attack_mod
Definition: rpg_saveactor.h:51
int32_t class_id
Definition: rpg_saveactor.h:63
std::string title
Definition: rpg_saveactor.h:41
std::string name
Definition: rpg_saveactor.h:40
int32_t defense_mod
Definition: rpg_saveactor.h:52
bool changed_battle_commands
Definition: rpg_saveactor.h:62
static constexpr auto kRowTypeTags
Definition: rpg_saveactor.h:31
int32_t transparency
Definition: rpg_saveactor.h:44
Definition: rpg_actor.h:26
bool operator==(const Actor &l, const Actor &r)
Definition: rpg_actor.h:64
bool operator!=(const Actor &l, const Actor &r)
Definition: rpg_actor.h:98