CommonLibSSE NG
Loading...
Searching...
No Matches
BGSMaterialType.h
Go to the documentation of this file.
1#pragma once
2
4#include "RE/F/FormTypes.h"
5#include "RE/M/MaterialIDs.h"
6#include "RE/N/NiColor.h"
7#include "RE/T/TESForm.h"
8
9namespace RE
10{
11 class BGSMaterialType : public TESForm
12 {
13 public:
14 inline static constexpr auto RTTI = RTTI_BGSMaterialType;
15 inline static constexpr auto VTABLE = VTABLE_BGSMaterialType;
16 inline static constexpr auto FORMTYPE = FormType::MaterialType;
17
18 enum class FLAG
19 {
20 kNone = 0,
21 kStairs = 1 << 0,
22 kArrowsStick = 1 << 1
23 };
24
26 {
27 enum RecordFlag : std::uint32_t
28 {
29 kDeleted = 1 << 5,
30 kIgnored = 1 << 12
31 };
32 };
33
34 ~BGSMaterialType() override; // 00
35
36 // override (TESForm)
37 void ClearData() override; // 04
38 bool Load(TESFile* a_mod) override; // 06
39 void InitItemImpl() override; // 13
40
42 {
43 using func_t = decltype(&BGSMaterialType::GetMaterialType);
44 REL::Relocation<func_t> func{ RELOCATION_ID(20529, 20968) };
45 return func(a_materialID);
46 }
47
48 // members
52 NiColor materialColor; // 34 - CNAM
53 float buoyancy; // 40 - BNAM
56 };
57 static_assert(sizeof(BGSMaterialType) == 0x50);
58}
#define RELOCATION_ID(a_se, a_ae)
Definition PCH.h:794
Definition BGSImpactDataSet.h:13
Definition BGSMaterialType.h:12
static constexpr auto VTABLE
Definition BGSMaterialType.h:15
float buoyancy
Definition BGSMaterialType.h:53
void ClearData() override
void InitItemImpl() override
BGSMaterialType * parentType
Definition BGSMaterialType.h:49
bool Load(TESFile *a_mod) override
NiColor materialColor
Definition BGSMaterialType.h:52
MATERIAL_ID materialID
Definition BGSMaterialType.h:51
static BGSMaterialType * GetMaterialType(MATERIAL_ID a_materialID)
Definition BGSMaterialType.h:41
stl::enumeration< FLAG, std::uint32_t > flags
Definition BGSMaterialType.h:54
FLAG
Definition BGSMaterialType.h:19
static constexpr auto FORMTYPE
Definition BGSMaterialType.h:16
static constexpr auto RTTI
Definition BGSMaterialType.h:14
BSFixedString materialName
Definition BGSMaterialType.h:50
~BGSMaterialType() override
BGSImpactDataSet * havokImpactDataSet
Definition BGSMaterialType.h:55
Definition NiColor.h:11
Definition TESFile.h:15
Definition TESForm.h:35
Definition Relocation.h:1638
Definition PCH.h:223
Definition AbsorbEffect.h:6
constexpr REL::VariantID RTTI_BGSMaterialType(513988, 392975, 0x1ee17b8)
constexpr std::array< REL::VariantID, 1 > VTABLE_BGSMaterialType
Definition Offsets_VTABLE.h:737
MATERIAL_ID
Definition MaterialIDs.h:6
Definition BGSMaterialType.h:26
RecordFlag
Definition BGSMaterialType.h:28
@ kDeleted
Definition BGSMaterialType.h:29
@ kIgnored
Definition BGSMaterialType.h:30