diff --git a/CommonLibF4/include/RE/Bethesda/Actor.h b/CommonLibF4/include/RE/Bethesda/Actor.h index 937aa675..fb156727 100644 --- a/CommonLibF4/include/RE/Bethesda/Actor.h +++ b/CommonLibF4/include/RE/Bethesda/Actor.h @@ -1305,6 +1305,13 @@ namespace RE return func(this, a_force); } + BGSBodyPartData* GetBodyPartData() + { + using func_t = decltype(&Actor::GetBodyPartData); + static REL::Relocation func{ REL::ID(2229571) }; + return func(this); + } + // members NiTFlags niFlags; // 2D0 float updateTargetTimer; // 2D4 diff --git a/CommonLibF4/include/RE/Bethesda/BGSBodyPartDefs.h b/CommonLibF4/include/RE/Bethesda/BGSBodyPartDefs.h index 79792d16..f5604fb4 100644 --- a/CommonLibF4/include/RE/Bethesda/BGSBodyPartDefs.h +++ b/CommonLibF4/include/RE/Bethesda/BGSBodyPartDefs.h @@ -4,6 +4,49 @@ namespace RE::BGSBodyPartDefs { + enum class LIMB_ENUM : std::uint32_t + { + kNone = 0xFFFFFFFF, + kTorso = 0x0, + kHead1 = 0x1, + kEye1 = 0x2, + kLookAt1 = 0x3, + kFlyGrab = 0x4, + kHead2 = 0x5, + kLeftArm1 = 0x6, + kLeftArm2 = 0x7, + kRightArm1 = 0x8, + kRightArm2 = 0x9, + kLeftLeg1 = 0xA, + kLeftLeg2 = 0xB, + kLeftLeg3 = 0xC, + kRightLeg1 = 0xD, + kRightLeg2 = 0xE, + kRightLeg3 = 0xF, + kBrain = 0x10, + kWeapon = 0x11, + kRoot = 0x12, + kCom = 0x13, + kPelvis = 0x14, + kCamera = 0x15, + kOffsetRoot = 0x16, + kLeftFoot = 0x17, + kRightFoot = 0x18, + kFaceTargetSource = 0x19 + }; + + enum class CAUSE_OF_DEATH : std::uint32_t + { + kCauseOfDeathNone = 0xFFFFFFFF, + kCauseOfDeathExplosion = 0x0, + kCauseOfDeathGun = 0x1, + kCauseOfDeathBluntWeapon = 0x2, + kCauseOfDeathHandToHand = 0x3, + kCauseOfDeathObjectImpact = 0x4, + kCauseOfDeathPoison = 0x5, + kCauseOfDeathDecapitation = 0x6 + }; + struct HitReactionData { public: diff --git a/CommonLibF4/include/RE/Bethesda/BSExtraData.h b/CommonLibF4/include/RE/Bethesda/BSExtraData.h index 50beaacb..c5185d9d 100644 --- a/CommonLibF4/include/RE/Bethesda/BSExtraData.h +++ b/CommonLibF4/include/RE/Bethesda/BSExtraData.h @@ -1107,6 +1107,13 @@ namespace RE return func(this, a_compare, a_qualifier); } + void SetFavorite(char a_quickkeyIndex) + { + using func_t = decltype(&ExtraDataList::SetFavorite); + static REL::Relocation func{ REL::ID(2190188) }; + return func(this, a_quickkeyIndex); + } + // members BaseExtraList extraData; // 08 mutable BSReadWriteLock extraRWLock; // 20 diff --git a/CommonLibF4/include/RE/Bethesda/Events.h b/CommonLibF4/include/RE/Bethesda/Events.h index dd49aefc..bc13a964 100644 --- a/CommonLibF4/include/RE/Bethesda/Events.h +++ b/CommonLibF4/include/RE/Bethesda/Events.h @@ -166,11 +166,19 @@ namespace RE { struct Event { + [[nodiscard]] static BSTEventSource* GetEventSource() + { + using func_t = decltype(&Event::GetEventSource); + static REL::Relocation func{ REL::ID(349120) }; // .163 + return func(); + } + std::uint32_t newLevel; // 00 }; static_assert(sizeof(Event) == 0x4); } + namespace LoadingStatusChanged { struct Event @@ -959,7 +967,7 @@ namespace RE [[nodiscard]] static BSTEventSource* GetEventSource() { using func_t = decltype(&TESHitEvent::GetEventSource); - static REL::Relocation func{ REL::ID(1411899) }; + static REL::Relocation func{ REL::ID(2201886) }; return func(); } @@ -1021,6 +1029,25 @@ namespace RE }; static_assert(sizeof(TESSwitchRaceCompleteEvent) == 0x8); + namespace TESHarvestEvent + { + struct ItemHarvested + { + [[nodiscard]] static BSTEventSource* GetEventSource() + { + using func_t = decltype(&ItemHarvested::GetEventSource); + static REL::Relocation func{ REL::ID(2193351) }; + return func(); + } + + // members + const TESBoundObject* itemHarvested; // 00 + TESObjectREFR* referenceHarvested; // 08 + const Actor* harvestedBy; // 10 + }; + static_assert(sizeof(ItemHarvested) == 0x18); + }; + class TutorialEvent { public: diff --git a/CommonLibF4/include/RE/Bethesda/Projectiles.h b/CommonLibF4/include/RE/Bethesda/Projectiles.h index ddc99dfc..8ee4d738 100644 --- a/CommonLibF4/include/RE/Bethesda/Projectiles.h +++ b/CommonLibF4/include/RE/Bethesda/Projectiles.h @@ -15,11 +15,6 @@ namespace RE enum class COL_LAYER; enum class ImpactResult; - namespace BGSBodyPartDefs - { - enum class LIMB_ENUM; - } - namespace MagicSystem { enum class CastingSource; diff --git a/CommonLibF4/include/RE/Bethesda/TESObjectREFRs.h b/CommonLibF4/include/RE/Bethesda/TESObjectREFRs.h index bdc7297b..4531ca3d 100644 --- a/CommonLibF4/include/RE/Bethesda/TESObjectREFRs.h +++ b/CommonLibF4/include/RE/Bethesda/TESObjectREFRs.h @@ -24,11 +24,6 @@ namespace RE enum class CastingSource; } - namespace BGSBodyPartDefs - { - enum class LIMB_ENUM; - } - class ActorCause; class BGSAnimationSequencer; class BGSDecalGroup;