CommonLibSSE (Parapets fork)
Loading...
Searching...
No Matches
BGSPerk.h
Go to the documentation of this file.
1#pragma once
2
3#include "RE/B/BSTArray.h"
4#include "RE/F/FormTypes.h"
6#include "RE/T/TESCondition.h"
8#include "RE/T/TESForm.h"
9#include "RE/T/TESFullName.h"
10#include "RE/T/TESIcon.h"
11
12namespace RE
13{
14 class BGSPerkEntry;
15
16 struct PerkData // DATA
17 {
18 bool trait; // 0
19 std::int8_t level; // 1
20 std::int8_t numRanks; // 2
21 bool playable; // 3
22 bool hidden; // 4
23 };
24 static_assert(sizeof(PerkData) == 0x5);
25
26 class BGSPerk :
27 public TESForm, // 00
28 public TESFullName, // 20
29 public TESDescription, // 30
30 public TESIcon // 40
31 {
32 public:
33 inline static constexpr auto RTTI = RTTI_BGSPerk;
34 inline static constexpr auto FORMTYPE = FormType::Perk;
35
37 {
38 enum RecordFlag : std::uint32_t
39 {
40 kNonPlayable = 1 << 2,
41 kDeleted = 1 << 5,
42 kIgnored = 1 << 12
43 };
44 };
45
47 {
48 public:
49 inline static constexpr auto RTTI = RTTI_BGSPerk__FindPerkInRanksVisitor;
50
51 // override (PerkRankVisitor)
52 bool operator()(const PerkRankData* a_entry) override; // 00
53 };
54 static_assert(sizeof(FindPerkInRanksVisitor) == 0x8);
55
57 {
58 public:
59 inline static constexpr auto RTTI = RTTI_BGSPerk__ApplyPerksVisitor;
60
61 // override (PerkRankVisitor)
62 bool operator()(const PerkRankData* a_entry) override; // 00
63 };
64 static_assert(sizeof(ApplyPerksVisitor) == 0x8);
65
67 {
68 public:
69 inline static constexpr auto RTTI = RTTI_BGSPerk__AddPerkVisitor;
70
71 // override (PerkRankVisitor)
72 bool operator()(const PerkRankData* a_entry) override; // 00
73 };
74 static_assert(sizeof(AddPerkVisitor) == 0x8);
75
76 ~BGSPerk() override; // 00
77
78 // override (TESForm)
79 void InitializeData() override; // 04
80 void ClearData() override; // 05
81 bool Load(TESFile* a_mod) override; // 06
82 void InitItemImpl() override; // 13
83
84 // members
85 PerkData data; // 50 - DATA
86 std::uint8_t pad55; // 55
87 std::uint16_t pad56; // 56
90 BGSPerk* nextPerk; // 78 - NNAM
91 };
92 static_assert(sizeof(BGSPerk) == 0x80);
93}
Definition: BGSPerk.h:67
bool operator()(const PerkRankData *a_entry) override
static constexpr auto RTTI
Definition: BGSPerk.h:69
Definition: BGSPerk.h:57
static constexpr auto RTTI
Definition: BGSPerk.h:59
bool operator()(const PerkRankData *a_entry) override
Definition: BGSPerk.h:47
bool operator()(const PerkRankData *a_entry) override
static constexpr auto RTTI
Definition: BGSPerk.h:49
Definition: BGSPerk.h:31
BGSPerk * nextPerk
Definition: BGSPerk.h:90
static constexpr auto FORMTYPE
Definition: BGSPerk.h:34
std::uint8_t pad55
Definition: BGSPerk.h:86
bool Load(TESFile *a_mod) override
std::uint16_t pad56
Definition: BGSPerk.h:87
void InitializeData() override
static constexpr auto RTTI
Definition: BGSPerk.h:33
void ClearData() override
PerkData data
Definition: BGSPerk.h:85
BSTArray< BGSPerkEntry * > perkEntries
Definition: BGSPerk.h:89
TESCondition perkConditions
Definition: BGSPerk.h:88
~BGSPerk() override
void InitItemImpl() override
Definition: BSTArray.h:377
Definition: PerkRankVisitor.h:10
Definition: TESCondition.h:987
Definition: TESDescription.h:12
Definition: TESFile.h:14
Definition: TESForm.h:34
Definition: TESFullName.h:9
Definition: TESIcon.h:8
Definition: AbsorbEffect.h:6
constexpr REL::ID RTTI_BGSPerk__FindPerkInRanksVisitor
Definition: Offsets_RTTI.h:1394
constexpr REL::ID RTTI_BGSPerk__ApplyPerksVisitor
Definition: Offsets_RTTI.h:1393
constexpr REL::ID RTTI_BGSPerk__AddPerkVisitor
Definition: Offsets_RTTI.h:1392
constexpr REL::ID RTTI_BGSPerk
Definition: Offsets_RTTI.h:1389
Definition: BGSPerk.h:37
RecordFlag
Definition: BGSPerk.h:39
@ kDeleted
Definition: BGSPerk.h:41
@ kNonPlayable
Definition: BGSPerk.h:40
@ kIgnored
Definition: BGSPerk.h:42
Definition: BGSPerk.h:17
bool playable
Definition: BGSPerk.h:21
std::int8_t level
Definition: BGSPerk.h:19
bool trait
Definition: BGSPerk.h:18
bool hidden
Definition: BGSPerk.h:22
std::int8_t numRanks
Definition: BGSPerk.h:20
Definition: BGSPerkRankArray.h:10