liblcf
Loading...
Searching...
No Matches
rpg_skill.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_SKILL_H
13#define LCF_RPG_SKILL_H
14
15// Headers
16#include <stdint.h>
17#include <string>
18#include <vector>
19#include "enum_tags.h"
21#include "rpg_sound.h"
22
26namespace RPG {
27 class Skill {
28 public:
29 enum Type {
35 };
36 static constexpr auto kTypeTags = makeEnumTags<Type>(
37 "normal",
38 "teleport",
39 "escape",
40 "switch",
41 "subskill"
42 );
43 enum SpType {
46 };
47 static constexpr auto kSpTypeTags = makeEnumTags<SpType>(
48 "cost",
49 "percent"
50 );
51 enum Scope {
56 Scope_party = 4
57 };
58 static constexpr auto kScopeTags = makeEnumTags<Scope>(
59 "enemy",
60 "enemies",
61 "self",
62 "ally",
63 "party"
64 );
65
66 int ID = 0;
67 std::string name;
68 std::string description;
69 std::string using_message1;
70 std::string using_message2;
71 int32_t failure_message = 0;
72 int32_t type = 0;
73 int32_t sp_type = 0;
74 int32_t sp_percent = 0;
75 int32_t sp_cost = 0;
76 int32_t scope = 0;
77 int32_t switch_id = 1;
78 int32_t animation_id = 1;
80 bool occasion_field = true;
81 bool occasion_battle = false;
83 int32_t physical_rate = 0;
84 int32_t magical_rate = 3;
85 int32_t variance = 4;
86 int32_t power = 0;
87 int32_t hit = 100;
88 bool affect_hp = false;
89 bool affect_sp = false;
90 bool affect_attack = false;
91 bool affect_defense = false;
92 bool affect_spirit = false;
93 bool affect_agility = false;
94 bool absorb_damage = false;
95 bool ignore_defense = false;
96 std::vector<bool> state_effects;
97 std::vector<bool> attribute_effects;
98 bool affect_attr_defence = false;
99 int32_t battler_animation = -1;
100 std::vector<BattlerAnimationData> battler_animation_data;
101 };
102
103 inline bool operator==(const Skill& l, const Skill& r) {
104 return l.name == r.name
105 && l.description == r.description
109 && l.type == r.type
110 && l.sp_type == r.sp_type
111 && l.sp_percent == r.sp_percent
112 && l.sp_cost == r.sp_cost
113 && l.scope == r.scope
114 && l.switch_id == r.switch_id
115 && l.animation_id == r.animation_id
116 && l.sound_effect == r.sound_effect
121 && l.magical_rate == r.magical_rate
122 && l.variance == r.variance
123 && l.power == r.power
124 && l.hit == r.hit
125 && l.affect_hp == r.affect_hp
126 && l.affect_sp == r.affect_sp
138 }
139
140 inline bool operator!=(const Skill& l, const Skill& r) {
141 return !(l == r);
142 }
143}
144
145#endif
@ Scope_self
Definition: rpg_skill.h:54
@ Scope_enemy
Definition: rpg_skill.h:52
@ Scope_party
Definition: rpg_skill.h:56
@ Scope_enemies
Definition: rpg_skill.h:53
@ Scope_ally
Definition: rpg_skill.h:55
bool reverse_state_effect
Definition: rpg_skill.h:82
int32_t switch_id
Definition: rpg_skill.h:77
@ SpType_percent
Definition: rpg_skill.h:45
@ SpType_cost
Definition: rpg_skill.h:44
@ Type_normal
Definition: rpg_skill.h:30
@ Type_escape
Definition: rpg_skill.h:32
@ Type_switch
Definition: rpg_skill.h:33
@ Type_subskill
Definition: rpg_skill.h:34
@ Type_teleport
Definition: rpg_skill.h:31
Sound sound_effect
Definition: rpg_skill.h:79
int32_t variance
Definition: rpg_skill.h:85
bool affect_defense
Definition: rpg_skill.h:91
bool affect_hp
Definition: rpg_skill.h:88
int32_t scope
Definition: rpg_skill.h:76
int32_t sp_percent
Definition: rpg_skill.h:74
int32_t type
Definition: rpg_skill.h:72
std::string using_message2
Definition: rpg_skill.h:70
static constexpr auto kTypeTags
Definition: rpg_skill.h:36
int32_t animation_id
Definition: rpg_skill.h:78
bool affect_spirit
Definition: rpg_skill.h:92
int32_t magical_rate
Definition: rpg_skill.h:84
std::string using_message1
Definition: rpg_skill.h:69
int32_t physical_rate
Definition: rpg_skill.h:83
static constexpr auto kSpTypeTags
Definition: rpg_skill.h:47
bool affect_attr_defence
Definition: rpg_skill.h:98
bool affect_agility
Definition: rpg_skill.h:93
bool absorb_damage
Definition: rpg_skill.h:94
std::vector< bool > attribute_effects
Definition: rpg_skill.h:97
std::vector< bool > state_effects
Definition: rpg_skill.h:96
static constexpr auto kScopeTags
Definition: rpg_skill.h:58
int32_t sp_type
Definition: rpg_skill.h:73
int32_t battler_animation
Definition: rpg_skill.h:99
int32_t sp_cost
Definition: rpg_skill.h:75
int32_t failure_message
Definition: rpg_skill.h:71
std::string description
Definition: rpg_skill.h:68
bool affect_attack
Definition: rpg_skill.h:90
std::string name
Definition: rpg_skill.h:67
bool occasion_field
Definition: rpg_skill.h:80
int32_t hit
Definition: rpg_skill.h:87
bool affect_sp
Definition: rpg_skill.h:89
int32_t power
Definition: rpg_skill.h:86
bool occasion_battle
Definition: rpg_skill.h:81
bool ignore_defense
Definition: rpg_skill.h:95
std::vector< BattlerAnimationData > battler_animation_data
Definition: rpg_skill.h:100
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