-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat:
TESLeveledList
and related classes (#228)
- Loading branch information
Showing
8 changed files
with
228 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSForcedLocRefType.h" | ||
#include "RE/B/BGSModelMaterialSwap.h" | ||
#include "RE/T/TESBoundAnimObject.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSLevGenericBaseForm : | ||
public TESBoundAnimObject, // 000 | ||
public TESLeveledList, // 118 | ||
public BGSModelMaterialSwap // 178 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(BGSLevGenericBaseForm); | ||
SF_FORMTYPE(LVLB); | ||
|
||
~BGSLevGenericBaseForm() override; // 00 | ||
}; | ||
static_assert(sizeof(BGSLevGenericBaseForm) == 0x1A0); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSForcedLocRefType.h" | ||
#include "RE/B/BGSModelMaterialSwap.h" | ||
#include "RE/T/TESBoundAnimObject.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSLevPackIn : | ||
public TESBoundAnimObject, // 000 | ||
public TESLeveledList, // 118 | ||
public BGSModelMaterialSwap, // 178 | ||
public BGSForcedLocRefType // 1A0 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(BGSLevPackIn); | ||
SF_FORMTYPE(LVLP); | ||
|
||
~BGSLevPackIn() override; // 00 | ||
}; | ||
static_assert(sizeof(BGSLevPackIn) == 0x1B8); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#pragma once | ||
|
||
#include "RE/T/TESForm.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSLevSpaceCell : | ||
public TESForm, // 00 | ||
public TESLeveledList // 38 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(BGSLevSpaceCell); | ||
SF_FORMTYPE(LVSC); | ||
|
||
~BGSLevSpaceCell() override; // 00 | ||
}; | ||
static_assert(sizeof(BGSLevSpaceCell) == 0x98); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BaseFormComponent.h" | ||
|
||
namespace RE | ||
{ | ||
class TESImageSpaceModifier; | ||
|
||
class TESImageSpaceModifiableForm : public BaseFormComponent | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(TESImageSpaceModifiableForm); | ||
|
||
~TESImageSpaceModifiableForm() override; // 00 | ||
|
||
// override (BaseFormComponent) | ||
const BSFixedString& GetFormComponentType() const override; // 01 - { return "TESImageSpaceModifiableForm_Component"; } | ||
void InitializeDataComponent() override; // 02 - { return; } | ||
|
||
// members | ||
TESImageSpaceModifier* imageSpaceModifying; // 08 - MNAM | ||
}; | ||
static_assert(sizeof(TESImageSpaceModifiableForm) == 0x10); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSModelMaterialSwap.h" | ||
#include "RE/T/TESBoundAnimObject.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class TESLevCharacter : | ||
public TESBoundAnimObject, // 000 | ||
public TESLeveledList, // 118 | ||
public BGSModelMaterialSwap // 178 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(TESLevCharacter); | ||
SF_FORMTYPE(LVLN); | ||
|
||
~TESLevCharacter() override; // 00 | ||
}; | ||
static_assert(sizeof(TESLevCharacter) == 0x1A0); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSForcedLocRefType.h" | ||
#include "RE/B/BGSModelMaterialSwap.h" | ||
#include "RE/T/TESBoundObject.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class TESLevItem : | ||
public TESBoundObject, // 000 | ||
public TESLeveledList, // 118 | ||
public BGSModelMaterialSwap, // 178 | ||
public BGSForcedLocRefType // 1A0 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(TESLevItem); | ||
SF_FORMTYPE(LVLI); | ||
|
||
~TESLevItem() override; // 00 | ||
}; | ||
static_assert(sizeof(TESLevItem) == 0x1B8); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#pragma once | ||
|
||
#include "RE/T/TESBoundObject.h" | ||
#include "RE/T/TESLeveledList.h" | ||
|
||
namespace RE | ||
{ | ||
class TESLevSpell : | ||
public TESBoundObject, // 000 | ||
public TESLeveledList // 118 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(TESLevSpell); | ||
SF_FORMTYPE(LVSP); | ||
|
||
~TESLevSpell() override; // 00 | ||
}; | ||
static_assert(sizeof(TESLevSpell) == 0x178); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSTypedFormValuePair.h" | ||
#include "RE/B/BSTArray.h" | ||
#include "RE/B/BSTTuple3.h" | ||
#include "RE/B/BaseFormComponent.h" | ||
#include "RE/F/FormTypes.h" | ||
#include "RE/T/TESCondition.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSCurveForm; | ||
class BGSBiome; | ||
class ContainerItemExtra; | ||
class TESForm; | ||
class TESGlobal; | ||
|
||
struct LEVELED_OBJECT | ||
{ | ||
public: | ||
// members | ||
TESForm* form; // 00 | ||
ContainerItemExtra* itemExtra; // 08 | ||
TESCondition* conditions; // 10 | ||
std::uint16_t count; // 18 | ||
std::uint16_t level; // 1A | ||
std::uint8_t unk1C; // 1C | ||
std::uint8_t unk1D; // 1D | ||
}; | ||
static_assert(sizeof(LEVELED_OBJECT) == 0x20); | ||
|
||
class TESLeveledList : public BaseFormComponent | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(TESLeveledList); | ||
|
||
enum Flag : std::uint8_t // LVLF | ||
{ | ||
kCalculateFromAllLevelsLTOrEqPCLevel = 1 << 0, | ||
kCalculateForEachItemInCount = 1 << 1, | ||
kUseAll = 1 << 2, | ||
kSpecialLoot = 1 << 3 | ||
}; | ||
|
||
~TESLeveledList() override; // 00 | ||
|
||
// override (BaseFormComponent) | ||
const BSFixedString& GetFormComponentType() const override; // 01 - { return "TESLeveledList_Component"; } | ||
void InitializeDataComponent() override; // 02 | ||
|
||
// add | ||
virtual std::int32_t GetMaxLevelDifference(); // 0B | ||
virtual bool GetCanHoldForm(TESForm* a_form); // 0C | ||
virtual void Unk_0D(); // 0D | ||
virtual void Unk_0E(); // 0E | ||
virtual void Unk_0F(); // 0F | ||
virtual bool GetCanContainFormsOfType(FormType a_type) const = 0; // 10 | ||
|
||
// members | ||
TESCondition conditions; // 08 | ||
TESGlobal* chanceGlobal; // 10 | ||
BGSBiome* biome; // 20 ?? | ||
TESForm* unk28; // 28 | ||
BSTArray<BSTTuple3<TESForm*, BGSCurveForm, BGSTypedFormValuePair::SharedVal>>* keywordChances; // 30 | ||
LEVELED_OBJECT* leveledLists; // 38 | ||
LEVELED_OBJECT** scriptAddedLists; // 40 | ||
std::int8_t scriptListCount; // 48 | ||
std::uint32_t unk4C; // 4C | ||
stl::enumeration<Flag, std::uint8_t> flags; // 50 | ||
std::uint8_t unk51; // 51 | ||
std::int8_t baseListCount; // 52 | ||
std::uint8_t unk53; // 53 | ||
std::uint8_t unk54; // 54 | ||
BSFixedString overrideName; // 58 | ||
}; | ||
static_assert(sizeof(TESLeveledList) == 0x60); | ||
} |