-
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.
- Loading branch information
Showing
10 changed files
with
323 additions
and
39 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,29 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BaseFormComponent.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSEquipSlot; | ||
class TBO_InstanceData; | ||
|
||
class BGSEquipType : public BaseFormComponent | ||
{ | ||
public: | ||
SF_RTTI(BGSEquipType); | ||
|
||
virtual ~BGSEquipType() override; // 00 | ||
|
||
// override (BaseFormComponent) | ||
const BSFixedString& GetFormComponentType() const override; // 01 - { return "BGSEquipType_Component"; } | ||
void InitializeDataComponent() override; // 02 - { return; } | ||
|
||
// add | ||
[[nodiscard]] virtual BGSEquipSlot* GetEquipSlot(const TBO_InstanceData* a_data) const; // 06 | ||
virtual void SetEquipSlot(BGSEquipSlot* a_slot); // 07 | ||
|
||
// members | ||
BGSEquipSlot* equipSlot; // 08 | ||
}; | ||
static_assert(sizeof(BGSEquipType) == 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,24 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BaseFormComponent.h" | ||
|
||
namespace RE | ||
{ | ||
class TESBoundObject; | ||
|
||
class BGSMenuDisplayObject : public BaseFormComponent | ||
{ | ||
public: | ||
SF_RTTI(BGSMenuDisplayObject); | ||
|
||
virtual ~BGSMenuDisplayObject() override; // 00 | ||
|
||
// override (BaseFormComponent) | ||
const BSFixedString& GetFormComponentType() const override; // 01 - { return "BGSMenuDisplayObject_Component"; } | ||
void InitializeDataComponent() override; // 02 - { return; } | ||
|
||
// members | ||
TESBoundObject* menuObject; // 08 | ||
}; | ||
static_assert(sizeof(BGSMenuDisplayObject) == 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
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
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,33 @@ | ||
#pragma once | ||
|
||
namespace RE | ||
{ | ||
class EffectSetting; | ||
class TESGlobal; | ||
|
||
struct EffectItemData | ||
{ | ||
public: | ||
// members | ||
float magnitude; // 0 | ||
float area; // 4 | ||
std::int32_t duration; // 8 | ||
}; | ||
static_assert(sizeof(EffectItemData) == 0xC); | ||
|
||
class EffectItem | ||
{ | ||
public: | ||
// members | ||
EffectItemData data; // 00 | ||
EffectSetting* effectSetting; // 10 | ||
TESGlobal* magGlobal; // 18 | ||
TESGlobal* areaGlobal; // 20 | ||
TESGlobal* durationGlobal; // 28 | ||
std::uint32_t unk30; // 30 | ||
std::uint32_t unk34; // 34 | ||
float rawCost; // 38 | ||
std::uint64_t conditions[2]; // 40 - TESCondition | ||
}; | ||
static_assert(sizeof(EffectItem) == 0x50); | ||
} |
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,87 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSKeywordForm.h" | ||
#include "RE/B/BSTArray.h" | ||
#include "RE/B/BSTSmartPointer.h" | ||
#include "RE/M/MagicSystem.h" | ||
#include "RE/T/TESBoundObject.h" | ||
#include "RE/T/TESFullName.h" | ||
|
||
namespace RE | ||
{ | ||
enum class CHUNK_ID; | ||
|
||
class ActorValueInfo; | ||
class EffectItem; | ||
class EffectSetting; | ||
class QueuedFile; | ||
|
||
class MagicItem : | ||
public TESBoundObject, // 000 | ||
public TESFullName, // 118 | ||
public BGSKeywordForm // 128 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(MagicItem); | ||
|
||
struct SkillUsageData | ||
{ | ||
public: | ||
// members | ||
EffectItem* effect; // 00 | ||
ActorValueInfo* skill; // 08 | ||
float magnitude; // 10 | ||
bool custom; // 14 | ||
}; | ||
static_assert(sizeof(SkillUsageData) == 0x18); | ||
|
||
class Data | ||
{ | ||
public: | ||
// members | ||
std::int32_t costOverride; // 0 | ||
std::uint32_t flags; // 4 | ||
}; | ||
static_assert(sizeof(Data) == 0x8); | ||
|
||
~MagicItem() override; // 00 | ||
|
||
// add | ||
virtual MagicSystem::SpellType GetSpellType() const; // 82 | ||
virtual void SetCastingType(MagicSystem::CastingType a_castingType); // 83 | ||
virtual MagicSystem::CastingType GetCastingType() const; // 84 | ||
virtual void SetDelivery(MagicSystem::Delivery a_delivery); // 85 | ||
virtual MagicSystem::Delivery GetDelivery() const; // 86 | ||
virtual bool IsValidDelivery(MagicSystem::Delivery); // 87 | ||
virtual float GetFixedCastDuration() const; // 88 | ||
virtual float GetRange() const; // 89 | ||
virtual bool IgnoreResistance() const; // 8A | ||
virtual bool IgnoreLOS() const; // 8B | ||
virtual bool IsFood() const; // 8C | ||
virtual bool GetNoAbsorb() const; // 8D | ||
virtual bool GetNoDualCastModifications() const; // 8E | ||
virtual bool GetSkillUsageData(SkillUsageData& a_data) const; // 8F | ||
virtual bool IsPoison() const; // 90 | ||
virtual bool IsMedicine() const; // 91 | ||
virtual void AdjustCost(float& a_cost, Actor* a_actor) const; // 92 | ||
virtual float GetChargeTime() const; // 93 | ||
virtual std::uint32_t GetMaxEffectCount() const; // 94 | ||
virtual ActorValueInfo* GetAssociatedSkill() const; // 95 | ||
virtual CHUNK_ID GetChunkID(); // 96 | ||
virtual void CopyMagicItemData(MagicItem* a_copy); // 97 | ||
virtual void LoadMagicItemChunk(TESFile* a_file, CHUNK_ID a_chunkID); // 98 | ||
virtual void LoadChunkDataPostProcess(TESFile* a_file); // 99 | ||
virtual Data* GetData1(); // 9A | ||
virtual const Data* GetData2() const; // 9B | ||
virtual std::size_t GetDataSize() const; // 9C | ||
virtual void InitFromChunk(TESFile* a_file); // 9D | ||
|
||
// members | ||
BSTArray<EffectItem*> listOfEffects; // 158 | ||
std::int32_t hostileCount; // 168 | ||
EffectSetting* avEffectSetting; // 170 | ||
std::uint32_t preloadCount; // 174 | ||
BSTSmartPointer<QueuedFile, BSTSmartPointerGamebryoRefCount> preloadedItem; // 180 | ||
}; | ||
static_assert(sizeof(MagicItem) == 0x188); | ||
} |
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,67 @@ | ||
#pragma once | ||
|
||
namespace RE::MagicSystem | ||
{ | ||
enum class CannotCastReason | ||
{ | ||
kOK = 0, | ||
kMagicka = 1, | ||
kPowerUsed = 2, | ||
kRangedUnderWater = 3, | ||
kMultipleCast = 4, | ||
kItemCharge = 5, | ||
kCastWhileShouting = 6, | ||
kShoutWhileCasting = 7, | ||
kStarPower = 8 | ||
}; | ||
|
||
enum class CastingSource | ||
{ | ||
kLeftHand = 0, | ||
kRightHand = 1, | ||
kOther = 2, | ||
kInstant = 3 | ||
}; | ||
|
||
enum class CastingType | ||
{ | ||
kConstantEffect = 0, | ||
kFireAndForget = 1, | ||
kConcentration = 2, | ||
kScroll = 3 | ||
}; | ||
|
||
enum class Delivery | ||
{ | ||
kSelf = 0, | ||
kTouch = 1, | ||
kAimed = 2, | ||
kTargetActor = 3, | ||
kTargetLocation = 4, | ||
|
||
kTotal | ||
}; | ||
|
||
enum class SpellType | ||
{ | ||
kSpell = 0, | ||
kDisease = 1, | ||
kPower = 2, | ||
kLesserPower = 3, | ||
kAbility = 4, | ||
kPoison = 5, | ||
kEnchantment = 6, | ||
|
||
kPotion = 7, | ||
kAlchemy = static_cast<std::underlying_type_t<SpellType>>(kPotion), | ||
|
||
kWortCraft = 8, | ||
kIngredient = static_cast<std::underlying_type_t<SpellType>>(kWortCraft), | ||
|
||
kLeveledSpell = 9, | ||
kAddiction = 10, | ||
kVoicePower = 11, | ||
kStaffEnchantment = 12, | ||
kScroll = 13 | ||
}; | ||
} |
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,49 @@ | ||
#pragma once | ||
|
||
#include "RE/B/BGSEquipType.h" | ||
#include "RE/B/BGSMenuDisplayObject.h" | ||
#include "RE/B/BGSPickupPutdownSounds.h" | ||
#include "RE/M/MagicItem.h" | ||
#include "RE/T/TESDescription.h" | ||
|
||
namespace RE | ||
{ | ||
class BGSPerk; | ||
|
||
class SpellItem : | ||
public MagicItem, // 000 | ||
public BGSEquipType, // 188 | ||
public BGSMenuDisplayObject, // 198 | ||
public BGSPickupPutdownSounds, // 1A8 | ||
public TESDescription // 210 | ||
{ | ||
public: | ||
SF_RTTI_VTABLE(SpellItem); | ||
SF_FORMTYPE(SPEL); | ||
|
||
class Data : | ||
public MagicItem::Data // 00 | ||
{ | ||
public: | ||
// members | ||
stl::enumeration<MagicSystem::SpellType, std::uint8_t> spellType; // 08 | ||
float chargeTime; // 0C | ||
stl::enumeration<MagicSystem::CastingType, std::uint8_t> castingType; // 10 | ||
stl::enumeration<MagicSystem::Delivery, std::uint8_t> delivery; // 11 | ||
float castDuration; // 14 | ||
float range; // 18 | ||
BGSPerk* castingPerk; // 20 | ||
}; | ||
static_assert(sizeof(Data) == 0x28); | ||
|
||
~SpellItem() override; // 00 | ||
|
||
// add | ||
virtual bool IsSpell(); // 9E - return { GetSpellType() == 0; } | ||
virtual void SetSpellType(MagicSystem::SpellType a_spellType); // 9F | ||
|
||
// members | ||
Data data; // 228 | ||
}; | ||
static_assert(sizeof(SpellItem) == 0x250); | ||
} |
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
Oops, something went wrong.