diff --git a/CommonLibSF/include/RE/A/Actor.h b/CommonLibSF/include/RE/A/Actor.h index d6034b2b..d648c0f8 100644 --- a/CommonLibSF/include/RE/A/Actor.h +++ b/CommonLibSF/include/RE/A/Actor.h @@ -11,6 +11,7 @@ namespace RE { + class TESNPC; class AIProcess; class BGSPerk; class CombatController; @@ -58,21 +59,21 @@ namespace RE class Actor : public TESObjectREFR, // 000 - public MagicTarget, // 110 - public ActorState, // 128 - public IMovementStateStore, // 138 - public IStoreAnimationActions, // 140 - public BSTEventSink, // 148 - public BSTEventSink, // 150 - public BSTEventSink, // 158 - public BSTEventSink, // 160 - public BSTEventSink, // 168 - public BSTEventSink, // 170 - public BSTEventSource, // 178 - public BSTEventSource, // 1A0 - public BSTEventSource, // 1C8 - public BSTEventSource, // 1F0 - public BSTEventSource // 218 + public MagicTarget, // 0F0 + public ActorState, // 108 + public IMovementStateStore, // 118 + public IStoreAnimationActions, // 120 + public BSTEventSink, // 128 + public BSTEventSink, // 130 + public BSTEventSink, // 138 + public BSTEventSink, // 140 + public BSTEventSink, // 148 + public BSTEventSink, // 150 + public BSTEventSource, // 158 + public BSTEventSource, // 180 + public BSTEventSource, // 1A8 + public BSTEventSource, // 1D0 + public BSTEventSource // 1F8 { public: SF_RTTI_VTABLE(Actor); @@ -170,7 +171,7 @@ namespace RE virtual void Unk_136(); // 136 virtual void Unk_137(); // 137 virtual void Unk_138(); // 138 - virtual void Unk_139(); // 139 + virtual void Resurrect(bool a_resetInventory, bool a_attach3D); // 139 virtual void Unk_13A(); // 13A virtual void Unk_13B(); // 13B virtual void Unk_13C(); // 13C @@ -200,7 +201,7 @@ namespace RE virtual void Unk_154(); // 154 virtual void Unk_155(); // 155 virtual void Unk_156(); // 156 - virtual void Unk_157(); // 157 + virtual void SetRefraction(bool a_enable, float a_refractionPower); // 157 virtual void Unk_158(); // 158 virtual void Unk_159(); // 159 virtual void Unk_15A(); // 15A @@ -218,7 +219,7 @@ namespace RE virtual void Unk_166(); // 166 virtual void Unk_167(); // 167 virtual void Unk_168(); // 168 - virtual void Unk_169(); // 169 + virtual void UpdateAlpha(); // 169 virtual void Unk_16A(); // 16A virtual void Unk_16B(); // 16B virtual bool IsInCombat() const; // 16C @@ -279,31 +280,33 @@ namespace RE [[nodiscard]] bool IsHostileToActor(Actor* a_actor); // members - stl::enumeration boolBits; // 240 - std::uint32_t unk244; // 244 + stl::enumeration boolBits; // 220 + float unk224; // 224 + BSGuarded, BSSpinLock> unk228; // 228 - BGSBody? + AIProcess* currentProcess; // 240 std::uint64_t unk248; // 248 std::uint64_t unk250; // 250 std::uint64_t unk258; // 258 - AIProcess* currentProcess; // 260 - std::uint64_t unk268; // 268 + std::uint64_t unk260; // 260 + CombatController* combatController; // 268 std::uint64_t unk270; // 270 - std::uint64_t unk278; // 278 - std::uint64_t unk280; // 280 - CombatController* combatController; // 288 - std::uint64_t unk290; // 290 - ActorValueStorage avStorage; // 298 + ActorValueStorage avStorage; // 278 + std::uint64_t unk2A0; // 2A0 + stl::enumeration criticalStage; // 2A8 + std::uint32_t dialogueItemTarget; // 2AC - TESPointerHandle + std::uint32_t currentCombatTarget; // 2B0 - TESPointerHandle + std::uint32_t myKiller; // 2B4 - TESPointerHandle + std::uint64_t unk2B8; // 2B8 std::uint64_t unk2C0; // 2C0 - stl::enumeration criticalStage; // 2C8 - std::uint32_t dialogueItemTarget; // 2CC - TESPointerHandle - std::uint32_t currentCombatTarget; // 2D0 - TESPointerHandle - std::uint32_t myKiller; // 2D4 - TESPointerHandle - std::uint64_t unk2D8; // 2D8 + std::uint32_t actionValue; // 2C8 + float timerOnAction; // 2CC + std::uint64_t unk2D0; // 2D0 + std::uint32_t intimidateBribeDayStamp; // 2D8 + std::uint32_t unk2DC; // 2DC std::uint64_t unk2E0; // 2E0 - std::uint32_t actionValue; // 2E8 - float timerOnAction; // 2EC + std::uint64_t unk2E8; // 2E8 std::uint64_t unk2F0; // 2F0 - std::uint32_t intimidateBribeDayStamp; // 2F8 - std::uint32_t unk2FC; // 2FC + std::uint64_t unk2F8; // 2F8 std::uint64_t unk300; // 300 std::uint64_t unk308; // 308 std::uint64_t unk310; // 310 @@ -317,17 +320,17 @@ namespace RE std::uint64_t unk350; // 350 std::uint64_t unk358; // 358 std::uint64_t unk360; // 360 - std::uint64_t unk368; // 368 - std::uint64_t unk370; // 370 - std::uint64_t unk378; // 378 - std::uint64_t unk380; // 380 - TESRace* race; // 388 - Perks* perks; // 390 - std::uint32_t unk398; // 398 - mutable BSReadWriteLock perkArrayLock; // 39C - std::uint32_t unk3A4; // 394 - stl::enumeration boolFlags; // 3A8 - stl::enumeration boolFlags2; // 3AC + TESRace* race; // 368 + Perks* perks; // 370 + std::uint32_t unk378; // 378 + mutable BSReadWriteLock perkArrayLock; // 37C + std::uint32_t unk384; // 374 + stl::enumeration boolFlags; // 388 + stl::enumeration boolFlags2; // 38C + std::uint64_t unk390; // 390 + std::uint64_t unk398; // 398 + std::uint64_t unk3A0; // 3A0 + std::uint64_t unk3A8; // 3A8 std::uint64_t unk3B0; // 3B0 std::uint64_t unk3B8; // 3B8 std::uint64_t unk3C0; // 3C0 @@ -376,10 +379,6 @@ namespace RE std::uint64_t unk518; // 518 std::uint64_t unk520; // 520 std::uint64_t unk528; // 528 - std::uint64_t unk530; // 530 - std::uint64_t unk538; // 538 - std::uint64_t unk540; // 540 - std::uint64_t unk548; // 548 }; - static_assert(sizeof(Actor) == 0x550); + static_assert(sizeof(Actor) == 0x530); } diff --git a/CommonLibSF/include/RE/A/ActorValueInfo.h b/CommonLibSF/include/RE/A/ActorValueInfo.h index 3493a525..3803da2b 100644 --- a/CommonLibSF/include/RE/A/ActorValueInfo.h +++ b/CommonLibSF/include/RE/A/ActorValueInfo.h @@ -11,7 +11,7 @@ namespace RE class ActorValueInfo : public TESForm, // 00 - public TESFullName // 38 + public TESFullName // 30 { public: SF_RTTI_VTABLE(ActorValueInfo); @@ -19,7 +19,9 @@ namespace RE ~ActorValueInfo() override; // 00 // members - BGSEditorID editorID; // 048 + + BGSEditorID editorID; // 040 + std::uint64_t unk050; // 050 std::uint64_t unk058; // 058 std::uint64_t unk060; // 060 std::uint64_t unk068; // 068 @@ -49,18 +51,17 @@ namespace RE std::uint64_t unk128; // 128 std::uint64_t unk130; // 130 std::uint64_t unk138; // 138 - std::uint64_t unk140; // 140 - BGSResource* resource; // 148 - BSFixedString abbreviation; // 150 - std::uint32_t index; // 158 - std::uint32_t flags; // 15C - stl::enumeration avType; // 160 - std::uint32_t unk164; // 164 - std::uint32_t fullCacheIndex; // 168 - std::uint32_t permanentCacheIndex; // 16C - std::uint64_t unk170; // 170 - std::uint32_t unk178; // 178 - std::uint32_t sortIndex; // 17C + BGSResource* resource; // 140 + BSFixedString abbreviation; // 148 + std::uint32_t index; // 150 + std::uint32_t flags; // 154 + stl::enumeration avType; // 158 + std::uint32_t unk15C; // 15C + std::uint32_t fullCacheIndex; // 160 + std::uint32_t permanentCacheIndex; // 164 + std::uint64_t unk168; // 168 + std::uint32_t unk170; // 170 + std::uint32_t sortIndex; // 174 }; - static_assert(sizeof(ActorValueInfo) == 0x180); + static_assert(sizeof(ActorValueInfo) == 0x178); } diff --git a/CommonLibSF/include/RE/A/ActorValueOwner.h b/CommonLibSF/include/RE/A/ActorValueOwner.h index 815ae3e3..ad436e4a 100644 --- a/CommonLibSF/include/RE/A/ActorValueOwner.h +++ b/CommonLibSF/include/RE/A/ActorValueOwner.h @@ -11,7 +11,7 @@ namespace RE public: SF_RTTI(ActorValueOwner); - virtual ~ActorValueOwner(); + virtual ~ActorValueOwner(); // 00 // add virtual float GetActorValue(const ActorValueInfo& a_info); // 01 diff --git a/CommonLibSF/include/RE/A/ActorValues.h b/CommonLibSF/include/RE/A/ActorValues.h index f2eb8173..96464d8c 100644 --- a/CommonLibSF/include/RE/A/ActorValues.h +++ b/CommonLibSF/include/RE/A/ActorValues.h @@ -71,7 +71,7 @@ namespace RE ActorValueInfo* electromagneticHealth; // 0D0 ActorValueInfo* electromagneticToDamageConversionRate; // 0D8 ActorValueInfo* electromagneticRecoverRateMult; // 0E0 - ActorValueInfo* unkE8; // 0E8 - null + ActorValueInfo* enchanting; // 0E8 ActorValueInfo* endurance; // 0F0 ActorValueInfo* enduranceCondition; // 0F8 ActorValueInfo* experience; // 100 diff --git a/CommonLibSF/include/RE/A/AlchemyItem.h b/CommonLibSF/include/RE/A/AlchemyItem.h index 4a9bf194..708f451f 100644 --- a/CommonLibSF/include/RE/A/AlchemyItem.h +++ b/CommonLibSF/include/RE/A/AlchemyItem.h @@ -54,7 +54,7 @@ namespace RE ~AlchemyItem() override; // 00 // members - Data data; // 2B8 + Data data; // 280 }; - static_assert(sizeof(AlchemyItem) == 0x308); + static_assert(sizeof(AlchemyItem) == 0x2D0); } diff --git a/CommonLibSF/include/RE/A/ArrowProjectile.h b/CommonLibSF/include/RE/A/ArrowProjectile.h index eafff2d8..44e99e49 100644 --- a/CommonLibSF/include/RE/A/ArrowProjectile.h +++ b/CommonLibSF/include/RE/A/ArrowProjectile.h @@ -15,7 +15,7 @@ namespace RE ~ArrowProjectile() override; // 00 // members - AlchemyItem* poison; // 2D0 + AlchemyItem* poison; // 2B0 }; - static_assert(sizeof(ArrowProjectile) == 0x2E0); + static_assert(sizeof(ArrowProjectile) == 0x2C0); } diff --git a/CommonLibSF/include/RE/B/BGSAcousticSpace.h b/CommonLibSF/include/RE/B/BGSAcousticSpace.h index 6471b827..c6a45ebc 100644 --- a/CommonLibSF/include/RE/B/BGSAcousticSpace.h +++ b/CommonLibSF/include/RE/B/BGSAcousticSpace.h @@ -19,18 +19,18 @@ namespace RE ~BGSAcousticSpace() override; // 00 // members - BGSAudio::WwiseSoundHook sound0; // 118 - BGSAudio::WwiseSoundHook sound1; // 148 - BGSAudio::WwiseSoundHook sound2; // 178 - BGSMusicType* music; // 1A8 - BGSAmbienceSet* ambienceSet; // 1B0 - BGSReverbParameters* environmentType; // 1B8 - std::uint32_t unk1C0; // 1C0 - float unk1C4; // 1C4 - float unk1C8; // 1C8 - std::uint8_t unk1CC; // 1CC - std::uint8_t unk1CD; // 1CD - std::uint32_t unk1D0; // 1D0 + BGSAudio::WwiseSoundHook sound0; // 0E0 + BGSAudio::WwiseSoundHook sound1; // 110 + BGSAudio::WwiseSoundHook sound2; // 140 + BGSMusicType* music; // 170 + BGSAmbienceSet* ambienceSet; // 178 + BGSReverbParameters* environmentType; // 180 + std::uint32_t unk188; // 188 + float unk18C; // 18C + float unk190; // 190 + std::uint8_t unk194; // 194 + std::uint8_t unk195; // 195 + std::uint32_t unk198; // 198 }; - static_assert(sizeof(BGSAcousticSpace) == 0x1D8); + static_assert(sizeof(BGSAcousticSpace) == 0x1A0); } diff --git a/CommonLibSF/include/RE/B/BGSArtObject.h b/CommonLibSF/include/RE/B/BGSArtObject.h index c4338a02..4fab0f8e 100644 --- a/CommonLibSF/include/RE/B/BGSArtObject.h +++ b/CommonLibSF/include/RE/B/BGSArtObject.h @@ -10,8 +10,8 @@ namespace RE class BGSArtObject : public TESBoundObject, // 000 - public BGSKeywordForm, // 118 - public BGSModelMaterialSwap // 148 + public BGSKeywordForm, // 0E0 + public BGSModelMaterialSwap // 110 { public: SF_RTTI_VTABLE(BGSArtObject); @@ -36,8 +36,8 @@ namespace RE ~BGSArtObject() override; // 00 // members - Data data; // 170 - EffectShader* effectShader; // 178 + Data data; // 138 + EffectShader* effectShader; // 140 }; - static_assert(sizeof(BGSArtObject) == 0x180); + static_assert(sizeof(BGSArtObject) == 0x148); } diff --git a/CommonLibSF/include/RE/B/BGSAudioOcclusionPrimitive.h b/CommonLibSF/include/RE/B/BGSAudioOcclusionPrimitive.h index cceff1b2..6e7c1e87 100644 --- a/CommonLibSF/include/RE/B/BGSAudioOcclusionPrimitive.h +++ b/CommonLibSF/include/RE/B/BGSAudioOcclusionPrimitive.h @@ -13,8 +13,8 @@ namespace RE ~BGSAudioOcclusionPrimitive() override; // 00 // members - float unk118; // 118 - float unk11C; // 11C + float unkE0; // E0 + float unkE4; // E4 }; - static_assert(sizeof(BGSAudioOcclusionPrimitive) == 0x120); + static_assert(sizeof(BGSAudioOcclusionPrimitive) == 0xE8); } diff --git a/CommonLibSF/include/RE/B/BGSBendableSpline.h b/CommonLibSF/include/RE/B/BGSBendableSpline.h index b0afd1dc..ad5e6617 100644 --- a/CommonLibSF/include/RE/B/BGSBendableSpline.h +++ b/CommonLibSF/include/RE/B/BGSBendableSpline.h @@ -27,8 +27,8 @@ namespace RE static_assert(sizeof(SplineData) == 0x1C); // members - SplineData data; // 118 - BGSMaterialPathForm* materialPath; // 138 + SplineData data; // 0E0 + BGSMaterialPathForm* materialPath; // 100 }; - static_assert(sizeof(BGSBendableSpline) == 0x140); + static_assert(sizeof(BGSBendableSpline) == 0x108); } diff --git a/CommonLibSF/include/RE/B/BGSBiomeMarkerObject.h b/CommonLibSF/include/RE/B/BGSBiomeMarkerObject.h index 362936b3..4e172793 100644 --- a/CommonLibSF/include/RE/B/BGSBiomeMarkerObject.h +++ b/CommonLibSF/include/RE/B/BGSBiomeMarkerObject.h @@ -11,8 +11,8 @@ namespace RE class BGSBiomeMarkerObject : public TESBoundObject, // 000 - public TESModel, // 118 - public BGSKeywordForm // 138 + public TESModel, // 0E0 + public BGSKeywordForm // 100 { public: SF_RTTI_VTABLE(BGSBiomeMarkerObject); @@ -21,9 +21,9 @@ namespace RE ~BGSBiomeMarkerObject() override; // 00 // members - TESCondition conditions; // 168 - BGSKeyword* type; // 178 - TESLevItem* floraList; // 180 + TESCondition conditions; // 130 + BGSKeyword* type; // 140 + TESLevItem* floraList; // 148 }; - static_assert(sizeof(BGSBiomeMarkerObject) == 0x188); + static_assert(sizeof(BGSBiomeMarkerObject) == 0x150); } diff --git a/CommonLibSF/include/RE/B/BGSEquipSlot.h b/CommonLibSF/include/RE/B/BGSEquipSlot.h index ae0b699a..654f4882 100644 --- a/CommonLibSF/include/RE/B/BGSEquipSlot.h +++ b/CommonLibSF/include/RE/B/BGSEquipSlot.h @@ -25,10 +25,10 @@ namespace RE ~BGSEquipSlot() override; // 00 // members - BGSEditorID formEditorID; // 38 - BSTArray parentSlots; // 48 - ActorValueInfo* conditionActorValue; // 58 - stl::enumeration flags; // 60 + BGSEditorID formEditorID; // 30 + BSTArray parentSlots; // 40 + ActorValueInfo* conditionActorValue; // 50 + stl::enumeration flags; // 58 }; - static_assert(sizeof(BGSEquipSlot) == 0x68); + static_assert(sizeof(BGSEquipSlot) == 0x60); } diff --git a/CommonLibSF/include/RE/B/BGSExplosion.h b/CommonLibSF/include/RE/B/BGSExplosion.h index b60007c7..ebf63c37 100644 --- a/CommonLibSF/include/RE/B/BGSExplosion.h +++ b/CommonLibSF/include/RE/B/BGSExplosion.h @@ -49,11 +49,11 @@ namespace RE class BGSExplosion : public TESBoundObject, // 000 - public TESFullName, // 118 - public TESModel, // 128 - public TESEnchantableForm, // 148 - public BGSPreloadable, // 160 - public TESImageSpaceModifiableForm // 168 + public TESFullName, // 0E0 + public TESModel, // 0F0 + public TESEnchantableForm, // 110 + public BGSPreloadable, // 128 + public TESImageSpaceModifiableForm // 130 { public: SF_RTTI_VTABLE(BGSExplosion); @@ -62,7 +62,7 @@ namespace RE ~BGSExplosion() override; // 00 // members - BGSExplosionData data; // 178 + BGSExplosionData data; // 140 }; - static_assert(sizeof(BGSExplosion) == 0x220); + static_assert(sizeof(BGSExplosion) == 0x1E8); } diff --git a/CommonLibSF/include/RE/B/BGSFormFolderKeywordList.h b/CommonLibSF/include/RE/B/BGSFormFolderKeywordList.h index 0292b727..65e8e60e 100644 --- a/CommonLibSF/include/RE/B/BGSFormFolderKeywordList.h +++ b/CommonLibSF/include/RE/B/BGSFormFolderKeywordList.h @@ -11,13 +11,12 @@ namespace RE { public: SF_RTTI_VTABLE(BGSFormFolderKeywordList); - SF_FORMTYPE(FFKW); ~BGSFormFolderKeywordList() override; // 00 // members - BSTArray keywords; // 38 - BSFixedString formFolder; // 48 + BSTArray keywords; // 30 + BSFixedString formFolderPath; // 40 }; - static_assert(sizeof(BGSFormFolderKeywordList) == 0x50); + static_assert(sizeof(BGSFormFolderKeywordList) == 0x48); } diff --git a/CommonLibSF/include/RE/B/BGSGenericBaseForm.h b/CommonLibSF/include/RE/B/BGSGenericBaseForm.h index 4ffc7119..83d2d22b 100644 --- a/CommonLibSF/include/RE/B/BGSGenericBaseForm.h +++ b/CommonLibSF/include/RE/B/BGSGenericBaseForm.h @@ -9,16 +9,16 @@ namespace RE class BGSGenericBaseFormTemplate; class BGSGenericBaseForm : - public TESBoundObject, // 000 - public BGSNavmeshableObject // 118 + public TESBoundObject, // 00 + public BGSNavmeshableObject // E8 { public: SF_RTTI_VTABLE(BGSGenericBaseForm); SF_FORMTYPE(GBFM); // members - BGSEditorID formEditorID; // 120 - BGSGenericBaseFormTemplate* genericBaseFormTemplate; // 130 + BGSEditorID formEditorID; // E8 + BGSGenericBaseFormTemplate* genericBaseFormTemplate; // F8 }; - static_assert(sizeof(BGSGenericBaseForm) == 0x138); + static_assert(sizeof(BGSGenericBaseForm) == 0x100); } diff --git a/CommonLibSF/include/RE/B/BGSHazard.h b/CommonLibSF/include/RE/B/BGSHazard.h index 8f3b8463..fad3d475 100644 --- a/CommonLibSF/include/RE/B/BGSHazard.h +++ b/CommonLibSF/include/RE/B/BGSHazard.h @@ -49,10 +49,10 @@ namespace RE class BGSHazard : public TESBoundObject, // 000 - public TESFullName, // 118 - public TESModel, // 128 - public BGSPreloadable, // 148 - public TESImageSpaceModifiableForm // 150 + public TESFullName, // 0E0 + public TESModel, // 0F0 + public BGSPreloadable, // 110 + public TESImageSpaceModifiableForm // 118 { public: SF_RTTI_VTABLE(BGSHazard); @@ -61,8 +61,8 @@ namespace RE ~BGSHazard() override; // 00 // members - BGSHazardData data; // 160 - TESCondition conditions; // 1D0 + BGSHazardData data; // 128 + TESCondition conditions; // 198 }; - static_assert(sizeof(BGSHazard) == 0x1E0); + static_assert(sizeof(BGSHazard) == 0x1A8); } diff --git a/CommonLibSF/include/RE/B/BGSIdleMarker.h b/CommonLibSF/include/RE/B/BGSIdleMarker.h index 66fa31e6..0bfad5e8 100644 --- a/CommonLibSF/include/RE/B/BGSIdleMarker.h +++ b/CommonLibSF/include/RE/B/BGSIdleMarker.h @@ -11,9 +11,9 @@ namespace RE class BGSIdleMarker : public TESBoundObject, // 000 - public BGSKeywordForm, // 118 - public TESModel, // 148 - public BGSIdleCollection // 168 + public BGSKeywordForm, // 0E0 + public TESModel, // 110 + public BGSIdleCollection // 130 { public: SF_RTTI_VTABLE(BGSIdleMarker); @@ -22,9 +22,9 @@ namespace RE ~BGSIdleMarker() override; // 00 // members - BGSKeyword* animArchType; // 188 - BGSKeyword* flavorAnim; // 190 - BGSAction* action; // 198 + BGSKeyword* animArchType; // 150 + BGSKeyword* flavorAnim; // 158 + BGSAction* action; // 160 }; - static_assert(sizeof(BGSIdleMarker) == 0x1A0); + static_assert(sizeof(BGSIdleMarker) == 0x168); } diff --git a/CommonLibSF/include/RE/B/BGSKeyword.h b/CommonLibSF/include/RE/B/BGSKeyword.h index 0e1f0b93..b4f22479 100644 --- a/CommonLibSF/include/RE/B/BGSKeyword.h +++ b/CommonLibSF/include/RE/B/BGSKeyword.h @@ -22,5 +22,5 @@ namespace RE BSFixedString unk50; // 50 BSTEventSource destroyEvent; // 58 }; - static_assert(sizeof(BGSKeyword) == 0x80); + static_assert(sizeof(BGSKeyword) == 0x78); } diff --git a/CommonLibSF/include/RE/B/BGSLegendaryItem.h b/CommonLibSF/include/RE/B/BGSLegendaryItem.h index 82da3bb1..1dcc2bb7 100644 --- a/CommonLibSF/include/RE/B/BGSLegendaryItem.h +++ b/CommonLibSF/include/RE/B/BGSLegendaryItem.h @@ -11,8 +11,8 @@ namespace RE class BGSLegendaryItem : public TESBoundObject, // 000 - public BGSModelMaterialSwap, // 118 - public TESFullName // 140 + public BGSModelMaterialSwap, // 0E0 + public TESFullName // 108 { public: SF_RTTI_VTABLE(BGSLegendaryItem); @@ -21,9 +21,9 @@ namespace RE ~BGSLegendaryItem() override; // 00 // members - TESLevItem* applicableItemList; // 150 - BGSLegendaryItem* legendaryTemplate; // 158 - BSTArray unk160[3]; // 160 + TESLevItem* applicableItemList; // 118 + BGSLegendaryItem* legendaryTemplate; // 120 + BSTArray unk128[3]; // 128 }; - static_assert(sizeof(BGSLegendaryItem) == 0x190); + static_assert(sizeof(BGSLegendaryItem) == 0x158); } diff --git a/CommonLibSF/include/RE/B/BGSLevPackIn.h b/CommonLibSF/include/RE/B/BGSLevPackIn.h index 2590e0c0..e0d81865 100644 --- a/CommonLibSF/include/RE/B/BGSLevPackIn.h +++ b/CommonLibSF/include/RE/B/BGSLevPackIn.h @@ -9,9 +9,9 @@ namespace RE { class BGSLevPackIn : public TESBoundAnimObject, // 000 - public TESLeveledList, // 118 - public BGSModelMaterialSwap, // 178 - public BGSForcedLocRefType // 1A0 + public TESLeveledList, // 0E0 + public BGSModelMaterialSwap, // 140 + public BGSForcedLocRefType // 168 { public: SF_RTTI_VTABLE(BGSLevPackIn); @@ -19,5 +19,5 @@ namespace RE ~BGSLevPackIn() override; // 00 }; - static_assert(sizeof(BGSLevPackIn) == 0x1B8); + static_assert(sizeof(BGSLevPackIn) == 0x180); } diff --git a/CommonLibSF/include/RE/B/BGSLevSpaceCell.h b/CommonLibSF/include/RE/B/BGSLevSpaceCell.h index d35e8047..9aa2e496 100644 --- a/CommonLibSF/include/RE/B/BGSLevSpaceCell.h +++ b/CommonLibSF/include/RE/B/BGSLevSpaceCell.h @@ -7,7 +7,7 @@ namespace RE { class BGSLevSpaceCell : public TESForm, // 00 - public TESLeveledList // 38 + public TESLeveledList // 30 { public: SF_RTTI_VTABLE(BGSLevSpaceCell); @@ -15,5 +15,5 @@ namespace RE ~BGSLevSpaceCell() override; // 00 }; - static_assert(sizeof(BGSLevSpaceCell) == 0x98); + static_assert(sizeof(BGSLevSpaceCell) == 0x90); } diff --git a/CommonLibSF/include/RE/B/BGSListForm.h b/CommonLibSF/include/RE/B/BGSListForm.h index 11080154..a33d6dd5 100644 --- a/CommonLibSF/include/RE/B/BGSListForm.h +++ b/CommonLibSF/include/RE/B/BGSListForm.h @@ -15,16 +15,16 @@ namespace RE ~BGSListForm() override; // 00 // members - BSTArray arrayOfForms; // 38 + BSTArray arrayOfForms; // 30 + std::uint64_t unk40; // 40 std::uint64_t unk48; // 48 std::uint64_t unk50; // 50 std::uint64_t unk58; // 58 std::uint64_t unk60; // 60 std::uint64_t unk68; // 68 std::uint64_t unk70; // 70 - std::uint64_t unk78; // 78 - BSTArray* scriptAddedTempForms; // 80 - std::uint32_t scriptAddedFormCount; // 88 + BSTArray* scriptAddedTempForms; // 78 + std::uint32_t scriptAddedFormCount; // 80 }; - static_assert(sizeof(BGSListForm) == 0x90); + static_assert(sizeof(BGSListForm) == 0x88); } diff --git a/CommonLibSF/include/RE/B/BGSLocation.h b/CommonLibSF/include/RE/B/BGSLocation.h index b0607033..e177a375 100644 --- a/CommonLibSF/include/RE/B/BGSLocation.h +++ b/CommonLibSF/include/RE/B/BGSLocation.h @@ -1,33 +1,95 @@ #pragma once #include "RE/A/ActorValueOwner.h" +#include "RE/A/ActorValueStorage.h" +#include "RE/B/BGSEditorID.h" #include "RE/B/BGSKeywordForm.h" #include "RE/B/BGSPropertySheet.h" -#include "RE/T/TESForm.h" +#include "RE/B/BSTArray.h" +#include "RE/B/BSTSmartPointer.h" #include "RE/T/TESFullName.h" +#include "RE/T/TESHandleForm.h" namespace RE { + class BGSMusicType; + class TESFaction; + class BGSLocation : - public TESForm, // 00 - public TESFullName, // 38 - public BGSKeywordForm, // 48 - public BGSPropertySheet, // 78 - public ActorValueOwner // 88 + public TESHandleForm, // 00 + public TESFullName, // 30 + public BGSKeywordForm, // 38 + public BGSPropertySheet, // 70 + public ActorValueOwner // 80 { public: SF_RTTI_VTABLE(BGSLocation); SF_FORMTYPE(LCTN); - std::int8_t pad90[25]; // 90 - std::uint8_t minLevel; // A9 - std::int8_t padAA; // AA - std::uint8_t maxLevel; // AB - std::int8_t padAC[20]; // AC - BGSLocation* parentLocation; // C0 - std::int8_t padC8[276]; // C8 - bool isExplored; // 1DC - bool hasBeenEverExplored; // 1DD - // + enum Flags + { + kNone, + kNoReset = 1 << 0 + }; + + struct KEYWORD_DATA + { + public: + // members + BGSKeyword* keyword; // 00 + float data; // 08 + }; + static_assert(sizeof(KEYWORD_DATA) == 0x10); + + ~BGSLocation() override; // 00 + + // members + BGSEditorID formEditorID; // 088 + TESForm* unk098; // 098 + std::uint8_t unk0A0; // 0A0 + std::uint8_t minLevel; // 0A1 + stl::enumeration flags; // 0A2 + std::uint8_t maxLevel; // 0A3 + std::uint8_t unk0A4; // 0A4 + std::uint64_t unk0A8; // 0A8 + std::uint64_t unk0B0; // 0B0 + BSTSmartPointer parentLocation; // 0B8 + TESFaction* unreportedCrimeFaction; // 0C0 + BGSMusicType* musicType; // 0C8 + TESFaction* ownerFaction; // 0D0 + std::uint32_t unk0D8; // 0D8 - TESPointerHandle + std::uint32_t unk0DC; // 0DC - TESPointerHandle + std::uint64_t unk0E0; // 0E0 + std::uint32_t unk0E8; // 0E8 - TESPointerHandle + BSTArray unk0F0; // 0F0 + BSTArray unk100; // 100 + BSTArray unk110; // 110 + std::uint64_t unk120; // 120 + BSTArray unk128; // 128 + BSTArray unk138; // 138 + std::uint64_t unk148; // 148 + BSTArray unk150; // 150 + std::uint32_t loadedCount; // 160 + std::uint32_t unk164; // 164 + BSTArray unk168; // 168 + std::uint32_t unk178; // 178 + ActorValueStorage avStorage; // 180 + BSTArray keywordData; // 1A8 + BSTArray unk1B8; // 1B8 + std::uint64_t unk1C8; // 1C8 + std::uint32_t unk1D0; // 1D0 + bool explored; // 1D4 + bool everExplored; // 1D5 + bool unk1D6; // 1D6 + std::uint64_t unk1D8; // 1D8 + std::uint64_t unk1E0; // 1E0 + std::uint64_t unk1E8; // 1E8 + std::uint64_t unk1F0; // 1F0 + std::uint64_t unk1F8; // 1F8 + std::uint64_t unk200; // 200 + std::uint64_t unk208; // 208 + std::uint64_t unk210; // 210 + mutable BSReadWriteLock locker; // 218 }; + static_assert(sizeof(BGSLocation) == 0x220); } diff --git a/CommonLibSF/include/RE/B/BGSOutfit.h b/CommonLibSF/include/RE/B/BGSOutfit.h index cd613c96..97dfe642 100644 --- a/CommonLibSF/include/RE/B/BGSOutfit.h +++ b/CommonLibSF/include/RE/B/BGSOutfit.h @@ -14,7 +14,7 @@ namespace RE ~BGSOutfit() override; // 00 // members - BSTArray outfitItems; // 38 + BSTArray outfitItems; // 30 }; - static_assert(sizeof(BGSOutfit) == 0x48); + static_assert(sizeof(BGSOutfit) == 0x40); } diff --git a/CommonLibSF/include/RE/B/BGSPackIn.h b/CommonLibSF/include/RE/B/BGSPackIn.h index 35b21a18..8788cc9f 100644 --- a/CommonLibSF/include/RE/B/BGSPackIn.h +++ b/CommonLibSF/include/RE/B/BGSPackIn.h @@ -15,11 +15,11 @@ namespace RE class BGSPackIn : public TESBoundObject, // 000 - public BGSKeywordForm, // 118 - public BGSPropertySheet, // 148 - public BGSPreviewTransform, // 158 - public BGSForcedLocRefType, // 1A0 - public BGSNativeTerminalForm // 1B8 + public BGSKeywordForm, // 0E0 + public BGSPropertySheet, // 110 + public BGSPreviewTransform, // 120 + public BGSForcedLocRefType, // 168 + public BGSNativeTerminalForm // 180 { public: SF_RTTI_VTABLE(BGSPackIn); @@ -28,11 +28,11 @@ namespace RE ~BGSPackIn() override; // 00 // members - TESObjectCELL* cell; // 1C8 - std::uint32_t flags; // 1D0 - BSStringT filter; // 1D4 - BSTArray materialSwaps; // 1E8 - std::uint32_t unk1F8; // 1F8 + TESObjectCELL* cell; // 190 + std::uint32_t flags; // 198 + BSStringT filter; // 19C + BSTArray materialSwaps; // 1B0 + std::uint32_t unk1C0; // 1C0 }; - static_assert(sizeof(BGSPackIn) == 0x200); + static_assert(sizeof(BGSPackIn) == 0x1C8); } diff --git a/CommonLibSF/include/RE/B/BGSPerk.h b/CommonLibSF/include/RE/B/BGSPerk.h index 1fb2fcfa..e34482b1 100644 --- a/CommonLibSF/include/RE/B/BGSPerk.h +++ b/CommonLibSF/include/RE/B/BGSPerk.h @@ -11,8 +11,8 @@ namespace RE class BGSPerk : public TESForm, // 00 - public TESFullName, // 38 - public TESDescription // 48 + public TESFullName, // 30 + public TESDescription // 40 { public: SF_RTTI_VTABLE(BGSPerk); @@ -21,18 +21,18 @@ namespace RE ~BGSPerk() override; // 00 // members - std::uint16_t unk60; // 60 - std::uint8_t unk62; // 62 - std::uint8_t unk63; // 63 - std::uint8_t unk64; // 64 - BGSPerk* trainingPerk; // 68 - BSFixedStringCS unk70; // 70 - BSFixedString perkIcon; // 78 - GNAM - BGSKeyword* restriction; // 80 + std::uint16_t unk58; // 58 + std::uint8_t unk5A; // 5A + std::uint8_t unk5B; // 5B + std::uint8_t unk5C; // 5C + BGSPerk* trainingPerk; // 60 + BSFixedStringCS unk68; // 68 + BSFixedString perkIcon; // 70 - GNAM + BGSKeyword* restriction; // 78 + std::uint64_t unk80; // 80 std::uint64_t unk88; // 88 std::uint64_t unk90; // 90 - std::uint64_t unk98; // 98 - BSTArray unkA0; // A0 + BSTArray unk98; // 98 }; - static_assert(sizeof(BGSPerk) == 0xB0); + static_assert(sizeof(BGSPerk) == 0xA8); } diff --git a/CommonLibSF/include/RE/B/BGSProjectedDecal.h b/CommonLibSF/include/RE/B/BGSProjectedDecal.h index f3434c09..358c1f70 100644 --- a/CommonLibSF/include/RE/B/BGSProjectedDecal.h +++ b/CommonLibSF/include/RE/B/BGSProjectedDecal.h @@ -28,8 +28,8 @@ namespace RE ~BGSProjectedDecal() override; // 00 // members - BGSMaterialPathForm* material; // 118 - Data data; // 120 + BGSMaterialPathForm* material; // E8 + Data data; // F0 }; - static_assert(sizeof(BGSProjectedDecal) == 0x138); + static_assert(sizeof(BGSProjectedDecal) == 0x100); } diff --git a/CommonLibSF/include/RE/B/BGSProjectile.h b/CommonLibSF/include/RE/B/BGSProjectile.h index 5e14e72c..6139521f 100644 --- a/CommonLibSF/include/RE/B/BGSProjectile.h +++ b/CommonLibSF/include/RE/B/BGSProjectile.h @@ -85,10 +85,10 @@ namespace RE class BGSProjectile : public TESBoundObject, // 000 - public TESFullName, // 118 - public TESModel, // 128 - public BGSPreloadable, // 148 - public BGSDestructibleObjectForm // 150 + public TESFullName, // 0E0 + public TESModel, // 0F0 + public BGSPreloadable, // 110 + public BGSDestructibleObjectForm // 118 { public: SF_RTTI_VTABLE(BGSProjectile); @@ -97,13 +97,13 @@ namespace RE ~BGSProjectile() override; // 00 // members - BGSProjectileData data; // 160 - TESModel muzzleFlashModel; // 1F8 - BGSCurveForm* curveTable; // 218 - BGSAudio::WwiseSoundHook activeSoundLoop; // 220 - BGSAudio::WwiseSoundHook countdownSound; // 250 - BGSAudio::WwiseSoundHook deactivateSound; // 280 - std::uint32_t unk2B0; // 2B0 + BGSProjectileData data; // 128 + TESModel muzzleFlashModel; // 1C0 + BGSCurveForm* curveTable; // 1E0 + BGSAudio::WwiseSoundHook activeSoundLoop; // 1E8 + BGSAudio::WwiseSoundHook countdownSound; // 218 + BGSAudio::WwiseSoundHook deactivateSound; // 248 + std::uint32_t unk278; // 278 }; - static_assert(sizeof(BGSProjectile) == 0x2B8); + static_assert(sizeof(BGSProjectile) == 0x280); } diff --git a/CommonLibSF/include/RE/B/BGSReflectedForm.h b/CommonLibSF/include/RE/B/BGSReflectedForm.h index 93763151..4f991afd 100644 --- a/CommonLibSF/include/RE/B/BGSReflectedForm.h +++ b/CommonLibSF/include/RE/B/BGSReflectedForm.h @@ -23,5 +23,5 @@ namespace RE virtual void Unk_6A(); // 6A virtual void Unk_6B(); // 6B }; - static_assert(sizeof(BGSReflectedForm) == 0x38); + static_assert(sizeof(BGSReflectedForm) == 0x30); } diff --git a/CommonLibSF/include/RE/B/BGSScene.h b/CommonLibSF/include/RE/B/BGSScene.h index a1c448fa..f77351d9 100644 --- a/CommonLibSF/include/RE/B/BGSScene.h +++ b/CommonLibSF/include/RE/B/BGSScene.h @@ -7,7 +7,7 @@ namespace RE { class BGSScene : public TESForm, // 00 - public IKeywordFormBase // 20 + public IKeywordFormBase // 30 { public: SF_RTTI_VTABLE(BGSScene); diff --git a/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h b/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h index 994eaa3e..0de8fea0 100644 --- a/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h +++ b/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h @@ -4,20 +4,23 @@ namespace RE { + class BGSSnapTemplate; + class BGSSnapBehavior; + class BGSSnapTemplateComponent : public BaseFormComponent { public: SF_RTTI_VTABLE(BGSSnapTemplateComponent); - virtual ~BGSSnapTemplateComponent() override; + ~BGSSnapTemplateComponent() override; // override (BaseFormComponent) const BSFixedString& GetFormComponentType() const override; // 01 - { return "BGSSnapTemplateComponent_Component"; } void InitializeDataComponent() override; // 02 - { return; } // members - std::uint64_t unk08; // 08 - std::uint64_t unk10; // 10 + BGSSnapTemplate* snapTemplate; // 08 + BGSSnapBehavior* snapBehavior; // 10 }; static_assert(sizeof(BGSSnapTemplateComponent) == 0x18); } diff --git a/CommonLibSF/include/RE/B/BGSStaticCollection.h b/CommonLibSF/include/RE/B/BGSStaticCollection.h index 1e771a34..55083803 100644 --- a/CommonLibSF/include/RE/B/BGSStaticCollection.h +++ b/CommonLibSF/include/RE/B/BGSStaticCollection.h @@ -10,7 +10,7 @@ namespace RE class BGSStaticCollection : public TESBoundObject, // 000 - public BGSModelMaterialSwap // 118 + public BGSModelMaterialSwap // 0E0 { public: SF_RTTI_VTABLE(BGSStaticCollection); @@ -19,8 +19,8 @@ namespace RE ~BGSStaticCollection() override; // 00 // members - NiPointer navmesh; // 140 - std::uint64_t unk148; // 148 - BSTHashMap* + NiPointer navmesh; // 108 + std::uint64_t unk110; // 110 - BSTHashMap* }; - static_assert(sizeof(BGSStaticCollection) == 0x150); + static_assert(sizeof(BGSStaticCollection) == 0x118); } diff --git a/CommonLibSF/include/RE/B/BGSTerminalMenu.h b/CommonLibSF/include/RE/B/BGSTerminalMenu.h index 553f2821..d789ba6f 100644 --- a/CommonLibSF/include/RE/B/BGSTerminalMenu.h +++ b/CommonLibSF/include/RE/B/BGSTerminalMenu.h @@ -9,7 +9,7 @@ namespace RE { class BGSTerminalMenu : public TESForm, // 00 - public TESFullName // 38 + public TESFullName // 30 { public: SF_RTTI_VTABLE(BGSTerminalMenu); @@ -18,12 +18,12 @@ namespace RE ~BGSTerminalMenu() override; // 00 // members - BSTArray unk48; // 48 - BSTArray unk58; // 58 - BGSLocalizedString unk68; // 68 + BSTArray unk48; // 40 + BSTArray unk58; // 50 + BGSLocalizedString unk60; // 60 + std::uint64_t unk68; // 68 std::uint64_t unk70; // 70 - std::uint64_t unk78; // 78 - std::uint32_t unk80; // 80 + std::uint32_t unk78; // 78 }; - static_assert(sizeof(BGSTerminalMenu) == 0x88); + static_assert(sizeof(BGSTerminalMenu) == 0x80); } diff --git a/CommonLibSF/include/RE/B/BGSTextureSet.h b/CommonLibSF/include/RE/B/BGSTextureSet.h index 10179c72..d9cf8244 100644 --- a/CommonLibSF/include/RE/B/BGSTextureSet.h +++ b/CommonLibSF/include/RE/B/BGSTextureSet.h @@ -29,8 +29,8 @@ namespace RE } class BGSTextureSet : - public TESBoundObject, // 000 - public TextureUtils::TextureIdSet // 118 + public TESBoundObject, // 00 + public TextureUtils::TextureIdSet // E0 { public: SF_RTTI_VTABLE(BGSTextureSet); @@ -39,10 +39,10 @@ namespace RE ~BGSTextureSet() override; // 00 // members - BSFixedString materialName; // 290 - TESTexture textures[19]; // 298 - DecalData* decalData; // 3C8 - std::uint16_t flags; // 3D0 + BSFixedString materialName; // 258 + TESTexture textures[19]; // 260 + DecalData* decalData; // 390 + std::uint16_t flags; // 398 }; - static_assert(sizeof(BGSTextureSet) == 0x3D8); + static_assert(sizeof(BGSTextureSet) == 0x3A0); } diff --git a/CommonLibSF/include/RE/B/BGSVoiceType.h b/CommonLibSF/include/RE/B/BGSVoiceType.h index 1ed8a496..373998b4 100644 --- a/CommonLibSF/include/RE/B/BGSVoiceType.h +++ b/CommonLibSF/include/RE/B/BGSVoiceType.h @@ -32,9 +32,9 @@ namespace RE ~BGSVoiceType() override; // 00 // members - BGSEditorID formEditorID; // 38 - BGSKeyword* animationFaceArchetype; // 48 - VOICE_TYPE_DATA data; // 50 + BGSEditorID formEditorID; // 30 + BGSKeyword* animationFaceArchetype; // 40 + VOICE_TYPE_DATA data; // 48 }; - static_assert(sizeof(BGSVoiceType) == 0x58); + static_assert(sizeof(BGSVoiceType) == 0x50); } diff --git a/CommonLibSF/include/RE/B/BSInputEventReceiver.h b/CommonLibSF/include/RE/B/BSInputEventReceiver.h index def64e81..5ba801fe 100644 --- a/CommonLibSF/include/RE/B/BSInputEventReceiver.h +++ b/CommonLibSF/include/RE/B/BSInputEventReceiver.h @@ -7,13 +7,15 @@ namespace RE class BSInputEventReceiver { public: + SF_RTTI_VTABLE(BSInputEventReceiver); + virtual ~BSInputEventReceiver() = default; // 00 // add virtual void PerformInputProcessing(const InputEvent* a_queueHead) = 0; // 01 // members - std::uint32_t currInputTimeCount; // 08 + std::int32_t currInputTimeCount; // 08 }; static_assert(sizeof(BSInputEventReceiver) == 0x10); } diff --git a/CommonLibSF/include/RE/B/BSInputEventUser.h b/CommonLibSF/include/RE/B/BSInputEventUser.h index ecfe109b..876baf21 100644 --- a/CommonLibSF/include/RE/B/BSInputEventUser.h +++ b/CommonLibSF/include/RE/B/BSInputEventUser.h @@ -1,7 +1,18 @@ #pragma once +#include "RE/M/MemoryManager.h" + namespace RE { + class ButtonEvent; + class CharacterEvent; + class CursorMoveEvent; + class DeviceConnectEvent; + class InputEvent; + class KinectEvent; + class MouseMoveEvent; + class ThumbstickEvent; + class BSInputEventUser { public: @@ -10,15 +21,17 @@ namespace RE virtual ~BSInputEventUser() = default; // 00 // add - virtual void Unk_01(void); // 01 - virtual void Unk_02(void); // 02 - virtual void Unk_03(void); // 03 - virtual void Unk_04(void); // 04 - virtual void Unk_05(void); // 05 - virtual void Unk_06(void); // 06 - virtual void Unk_07(void); // 07 - virtual void Unk_08(void); // 08 - virtual void Unk_09(void); // 09 + virtual bool ShouldHandleEvent(const InputEvent*) { return false; } // 01 + virtual void HandleEvent(const KinectEvent*) { return; } // 02 + virtual void HandleEvent(const DeviceConnectEvent*) { return; } // 03 + virtual void HandleEvent(const ThumbstickEvent*) { return; } // 04 + virtual void HandleEvent(const CursorMoveEvent*) { return; } // 05 + virtual void HandleEvent(const MouseMoveEvent*) { return; } // 06 + virtual void HandleEvent(const CharacterEvent*) { return; } // 07 + virtual void HandleEvent(const ButtonEvent*) { return; } // 08 + virtual void Unk_09(const InputEvent*); // 09 + + SF_HEAP_REDEFINE_NEW(BSInputEventUser); // members std::uint8_t pad08[0x30]; // 08 diff --git a/CommonLibSF/include/RE/B/BSTEvent.h b/CommonLibSF/include/RE/B/BSTEvent.h index 8fde218d..68493e2c 100644 --- a/CommonLibSF/include/RE/B/BSTEvent.h +++ b/CommonLibSF/include/RE/B/BSTEvent.h @@ -95,4 +95,14 @@ namespace RE virtual ~BSTGlobalEvent(); // 00 }; static_assert(sizeof(BSTGlobalEvent) == 0x08); + + template + class BSTEventSourceLazyInit + { + public: + // members + BSTEventSource* eventSource; // 00 + std::uint64_t unk08; // 08 + }; + static_assert(sizeof(BSTEventSourceLazyInit) == 0x10); } diff --git a/CommonLibSF/include/RE/B/BarrierProjectile.h b/CommonLibSF/include/RE/B/BarrierProjectile.h index a1233dc1..c2685616 100644 --- a/CommonLibSF/include/RE/B/BarrierProjectile.h +++ b/CommonLibSF/include/RE/B/BarrierProjectile.h @@ -23,8 +23,8 @@ namespace RE virtual void Unk_15D(); // 15D // members - float width; // 280 - BSTArray collisionData; // 288 + float width; // 260 + BSTArray collisionData; // 268 }; - static_assert(sizeof(BarrierProjectile) == 0x2A0); + static_assert(sizeof(BarrierProjectile) == 0x280); } diff --git a/CommonLibSF/include/RE/B/BeamProjectile.h b/CommonLibSF/include/RE/B/BeamProjectile.h index 2dfc82ab..15b19f86 100644 --- a/CommonLibSF/include/RE/B/BeamProjectile.h +++ b/CommonLibSF/include/RE/B/BeamProjectile.h @@ -21,16 +21,16 @@ namespace RE ~BeamProjectile() override; // 00 // members - void* unk2B0; // 2B0 - smart ptr - std::uint64_t unk2B8; // 2B8 - ProjectileLaunchData launchData; // 2C0 - std::uint64_t unk3B0; // 3B0 - std::uint64_t unk3C0; // 3C0 - void* unk3C8; // 3C8 - smart ptr - std::uint32_t unk3D0; // 3D0 - std::uint8_t unk3D4; // 3D4 - std::uint8_t unk3D5; // 3D5 - std::uint8_t unk3D6; // 3D6 + void* unk290; // 290 - smart ptr + std::uint64_t unk298; // 298 + ProjectileLaunchData launchData; // 2A0 + std::uint64_t unk390; // 390 + std::uint64_t unk3A0; // 3A0 + void* unk3A8; // 3A8 - smart ptr + std::uint32_t unk3B0; // 3B0 + std::uint8_t unk3B4; // 3B4 + std::uint8_t unk3B5; // 3B5 + std::uint8_t unk3B6; // 3B6 }; - static_assert(sizeof(BeamProjectile) == 0x3E0); + static_assert(sizeof(BeamProjectile) == 0x3C0); } diff --git a/CommonLibSF/include/RE/C/ConeProjectile.h b/CommonLibSF/include/RE/C/ConeProjectile.h index 317f20a9..d4144ccd 100644 --- a/CommonLibSF/include/RE/C/ConeProjectile.h +++ b/CommonLibSF/include/RE/C/ConeProjectile.h @@ -13,13 +13,13 @@ namespace RE ~ConeProjectile() override; // 00 // members - stl::enumeration impactResult; // 280 - float environmentTimer; // 284 - float coneSpreadTangent; // 288 - float initialCollisionSphereRadius; // 28C - Location origin; // 290 - void* collisionShape; // 2A8 - BSTArray collisions; // 2B0 + stl::enumeration impactResult; // 260 + float environmentTimer; // 264 + float coneSpreadTangent; // 268 + float initialCollisionSphereRadius; // 26C + Location origin; // 270 + void* collisionShape; // 288 + BSTArray collisions; // 290 }; - static_assert(sizeof(ConeProjectile) == 0x2C0); + static_assert(sizeof(ConeProjectile) == 0x2A0); } diff --git a/CommonLibSF/include/RE/E/EffectSetting.h b/CommonLibSF/include/RE/E/EffectSetting.h index 003ff193..13be61c5 100644 --- a/CommonLibSF/include/RE/E/EffectSetting.h +++ b/CommonLibSF/include/RE/E/EffectSetting.h @@ -26,9 +26,9 @@ namespace RE class EffectSetting : public TESForm, // 000 - public TESFullName, // 038 - public BGSMenuDisplayObject, // 048 - public BGSKeywordForm // 058 + public TESFullName, // 030 + public BGSMenuDisplayObject, // 040 + public BGSKeywordForm // 050 { public: SF_RTTI_VTABLE(EffectSetting); @@ -104,16 +104,16 @@ namespace RE ~EffectSetting() override; // 00 // members - FilterValidationFunction_t* filterValidationFunction; // 088 - void* filterValidationItem; // 090 - EffectSettingData data; // 098 - BSTArray unk168; // 168 - std::uint8_t unk178[0x48]; // 178 - ESSH + FilterValidationFunction_t* filterValidationFunction; // 080 + void* filterValidationItem; // 088 + EffectSettingData data; // 090 + BSTArray unk160; // 160 + std::uint8_t unk170[0x48]; // 170 - ESSH + std::uint64_t unk1B8; // 1B8 std::uint64_t unk1C0; // 1C0 - std::uint64_t unk1C8; // 1C8 - BGSLocalizedString magicItemDescription; // 1D0 - std::uint64_t unk1D8; // 1D8 - TESCondition conditions; // 1E0 + BGSLocalizedString magicItemDescription; // 1C8 + std::uint64_t unk1D0; // 1D0 + TESCondition conditions; // 1D8 }; - static_assert(sizeof(EffectSetting) == 0x1F0); + static_assert(sizeof(EffectSetting) == 0x1E8); } diff --git a/CommonLibSF/include/RE/E/EmitterProjectile.h b/CommonLibSF/include/RE/E/EmitterProjectile.h index 240e92ec..ef02dc5d 100644 --- a/CommonLibSF/include/RE/E/EmitterProjectile.h +++ b/CommonLibSF/include/RE/E/EmitterProjectile.h @@ -18,17 +18,17 @@ namespace RE ~EmitterProjectile() override; // 00 // members - std::int32_t unk280; // 280 - BSTSmartPointer unk288; // 288 - BSTSmartPointer unk290; // 290 - BSTSmartPointer unk298; // 298 - bool unk2A0; // 2A0 - bool unk2A1; // 2A1 + std::int32_t unk260; // 260 + BSTSmartPointer unk268; // 268 + BSTSmartPointer unk270; // 270 + BSTSmartPointer unk278; // 278 + bool unk280; // 280 + bool unk281; // 281 + std::uint64_t unk288; // 288 + std::uint64_t unk290; // 290 + std::uint64_t unk298; // 298 + std::uint64_t unk2A0; // 2A0 std::uint64_t unk2A8; // 2A8 - std::uint64_t unk2B0; // 2B0 - std::uint64_t unk2B8; // 2B8 - std::uint64_t unk2C0; // 2C0 - std::uint64_t unk2C8; // 2C8 }; - static_assert(sizeof(EmitterProjectile) == 0x2D0); + static_assert(sizeof(EmitterProjectile) == 0x2B0); } diff --git a/CommonLibSF/include/RE/E/EnchantmentItem.h b/CommonLibSF/include/RE/E/EnchantmentItem.h index d6ab3651..b3f2e375 100644 --- a/CommonLibSF/include/RE/E/EnchantmentItem.h +++ b/CommonLibSF/include/RE/E/EnchantmentItem.h @@ -28,7 +28,7 @@ namespace RE static_assert(sizeof(Data) == 0x28); // members - Data data; // 188 + Data data; // 150 }; - static_assert(sizeof(EnchantmentItem) == 0x1B0); + static_assert(sizeof(EnchantmentItem) == 0x178); } diff --git a/CommonLibSF/include/RE/F/FlameProjectile.h b/CommonLibSF/include/RE/F/FlameProjectile.h index 7af02b4f..ccfacfee 100644 --- a/CommonLibSF/include/RE/F/FlameProjectile.h +++ b/CommonLibSF/include/RE/F/FlameProjectile.h @@ -13,8 +13,8 @@ namespace RE ~FlameProjectile() override; // 00 // members - float expirationTimer; // 280 - float coneAngle; // 284 + float expirationTimer; // 260 + float coneAngle; // 264 }; - static_assert(sizeof(FlameProjectile) == 0x290); + static_assert(sizeof(FlameProjectile) == 0x270); } diff --git a/CommonLibSF/include/RE/G/GrenadeProjectile.h b/CommonLibSF/include/RE/G/GrenadeProjectile.h index 6fd10ed1..f521b111 100644 --- a/CommonLibSF/include/RE/G/GrenadeProjectile.h +++ b/CommonLibSF/include/RE/G/GrenadeProjectile.h @@ -16,8 +16,8 @@ namespace RE ~GrenadeProjectile() override; // 00 // members - BSTSmartPointer decalGroup; // 280 - NiPointer? - bool collisionGroupReset; // 288 + BSTSmartPointer decalGroup; // 260 - NiPointer? + bool collisionGroupReset; // 268 }; - static_assert(sizeof(GrenadeProjectile) == 0x290); + static_assert(sizeof(GrenadeProjectile) == 0x270); } diff --git a/CommonLibSF/include/RE/I/InteriorData.h b/CommonLibSF/include/RE/I/InteriorData.h new file mode 100644 index 00000000..126f082a --- /dev/null +++ b/CommonLibSF/include/RE/I/InteriorData.h @@ -0,0 +1,40 @@ +#pragma once + +namespace RE +{ + struct INTERIOR_DATA + { + public: + // members + std::uint32_t ambient; // 00 + std::uint32_t directional; // 04 + std::uint32_t fogColorNear; // 08 + float fogNear; // 0C + float fogFar; // 10 + std::uint32_t directionalXY; // 14 + std::uint32_t directionalZ; // 18 + float directionalFade; // 1C + float clipDist; // 20 + std::uint32_t fogPower; // 24 + std::uint32_t fogColorFar; // 28 + float fogClamp; // 2C + float lightFadeStart; // 30 + float lightFadeEnd; // 34 + std::uint32_t unk38; // 38 + float fogHeightMid; // 3C + float fogHeightRange; // 40 + std::uint32_t fogColorHighNear; // 44 + std::uint32_t fogColorHighFar; // 48 + float fogHighDensityScale; // 4C + float fogNearColorScale; // 50 + float fogFarColorScale; // 54 + float fogHighNearColorScale; // 58 + float fogHighFarColorScale; // 5C + float fogFarHeightMid; // 60 + float fogFarHeightRange; // 64 + std::int8_t flags; // 68 + std::uint32_t unk6C; // 6C + std::uint64_t unk70; // 70 + }; + static_assert(sizeof(INTERIOR_DATA) == 0x78); +} diff --git a/CommonLibSF/include/RE/M/MagicItem.h b/CommonLibSF/include/RE/M/MagicItem.h index a14c49f9..8f11bb71 100644 --- a/CommonLibSF/include/RE/M/MagicItem.h +++ b/CommonLibSF/include/RE/M/MagicItem.h @@ -18,8 +18,8 @@ namespace RE class MagicItem : public TESBoundObject, // 000 - public TESFullName, // 118 - public BGSKeywordForm // 128 + public TESFullName, // 0E0 + public BGSKeywordForm // 0F0 { public: SF_RTTI_VTABLE(MagicItem); @@ -77,11 +77,11 @@ namespace RE virtual void InitFromChunk(TESFile* a_file); // 9D // members - BSTArray listOfEffects; // 158 - std::int32_t hostileCount; // 168 - EffectSetting* avEffectSetting; // 170 - std::uint32_t preloadCount; // 174 - BSTSmartPointer preloadedItem; // 180 + BSTArray listOfEffects; // 120 + std::int32_t hostileCount; // 130 + EffectSetting* avEffectSetting; // 138 + std::uint32_t preloadCount; // 13C + BSTSmartPointer preloadedItem; // 148 }; - static_assert(sizeof(MagicItem) == 0x188); + static_assert(sizeof(MagicItem) == 0x150); } diff --git a/CommonLibSF/include/RE/M/MissileProjectile.h b/CommonLibSF/include/RE/M/MissileProjectile.h index 0a1347b7..737327ca 100644 --- a/CommonLibSF/include/RE/M/MissileProjectile.h +++ b/CommonLibSF/include/RE/M/MissileProjectile.h @@ -16,14 +16,14 @@ namespace RE virtual bool ShouldReorient() const; // 15D // members - NiMatrix3 unk280; // 280 - NiPoint3 unk2B0; // 2B0 - std::uint32_t unk2BC; // 2BC - NiPointer modelCollision; // 2C0 - stl::enumeration impactResult; // 2C8 - bool waitingToInitialize3D; // 2CC - bool unk2CD; // 2CD - bool unk2CE; // 2CE + NiMatrix3 unk260; // 260 + NiPoint3 unk290; // 290 + std::uint32_t unk29C; // 29C + NiPointer modelCollision; // 2A0 + stl::enumeration impactResult; // 2A8 + bool waitingToInitialize3D; // 2AC + bool unk2AD; // 2AD + bool unk2AE; // 2AE }; - static_assert(sizeof(MissileProjectile) == 0x2D0); + static_assert(sizeof(MissileProjectile) == 0x2B0); } diff --git a/CommonLibSF/include/RE/N/NiPoint2.h b/CommonLibSF/include/RE/N/NiPoint2.h new file mode 100644 index 00000000..20ecacc6 --- /dev/null +++ b/CommonLibSF/include/RE/N/NiPoint2.h @@ -0,0 +1,13 @@ +#pragma once + +namespace RE +{ + class NiPoint2 + { + public: + // members + float x; // 0 + float y; // 4 + }; + static_assert(sizeof(NiPoint2) == 0x8); +} diff --git a/CommonLibSF/include/RE/P/PlasmaProjectile.h b/CommonLibSF/include/RE/P/PlasmaProjectile.h index a73889b2..67a562fc 100644 --- a/CommonLibSF/include/RE/P/PlasmaProjectile.h +++ b/CommonLibSF/include/RE/P/PlasmaProjectile.h @@ -12,5 +12,5 @@ namespace RE ~PlasmaProjectile() override; // 00 }; - static_assert(sizeof(PlasmaProjectile) == 0x2C0); + static_assert(sizeof(PlasmaProjectile) == 0x2A0); } diff --git a/CommonLibSF/include/RE/P/PlayerCharacter.h b/CommonLibSF/include/RE/P/PlayerCharacter.h index b470a447..d77d600e 100644 --- a/CommonLibSF/include/RE/P/PlayerCharacter.h +++ b/CommonLibSF/include/RE/P/PlayerCharacter.h @@ -36,22 +36,22 @@ namespace RE class PlayerCharacter : public Actor, // 000 - public BSTEventSource, // 550 - public BSTEventSource, // 578 - public BSTEventSource, // 5A0 - public BSTEventSource, // 5C8 - public BSTEventSource, // 5F0 - public BSTEventSink, // 618 - public BSTEventSink, // 620 - public BSTEventSink, // 628 - public BSTEventSink, // 630 - public BSTEventSink, // 638 - public BSTEventSink, // 640 - public BSTEventSink, // 648 - public BSTEventSink, // 650 - public BSTEventSink, // 658 - public BSTEventSink, // 660 - public IMovementPlayerControlsFilter // 668 + public BSTEventSource, // 530 + public BSTEventSource, // 558 + public BSTEventSource, // 580 + public BSTEventSource, // 5A8 + public BSTEventSource, // 5D0 + public BSTEventSink, // 5F8 + public BSTEventSink, // 0600 + public BSTEventSink, // 0608 + public BSTEventSink, // 0610 + public BSTEventSink, // 0618 + public BSTEventSink, // 0620 + public BSTEventSink, // 0628 + public BSTEventSink, // 0630 + public BSTEventSink, // 0638 + public BSTEventSink, // 0640 + public IMovementPlayerControlsFilter // 0648 { public: SF_RTTI_VTABLE(PlayerCharacter); @@ -59,7 +59,7 @@ namespace RE ~PlayerCharacter() override; // 00 - // add + // 0Add virtual void Unk_1A2(); // 1A2 virtual void Unk_1A3(); // 1A3 virtual void Unk_1A4(); // 1A4 @@ -70,6 +70,10 @@ namespace RE bool IsInChargen(); // members + std::uint64_t unk0650; // 0650 + std::uint64_t unk0658; // 0658 + std::uint64_t unk0660; // 0660 + std::uint64_t unk0668; // 0668 std::uint64_t unk0670; // 0670 std::uint64_t unk0678; // 0678 std::uint64_t unk0680; // 0680 @@ -339,22 +343,22 @@ namespace RE std::uint64_t unk0EC0; // 0EC0 std::uint64_t unk0EC8; // 0EC8 std::uint64_t unk0ED0; // 0ED0 - std::uint64_t unk0ED8; // 0ED8 + BGSLocation* currentLocation; // 0ED8 std::uint64_t unk0EE0; // 0EE0 std::uint64_t unk0EE8; // 0EE8 std::uint64_t unk0EF0; // 0EF0 - BGSLocation* currentLocation; // 0EF8 + std::uint64_t unk0EF8; // 0EF8 std::uint64_t unk0F00; // 0F00 std::uint64_t unk0F08; // 0F08 std::uint64_t unk0F10; // 0F10 std::uint64_t unk0F18; // 0F18 std::uint64_t unk0F20; // 0F20 std::uint64_t unk0F28; // 0F28 - std::uint64_t unk0F30; // 0F30 + TESObjectREFR* crosshairRef; // 0F30 - NiPointer? std::uint64_t unk0F38; // 0F38 std::uint64_t unk0F40; // 0F40 std::uint64_t unk0F48; // 0F48 - TESObjectREFR* crosshairRef; // 0F50 - NiPointer? + std::uint64_t unk0F50; // 0F50 std::uint64_t unk0F58; // 0F58 std::uint64_t unk0F60; // 0F60 std::uint64_t unk0F68; // 0F68 @@ -402,13 +406,9 @@ namespace RE std::uint64_t unk10B8; // 10B8 std::uint64_t unk10C0; // 10C0 std::uint64_t unk10C8; // 10C8 - std::uint64_t unk10D0; // 10D0 + float playerGravity; // 10D0 + std::uint32_t unk10D4; // 10D4 std::uint64_t unk10D8; // 10D8 - std::uint64_t unk10E0; // 10E0 - std::uint64_t unk10E8; // 10E8 - float playerGravity; // 10F0 - std::uint32_t unk10F4; // 10F4 - std::uint64_t unk10F8; // 10F8 }; - static_assert(sizeof(PlayerCharacter) == 0x1100); + static_assert(sizeof(PlayerCharacter) == 0x10E0); } diff --git a/CommonLibSF/include/RE/P/Projectile.h b/CommonLibSF/include/RE/P/Projectile.h index c554b034..aa1f8107 100644 --- a/CommonLibSF/include/RE/P/Projectile.h +++ b/CommonLibSF/include/RE/P/Projectile.h @@ -169,59 +169,59 @@ namespace RE virtual bool ShouldUseDesiredTarget(); // 15C // members - BSTArray impacts; // 110 - NiPointer collisionObject; // 120 - NiPointer droppedRefr; // 128 - NiTransform followOffset; // 130 - BSSpinLock lock; // 170 - NiPoint3 movementDirection; // 178 - NiPoint3 velocity; // 184 - void* unk190; // 190 - smart ptr - NiPointer actorCause; // 198 - std::uint32_t shooterHandle; // 1A0 - TESPointerHandle - std::uint32_t desiredTargetHandle; // 1A4 - TESPointerHandle - std::uint32_t unk1A8; // 1A8 - std::uint32_t unk1AC; // 1AC - std::uint32_t unk1B0; // 1B0 - std::uint32_t unk1B4; // 1B4 - BGSExplosion* explosion; // 1B8 - MagicItem* spell; // 1C0 - EffectSetting* avEffect; // 1C8 - void* unk1D0; // 1D0 - smart ptr - void* unk1D8; // 1D8 - smart ptr - void* unk1E0; // 1E0 - smart ptr - void* unk1E8; // 1E8 - smart ptr - std::uint64_t unk1F0; // 1F0 - BGSEquipIndex equipIndex; // 1F8 - stl::enumeration targetLimbEnum; // 1FC - NiPointer targetLimbObj; // 200 - std::uint64_t unk208; // 208 - BGSObjectInstanceT weaponSource; // 210 - TESAmmo* ammoSource; // 220 - std::uint64_t flags; // 228 - std::uint32_t unk230; // 230 - float power; // 234 - float speedMult; // 238 - float range; // 23C - float age; // 240 - float damage; // 244 - float alpha; // 248 - float explosionTimer; // 24C - float blinkTimer; // 250 - float distanceMoved; // 254 - std::uint32_t unk258; // 258 - float scale; // 25C - float unk260; // 260 - float unk264; // 264 - std::uint32_t unk268; // 268 - std::uint32_t unk26C; // 26C - std::uint32_t unk270; // 270 - std::uint32_t unk274; // 274 - stl::enumeration castingSource; // 278 - std::uint8_t unk279; // 279 - bool artRequested; // 27A - bool animationsLoaded; // 27B - std::uint8_t unk27C; // 27C + BSTArray impacts; // 0F0 + NiPointer collisionObject; // 100 + NiPointer droppedRefr; // 108 + NiTransform followOffset; // 110 + BSSpinLock lock; // 150 + NiPoint3 movementDirection; // 158 + NiPoint3 velocity; // 164 + void* unk170; // 170 - smart ptr + NiPointer actorCause; // 178 + std::uint32_t shooterHandle; // 180 - TESPointerHandle + std::uint32_t desiredTargetHandle; // 184 - TESPointerHandle + std::uint32_t unk188; // 188 + std::uint32_t unk18C; // 18C + std::uint32_t unk190; // 190 + std::uint32_t unk194; // 194 + BGSExplosion* explosion; // 198 + MagicItem* spell; // 1A0 + EffectSetting* avEffect; // 1A8 + void* unk1B0; // 1B0 - smart ptr + void* unk1B8; // 1B8 - smart ptr + void* unk1C0; // 1C0 - smart ptr + void* unk1C8; // 1C8 - smart ptr + std::uint64_t unk1D0; // 1D0 + BGSEquipIndex equipIndex; // 1D8 + stl::enumeration targetLimbEnum; // 1DC + NiPointer targetLimbObj; // 1E0 + std::uint64_t unk1E8; // 1E8 + BGSObjectInstanceT weaponSource; // 1F0 + TESAmmo* ammoSource; // 200 + std::uint64_t flags; // 208 + std::uint32_t unk210; // 210 + float power; // 214 + float speedMult; // 218 + float range; // 21C + float age; // 220 + float damage; // 224 + float alpha; // 228 + float explosionTimer; // 22C + float blinkTimer; // 230 + float distanceMoved; // 234 + std::uint32_t unk238; // 238 + float scale; // 23C + float unk240; // 240 + float unk244; // 244 + std::uint32_t unk248; // 248 + std::uint32_t unk24C; // 24C + std::uint32_t unk250; // 250 + std::uint32_t unk254; // 254 + stl::enumeration castingSource; // 258 + std::uint8_t unk259; // 259 + bool artRequested; // 25A + bool animationsLoaded; // 25B + std::uint8_t unk25C; // 25C }; - static_assert(sizeof(Projectile) == 0x280); + static_assert(sizeof(Projectile) == 0x260); } diff --git a/CommonLibSF/include/RE/S/SpellItem.h b/CommonLibSF/include/RE/S/SpellItem.h index 154efd77..ff01b1d0 100644 --- a/CommonLibSF/include/RE/S/SpellItem.h +++ b/CommonLibSF/include/RE/S/SpellItem.h @@ -12,10 +12,10 @@ namespace RE class SpellItem : public MagicItem, // 000 - public BGSEquipType, // 188 - public BGSMenuDisplayObject, // 198 - public BGSPickupPutdownSounds, // 1A8 - public TESDescription // 210 + public BGSEquipType, // 150 + public BGSMenuDisplayObject, // 160 + public BGSPickupPutdownSounds, // 170 + public TESDescription // 1D8 { public: SF_RTTI_VTABLE(SpellItem); @@ -43,7 +43,7 @@ namespace RE virtual void SetSpellType(MagicSystem::SpellType a_spellType); // 9F // members - Data data; // 228 + Data data; // 1F0 }; - static_assert(sizeof(SpellItem) == 0x250); + static_assert(sizeof(SpellItem) == 0x218); } diff --git a/CommonLibSF/include/RE/T/TESActorBase.h b/CommonLibSF/include/RE/T/TESActorBase.h index a0216191..bf39a974 100644 --- a/CommonLibSF/include/RE/T/TESActorBase.h +++ b/CommonLibSF/include/RE/T/TESActorBase.h @@ -20,18 +20,18 @@ namespace RE class TESActorBase : public TESBoundAnimObject, // 000 - public TESActorBaseData, // 118 - public TESContainer, // 188 - public TESSpellList, // 1A0 - public TESAIForm, // 1B8 - public TESFullName, // 1F8 - public ActorValueOwner, // 208 - public BGSDestructibleObjectForm, // 210 - public BGSSkinForm, // 220 - public BGSKeywordForm, // 230 - public BGSAttackDataForm, // 260 - public BGSPerkRankArray, // 270 - public BGSPropertySheet // 288 + public TESActorBaseData, // 0E0 + public TESContainer, // 150 + public TESSpellList, // 168 + public TESAIForm, // 180 + public TESFullName, // 1C0 + public ActorValueOwner, // 1D0 + public BGSDestructibleObjectForm, // 1D8 + public BGSSkinForm, // 1E8 + public BGSKeywordForm, // 1F8 + public BGSAttackDataForm, // 228 + public BGSPerkRankArray, // 238 + public BGSPropertySheet // 250 { public: SF_RTTI_VTABLE(TESActorBase); @@ -44,5 +44,5 @@ namespace RE virtual void SetCombatStyle(TESCombatStyle*); // 84 virtual TESForm* GetAsForm(); // 85 }; - static_assert(sizeof(TESActorBase) == 0x298); + static_assert(sizeof(TESActorBase) == 0x260); } diff --git a/CommonLibSF/include/RE/T/TESAmmo.h b/CommonLibSF/include/RE/T/TESAmmo.h index 6e875c44..764fadcb 100644 --- a/CommonLibSF/include/RE/T/TESAmmo.h +++ b/CommonLibSF/include/RE/T/TESAmmo.h @@ -36,14 +36,14 @@ namespace RE class TESAmmo : public TESBoundObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESValueForm, // 150 - public BGSDestructibleObjectForm, // 160 - public BGSPickupPutdownSounds, // 170 - public TESDescription, // 1D8 - public BGSKeywordForm, // 1F0 - public TESWeightForm // 220 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESValueForm, // 118 + public BGSDestructibleObjectForm, // 128 + public BGSPickupPutdownSounds, // 138 + public TESDescription, // 1A0 + public BGSKeywordForm, // 1B8 + public TESWeightForm // 1E8 { public: SF_RTTI_VTABLE(TESAmmo); @@ -52,9 +52,9 @@ namespace RE ~TESAmmo() override; // 00 // members - AMMO_DATA data; // 230 - BGSLocalizedString shortDesc; // 248 - TESModel shellCasing; // 250 + AMMO_DATA data; // 1F8 + BGSLocalizedString shortDesc; // 210 + TESModel shellCasing; // 218 }; - static_assert(sizeof(TESAmmo) == 0x270); + static_assert(sizeof(TESAmmo) == 0x238); } diff --git a/CommonLibSF/include/RE/T/TESBoundAnimObject.h b/CommonLibSF/include/RE/T/TESBoundAnimObject.h index fa0e44e5..5f3a70b6 100644 --- a/CommonLibSF/include/RE/T/TESBoundAnimObject.h +++ b/CommonLibSF/include/RE/T/TESBoundAnimObject.h @@ -11,5 +11,5 @@ namespace RE ~TESBoundAnimObject() override; // 00 }; - static_assert(sizeof(TESBoundAnimObject) == 0x118); + static_assert(sizeof(TESBoundAnimObject) == 0xE0); } diff --git a/CommonLibSF/include/RE/T/TESBoundObject.h b/CommonLibSF/include/RE/T/TESBoundObject.h index 7b5592c7..5a3cc0fb 100644 --- a/CommonLibSF/include/RE/T/TESBoundObject.h +++ b/CommonLibSF/include/RE/T/TESBoundObject.h @@ -3,7 +3,6 @@ #include "RE/B/BGSMod.h" #include "RE/B/BGSObjectPlacementDefaults.h" #include "RE/B/BGSPreviewTransform.h" -#include "RE/B/BGSSnapTemplateComponent.h" #include "RE/N/NiPoint3.h" #include "RE/T/TESObject.h" @@ -44,21 +43,12 @@ namespace RE virtual void Unk_81(); // 81 // members - BGSSnapTemplateComponent snapTemplate; // 038 - NiPoint3 boundMin; // 050 - NiPoint3 boundMax; // 05C - BGSMod::Template::Items templateItems; // 068 - BGSPreviewTransform previewTransform; // 088 - BGSObjectPlacementDefaults placementDefaults; // 0D0 - std::uint32_t unk0E0; // 0E0 - std::uint32_t unk0E4; // 0E4 - std::uint32_t unk0E8; // 0E8 - std::uint32_t unk0F0; // 0F0 - std::uint32_t unk0F4; // 0F4 - std::uint64_t unk0F8; // 0F8 - std::uint64_t unk100; // 100 - std::uint64_t unk108; // 108 - std::uint64_t unk110; // 110 + NiPoint3 boundMin; // 048 + NiPoint3 boundMax; // 054 + BGSMod::Template::Items templateItems; // 060 + BGSPreviewTransform previewTransform; // 080 + BGSObjectPlacementDefaults placementDefaults; // 0C8 + std::uint32_t unk0D8; // 0D8 }; - static_assert(sizeof(TESBoundObject) == 0x118); + static_assert(sizeof(TESBoundObject) == 0xE0); } diff --git a/CommonLibSF/include/RE/T/TESForm.h b/CommonLibSF/include/RE/T/TESForm.h index 7c7d2ba7..911585f2 100644 --- a/CommonLibSF/include/RE/T/TESForm.h +++ b/CommonLibSF/include/RE/T/TESForm.h @@ -21,6 +21,19 @@ namespace RE struct FORM; struct FORM_GROUP; + struct OBJ_ACTIVATE_DATA + { + TESObjectREFR* activatedRef; // 00 + TESObjectREFR* actionRef; // 08 + TESForm* objectToGet; // 10 + std::int32_t count; // 18 + bool unk1C; // 1C + bool unk1D; // 1D + bool unk1E; // 1E + bool unk1F; // 1F + }; + static_assert(sizeof(OBJ_ACTIVATE_DATA) == 0x20); + class TESForm : public TESFormRefCount, // 00 public BSReflection::IObject // 10 @@ -29,19 +42,6 @@ namespace RE SF_RTTI_VTABLE(TESForm); SF_FORMTYPE(NONE); - struct ActivateData - { - TESObjectREFR* activatedRef; // 00 - TESObjectREFR* actionRef; // 08 - TESForm* objectToGet; // 10 - std::int32_t count; // 18 - bool unk1C; // 1C - bool unk1D; // 1D - bool unk1E; // 1E - bool unk1F; // 1F - }; - static_assert(sizeof(ActivateData) == 0x20); - ~TESForm() override; // 00 // override (BaseFormComponent) @@ -101,7 +101,7 @@ namespace RE virtual void Unk_3C(); // 3C virtual bool IsBoundObject() const; // 3D virtual void Unk_3E(); // 3E - virtual void Unk_3F(); // 3F + virtual bool IsMagicItem(); // 3F virtual bool IsFurniture(); // 40 - new virtual void Unk_41(); // 41 virtual void Unk_42(); // 42 @@ -122,7 +122,7 @@ namespace RE virtual void Unk_51(); // 51 virtual void Unk_52(); // 52 virtual bool LoopingActivate(TESObjectREFR* a_itemActivated, TESObjectREFR* a_actionRef); // 53 - virtual bool Activate(const ActivateData& a_activateData); // 54 + virtual bool Activate(const OBJ_ACTIVATE_DATA& a_activateData); // 54 virtual const char* GetObjectTypeName() const; // 55 virtual void Unk_56(); // 56 virtual void Unk_57(); // 57 @@ -153,18 +153,32 @@ namespace RE [[nodiscard]] static TESForm* LookupByID(std::uint32_t a_formID) { - using func_t = decltype(&TESForm::LookupByID); + using func_t = TESForm* (*)(std::uint32_t); REL::Relocation func{ ID::TESForm::LookupByID }; return func(a_formID); } - [[nodiscard]] static TESForm* LookupByEditorID(const char* a_editorID) + template + [[nodiscard]] static T* LookupByID(std::uint32_t a_formID) + { + const auto form = LookupByID(a_formID); + return form ? form->As() : nullptr; + } + + [[nodiscard]] static TESForm* LookupByEditorID(const BSFixedString& a_editorID) { - using func_t = decltype(&TESForm::LookupByEditorID); + using func_t = TESForm* (*)(const BSFixedString&); REL::Relocation func{ ID::TESForm::LookupByEditorID }; return func(a_editorID); } + template + [[nodiscard]] static T* LookupByEditorID(const BSFixedString& a_editorID) + { + const auto form = LookupByEditorID(a_editorID); + return form ? form->As() : nullptr; + } + [[nodiscard]] TESObjectREFR* AsReference() { return AsReference1(); } [[nodiscard]] const TESObjectREFR* AsReference() const { return AsReference2(); } @@ -212,16 +226,33 @@ namespace RE [[nodiscard]] bool IsPlayerRef() const noexcept { return GetFormID() == 0x00000014; } [[nodiscard]] bool IsWeapon() const noexcept { return Is(FormType::kWEAP); } + template + [[nodiscard]] T* As() noexcept + requires(std::derived_from && + !std::is_pointer_v && + !std::is_reference_v) + { + return Is() ? static_cast(this) : nullptr; + } + + template + [[nodiscard]] const T* As() const noexcept + requires(std::derived_from && + !std::is_pointer_v && + !std::is_reference_v) + { + return Is() ? static_cast(this) : nullptr; + } + // members - std::uint64_t sourceFiles; // 18 - TESFileContainer - std::uint32_t unk20; // 20 - std::uint32_t unk24; // 24 - std::uint32_t formFlags; // 28 - std::uint32_t unk2C; // 2C - std::uint32_t formID; // 30 - std::uint8_t unk34; // 34 - also flag - std::uint8_t unk35; // 35 - stl::enumeration formType; // 36 + std::uint64_t unk18; // 18 + std::uint32_t formFlags; // 20 + std::uint32_t unk24; // 24 + std::uint32_t formID; // 28 + std::uint8_t flags2; // 2C + std::uint8_t unk2D; // 2D + stl::enumeration formType; // 2E + std::uint8_t loadOrderIndex; // 2F - init'd to 0xFF }; - static_assert(sizeof(TESForm) == 0x38); + static_assert(sizeof(TESForm) == 0x30); } diff --git a/CommonLibSF/include/RE/T/TESGlobal.h b/CommonLibSF/include/RE/T/TESGlobal.h index 3b559ac7..cbbd6b62 100644 --- a/CommonLibSF/include/RE/T/TESGlobal.h +++ b/CommonLibSF/include/RE/T/TESGlobal.h @@ -16,8 +16,8 @@ namespace RE [[nodiscard]] float GetValue() const noexcept { return value; } // members - BGSEditorID formEditorID; // 38 - float value; // 48 + BGSEditorID formEditorID; // 30 + float value; // 40 }; - static_assert(sizeof(TESGlobal) == 0x50); + static_assert(sizeof(TESGlobal) == 0x48); } diff --git a/CommonLibSF/include/RE/T/TESGrass.h b/CommonLibSF/include/RE/T/TESGrass.h index cd1c7599..a6065744 100644 --- a/CommonLibSF/include/RE/T/TESGrass.h +++ b/CommonLibSF/include/RE/T/TESGrass.h @@ -7,7 +7,7 @@ namespace RE { class TESGrass : public TESBoundObject, // 00 - public TESModel // 30 + public TESModel // E0 { public: SF_RTTI_VTABLE(TESGrass); @@ -69,7 +69,7 @@ namespace RE virtual void SetFitToSlope(bool a_set); // 99 // members - GRASS_DATA data; // 138 - DATA + GRASS_DATA data; // 100 - DATA }; - static_assert(sizeof(TESGrass) == 0x160); + static_assert(sizeof(TESGrass) == 0x128); } diff --git a/CommonLibSF/include/RE/T/TESHandleForm.h b/CommonLibSF/include/RE/T/TESHandleForm.h index 3965e225..dcb16e19 100644 --- a/CommonLibSF/include/RE/T/TESHandleForm.h +++ b/CommonLibSF/include/RE/T/TESHandleForm.h @@ -12,5 +12,5 @@ namespace RE ~TESHandleForm() override; // 00 }; - static_assert(sizeof(TESHandleForm) == 0x38); + static_assert(sizeof(TESHandleForm) == 0x30); } diff --git a/CommonLibSF/include/RE/T/TESKey.h b/CommonLibSF/include/RE/T/TESKey.h index d632225d..89685b0d 100644 --- a/CommonLibSF/include/RE/T/TESKey.h +++ b/CommonLibSF/include/RE/T/TESKey.h @@ -12,5 +12,5 @@ namespace RE ~TESKey() override; // 00 }; - static_assert(sizeof(TESKey) == 0x290); + static_assert(sizeof(TESKey) == 0x258); } diff --git a/CommonLibSF/include/RE/T/TESLevCharacter.h b/CommonLibSF/include/RE/T/TESLevCharacter.h index 91f701fd..77ef61db 100644 --- a/CommonLibSF/include/RE/T/TESLevCharacter.h +++ b/CommonLibSF/include/RE/T/TESLevCharacter.h @@ -8,8 +8,8 @@ namespace RE { class TESLevCharacter : public TESBoundAnimObject, // 000 - public TESLeveledList, // 118 - public BGSModelMaterialSwap // 178 + public TESLeveledList, // 0E8 + public BGSModelMaterialSwap // 140 { public: SF_RTTI_VTABLE(TESLevCharacter); @@ -17,5 +17,5 @@ namespace RE ~TESLevCharacter() override; // 00 }; - static_assert(sizeof(TESLevCharacter) == 0x1A0); + static_assert(sizeof(TESLevCharacter) == 0x168); } diff --git a/CommonLibSF/include/RE/T/TESLevItem.h b/CommonLibSF/include/RE/T/TESLevItem.h index 0f4480a3..bfd58289 100644 --- a/CommonLibSF/include/RE/T/TESLevItem.h +++ b/CommonLibSF/include/RE/T/TESLevItem.h @@ -9,9 +9,9 @@ namespace RE { class TESLevItem : public TESBoundObject, // 000 - public TESLeveledList, // 118 - public BGSModelMaterialSwap, // 178 - public BGSForcedLocRefType // 1A0 + public TESLeveledList, // 0E0 + public BGSModelMaterialSwap, // 140 + public BGSForcedLocRefType // 168 { public: SF_RTTI_VTABLE(TESLevItem); @@ -19,5 +19,5 @@ namespace RE ~TESLevItem() override; // 00 }; - static_assert(sizeof(TESLevItem) == 0x1B8); + static_assert(sizeof(TESLevItem) == 0x180); } diff --git a/CommonLibSF/include/RE/T/TESLevSpell.h b/CommonLibSF/include/RE/T/TESLevSpell.h index dbfddedc..75678bec 100644 --- a/CommonLibSF/include/RE/T/TESLevSpell.h +++ b/CommonLibSF/include/RE/T/TESLevSpell.h @@ -6,8 +6,8 @@ namespace RE { class TESLevSpell : - public TESBoundObject, // 000 - public TESLeveledList // 118 + public TESBoundObject, // 00 + public TESLeveledList // E8 { public: SF_RTTI_VTABLE(TESLevSpell); @@ -15,5 +15,5 @@ namespace RE ~TESLevSpell() override; // 00 }; - static_assert(sizeof(TESLevSpell) == 0x178); + static_assert(sizeof(TESLevSpell) == 0x140); } diff --git a/CommonLibSF/include/RE/T/TESNPC.h b/CommonLibSF/include/RE/T/TESNPC.h index 6e6e8591..a24cbc43 100644 --- a/CommonLibSF/include/RE/T/TESNPC.h +++ b/CommonLibSF/include/RE/T/TESNPC.h @@ -27,11 +27,11 @@ namespace RE class TESNPC : public TESActorBase, // 000 - public TESRaceForm, // 298 - public BGSOverridePackCollection, // 2A8 - public BGSForcedLocRefType, // 2F0 - public BGSNativeTerminalForm, // 308 - public BSTEventSink // 318 + public TESRaceForm, // 260 + public BGSOverridePackCollection, // 270 + public BGSForcedLocRefType, // 2B8 + public BGSNativeTerminalForm, // 2D0 + public BSTEventSink // 2E0 { public: SF_RTTI_VTABLE(TESNPC); @@ -55,50 +55,49 @@ namespace RE [[nodiscard]] bool IsInFaction(TESFaction* a_faction) const; // members - BGSAttachParentArray attachParents; // 320 - std::uint32_t unk340; // 340 - std::uint32_t unk344; // 344 - TESClass* npcClass; // 348 - std::uint64_t unk350; // 350 - BGSListForm* giftFilter; // 358 - TESCombatStyle* combatStyle; // 360 - std::uint32_t fileOffset; // 368 - std::uint32_t unk36C; // 36C - TESRace* originalRace; // 370 - TESNPC* faceNPC; // 378 - NiPoint3 morphWeight; // 380 - float height; // 38C - float heightMax; // 390 - std::uint32_t unk394; // 394 - TESNPC* unk398; // 398 - std::uint64_t unk3A0; // 3A0 - std::uint64_t unk3A8; // 3A8 - BGSLocalizedString shortName; // 3B0 - TESObjectARMO* farSkin; // 3B8 - TESFurniture* powerArmorFurn; // 3C0 - BGSOutfit* defaultOutfit; // 3C8 - BGSOutfit* sleepOutfit; // 3D0 - BGSListForm* defaultPackList; // 3D8 - TESFaction* crimeFaction; // 3E0 - TESFaction* unk3E8; // 3E8 - BSTArray headparts; // 3F0 - BSNonReentrantSpinLock headpartsLock; // 3F8 - BSTArray* unk408; // 408 - std::uint64_t unk410; // 410 - std::uint64_t unk418; // 418 - BSTArray tintAVMData; // 420 - std::uint32_t skinToneIndex; // 430 - std::uint32_t unk434; // 434 - BSFixedString teeth; // 438 - BSFixedString jewelryColor; // 440 - BSFixedString eyeColor; // 448 - BSFixedString hairColor; // 450 - BSFixedString facialColor; // 458 - BSFixedString eyebrowColor; // 460 - BSTArray* relationships; // 468 - BGSLocalizedString organization; // 470 - faction? - std::uint64_t unk478; // 478 - stl::enumeration pronoun; // 480 + BGSAttachParentArray attachParents; // 2E8 + std::uint32_t unk308; // 308 + std::uint32_t unk30C; // 30C + TESClass* npcClass; // 310 + std::uint64_t unk318; // 318 + BGSListForm* giftFilter; // 320 + TESCombatStyle* combatStyle; // 328 + std::uint32_t fileOffset; // 330 + std::uint32_t unk334; // 334 + TESRace* originalRace; // 338 + TESNPC* faceNPC; // 340 + NiPoint3 morphWeight; // 348 + float height; // 354 + float heightMax; // 358 + std::uint32_t unk35C; // 35C + TESNPC* unk360; // 360 + std::uint64_t unk368; // 368 + std::uint64_t unk370; // 370 + BGSLocalizedString shortName; // 378 + TESObjectARMO* farSkin; // 380 + TESFurniture* powerArmorFurn; // 388 + BGSOutfit* defaultOutfit; // 390 + BGSOutfit* sleepOutfit; // 398 + BGSListForm* defaultPackList; // 3A0 + TESFaction* crimeFaction; // 3A8 + TESFaction* unk3B0; // 3B0 + BSGuarded, BSNonReentrantSpinLock> headparts; // 3B8 + BSTArray* unk3D0; // 3D0 + std::uint64_t unk3D8; // 3D8 + std::uint64_t unk3E0; // 3E0 + BSTArray tintAVMData; // 3E8 + std::uint32_t skinToneIndex; // 3F8 + std::uint32_t unk3FC; // 3FC + BSFixedString teeth; // 400 + BSFixedString jewelryColor; // 408 + BSFixedString eyeColor; // 410 + BSFixedString hairColor; // 418 + BSFixedString facialColor; // 420 + BSFixedString eyebrowColor; // 428 + BSTArray* relationships; // 430 + BGSLocalizedString organization; // 438 - faction? + std::uint64_t unk440; // 440 + stl::enumeration pronoun; // 448 }; - static_assert(sizeof(TESNPC) == 0x488); + static_assert(sizeof(TESNPC) == 0x450); } diff --git a/CommonLibSF/include/RE/T/TESObject.h b/CommonLibSF/include/RE/T/TESObject.h index e25cdd13..0d6414a3 100644 --- a/CommonLibSF/include/RE/T/TESObject.h +++ b/CommonLibSF/include/RE/T/TESObject.h @@ -1,5 +1,6 @@ #pragma once +#include "RE/B/BGSSnapTemplateComponent.h" #include "RE/T/TESForm.h" namespace RE @@ -22,6 +23,9 @@ namespace RE virtual void Unk_69(); // 69 virtual void Unk_6A(); // 6A virtual void Unk_6B(); // 6B + + // members + BGSSnapTemplateComponent snapTemplate; // 030 }; - static_assert(sizeof(TESObject) == 0x38); + static_assert(sizeof(TESObject) == 0x48); } diff --git a/CommonLibSF/include/RE/T/TESObjectACTI.h b/CommonLibSF/include/RE/T/TESObjectACTI.h index 19c757d6..95d531c3 100644 --- a/CommonLibSF/include/RE/T/TESObjectACTI.h +++ b/CommonLibSF/include/RE/T/TESObjectACTI.h @@ -19,16 +19,16 @@ namespace RE class TESObjectACTI : public TESBoundAnimObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESMagicTargetForm, // 150 - public BGSDestructibleObjectForm, // 158 - public BGSOpenCloseForm, // 168 - public BGSKeywordForm, // 170 - public BGSPropertySheet, // 1A0 - public BGSForcedLocRefType, // 1B0 - public BGSNativeTerminalForm, // 1C8 - public BGSNavmeshableObject // 1D8 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESMagicTargetForm, // 118 + public BGSDestructibleObjectForm, // 120 + public BGSOpenCloseForm, // 130 + public BGSKeywordForm, // 138 + public BGSPropertySheet, // 168 + public BGSForcedLocRefType, // 178 + public BGSNativeTerminalForm, // 190 + public BGSNavmeshableObject // 1A0 { public: SF_RTTI_VTABLE(TESObjectACTI); @@ -37,13 +37,13 @@ namespace RE ~TESObjectACTI() override; // 00 // members - BGSAudio::WwiseSoundHook soundLoop; // 1E0 - BGSAudio::WwiseSoundHook soundActivate; // 210 - TESWaterForm* waterForm; // 240 - std::uint32_t unk248; // 248 - std::uint16_t flags; // 24C - std::uint16_t activationAngle; // 24E - std::uint8_t unk250; // 250 + BGSAudio::WwiseSoundHook soundLoop; // 1A8 + BGSAudio::WwiseSoundHook soundActivate; // 1D8 + TESWaterForm* waterForm; // 208 + std::uint32_t unk210; // 210 + std::uint16_t flags; // 214 + std::uint16_t activationAngle; // 216 + std::uint8_t unk218; // 218 }; - static_assert(sizeof(TESObjectACTI) == 0x258); + static_assert(sizeof(TESObjectACTI) == 0x220); } diff --git a/CommonLibSF/include/RE/T/TESObjectANIO.h b/CommonLibSF/include/RE/T/TESObjectANIO.h index a894a771..44a516da 100644 --- a/CommonLibSF/include/RE/T/TESObjectANIO.h +++ b/CommonLibSF/include/RE/T/TESObjectANIO.h @@ -8,7 +8,7 @@ namespace RE { class TESObjectANIO : public TESForm, // 00 - public BGSModelMaterialSwap // 38 + public BGSModelMaterialSwap // 30 { public: SF_RTTI_VTABLE(TESObjectANIO); @@ -17,7 +17,7 @@ namespace RE ~TESObjectANIO() override; // 00 // members - BGSEditorID formEditorID; // 60 + BGSEditorID formEditorID; // 58 }; - static_assert(sizeof(TESObjectANIO) == 0x70); + static_assert(sizeof(TESObjectANIO) == 0x68); } diff --git a/CommonLibSF/include/RE/T/TESObjectARMO.h b/CommonLibSF/include/RE/T/TESObjectARMO.h index b837b0ce..84bbcbd9 100644 --- a/CommonLibSF/include/RE/T/TESObjectARMO.h +++ b/CommonLibSF/include/RE/T/TESObjectARMO.h @@ -86,18 +86,18 @@ namespace RE } // members - BGSEditorID formEditorID; // 2B0 - BSTOptional instanceData; // 2C0 - BSTArray modelArray; // 340 - BGSAttachParentArray attachParents; // 350 + BGSEditorID formEditorID; // 278 + BSTOptional instanceData; // 288 + BSTArray modelArray; // 308 + BGSAttachParentArray attachParents; // 318 + std::uint64_t unk338; // 338 + std::uint64_t unk340; // 340 + std::uint64_t unk348; // 348 + std::uint64_t unk350; // 350 + std::uint64_t unk358; // 358 + std::uint64_t unk360; // 360 + std::uint64_t unk368; // 368 std::uint64_t unk370; // 370 - std::uint64_t unk378; // 378 - std::uint64_t unk380; // 380 - std::uint64_t unk388; // 388 - std::uint64_t unk390; // 390 - std::uint64_t unk398; // 398 - std::uint64_t unk3A0; // 3A0 - std::uint64_t unk3A8; // 3A8 }; - static_assert(sizeof(TESObjectARMO) == 0x3B0); + static_assert(sizeof(TESObjectARMO) == 0x378); } diff --git a/CommonLibSF/include/RE/T/TESObjectBOOK.h b/CommonLibSF/include/RE/T/TESObjectBOOK.h index 66fca7b7..8aa5582d 100644 --- a/CommonLibSF/include/RE/T/TESObjectBOOK.h +++ b/CommonLibSF/include/RE/T/TESObjectBOOK.h @@ -52,27 +52,27 @@ namespace RE class TESObjectBOOK : public TESBoundObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESValueForm, // 150 - public TESWeightForm, // 160 - public TESDescription, // 170 - public BGSDestructibleObjectForm, // 188 - public BGSPickupPutdownSounds, // 198 - public BGSKeywordForm, // 200 - public BGSFeaturedItemMessage // 230 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESValueForm, // 118 + public TESWeightForm, // 128 + public TESDescription, // 138 + public BGSDestructibleObjectForm, // 150 + public BGSPickupPutdownSounds, // 160 + public BGSKeywordForm, // 1C8 + public BGSFeaturedItemMessage // 1F8 { public: SF_RTTI_VTABLE(TESObjectBOOK); SF_FORMTYPE(BOOK); // members - OBJ_BOOK data; // 240 - TESObjectSTAT* inventoryModel; // 260 - TESDescription itemCardDescription; // 268 - BGSScene* scene; // 280 - BGSLocalizedString unk288; // 288 - BGSLocalizedString unk290; // 290 + OBJ_BOOK data; // 208 + TESObjectSTAT* inventoryModel; // 228 + TESDescription itemCardDescription; // 230 + BGSScene* scene; // 248 + BGSLocalizedString unk250; // 250 + BGSLocalizedString unk258; // 258 }; - static_assert(sizeof(TESObjectBOOK) == 0x298); + static_assert(sizeof(TESObjectBOOK) == 0x260); } diff --git a/CommonLibSF/include/RE/T/TESObjectCELL.h b/CommonLibSF/include/RE/T/TESObjectCELL.h index 5904519f..aec93eac 100644 --- a/CommonLibSF/include/RE/T/TESObjectCELL.h +++ b/CommonLibSF/include/RE/T/TESObjectCELL.h @@ -5,6 +5,7 @@ #include "RE/B/BSTArray.h" #include "RE/B/BSTSmartPointer.h" #include "RE/E/ExtraDataList.h" +#include "RE/I/InteriorData.h" #include "RE/N/NiPoint3.h" #include "RE/N/NiSmartPointer.h" #include "RE/T/TESFullName.h" @@ -15,40 +16,6 @@ namespace RE class TESObjectREFR; class TESWorldSpace; - struct INTERIOR_DATA - { - public: - // members - std::uint64_t unk00; // 00 - std::uint32_t fogColorNear; // 08 - float fogPlaneNear; // 0C - float fogPlaneFar; // 10 - std::uint32_t unk14; // 14 - std::uint32_t unk18; // 18 - float gravity; // 1C - std::uint32_t unk20; // 20 - std::uint32_t fogPower; // 24 - std::uint32_t fogColorFar; // 28 - std::uint32_t unk2C; // 2C - std::uint32_t unk30; // 30 - std::uint32_t unk34; // 34 - float unk38; // 38 - std::uint32_t unk3C; // 3C - float unk40; // 40 - std::uint32_t unk44; // 44 - std::uint32_t unk48; // 48 - float unk50; // 50 - float unk54; // 54 - float unk58; // 58 - float unk5C; // 5C - std::uint32_t unk60; // 60 - std::uint32_t unk64; // 64 - std::int8_t unk68; // 68 - std::uint32_t unk6C; // 6C - std::uint64_t unk70; // 70 - }; - static_assert(sizeof(INTERIOR_DATA) == 0x78); - struct EXTERIOR_DATA { public: @@ -69,7 +36,7 @@ namespace RE class TESObjectCELL : public TESHandleForm, // 00 - public TESFullName // 20 + public TESFullName // 30 { public: SF_RTTI_VTABLE(TESObjectCELL); @@ -130,23 +97,24 @@ namespace RE void ForEachReferenceInRange(const NiPoint3A& a_origin, float a_radius, std::function&)> a_callback) const; // members - stl::enumeration cellFlags; // 048 - std::uint16_t cellGameFlags; // 04C - std::uint8_t unk4E; // 04E - stl::enumeration cellState; // 04F - std::uint64_t unk50; // 050 - BSTSmartPointer extraDataList; // 058 - CellData cellData; // 060 - std::uint32_t unk068; // 068 + stl::enumeration cellFlags; // 040 + std::uint16_t cellGameFlags; // 044 + std::uint8_t unk04E; // 046 + stl::enumeration cellState; // 047 + std::uint64_t unk050; // 048 + BSTSmartPointer extraDataList; // 050 + CellData cellData; // 058 + std::uint32_t unk060; // 060 + float unk064; // 064 + float unk068; // 068 float unk06C; // 06C - float unk070; // 070 - float unk074; // 074 - std::uint8_t unk078; // 078 - std::uint8_t pad079; // 079 - std::uint16_t pad07A; // 07A - std::uint32_t pad07C; // 07C - std::uint64_t unk080; // 080 - BSTArray> references; // 088 + std::uint8_t unk070; // 070 + std::uint8_t pad071; // 071 + std::uint16_t pad072; // 072 + std::uint32_t pad074; // 074 + std::uint64_t unk078; // 078 + BSTArray> references; // 080 + std::uint64_t unk090; // 090 std::uint64_t unk098; // 098 std::uint64_t unk0A0; // 0A0 std::uint64_t unk0A8; // 0A8 @@ -157,22 +125,21 @@ namespace RE std::uint64_t unk0D0; // 0D0 std::uint64_t unk0D8; // 0D8 std::uint64_t unk0E0; // 0E0 - std::uint64_t unk0E8; // 0E8 - std::uint8_t unk0F0; // 0F0 - std::uint8_t pad0F1; // 0F1 - std::uint16_t pad0F2; // 0F2 - std::uint32_t pad0F4; // 0F4 + std::uint8_t unk0E8; // 0E8 + std::uint8_t pad0E9; // 0E9 + std::uint16_t pad0EA; // 0EA + std::uint32_t pad0EC; // 0EC + std::uint64_t unk0F0; // 0F0 std::uint64_t unk0F8; // 0F8 std::uint64_t unk100; // 100 std::uint64_t unk108; // 108 std::uint64_t unk110; // 110 - std::uint64_t unk118; // 118 - TESWorldSpace* cellWorldspace; // 120 - mutable BSReadWriteLock lock; // 128 + TESWorldSpace* cellWorldspace; // 118 + mutable BSReadWriteLock lock; // 120 + std::uint64_t unk128; // 128 std::uint64_t unk130; // 130 - std::uint64_t unk138; // 138 - std::uint32_t unk140; // 140 - std::uint64_t unk148; // 148 + std::uint32_t unk138; // 138 + std::uint64_t unk140; // 140 }; - static_assert(sizeof(TESObjectCELL) == 0x150); + static_assert(sizeof(TESObjectCELL) == 0x148); } diff --git a/CommonLibSF/include/RE/T/TESObjectCONT.h b/CommonLibSF/include/RE/T/TESObjectCONT.h index 0fc3c068..9f398860 100644 --- a/CommonLibSF/include/RE/T/TESObjectCONT.h +++ b/CommonLibSF/include/RE/T/TESObjectCONT.h @@ -34,16 +34,16 @@ namespace RE class TESObjectCONT : public TESBoundAnimObject, // 000 - public TESContainer, // 118 - public TESFullName, // 130 - public BGSModelMaterialSwap, // 140 - public TESMagicTargetForm, // 168 - public BGSDestructibleObjectForm, // 170 - public BGSOpenCloseForm, // 180 - public BGSKeywordForm, // 188 - public BGSForcedLocRefType, // 1B8 - public BGSPropertySheet, // 1D0 - public BGSNativeTerminalForm // 1E0 + public TESContainer, // 0E0 + public TESFullName, // 0F8 + public BGSModelMaterialSwap, // 108 + public TESMagicTargetForm, // 130 + public BGSDestructibleObjectForm, // 138 + public BGSOpenCloseForm, // 148 + public BGSKeywordForm, // 150 + public BGSForcedLocRefType, // 180 + public BGSPropertySheet, // 198 + public BGSNativeTerminalForm // 1A8 { public: SF_RTTI_VTABLE(TESObjectCONT); @@ -52,13 +52,13 @@ namespace RE ~TESObjectCONT() override; // 00 // members - CONT_DATA data; // 1F0 - BGSAudio::WwiseSoundHook openSound; // 1F8 - BGSAudio::WwiseSoundHook closeSound; // 228 - BGSAudio::WwiseSoundHook takeAllSound; // 258 - BGSListForm* containsOnlyList; // 288 - BGSAttachParentArray attachParents; // 290 - std::uint8_t unk2B0; // 2B0 + CONT_DATA data; // 1B8 + BGSAudio::WwiseSoundHook openSound; // 1C0 + BGSAudio::WwiseSoundHook closeSound; // 1F0 + BGSAudio::WwiseSoundHook takeAllSound; // 220 + BGSListForm* containsOnlyList; // 250 + BGSAttachParentArray attachParents; // 258 + std::uint8_t unk278; // 278 }; - static_assert(sizeof(TESObjectCONT) == 0x2B8); + static_assert(sizeof(TESObjectCONT) == 0x280); } diff --git a/CommonLibSF/include/RE/T/TESObjectDOOR.h b/CommonLibSF/include/RE/T/TESObjectDOOR.h index de872a37..f89d0785 100644 --- a/CommonLibSF/include/RE/T/TESObjectDOOR.h +++ b/CommonLibSF/include/RE/T/TESObjectDOOR.h @@ -18,16 +18,16 @@ namespace RE { class TESObjectDOOR : public TESBoundAnimObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESMagicTargetForm, // 150 - public BGSDestructibleObjectForm, // 158 - public BGSOpenCloseForm, // 168 - public BGSKeywordForm, // 170 - public BGSNativeTerminalForm, // 1A0 - public BGSForcedLocRefType, // 1B0 - public BGSPropertySheet, // 1C8 - public BGSNavmeshableObject // 1D8 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESMagicTargetForm, // 118 + public BGSDestructibleObjectForm, // 120 + public BGSOpenCloseForm, // 130 + public BGSKeywordForm, // 138 + public BGSNativeTerminalForm, // 168 + public BGSForcedLocRefType, // 178 + public BGSPropertySheet, // 190 + public BGSNavmeshableObject // 1A0 { public: SF_RTTI_VTABLE(TESObjectDOOR); @@ -47,15 +47,15 @@ namespace RE ~TESObjectDOOR() override; // 00 // members - BGSLocalizedString altOpenText; // 1E0 - BGSLocalizedString altCloseText; // 1E8 - BGSAudio::WwiseSoundHook openSound; // 1F0 - BGSAudio::WwiseSoundHook closeSound; // 220 - BGSAudio::WwiseSoundHook lockSound; // 250 - std::uint32_t unk280; // 280 - std::uint32_t unk284; // 284 - stl::enumeration flags; // 288 - BSTArray randomTeleports; // 290 + BGSLocalizedString altOpenText; // 1A8 + BGSLocalizedString altCloseText; // 1B0 + BGSAudio::WwiseSoundHook openSound; // 1B8 + BGSAudio::WwiseSoundHook closeSound; // 1E8 + BGSAudio::WwiseSoundHook lockSound; // 218 + std::uint32_t unk248; // 248 + std::uint32_t unk24C; // 24C + stl::enumeration flags; // 250 + BSTArray randomTeleports; // 258 }; - static_assert(sizeof(TESObjectDOOR) == 0x2A0); + static_assert(sizeof(TESObjectDOOR) == 0x268); } diff --git a/CommonLibSF/include/RE/T/TESObjectMISC.h b/CommonLibSF/include/RE/T/TESObjectMISC.h index 1d4b98e5..948102c1 100644 --- a/CommonLibSF/include/RE/T/TESObjectMISC.h +++ b/CommonLibSF/include/RE/T/TESObjectMISC.h @@ -16,16 +16,16 @@ namespace RE { class TESObjectMISC : public TESBoundObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESValueForm, // 150 - public TESWeightForm, // 160 - public BGSDestructibleObjectForm, // 170 - public BGSCraftingUseSound, // 180 - public BGSPickupPutdownSounds, // 1B8 - public BGSKeywordForm, // 220 - public BGSFeaturedItemMessage, // 250 - public BGSCraftingResourceOwner // 260 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESValueForm, // 118 + public TESWeightForm, // 128 + public BGSDestructibleObjectForm, // 138 + public BGSCraftingUseSound, // 148 + public BGSPickupPutdownSounds, // 180 + public BGSKeywordForm, // 1E8 + public BGSFeaturedItemMessage, // 218 + public BGSCraftingResourceOwner // 228 { public: SF_RTTI_VTABLE(TESObjectMISC); @@ -37,8 +37,8 @@ namespace RE virtual void Unk_82(); // 82 - { return; } // members - BGSLocalizedString shortName; // 280 - std::uint32_t flags; // 288 + BGSLocalizedString shortName; // 248 + std::uint32_t flags; // 250 }; - static_assert(sizeof(TESObjectMISC) == 0x290); + static_assert(sizeof(TESObjectMISC) == 0x258); } diff --git a/CommonLibSF/include/RE/T/TESObjectREFR.h b/CommonLibSF/include/RE/T/TESObjectREFR.h index a3dc8ad7..50623fb4 100644 --- a/CommonLibSF/include/RE/T/TESObjectREFR.h +++ b/CommonLibSF/include/RE/T/TESObjectREFR.h @@ -19,8 +19,11 @@ namespace RE { enum class LOCK_LEVEL; + enum class IO_TASK_PRIORITY; + class TESContainer; class Actor; + class ActorCause; class BGSEquipSlot; class BGSLocation; class BGSObjectInstance; @@ -128,16 +131,16 @@ namespace RE static_assert(sizeof(LOADED_REF_DATA) == 0x28); class TESObjectREFR : - public TESHandleForm, // 00 - public BSTEventSink, // 38 - public IMovementProcessMessageInterface, // 40 - public IPostAnimationChannelUpdateFunctor, // 48 - public BSTEventSink, // 50 - public BSTEventSink, // 58 - public IAnimationGraphManagerHolder, // 60 - public IKeywordFormBase, // 68 - public ActorValueOwner, // 70 - public BSTEventSource // 78 + public TESHandleForm, // 00 + public BSTEventSink, // 30 + public IMovementProcessMessageInterface, // 38 + public IPostAnimationChannelUpdateFunctor, // 40 + public BSTEventSink, // 48 + public BSTEventSink, // 50 + public IAnimationGraphManagerHolder, // 58 + public IKeywordFormBase, // 60 + public ActorValueOwner, // 68 + public BSTEventSourceLazyInit // 70 { public: SF_RTTI_VTABLE(TESObjectREFR); @@ -157,7 +160,7 @@ namespace RE virtual void Unk_6A(); // 06A virtual void UpdateSoundCallBack(bool a_endSceneAction); // 06B virtual bool SetDialoguewithPlayer(bool a_flag, bool a_forceGreet, TESTopicInfo* a_topicInfo); // 06C - virtual void Unk_6D(); // 06D + virtual bool IsInvulnerable() const; // 06D virtual void Unk_6E(); // 06E virtual void Unk_6F(); // 06F virtual void Unk_70(); // 070 @@ -180,8 +183,8 @@ namespace RE virtual void Unk_81(); // 081 virtual void Unk_82(); // 082 virtual void Unk_83(); // 083 - virtual void Unk_84(); // 084 - virtual void Unk_85(); // 085 + virtual void SetActorCause(ActorCause* a_actorCause); // 084 + virtual ActorCause* GetActorCause(); // 085 virtual void SetScale(float a_scale); // 086 virtual void Unk_87(); // 087 virtual void Unk_88(); // 088 @@ -217,8 +220,8 @@ namespace RE virtual void Unk_A6(); // 0A6 virtual void Unk_A7(); // 0A7 virtual void Unk_A8(); // 0A8 - virtual void Unk_A9(); // 0A9 - virtual void Unk_AA(); // 0AA + virtual bool ShouldBackgroundClone() const; // 0A9 + virtual bool IsReadyForAttach([[maybe_unused]] const IO_TASK_PRIORITY& a_priority) const; // 0AA virtual void Unk_AB(); // 0AB - { return Get3D(a_objectOut) };? virtual void Unk_AC(); // 0AC - Get3D(NiPointer&)? virtual void Unk_AD(); // 0AD @@ -302,7 +305,7 @@ namespace RE virtual void Unk_FB(); // 0FB virtual void Unk_FC(); // 0FC virtual void Unk_FD(); // 0FD - virtual void ResetInventory(bool a_leveledOnly, bool a_skipInitDefaultWorn); // 0FE + virtual void ResetInventory(bool a_leveledOnly, bool a_skipInitDefaultWorn, bool a_arg3); // 0FE virtual void Unk_FF(); // 0FF virtual void Unk_100(); // 100 virtual void Unk_101(); // 101 @@ -324,7 +327,7 @@ namespace RE virtual void Unk_111(); // 111 virtual void Unk_112(); // 112 virtual void Unk_113(); // 113 - virtual void InitDefaultWornImpl(bool a_weapon, bool a_allowChanges); // 114 + virtual void InitDefaultWornImpl(bool a_weapon); // 114 virtual void Unk_115(); // 115 virtual void Unk_116(); // 116 virtual void Unk_117(); // 117 @@ -386,18 +389,17 @@ namespace RE void Unlock(); // members - OBJ_REFR data; // 0A0 - BSGuarded inventoryList; // 0D0 - TESObjectCELL* parentCell; // 0E0 - BSGuarded loadedData; // 0E8 - BSTSmartPointer extraDataList; // 0F8 - BGSLocalizedString unk100; // 100 - empty? - std::uint16_t scale; // 108 - std::uint8_t unk10A; // 10A - std::uint8_t flags; // 10B + OBJ_REFR data; // 80 + BSGuarded inventoryList; // B0 + TESObjectCELL* parentCell; // C0 + BSGuarded loadedData; // C8 + BSTSmartPointer extraDataList; // D8 + std::uint16_t scale; // E0 + std::uint8_t unkE2; // E2 + std::uint8_t flags; // E3 private: void AddLockChange(); }; - static_assert(sizeof(TESObjectREFR) == 0x110); + static_assert(sizeof(TESObjectREFR) == 0xF0); } diff --git a/CommonLibSF/include/RE/T/TESObjectSTAT.h b/CommonLibSF/include/RE/T/TESObjectSTAT.h index 01406aa2..0f66e337 100644 --- a/CommonLibSF/include/RE/T/TESObjectSTAT.h +++ b/CommonLibSF/include/RE/T/TESObjectSTAT.h @@ -20,10 +20,10 @@ namespace RE class TESObjectSTAT : public TESBoundObject, // 000 - public BGSModelMaterialSwap, // 118 - public BGSPropertySheet, // 140 - public BGSForcedLocRefType, // 150 - public BGSNavmeshableObject // 168 + public BGSModelMaterialSwap, // 0E0 + public BGSPropertySheet, // 108 + public BGSForcedLocRefType, // 118 + public BGSNavmeshableObject // 130 { public: SF_RTTI_VTABLE(TESObjectSTAT); @@ -32,8 +32,8 @@ namespace RE ~TESObjectSTAT() override; // 00 // members - TESObjectSTATData data; // 170 - BGSAudio::WwiseSoundHook ambientSound; // 178 + TESObjectSTATData data; // 138 + BGSAudio::WwiseSoundHook ambientSound; // 140 }; - static_assert(sizeof(TESObjectSTAT) == 0x1A8); + static_assert(sizeof(TESObjectSTAT) == 0x170); } diff --git a/CommonLibSF/include/RE/T/TESObjectWEAP.h b/CommonLibSF/include/RE/T/TESObjectWEAP.h index c5909f92..647168dd 100644 --- a/CommonLibSF/include/RE/T/TESObjectWEAP.h +++ b/CommonLibSF/include/RE/T/TESObjectWEAP.h @@ -27,17 +27,17 @@ namespace RE class TESObjectWEAP : public TESBoundObject, // 000 - public TESFullName, // 118 - public BGSModelMaterialSwap, // 128 - public TESEnchantableForm, // 150 - public BGSDestructibleObjectForm, // 168 - public BGSEquipType, // 178 - public BGSPreloadable, // 188 - public BGSPickupPutdownSounds, // 190 - public BGSBlockBashData, // 1F8 - public BGSKeywordForm, // 210 - public TESDescription, // 240 - public BGSInstanceNamingRulesForm // 258 + public TESFullName, // 0E0 + public BGSModelMaterialSwap, // 0F0 + public TESEnchantableForm, // 118 + public BGSDestructibleObjectForm, // 130 + public BGSEquipType, // 140 + public BGSPreloadable, // 150 + public BGSPickupPutdownSounds, // 158 + public BGSBlockBashData, // 1C0 + public BGSKeywordForm, // 1D8 + public TESDescription, // 208 + public BGSInstanceNamingRulesForm // 220 { public: SF_RTTI_VTABLE(TESObjectWEAP); @@ -46,11 +46,11 @@ namespace RE ~TESObjectWEAP() override; // 00 // members - BGSEditorID formEditorID; // 268 - BSTSmartPointer weaponData; // 278 - BGSAttachParentArray attachParents; // 280 - BGSMod::Attachment::Mod* embeddedWeaponMod; // 2A0 - std::uint8_t unk2A8; // 2A8 + BGSEditorID formEditorID; // 230 + BSTSmartPointer weaponData; // 240 + BGSAttachParentArray attachParents; // 248 + BGSMod::Attachment::Mod* embeddedWeaponMod; // 268 + std::uint8_t unk270; // 270 }; - static_assert(sizeof(TESObjectWEAP) == 0x2B0); + static_assert(sizeof(TESObjectWEAP) == 0x278); } diff --git a/CommonLibSF/include/RE/T/TESRace.h b/CommonLibSF/include/RE/T/TESRace.h index d84be2fd..9e1e0344 100644 --- a/CommonLibSF/include/RE/T/TESRace.h +++ b/CommonLibSF/include/RE/T/TESRace.h @@ -101,15 +101,15 @@ namespace RE class TESRace : public TESForm, // 00 - public TESFullName, // 38 - public TESDescription, // 48 - public TESSpellList, // 60 - public BGSSkinForm, // 78 - public BGSBipedObjectForm, // 88 - public BGSKeywordForm, // 98 - public BGSAttackDataForm, // C8 - public BGSPropertySheet, // D8 - public BGSPreloadable // E8 + public TESFullName, // 30 + public TESDescription, // 40 + public TESSpellList, // 58 + public BGSSkinForm, // 70 + public BGSBipedObjectForm, // 80 + public BGSKeywordForm, // 90 + public BGSAttackDataForm, // C0 + public BGSPropertySheet, // D0 + public BGSPreloadable // E0 { public: SF_RTTI_VTABLE(TESRace); @@ -124,46 +124,46 @@ namespace RE ~TESRace() override; // 00 // members - BGSEditorID formEditorID; // 0F0 - BGSMaterialType* bloodImpactMaterial; // 100 - BGSAudio::WwiseSoundHook corpseOpenSound; // 108 - BGSAudio::WwiseSoundHook corpseCloseSound; // 138 - BSFixedString bipedObjectNames[64]; // 168 - ActorValueInfo* bipedObjectConditions[64]; // 368 + BGSEditorID formEditorID; // 0E8 + BGSMaterialType* bloodImpactMaterial; // 0F8 + BGSAudio::WwiseSoundHook corpseOpenSound; // 100 + BGSAudio::WwiseSoundHook corpseCloseSound; // 130 + BSFixedString bipedObjectNames[64]; // 160 + ActorValueInfo* bipedObjectConditions[64]; // 360 + std::uint64_t unk560; // 560 std::uint64_t unk568; // 568 std::uint64_t unk570; // 570 std::uint64_t unk578; // 578 std::uint64_t unk580; // 580 std::uint64_t unk588; // 588 std::uint64_t unk590; // 590 - std::uint64_t unk598; // 598 - BSTArray equipSlotArray; // 5A0 - std::uint64_t unk5B0; // 5B0 - TESRace* morphRace; // 5B8 - TESRace* armorParentRace; // 5C0 - BSTArray unk5C8[SEXES::kTotal]; // 5C8 - TESQuest* dialogueQuest; // 5E8 - TESModel unk5F0[4]; // 5F0 - TESModel faceBones[SEXES::kTotal]; // 670 - RACE_DATA data; // 6B0 - std::uint64_t unk7B0; // 7B0 - BGSTextureModel unk7B8[SEXES::kTotal]; // 7B8 - BGSAnimationGraphComponent unk7F8[4]; // 7F8 - BGSVoiceType* defaultVoiceType[SEXES::kTotal]; // 8F8 - BGSBodyPartInfo bodyPartInfo; // 908 - BGSAttachParentArray attachParents; // 930 - BSTArray unk950; // 950 - BGSMovementType* baseMoveTypes[4]; // 960 + BSTArray equipSlotArray; // 598 + std::uint64_t unk5A8; // 5A8 + TESRace* morphRace; // 5B0 + TESRace* armorParentRace; // 5B8 + BSTArray unk5C0[SEXES::kTotal]; // 5C0 + TESQuest* dialogueQuest; // 5E0 + TESModel unk5E8[4]; // 5E8 + TESModel faceBones[SEXES::kTotal]; // 668 + RACE_DATA data; // 6A8 + std::uint64_t unk7A8; // 7A8 + BGSTextureModel unk7B0[SEXES::kTotal]; // 7B0 + BGSAnimationGraphComponent unk7F0[4]; // 7F0 + BGSVoiceType* defaultVoiceType[SEXES::kTotal]; // 8F0 + BGSBodyPartInfo bodyPartInfo; // 900 + BGSAttachParentArray attachParents; // 928 + BSTArray unk948; // 948 + BGSMovementType* baseMoveTypes[4]; // 958 + std::uint64_t unk978; // 978 std::uint64_t unk980; // 980 - std::uint64_t unk988; // 988 - void* chargenData[SEXES::kTotal]; // 990 - std::uint64_t unk9A0; // 9A0 - BSFixedString handMaterials[SEXES::kTotal]; // 9A8 - BSFixedString skinMaterials[SEXES::kTotal]; // 9B8 - BSFixedString unk9C8[SEXES::kTotal]; // 9C8 - BSTArray headparts[SEXES::kTotal]; // 9D8 - Unk9F8 unk9F8[SEXES::kTotal]; // 9F8 - BGSLocalizedString unkA18; // A18 + void* chargenData[SEXES::kTotal]; // 988 + std::uint64_t unk998; // 998 + BSFixedString handMaterials[SEXES::kTotal]; // 9A0 + BSFixedString skinMaterials[SEXES::kTotal]; // 9B0 + BSFixedString unk9C0[SEXES::kTotal]; // 9C0 + BSTArray headparts[SEXES::kTotal]; // 9D0 + Unk9F8 unk9F0[SEXES::kTotal]; // 9F0 + BGSLocalizedString unkA10; // A10 }; - static_assert(sizeof(TESRace) == 0xA20); + static_assert(sizeof(TESRace) == 0xA18); } diff --git a/CommonLibSF/include/RE/T/TESTopicInfo.h b/CommonLibSF/include/RE/T/TESTopicInfo.h index b39887b2..84e032b8 100644 --- a/CommonLibSF/include/RE/T/TESTopicInfo.h +++ b/CommonLibSF/include/RE/T/TESTopicInfo.h @@ -1,30 +1,29 @@ #pragma once +#include "RE/T/TESCondition.h" #include "RE/T/TESForm.h" namespace RE { class TESResponse; - // 78 class TESTopicInfo : - public TESForm + public TESForm // 00 { public: SF_RTTI_VTABLE(TESTopicInfo); SF_FORMTYPE(INFO); - TESTopicInfo* unk38; // 38 + ~TESTopicInfo() override; // 00 + + TESTopicInfo* unk30; // 30 + std::uint64_t unk38; // 38 std::uint64_t unk40; // 40 - std::uint64_t unk48; // 48 - TESTopicInfo* unk50; // 50 - Left/right (in the info list) - std::uint8_t unk58; // 58 - std::uint8_t pad59[3]; // 59 - std::uint32_t unk5C; // 5C - std::uint64_t unk60; // 60 - std::uint32_t unk68; // 68 - BSPointerHandleRef? - std::uint32_t unk6C; // 6C - Flags of some kind - TESResponse* responses; // 70 + TESTopicInfo* unk48; // 48 - Left/right (in the info list) + TESCondition condition; // 50 + std::uint32_t unk60; // 60 - BSPointerHandleRef? + std::uint32_t flags; // 64 + TESResponse* responses; // 68 }; - static_assert(sizeof(TESTopicInfo) == 0x78); + static_assert(sizeof(TESTopicInfo) == 0x70); } diff --git a/CommonLibSF/include/RE/T/TESWorldSpace.h b/CommonLibSF/include/RE/T/TESWorldSpace.h index fabe2bd5..bf8203d5 100644 --- a/CommonLibSF/include/RE/T/TESWorldSpace.h +++ b/CommonLibSF/include/RE/T/TESWorldSpace.h @@ -2,6 +2,7 @@ #include "RE/B/BGSEditorID.h" #include "RE/B/BSTEvent.h" +#include "RE/B/BSTSmartPointer.h" #include "RE/N/NiPoint3.h" #include "RE/N/NiSmartPointer.h" #include "RE/T/TESForm.h" @@ -10,16 +11,22 @@ namespace RE { + class BGSAmbienceSet; + class BGSBiome; + class BGSLightingTemplate; class BGSLocation; + class BGSMusicType; + class BGSTerrainManager; class TESObjectCELL; + class TESWaterForm; struct WorldSpaceReleasedEvent; class TESWorldSpace : public TESForm, // 00 - public TESFullName, // 38 - public TESTexture, // 48 - public BSTEventSource // 58 + public TESFullName, // 30 + public TESTexture, // 38 + public BSTEventSource // 50 { public: SF_RTTI_VTABLE(TESWorldSpace); @@ -30,102 +37,102 @@ namespace RE [[nodiscard]] BGSLocation* GetLocationFromCoordinates(const NiPoint3A& a_coordinates); // members - BGSEditorID formEditorID; // 080 - std::uint64_t unk090; // 090 - std::uint64_t unk098; // 098 - std::uint64_t unk0A0; // 0A0 - std::uint64_t unk0A8; // 0A8 - std::uint64_t unk0B0; // 0B0 - std::uint64_t unk0B8; // 0B8 - std::uint64_t unk0C0; // 0C0 - BSTArray unk0C8; // 0C8 - NiPointer unk0D8; // 0D8 - persistent cell? - std::uint64_t unk0E0; // 0E0 - std::uint64_t unk0E8; // 0E8 - std::uint64_t unk0F0; // 0F0 - std::uint64_t unk0F8; // 0F8 - std::uint64_t unk100; // 100 - std::uint64_t unk108; // 108 - std::uint64_t unk110; // 110 - std::uint64_t unk118; // 118 - std::uint64_t unk120; // 120 - std::uint64_t unk128; // 128 - std::uint64_t unk130; // 130 - std::uint64_t unk138; // 138 - std::uint64_t unk140; // 140 - std::uint64_t unk148; // 148 - std::uint64_t unk150; // 150 - std::uint64_t unk158; // 158 - std::uint64_t unk160; // 160 - std::uint64_t unk168; // 168 - std::uint64_t unk170; // 170 - std::uint64_t unk178; // 178 - std::uint64_t unk180; // 180 - std::uint64_t unk188; // 188 - std::uint64_t unk190; // 190 - std::uint64_t unk198; // 198 - std::uint64_t unk1A0; // 1A0 - std::uint64_t unk1A8; // 1A8 - std::uint64_t unk1B0; // 1B0 - std::uint64_t unk1B8; // 1B8 - std::uint64_t unk1C0; // 1C0 - std::uint64_t unk1C8; // 1C8 - std::uint64_t unk1D0; // 1D0 - NiPointer unk1D8; // 1D8 - persistent cell? - BSTArray> unk1E0; // 1E0 - std::uint64_t unk1F0; // 1F0 - std::uint64_t unk1F8; // 1F8 - std::uint64_t unk200; // 200 - std::uint64_t unk208; // 208 - std::uint64_t unk210; // 210 - BSFixedString unk218; // 218 - std::uint64_t unk220; // 220 - std::uint64_t unk228; // 228 - std::uint64_t unk230; // 230 - std::uint64_t unk238; // 238 - std::uint64_t unk240; // 240 - std::uint64_t unk248; // 248 - std::uint64_t unk250; // 250 - std::uint64_t unk258; // 258 - std::uint64_t unk260; // 260 - std::uint64_t unk268; // 268 - std::uint64_t unk270; // 270 - std::uint64_t unk278; // 278 - std::uint64_t unk280; // 280 - std::uint64_t unk288; // 288 - std::uint64_t unk290; // 290 - std::uint64_t unk298; // 298 - float defaultLandHeight; // 2A0 - float defaultWaterHeight; // 2A4 - float unk2A8; // 2A8 - std::uint32_t unk2AC; // 2AC - std::uint64_t unk2B0; // 2B0 - std::uint64_t unk2B8; // 2B8 - TESTexture unk2C0; // 2C0 - TESTexture unk2D0; // 2D0 - std::uint64_t unk2E0; // 2E0 - std::uint64_t unk2E8; // 2E8 - std::uint64_t unk2F0; // 2F0 - std::uint64_t unk2F8; // 2F8 - std::uint64_t unk300; // 300 - std::uint64_t unk308; // 308 - std::uint64_t unk310; // 310 - std::uint64_t unk318; // 318 - std::uint64_t unk320; // 320 - std::uint64_t unk328; // 328 - std::uint64_t unk330; // 330 - std::uint64_t unk338; // 338 - std::uint64_t unk340; // 340 - std::uint64_t unk348; // 348 - std::uint64_t unk350; // 350 - std::uint64_t unk358; // 358 - std::uint64_t unk360; // 360 - std::uint64_t unk368; // 368 - std::uint64_t unk370; // 370 - std::uint64_t unk378; // 378 - std::uint64_t unk380; // 380 - TESWorldSpace* unk388; // 388 - std::uint64_t unk390; // 390 + BGSEditorID formEditorID; // 078 + std::uint64_t unk088; // 088 + std::uint64_t unk090; // 090 + std::uint64_t unk098; // 098 + std::uint64_t unk0A0; // 0A0 + std::uint64_t unk0A8; // 0A8 + std::uint64_t unk0B0; // 0B0 + std::uint64_t unk0B8; // 0B8 + BSTArray unk0C0; // 0C0 + NiPointer unk0D0; // 0D0 - persistent cell? + BSTSmartPointer terrainManager; // 0D8 + std::uint64_t unk0E0; // 0E0 + std::uint64_t unk0E8; // 0E8 + std::uint64_t unk0F0; // 0F0 + std::uint64_t unk0F8; // 0F8 + std::uint64_t unk100; // 100 + std::uint64_t unk108; // 108 + std::uint64_t unk110; // 110 + std::uint64_t unk118; // 118 + std::uint64_t unk120; // 120 + std::uint64_t unk128; // 128 + std::uint64_t unk130; // 130 + std::uint64_t unk138; // 138 + std::uint64_t unk140; // 140 + std::uint64_t unk148; // 148 + std::uint64_t unk150; // 150 + std::uint64_t unk158; // 158 + std::uint64_t unk160; // 160 + std::uint64_t unk168; // 168 + std::uint64_t unk170; // 170 + std::uint64_t unk178; // 178 + std::uint64_t unk180; // 180 + std::uint64_t unk188; // 188 + std::uint64_t unk190; // 190 + std::uint64_t unk198; // 198 + std::uint64_t unk1A0; // 1A0 + std::uint64_t unk1A8; // 1A8 + std::uint64_t unk1B0; // 1B0 + std::uint64_t unk1B8; // 1B8 + std::uint64_t unk1C0; // 1C0 + std::uint64_t unk1C8; // 1C8 + NiPointer unk1D0; // 1D0 - persistent cell? + BSTArray> unk1D8; // 1D8 + BSTSmartPointer parentWorld; // 1E8 + BGSLightingTemplate* lightingTemplate; // 1F0 + TESWaterForm* worldWater; // 1F8 + TESWaterForm* lodWater; // 200 + std::uint64_t unk208; // 208 + BSFixedString unk210; // 210 + std::uint64_t unk218; // 218 + std::uint64_t unk220; // 220 + std::uint64_t unk228; // 228 + std::uint64_t unk230; // 230 + std::uint64_t unk238; // 238 + BGSMusicType* musicType; // 240 + BGSAmbienceSet* ambienceSet; // 248 + std::uint64_t unk250; // 250 + std::uint64_t unk258; // 258 + std::uint64_t unk260; // 260 + std::uint64_t unk268; // 268 + std::uint64_t unk270; // 270 + std::uint64_t unk278; // 278 + std::uint64_t unk280; // 280 + std::uint64_t unk288; // 288 + std::uint64_t unk290; // 290 + float defaultLandHeight; // 298 + float defaultWaterHeight; // 29C + float unk2A0; // 2A0 + std::uint32_t unk2A4; // 2A4 + BSTSmartPointer location; // 2A8 + BGSBiome* biome; // 2B0 + TESTexture unk2B8; // 2B8 + TESTexture unk2C8; // 2C8 + std::uint64_t unk2D8; // 2D8 + std::uint64_t unk2E0; // 2E0 + std::uint64_t unk2E8; // 2E8 + std::uint64_t unk2F0; // 2F0 + std::uint64_t unk2F8; // 2F8 + std::uint64_t unk300; // 300 + std::uint64_t unk308; // 308 + std::uint64_t unk310; // 310 + std::uint64_t unk318; // 318 + std::uint64_t unk320; // 320 + std::uint64_t unk328; // 328 + std::uint64_t unk330; // 330 + std::uint64_t unk338; // 338 + std::uint64_t unk340; // 340 + std::uint64_t unk348; // 348 + std::uint64_t unk350; // 350 + std::uint64_t unk358; // 358 + std::uint64_t unk360; // 360 + std::uint64_t unk368; // 368 + std::uint64_t unk370; // 370 + std::uint64_t unk378; // 378 + TESWorldSpace* unk380; // 380 + std::uint64_t unk388; // 388 }; - static_assert(sizeof(TESWorldSpace) == 0x398); + static_assert(sizeof(TESWorldSpace) == 0x390); } diff --git a/CommonLibSF/src/RE/T/TESFormRefCount.cpp b/CommonLibSF/src/RE/T/TESFormRefCount.cpp index 8eac967f..ec302e6a 100644 --- a/CommonLibSF/src/RE/T/TESFormRefCount.cpp +++ b/CommonLibSF/src/RE/T/TESFormRefCount.cpp @@ -2,13 +2,19 @@ namespace RE { + std::uint64_t TESFormRefCount::IncExternalRefCount() const + { + stl::atomic_ref myRefCount{ refCount }; + return (myRefCount += 0x400000) + 0x400000; + } + std::uint64_t TESFormRefCount::IncRefCount() const { stl::atomic_ref myRefCount{ refCount }; return ++myRefCount; } - std::uint64_t TESFormRefCount::QRefCount() const + std::uint64_t TESFormRefCount::QRefCount() const { return refCount & kRefCountMask; }