From 8e554d03c3f0b3ffaee761600f92fc3e4ecaf811 Mon Sep 17 00:00:00 2001 From: powerof3 <32599957+powerof3@users.noreply.github.com> Date: Fri, 29 Sep 2023 00:15:25 +0530 Subject: [PATCH 01/21] chore: declare previously commented instances of `NiPointer` (#119) --- CommonLibSF/include/RE/B/BGSAttackDataForm.h | 7 ++++- CommonLibSF/include/RE/T/TESCamera.h | 28 +++++++++++--------- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/CommonLibSF/include/RE/B/BGSAttackDataForm.h b/CommonLibSF/include/RE/B/BGSAttackDataForm.h index eaa01c33..dfdb3db5 100644 --- a/CommonLibSF/include/RE/B/BGSAttackDataForm.h +++ b/CommonLibSF/include/RE/B/BGSAttackDataForm.h @@ -1,16 +1,21 @@ #pragma once #include "RE/B/BaseFormComponent.h" +#include "RE/N/NiSmartPointer.h" namespace RE { + class BGSAttackDataMap; + class BGSAttackDataForm : public BaseFormComponent { public: SF_RTTI_VTABLE(BGSAttackDataForm); + virtual ~BGSAttackDataForm(); // 00 + // members - void* /*NiPointer*/ attackDataMap; // 08 + NiPointer attackDataMap; // 08 }; static_assert(sizeof(BGSAttackDataForm) == 0x10); } // namespace RE diff --git a/CommonLibSF/include/RE/T/TESCamera.h b/CommonLibSF/include/RE/T/TESCamera.h index 2ab1579c..b6d01aef 100644 --- a/CommonLibSF/include/RE/T/TESCamera.h +++ b/CommonLibSF/include/RE/T/TESCamera.h @@ -1,5 +1,7 @@ #pragma once +#include "RE/N/NiSmartPointer.h" + namespace RE { class NiNode; @@ -18,19 +20,19 @@ namespace RE virtual void Unk_04(); // 04 // members - void* cameraRoot; // 08 - NiPointer - void* currentState; // 10 - BSTSmartPointer - std::uint64_t unk18; // 18 - bool enabled; // 20 - float unk24; // 24 - float unk28; // 28 - float unk2C; // 2C - float unk30; // 30 - float unk34; // 34 - float unk38; // 38 - float unk3C; // 3C - float unk40; // 40 - std::uint32_t pad44; // 44 + NiPointer cameraRoot; // 08 + void* currentState; // 10 - BSTSmartPointer + std::uint64_t unk18; // 18 + bool enabled; // 20 + float unk24; // 24 + float unk28; // 28 + float unk2C; // 2C + float unk30; // 30 + float unk34; // 34 + float unk38; // 38 + float unk3C; // 3C + float unk40; // 40 + std::uint32_t pad44; // 44 }; static_assert(sizeof(TESCamera) == 0x48); } // namespace RE From 1141df72191aecce25c1b09698101288a8f2d2df Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 28 Sep 2023 18:45:55 +0000 Subject: [PATCH 02/21] ci: maintenance `2023-09-28.6` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index 6b5dc0ac..afa9baf3 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-28.5", + "version-date": "2023-09-28.6", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index bea609d5..3973a5f5 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-28.5&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-28.6&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 4847f8998b081e8da27c8ea94126c378fc09ee5b Mon Sep 17 00:00:00 2001 From: powerof3 <32599957+powerof3@users.noreply.github.com> Date: Fri, 29 Sep 2023 06:29:16 +0530 Subject: [PATCH 03/21] chore: remove redundant `BSStringPool` template specialization (#120) - Also replaces `_InterlockedExchangeAdd` with `stl::atomic_ref` to be consistent with other atomic usage --- CommonLibSF/include/RE/B/BSStringPool.h | 43 ++++++------------------- 1 file changed, 10 insertions(+), 33 deletions(-) diff --git a/CommonLibSF/include/RE/B/BSStringPool.h b/CommonLibSF/include/RE/B/BSStringPool.h index f6450af4..4b90b554 100644 --- a/CommonLibSF/include/RE/B/BSStringPool.h +++ b/CommonLibSF/include/RE/B/BSStringPool.h @@ -20,24 +20,21 @@ namespace RE return func(a_entry); } - void acquire() + std::uint32_t acquire() { - _InterlockedExchangeAdd(reinterpret_cast(&_refCount), 1); + stl::atomic_ref refCount{ _refCount }; + return ++refCount; } template - [[nodiscard]] const T* data() const noexcept; - - template <> - [[nodiscard]] const char* data() const noexcept - { - return u8(); - } - - template <> - [[nodiscard]] const wchar_t* data() const noexcept + [[nodiscard]] const T* data() const noexcept { - return u16(); + const auto entry = leaf(); + if (entry) { + return reinterpret_cast(entry + 1); + } else { + return nullptr; + } } [[nodiscard]] const Entry* leaf() const noexcept @@ -58,26 +55,6 @@ namespace RE [[nodiscard]] bool external() const noexcept { return _flags & kExternal; } [[nodiscard]] std::uint32_t size() const noexcept { return length(); } - [[nodiscard]] const char* u8() const noexcept - { - const auto entry = leaf(); - if (entry) { - return reinterpret_cast(entry + 1); - } else { - return nullptr; - } - } - - [[nodiscard]] const wchar_t* u16() const noexcept - { - const auto entry = leaf(); - if (entry) { - return reinterpret_cast(entry + 1); - } else { - return nullptr; - } - } - // members Entry* _left; // 00 union From 624c8179b33d2a95fc704d476e9715cc887245bf Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 00:59:54 +0000 Subject: [PATCH 04/21] ci: maintenance `2023-09-29` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index afa9baf3..d52b6241 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-28.6", + "version-date": "2023-09-29", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index 3973a5f5..ee13bdf0 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-28.6&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 7e9cf04ad3923d16947a1fc138efe5fb077cbfa6 Mon Sep 17 00:00:00 2001 From: Qudix <17361645+Qudix@users.noreply.github.com> Date: Fri, 29 Sep 2023 11:42:10 -0500 Subject: [PATCH 05/21] chore: remove empty compilation units (#121) --- CommonLibSF/src/RE/A/Actor.cpp | 1 - CommonLibSF/src/RE/A/ActorValueInfo.cpp | 1 - CommonLibSF/src/RE/A/ActorValueOwner.cpp | 1 - CommonLibSF/src/RE/A/ActorValues.cpp | 4 ---- CommonLibSF/src/RE/B/BGSAttackDataForm.cpp | 1 - CommonLibSF/src/RE/B/BGSDestructibleObjectForm.cpp | 1 - CommonLibSF/src/RE/B/BGSForcedLocRefType.cpp | 1 - CommonLibSF/src/RE/B/BGSKeyword.cpp | 1 - CommonLibSF/src/RE/B/BGSKeywordForm.cpp | 4 ---- CommonLibSF/src/RE/B/BGSListForm.cpp | 4 ---- CommonLibSF/src/RE/B/BGSLocation.cpp | 1 - CommonLibSF/src/RE/B/BGSLocationRefType.cpp | 1 - CommonLibSF/src/RE/B/BGSMod.cpp | 1 - CommonLibSF/src/RE/B/BGSNativeTerminalForm.cpp | 1 - CommonLibSF/src/RE/B/BGSObjectPlacementDefaults.cpp | 1 - CommonLibSF/src/RE/B/BGSOverridePackCollection.cpp | 1 - CommonLibSF/src/RE/B/BGSPerk.cpp | 1 - CommonLibSF/src/RE/B/BGSPerkRankArray.cpp | 1 - CommonLibSF/src/RE/B/BGSPreviewTransform.cpp | 1 - CommonLibSF/src/RE/B/BGSPropertySheet.cpp | 1 - CommonLibSF/src/RE/B/BGSScene.cpp | 1 - CommonLibSF/src/RE/B/BGSSkinForm.cpp | 1 - CommonLibSF/src/RE/B/BGSSnapTemplateComponent.cpp | 1 - CommonLibSF/src/RE/B/BGSTerminal.cpp | 1 - CommonLibSF/src/RE/B/BSFixedString.cpp | 1 - CommonLibSF/src/RE/B/BSIntrusiveRefCounted.cpp | 1 - CommonLibSF/src/RE/B/BSReflection.cpp | 1 - CommonLibSF/src/RE/B/BSStringT.cpp | 4 ---- CommonLibSF/src/RE/B/BSTEvent.cpp | 4 ---- CommonLibSF/src/RE/B/BSTList.cpp | 1 - CommonLibSF/src/RE/B/BaseFormComponent.cpp | 1 - CommonLibSF/src/RE/C/CombatGroup.cpp | 4 ---- CommonLibSF/src/RE/C/ConsoleLog.cpp | 1 - CommonLibSF/src/RE/I/IAnimationGraphManagerHolder.cpp | 4 ---- CommonLibSF/src/RE/I/IFunction.cpp | 1 - CommonLibSF/src/RE/I/IKeywordFormBase.cpp | 1 - CommonLibSF/src/RE/I/IMovementInterface.cpp | 4 ---- CommonLibSF/src/RE/I/INIPrefSettingCollection.cpp | 1 - CommonLibSF/src/RE/I/INISettingCollection.cpp | 1 - CommonLibSF/src/RE/I/IPostAnimationChannelUpdateFunctor.cpp | 4 ---- CommonLibSF/src/RE/M/MemoryManager.cpp | 4 ---- CommonLibSF/src/RE/M/MenuOpenCloseEvent.cpp | 4 ---- CommonLibSF/src/RE/N/NativeFunction.cpp | 1 - CommonLibSF/src/RE/N/NativeFunctionBase.cpp | 1 - CommonLibSF/src/RE/R/RegSettingCollection.cpp | 1 - CommonLibSF/src/RE/S/Script.cpp | 1 - CommonLibSF/src/RE/S/SettingCollection.cpp | 1 - CommonLibSF/src/RE/S/SettingCollectionList.cpp | 1 - CommonLibSF/src/RE/S/SettingCollectionMap.cpp | 1 - CommonLibSF/src/RE/S/Settings.cpp | 1 - CommonLibSF/src/RE/Starfield.cpp | 1 - CommonLibSF/src/RE/T/TBO_InstanceData.cpp | 4 ---- CommonLibSF/src/RE/T/TESAIForm.cpp | 1 - CommonLibSF/src/RE/T/TESActorBase.cpp | 1 - CommonLibSF/src/RE/T/TESActorBaseData.cpp | 1 - CommonLibSF/src/RE/T/TESBoundAnimObject.cpp | 1 - CommonLibSF/src/RE/T/TESBoundObject.cpp | 1 - CommonLibSF/src/RE/T/TESCamera.cpp | 4 ---- CommonLibSF/src/RE/T/TESContainer.cpp | 1 - CommonLibSF/src/RE/T/TESFile.cpp | 1 - CommonLibSF/src/RE/T/TESForm.cpp | 1 - CommonLibSF/src/RE/T/TESFullName.cpp | 1 - CommonLibSF/src/RE/T/TESHandleForm.cpp | 4 ---- CommonLibSF/src/RE/T/TESNPC.cpp | 1 - CommonLibSF/src/RE/T/TESObject.cpp | 1 - CommonLibSF/src/RE/T/TESObjectARMO.cpp | 1 - CommonLibSF/src/RE/T/TESObjectCELL.cpp | 1 - CommonLibSF/src/RE/T/TESQuest.cpp | 4 ---- CommonLibSF/src/RE/T/TESRace.cpp | 1 - CommonLibSF/src/RE/T/TESRaceForm.cpp | 1 - CommonLibSF/src/RE/T/TESResponse.cpp | 4 ---- CommonLibSF/src/RE/T/TESSpellList.cpp | 1 - CommonLibSF/src/RE/T/TESTopicInfo.cpp | 1 - CommonLibSF/src/SFSE/Impl/PCH.cpp | 1 - 74 files changed, 122 deletions(-) delete mode 100644 CommonLibSF/src/RE/A/Actor.cpp delete mode 100644 CommonLibSF/src/RE/A/ActorValueInfo.cpp delete mode 100644 CommonLibSF/src/RE/A/ActorValueOwner.cpp delete mode 100644 CommonLibSF/src/RE/A/ActorValues.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSAttackDataForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSDestructibleObjectForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSForcedLocRefType.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSKeyword.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSKeywordForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSListForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSLocation.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSLocationRefType.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSMod.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSNativeTerminalForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSObjectPlacementDefaults.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSOverridePackCollection.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSPerk.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSPerkRankArray.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSPreviewTransform.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSPropertySheet.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSScene.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSSkinForm.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSSnapTemplateComponent.cpp delete mode 100644 CommonLibSF/src/RE/B/BGSTerminal.cpp delete mode 100644 CommonLibSF/src/RE/B/BSFixedString.cpp delete mode 100644 CommonLibSF/src/RE/B/BSIntrusiveRefCounted.cpp delete mode 100644 CommonLibSF/src/RE/B/BSReflection.cpp delete mode 100644 CommonLibSF/src/RE/B/BSStringT.cpp delete mode 100644 CommonLibSF/src/RE/B/BSTEvent.cpp delete mode 100644 CommonLibSF/src/RE/B/BSTList.cpp delete mode 100644 CommonLibSF/src/RE/B/BaseFormComponent.cpp delete mode 100644 CommonLibSF/src/RE/C/CombatGroup.cpp delete mode 100644 CommonLibSF/src/RE/C/ConsoleLog.cpp delete mode 100644 CommonLibSF/src/RE/I/IAnimationGraphManagerHolder.cpp delete mode 100644 CommonLibSF/src/RE/I/IFunction.cpp delete mode 100644 CommonLibSF/src/RE/I/IKeywordFormBase.cpp delete mode 100644 CommonLibSF/src/RE/I/IMovementInterface.cpp delete mode 100644 CommonLibSF/src/RE/I/INIPrefSettingCollection.cpp delete mode 100644 CommonLibSF/src/RE/I/INISettingCollection.cpp delete mode 100644 CommonLibSF/src/RE/I/IPostAnimationChannelUpdateFunctor.cpp delete mode 100644 CommonLibSF/src/RE/M/MemoryManager.cpp delete mode 100644 CommonLibSF/src/RE/M/MenuOpenCloseEvent.cpp delete mode 100644 CommonLibSF/src/RE/N/NativeFunction.cpp delete mode 100644 CommonLibSF/src/RE/N/NativeFunctionBase.cpp delete mode 100644 CommonLibSF/src/RE/R/RegSettingCollection.cpp delete mode 100644 CommonLibSF/src/RE/S/Script.cpp delete mode 100644 CommonLibSF/src/RE/S/SettingCollection.cpp delete mode 100644 CommonLibSF/src/RE/S/SettingCollectionList.cpp delete mode 100644 CommonLibSF/src/RE/S/SettingCollectionMap.cpp delete mode 100644 CommonLibSF/src/RE/S/Settings.cpp delete mode 100644 CommonLibSF/src/RE/Starfield.cpp delete mode 100644 CommonLibSF/src/RE/T/TBO_InstanceData.cpp delete mode 100644 CommonLibSF/src/RE/T/TESAIForm.cpp delete mode 100644 CommonLibSF/src/RE/T/TESActorBase.cpp delete mode 100644 CommonLibSF/src/RE/T/TESActorBaseData.cpp delete mode 100644 CommonLibSF/src/RE/T/TESBoundAnimObject.cpp delete mode 100644 CommonLibSF/src/RE/T/TESBoundObject.cpp delete mode 100644 CommonLibSF/src/RE/T/TESCamera.cpp delete mode 100644 CommonLibSF/src/RE/T/TESContainer.cpp delete mode 100644 CommonLibSF/src/RE/T/TESFile.cpp delete mode 100644 CommonLibSF/src/RE/T/TESForm.cpp delete mode 100644 CommonLibSF/src/RE/T/TESFullName.cpp delete mode 100644 CommonLibSF/src/RE/T/TESHandleForm.cpp delete mode 100644 CommonLibSF/src/RE/T/TESNPC.cpp delete mode 100644 CommonLibSF/src/RE/T/TESObject.cpp delete mode 100644 CommonLibSF/src/RE/T/TESObjectARMO.cpp delete mode 100644 CommonLibSF/src/RE/T/TESObjectCELL.cpp delete mode 100644 CommonLibSF/src/RE/T/TESQuest.cpp delete mode 100644 CommonLibSF/src/RE/T/TESRace.cpp delete mode 100644 CommonLibSF/src/RE/T/TESRaceForm.cpp delete mode 100644 CommonLibSF/src/RE/T/TESResponse.cpp delete mode 100644 CommonLibSF/src/RE/T/TESSpellList.cpp delete mode 100644 CommonLibSF/src/RE/T/TESTopicInfo.cpp delete mode 100644 CommonLibSF/src/SFSE/Impl/PCH.cpp diff --git a/CommonLibSF/src/RE/A/Actor.cpp b/CommonLibSF/src/RE/A/Actor.cpp deleted file mode 100644 index e160e4bb..00000000 --- a/CommonLibSF/src/RE/A/Actor.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/A/Actor.h" diff --git a/CommonLibSF/src/RE/A/ActorValueInfo.cpp b/CommonLibSF/src/RE/A/ActorValueInfo.cpp deleted file mode 100644 index af6eb276..00000000 --- a/CommonLibSF/src/RE/A/ActorValueInfo.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/A/ActorValueInfo.h" diff --git a/CommonLibSF/src/RE/A/ActorValueOwner.cpp b/CommonLibSF/src/RE/A/ActorValueOwner.cpp deleted file mode 100644 index 0ad41f29..00000000 --- a/CommonLibSF/src/RE/A/ActorValueOwner.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/A/ActorValueOwner.h" diff --git a/CommonLibSF/src/RE/A/ActorValues.cpp b/CommonLibSF/src/RE/A/ActorValues.cpp deleted file mode 100644 index e4570a80..00000000 --- a/CommonLibSF/src/RE/A/ActorValues.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/A/ActorValues.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/B/BGSAttackDataForm.cpp b/CommonLibSF/src/RE/B/BGSAttackDataForm.cpp deleted file mode 100644 index 293cf319..00000000 --- a/CommonLibSF/src/RE/B/BGSAttackDataForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSAttackDataForm.h" diff --git a/CommonLibSF/src/RE/B/BGSDestructibleObjectForm.cpp b/CommonLibSF/src/RE/B/BGSDestructibleObjectForm.cpp deleted file mode 100644 index 5148538e..00000000 --- a/CommonLibSF/src/RE/B/BGSDestructibleObjectForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSDestructibleObjectForm.h" diff --git a/CommonLibSF/src/RE/B/BGSForcedLocRefType.cpp b/CommonLibSF/src/RE/B/BGSForcedLocRefType.cpp deleted file mode 100644 index 644c13d2..00000000 --- a/CommonLibSF/src/RE/B/BGSForcedLocRefType.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSForcedLocRefType.h" diff --git a/CommonLibSF/src/RE/B/BGSKeyword.cpp b/CommonLibSF/src/RE/B/BGSKeyword.cpp deleted file mode 100644 index d6a4d9b5..00000000 --- a/CommonLibSF/src/RE/B/BGSKeyword.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSKeyword.h" diff --git a/CommonLibSF/src/RE/B/BGSKeywordForm.cpp b/CommonLibSF/src/RE/B/BGSKeywordForm.cpp deleted file mode 100644 index b362a301..00000000 --- a/CommonLibSF/src/RE/B/BGSKeywordForm.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/B/BGSKeywordForm.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/B/BGSListForm.cpp b/CommonLibSF/src/RE/B/BGSListForm.cpp deleted file mode 100644 index efa6dc95..00000000 --- a/CommonLibSF/src/RE/B/BGSListForm.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/B/BGSListForm.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/B/BGSLocation.cpp b/CommonLibSF/src/RE/B/BGSLocation.cpp deleted file mode 100644 index b6904b57..00000000 --- a/CommonLibSF/src/RE/B/BGSLocation.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSLocation.h" diff --git a/CommonLibSF/src/RE/B/BGSLocationRefType.cpp b/CommonLibSF/src/RE/B/BGSLocationRefType.cpp deleted file mode 100644 index 17d78fa7..00000000 --- a/CommonLibSF/src/RE/B/BGSLocationRefType.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSLocationRefType.h" diff --git a/CommonLibSF/src/RE/B/BGSMod.cpp b/CommonLibSF/src/RE/B/BGSMod.cpp deleted file mode 100644 index 1fce9644..00000000 --- a/CommonLibSF/src/RE/B/BGSMod.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSMod.h" diff --git a/CommonLibSF/src/RE/B/BGSNativeTerminalForm.cpp b/CommonLibSF/src/RE/B/BGSNativeTerminalForm.cpp deleted file mode 100644 index dbb34424..00000000 --- a/CommonLibSF/src/RE/B/BGSNativeTerminalForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSNativeTerminalForm.h" diff --git a/CommonLibSF/src/RE/B/BGSObjectPlacementDefaults.cpp b/CommonLibSF/src/RE/B/BGSObjectPlacementDefaults.cpp deleted file mode 100644 index 7379a6e5..00000000 --- a/CommonLibSF/src/RE/B/BGSObjectPlacementDefaults.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSObjectPlacementDefaults.h" diff --git a/CommonLibSF/src/RE/B/BGSOverridePackCollection.cpp b/CommonLibSF/src/RE/B/BGSOverridePackCollection.cpp deleted file mode 100644 index 99796d42..00000000 --- a/CommonLibSF/src/RE/B/BGSOverridePackCollection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSOverridePackCollection.h" diff --git a/CommonLibSF/src/RE/B/BGSPerk.cpp b/CommonLibSF/src/RE/B/BGSPerk.cpp deleted file mode 100644 index 9b6318b2..00000000 --- a/CommonLibSF/src/RE/B/BGSPerk.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSPerk.h" diff --git a/CommonLibSF/src/RE/B/BGSPerkRankArray.cpp b/CommonLibSF/src/RE/B/BGSPerkRankArray.cpp deleted file mode 100644 index 37488b1f..00000000 --- a/CommonLibSF/src/RE/B/BGSPerkRankArray.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSPerkRankArray.h" diff --git a/CommonLibSF/src/RE/B/BGSPreviewTransform.cpp b/CommonLibSF/src/RE/B/BGSPreviewTransform.cpp deleted file mode 100644 index 5f4f8aad..00000000 --- a/CommonLibSF/src/RE/B/BGSPreviewTransform.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSPreviewTransform.h" diff --git a/CommonLibSF/src/RE/B/BGSPropertySheet.cpp b/CommonLibSF/src/RE/B/BGSPropertySheet.cpp deleted file mode 100644 index 37ed911b..00000000 --- a/CommonLibSF/src/RE/B/BGSPropertySheet.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSPropertySheet.h" diff --git a/CommonLibSF/src/RE/B/BGSScene.cpp b/CommonLibSF/src/RE/B/BGSScene.cpp deleted file mode 100644 index c31b7390..00000000 --- a/CommonLibSF/src/RE/B/BGSScene.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSScene.h" diff --git a/CommonLibSF/src/RE/B/BGSSkinForm.cpp b/CommonLibSF/src/RE/B/BGSSkinForm.cpp deleted file mode 100644 index 756b683f..00000000 --- a/CommonLibSF/src/RE/B/BGSSkinForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSSkinForm.h" diff --git a/CommonLibSF/src/RE/B/BGSSnapTemplateComponent.cpp b/CommonLibSF/src/RE/B/BGSSnapTemplateComponent.cpp deleted file mode 100644 index d7e062ab..00000000 --- a/CommonLibSF/src/RE/B/BGSSnapTemplateComponent.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSSnapTemplateComponent.h" diff --git a/CommonLibSF/src/RE/B/BGSTerminal.cpp b/CommonLibSF/src/RE/B/BGSTerminal.cpp deleted file mode 100644 index d020fc1e..00000000 --- a/CommonLibSF/src/RE/B/BGSTerminal.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BGSTerminal.h" diff --git a/CommonLibSF/src/RE/B/BSFixedString.cpp b/CommonLibSF/src/RE/B/BSFixedString.cpp deleted file mode 100644 index 6be952a1..00000000 --- a/CommonLibSF/src/RE/B/BSFixedString.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BSFixedString.h" diff --git a/CommonLibSF/src/RE/B/BSIntrusiveRefCounted.cpp b/CommonLibSF/src/RE/B/BSIntrusiveRefCounted.cpp deleted file mode 100644 index cfcc9c3e..00000000 --- a/CommonLibSF/src/RE/B/BSIntrusiveRefCounted.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BSIntrusiveRefCounted.h" diff --git a/CommonLibSF/src/RE/B/BSReflection.cpp b/CommonLibSF/src/RE/B/BSReflection.cpp deleted file mode 100644 index 1412ab21..00000000 --- a/CommonLibSF/src/RE/B/BSReflection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BSReflection.h" diff --git a/CommonLibSF/src/RE/B/BSStringT.cpp b/CommonLibSF/src/RE/B/BSStringT.cpp deleted file mode 100644 index 8e9a9855..00000000 --- a/CommonLibSF/src/RE/B/BSStringT.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/B/BSStringT.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/B/BSTEvent.cpp b/CommonLibSF/src/RE/B/BSTEvent.cpp deleted file mode 100644 index 235bf59f..00000000 --- a/CommonLibSF/src/RE/B/BSTEvent.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/B/BSTEvent.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/B/BSTList.cpp b/CommonLibSF/src/RE/B/BSTList.cpp deleted file mode 100644 index 9d86b746..00000000 --- a/CommonLibSF/src/RE/B/BSTList.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BSTList.h" diff --git a/CommonLibSF/src/RE/B/BaseFormComponent.cpp b/CommonLibSF/src/RE/B/BaseFormComponent.cpp deleted file mode 100644 index ec7ac22b..00000000 --- a/CommonLibSF/src/RE/B/BaseFormComponent.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/B/BaseFormComponent.h" diff --git a/CommonLibSF/src/RE/C/CombatGroup.cpp b/CommonLibSF/src/RE/C/CombatGroup.cpp deleted file mode 100644 index 8d251810..00000000 --- a/CommonLibSF/src/RE/C/CombatGroup.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/C/CombatGroup.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/C/ConsoleLog.cpp b/CommonLibSF/src/RE/C/ConsoleLog.cpp deleted file mode 100644 index 70e26608..00000000 --- a/CommonLibSF/src/RE/C/ConsoleLog.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/C/ConsoleLog.h" diff --git a/CommonLibSF/src/RE/I/IAnimationGraphManagerHolder.cpp b/CommonLibSF/src/RE/I/IAnimationGraphManagerHolder.cpp deleted file mode 100644 index d0a9d1e8..00000000 --- a/CommonLibSF/src/RE/I/IAnimationGraphManagerHolder.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/I/IAnimationGraphManagerHolder.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/I/IFunction.cpp b/CommonLibSF/src/RE/I/IFunction.cpp deleted file mode 100644 index c4e0e815..00000000 --- a/CommonLibSF/src/RE/I/IFunction.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/I/IFunction.h" diff --git a/CommonLibSF/src/RE/I/IKeywordFormBase.cpp b/CommonLibSF/src/RE/I/IKeywordFormBase.cpp deleted file mode 100644 index e41eaa36..00000000 --- a/CommonLibSF/src/RE/I/IKeywordFormBase.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/I/IKeywordFormBase.h" diff --git a/CommonLibSF/src/RE/I/IMovementInterface.cpp b/CommonLibSF/src/RE/I/IMovementInterface.cpp deleted file mode 100644 index 4dbee63e..00000000 --- a/CommonLibSF/src/RE/I/IMovementInterface.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/I/IMovementInterface.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/I/INIPrefSettingCollection.cpp b/CommonLibSF/src/RE/I/INIPrefSettingCollection.cpp deleted file mode 100644 index 150a1faa..00000000 --- a/CommonLibSF/src/RE/I/INIPrefSettingCollection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/I/INIPrefSettingCollection.h" diff --git a/CommonLibSF/src/RE/I/INISettingCollection.cpp b/CommonLibSF/src/RE/I/INISettingCollection.cpp deleted file mode 100644 index c1dd7881..00000000 --- a/CommonLibSF/src/RE/I/INISettingCollection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/I/INISettingCollection.h" diff --git a/CommonLibSF/src/RE/I/IPostAnimationChannelUpdateFunctor.cpp b/CommonLibSF/src/RE/I/IPostAnimationChannelUpdateFunctor.cpp deleted file mode 100644 index 346f4f66..00000000 --- a/CommonLibSF/src/RE/I/IPostAnimationChannelUpdateFunctor.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/I/IPostAnimationChannelUpdateFunctor.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/M/MemoryManager.cpp b/CommonLibSF/src/RE/M/MemoryManager.cpp deleted file mode 100644 index 0d206165..00000000 --- a/CommonLibSF/src/RE/M/MemoryManager.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/M/MemoryManager.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/M/MenuOpenCloseEvent.cpp b/CommonLibSF/src/RE/M/MenuOpenCloseEvent.cpp deleted file mode 100644 index 42d123c4..00000000 --- a/CommonLibSF/src/RE/M/MenuOpenCloseEvent.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/M/MenuOpenCloseEvent.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/N/NativeFunction.cpp b/CommonLibSF/src/RE/N/NativeFunction.cpp deleted file mode 100644 index bcc224c0..00000000 --- a/CommonLibSF/src/RE/N/NativeFunction.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/N/NativeFunction.h" diff --git a/CommonLibSF/src/RE/N/NativeFunctionBase.cpp b/CommonLibSF/src/RE/N/NativeFunctionBase.cpp deleted file mode 100644 index 60e69752..00000000 --- a/CommonLibSF/src/RE/N/NativeFunctionBase.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/N/NativeFunctionBase.h" diff --git a/CommonLibSF/src/RE/R/RegSettingCollection.cpp b/CommonLibSF/src/RE/R/RegSettingCollection.cpp deleted file mode 100644 index c555ba56..00000000 --- a/CommonLibSF/src/RE/R/RegSettingCollection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/R/RegSettingCollection.h" diff --git a/CommonLibSF/src/RE/S/Script.cpp b/CommonLibSF/src/RE/S/Script.cpp deleted file mode 100644 index 0ec2907b..00000000 --- a/CommonLibSF/src/RE/S/Script.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/S/Script.h" diff --git a/CommonLibSF/src/RE/S/SettingCollection.cpp b/CommonLibSF/src/RE/S/SettingCollection.cpp deleted file mode 100644 index cc97109e..00000000 --- a/CommonLibSF/src/RE/S/SettingCollection.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/S/SettingCollection.h" diff --git a/CommonLibSF/src/RE/S/SettingCollectionList.cpp b/CommonLibSF/src/RE/S/SettingCollectionList.cpp deleted file mode 100644 index 4678cb87..00000000 --- a/CommonLibSF/src/RE/S/SettingCollectionList.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/S/SettingCollectionList.h" diff --git a/CommonLibSF/src/RE/S/SettingCollectionMap.cpp b/CommonLibSF/src/RE/S/SettingCollectionMap.cpp deleted file mode 100644 index 5c63f071..00000000 --- a/CommonLibSF/src/RE/S/SettingCollectionMap.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/S/SettingCollectionMap.h" diff --git a/CommonLibSF/src/RE/S/Settings.cpp b/CommonLibSF/src/RE/S/Settings.cpp deleted file mode 100644 index c465ef9e..00000000 --- a/CommonLibSF/src/RE/S/Settings.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/S/Settings.h" diff --git a/CommonLibSF/src/RE/Starfield.cpp b/CommonLibSF/src/RE/Starfield.cpp deleted file mode 100644 index 4d0c81b1..00000000 --- a/CommonLibSF/src/RE/Starfield.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/Starfield.h" diff --git a/CommonLibSF/src/RE/T/TBO_InstanceData.cpp b/CommonLibSF/src/RE/T/TBO_InstanceData.cpp deleted file mode 100644 index b8fe53ab..00000000 --- a/CommonLibSF/src/RE/T/TBO_InstanceData.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/T/TBO_InstanceData.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/T/TESAIForm.cpp b/CommonLibSF/src/RE/T/TESAIForm.cpp deleted file mode 100644 index 65822538..00000000 --- a/CommonLibSF/src/RE/T/TESAIForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESAIForm.h" diff --git a/CommonLibSF/src/RE/T/TESActorBase.cpp b/CommonLibSF/src/RE/T/TESActorBase.cpp deleted file mode 100644 index ad9b4b5f..00000000 --- a/CommonLibSF/src/RE/T/TESActorBase.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESActorBase.h" diff --git a/CommonLibSF/src/RE/T/TESActorBaseData.cpp b/CommonLibSF/src/RE/T/TESActorBaseData.cpp deleted file mode 100644 index aed70d0a..00000000 --- a/CommonLibSF/src/RE/T/TESActorBaseData.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESActorBaseData.h" diff --git a/CommonLibSF/src/RE/T/TESBoundAnimObject.cpp b/CommonLibSF/src/RE/T/TESBoundAnimObject.cpp deleted file mode 100644 index 6383364c..00000000 --- a/CommonLibSF/src/RE/T/TESBoundAnimObject.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESBoundAnimObject.h" diff --git a/CommonLibSF/src/RE/T/TESBoundObject.cpp b/CommonLibSF/src/RE/T/TESBoundObject.cpp deleted file mode 100644 index 0bcc90d1..00000000 --- a/CommonLibSF/src/RE/T/TESBoundObject.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESBoundObject.h" diff --git a/CommonLibSF/src/RE/T/TESCamera.cpp b/CommonLibSF/src/RE/T/TESCamera.cpp deleted file mode 100644 index c79926f6..00000000 --- a/CommonLibSF/src/RE/T/TESCamera.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/T/TESCamera.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/T/TESContainer.cpp b/CommonLibSF/src/RE/T/TESContainer.cpp deleted file mode 100644 index 05a31fa0..00000000 --- a/CommonLibSF/src/RE/T/TESContainer.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESContainer.h" diff --git a/CommonLibSF/src/RE/T/TESFile.cpp b/CommonLibSF/src/RE/T/TESFile.cpp deleted file mode 100644 index aa41bc75..00000000 --- a/CommonLibSF/src/RE/T/TESFile.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESFile.h" diff --git a/CommonLibSF/src/RE/T/TESForm.cpp b/CommonLibSF/src/RE/T/TESForm.cpp deleted file mode 100644 index a6ca64ef..00000000 --- a/CommonLibSF/src/RE/T/TESForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESForm.h" diff --git a/CommonLibSF/src/RE/T/TESFullName.cpp b/CommonLibSF/src/RE/T/TESFullName.cpp deleted file mode 100644 index d8d9b1fb..00000000 --- a/CommonLibSF/src/RE/T/TESFullName.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESFullName.h" diff --git a/CommonLibSF/src/RE/T/TESHandleForm.cpp b/CommonLibSF/src/RE/T/TESHandleForm.cpp deleted file mode 100644 index 41d7dca4..00000000 --- a/CommonLibSF/src/RE/T/TESHandleForm.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/T/TESHandleForm.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/T/TESNPC.cpp b/CommonLibSF/src/RE/T/TESNPC.cpp deleted file mode 100644 index b9eebdf5..00000000 --- a/CommonLibSF/src/RE/T/TESNPC.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESNPC.h" diff --git a/CommonLibSF/src/RE/T/TESObject.cpp b/CommonLibSF/src/RE/T/TESObject.cpp deleted file mode 100644 index 9227cc68..00000000 --- a/CommonLibSF/src/RE/T/TESObject.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESObject.h" diff --git a/CommonLibSF/src/RE/T/TESObjectARMO.cpp b/CommonLibSF/src/RE/T/TESObjectARMO.cpp deleted file mode 100644 index 363088ae..00000000 --- a/CommonLibSF/src/RE/T/TESObjectARMO.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESObjectARMO.h" diff --git a/CommonLibSF/src/RE/T/TESObjectCELL.cpp b/CommonLibSF/src/RE/T/TESObjectCELL.cpp deleted file mode 100644 index f236947b..00000000 --- a/CommonLibSF/src/RE/T/TESObjectCELL.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESObjectCELL.h" diff --git a/CommonLibSF/src/RE/T/TESQuest.cpp b/CommonLibSF/src/RE/T/TESQuest.cpp deleted file mode 100644 index a82d6f18..00000000 --- a/CommonLibSF/src/RE/T/TESQuest.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/T/TESQuest.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/T/TESRace.cpp b/CommonLibSF/src/RE/T/TESRace.cpp deleted file mode 100644 index 872863d3..00000000 --- a/CommonLibSF/src/RE/T/TESRace.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESRace.h" diff --git a/CommonLibSF/src/RE/T/TESRaceForm.cpp b/CommonLibSF/src/RE/T/TESRaceForm.cpp deleted file mode 100644 index 4683797d..00000000 --- a/CommonLibSF/src/RE/T/TESRaceForm.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESRaceForm.h" diff --git a/CommonLibSF/src/RE/T/TESResponse.cpp b/CommonLibSF/src/RE/T/TESResponse.cpp deleted file mode 100644 index 6c5b47be..00000000 --- a/CommonLibSF/src/RE/T/TESResponse.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/T/TESResponse.h" - -namespace RE -{} diff --git a/CommonLibSF/src/RE/T/TESSpellList.cpp b/CommonLibSF/src/RE/T/TESSpellList.cpp deleted file mode 100644 index 5bdf4daf..00000000 --- a/CommonLibSF/src/RE/T/TESSpellList.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESSpellList.h" diff --git a/CommonLibSF/src/RE/T/TESTopicInfo.cpp b/CommonLibSF/src/RE/T/TESTopicInfo.cpp deleted file mode 100644 index 4993002e..00000000 --- a/CommonLibSF/src/RE/T/TESTopicInfo.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "RE/T/TESTopicInfo.h" diff --git a/CommonLibSF/src/SFSE/Impl/PCH.cpp b/CommonLibSF/src/SFSE/Impl/PCH.cpp deleted file mode 100644 index e376e25f..00000000 --- a/CommonLibSF/src/SFSE/Impl/PCH.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "SFSE/Impl/PCH.h" From c710bb166b7a40419ab6e25462ed330fd2784844 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 16:42:51 +0000 Subject: [PATCH 06/21] ci: maintenance `2023-09-29.1` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index d52b6241..0da74dc4 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29", + "version-date": "2023-09-29.1", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index ee13bdf0..40706d38 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.1&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 77041d86eec39ee35bafbeab5ec5ac9964625c58 Mon Sep 17 00:00:00 2001 From: lStewieAl Date: Fri, 29 Sep 2023 17:59:25 +0100 Subject: [PATCH 07/21] feat: `Actor`, `AIProcess`, `ActorPackage` RE (#106) Adds AIProcess struct, the fields line up with CommonLibF4. --------- Co-authored-by: powerof3 <32599957+powerof3@users.noreply.github.com> Co-authored-by: Qudix <17361645+Qudix@users.noreply.github.com> --- CommonLibSF/include/RE/A/AIProcess.h | 44 ++++++++ CommonLibSF/include/RE/A/Actor.h | 141 +++++++++++++++++++++++- CommonLibSF/include/RE/A/ActorPackage.h | 25 +++++ CommonLibSF/include/RE/Starfield.h | 2 + CommonLibSF/src/RE/A/AIProcess.cpp | 4 + CommonLibSF/src/RE/A/ActorPackage.cpp | 4 + 6 files changed, 219 insertions(+), 1 deletion(-) create mode 100644 CommonLibSF/include/RE/A/AIProcess.h create mode 100644 CommonLibSF/include/RE/A/ActorPackage.h create mode 100644 CommonLibSF/src/RE/A/AIProcess.cpp create mode 100644 CommonLibSF/src/RE/A/ActorPackage.cpp diff --git a/CommonLibSF/include/RE/A/AIProcess.h b/CommonLibSF/include/RE/A/AIProcess.h new file mode 100644 index 00000000..0e7e2f99 --- /dev/null +++ b/CommonLibSF/include/RE/A/AIProcess.h @@ -0,0 +1,44 @@ +#pragma once + +#include "ActorPackage.h" + +namespace RE +{ + struct MiddleLowProcessData; + struct MiddleHighProcessData; + struct HighProcessData; + + // F8 + class AIProcess + { + public: + MiddleLowProcessData* middleLow; // 00 + MiddleHighProcessData* middleHigh; // 08 + HighProcessData* high; // 10 + ActorPackage currentPackage; // 18 + float hourLastProcessed; // 48 + std::uint32_t unk4C; // 4C + 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 + std::uint64_t unk80; // 80 + std::uint64_t unk88; // 88 + std::uint64_t unk90; // 90 + std::uint64_t unk98; // 98 + std::uint64_t unkA0; // A0 + std::uint64_t unkA8; // A8 + std::uint64_t unkB0; // B0 + std::uint64_t unkB8; // B8 + std::uint64_t unkC0; // C0 + std::uint64_t unkC8; // C8 + std::uint64_t unkD0; // D0 + std::uint64_t unkD8; // D8 + std::uint64_t unkE0; // E0 + std::uint64_t unkE8; // E8 + std::uint64_t unkF0; // F0 + }; + static_assert(sizeof(AIProcess) == 0xF8); +} diff --git a/CommonLibSF/include/RE/A/Actor.h b/CommonLibSF/include/RE/A/Actor.h index 76674f22..83b74630 100644 --- a/CommonLibSF/include/RE/A/Actor.h +++ b/CommonLibSF/include/RE/A/Actor.h @@ -1,11 +1,14 @@ #pragma once #include "RE/T/TESObjectREFR.h" +#include "RE/A/AIProcess.h" +#include "RE/A/ActorPackage.h" namespace RE { class CombatGroup; class TESFaction; + class AIProcess; class Actor : public TESObjectREFR // 110 @@ -145,6 +148,142 @@ namespace RE virtual void Unk_1A0(); // 1A0 virtual void Unk_1A1(); // 1A1 - // More... + 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 + 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 + 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 + std::uint64_t unk240; // 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 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 + 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 + std::uint64_t unk2D0; // 2D0 + 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 + 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 + std::uint64_t unk3B0; // 3B0 + std::uint64_t unk3B8; // 3B8 + std::uint64_t unk3C0; // 3C0 + std::uint64_t unk3C8; // 3C8 + std::uint64_t unk3D0; // 3D0 + std::uint64_t unk3D8; // 3D8 + std::uint64_t unk3E0; // 3E0 + std::uint64_t unk3E8; // 3E8 + std::uint64_t unk3F0; // 3F0 + std::uint64_t unk3F8; // 3F8 + std::uint64_t unk400; // 400 + std::uint64_t unk408; // 408 + std::uint64_t unk410; // 410 + std::uint64_t unk418; // 418 + std::uint64_t unk420; // 420 + std::uint64_t unk428; // 428 + std::uint64_t unk430; // 430 + std::uint64_t unk438; // 438 + std::uint64_t unk440; // 440 + std::uint64_t unk448; // 448 + std::uint64_t unk450; // 450 + std::uint64_t unk458; // 458 + std::uint64_t unk460; // 460 + std::uint64_t unk468; // 468 + std::uint64_t unk470; // 470 + std::uint64_t unk478; // 478 + std::uint64_t unk480; // 480 + std::uint64_t unk488; // 488 + std::uint64_t unk490; // 490 + std::uint64_t unk498; // 498 + std::uint64_t unk4A0; // 4A0 + std::uint64_t unk4A8; // 4A8 + std::uint64_t unk4B0; // 4B0 + std::uint64_t unk4B8; // 4B8 + std::uint64_t unk4C0; // 4C0 + std::uint64_t unk4C8; // 4C8 + std::uint64_t unk4D0; // 4D0 + std::uint64_t unk4D8; // 4D8 + std::uint64_t unk4E0; // 4E0 + std::uint64_t unk4E8; // 4E8 + std::uint64_t unk4F0; // 4F0 + std::uint64_t unk4F8; // 4F8 + std::uint64_t unk500; // 500 + std::uint64_t unk508; // 508 + std::uint64_t unk510; // 510 + 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); } // namespace RE diff --git a/CommonLibSF/include/RE/A/ActorPackage.h b/CommonLibSF/include/RE/A/ActorPackage.h new file mode 100644 index 00000000..2e96f2f0 --- /dev/null +++ b/CommonLibSF/include/RE/A/ActorPackage.h @@ -0,0 +1,25 @@ +#pragma once + +namespace RE +{ + struct ActorPackageData; + class TESPackage; + + class ActorPackage + { + public: + // members + void* packageLock; // 00 + TESPackage* package; // 08 + ActorPackageData* data; // 10 + void* target; // 18 + std::int32_t currentProcedureIndex; // 1C + float packageStartTime; // 20 + std::uint32_t modifiedPackageFlag; // 24 + std::uint16_t modifiedInterruptFlag; // 28 + std::int8_t actorPackageFlags; // 2A + std::int8_t preferredSpeed; // 2B + }; + static_assert(sizeof(ActorPackage) == 0x30); +} + diff --git a/CommonLibSF/include/RE/Starfield.h b/CommonLibSF/include/RE/Starfield.h index 0990d969..6e28d3ad 100644 --- a/CommonLibSF/include/RE/Starfield.h +++ b/CommonLibSF/include/RE/Starfield.h @@ -3,9 +3,11 @@ #include "SFSE/Impl/PCH.h" #include "RE/A/Actor.h" +#include "RE/A/ActorPackage.h" #include "RE/A/ActorValueInfo.h" #include "RE/A/ActorValueOwner.h" #include "RE/A/ActorValues.h" +#include "RE/A/AIProcess.h" #include "RE/B/BGSAttackDataForm.h" #include "RE/B/BGSDestructibleObjectForm.h" #include "RE/B/BGSEditorID.h" diff --git a/CommonLibSF/src/RE/A/AIProcess.cpp b/CommonLibSF/src/RE/A/AIProcess.cpp new file mode 100644 index 00000000..b32c10c0 --- /dev/null +++ b/CommonLibSF/src/RE/A/AIProcess.cpp @@ -0,0 +1,4 @@ +#include "RE/A/AIProcess.h" +namespace RE +{ +} diff --git a/CommonLibSF/src/RE/A/ActorPackage.cpp b/CommonLibSF/src/RE/A/ActorPackage.cpp new file mode 100644 index 00000000..df6390af --- /dev/null +++ b/CommonLibSF/src/RE/A/ActorPackage.cpp @@ -0,0 +1,4 @@ +#include "RE/A/ActorPackage.h" +namespace RE +{ +} From 005f6f3bda6802b14b44d91d65cc3acd819ca992 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 17:00:00 +0000 Subject: [PATCH 08/21] ci: maintenance `2023-09-29.2` --- CommonLibSF/include/RE/A/AIProcess.h | 2 +- CommonLibSF/include/RE/A/Actor.h | 274 ++++++++++++------------ CommonLibSF/include/RE/A/ActorPackage.h | 3 +- CommonLibSF/include/RE/Starfield.h | 2 +- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 6 files changed, 142 insertions(+), 143 deletions(-) diff --git a/CommonLibSF/include/RE/A/AIProcess.h b/CommonLibSF/include/RE/A/AIProcess.h index 0e7e2f99..edaab507 100644 --- a/CommonLibSF/include/RE/A/AIProcess.h +++ b/CommonLibSF/include/RE/A/AIProcess.h @@ -41,4 +41,4 @@ namespace RE std::uint64_t unkF0; // F0 }; static_assert(sizeof(AIProcess) == 0xF8); -} +} // namespace RE diff --git a/CommonLibSF/include/RE/A/Actor.h b/CommonLibSF/include/RE/A/Actor.h index 83b74630..761bbc66 100644 --- a/CommonLibSF/include/RE/A/Actor.h +++ b/CommonLibSF/include/RE/A/Actor.h @@ -1,8 +1,8 @@ #pragma once -#include "RE/T/TESObjectREFR.h" #include "RE/A/AIProcess.h" #include "RE/A/ActorPackage.h" +#include "RE/T/TESObjectREFR.h" namespace RE { @@ -148,142 +148,142 @@ namespace RE virtual void Unk_1A0(); // 1A0 virtual void Unk_1A1(); // 1A1 - 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 - 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 - 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 - std::uint64_t unk240; // 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 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 - 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 - std::uint64_t unk2D0; // 2D0 - 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 - 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 - std::uint64_t unk3B0; // 3B0 - std::uint64_t unk3B8; // 3B8 - std::uint64_t unk3C0; // 3C0 - std::uint64_t unk3C8; // 3C8 - std::uint64_t unk3D0; // 3D0 - std::uint64_t unk3D8; // 3D8 - std::uint64_t unk3E0; // 3E0 - std::uint64_t unk3E8; // 3E8 - std::uint64_t unk3F0; // 3F0 - std::uint64_t unk3F8; // 3F8 - std::uint64_t unk400; // 400 - std::uint64_t unk408; // 408 - std::uint64_t unk410; // 410 - std::uint64_t unk418; // 418 - std::uint64_t unk420; // 420 - std::uint64_t unk428; // 428 - std::uint64_t unk430; // 430 - std::uint64_t unk438; // 438 - std::uint64_t unk440; // 440 - std::uint64_t unk448; // 448 - std::uint64_t unk450; // 450 - std::uint64_t unk458; // 458 - std::uint64_t unk460; // 460 - std::uint64_t unk468; // 468 - std::uint64_t unk470; // 470 - std::uint64_t unk478; // 478 - std::uint64_t unk480; // 480 - std::uint64_t unk488; // 488 - std::uint64_t unk490; // 490 - std::uint64_t unk498; // 498 - std::uint64_t unk4A0; // 4A0 - std::uint64_t unk4A8; // 4A8 - std::uint64_t unk4B0; // 4B0 - std::uint64_t unk4B8; // 4B8 - std::uint64_t unk4C0; // 4C0 - std::uint64_t unk4C8; // 4C8 - std::uint64_t unk4D0; // 4D0 - std::uint64_t unk4D8; // 4D8 - std::uint64_t unk4E0; // 4E0 - std::uint64_t unk4E8; // 4E8 - std::uint64_t unk4F0; // 4F0 - std::uint64_t unk4F8; // 4F8 - std::uint64_t unk500; // 500 - std::uint64_t unk508; // 508 - std::uint64_t unk510; // 510 - 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 + 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 + 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 + 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 + std::uint64_t unk240; // 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 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 + 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 + std::uint64_t unk2D0; // 2D0 + 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 + 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 + std::uint64_t unk3B0; // 3B0 + std::uint64_t unk3B8; // 3B8 + std::uint64_t unk3C0; // 3C0 + std::uint64_t unk3C8; // 3C8 + std::uint64_t unk3D0; // 3D0 + std::uint64_t unk3D8; // 3D8 + std::uint64_t unk3E0; // 3E0 + std::uint64_t unk3E8; // 3E8 + std::uint64_t unk3F0; // 3F0 + std::uint64_t unk3F8; // 3F8 + std::uint64_t unk400; // 400 + std::uint64_t unk408; // 408 + std::uint64_t unk410; // 410 + std::uint64_t unk418; // 418 + std::uint64_t unk420; // 420 + std::uint64_t unk428; // 428 + std::uint64_t unk430; // 430 + std::uint64_t unk438; // 438 + std::uint64_t unk440; // 440 + std::uint64_t unk448; // 448 + std::uint64_t unk450; // 450 + std::uint64_t unk458; // 458 + std::uint64_t unk460; // 460 + std::uint64_t unk468; // 468 + std::uint64_t unk470; // 470 + std::uint64_t unk478; // 478 + std::uint64_t unk480; // 480 + std::uint64_t unk488; // 488 + std::uint64_t unk490; // 490 + std::uint64_t unk498; // 498 + std::uint64_t unk4A0; // 4A0 + std::uint64_t unk4A8; // 4A8 + std::uint64_t unk4B0; // 4B0 + std::uint64_t unk4B8; // 4B8 + std::uint64_t unk4C0; // 4C0 + std::uint64_t unk4C8; // 4C8 + std::uint64_t unk4D0; // 4D0 + std::uint64_t unk4D8; // 4D8 + std::uint64_t unk4E0; // 4E0 + std::uint64_t unk4E8; // 4E8 + std::uint64_t unk4F0; // 4F0 + std::uint64_t unk4F8; // 4F8 + std::uint64_t unk500; // 500 + std::uint64_t unk508; // 508 + std::uint64_t unk510; // 510 + 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); } // namespace RE diff --git a/CommonLibSF/include/RE/A/ActorPackage.h b/CommonLibSF/include/RE/A/ActorPackage.h index 2e96f2f0..c7665f79 100644 --- a/CommonLibSF/include/RE/A/ActorPackage.h +++ b/CommonLibSF/include/RE/A/ActorPackage.h @@ -21,5 +21,4 @@ namespace RE std::int8_t preferredSpeed; // 2B }; static_assert(sizeof(ActorPackage) == 0x30); -} - +} // namespace RE diff --git a/CommonLibSF/include/RE/Starfield.h b/CommonLibSF/include/RE/Starfield.h index 6e28d3ad..1864e004 100644 --- a/CommonLibSF/include/RE/Starfield.h +++ b/CommonLibSF/include/RE/Starfield.h @@ -2,12 +2,12 @@ #include "SFSE/Impl/PCH.h" +#include "RE/A/AIProcess.h" #include "RE/A/Actor.h" #include "RE/A/ActorPackage.h" #include "RE/A/ActorValueInfo.h" #include "RE/A/ActorValueOwner.h" #include "RE/A/ActorValues.h" -#include "RE/A/AIProcess.h" #include "RE/B/BGSAttackDataForm.h" #include "RE/B/BGSDestructibleObjectForm.h" #include "RE/B/BGSEditorID.h" diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index 0da74dc4..980ad28b 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29.1", + "version-date": "2023-09-29.2", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index 40706d38..b271b3af 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.1&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.2&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From c4b9ee1d51fae3948837cc3a9bf01c4272d71deb Mon Sep 17 00:00:00 2001 From: Angad <66992519+ThirdEyeSqueegee@users.noreply.github.com> Date: Fri, 29 Sep 2023 10:55:29 -0700 Subject: [PATCH 09/21] chore: remove namespace comments (#122) --- CommonLibSF/.clang-format | 2 +- CommonLibSF/include/RE/A/AIProcess.h | 2 +- CommonLibSF/include/RE/A/Actor.h | 2 +- CommonLibSF/include/RE/A/ActorPackage.h | 2 +- CommonLibSF/include/RE/A/ActorValueInfo.h | 2 +- CommonLibSF/include/RE/A/ActorValueOwner.h | 2 +- CommonLibSF/include/RE/A/ActorValues.h | 2 +- CommonLibSF/include/RE/B/BGSAttackDataForm.h | 2 +- .../include/RE/B/BGSDestructibleObjectForm.h | 2 +- CommonLibSF/include/RE/B/BGSEditorID.h | 2 +- CommonLibSF/include/RE/B/BGSEntryPoint.h | 4 ++-- CommonLibSF/include/RE/B/BGSForcedLocRefType.h | 2 +- CommonLibSF/include/RE/B/BGSKeyword.h | 2 +- CommonLibSF/include/RE/B/BGSKeywordForm.h | 2 +- CommonLibSF/include/RE/B/BGSListForm.h | 2 +- CommonLibSF/include/RE/B/BGSLocalizedString.h | 2 +- CommonLibSF/include/RE/B/BGSLocation.h | 2 +- CommonLibSF/include/RE/B/BGSMod.h | 6 +++--- CommonLibSF/include/RE/B/BGSNativeTerminalForm.h | 2 +- .../include/RE/B/BGSObjectPlacementDefaults.h | 2 +- .../include/RE/B/BGSOverridePackCollection.h | 2 +- CommonLibSF/include/RE/B/BGSPerkRankArray.h | 2 +- CommonLibSF/include/RE/B/BGSPreviewTransform.h | 2 +- CommonLibSF/include/RE/B/BGSPropertySheet.h | 2 +- CommonLibSF/include/RE/B/BGSScene.h | 2 +- CommonLibSF/include/RE/B/BGSSkinForm.h | 2 +- .../include/RE/B/BGSSnapTemplateComponent.h | 2 +- CommonLibSF/include/RE/B/BGSTerminal.h | 2 +- CommonLibSF/include/RE/B/BSFixedString.h | 4 ++-- CommonLibSF/include/RE/B/BSInputEventReceiver.h | 2 +- CommonLibSF/include/RE/B/BSIntrusiveRefCounted.h | 2 +- CommonLibSF/include/RE/B/BSReflection.h | 4 ++-- CommonLibSF/include/RE/B/BSStringPool.h | 2 +- CommonLibSF/include/RE/B/BSStringT.h | 2 +- CommonLibSF/include/RE/B/BSTEvent.h | 4 ++-- CommonLibSF/include/RE/B/BSTList.h | 2 +- CommonLibSF/include/RE/B/BSTSingleton.h | 2 +- CommonLibSF/include/RE/B/BaseFormComponent.h | 2 +- CommonLibSF/include/RE/C/CombatGroup.h | 2 +- CommonLibSF/include/RE/C/ConsoleLog.h | 2 +- CommonLibSF/include/RE/F/FORM_ENUM_STRING.h | 2 +- CommonLibSF/include/RE/F/FormTypes.h | 8 ++++---- .../include/RE/I/IAnimationGraphManagerHolder.h | 2 +- CommonLibSF/include/RE/I/IFunction.h | 4 ++-- CommonLibSF/include/RE/I/IKeywordFormBase.h | 2 +- CommonLibSF/include/RE/I/IMovementInterface.h | 2 +- .../include/RE/I/INIPrefSettingCollection.h | 2 +- CommonLibSF/include/RE/I/INISettingCollection.h | 2 +- .../RE/I/IPostAnimationChannelUpdateFunctor.h | 2 +- CommonLibSF/include/RE/M/MenuOpenCloseEvent.h | 2 +- CommonLibSF/include/RE/N/NativeFunction.h | 4 ++-- CommonLibSF/include/RE/N/NativeFunctionBase.h | 6 +++--- CommonLibSF/include/RE/N/NiPoint3.h | 2 +- CommonLibSF/include/RE/N/NiSmartPointer.h | 2 +- CommonLibSF/include/RE/Offsets_RTTI.h | 4 ++-- CommonLibSF/include/RE/Offsets_VTABLE.h | 4 ++-- CommonLibSF/include/RE/P/PlayerCamera.h | 4 ++-- CommonLibSF/include/RE/R/RegSettingCollection.h | 2 +- CommonLibSF/include/RE/RTTI.h | 8 ++++---- CommonLibSF/include/RE/S/Script.h | 2 +- CommonLibSF/include/RE/S/SettingCollection.h | 2 +- CommonLibSF/include/RE/S/SettingCollectionList.h | 2 +- CommonLibSF/include/RE/S/SettingCollectionMap.h | 2 +- CommonLibSF/include/RE/S/Settings.h | 2 +- CommonLibSF/include/RE/T/TBO_InstanceData.h | 2 +- CommonLibSF/include/RE/T/TESAIForm.h | 2 +- CommonLibSF/include/RE/T/TESActorBase.h | 2 +- CommonLibSF/include/RE/T/TESActorBaseData.h | 2 +- CommonLibSF/include/RE/T/TESBoundAnimObject.h | 2 +- CommonLibSF/include/RE/T/TESBoundObject.h | 2 +- CommonLibSF/include/RE/T/TESCamera.h | 2 +- CommonLibSF/include/RE/T/TESContainer.h | 2 +- CommonLibSF/include/RE/T/TESFile.h | 2 +- CommonLibSF/include/RE/T/TESForm.h | 2 +- CommonLibSF/include/RE/T/TESFormRefCount.h | 2 +- CommonLibSF/include/RE/T/TESFullName.h | 2 +- CommonLibSF/include/RE/T/TESHandleForm.h | 2 +- CommonLibSF/include/RE/T/TESNPC.h | 2 +- CommonLibSF/include/RE/T/TESObject.h | 2 +- CommonLibSF/include/RE/T/TESObjectARMO.h | 2 +- CommonLibSF/include/RE/T/TESObjectCELL.h | 2 +- CommonLibSF/include/RE/T/TESObjectREFR.h | 2 +- CommonLibSF/include/RE/T/TESQuest.h | 2 +- CommonLibSF/include/RE/T/TESRace.h | 2 +- CommonLibSF/include/RE/T/TESRaceForm.h | 2 +- CommonLibSF/include/RE/T/TESResponse.h | 2 +- CommonLibSF/include/RE/T/TESSpellList.h | 2 +- CommonLibSF/include/RE/T/TESTopicInfo.h | 2 +- CommonLibSF/include/RE/T/TESWorldSpace.h | 2 +- CommonLibSF/include/RE/U/UI.h | 2 +- CommonLibSF/include/REL/ID.h | 4 ++-- CommonLibSF/include/REL/Module.h | 2 +- CommonLibSF/include/REL/Offset.h | 2 +- CommonLibSF/include/REL/Pattern.h | 10 +++++----- CommonLibSF/include/REL/Relocation.h | 4 ++-- CommonLibSF/include/REL/Version.h | 6 +++--- CommonLibSF/include/SFSE/API.h | 2 +- CommonLibSF/include/SFSE/IAT.h | 2 +- CommonLibSF/include/SFSE/Impl/DInputAPI.h | 2 +- CommonLibSF/include/SFSE/Impl/PCH.h | 14 +++++++------- CommonLibSF/include/SFSE/Impl/Stubs.h | 4 ++-- CommonLibSF/include/SFSE/Impl/WinAPI.h | 4 ++-- CommonLibSF/include/SFSE/Impl/XInputAPI.h | 2 +- CommonLibSF/include/SFSE/InputMap.h | 4 ++-- CommonLibSF/include/SFSE/Interfaces.h | 2 +- CommonLibSF/include/SFSE/Logger.h | 2 +- CommonLibSF/include/SFSE/Trampoline.h | 4 ++-- CommonLibSF/include/SFSE/Utilities.h | 4 ++-- CommonLibSF/include/SFSE/Version.h | 2 +- CommonLibSF/src/RE/F/FormTypes.cpp | 2 +- CommonLibSF/src/RE/N/NiPoint3.cpp | 2 +- CommonLibSF/src/RE/P/PlayerCamera.cpp | 2 +- CommonLibSF/src/RE/T/TESFormRefCount.cpp | 2 +- CommonLibSF/src/RE/T/TESObjectREFR.cpp | 2 +- CommonLibSF/src/REL/ID.cpp | 4 ++-- CommonLibSF/src/REL/Module.cpp | 2 +- CommonLibSF/src/REL/Version.cpp | 2 +- CommonLibSF/src/SFSE/API.cpp | 4 ++-- CommonLibSF/src/SFSE/IAT.cpp | 2 +- CommonLibSF/src/SFSE/Impl/WinAPI.cpp | 2 +- CommonLibSF/src/SFSE/InputMap.cpp | 2 +- CommonLibSF/src/SFSE/Interfaces.cpp | 2 +- CommonLibSF/src/SFSE/Logger.cpp | 4 ++-- CommonLibSF/src/SFSE/Trampoline.cpp | 2 +- 124 files changed, 165 insertions(+), 165 deletions(-) diff --git a/CommonLibSF/.clang-format b/CommonLibSF/.clang-format index 170ef92e..8544cf0c 100644 --- a/CommonLibSF/.clang-format +++ b/CommonLibSF/.clang-format @@ -54,7 +54,7 @@ ContinuationIndentWidth: 4 Cpp11BracedListStyle: false DerivePointerAlignment: false DisableFormat: false -FixNamespaceComments: true +FixNamespaceComments: false IncludeBlocks: Preserve IndentCaseBlocks: true IndentCaseLabels: false diff --git a/CommonLibSF/include/RE/A/AIProcess.h b/CommonLibSF/include/RE/A/AIProcess.h index edaab507..0e7e2f99 100644 --- a/CommonLibSF/include/RE/A/AIProcess.h +++ b/CommonLibSF/include/RE/A/AIProcess.h @@ -41,4 +41,4 @@ namespace RE std::uint64_t unkF0; // F0 }; static_assert(sizeof(AIProcess) == 0xF8); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/A/Actor.h b/CommonLibSF/include/RE/A/Actor.h index 761bbc66..ce642c0e 100644 --- a/CommonLibSF/include/RE/A/Actor.h +++ b/CommonLibSF/include/RE/A/Actor.h @@ -286,4 +286,4 @@ namespace RE std::uint64_t unk548; // 548 }; static_assert(sizeof(Actor) == 0x550); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/A/ActorPackage.h b/CommonLibSF/include/RE/A/ActorPackage.h index c7665f79..e36a56eb 100644 --- a/CommonLibSF/include/RE/A/ActorPackage.h +++ b/CommonLibSF/include/RE/A/ActorPackage.h @@ -21,4 +21,4 @@ namespace RE std::int8_t preferredSpeed; // 2B }; static_assert(sizeof(ActorPackage) == 0x30); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/A/ActorValueInfo.h b/CommonLibSF/include/RE/A/ActorValueInfo.h index 0ff84dba..3493a525 100644 --- a/CommonLibSF/include/RE/A/ActorValueInfo.h +++ b/CommonLibSF/include/RE/A/ActorValueInfo.h @@ -63,4 +63,4 @@ namespace RE std::uint32_t sortIndex; // 17C }; static_assert(sizeof(ActorValueInfo) == 0x180); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/A/ActorValueOwner.h b/CommonLibSF/include/RE/A/ActorValueOwner.h index c0632f05..2f2cafe9 100644 --- a/CommonLibSF/include/RE/A/ActorValueOwner.h +++ b/CommonLibSF/include/RE/A/ActorValueOwner.h @@ -28,4 +28,4 @@ namespace RE [[nodiscard]] virtual bool GetIsPlayerOwner() const; // 0B }; static_assert(sizeof(ActorValueOwner) == 0x8); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/A/ActorValues.h b/CommonLibSF/include/RE/A/ActorValues.h index d1a85612..e5827009 100644 --- a/CommonLibSF/include/RE/A/ActorValues.h +++ b/CommonLibSF/include/RE/A/ActorValues.h @@ -221,4 +221,4 @@ namespace RE std::uint32_t avTypeCounts[10]; // 598 }; static_assert(sizeof(ActorValue) == 0x5C0); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSAttackDataForm.h b/CommonLibSF/include/RE/B/BGSAttackDataForm.h index dfdb3db5..378f7b97 100644 --- a/CommonLibSF/include/RE/B/BGSAttackDataForm.h +++ b/CommonLibSF/include/RE/B/BGSAttackDataForm.h @@ -18,4 +18,4 @@ namespace RE NiPointer attackDataMap; // 08 }; static_assert(sizeof(BGSAttackDataForm) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSDestructibleObjectForm.h b/CommonLibSF/include/RE/B/BGSDestructibleObjectForm.h index f7316c55..3672df68 100644 --- a/CommonLibSF/include/RE/B/BGSDestructibleObjectForm.h +++ b/CommonLibSF/include/RE/B/BGSDestructibleObjectForm.h @@ -17,4 +17,4 @@ namespace RE DestructibleObjectData* data; // 08 }; static_assert(sizeof(BGSDestructibleObjectForm) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSEditorID.h b/CommonLibSF/include/RE/B/BGSEditorID.h index 00735d3a..7f00c934 100644 --- a/CommonLibSF/include/RE/B/BGSEditorID.h +++ b/CommonLibSF/include/RE/B/BGSEditorID.h @@ -34,4 +34,4 @@ namespace RE TESForm* _owner; // 08 }; static_assert(sizeof(BGSEditorID) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSEntryPoint.h b/CommonLibSF/include/RE/B/BGSEntryPoint.h index 80538154..a6a6d5d0 100644 --- a/CommonLibSF/include/RE/B/BGSEntryPoint.h +++ b/CommonLibSF/include/RE/B/BGSEntryPoint.h @@ -270,5 +270,5 @@ namespace RE REL::Relocation func{ REL::ID(110912) }; return func(a_entryPoint, a_perkOwner, a_args...); } - } // namespace BGSEntryPoint -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/B/BGSForcedLocRefType.h b/CommonLibSF/include/RE/B/BGSForcedLocRefType.h index cdfdba24..681e3ed2 100644 --- a/CommonLibSF/include/RE/B/BGSForcedLocRefType.h +++ b/CommonLibSF/include/RE/B/BGSForcedLocRefType.h @@ -14,4 +14,4 @@ namespace RE std::uint64_t unk10; // 10 }; static_assert(sizeof(BGSForcedLocRefType) == 0x18); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSKeyword.h b/CommonLibSF/include/RE/B/BGSKeyword.h index 47b3065d..97859989 100644 --- a/CommonLibSF/include/RE/B/BGSKeyword.h +++ b/CommonLibSF/include/RE/B/BGSKeyword.h @@ -10,4 +10,4 @@ namespace RE SF_RTTI_VTABLE(BGSKeyword); SF_FORMTYPE(KYWD); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSKeywordForm.h b/CommonLibSF/include/RE/B/BGSKeywordForm.h index ebcf3db4..5bab5910 100644 --- a/CommonLibSF/include/RE/B/BGSKeywordForm.h +++ b/CommonLibSF/include/RE/B/BGSKeywordForm.h @@ -21,4 +21,4 @@ namespace RE std::uint64_t unk28; }; static_assert(sizeof(BGSKeywordForm) == 0x30); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSListForm.h b/CommonLibSF/include/RE/B/BGSListForm.h index 1fe5429d..c796aa34 100644 --- a/CommonLibSF/include/RE/B/BGSListForm.h +++ b/CommonLibSF/include/RE/B/BGSListForm.h @@ -11,4 +11,4 @@ namespace RE SF_RTTI_VTABLE(BGSListForm); SF_FORMTYPE(FLST); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSLocalizedString.h b/CommonLibSF/include/RE/B/BGSLocalizedString.h index d1b43e2f..86959429 100644 --- a/CommonLibSF/include/RE/B/BGSLocalizedString.h +++ b/CommonLibSF/include/RE/B/BGSLocalizedString.h @@ -47,4 +47,4 @@ namespace RE BSFixedStringCS _data; // 0 }; static_assert(sizeof(BGSLocalizedString) == 0x8); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSLocation.h b/CommonLibSF/include/RE/B/BGSLocation.h index dc3b9fb3..b0607033 100644 --- a/CommonLibSF/include/RE/B/BGSLocation.h +++ b/CommonLibSF/include/RE/B/BGSLocation.h @@ -30,4 +30,4 @@ namespace RE bool hasBeenEverExplored; // 1DD // }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSMod.h b/CommonLibSF/include/RE/B/BGSMod.h index 699954ef..a777e604 100644 --- a/CommonLibSF/include/RE/B/BGSMod.h +++ b/CommonLibSF/include/RE/B/BGSMod.h @@ -27,6 +27,6 @@ namespace RE void* unk18; // 18 }; static_assert(sizeof(Items) == 0x20); - } // namespace Template - } // namespace BGSMod -} // namespace RE + } + } +} diff --git a/CommonLibSF/include/RE/B/BGSNativeTerminalForm.h b/CommonLibSF/include/RE/B/BGSNativeTerminalForm.h index c413363b..af5c2c5d 100644 --- a/CommonLibSF/include/RE/B/BGSNativeTerminalForm.h +++ b/CommonLibSF/include/RE/B/BGSNativeTerminalForm.h @@ -11,4 +11,4 @@ namespace RE BGSTerminal* terminal; // 08 }; static_assert(sizeof(BGSNativeTerminalForm) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSObjectPlacementDefaults.h b/CommonLibSF/include/RE/B/BGSObjectPlacementDefaults.h index c9d9e784..52c5cee8 100644 --- a/CommonLibSF/include/RE/B/BGSObjectPlacementDefaults.h +++ b/CommonLibSF/include/RE/B/BGSObjectPlacementDefaults.h @@ -15,4 +15,4 @@ namespace RE std::uint32_t unk18; // 18 }; static_assert(sizeof(BGSObjectPlacementDefaults) == 0x20); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSOverridePackCollection.h b/CommonLibSF/include/RE/B/BGSOverridePackCollection.h index 1f53672f..0ee387ee 100644 --- a/CommonLibSF/include/RE/B/BGSOverridePackCollection.h +++ b/CommonLibSF/include/RE/B/BGSOverridePackCollection.h @@ -21,4 +21,4 @@ namespace RE BGSListForm* unk40; }; static_assert(sizeof(BGSOverridePackCollection) == 0x48); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSPerkRankArray.h b/CommonLibSF/include/RE/B/BGSPerkRankArray.h index d6f2ee23..b83c458a 100644 --- a/CommonLibSF/include/RE/B/BGSPerkRankArray.h +++ b/CommonLibSF/include/RE/B/BGSPerkRankArray.h @@ -24,4 +24,4 @@ namespace RE std::uint32_t perkCount; // 10 }; static_assert(sizeof(BGSPerkRankArray) == 0x18); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSPreviewTransform.h b/CommonLibSF/include/RE/B/BGSPreviewTransform.h index 3f1679e3..10d8179c 100644 --- a/CommonLibSF/include/RE/B/BGSPreviewTransform.h +++ b/CommonLibSF/include/RE/B/BGSPreviewTransform.h @@ -20,4 +20,4 @@ namespace RE std::uint64_t unk40; // 40 }; static_assert(sizeof(BGSPreviewTransform) == 0x48); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSPropertySheet.h b/CommonLibSF/include/RE/B/BGSPropertySheet.h index 172e5622..748cda3b 100644 --- a/CommonLibSF/include/RE/B/BGSPropertySheet.h +++ b/CommonLibSF/include/RE/B/BGSPropertySheet.h @@ -13,4 +13,4 @@ namespace RE std::uint64_t /* BSTArray>* */ unk08; }; static_assert(sizeof(BGSPropertySheet) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSScene.h b/CommonLibSF/include/RE/B/BGSScene.h index 3c2c5602..a1c448fa 100644 --- a/CommonLibSF/include/RE/B/BGSScene.h +++ b/CommonLibSF/include/RE/B/BGSScene.h @@ -15,4 +15,4 @@ namespace RE // }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSSkinForm.h b/CommonLibSF/include/RE/B/BGSSkinForm.h index 00435c12..dad9bf20 100644 --- a/CommonLibSF/include/RE/B/BGSSkinForm.h +++ b/CommonLibSF/include/RE/B/BGSSkinForm.h @@ -14,4 +14,4 @@ namespace RE TESObjectARMO* formSkin; // 08 }; static_assert(sizeof(BGSSkinForm) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h b/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h index 62426e61..d4aee027 100644 --- a/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h +++ b/CommonLibSF/include/RE/B/BGSSnapTemplateComponent.h @@ -16,4 +16,4 @@ namespace RE std::uint64_t unk10; // 10 }; static_assert(sizeof(BGSSnapTemplateComponent) == 0x18); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BGSTerminal.h b/CommonLibSF/include/RE/B/BGSTerminal.h index f216a9f4..0359741a 100644 --- a/CommonLibSF/include/RE/B/BGSTerminal.h +++ b/CommonLibSF/include/RE/B/BGSTerminal.h @@ -7,4 +7,4 @@ namespace RE public: SF_RTTI_VTABLE(BGSTerminal); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSFixedString.h b/CommonLibSF/include/RE/B/BSFixedString.h index 91bf7a72..a5d3c2a2 100644 --- a/CommonLibSF/include/RE/B/BSFixedString.h +++ b/CommonLibSF/include/RE/B/BSFixedString.h @@ -200,10 +200,10 @@ namespace RE extern template class BSFixedString; extern template class BSFixedString; extern template class BSFixedString; - } // namespace detail + } using BSFixedString = detail::BSFixedString; using BSFixedStringCS = detail::BSFixedString; using BSFixedStringW = detail::BSFixedString; using BSFixedStringWCS = detail::BSFixedString; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSInputEventReceiver.h b/CommonLibSF/include/RE/B/BSInputEventReceiver.h index 03f90bc9..def64e81 100644 --- a/CommonLibSF/include/RE/B/BSInputEventReceiver.h +++ b/CommonLibSF/include/RE/B/BSInputEventReceiver.h @@ -16,4 +16,4 @@ namespace RE std::uint32_t currInputTimeCount; // 08 }; static_assert(sizeof(BSInputEventReceiver) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSIntrusiveRefCounted.h b/CommonLibSF/include/RE/B/BSIntrusiveRefCounted.h index d3f14eb5..96eaf441 100644 --- a/CommonLibSF/include/RE/B/BSIntrusiveRefCounted.h +++ b/CommonLibSF/include/RE/B/BSIntrusiveRefCounted.h @@ -11,4 +11,4 @@ namespace RE std::uint32_t unk04; // 04 }; static_assert(sizeof(BSIntrusiveRefCounted) == 0x08); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSReflection.h b/CommonLibSF/include/RE/B/BSReflection.h index 22765e34..22a419cc 100644 --- a/CommonLibSF/include/RE/B/BSReflection.h +++ b/CommonLibSF/include/RE/B/BSReflection.h @@ -55,5 +55,5 @@ namespace RE void* data; // 08 }; static_assert(sizeof(TypedData) == 0x10); - } // namespace BSReflection -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/B/BSStringPool.h b/CommonLibSF/include/RE/B/BSStringPool.h index 4b90b554..d860f281 100644 --- a/CommonLibSF/include/RE/B/BSStringPool.h +++ b/CommonLibSF/include/RE/B/BSStringPool.h @@ -114,4 +114,4 @@ namespace RE REL::Relocation func{ REL::ID(198220) }; return func(a_result, a_string, a_caseSensitive); } -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSStringT.h b/CommonLibSF/include/RE/B/BSStringT.h index 7823c4d4..18670b2a 100644 --- a/CommonLibSF/include/RE/B/BSStringT.h +++ b/CommonLibSF/include/RE/B/BSStringT.h @@ -118,4 +118,4 @@ namespace RE size_type _size{ 0 }; // ?? size_type _capacity{ 0 }; // ?? }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSTEvent.h b/CommonLibSF/include/RE/B/BSTEvent.h index 377827f1..98710af8 100644 --- a/CommonLibSF/include/RE/B/BSTEvent.h +++ b/CommonLibSF/include/RE/B/BSTEvent.h @@ -27,7 +27,7 @@ namespace RE inline SinkBase::~SinkBase() = default; inline SourceBase::~SourceBase() = default; - } // namespace BSTEventDetail + } template class BSTEventSource; @@ -86,4 +86,4 @@ namespace RE virtual ~BSTGlobalEvent(); // 00 }; static_assert(sizeof(BSTGlobalEvent) == 0x08); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSTList.h b/CommonLibSF/include/RE/B/BSTList.h index 730e5637..147283ee 100644 --- a/CommonLibSF/include/RE/B/BSTList.h +++ b/CommonLibSF/include/RE/B/BSTList.h @@ -429,4 +429,4 @@ namespace RE // members Node _listHead; // 00 }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BSTSingleton.h b/CommonLibSF/include/RE/B/BSTSingleton.h index ad758f0e..31abbe43 100644 --- a/CommonLibSF/include/RE/B/BSTSingleton.h +++ b/CommonLibSF/include/RE/B/BSTSingleton.h @@ -58,4 +58,4 @@ namespace RE }; #endif -} // namespace RE +} diff --git a/CommonLibSF/include/RE/B/BaseFormComponent.h b/CommonLibSF/include/RE/B/BaseFormComponent.h index ccc1a6ea..bfa1763c 100644 --- a/CommonLibSF/include/RE/B/BaseFormComponent.h +++ b/CommonLibSF/include/RE/B/BaseFormComponent.h @@ -20,4 +20,4 @@ namespace RE virtual void Unk_0A(); // 0A }; static_assert(sizeof(BaseFormComponent) == 0x08); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/C/CombatGroup.h b/CommonLibSF/include/RE/C/CombatGroup.h index 052879c7..11bff87f 100644 --- a/CommonLibSF/include/RE/C/CombatGroup.h +++ b/CommonLibSF/include/RE/C/CombatGroup.h @@ -46,4 +46,4 @@ namespace RE */ }; //static_assert(sizeof(CombatGroup) == 0x168); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/C/ConsoleLog.h b/CommonLibSF/include/RE/C/ConsoleLog.h index 63bd46fd..703bb45b 100644 --- a/CommonLibSF/include/RE/C/ConsoleLog.h +++ b/CommonLibSF/include/RE/C/ConsoleLog.h @@ -37,4 +37,4 @@ namespace RE Print(std::vformat(a_fmt.get(), std::make_format_args(a_args...)).c_str()); } }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/F/FORM_ENUM_STRING.h b/CommonLibSF/include/RE/F/FORM_ENUM_STRING.h index dc943fc5..87404506 100644 --- a/CommonLibSF/include/RE/F/FORM_ENUM_STRING.h +++ b/CommonLibSF/include/RE/F/FORM_ENUM_STRING.h @@ -18,4 +18,4 @@ namespace RE FormType formType; // 08 }; static_assert(sizeof(FORM_ENUM_STRING) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/F/FormTypes.h b/CommonLibSF/include/RE/F/FormTypes.h index 632e89e2..8ce3ef76 100644 --- a/CommonLibSF/include/RE/F/FormTypes.h +++ b/CommonLibSF/include/RE/F/FormTypes.h @@ -225,7 +225,7 @@ namespace RE [[nodiscard]] const char* FormTypeToString(FormType a_formType); [[nodiscard]] FormType StringToFormType(std::string_view a_formType); -} // namespace RE +} namespace std { @@ -233,7 +233,7 @@ namespace std { return RE::FormTypeToString(a_formType); } -} // namespace std +} #ifdef FMT_VERSION namespace fmt @@ -253,7 +253,7 @@ namespace fmt return fmt::format_to(a_ctx.out(), "{}", RE::FormTypeToString(a_formType)); } }; -} // namespace fmt +} #endif #ifdef __cpp_lib_format @@ -268,7 +268,7 @@ namespace std return formatter::format(RE::FormTypeToString(a_formType), a_ctx); } }; -} // namespace std +} #endif #define SF_FORMTYPE(TYPE) \ diff --git a/CommonLibSF/include/RE/I/IAnimationGraphManagerHolder.h b/CommonLibSF/include/RE/I/IAnimationGraphManagerHolder.h index 715dad35..f539c114 100644 --- a/CommonLibSF/include/RE/I/IAnimationGraphManagerHolder.h +++ b/CommonLibSF/include/RE/I/IAnimationGraphManagerHolder.h @@ -33,4 +33,4 @@ namespace RE virtual void Unk_17(); // 17 virtual void Unk_18(); // 18 }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/I/IFunction.h b/CommonLibSF/include/RE/I/IFunction.h index 7f323c02..b7db52cb 100644 --- a/CommonLibSF/include/RE/I/IFunction.h +++ b/CommonLibSF/include/RE/I/IFunction.h @@ -57,5 +57,5 @@ namespace RE BSIntrusiveRefCounted refCount; // 08 }; static_assert(sizeof(IFunction) == 0x10); - } // namespace BSScript -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/I/IKeywordFormBase.h b/CommonLibSF/include/RE/I/IKeywordFormBase.h index 79d052b9..73fb26fc 100644 --- a/CommonLibSF/include/RE/I/IKeywordFormBase.h +++ b/CommonLibSF/include/RE/I/IKeywordFormBase.h @@ -18,4 +18,4 @@ namespace RE virtual bool HasKeyword(const BGSKeyword* a_keyword, const TBO_InstanceData* a_data); virtual void CollectAllKeywords(void* /* BSScrapArray */ a_refOutKeywordA, const TBO_InstanceData* a_data); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/I/IMovementInterface.h b/CommonLibSF/include/RE/I/IMovementInterface.h index e603add4..c34b3024 100644 --- a/CommonLibSF/include/RE/I/IMovementInterface.h +++ b/CommonLibSF/include/RE/I/IMovementInterface.h @@ -8,4 +8,4 @@ namespace RE virtual ~IMovementInterface(); // 00 }; static_assert(sizeof(IMovementInterface) == 0x8); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/I/INIPrefSettingCollection.h b/CommonLibSF/include/RE/I/INIPrefSettingCollection.h index 7e62cf3b..5aa6455e 100644 --- a/CommonLibSF/include/RE/I/INIPrefSettingCollection.h +++ b/CommonLibSF/include/RE/I/INIPrefSettingCollection.h @@ -18,4 +18,4 @@ namespace RE virtual ~INIPrefSettingCollection(); }; static_assert(sizeof(INIPrefSettingCollection) == 0x160); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/I/INISettingCollection.h b/CommonLibSF/include/RE/I/INISettingCollection.h index 04d40756..99aff445 100644 --- a/CommonLibSF/include/RE/I/INISettingCollection.h +++ b/CommonLibSF/include/RE/I/INISettingCollection.h @@ -18,4 +18,4 @@ namespace RE virtual ~INISettingCollection(); }; static_assert(sizeof(INISettingCollection) == 0x160); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/I/IPostAnimationChannelUpdateFunctor.h b/CommonLibSF/include/RE/I/IPostAnimationChannelUpdateFunctor.h index 79a6b6ab..b54c7402 100644 --- a/CommonLibSF/include/RE/I/IPostAnimationChannelUpdateFunctor.h +++ b/CommonLibSF/include/RE/I/IPostAnimationChannelUpdateFunctor.h @@ -13,4 +13,4 @@ namespace RE virtual void DoPostAnimationChannelUpdate() = 0; // 01 }; static_assert(sizeof(IPostAnimationChannelUpdateFunctor) == 0x8); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/M/MenuOpenCloseEvent.h b/CommonLibSF/include/RE/M/MenuOpenCloseEvent.h index 02b1c240..d6f9f639 100644 --- a/CommonLibSF/include/RE/M/MenuOpenCloseEvent.h +++ b/CommonLibSF/include/RE/M/MenuOpenCloseEvent.h @@ -12,4 +12,4 @@ namespace RE bool opening; // 08 }; static_assert(sizeof(MenuOpenCloseEvent) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/N/NativeFunction.h b/CommonLibSF/include/RE/N/NativeFunction.h index 6ed5a694..d078c936 100644 --- a/CommonLibSF/include/RE/N/NativeFunction.h +++ b/CommonLibSF/include/RE/N/NativeFunction.h @@ -31,5 +31,5 @@ namespace RE void* _callback; // 50 }; static_assert(sizeof(NativeFunction) == 0x60); - } // namespace BSScript -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/N/NativeFunctionBase.h b/CommonLibSF/include/RE/N/NativeFunctionBase.h index 945d6710..ae5a7130 100644 --- a/CommonLibSF/include/RE/N/NativeFunctionBase.h +++ b/CommonLibSF/include/RE/N/NativeFunctionBase.h @@ -132,6 +132,6 @@ namespace RE BSFixedString _docString; // 48 }; static_assert(sizeof(NativeFunctionBase) == 0x50); - } // namespace NF_util - } // namespace BSScript -} // namespace RE + } + } +} diff --git a/CommonLibSF/include/RE/N/NiPoint3.h b/CommonLibSF/include/RE/N/NiPoint3.h index fe6b775a..9fd85f8b 100644 --- a/CommonLibSF/include/RE/N/NiPoint3.h +++ b/CommonLibSF/include/RE/N/NiPoint3.h @@ -52,4 +52,4 @@ namespace RE std::array padding; // 0xC }; static_assert(sizeof(NiPoint3A) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/N/NiSmartPointer.h b/CommonLibSF/include/RE/N/NiSmartPointer.h index d668f21c..22485ac4 100644 --- a/CommonLibSF/include/RE/N/NiSmartPointer.h +++ b/CommonLibSF/include/RE/N/NiSmartPointer.h @@ -172,7 +172,7 @@ namespace RE template NiPointer(T*) -> NiPointer; -} // namespace RE +} #define NiSmartPointer(className) \ class className; \ diff --git a/CommonLibSF/include/RE/Offsets_RTTI.h b/CommonLibSF/include/RE/Offsets_RTTI.h index 0436ae37..9414714e 100644 --- a/CommonLibSF/include/RE/Offsets_RTTI.h +++ b/CommonLibSF/include/RE/Offsets_RTTI.h @@ -31715,5 +31715,5 @@ namespace RE inline constexpr REL::ID winrt__impl__delegate_winrt__Windows__Foundation__EventHandler_winrt__Windows__Gaming__Input__Gamepad___lambda_a466c087e9cd272369893bc050bef422__{ 811143 }; inline constexpr REL::ID winrt__impl__implements_delegate_winrt__Windows__Foundation__EventHandler_winrt__Windows__Gaming__Input__Gamepad___lambda_a466c087e9cd272369893bc050bef422__{ 811147 }; inline constexpr REL::ID winrt__impl__make_marshaler__2__marshaler{ 811144 }; - } // namespace RTTI -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/Offsets_VTABLE.h b/CommonLibSF/include/RE/Offsets_VTABLE.h index 56a1daf3..b6506857 100644 --- a/CommonLibSF/include/RE/Offsets_VTABLE.h +++ b/CommonLibSF/include/RE/Offsets_VTABLE.h @@ -22374,5 +22374,5 @@ namespace RE inline constexpr std::array type_info{ REL::ID(284559) }; inline constexpr std::array winrt__impl__delegate_winrt__Windows__Foundation__EventHandler_winrt__Windows__Gaming__Input__Gamepad___lambda_a466c087e9cd272369893bc050bef422__{ REL::ID(438927) }; inline constexpr std::array winrt__impl__make_marshaler__2__marshaler{ REL::ID(438935) }; - } // namespace VTABLE -} // namespace RE + } +} diff --git a/CommonLibSF/include/RE/P/PlayerCamera.h b/CommonLibSF/include/RE/P/PlayerCamera.h index e8e5d466..f01b1d3f 100644 --- a/CommonLibSF/include/RE/P/PlayerCamera.h +++ b/CommonLibSF/include/RE/P/PlayerCamera.h @@ -16,7 +16,7 @@ namespace RE struct TakeOffEvent; struct DockEvent; struct LandedSetEvent; - } // namespace Spaceship + } struct CameraStates { @@ -83,4 +83,4 @@ namespace RE private: bool QCameraEquals(CameraState a_cameraState) const; }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/R/RegSettingCollection.h b/CommonLibSF/include/RE/R/RegSettingCollection.h index 5e6808f6..1653c2b5 100644 --- a/CommonLibSF/include/RE/R/RegSettingCollection.h +++ b/CommonLibSF/include/RE/R/RegSettingCollection.h @@ -12,4 +12,4 @@ namespace RE virtual ~RegSettingCollection(); }; static_assert(sizeof(RegSettingCollection) == 0x160); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/RTTI.h b/CommonLibSF/include/RE/RTTI.h index 6b9b17cc..c976b231 100644 --- a/CommonLibSF/include/RE/RTTI.h +++ b/CommonLibSF/include/RE/RTTI.h @@ -22,7 +22,7 @@ namespace RE }; static_assert(sizeof(type_info) == 0x18); - } // namespace msvc + } namespace RTTI { @@ -133,7 +133,7 @@ namespace RE }; static_assert(sizeof(CompleteObjectLocator) == 0x14); - } // namespace RTTI + } inline void* RTDynamicCast(void* a_inptr, std::int32_t a_vfDelta, void* a_srcType, void* a_targetType, std::int32_t a_isReference) { @@ -185,8 +185,8 @@ namespace RE template inline constexpr bool cast_is_valid_v = cast_is_valid::value; - } // namespace detail -} // namespace RE + } +} template , int> = 0> To starfield_cast(From* a_from) diff --git a/CommonLibSF/include/RE/S/Script.h b/CommonLibSF/include/RE/S/Script.h index 54e150be..68591400 100644 --- a/CommonLibSF/include/RE/S/Script.h +++ b/CommonLibSF/include/RE/S/Script.h @@ -202,4 +202,4 @@ namespace RE BSSimpleList variables; // 4C }; static_assert(sizeof(Script) == 0x60); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/S/SettingCollection.h b/CommonLibSF/include/RE/S/SettingCollection.h index 1991ead8..1a73d4f1 100644 --- a/CommonLibSF/include/RE/S/SettingCollection.h +++ b/CommonLibSF/include/RE/S/SettingCollection.h @@ -33,4 +33,4 @@ namespace RE std::uint64_t unk130; // 130 }; extern template class SettingCollection; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/S/SettingCollectionList.h b/CommonLibSF/include/RE/S/SettingCollectionList.h index 5043e0e8..c38763d6 100644 --- a/CommonLibSF/include/RE/S/SettingCollectionList.h +++ b/CommonLibSF/include/RE/S/SettingCollectionList.h @@ -14,4 +14,4 @@ namespace RE BSSimpleList settings; // 118 }; extern template class SettingCollectionList; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/S/SettingCollectionMap.h b/CommonLibSF/include/RE/S/SettingCollectionMap.h index 7982d90d..f5bdcc11 100644 --- a/CommonLibSF/include/RE/S/SettingCollectionMap.h +++ b/CommonLibSF/include/RE/S/SettingCollectionMap.h @@ -27,4 +27,4 @@ namespace RE void* /* BSTBTree */ settings; // 118 }; extern template class SettingCollectionMap; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/S/Settings.h b/CommonLibSF/include/RE/S/Settings.h index 87e69687..e432c280 100644 --- a/CommonLibSF/include/RE/S/Settings.h +++ b/CommonLibSF/include/RE/S/Settings.h @@ -61,4 +61,4 @@ namespace RE extern template class SettingT; extern template class SettingT; extern template class SettingT; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TBO_InstanceData.h b/CommonLibSF/include/RE/T/TBO_InstanceData.h index 4a56db1c..fb529bf7 100644 --- a/CommonLibSF/include/RE/T/TBO_InstanceData.h +++ b/CommonLibSF/include/RE/T/TBO_InstanceData.h @@ -12,4 +12,4 @@ namespace RE virtual ~TBO_InstanceData() = default; // 00 }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESAIForm.h b/CommonLibSF/include/RE/T/TESAIForm.h index 37ef3800..17de5136 100644 --- a/CommonLibSF/include/RE/T/TESAIForm.h +++ b/CommonLibSF/include/RE/T/TESAIForm.h @@ -38,4 +38,4 @@ namespace RE PackageList aiPackList; // 18 }; static_assert(sizeof(TESAIForm) == 0x40); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESActorBase.h b/CommonLibSF/include/RE/T/TESActorBase.h index 63f3efbd..4619701f 100644 --- a/CommonLibSF/include/RE/T/TESActorBase.h +++ b/CommonLibSF/include/RE/T/TESActorBase.h @@ -70,4 +70,4 @@ namespace RE static_assert(offsetof(TESActorBase, perkRankArray) == 0x270); static_assert(offsetof(TESActorBase, propertySheet) == 0x288); */ -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESActorBaseData.h b/CommonLibSF/include/RE/T/TESActorBaseData.h index 53c97410..c454d2bc 100644 --- a/CommonLibSF/include/RE/T/TESActorBaseData.h +++ b/CommonLibSF/include/RE/T/TESActorBaseData.h @@ -55,4 +55,4 @@ namespace RE std::uint64_t unk68; // 68 }; static_assert(sizeof(TESActorBaseData) == 0x70); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESBoundAnimObject.h b/CommonLibSF/include/RE/T/TESBoundAnimObject.h index 9d127138..3b5b8a5e 100644 --- a/CommonLibSF/include/RE/T/TESBoundAnimObject.h +++ b/CommonLibSF/include/RE/T/TESBoundAnimObject.h @@ -23,4 +23,4 @@ namespace RE std::uint64_t unk110; // 110 }; static_assert(sizeof(TESBoundAnimObject) == 0x118); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESBoundObject.h b/CommonLibSF/include/RE/T/TESBoundObject.h index 1f7edfed..122e2c81 100644 --- a/CommonLibSF/include/RE/T/TESBoundObject.h +++ b/CommonLibSF/include/RE/T/TESBoundObject.h @@ -50,4 +50,4 @@ namespace RE static_assert(offsetof(TESBoundObject, previewTransform) == 0x88); static_assert(offsetof(TESBoundObject, placementDefaults) == 0xD0); static_assert(sizeof(TESBoundObject) == 0xF0); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESCamera.h b/CommonLibSF/include/RE/T/TESCamera.h index b6d01aef..b544488f 100644 --- a/CommonLibSF/include/RE/T/TESCamera.h +++ b/CommonLibSF/include/RE/T/TESCamera.h @@ -35,4 +35,4 @@ namespace RE std::uint32_t pad44; // 44 }; static_assert(sizeof(TESCamera) == 0x48); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESContainer.h b/CommonLibSF/include/RE/T/TESContainer.h index 2bca6b42..2afd1cce 100644 --- a/CommonLibSF/include/RE/T/TESContainer.h +++ b/CommonLibSF/include/RE/T/TESContainer.h @@ -16,4 +16,4 @@ namespace RE std::uint32_t numContainerObjects; // 10 }; static_assert(sizeof(TESContainer) == 0x18); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESFile.h b/CommonLibSF/include/RE/T/TESFile.h index c5f8736d..f308f3a8 100644 --- a/CommonLibSF/include/RE/T/TESFile.h +++ b/CommonLibSF/include/RE/T/TESFile.h @@ -7,4 +7,4 @@ namespace RE public: SF_RTTI_VTABLE(TESFile); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESForm.h b/CommonLibSF/include/RE/T/TESForm.h index 1ccc5640..c3b32e1a 100644 --- a/CommonLibSF/include/RE/T/TESForm.h +++ b/CommonLibSF/include/RE/T/TESForm.h @@ -200,4 +200,4 @@ namespace RE stl::enumeration formType; // 36 }; static_assert(sizeof(TESForm) == 0x38); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESFormRefCount.h b/CommonLibSF/include/RE/T/TESFormRefCount.h index 10a466cc..3b5a226a 100644 --- a/CommonLibSF/include/RE/T/TESFormRefCount.h +++ b/CommonLibSF/include/RE/T/TESFormRefCount.h @@ -21,4 +21,4 @@ namespace RE volatile mutable std::uint64_t refCount; // 08 }; static_assert(sizeof(TESFormRefCount) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESFullName.h b/CommonLibSF/include/RE/T/TESFullName.h index 5a9153be..0bc68ba8 100644 --- a/CommonLibSF/include/RE/T/TESFullName.h +++ b/CommonLibSF/include/RE/T/TESFullName.h @@ -21,4 +21,4 @@ namespace RE BGSLocalizedString fullName; // 08 - FULL }; static_assert(sizeof(TESFullName) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESHandleForm.h b/CommonLibSF/include/RE/T/TESHandleForm.h index c877301d..3965e225 100644 --- a/CommonLibSF/include/RE/T/TESHandleForm.h +++ b/CommonLibSF/include/RE/T/TESHandleForm.h @@ -13,4 +13,4 @@ namespace RE ~TESHandleForm() override; // 00 }; static_assert(sizeof(TESHandleForm) == 0x38); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESNPC.h b/CommonLibSF/include/RE/T/TESNPC.h index 103d092d..227f96fb 100644 --- a/CommonLibSF/include/RE/T/TESNPC.h +++ b/CommonLibSF/include/RE/T/TESNPC.h @@ -34,4 +34,4 @@ namespace RE static_assert(offsetof(TESNPC, forcedLocRefType) == 0x2F0); static_assert(offsetof(TESNPC, terminalForm) == 0x308); */ -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESObject.h b/CommonLibSF/include/RE/T/TESObject.h index 4d0b8f56..d743ec95 100644 --- a/CommonLibSF/include/RE/T/TESObject.h +++ b/CommonLibSF/include/RE/T/TESObject.h @@ -22,4 +22,4 @@ namespace RE virtual void Unk_6A(); // 6A virtual void Unk_6B(); // 6B }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESObjectARMO.h b/CommonLibSF/include/RE/T/TESObjectARMO.h index db97474b..522ea14f 100644 --- a/CommonLibSF/include/RE/T/TESObjectARMO.h +++ b/CommonLibSF/include/RE/T/TESObjectARMO.h @@ -11,4 +11,4 @@ namespace RE SF_RTTI_VTABLE(TESObjectARMO); SF_FORMTYPE(ARMO); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESObjectCELL.h b/CommonLibSF/include/RE/T/TESObjectCELL.h index 82dd6ed9..1a442320 100644 --- a/CommonLibSF/include/RE/T/TESObjectCELL.h +++ b/CommonLibSF/include/RE/T/TESObjectCELL.h @@ -166,4 +166,4 @@ namespace RE std::uint64_t unk148; // 148 }; static_assert(sizeof(TESObjectCELL) == 0x150); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESObjectREFR.h b/CommonLibSF/include/RE/T/TESObjectREFR.h index ab81ff58..621b2dbc 100644 --- a/CommonLibSF/include/RE/T/TESObjectREFR.h +++ b/CommonLibSF/include/RE/T/TESObjectREFR.h @@ -321,4 +321,4 @@ namespace RE std::uint8_t unk10B; // 10B }; static_assert(sizeof(TESObjectREFR) == 0x110); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESQuest.h b/CommonLibSF/include/RE/T/TESQuest.h index 38961660..abc3a5b0 100644 --- a/CommonLibSF/include/RE/T/TESQuest.h +++ b/CommonLibSF/include/RE/T/TESQuest.h @@ -8,4 +8,4 @@ namespace RE SF_RTTI_VTABLE(TESQuest); SF_FORMTYPE(QUST); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESRace.h b/CommonLibSF/include/RE/T/TESRace.h index 3e48af24..a0e24169 100644 --- a/CommonLibSF/include/RE/T/TESRace.h +++ b/CommonLibSF/include/RE/T/TESRace.h @@ -11,4 +11,4 @@ namespace RE SF_RTTI_VTABLE(TESRace); SF_FORMTYPE(RACE); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESRaceForm.h b/CommonLibSF/include/RE/T/TESRaceForm.h index 55ca8e91..1725d6e3 100644 --- a/CommonLibSF/include/RE/T/TESRaceForm.h +++ b/CommonLibSF/include/RE/T/TESRaceForm.h @@ -15,4 +15,4 @@ namespace RE TESRace* formRace; // 08 }; static_assert(sizeof(TESRaceForm) == 0x10); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESResponse.h b/CommonLibSF/include/RE/T/TESResponse.h index 3040e00a..88e5d099 100644 --- a/CommonLibSF/include/RE/T/TESResponse.h +++ b/CommonLibSF/include/RE/T/TESResponse.h @@ -17,4 +17,4 @@ namespace RE std::uint32_t unk24; // 24 }; static_assert(sizeof(TESResponse) == 0x28); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESSpellList.h b/CommonLibSF/include/RE/T/TESSpellList.h index 478901fe..38c6ca44 100644 --- a/CommonLibSF/include/RE/T/TESSpellList.h +++ b/CommonLibSF/include/RE/T/TESSpellList.h @@ -15,4 +15,4 @@ namespace RE std::uint64_t unk10; // 10 }; static_assert(sizeof(TESSpellList) == 0x18); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESTopicInfo.h b/CommonLibSF/include/RE/T/TESTopicInfo.h index 853613fd..b39887b2 100644 --- a/CommonLibSF/include/RE/T/TESTopicInfo.h +++ b/CommonLibSF/include/RE/T/TESTopicInfo.h @@ -27,4 +27,4 @@ namespace RE TESResponse* responses; // 70 }; static_assert(sizeof(TESTopicInfo) == 0x78); -} // namespace RE +} diff --git a/CommonLibSF/include/RE/T/TESWorldSpace.h b/CommonLibSF/include/RE/T/TESWorldSpace.h index 79bc2c0b..25fb8df4 100644 --- a/CommonLibSF/include/RE/T/TESWorldSpace.h +++ b/CommonLibSF/include/RE/T/TESWorldSpace.h @@ -12,4 +12,4 @@ namespace RE public: SF_FORMTYPE(WRLD); }; -} // namespace RE +} diff --git a/CommonLibSF/include/RE/U/UI.h b/CommonLibSF/include/RE/U/UI.h index dcbef19c..bee954ae 100644 --- a/CommonLibSF/include/RE/U/UI.h +++ b/CommonLibSF/include/RE/U/UI.h @@ -18,4 +18,4 @@ namespace RE return func(this, a_name); } }; -} // namespace RE +} diff --git a/CommonLibSF/include/REL/ID.h b/CommonLibSF/include/REL/ID.h index 3edd0b1a..f4adda61 100644 --- a/CommonLibSF/include/REL/ID.h +++ b/CommonLibSF/include/REL/ID.h @@ -175,7 +175,7 @@ namespace REL std::uint32_t _pointerSize{ 0 }; std::uint32_t _addressCount{ 0 }; }; - } // namespace database + } class IDDatabase { @@ -293,4 +293,4 @@ namespace REL return a_lhs.offset < a_rhs.offset; }); } -} // namespace REL +} diff --git a/CommonLibSF/include/REL/Module.h b/CommonLibSF/include/REL/Module.h index a7c06b13..c7a16ab9 100644 --- a/CommonLibSF/include/REL/Module.h +++ b/CommonLibSF/include/REL/Module.h @@ -89,4 +89,4 @@ namespace REL Version _version; std::wstring _file; }; -} // namespace REL +} diff --git a/CommonLibSF/include/REL/Offset.h b/CommonLibSF/include/REL/Offset.h index 88c39fe3..5550eccd 100644 --- a/CommonLibSF/include/REL/Offset.h +++ b/CommonLibSF/include/REL/Offset.h @@ -26,4 +26,4 @@ namespace REL private: std::ptrdiff_t _offset{ 0 }; }; -} // namespace REL +} diff --git a/CommonLibSF/include/REL/Pattern.h b/CommonLibSF/include/REL/Pattern.h index ce635052..60239886 100644 --- a/CommonLibSF/include/REL/Pattern.h +++ b/CommonLibSF/include/REL/Pattern.h @@ -23,7 +23,7 @@ namespace REL { return a_ch == '?'; } - } // namespace characters + } namespace rules { @@ -59,7 +59,7 @@ namespace REL lut[static_cast(a_hi)] * 0x10u + lut[static_cast(a_lo)]); } - } // namespace detail + } template class Hexadecimal @@ -110,7 +110,7 @@ namespace REL template Wildcard rule_for() noexcept requires(characters::wildcard(C1) && characters::wildcard(C2)); - } // namespace rules + } template class PatternMatcher @@ -203,7 +203,7 @@ namespace REL "all bytes must be an integral type"); return { static_cast(a_bytes)... }; } - } // namespace detail + } template [[nodiscard]] constexpr auto Pattern() noexcept @@ -215,4 +215,4 @@ namespace REL detail::make_byte_array(0x40, 0x10, 0xF2, 0x41))); static_assert(Pattern<"B8 D0 ?? ?? D4 6E">().match( detail::make_byte_array(0xB8, 0xD0, 0x35, 0x2A, 0xD4, 0x6E))); -} // namespace REL +} diff --git a/CommonLibSF/include/REL/Relocation.h b/CommonLibSF/include/REL/Relocation.h index b66bbaaf..e14ca8cf 100644 --- a/CommonLibSF/include/REL/Relocation.h +++ b/CommonLibSF/include/REL/Relocation.h @@ -116,7 +116,7 @@ namespace REL return func(std::forward(a_first), std::addressof(result), std::forward(a_rest)...); } - } // namespace detail + } inline constexpr std::uint8_t NOP = 0x90; inline constexpr std::uint8_t NOP2[] = { 0x66, 0x90 }; @@ -272,7 +272,7 @@ namespace REL std::uintptr_t _address{ 0 }; }; -} // namespace REL +} #undef REL_MAKE_MEMBER_FUNCTION_NON_POD_TYPE #undef REL_MAKE_MEMBER_FUNCTION_NON_POD_TYPE_HELPER diff --git a/CommonLibSF/include/REL/Version.h b/CommonLibSF/include/REL/Version.h index f4d60f53..7c945a7a 100644 --- a/CommonLibSF/include/REL/Version.h +++ b/CommonLibSF/include/REL/Version.h @@ -129,7 +129,7 @@ namespace REL return position * 10; } } - } // namespace detail + } template [[nodiscard]] constexpr REL::Version operator""_v() noexcept @@ -143,7 +143,7 @@ namespace REL { return Version(std::string_view(str, len)); } - } // namespace literals + } [[nodiscard]] std::optional get_file_version(stl::zwstring a_filename); -} // namespace REL +} diff --git a/CommonLibSF/include/SFSE/API.h b/CommonLibSF/include/SFSE/API.h index 95b7fc61..a3595921 100644 --- a/CommonLibSF/include/SFSE/API.h +++ b/CommonLibSF/include/SFSE/API.h @@ -20,4 +20,4 @@ namespace SFSE Trampoline& GetTrampoline(); void AllocTrampoline(std::size_t a_size, bool a_trySFSEReserve = true); -} // namespace SFSE +} diff --git a/CommonLibSF/include/SFSE/IAT.h b/CommonLibSF/include/SFSE/IAT.h index ace2360a..06e02545 100644 --- a/CommonLibSF/include/SFSE/IAT.h +++ b/CommonLibSF/include/SFSE/IAT.h @@ -28,4 +28,4 @@ namespace SFSE { return PatchIAT(stl::unrestricted_cast(a_newFunc), a_dll, a_function); } -} // namespace SFSE +} diff --git a/CommonLibSF/include/SFSE/Impl/DInputAPI.h b/CommonLibSF/include/SFSE/Impl/DInputAPI.h index 332ff4ae..eeb7ce19 100644 --- a/CommonLibSF/include/SFSE/Impl/DInputAPI.h +++ b/CommonLibSF/include/SFSE/Impl/DInputAPI.h @@ -592,4 +592,4 @@ namespace RE::DirectInput8 virtual HRESULT ConfigureDevices(LPDICONFIGUREDEVICESCALLBACK, DICONFIGUREDEVICESPARAMSA*, std::uint32_t, void*) noexcept = 0; }; -} // namespace RE::DirectInput8 +} diff --git a/CommonLibSF/include/SFSE/Impl/PCH.h b/CommonLibSF/include/SFSE/Impl/PCH.h index e7e8800e..24456436 100644 --- a/CommonLibSF/include/SFSE/Impl/PCH.h +++ b/CommonLibSF/include/SFSE/Impl/PCH.h @@ -237,7 +237,7 @@ namespace SFSE template string(const CharT (&)[N]) -> string; - } // namespace nttp + } template requires(std::invocable>) @@ -394,8 +394,8 @@ namespace SFSE template enumeration(Args...) -> enumeration, std::underlying_type_t>>; - } // namespace stl -} // namespace SFSE + } +} #define SFSE_MAKE_LOGICAL_OP(a_op, a_result) \ template \ @@ -732,8 +732,8 @@ namespace SFSE return to; } } - } // namespace stl -} // namespace SFSE + } +} #undef SFSE_MAKE_INCREMENTER_OP #undef SFSE_MAKE_ENUMERATION_OP @@ -745,14 +745,14 @@ namespace RE using namespace std::literals; namespace stl = SFSE::stl; namespace WinAPI = SFSE::WinAPI; -} // namespace RE +} namespace REL { using namespace std::literals; namespace stl = SFSE::stl; namespace WinAPI = SFSE::WinAPI; -} // namespace REL +} #include "REL/REL.h" diff --git a/CommonLibSF/include/SFSE/Impl/Stubs.h b/CommonLibSF/include/SFSE/Impl/Stubs.h index 76a77ceb..eff493c9 100644 --- a/CommonLibSF/include/SFSE/Impl/Stubs.h +++ b/CommonLibSF/include/SFSE/Impl/Stubs.h @@ -47,5 +47,5 @@ namespace SFSE std::uint32_t interfaceVersion; void (*Register)(void*); }; - } // namespace detail -} // namespace SFSE + } +} diff --git a/CommonLibSF/include/SFSE/Impl/WinAPI.h b/CommonLibSF/include/SFSE/Impl/WinAPI.h index e822efdb..cd3e0a5a 100644 --- a/CommonLibSF/include/SFSE/Impl/WinAPI.h +++ b/CommonLibSF/include/SFSE/Impl/WinAPI.h @@ -1191,7 +1191,7 @@ namespace SFSE::WinAPI const void* a_buffer, std::size_t a_bufferLen, std::size_t* a_bufferWritten) noexcept; -} // namespace SFSE::WinAPI +} #endif // _INC_WINAPIFAMILY @@ -1204,4 +1204,4 @@ namespace RE::DirectX float m[4][4]; }; static_assert(sizeof(XMFLOAT4X4) == 0x40); -} // namespace RE::DirectX +} diff --git a/CommonLibSF/include/SFSE/Impl/XInputAPI.h b/CommonLibSF/include/SFSE/Impl/XInputAPI.h index 9c63995f..df3578d7 100644 --- a/CommonLibSF/include/SFSE/Impl/XInputAPI.h +++ b/CommonLibSF/include/SFSE/Impl/XInputAPI.h @@ -77,4 +77,4 @@ namespace RE::XInput static constexpr std::uint8_t XINPUT_GAMEPAD_TRIGGER_THRESHOLD = 30; static constexpr std::uint16_t XINPUT_BUTTON_MASK = XINPUT_GAMEPAD_DPAD_UP | XINPUT_GAMEPAD_DPAD_DOWN | XINPUT_GAMEPAD_DPAD_LEFT | XINPUT_GAMEPAD_DPAD_RIGHT | XINPUT_GAMEPAD_START | XINPUT_GAMEPAD_BACK | XINPUT_GAMEPAD_LEFT_THUMB | XINPUT_GAMEPAD_RIGHT_THUMB | XINPUT_GAMEPAD_LEFT_SHOULDER | XINPUT_GAMEPAD_RIGHT_SHOULDER | XINPUT_GAMEPAD_A | XINPUT_GAMEPAD_B | XINPUT_GAMEPAD_X | XINPUT_GAMEPAD_Y; -} // namespace RE::XInput +} diff --git a/CommonLibSF/include/SFSE/InputMap.h b/CommonLibSF/include/SFSE/InputMap.h index c46e089e..62973c66 100644 --- a/CommonLibSF/include/SFSE/InputMap.h +++ b/CommonLibSF/include/SFSE/InputMap.h @@ -49,5 +49,5 @@ namespace SFSE std::string GetKeyboardKeyName(std::uint32_t keyCode); std::string GetMouseButtonName(std::uint32_t keyCode); std::string GetGamepadButtonName(std::uint32_t a_keyCode); - } // namespace InputMap -} // namespace SFSE + } +} diff --git a/CommonLibSF/include/SFSE/Interfaces.h b/CommonLibSF/include/SFSE/Interfaces.h index 8c22a1d7..d55bd9e6 100644 --- a/CommonLibSF/include/SFSE/Interfaces.h +++ b/CommonLibSF/include/SFSE/Interfaces.h @@ -203,7 +203,7 @@ namespace SFSE static_assert(offsetof(PluginVersionData, reservedNonBreaking) == 0x254); static_assert(offsetof(PluginVersionData, reservedBreaking) == 0x258); static_assert(sizeof(PluginVersionData) == 0x25C); -} // namespace SFSE +} #define SFSEPluginPreload(...) extern "C" [[maybe_unused]] __declspec(dllexport) bool SFSEPlugin_Preload(__VA_ARGS__) #define SFSEPluginLoad(...) extern "C" [[maybe_unused]] __declspec(dllexport) bool SFSEPlugin_Load(__VA_ARGS__) diff --git a/CommonLibSF/include/SFSE/Logger.h b/CommonLibSF/include/SFSE/Logger.h index 37768552..834eb187 100644 --- a/CommonLibSF/include/SFSE/Logger.h +++ b/CommonLibSF/include/SFSE/Logger.h @@ -27,6 +27,6 @@ namespace SFSE::log [[nodiscard]] std::optional log_directory(); void init(); -} // namespace SFSE::log +} #undef SFSE_MAKE_SOURCE_LOGGER diff --git a/CommonLibSF/include/SFSE/Trampoline.h b/CommonLibSF/include/SFSE/Trampoline.h index af3df5e7..db3617c2 100644 --- a/CommonLibSF/include/SFSE/Trampoline.h +++ b/CommonLibSF/include/SFSE/Trampoline.h @@ -30,7 +30,7 @@ namespace SFSE const auto remainder = a_number % a_multiple; return remainder == 0 ? a_number : a_number - remainder; } - } // namespace detail + } class Trampoline { @@ -352,4 +352,4 @@ namespace SFSE std::size_t _capacity{ 0 }; std::size_t _size{ 0 }; }; -} // namespace SFSE +} diff --git a/CommonLibSF/include/SFSE/Utilities.h b/CommonLibSF/include/SFSE/Utilities.h index 1a3c3e32..4bb87ac9 100644 --- a/CommonLibSF/include/SFSE/Utilities.h +++ b/CommonLibSF/include/SFSE/Utilities.h @@ -33,5 +33,5 @@ namespace SFSE { write_vfunc(To::VTABLE[a_vtableIdx]); } - } // namespace stl -} // namespace SFSE + } +} diff --git a/CommonLibSF/include/SFSE/Version.h b/CommonLibSF/include/SFSE/Version.h index e7f68b75..af4c397e 100644 --- a/CommonLibSF/include/SFSE/Version.h +++ b/CommonLibSF/include/SFSE/Version.h @@ -9,4 +9,4 @@ namespace SFSE constexpr auto RUNTIME_LATEST = RUNTIME_SF_1_7_33; constexpr REL::Version SFSE_PACK_LATEST(0, 1, 3, 0); -} // namespace SFSE +} diff --git a/CommonLibSF/src/RE/F/FormTypes.cpp b/CommonLibSF/src/RE/F/FormTypes.cpp index 3a759419..eff4c0d3 100644 --- a/CommonLibSF/src/RE/F/FormTypes.cpp +++ b/CommonLibSF/src/RE/F/FormTypes.cpp @@ -19,4 +19,4 @@ namespace RE return FormType::kNONE; } -} // namespace RE +} diff --git a/CommonLibSF/src/RE/N/NiPoint3.cpp b/CommonLibSF/src/RE/N/NiPoint3.cpp index 3d361f85..6375930a 100644 --- a/CommonLibSF/src/RE/N/NiPoint3.cpp +++ b/CommonLibSF/src/RE/N/NiPoint3.cpp @@ -157,4 +157,4 @@ namespace RE } return length; } -} // namespace RE +} diff --git a/CommonLibSF/src/RE/P/PlayerCamera.cpp b/CommonLibSF/src/RE/P/PlayerCamera.cpp index d1893c63..3ba8332e 100644 --- a/CommonLibSF/src/RE/P/PlayerCamera.cpp +++ b/CommonLibSF/src/RE/P/PlayerCamera.cpp @@ -45,4 +45,4 @@ namespace RE REL::Relocation func{ REL::ID(166081) }; return func(this, a_cameraState); } -} // namespace RE +} diff --git a/CommonLibSF/src/RE/T/TESFormRefCount.cpp b/CommonLibSF/src/RE/T/TESFormRefCount.cpp index 64142067..8eac967f 100644 --- a/CommonLibSF/src/RE/T/TESFormRefCount.cpp +++ b/CommonLibSF/src/RE/T/TESFormRefCount.cpp @@ -12,4 +12,4 @@ namespace RE { return refCount & kRefCountMask; } -} // namespace RE +} diff --git a/CommonLibSF/src/RE/T/TESObjectREFR.cpp b/CommonLibSF/src/RE/T/TESObjectREFR.cpp index 47cf913a..32376083 100644 --- a/CommonLibSF/src/RE/T/TESObjectREFR.cpp +++ b/CommonLibSF/src/RE/T/TESObjectREFR.cpp @@ -79,4 +79,4 @@ namespace RE return func(this); } -} // namespace RE +} diff --git a/CommonLibSF/src/REL/ID.cpp b/CommonLibSF/src/REL/ID.cpp index ac1e0b4e..63cb7a8d 100644 --- a/CommonLibSF/src/REL/ID.cpp +++ b/CommonLibSF/src/REL/ID.cpp @@ -142,7 +142,7 @@ namespace REL _version[i] = static_cast(version[i]); } } - } // namespace database + } [[nodiscard]] std::size_t IDDatabase::id2offset(std::uint64_t a_id) const { @@ -349,4 +349,4 @@ namespace REL } IDDatabase IDDatabase::_instance; -} // namespace REL +} diff --git a/CommonLibSF/src/REL/Module.cpp b/CommonLibSF/src/REL/Module.cpp index 06bc4a3d..68cb388d 100644 --- a/CommonLibSF/src/REL/Module.cpp +++ b/CommonLibSF/src/REL/Module.cpp @@ -57,4 +57,4 @@ namespace REL const auto base = AsAddress(WinAPI::GetModuleHandle(a_filePath.empty() ? WinAPI::GetProcPath(nullptr).data() : a_filePath.data())); return get(base); } -} // namespace REL +} diff --git a/CommonLibSF/src/REL/Version.cpp b/CommonLibSF/src/REL/Version.cpp index 15c110a6..a7e088b1 100644 --- a/CommonLibSF/src/REL/Version.cpp +++ b/CommonLibSF/src/REL/Version.cpp @@ -55,4 +55,4 @@ namespace REL return version; } -} // namespace REL +} diff --git a/CommonLibSF/src/SFSE/API.cpp b/CommonLibSF/src/SFSE/API.cpp index 3239fcf2..b89d35e0 100644 --- a/CommonLibSF/src/SFSE/API.cpp +++ b/CommonLibSF/src/SFSE/API.cpp @@ -44,7 +44,7 @@ namespace SFSE } return result; } - } // namespace detail + } void Init(const LoadInterface* a_intfc, bool a_log) noexcept { @@ -129,4 +129,4 @@ namespace SFSE trampoline.create(a_size); } -} // namespace SFSE +} diff --git a/CommonLibSF/src/SFSE/IAT.cpp b/CommonLibSF/src/SFSE/IAT.cpp index 987d94b5..39cca617 100644 --- a/CommonLibSF/src/SFSE/IAT.cpp +++ b/CommonLibSF/src/SFSE/IAT.cpp @@ -70,4 +70,4 @@ namespace SFSE return origAddr; } -} // namespace SFSE +} diff --git a/CommonLibSF/src/SFSE/Impl/WinAPI.cpp b/CommonLibSF/src/SFSE/Impl/WinAPI.cpp index e0d3b5e7..70d49cc2 100644 --- a/CommonLibSF/src/SFSE/Impl/WinAPI.cpp +++ b/CommonLibSF/src/SFSE/Impl/WinAPI.cpp @@ -1048,4 +1048,4 @@ namespace SFSE::WinAPI static_cast<::SIZE_T>(a_bufferLen), static_cast<::SIZE_T*>(a_bufferWritten))); } -} // namespace SFSE::WinAPI +} diff --git a/CommonLibSF/src/SFSE/InputMap.cpp b/CommonLibSF/src/SFSE/InputMap.cpp index d27c49b3..35de7dba 100644 --- a/CommonLibSF/src/SFSE/InputMap.cpp +++ b/CommonLibSF/src/SFSE/InputMap.cpp @@ -229,4 +229,4 @@ namespace SFSE return ""s; } } -} // namespace SFSE +} diff --git a/CommonLibSF/src/SFSE/Interfaces.cpp b/CommonLibSF/src/SFSE/Interfaces.cpp index f71a89b4..19dbd177 100644 --- a/CommonLibSF/src/SFSE/Interfaces.cpp +++ b/CommonLibSF/src/SFSE/Interfaces.cpp @@ -116,4 +116,4 @@ namespace SFSE { return reinterpret_cast(WinAPI::GetProcAddress(WinAPI::GetCurrentModule(), "SFSEPlugin_Version")); } -} // namespace SFSE +} diff --git a/CommonLibSF/src/SFSE/Logger.cpp b/CommonLibSF/src/SFSE/Logger.cpp index 6ecfc688..36fa460e 100644 --- a/CommonLibSF/src/SFSE/Logger.cpp +++ b/CommonLibSF/src/SFSE/Logger.cpp @@ -48,5 +48,5 @@ namespace SFSE spdlog::set_default_logger(std::move(logger)); spdlog::set_pattern("[%T.%e] [%=5t] [%L] %v"); } - } // namespace log -} // namespace SFSE + } +} diff --git a/CommonLibSF/src/SFSE/Trampoline.cpp b/CommonLibSF/src/SFSE/Trampoline.cpp index 4b10ecad..4c06af48 100644 --- a/CommonLibSF/src/SFSE/Trampoline.cpp +++ b/CommonLibSF/src/SFSE/Trampoline.cpp @@ -72,4 +72,4 @@ namespace SFSE auto pct = (static_cast(_size) / static_cast(_capacity)) * 100.0; log::debug("{} => {}B / {}B ({:05.2f}%)"sv, _name, _size, _capacity, pct); } -} // namespace SFSE +} From 9789a9f50b1faee4592e8ce4cc6f79255794b9b3 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 17:56:05 +0000 Subject: [PATCH 10/21] ci: maintenance `2023-09-29.3` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index 980ad28b..b4c6fa74 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29.2", + "version-date": "2023-09-29.3", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index b271b3af..3e656ded 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.2&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.3&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 61568f7bf2c10dbf6eb62b89afb3fbb458b1368a Mon Sep 17 00:00:00 2001 From: Qudix <17361645+Qudix@users.noreply.github.com> Date: Fri, 29 Sep 2023 13:02:27 -0500 Subject: [PATCH 11/21] chore: remove empty compilation units (#123) - from a previous pr --- CommonLibSF/src/RE/A/AIProcess.cpp | 4 ---- CommonLibSF/src/RE/A/ActorPackage.cpp | 4 ---- 2 files changed, 8 deletions(-) delete mode 100644 CommonLibSF/src/RE/A/AIProcess.cpp delete mode 100644 CommonLibSF/src/RE/A/ActorPackage.cpp diff --git a/CommonLibSF/src/RE/A/AIProcess.cpp b/CommonLibSF/src/RE/A/AIProcess.cpp deleted file mode 100644 index b32c10c0..00000000 --- a/CommonLibSF/src/RE/A/AIProcess.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/A/AIProcess.h" -namespace RE -{ -} diff --git a/CommonLibSF/src/RE/A/ActorPackage.cpp b/CommonLibSF/src/RE/A/ActorPackage.cpp deleted file mode 100644 index df6390af..00000000 --- a/CommonLibSF/src/RE/A/ActorPackage.cpp +++ /dev/null @@ -1,4 +0,0 @@ -#include "RE/A/ActorPackage.h" -namespace RE -{ -} From 81721af15417660eec8d4a9d6c6706f0551e487d Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 18:02:55 +0000 Subject: [PATCH 12/21] ci: maintenance `2023-09-29.4` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index b4c6fa74..f5e24727 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29.3", + "version-date": "2023-09-29.4", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index 3e656ded..432d6d55 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.3&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.4&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 3c708d02c9f50380df2d05498bd71033f7949e45 Mon Sep 17 00:00:00 2001 From: powerof3 <32599957+powerof3@users.noreply.github.com> Date: Sat, 30 Sep 2023 01:45:38 +0530 Subject: [PATCH 13/21] feat: add `BSTEventSource` members (#124) --- CommonLibSF/include/RE/B/BSTEvent.h | 8 ++++++++ CommonLibSF/include/RE/T/TESObjectREFR.h | 20 +++++++------------- 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/CommonLibSF/include/RE/B/BSTEvent.h b/CommonLibSF/include/RE/B/BSTEvent.h index 98710af8..fe4379d5 100644 --- a/CommonLibSF/include/RE/B/BSTEvent.h +++ b/CommonLibSF/include/RE/B/BSTEvent.h @@ -67,7 +67,15 @@ namespace RE REL::Relocation func{ REL::ID(34451) }; return func(this, a_sink); } + + // members + std::uint8_t sinks[0x10]; // 08 - BSTArray> + std::uint32_t unk18; // 18 + std::uint32_t unk1C; // 1C + std::uint32_t unk20; // 20 + std::uint32_t unk24; // 24 }; + static_assert(sizeof(BSTEventSource) == 0x28); class BSTGlobalEvent { diff --git a/CommonLibSF/include/RE/T/TESObjectREFR.h b/CommonLibSF/include/RE/T/TESObjectREFR.h index 621b2dbc..666dcd34 100644 --- a/CommonLibSF/include/RE/T/TESObjectREFR.h +++ b/CommonLibSF/include/RE/T/TESObjectREFR.h @@ -302,19 +302,13 @@ namespace RE [[nodiscard]] bool IsSpaceshipDocked(); // members - std::uint32_t unk80; // 80 - std::uint32_t unk84; // 84 - std::uint64_t unk88; // 88 - std::uint64_t unk90; // 90 - std::uint32_t unk98; // 98 - std::uint8_t pad9C[4]; // 9C - OBJ_REFR data; // A0 - std::uint64_t unkD0; // D0 - std::uint64_t unkD8; // D8 - TESObjectCELL* parentCell; // E0 - void* loadedData; // E8 - std::uint64_t unkF0; // F0 - std::uint64_t extraDataList; // F8 + OBJ_REFR data; // 0A0 + std::uint64_t unkD0; // 0D0 + std::uint64_t unkD8; // 0D8 + TESObjectCELL* parentCell; // 0E0 + void* loadedData; // 0E8 + std::uint64_t unkF0; // 0F0 + std::uint64_t extraDataList; // 0F8 std::uint64_t unk100; // 100 std::uint16_t scale; // 108 std::uint8_t unk10A; // 10A From fc15f0db19fe4eecab70e8fc34a8df860940d94c Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 29 Sep 2023 20:16:21 +0000 Subject: [PATCH 14/21] ci: maintenance `2023-09-29.5` --- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index f5e24727..00e1c0ec 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29.4", + "version-date": "2023-09-29.5", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index 432d6d55..753ca3d0 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.4&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.5&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 0ed898fc675d31936b284c4c1416e7e6a2178053 Mon Sep 17 00:00:00 2001 From: powerof3 <32599957+powerof3@users.noreply.github.com> Date: Sat, 30 Sep 2023 13:19:39 +0530 Subject: [PATCH 15/21] feat!: `TESObjectREFR`, `Actor`, `PlayerCharacter` RE (#125) ### Breaking Changes - `Actor::PlayerCharacter()` to `PlayerCharacter::GetSingleton()` - `Actor::IsPlayerCharacterInChargen()` to `PlayerCharacter::IsInChargen()` --- CommonLibSF/include/RE/A/Actor.h | 387 +++++++++------- CommonLibSF/include/RE/A/ActorState.h | 25 ++ .../RE/I/IMovementPlayerControlsFilter.h | 29 ++ CommonLibSF/include/RE/I/IMovementState.h | 65 +++ .../include/RE/I/IMovementStateStore.h | 18 + .../include/RE/I/IStoreAnimationActions.h | 20 + CommonLibSF/include/RE/M/MagicTarget.h | 45 ++ CommonLibSF/include/RE/P/PlayerCharacter.h | 421 ++++++++++++++++++ CommonLibSF/include/RE/T/TESObjectREFR.h | 7 +- 9 files changed, 863 insertions(+), 154 deletions(-) create mode 100644 CommonLibSF/include/RE/A/ActorState.h create mode 100644 CommonLibSF/include/RE/I/IMovementPlayerControlsFilter.h create mode 100644 CommonLibSF/include/RE/I/IMovementState.h create mode 100644 CommonLibSF/include/RE/I/IMovementStateStore.h create mode 100644 CommonLibSF/include/RE/I/IStoreAnimationActions.h create mode 100644 CommonLibSF/include/RE/M/MagicTarget.h create mode 100644 CommonLibSF/include/RE/P/PlayerCharacter.h diff --git a/CommonLibSF/include/RE/A/Actor.h b/CommonLibSF/include/RE/A/Actor.h index ce642c0e..c8cf3dcd 100644 --- a/CommonLibSF/include/RE/A/Actor.h +++ b/CommonLibSF/include/RE/A/Actor.h @@ -1,36 +1,153 @@ #pragma once #include "RE/A/AIProcess.h" -#include "RE/A/ActorPackage.h" +#include "RE/A/ActorState.h" +#include "RE/I/IMovementStateStore.h" +#include "RE/I/IStoreAnimationActions.h" +#include "RE/M/MagicTarget.h" #include "RE/T/TESObjectREFR.h" namespace RE { + class AIProcess; + class CombatController; class CombatGroup; + class MovementMessageUpdateRequestImmediate; class TESFaction; - class AIProcess; + class TESRace; + + struct ActorCPMEvent; + struct ActorSprintEvent; + struct bhkCharacterMoveFinishEvent; + struct bhkCharacterStateChangeEvent; + struct bhkNonSupportContactEvent; + struct BSMovementDataChangedEvent; + struct BSNavmeshChangeEvent; + struct BSSubGraphActivationUpdate; + struct Perks; + + namespace PerkValueEvents + { + struct PerkValueChangedEvent; + struct PerkEntryUpdatedEvent; + } + + enum class ACTOR_CRITICAL_STAGE + { + kNone = 0, + kGooStart = 1, + kGooEnd = 2, + kDisintegrateStart = 3, + kDisintegrateEnd = 4, + kFreezeStart = 5, + kFreezeEnd = 6, + + kTotal + }; class Actor : - public TESObjectREFR // 110 - // ... + 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: SF_RTTI_VTABLE(Actor); SF_FORMTYPE(ACHR); - ~Actor() override; // 00 + enum class BOOL_BITS + { + kNone = 0, + kDelayUpdateScenegraph = 1 << 0, + kProcessMe = 1 << 1, + kMurderAlarm = 1 << 2, + kHasSceneExtra = 1 << 3, + kHeadingFixed = 1 << 4, + kSpeakingDone = 1 << 5, + kIgnoreChangeAnimationCall = 1 << 6, + kSoundFileDone = 1 << 7, + kVoiceFileDone = 1 << 8, + kInTempChangeList = 1 << 9, + kDoNotRunSayToCallback = 1 << 10, + kDead = 1 << 11, + kForceGreetingPlayer = 1 << 12, + kForceUpdateQuestTarget = 1 << 13, + kSearchingInCombat = 1 << 14, + kAttackOnNextTheft = 1 << 15, + kEvpBuffered = 1 << 16, + kResetAI = 1 << 17, + kInWater = 1 << 18, + kSwimming = 1 << 19, + kVoicePausedByScript = 1 << 20, + kWasInFrustrum = 1 << 21, + kShouldRotateToTrack = 1 << 22, + kSetOnDeath = 1 << 23, + kDoNotPadVoice = 1 << 24, + kFootIKInRange = 1 << 25, + kPlayerTeammate = 1 << 26, + kGivePlayerXP = 1 << 27, + kSoundCallbackSuccess = 1 << 28, + kUseEmotion = 1 << 29, + kGuard = 1 << 30, + kParalyzed = 1 << 31 + }; - inline static Actor* PlayerCharacter() + enum class BOOL_FLAGS { - static REL::Relocation singleton{ REL::ID(865059) }; - return *singleton; - } + kNone = 0, + kScenePackage = 1 << 0, + kIsAMount = 1 << 1, + kIsMountPointClear = 1 << 2, + kIsGettingOnOffMount = 1 << 3, + kInRandomScene = 1 << 4, + kNoBleedoutRecovery = 1 << 5, + kInBleedoutAnimation = 1 << 6, + kCanDoFavor = 1 << 7, + kShouldAnimGraphUpdate = 1 << 8, + kCanSpeakToEssentialDown = 1 << 9, + kBribedByPlayer = 1 << 10, + kAngryWithPlayer = 1 << 11, + kIsTresspassing = 1 << 12, + kCanSpeak = 1 << 13, + kIsInKillMove = 1 << 14, + kAttackOnSight = 1 << 15, + kIsCommandedActor = 1 << 16, + kForceOneAnimGraphUpdate = 1 << 17, + kEssential = 1 << 18, + kProtected = 1 << 19, + kAttackingDisabled = 1 << 20, + kCastingDisabled = 1 << 21, + kSceneHeadtrackRotation = 1 << 22, + kForceIncMinBoneUpdate = 1 << 23, + kCrimeSearch = 1 << 24, + kMovingIntoLoadedArea = 1 << 25, + kDoNotShowOnStealthMeter = 1 << 26, + kMovementBlocked = 1 << 27, + kAllowInstantFurniturePopInPlayerCell = 1 << 28, + kForceAnimGraphUpdate = 1 << 29, + kCheckAddEffectDualCast = 1 << 30, + kUnderwater = 1 << 31, + }; - inline static bool IsPlayerCharacterInChargen() + enum class BOOL_FLAGS2 { - auto PC = PlayerCharacter(); - return *(stl::adjust_pointer(PC, 0xF24)); - } + kNone = 0, + kHasChargenSkeleton = 1 << 5, + }; + + ~Actor() override; // 00 // add virtual void PlayPickUpSound(TESBoundObject* a_boundObj, bool a_pickUp, bool a_use); // 130 @@ -95,14 +212,14 @@ namespace RE virtual void Unk_16B(); // 16B virtual bool IsInCombat() const; // 16C virtual void Unk_16D(); // 16D - virtual void Unk_16E(); // 16E + virtual void StopCombat(); // 16E virtual void Unk_16F(); // 16F virtual void SetLifeState(std::uint32_t a_state); // 170 virtual void Unk_171(); // 171 virtual void Unk_172(); // 172 virtual void Unk_173(); // 173 virtual void Unk_174(); // 174 - virtual void Unk_175(); // 175 + virtual bool IsInFaction(TESFaction* a_faction); // 175 virtual void Unk_176(); // 176 virtual void Unk_177(); // 177 virtual void Unk_178(); // 178 @@ -148,142 +265,110 @@ namespace RE virtual void Unk_1A0(); // 1A0 virtual void Unk_1A1(); // 1A1 - 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 - 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 - 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 - std::uint64_t unk240; // 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 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 - 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 - std::uint64_t unk2D0; // 2D0 - 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 - 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 - std::uint64_t unk3B0; // 3B0 - std::uint64_t unk3B8; // 3B8 - std::uint64_t unk3C0; // 3C0 - std::uint64_t unk3C8; // 3C8 - std::uint64_t unk3D0; // 3D0 - std::uint64_t unk3D8; // 3D8 - std::uint64_t unk3E0; // 3E0 - std::uint64_t unk3E8; // 3E8 - std::uint64_t unk3F0; // 3F0 - std::uint64_t unk3F8; // 3F8 - std::uint64_t unk400; // 400 - std::uint64_t unk408; // 408 - std::uint64_t unk410; // 410 - std::uint64_t unk418; // 418 - std::uint64_t unk420; // 420 - std::uint64_t unk428; // 428 - std::uint64_t unk430; // 430 - std::uint64_t unk438; // 438 - std::uint64_t unk440; // 440 - std::uint64_t unk448; // 448 - std::uint64_t unk450; // 450 - std::uint64_t unk458; // 458 - std::uint64_t unk460; // 460 - std::uint64_t unk468; // 468 - std::uint64_t unk470; // 470 - std::uint64_t unk478; // 478 - std::uint64_t unk480; // 480 - std::uint64_t unk488; // 488 - std::uint64_t unk490; // 490 - std::uint64_t unk498; // 498 - std::uint64_t unk4A0; // 4A0 - std::uint64_t unk4A8; // 4A8 - std::uint64_t unk4B0; // 4B0 - std::uint64_t unk4B8; // 4B8 - std::uint64_t unk4C0; // 4C0 - std::uint64_t unk4C8; // 4C8 - std::uint64_t unk4D0; // 4D0 - std::uint64_t unk4D8; // 4D8 - std::uint64_t unk4E0; // 4E0 - std::uint64_t unk4E8; // 4E8 - std::uint64_t unk4F0; // 4F0 - std::uint64_t unk4F8; // 4F8 - std::uint64_t unk500; // 500 - std::uint64_t unk508; // 508 - std::uint64_t unk510; // 510 - 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 + // members + stl::enumeration boolBits; // 240 + std::uint32_t unk244; // 244 + 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 unk270; // 270 + std::uint64_t unk278; // 278 + std::uint64_t unk280; // 280 + CombatController* combatController; // 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 + 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::uint64_t unk2E0; // 2E0 + std::uint64_t unk2E8; // 2E8 + std::uint64_t unk2F0; // 2F0 + std::uint32_t intimidateBribeDayStamp; // 2F8 + std::uint32_t unk2FC; // 2FC + 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 + TESRace* race; // 388 + Perks* perks; // 390 + std::uint64_t unk398; // 398 + std::uint64_t unk3A0; // 3A0 + stl::enumeration boolFlags; // 3A8 + stl::enumeration boolFlags2; // 3AC + std::uint64_t unk3B0; // 3B0 + std::uint64_t unk3B8; // 3B8 + std::uint64_t unk3C0; // 3C0 + std::uint64_t unk3C8; // 3C8 + std::uint64_t unk3D0; // 3D0 + std::uint64_t unk3D8; // 3D8 + std::uint64_t unk3E0; // 3E0 + std::uint64_t unk3E8; // 3E8 + std::uint64_t unk3F0; // 3F0 + std::uint64_t unk3F8; // 3F8 + std::uint64_t unk400; // 400 + std::uint64_t unk408; // 408 + std::uint64_t unk410; // 410 + std::uint64_t unk418; // 418 + std::uint64_t unk420; // 420 + std::uint64_t unk428; // 428 + std::uint64_t unk430; // 430 + std::uint64_t unk438; // 438 + std::uint64_t unk440; // 440 + std::uint64_t unk448; // 448 + std::uint64_t unk450; // 450 + std::uint64_t unk458; // 458 + std::uint64_t unk460; // 460 + std::uint64_t unk468; // 468 + std::uint64_t unk470; // 470 + std::uint64_t unk478; // 478 + std::uint64_t unk480; // 480 + std::uint64_t unk488; // 488 + std::uint64_t unk490; // 490 + std::uint64_t unk498; // 498 + std::uint64_t unk4A0; // 4A0 + std::uint64_t unk4A8; // 4A8 + std::uint64_t unk4B0; // 4B0 + std::uint64_t unk4B8; // 4B8 + std::uint64_t unk4C0; // 4C0 + std::uint64_t unk4C8; // 4C8 + std::uint64_t unk4D0; // 4D0 + std::uint64_t unk4D8; // 4D8 + std::uint64_t unk4E0; // 4E0 + std::uint64_t unk4E8; // 4E8 + std::uint64_t unk4F0; // 4F0 + std::uint64_t unk4F8; // 4F8 + std::uint64_t unk500; // 500 + std::uint64_t unk508; // 508 + std::uint64_t unk510; // 510 + 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); } diff --git a/CommonLibSF/include/RE/A/ActorState.h b/CommonLibSF/include/RE/A/ActorState.h new file mode 100644 index 00000000..f0ee733e --- /dev/null +++ b/CommonLibSF/include/RE/A/ActorState.h @@ -0,0 +1,25 @@ +#pragma once + +#include "RE/I/IMovementState.h" + +namespace RE +{ + class ActorState : public IMovementState + { + public: + SF_RTTI(ActorState); + + ~ActorState() override; // 00 + + // add + virtual void Unk_31(); // 31 + virtual void Unk_32(); // 32 + virtual void Unk_33(); // 33 + virtual void Unk_34(); // 34 + + // members + std::uint32_t actorState1; // 08 + std::uint32_t actorState2; // 0C + }; + static_assert(sizeof(ActorState) == 0x10); +} diff --git a/CommonLibSF/include/RE/I/IMovementPlayerControlsFilter.h b/CommonLibSF/include/RE/I/IMovementPlayerControlsFilter.h new file mode 100644 index 00000000..cbd58d63 --- /dev/null +++ b/CommonLibSF/include/RE/I/IMovementPlayerControlsFilter.h @@ -0,0 +1,29 @@ +#pragma once + +#include "RE/I/IMovementInterface.h" + +namespace RE +{ + class IMovementPlayerControlsFilter : public IMovementInterface + { + public: + SF_RTTI(IMovementPlayerControlsFilter); + + ~IMovementPlayerControlsFilter() override; // 00 + + // add + virtual void Unk_01(); // 01 + virtual void Unk_02(); // 02 + virtual void Unk_03(); // 03 + virtual void Unk_04(); // 04 + virtual void Unk_05(); // 05 + virtual void Unk_06(); // 06 + virtual void Unk_07(); // 07 + virtual void Unk_08(); // 08 + virtual void Unk_09(); // 09 + virtual void Unk_0A(); // 0A + virtual void Unk_0B(); // 0B + virtual void Unk_0C(); // 0C + }; + static_assert(sizeof(IMovementPlayerControlsFilter) == 0x8); +} diff --git a/CommonLibSF/include/RE/I/IMovementState.h b/CommonLibSF/include/RE/I/IMovementState.h new file mode 100644 index 00000000..a5870188 --- /dev/null +++ b/CommonLibSF/include/RE/I/IMovementState.h @@ -0,0 +1,65 @@ +#pragma once + +#include "RE/I/IMovementInterface.h" + +namespace RE +{ + class IMovementState : public IMovementInterface + { + public: + SF_RTTI(IMovementState); + + ~IMovementState() override; // 00 + + // add + virtual void Unk_01(); // 01 + virtual void Unk_02(); // 02 + virtual void Unk_03(); // 03 + virtual void Unk_04(); // 04 + virtual void Unk_05(); // 05 + virtual void Unk_06(); // 06 + virtual void Unk_07(); // 07 + virtual void Unk_08(); // 08 + virtual void Unk_09(); // 09 + virtual void Unk_0A(); // 0A + virtual void Unk_0B(); // 0B + virtual void Unk_0C(); // 0C + virtual void Unk_0D(); // 0D + virtual void Unk_0E(); // 0E + virtual void Unk_0F(); // 0F + virtual void Unk_10(); // 10 + virtual void Unk_11(); // 11 + virtual void Unk_12(); // 12 + virtual void Unk_13(); // 13 + virtual void Unk_14(); // 14 + virtual void Unk_15(); // 15 + virtual void Unk_16(); // 16 + virtual void Unk_17(); // 17 + virtual void Unk_18(); // 18 + virtual void Unk_19(); // 19 + virtual void Unk_1A(); // 1A + virtual void Unk_1B(); // 1B + virtual void Unk_1C(); // 1C + virtual void Unk_1D(); // 1D + virtual void Unk_1E(); // 1E + virtual void Unk_1F(); // 1F + virtual void Unk_20(); // 20 + virtual void Unk_21(); // 21 + virtual void Unk_22(); // 22 + virtual void Unk_23(); // 23 + virtual void Unk_24(); // 24 + virtual void Unk_25(); // 25 + virtual void Unk_26(); // 26 + virtual void Unk_27(); // 27 + virtual void Unk_28(); // 28 + virtual void Unk_29(); // 29 + virtual void Unk_2A(); // 2A + virtual void Unk_2B(); // 2B + virtual void Unk_2C(); // 2C + virtual void Unk_2D(); // 2D + virtual void Unk_2E(); // 2E + virtual void Unk_2F(); // 2F + virtual void Unk_30(); // 30 + }; + static_assert(sizeof(IMovementState) == 0x8); +} diff --git a/CommonLibSF/include/RE/I/IMovementStateStore.h b/CommonLibSF/include/RE/I/IMovementStateStore.h new file mode 100644 index 00000000..410ce261 --- /dev/null +++ b/CommonLibSF/include/RE/I/IMovementStateStore.h @@ -0,0 +1,18 @@ +#pragma once + +#include "RE/I/IMovementInterface.h" + +namespace RE +{ + struct IMovementStateStore : public IMovementInterface + { + public: + SF_RTTI(IMovementStateStore); + + ~IMovementStateStore() override; // 00 + + // add + virtual void Unk_01(); // 01 + }; + static_assert(sizeof(IMovementStateStore) == 0x8); +} diff --git a/CommonLibSF/include/RE/I/IStoreAnimationActions.h b/CommonLibSF/include/RE/I/IStoreAnimationActions.h new file mode 100644 index 00000000..9b7eb2a2 --- /dev/null +++ b/CommonLibSF/include/RE/I/IStoreAnimationActions.h @@ -0,0 +1,20 @@ +#pragma once + +#include "RE/I/IMovementInterface.h" + +namespace RE +{ + class IStoreAnimationActions : public IMovementInterface + { + public: + SF_RTTI(IStoreAnimationActions); + + ~IStoreAnimationActions() override; // 00 + + // add + virtual void Unk_01(); // 01 + virtual void Unk_02(); // 02 + virtual void Unk_03(); // 03 + }; + static_assert(sizeof(IStoreAnimationActions) == 0x8); +} diff --git a/CommonLibSF/include/RE/M/MagicTarget.h b/CommonLibSF/include/RE/M/MagicTarget.h new file mode 100644 index 00000000..15f9bebf --- /dev/null +++ b/CommonLibSF/include/RE/M/MagicTarget.h @@ -0,0 +1,45 @@ +#pragma once + +namespace RE +{ + class ActiveEffect; + class Actor; + class EffectItem; + class MagicItem; + class TESBoundObject; + class TESObjectREFR; + + struct AddTargetData; + struct SpellDispelData; + + class MagicTarget + { + public: + SF_RTTI_VTABLE(MagicTarget); + + virtual ~MagicTarget(); // 00 + + // add + virtual bool AddTarget(AddTargetData& a_targetData); // 01 + virtual TESObjectREFR* GetTargetStatsObject(); // 02 + [[nodiscard]] virtual bool MagicTargetIsActor() const; // 03 + virtual bool IsInvulnerable(); // 04 + virtual void Unk_05(); // 05 + virtual bool CanAddActiveEffect() = 0; // 06 + virtual void Unk_07(); // 07 - GetActiveEffectList? + virtual void Unk_08(); // 08 - GetActiveEffectList const? + virtual float CheckResistance(MagicItem* a_spell, EffectItem* a_effect, TESBoundObject* a_source) const; // 09 + virtual void EffectAdded(ActiveEffect* a_effect); // 0A + virtual void EffectRemoved(ActiveEffect* a_effect); // 0B + virtual void EffectActiveStatusChanged(ActiveEffect* a_effect); // 0C + virtual bool CheckAbsorb(Actor* a_caster, MagicItem* a_spell, const EffectItem* a_effectItem); // 0D + + // members + SpellDispelData* postUpdateDispelList; // 08 + std::uint8_t flags; // 10 + std::uint8_t pad11; // 11 + std::uint16_t pad12; // 12 + std::uint32_t pad14; // 14 + }; + static_assert(sizeof(MagicTarget) == 0x18); +} diff --git a/CommonLibSF/include/RE/P/PlayerCharacter.h b/CommonLibSF/include/RE/P/PlayerCharacter.h new file mode 100644 index 00000000..7ffc6d56 --- /dev/null +++ b/CommonLibSF/include/RE/P/PlayerCharacter.h @@ -0,0 +1,421 @@ +#pragma once + +#include "RE/A/Actor.h" +#include "RE/I/IMovementPlayerControlsFilter.h" + +namespace RE +{ + class MenuModeChangeEvent; + class MenuOpenCloseEvent; + class OtherEventEnabledEvent; + class TESFormDeleteEvent; + class TESHitEvent; + class UserEventEnabledEvent; + + struct AnimationGraphDependentEvent; + struct BGSActorCellEvent; + struct BGSActorDeathEvent; + struct PickRefUpdateEvent; + struct PositionPlayerEvent; + struct TargetHitEvent; + + struct QuestStatus + { + struct Event; + }; + + struct TESQuestEvent + { + struct Event; + }; + + namespace PerkValueEvents + { + struct PerkEntryUpdatedEvent; + } + + 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: + SF_RTTI_VTABLE(PlayerCharacter); + SF_FORMTYPE(ACHR); + + ~PlayerCharacter() override; // 00 + + // add + virtual void Unk_1A2(); // 1A2 + virtual void Unk_1A3(); // 1A3 + virtual void Unk_1A4(); // 1A4 + virtual void Unk_1A5(); // 1A5 + + [[nodiscard]] static PlayerCharacter* GetSingleton() + { + static REL::Relocation singleton{ REL::ID(865059) }; + return *singleton; + } + + bool IsInChargen() + { + return *(stl::adjust_pointer(this, 0xF24)); + } + + // members + std::uint64_t unk0670; // 0670 + std::uint64_t unk0678; // 0678 + std::uint64_t unk0680; // 0680 + std::uint64_t unk0688; // 0688 + std::uint64_t unk0690; // 0690 + std::uint64_t unk0698; // 0698 + std::uint64_t unk06A0; // 06A0 + std::uint64_t unk06A8; // 06A8 + std::uint64_t unk06B0; // 06B0 + std::uint64_t unk06B8; // 06B8 + std::uint64_t unk06C0; // 06C0 + std::uint64_t unk06C8; // 06C8 + std::uint64_t unk06D0; // 06D0 + std::uint64_t unk06D8; // 06D8 + std::uint64_t unk06E0; // 06E0 + std::uint64_t unk06E8; // 06E8 + std::uint64_t unk06F0; // 06F0 + std::uint64_t unk06F8; // 06F8 + std::uint64_t unk0700; // 0700 + std::uint64_t unk0708; // 0708 + std::uint64_t unk0710; // 0710 + std::uint64_t unk0718; // 0718 + std::uint64_t unk0720; // 0720 + std::uint64_t unk0728; // 0728 + std::uint64_t unk0730; // 0730 + std::uint64_t unk0738; // 0738 + std::uint64_t unk0740; // 0740 + std::uint64_t unk0748; // 0748 + std::uint64_t unk0750; // 0750 + std::uint64_t unk0758; // 0758 + std::uint64_t unk0760; // 0760 + std::uint64_t unk0768; // 0768 + std::uint64_t unk0770; // 0770 + std::uint64_t unk0778; // 0778 + std::uint64_t unk0780; // 0780 + std::uint64_t unk0788; // 0788 + std::uint64_t unk0790; // 0790 + std::uint64_t unk0798; // 0798 + std::uint64_t unk07A0; // 07A0 + std::uint64_t unk07A8; // 07A8 + std::uint64_t unk07B0; // 07B0 + std::uint64_t unk07B8; // 07B8 + std::uint64_t unk07C0; // 07C0 + std::uint64_t unk07C8; // 07C8 + std::uint64_t unk07D0; // 07D0 + std::uint64_t unk07D8; // 07D8 + std::uint64_t unk07E0; // 07E0 + std::uint64_t unk07E8; // 07E8 + std::uint64_t unk07F0; // 07F0 + std::uint64_t unk07F8; // 07F8 + std::uint64_t unk0800; // 0800 + std::uint64_t unk0808; // 0808 + std::uint64_t unk0810; // 0810 + std::uint64_t unk0818; // 0818 + std::uint64_t unk0820; // 0820 + std::uint64_t unk0828; // 0828 + std::uint64_t unk0830; // 0830 + std::uint64_t unk0838; // 0838 + std::uint64_t unk0840; // 0840 + std::uint64_t unk0848; // 0848 + std::uint64_t unk0850; // 0850 + std::uint64_t unk0858; // 0858 + std::uint64_t unk0860; // 0860 + std::uint64_t unk0868; // 0868 + std::uint64_t unk0870; // 0870 + std::uint64_t unk0878; // 0878 + std::uint64_t unk0880; // 0880 + std::uint64_t unk0888; // 0888 + std::uint64_t unk0890; // 0890 + std::uint64_t unk0898; // 0898 + std::uint64_t unk08A0; // 08A0 + std::uint64_t unk08A8; // 08A8 + std::uint64_t unk08B0; // 08B0 + std::uint64_t unk08B8; // 08B8 + std::uint64_t unk08C0; // 08C0 + std::uint64_t unk08C8; // 08C8 + std::uint64_t unk08D0; // 08D0 + std::uint64_t unk08D8; // 08D8 + std::uint64_t unk08E0; // 08E0 + std::uint64_t unk08E8; // 08E8 + std::uint64_t unk08F0; // 08F0 + std::uint64_t unk08F8; // 08F8 + std::uint64_t unk0900; // 0900 + std::uint64_t unk0908; // 0908 + std::uint64_t unk0910; // 0910 + std::uint64_t unk0918; // 0918 + std::uint64_t unk0920; // 0920 + std::uint64_t unk0928; // 0928 + std::uint64_t unk0930; // 0930 + std::uint64_t unk0938; // 0938 + std::uint64_t unk0940; // 0940 + std::uint64_t unk0948; // 0948 + std::uint64_t unk0950; // 0950 + std::uint64_t unk0958; // 0958 + std::uint64_t unk0960; // 0960 + std::uint64_t unk0968; // 0968 + std::uint64_t unk0970; // 0970 + std::uint64_t unk0978; // 0978 + std::uint64_t unk0980; // 0980 + std::uint64_t unk0988; // 0988 + std::uint64_t unk0990; // 0990 + std::uint64_t unk0998; // 0998 + std::uint64_t unk09A0; // 09A0 + std::uint64_t unk09A8; // 09A8 + std::uint64_t unk09B0; // 09B0 + std::uint64_t unk09B8; // 09B8 + std::uint64_t unk09C0; // 09C0 + std::uint64_t unk09C8; // 09C8 + std::uint64_t unk09D0; // 09D0 + std::uint64_t unk09D8; // 09D8 + std::uint64_t unk09E0; // 09E0 + std::uint64_t unk09E8; // 09E8 + std::uint64_t unk09F0; // 09F0 + std::uint64_t unk09F8; // 09F8 + std::uint64_t unk0A00; // 0A00 + std::uint64_t unk0A08; // 0A08 + std::uint64_t unk0A10; // 0A10 + std::uint64_t unk0A18; // 0A18 + std::uint64_t unk0A20; // 0A20 + std::uint64_t unk0A28; // 0A28 + std::uint64_t unk0A30; // 0A30 + std::uint64_t unk0A38; // 0A38 + std::uint64_t unk0A40; // 0A40 + std::uint64_t unk0A48; // 0A48 + std::uint64_t unk0A50; // 0A50 + std::uint64_t unk0A58; // 0A58 + std::uint64_t unk0A60; // 0A60 + std::uint64_t unk0A68; // 0A68 + std::uint64_t unk0A70; // 0A70 + std::uint64_t unk0A78; // 0A78 + std::uint64_t unk0A80; // 0A80 + std::uint64_t unk0A88; // 0A88 + std::uint64_t unk0A90; // 0A90 + std::uint64_t unk0A98; // 0A98 + std::uint64_t unk0AA0; // 0AA0 + std::uint64_t unk0AA8; // 0AA8 + std::uint64_t unk0AB0; // 0AB0 + std::uint64_t unk0AB8; // 0AB8 + std::uint64_t unk0AC0; // 0AC0 + std::uint64_t unk0AC8; // 0AC8 + std::uint64_t unk0AD0; // 0AD0 + std::uint64_t unk0AD8; // 0AD8 + std::uint64_t unk0AE0; // 0AE0 + std::uint64_t unk0AE8; // 0AE8 + std::uint64_t unk0AF0; // 0AF0 + std::uint64_t unk0AF8; // 0AF8 + std::uint64_t unk0B00; // 0B00 + std::uint64_t unk0B08; // 0B08 + std::uint64_t unk0B10; // 0B10 + std::uint64_t unk0B18; // 0B18 + std::uint64_t unk0B20; // 0B20 + std::uint64_t unk0B28; // 0B28 + std::uint64_t unk0B30; // 0B30 + std::uint64_t unk0B38; // 0B38 + std::uint64_t unk0B40; // 0B40 + std::uint64_t unk0B48; // 0B48 + std::uint64_t unk0B50; // 0B50 + std::uint64_t unk0B58; // 0B58 + std::uint64_t unk0B60; // 0B60 + std::uint64_t unk0B68; // 0B68 + std::uint64_t unk0B70; // 0B70 + std::uint64_t unk0B78; // 0B78 + std::uint64_t unk0B80; // 0B80 + std::uint64_t unk0B88; // 0B88 + std::uint64_t unk0B90; // 0B90 + std::uint64_t unk0B98; // 0B98 + std::uint64_t unk0BA0; // 0BA0 + std::uint64_t unk0BA8; // 0BA8 + std::uint64_t unk0BB0; // 0BB0 + std::uint64_t unk0BB8; // 0BB8 + std::uint64_t unk0BC0; // 0BC0 + std::uint64_t unk0BC8; // 0BC8 + std::uint64_t unk0BD0; // 0BD0 + std::uint64_t unk0BD8; // 0BD8 + std::uint64_t unk0BE0; // 0BE0 + std::uint64_t unk0BE8; // 0BE8 + std::uint64_t unk0BF0; // 0BF0 + std::uint64_t unk0BF8; // 0BF8 + std::uint64_t unk0C00; // 0C00 + std::uint64_t unk0C08; // 0C08 + std::uint64_t unk0C10; // 0C10 + std::uint64_t unk0C18; // 0C18 + std::uint64_t unk0C20; // 0C20 + std::uint64_t unk0C28; // 0C28 + std::uint64_t unk0C30; // 0C30 + std::uint64_t unk0C38; // 0C38 + std::uint64_t unk0C40; // 0C40 + std::uint64_t unk0C48; // 0C48 + std::uint64_t unk0C50; // 0C50 + std::uint64_t unk0C58; // 0C58 + std::uint64_t unk0C60; // 0C60 + std::uint64_t unk0C68; // 0C68 + std::uint64_t unk0C70; // 0C70 + std::uint64_t unk0C78; // 0C78 + std::uint64_t unk0C80; // 0C80 + std::uint64_t unk0C88; // 0C88 + std::uint64_t unk0C90; // 0C90 + std::uint64_t unk0C98; // 0C98 + std::uint64_t unk0CA0; // 0CA0 + std::uint64_t unk0CA8; // 0CA8 + std::uint64_t unk0CB0; // 0CB0 + std::uint64_t unk0CB8; // 0CB8 + std::uint64_t unk0CC0; // 0CC0 + std::uint64_t unk0CC8; // 0CC8 + std::uint64_t unk0CD0; // 0CD0 + std::uint64_t unk0CD8; // 0CD8 + std::uint64_t unk0CE0; // 0CE0 + std::uint64_t unk0CE8; // 0CE8 + std::uint64_t unk0CF0; // 0CF0 + std::uint64_t unk0CF8; // 0CF8 + std::uint64_t unk0D00; // 0D00 + std::uint64_t unk0D08; // 0D08 + std::uint64_t unk0D10; // 0D10 + std::uint64_t unk0D18; // 0D18 + std::uint64_t unk0D20; // 0D20 + std::uint64_t unk0D28; // 0D28 + std::uint64_t unk0D30; // 0D30 + std::uint64_t unk0D38; // 0D38 + std::uint64_t unk0D40; // 0D40 + std::uint64_t unk0D48; // 0D48 + std::uint64_t unk0D50; // 0D50 + std::uint64_t unk0D58; // 0D58 + std::uint64_t unk0D60; // 0D60 + std::uint64_t unk0D68; // 0D68 + std::uint64_t unk0D70; // 0D70 + std::uint64_t unk0D78; // 0D78 + std::uint64_t unk0D80; // 0D80 + std::uint64_t unk0D88; // 0D88 + std::uint64_t unk0D90; // 0D90 + std::uint64_t unk0D98; // 0D98 + std::uint64_t unk0DA0; // 0DA0 + std::uint64_t unk0DA8; // 0DA8 + std::uint64_t unk0DB0; // 0DB0 + std::uint64_t unk0DB8; // 0DB8 + std::uint64_t unk0DC0; // 0DC0 + std::uint64_t unk0DC8; // 0DC8 + std::uint64_t unk0DD0; // 0DD0 + std::uint64_t unk0DD8; // 0DD8 + std::uint64_t unk0DE0; // 0DE0 + std::uint64_t unk0DE8; // 0DE8 + std::uint64_t unk0DF0; // 0DF0 + std::uint64_t unk0DF8; // 0DF8 + std::uint64_t unk0E00; // 0E00 + std::uint64_t unk0E08; // 0E08 + std::uint64_t unk0E10; // 0E10 + std::uint64_t unk0E18; // 0E18 + std::uint64_t unk0E20; // 0E20 + std::uint64_t unk0E28; // 0E28 + std::uint64_t unk0E30; // 0E30 + std::uint64_t unk0E38; // 0E38 + std::uint64_t unk0E40; // 0E40 + std::uint64_t unk0E48; // 0E48 + std::uint64_t unk0E50; // 0E50 + std::uint64_t unk0E58; // 0E58 + std::uint64_t unk0E60; // 0E60 + std::uint64_t unk0E68; // 0E68 + std::uint64_t unk0E70; // 0E70 + std::uint64_t unk0E78; // 0E78 + std::uint64_t unk0E80; // 0E80 + std::uint64_t unk0E88; // 0E88 + std::uint64_t unk0E90; // 0E90 + std::uint64_t unk0E98; // 0E98 + std::uint64_t unk0EA0; // 0EA0 + std::uint64_t unk0EA8; // 0EA8 + std::uint64_t unk0EB0; // 0EB0 + std::uint64_t unk0EB8; // 0EB8 + std::uint64_t unk0EC0; // 0EC0 + std::uint64_t unk0EC8; // 0EC8 + std::uint64_t unk0ED0; // 0ED0 + std::uint64_t unk0ED8; // 0ED8 + std::uint64_t unk0EE0; // 0EE0 + std::uint64_t unk0EE8; // 0EE8 + std::uint64_t unk0EF0; // 0EF0 + 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 + std::uint64_t unk0F38; // 0F38 + std::uint64_t unk0F40; // 0F40 + std::uint64_t unk0F48; // 0F48 + std::uint64_t unk0F50; // 0F50 + std::uint64_t unk0F58; // 0F58 + std::uint64_t unk0F60; // 0F60 + std::uint64_t unk0F68; // 0F68 + std::uint64_t unk0F70; // 0F70 + std::uint64_t unk0F78; // 0F78 + std::uint64_t unk0F80; // 0F80 + std::uint64_t unk0F88; // 0F88 + std::uint64_t unk0F90; // 0F90 + std::uint64_t unk0F98; // 0F98 + std::uint64_t unk0FA0; // 0FA0 + std::uint64_t unk0FA8; // 0FA8 + std::uint64_t unk0FB0; // 0FB0 + std::uint64_t unk0FB8; // 0FB8 + std::uint64_t unk0FC0; // 0FC0 + std::uint64_t unk0FC8; // 0FC8 + std::uint64_t unk0FD0; // 0FD0 + std::uint64_t unk0FD8; // 0FD8 + std::uint64_t unk0FE0; // 0FE0 + std::uint64_t unk0FE8; // 0FE8 + std::uint64_t unk0FF0; // 0FF0 + std::uint64_t unk0FF8; // 0FF8 + std::uint64_t unk1000; // 1000 + std::uint64_t unk1008; // 1008 + std::uint64_t unk1010; // 1010 + std::uint64_t unk1018; // 1018 + std::uint64_t unk1020; // 1020 + std::uint64_t unk1028; // 1028 + std::uint64_t unk1030; // 1030 + std::uint64_t unk1038; // 1038 + std::uint64_t unk1040; // 1040 + std::uint64_t unk1048; // 1048 + std::uint64_t unk1050; // 1050 + std::uint64_t unk1058; // 1058 + std::uint64_t unk1060; // 1060 + std::uint64_t unk1068; // 1068 + std::uint64_t unk1070; // 1070 + std::uint64_t unk1078; // 1078 + std::uint64_t unk1080; // 1080 + std::uint64_t unk1088; // 1088 + std::uint64_t unk1090; // 1090 + std::uint64_t unk1098; // 1098 + std::uint64_t unk10A0; // 10A0 + std::uint64_t unk10A8; // 10A8 + std::uint64_t unk10B0; // 10B0 + std::uint64_t unk10B8; // 10B8 + std::uint64_t unk10C0; // 10C0 + std::uint64_t unk10C8; // 10C8 + std::uint64_t unk10D0; // 10D0 + 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); +} diff --git a/CommonLibSF/include/RE/T/TESObjectREFR.h b/CommonLibSF/include/RE/T/TESObjectREFR.h index 666dcd34..1e2c8388 100644 --- a/CommonLibSF/include/RE/T/TESObjectREFR.h +++ b/CommonLibSF/include/RE/T/TESObjectREFR.h @@ -17,6 +17,7 @@ namespace RE class BSAnimationGraphEvent; class BSTransformDeltaEvent; class TESBoundObject; + class TESModel; class TESObjectCELL; class TESRace; class TESTopicInfo; @@ -94,7 +95,7 @@ namespace RE virtual void Unk_75(); // 075 virtual void Unk_76(); // 076 virtual void Unk_77(); // 077 - virtual void Unk_78(); // 078 + virtual bool IsInZeroGravity(); // 078 virtual void Unk_79(); // 079 virtual BGSScene* GetCurrentScene() const; // 07A virtual void Unk_7B(); // 07B @@ -149,7 +150,7 @@ namespace RE virtual void Unk_AC(); // 0AC - Get3D(NiPointer&)? virtual void Unk_AD(); // 0AD virtual void Unk_AE(); // 0AE - virtual void Unk_AF(); // 0AF + virtual TESModel* GetTESModel() const; // 0AF virtual TESRace* GetVisualsRace() const; // 0B0 virtual void Unk_B1(); // 0B1 virtual void Unk_B2(); // 0B2 @@ -242,7 +243,7 @@ namespace RE virtual void Unk_109(); // 109 virtual void Unk_10A(); // 10A virtual void Unk_10B(); // 10B - virtual void Unk_10C(); // 10C + virtual void SetParentCell(TESObjectCELL* a_cell); // 10C virtual bool IsDead(bool a_notEssential) const; // 10D virtual bool ProcessInWater(std::uint32_t a_bodyID, float a_waterHeight, float a_deltaTime); // 10E virtual void Unk_10F(); // 10F From d0edbe8e8c8f2da410e1accab208f812317ec446 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 30 Sep 2023 07:50:12 +0000 Subject: [PATCH 16/21] ci: maintenance `2023-09-30` --- CommonLibSF/include/RE/Starfield.h | 7 +++++++ CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/CommonLibSF/include/RE/Starfield.h b/CommonLibSF/include/RE/Starfield.h index 1864e004..877b5203 100644 --- a/CommonLibSF/include/RE/Starfield.h +++ b/CommonLibSF/include/RE/Starfield.h @@ -5,6 +5,7 @@ #include "RE/A/AIProcess.h" #include "RE/A/Actor.h" #include "RE/A/ActorPackage.h" +#include "RE/A/ActorState.h" #include "RE/A/ActorValueInfo.h" #include "RE/A/ActorValueOwner.h" #include "RE/A/ActorValues.h" @@ -50,9 +51,14 @@ #include "RE/I/IFunction.h" #include "RE/I/IKeywordFormBase.h" #include "RE/I/IMovementInterface.h" +#include "RE/I/IMovementPlayerControlsFilter.h" +#include "RE/I/IMovementState.h" +#include "RE/I/IMovementStateStore.h" #include "RE/I/INIPrefSettingCollection.h" #include "RE/I/INISettingCollection.h" #include "RE/I/IPostAnimationChannelUpdateFunctor.h" +#include "RE/I/IStoreAnimationActions.h" +#include "RE/M/MagicTarget.h" #include "RE/M/MemoryManager.h" #include "RE/M/MenuOpenCloseEvent.h" #include "RE/N/NativeFunction.h" @@ -64,6 +70,7 @@ #include "RE/Offsets_RTTI.h" #include "RE/Offsets_VTABLE.h" #include "RE/P/PlayerCamera.h" +#include "RE/P/PlayerCharacter.h" #include "RE/R/RegSettingCollection.h" #include "RE/RTTI.h" #include "RE/S/Script.h" diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index 00e1c0ec..2ebacc75 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-29.5", + "version-date": "2023-09-30", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index 753ca3d0..e0622086 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-29.5&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-30&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From 91bd9ba4e6fb8776b7094fddf30f1ad42ecf5a03 Mon Sep 17 00:00:00 2001 From: Qudix <17361645+Qudix@users.noreply.github.com> Date: Sat, 30 Sep 2023 20:49:21 -0500 Subject: [PATCH 17/21] feat: add scaleform stuff (#126) - `IMenu`, `Scaleform::` stuff - basic `BSTArray` class just to be able to define and iterate over content --- CommonLibSF/include/RE/B/BSInputEventUser.h | 28 + CommonLibSF/include/RE/B/BSTArray.h | 61 ++ CommonLibSF/include/RE/C/Console.h | 13 + CommonLibSF/include/RE/G/GameMenuBase.h | 17 + CommonLibSF/include/RE/I/IMenu.h | 80 ++ .../include/RE/S/SWFToCodeFunctionHandler.h | 22 + .../RE/S/ScaleformGFxASMovieRootBase.h | 115 +++ .../RE/S/ScaleformGFxFileTypeConstants.h | 14 + .../RE/S/ScaleformGFxFunctionHandler.h | 35 + CommonLibSF/include/RE/S/ScaleformGFxMovie.h | 48 ++ CommonLibSF/include/RE/S/ScaleformGFxState.h | 64 ++ .../include/RE/S/ScaleformGFxStateBag.h | 26 + CommonLibSF/include/RE/S/ScaleformGFxValue.h | 691 ++++++++++++++++++ CommonLibSF/include/RE/S/ScaleformPtr.h | 230 ++++++ CommonLibSF/include/RE/S/ScaleformRefCount.h | 63 ++ CommonLibSF/include/RE/Starfield.h | 14 + CommonLibSF/include/RE/U/UI.h | 53 +- 17 files changed, 1573 insertions(+), 1 deletion(-) create mode 100644 CommonLibSF/include/RE/B/BSInputEventUser.h create mode 100644 CommonLibSF/include/RE/B/BSTArray.h create mode 100644 CommonLibSF/include/RE/C/Console.h create mode 100644 CommonLibSF/include/RE/G/GameMenuBase.h create mode 100644 CommonLibSF/include/RE/I/IMenu.h create mode 100644 CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxFileTypeConstants.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxFunctionHandler.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxMovie.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxState.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxStateBag.h create mode 100644 CommonLibSF/include/RE/S/ScaleformGFxValue.h create mode 100644 CommonLibSF/include/RE/S/ScaleformPtr.h create mode 100644 CommonLibSF/include/RE/S/ScaleformRefCount.h diff --git a/CommonLibSF/include/RE/B/BSInputEventUser.h b/CommonLibSF/include/RE/B/BSInputEventUser.h new file mode 100644 index 00000000..ecfe109b --- /dev/null +++ b/CommonLibSF/include/RE/B/BSInputEventUser.h @@ -0,0 +1,28 @@ +#pragma once + +namespace RE +{ + class BSInputEventUser + { + public: + SF_RTTI_VTABLE(BSInputEventUser); + + 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 + + // members + std::uint8_t pad08[0x30]; // 08 + bool inputEventHandlingEnabled{ true }; // 38 + }; + static_assert(sizeof(BSInputEventUser) == 0x40); +} diff --git a/CommonLibSF/include/RE/B/BSTArray.h b/CommonLibSF/include/RE/B/BSTArray.h new file mode 100644 index 00000000..110181f8 --- /dev/null +++ b/CommonLibSF/include/RE/B/BSTArray.h @@ -0,0 +1,61 @@ +#pragma once + +namespace RE +{ + template + class BSTArray + { + public: + //using allocator_type = Allocator + using value_type = T; + using size_type = std::uint32_t; + using difference_type = std::ptrdiff_t; + using pointer = value_type*; + using const_pointer = const value_type*; + using reference = value_type&; + using const_reference = const value_type&; + using iterator = pointer; + using const_iterator = const_pointer; + + [[nodiscard]] constexpr pointer data() noexcept + { + return static_cast(_data); + } + + [[nodiscard]] constexpr iterator begin() noexcept + { + return data(); + } + + [[nodiscard]] constexpr const_iterator begin() const noexcept + { + return data(); + } + + [[nodiscard]] constexpr iterator end() noexcept + { + return begin() + size(); + } + + [[nodiscard]] constexpr const_iterator end() const noexcept + { + return begin() + size(); + } + + [[nodiscard]] constexpr bool empty() const noexcept + { + return _size == 0; + } + + [[nodiscard]] constexpr size_type size() const noexcept + { + return _size; + } + + private: + // members + std::uint32_t _size; + std::uint32_t _capacity; + void* _data; + }; +} diff --git a/CommonLibSF/include/RE/C/Console.h b/CommonLibSF/include/RE/C/Console.h new file mode 100644 index 00000000..c98df0e5 --- /dev/null +++ b/CommonLibSF/include/RE/C/Console.h @@ -0,0 +1,13 @@ +#pragma once + +#include "RE/G/GameMenuBase.h" + +namespace RE +{ + class Console : + public GameMenuBase // 00 + { + public: + SF_RTTI_VTABLE(Console); + }; +} diff --git a/CommonLibSF/include/RE/G/GameMenuBase.h b/CommonLibSF/include/RE/G/GameMenuBase.h new file mode 100644 index 00000000..61fcbc46 --- /dev/null +++ b/CommonLibSF/include/RE/G/GameMenuBase.h @@ -0,0 +1,17 @@ +#pragma once + +#include "RE/I/IMenu.h" + +namespace RE +{ + class GameMenuBase : + public IMenu // 00 + { + public: + SF_RTTI_VTABLE(GameMenuBase); + + GameMenuBase() = default; + + virtual ~GameMenuBase() = default; // 00 + }; +} diff --git a/CommonLibSF/include/RE/I/IMenu.h b/CommonLibSF/include/RE/I/IMenu.h new file mode 100644 index 00000000..8bc3f03b --- /dev/null +++ b/CommonLibSF/include/RE/I/IMenu.h @@ -0,0 +1,80 @@ +#pragma once + +#include "RE/B/BSInputEventUser.h" +#include "RE/B/BSTEvent.h" +#include "RE/S/ScaleformGFxMovie.h" +#include "RE/S/ScaleformGFxValue.h" +#include "RE/S/SWFToCodeFunctionHandler.h" + +namespace RE +{ + struct UpdateSceneRectEvent; + + class IMenu : + public SWFToCodeFunctionHandler, // 00 + public BSInputEventUser, // 10 + public BSTEventSink // 50 + { + public: + SF_RTTI_VTABLE(IMenu); + + virtual ~IMenu() = default; // 00 + + // add + virtual const char* GetName() const; // 03 + virtual const char* GetRootPath() const; // 04 + virtual void Unk_05(void); // 05 + virtual void Unk_06(void); // 06 + virtual bool LoadMovie(bool a_addEventDispatcher, bool a_arg2); // 07 + virtual void Unk_08(void); // 08 + virtual void Unk_09(void); // 09 + virtual void Unk_0A(void); // 0A + virtual void Unk_0B(void); // 0B + virtual void Unk_0C(void); // 0C + virtual void Unk_0D(void); // 0D + virtual void Unk_0E(void); // 0E + virtual void Unk_0F(void); // 0F + virtual void Unk_10(void); // 10 + virtual void Unk_11(void); // 11 + virtual void Unk_12(void); // 12 + virtual void Unk_13(void); // 13 + virtual void Unk_14(void); // 14 + virtual void Unk_15(void); // 15 + virtual void Unk_16(void); // 16 + virtual void Unk_17(void); // 17 + virtual void Unk_18(void); // 18 + virtual void Unk_19(void); // 19 + virtual void Unk_1A(void); // 1A + + std::int64_t unk058; // 058 + std::int64_t unk060; // 060 + Scaleform::GFx::Value menuObj; // 080 + Scaleform::Ptr uiMovie; // 088 + std::uint64_t unk090; // 090 + std::uint64_t unk098; // 098 + std::uint64_t unk0A0; // 0A0 + std::uint32_t unk0A8; // 0A8 + std::uint32_t unk0AC; // 0AC + BSFixedString menuName; // 0B0 + BSFixedString unk0B8; // 0B8 + std::uint64_t unk0C0; // 0C0 + std::uint32_t unk0C8; // 0C8 + std::uint32_t unk0CC; // 0CC + std::uint32_t unk0D0; // 0D0 + std::uint32_t unk0D4; // 0D4 + std::uint64_t unk0D8; // 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::uint32_t unk108; // 108 + std::uint32_t unk10C; // 10C + std::uint64_t unk110; // 110 + std::uint64_t unk118; // 118 + std::uint64_t unk120; // 120 + std::uint64_t unk128; // 128 + }; + static_assert(offsetof(IMenu, uiMovie) == 0x088); + static_assert(offsetof(IMenu, menuName) == 0x0B0); +} diff --git a/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h b/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h new file mode 100644 index 00000000..f3791690 --- /dev/null +++ b/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h @@ -0,0 +1,22 @@ +#pragma once + +#include "RE/S/ScaleformGFxFunctionHandler.h" + +namespace RE +{ + class SWFToCodeFunctionHandler : + public Scaleform::GFx::FunctionHandler // 00 + { + public: + SF_RTTI_VTABLE(SWFToCodeFunctionHandler); + + virtual ~SWFToCodeFunctionHandler() = default; // 00 + + // override + void Call(const Params&) override { return; } // 01 + + // add + virtual void MapCodeObjectFunctions() { return; } // 02 + }; + static_assert(sizeof(SWFToCodeFunctionHandler) == 0x10); +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h b/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h new file mode 100644 index 00000000..913b448a --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h @@ -0,0 +1,115 @@ +#pragma once + +namespace RE::Scaleform +{ + template + class ArrayPOD; + + class Log; + class String; + + namespace Render::Text + { + class Allocator; + } +} + +namespace RE::Scaleform::GFx +{ + class AccelerometerEvent; + class AmpMovieObjectDesc; + class AppLifecycleEvent; + class ASString; + class ASStringManager; + class DisplayObjContainer; + class DisplayObject; + class EventId; + class GeolocationEvent; + class InputEventsQueueEntry; + class InteractiveObject; + class LoadStates; + class LoadQueueEntry; + class MemoryContext; + class MemoryHeap; + class MouseState; + class MovieDefImpl; + class MovieDefRootNode; + class MovieImpl; + class OrientationEvent; + + struct ProcessFocusKeyInfo; + + enum class FocusMovedType; + + class ASMovieRootBase + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__ASMovieRootBase); + + virtual ~ASMovieRootBase() = default; // 00 + + // add + virtual void SetMovie(MovieImpl* a_movie); // 01 + virtual void AdvanceFrame(bool a_nextFrame) = 0; // 02 + virtual void ChangeMouseCursorType(std::uint32_t a_mouseIndex, std::uint32_t a_newCursorType) = 0; // 03 + virtual bool CheckAvm() = 0; // 04 + virtual void ClearDisplayList() = 0; // 05 + virtual MovieDefRootNode* CreateMovieDefRootNode(MemoryHeap* a_heap, MovieDefImpl* a_defImpl, bool a_importFlag) = 0; // 06 + virtual void DoActions() = 0; // 07 + virtual InteractiveObject* FindTarget(const ASString& a_path) const = 0; // 08 + virtual void ForceCollect() = 0; // 09 + virtual void ForceEmergencyCollect() = 0; // 0A + virtual void SuspendGC() = 0; // 0B + virtual void ScheduleGC() = 0; // 0C + virtual void GenerateMouseEvents(std::uint32_t a_mouseIndex) = 0; // 0D + virtual void GenerateTouchEvents(std::uint32_t a_mouseStateIndex); // 0E + virtual void GenerateGestureEvents(void); // 0F + virtual DisplayObjContainer* GetRootMovie(DisplayObject* a_dobj = nullptr) const = 0; // 10 + virtual bool Init(MovieDefImpl* a_movieDef) = 0; // 11 + virtual void NotifyMouseEvent(const InputEventsQueueEntry* a_qe, const MouseState& a_ms, std::int32_t a_mi) = 0; // 12 + virtual void NotifyOnResize() = 0; // 13 + virtual void NotifyQueueSetFocus(InteractiveObject* a_ch, std::uint32_t a_controllerIndex, FocusMovedType a_fmt) = 0; // 14 + virtual void NotifyTransferFocus(InteractiveObject* a_curFocused, InteractiveObject* a_newFocus, std::uint32_t a_controllerIndex) = 0; // 15 + virtual bool NotifyOnFocusChange(InteractiveObject* a_curFocused, InteractiveObject* a_toBeFocused, std::uint32_t a_controllerIndex, FocusMovedType a_fmt, ProcessFocusKeyInfo* a_focusKeyInfo = nullptr) = 0; // 16 + virtual void NotifyGamePadAnalogEvent(const EventId* a_id); // 17 + virtual void NotifyStatusEvent(const EventId* a_id); // 18 + virtual void NotifyAccelerometerEvent(const EventId* a_id, std::int32_t a_evtIDAcc); // 19 + virtual void NotifyGeolocationEvent(const EventId* a_id, std::int32_t a_evtIDGeo); // 1A + virtual void OnMovieFocus(bool a_set) = 0; // 1B + virtual void OnNextFrame() = 0; // 1C + virtual void OnDeviceOrientationChanged(const OrientationEvent&); // 1D + virtual void OnAppLifecycleEvent(const AppLifecycleEvent&); // 1E + virtual void OnAccelerometerEvent(const AccelerometerEvent&); // 1F + virtual void OnGeolocationEvent(const GeolocationEvent&); // 20 + virtual void PrintObjectsReport(std::uint32_t a_flags = 0, Log* a_log = nullptr, const char* a_swfName = nullptr); // 21 + virtual void GetObjectsTree(/* Array>* */ void* a_rootObjects, MemoryHeap* a_heap); // 22 + virtual AmpMovieObjectDesc* GetDisplayObjectsTree(MemoryHeap* a_heap); // 23 + virtual void ProcessLoadQueueEntry(LoadQueueEntry* a_entry, LoadStates* a_ls) = 0; // 24 + virtual void ProcessLoadVarsMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const String& a_data, std::size_t a_fileLen, bool a_succeeded) = 0; // 25 + virtual void ProcessLoadBinaryMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const ArrayPOD& a_data, std::size_t a_fileLen, bool a_succeeded); // 26 + virtual void RegisterAuxASClasses() = 0; // 27 + virtual void ResolveStickyVariables(InteractiveObject* a_character) = 0; // 28 + virtual void SetExternalInterfaceRetVal(const Value&) = 0; // 29 + virtual void SetMemoryParams(std::uint32_t a_frameBetweenCollections, std::uint32_t a_maxRootCount) = 0; // 2A + virtual void Shutdown() = 0; // 2B + virtual void CreateString(Value* a_value, const char* a_string) = 0; // 2C + virtual void CreateStringW(Value* a_value, const wchar_t* a_string) = 0; // 2D + virtual void CreateObject(Value* a_value, const char* a_className = nullptr, const Value* a_args = nullptr, std::uint32_t a_numArgs = 0) = 0; // 2E + virtual void CreateArray(Value* a_value) = 0; // 2F + virtual void CreateFunction(Value* a_value, FunctionHandler* a_fc, void* a_userData = nullptr) = 0; // 30 + virtual bool SetVariable(const char* a_pathToVar, const Value& a_value, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 31 + virtual bool GetVariable(Value* a_val, const char* a_pathToVar) const = 0; // 32 + virtual bool SetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, const void* a_data, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 33 + virtual bool SetVariableArraySize(const char* a_pathToVar, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 35 + virtual std::uint32_t GetVariableArraySize(const char* a_pathToVar) = 0; // 34 + virtual bool GetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, void* a_data, std::uint32_t a_count) = 0; // 36 + virtual bool IsAvailable(const char* a_pathToVar) const = 0; // 37 + virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const Value* a_args, std::uint32_t a_numArgs) = 0; // 39 + virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, ...) = 0; // 38 + virtual bool InvokeArgs(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, std::va_list a_args) = 0; // 3A + virtual MemoryContext* GetMemoryContext() const = 0; // 3B + virtual ASStringManager* GetStringManager() const = 0; // 3C + virtual Render::Text::Allocator* GetTextAllocator() = 0; // 3D + virtual void BroadcastGeolocationStatusEvent(const EventId* a_id) = 0; // 3E + }; +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxFileTypeConstants.h b/CommonLibSF/include/RE/S/ScaleformGFxFileTypeConstants.h new file mode 100644 index 00000000..7121f9f7 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxFileTypeConstants.h @@ -0,0 +1,14 @@ +#pragma once + +namespace RE::Scaleform::GFx +{ + class FileTypeConstants + { + public: + //enum class FileFormatType : std::int32_t + //{ + + //}; + }; + static_assert(std::is_empty_v); +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxFunctionHandler.h b/CommonLibSF/include/RE/S/ScaleformGFxFunctionHandler.h new file mode 100644 index 00000000..c78d6140 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxFunctionHandler.h @@ -0,0 +1,35 @@ +#pragma once + +#include "RE/S/ScaleformRefCount.h" + +namespace RE::Scaleform::GFx +{ + class Value; + class Movie; + + class FunctionHandler : + public RefCountBase // 00 + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__FunctionHandler); + + struct Params + { + // members + Value* ret; // 00 + Movie* movie; // 08 + Value* self; // 10 + Value* argsWithThisRef; // 18 + Value* args; // 20 + std::uint32_t argCount; // 28 + void* userData; // 30 + }; + static_assert(sizeof(Params) == 0x38); + + virtual ~FunctionHandler() = default; // 00 + + // add + virtual void Call(const Params& a_params) = 0; + }; + static_assert(sizeof(FunctionHandler) == 0x10); +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxMovie.h b/CommonLibSF/include/RE/S/ScaleformGFxMovie.h new file mode 100644 index 00000000..9c39b506 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxMovie.h @@ -0,0 +1,48 @@ +#pragma once + +#include "RE/S/ScaleformPtr.h" +#include "RE/S/ScaleformGFxStateBag.h" + +namespace RE::Scaleform::GFx +{ + class ASMovieRootBase; + + class Movie : + public RefCountBase, // 00 + public StateBag // 10 + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__Movie); + + enum class SetVarType : std::uint32_t + { + kNormal, + kSticky, + kPermanent + }; + + enum class SetArrayType : std::uint32_t + { + kInt, + kDouble, + kFloat, + kString, + kStringW, + kValue + }; + + virtual ~Movie() = default; // 01 + + // members + Ptr asMovieRoot; + }; + + class MovieImpl : + public Movie // 00 + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__MovieImpl); + + virtual ~MovieImpl() = default; // 00 + }; +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxState.h b/CommonLibSF/include/RE/S/ScaleformGFxState.h new file mode 100644 index 00000000..6be15c92 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxState.h @@ -0,0 +1,64 @@ +#pragma once + +#include "RE/S/ScaleformRefCount.h" + +namespace RE::Scaleform::GFx +{ + class State : + public RefCountBase // 00 + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__State); + + virtual ~State() = default; // 00 + + enum class StateType : std::int32_t + { + kNone, + kTranslator, + kLog, + kActionControl, + kUserEventHandler, + kFSCommandHandler, + kExternalInterface, + //kMultitouchInterface, ? + //kVirtualKeyboardInterface, ? + kFileOpener, + kURLBuilder, + kImageCreator, + kImageFileHandlerRegistry, + kParseControl, + kProgressHandler, + kImportVisitor, + kFontPackParams, + kFontLib, + kFontProvider, + kFontMap, + kTaskManager, + kTextClipboard, + kTextKeyMap, + kIMEManager, + kXMLSupport, + kZlibSupport, + kFontCompactorParams, + kImagePackerParams, + kAudio, + kVideo, + kTestStream, + kSharedObject, + kLocSupport, + kAS2Support, + kAS3Support + }; + + [[nodiscard]] constexpr auto GetStateType() const noexcept + { + return *stateType; + } + + protected: + // members + stl::enumeration stateType; + }; + static_assert(sizeof(State) == 0x18); +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h b/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h new file mode 100644 index 00000000..011b0d42 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h @@ -0,0 +1,26 @@ +#pragma once + +#include "RE/S/ScaleformGFxFileTypeConstants.h" +#include "RE/S/ScaleformGFxState.h" + +namespace RE::Scaleform::GFx +{ + class StateBag : + public FileTypeConstants // 00 + { + protected: + // add + virtual StateBag* GetStateBagImpl() const { return nullptr; } // 00 + + public: + SF_RTTI_VTABLE(Scaleform__GFx__StateBag); + + virtual ~StateBag() = default; // 01 + + // add + virtual void SetState(State::StateType a_stateType, State* a_state); // 02 + virtual State* GetStateAddRef(State::StateType a_stateType) const; // 03 + virtual void GetStatesAddRef(State** a_states, const State::StateType* a_stateTypes, std::uint32_t a_count) const; // 04 + }; + //static_assert(sizeof(StateBag) == 0x8); +} diff --git a/CommonLibSF/include/RE/S/ScaleformGFxValue.h b/CommonLibSF/include/RE/S/ScaleformGFxValue.h new file mode 100644 index 00000000..1a1a9656 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformGFxValue.h @@ -0,0 +1,691 @@ +#pragma once + +namespace RE::Scaleform::GFx +{ + class MovieImpl; + + class Value + { + public: + enum class ValueType : std::int32_t + { + kUndefined, + kNull, + kBoolean, + kInt, + kUInt, + kNumber, + kString, + kStringW, + kObject, + kArray, + kDisplayObject, + kClosure, + + kOrphanedBit = 1 << 5, + kManagedBit = 1 << 6, + kConvertBit = 1 << 7, + + kTypeMask = kConvertBit | 0x0F, + + kConvertBoolean = kConvertBit | kBoolean, + kConvertInt = kConvertBit | kInt, + kConvertUInt = kConvertBit | kUInt, + kConvertNumber = kConvertBit | kNumber, + kConvertString = kConvertBit | kString, + kConvertStringW = kConvertBit | kStringW + }; + + union ValueUnion + { + ValueUnion() noexcept : + data(nullptr) + {} + + ValueUnion(const ValueUnion& a_rhs) noexcept : + data(a_rhs.data) + {} + + ValueUnion(ValueUnion&& a_rhs) noexcept : + data(a_rhs.data) + { + a_rhs.data = nullptr; + } + + explicit ValueUnion(const std::int32_t a_rhs) noexcept : + int32(a_rhs) + {} + + explicit ValueUnion(const std::uint32_t a_rhs) noexcept : + uint32(a_rhs) + {} + + explicit ValueUnion(const double a_rhs) noexcept : + number(a_rhs) + {} + + explicit ValueUnion(const bool a_rhs) noexcept : + boolean(a_rhs) + {} + + explicit ValueUnion(const char* a_rhs) noexcept : + string(a_rhs) + {} + + explicit ValueUnion(const wchar_t* a_rhs) noexcept : + wstring(a_rhs) + {} + + ValueUnion& operator=(const ValueUnion& a_rhs) noexcept + { + if (this != std::addressof(a_rhs)) { + data = a_rhs.data; + } + return *this; + } + + ValueUnion& operator=(ValueUnion&& a_rhs) noexcept + { + if (this != std::addressof(a_rhs)) { + data = a_rhs.data; + a_rhs.data = nullptr; + } + return *this; + } + + ValueUnion& operator=(const std::int32_t a_rhs) noexcept + { + int32 = a_rhs; + return *this; + } + + ValueUnion& operator=(const std::uint32_t a_rhs) noexcept + { + uint32 = a_rhs; + return *this; + } + + ValueUnion& operator=(const double a_rhs) noexcept + { + number = a_rhs; + return *this; + } + + ValueUnion& operator=(const bool a_rhs) noexcept + { + boolean = a_rhs; + return *this; + } + + ValueUnion& operator=(const char* a_rhs) noexcept + { + string = a_rhs; + return *this; + } + + ValueUnion& operator=(const wchar_t* a_rhs) noexcept + { + wstring = a_rhs; + return *this; + } + + std::int32_t int32; + std::uint32_t uint32; + double number; + bool boolean; + const char* string; + const char** mstring; + const wchar_t* wstring; + void* data; + }; + static_assert(sizeof(ValueUnion) == 0x8); + + + class ObjectInterface + { + public: + class ArrVisitor + { + public: + virtual ~ArrVisitor() = default; // 00 + + // add + virtual void Visit(std::uint32_t a_idx, const Value& a_val) = 0; // 00 + }; + static_assert(sizeof(ArrVisitor) == 0x8); + + class ObjVisitor + { + public: + virtual ~ObjVisitor() = default; // 00 + + // add + virtual bool IncludeAS3PublicMembers() const { return false; } // 01 + virtual void Visit(const char* a_name, const Value& a_val) = 0; // 02 + }; + static_assert(sizeof(ObjVisitor) == 0x8); + + virtual ~ObjectInterface() = default; // 00 + + + void ObjectAddRef(Value* a_val, void* a_obj) + { + using func_t = decltype(&ObjectInterface::ObjectRelease); + REL::Relocation func{ REL::ID(57288) }; + return func(this, a_val, a_obj); + } + + void ObjectRelease(Value* a_val, void* a_obj) + { + using func_t = decltype(&ObjectInterface::ObjectRelease); + REL::Relocation func{ REL::ID(57289) }; + return func(this, a_val, a_obj); + } + + bool HasMember(void* a_data, const char* a_name, bool a_isdobj) const + { + using func_t = decltype(&ObjectInterface::HasMember); + REL::Relocation func{ REL::ID(57290) }; + return func(this, a_data, a_name, a_isdobj); + } + + bool GetMember(void* a_data, const char* a_name, Value* a_val, bool a_isdobj) const + { + using func_t = decltype(&ObjectInterface::GetMember); + REL::Relocation func{ REL::ID(57291) }; + return func(this, a_data, a_name, a_val, a_isdobj); + } + + bool SetMember(void* a_data, const char* a_name, const Value& a_value, bool a_isdobj) + { + using func_t = decltype(&ObjectInterface::SetMember); + REL::Relocation func{ REL::ID(57292) }; + return func(this, a_data, a_name, a_value, a_isdobj); + } + + bool Invoke(void* a_data, Value* a_result, const char* a_name, const Value* a_args, std::size_t a_numArgs, bool a_isdobj) + { + using func_t = decltype(&ObjectInterface::Invoke); + REL::Relocation func{ REL::ID(57293) }; + return func(this, a_data, a_result, a_name, a_args, a_numArgs, a_isdobj); + } + + void VisitMembers(void* a_data, ObjVisitor* a_visitor, bool a_isdobj) + { + using func_t = decltype(&ObjectInterface::VisitMembers); + REL::Relocation func{ REL::ID(57296) }; + return func(this, a_data, a_visitor, a_isdobj); + } + + std::uint32_t GetArraySize(void* a_data) + { + using func_t = decltype(&ObjectInterface::GetArraySize); + REL::Relocation func{ REL::ID(57297) }; + return func(this, a_data); + } + + bool SetArraySize(void* a_data, std::uint32_t a_size) + { + using func_t = decltype(&ObjectInterface::SetArraySize); + REL::Relocation func{ REL::ID(57298) }; + return func(this, a_data, a_size); + } + + bool GetElement(void* a_data, std::uint32_t a_index, Value* a_value) + { + using func_t = decltype(&ObjectInterface::GetElement); + REL::Relocation func{ REL::ID(57299) }; + return func(this, a_data, a_index, a_value); + } + + bool SetElement(void* a_data, std::uint32_t a_index, const Value& a_value) + { + using func_t = decltype(&ObjectInterface::SetElement); + REL::Relocation func{ REL::ID(57300) }; + return func(this, a_data, a_index, a_value); + } + + void VisitElements(void* a_data, ArrVisitor* a_visitor, std::uint32_t a_index, std::int32_t a_count) + { + using func_t = decltype(&ObjectInterface::VisitElements); + REL::Relocation func{ REL::ID(57301) }; + return func(this, a_data, a_visitor, a_index, a_count); + } + + bool PushBack(void* a_data, const Value& a_value) + { + using func_t = decltype(&ObjectInterface::PushBack); + REL::Relocation func{ REL::ID(57303) }; + return func(this, a_data, a_value); + } + + bool PopBack(void* a_data, Value* a_value) + { + using func_t = decltype(&ObjectInterface::PopBack); + REL::Relocation func{ REL::ID(57304) }; + return func(this, a_data, a_value); + } + + bool RemoveElements(void* a_data, std::uint32_t a_index, std::int32_t a_count) + { + using func_t = decltype(&ObjectInterface::RemoveElements); + REL::Relocation func{ REL::ID(57305) }; + return func(this, a_data, a_index, a_count); + } + + bool GetParent(void* a_data, Value* a_value) + { + using func_t = decltype(&ObjectInterface::GetParent); + REL::Relocation func{ REL::ID(57314) }; + return func(this, a_data, a_value); + } + + bool GetText(void* a_data, Value* a_value, bool a_html) + { + using func_t = decltype(&ObjectInterface::GetText); + REL::Relocation func{ REL::ID(57324) }; + return func(this, a_data, a_value, a_html); + } + + bool SetText(void* a_data, const char* a_text, bool a_html) + { + using func_t = decltype(&ObjectInterface::SetText); + REL::Relocation func{ REL::ID(57325) }; + return func(this, a_data, a_text, a_html); + } + + bool SetTextW(void* a_data, const wchar_t* a_text, bool a_html) + { + using func_t = decltype(&ObjectInterface::SetTextW); + REL::Relocation func{ REL::ID(57326) }; + return func(this, a_data, a_text, a_html); + } + + bool CreateEmptyMovieClip(void* a_data, Value* a_value, const char* a_name, std::int32_t a_depth) + { + using func_t = decltype(&ObjectInterface::CreateEmptyMovieClip); + REL::Relocation func{ REL::ID(57327) }; + return func(this, a_data, a_value, a_name, a_depth); + } + + // members + MovieImpl* movieRoot; // 08 + }; + static_assert(sizeof(ObjectInterface) == 0x10); + + using ArrayVisitor = ObjectInterface::ArrVisitor; + using ObjectVisitor = ObjectInterface::ObjVisitor; + + Value() noexcept = default; + + Value(const Value& a_rhs) : + _type(a_rhs._type), + _value(a_rhs._value), + _dataAux(a_rhs._dataAux) + { + if (a_rhs.IsManagedValue()) { + AcquireManagedValue(a_rhs); + } + } + + Value(Value&& a_rhs) noexcept : + _objectInterface(a_rhs._objectInterface), + _type(a_rhs._type), + _value(std::move(a_rhs._value)), + _dataAux(a_rhs._dataAux) + { + a_rhs._objectInterface = nullptr; + a_rhs._type = ValueType::kUndefined; + a_rhs._dataAux = 0; + } + + Value(const std::nullptr_t) noexcept : + _type(ValueType::kNull) + {} + + Value(const std::int32_t a_rhs) noexcept : + _type(ValueType::kInt), + _value(a_rhs) + {} + + Value(const std::uint32_t a_rhs) noexcept : + _type(ValueType::kUInt), + _value(a_rhs) + {} + + Value(const double a_rhs) noexcept : + _type(ValueType::kNumber), + _value(a_rhs) + {} + + Value(const bool a_rhs) noexcept : + _type(ValueType::kBoolean), + _value(a_rhs) + {} + + Value(const char* a_rhs) noexcept : + _type(ValueType::kString), + _value(a_rhs) + {} + + Value(const wchar_t* a_rhs) noexcept : + _type(ValueType::kStringW), + _value(a_rhs) + {} + + ~Value() + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kUndefined; + } + + Value& operator=(const Value& a_rhs) + { + if (this != std::addressof(a_rhs)) { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = a_rhs._type; + _value = a_rhs._value; + _dataAux = a_rhs._dataAux; + + if (a_rhs.IsManagedValue()) { + AcquireManagedValue(a_rhs); + } + } + return *this; + } + + Value& operator=(Value&& a_rhs) noexcept + { + if (this != std::addressof(a_rhs)) { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _objectInterface = a_rhs._objectInterface; + a_rhs._objectInterface = nullptr; + + _type = a_rhs._type; + a_rhs._type = ValueType::kUndefined; + + _value = std::move(a_rhs._value); + + _dataAux = a_rhs._dataAux; + a_rhs._dataAux = 0; + } + return *this; + } + + Value& operator=(const std::nullptr_t) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kNull; + return *this; + } + + Value& operator=(const std::int32_t a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kInt; + _value = a_rhs; + return *this; + } + + Value& operator=(const std::uint32_t a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kUInt; + _value = a_rhs; + return *this; + } + + Value& operator=(const double a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kNumber; + _value = a_rhs; + return *this; + } + + Value& operator=(const bool a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kBoolean; + _value = a_rhs; + return *this; + } + + Value& operator=(const char* a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kString; + _value = a_rhs; + return *this; + } + + Value& operator=(const wchar_t* a_rhs) noexcept + { + if (IsManagedValue()) { + ReleaseManagedValue(); + } + + _type = ValueType::kStringW; + _value = a_rhs; + return *this; + } + + [[nodiscard]] ValueType GetType() const noexcept { return *(_type & ValueType::kTypeMask); } + + [[nodiscard]] bool IsArray() const noexcept { return GetType() == ValueType::kArray; } + [[nodiscard]] bool IsBoolean() const noexcept { return GetType() == ValueType::kBoolean; } + [[nodiscard]] bool IsDisplayObject() const noexcept { return GetType() == ValueType::kDisplayObject; } + [[nodiscard]] bool IsInt() const noexcept { return GetType() == ValueType::kInt; } + [[nodiscard]] bool IsNumber() const noexcept { return GetType() == ValueType::kNumber; } + [[nodiscard]] bool IsString() const noexcept { return GetType() == ValueType::kString; } + [[nodiscard]] bool IsStringW() const noexcept { return GetType() == ValueType::kStringW; } + [[nodiscard]] bool IsUndefined() const noexcept { return GetType() == ValueType::kUndefined; } + [[nodiscard]] bool IsUInt() const noexcept { return GetType() == ValueType::kUInt; } + + [[nodiscard]] bool IsObject() const noexcept + { + switch (GetType()) { + case ValueType::kObject: + case ValueType::kArray: + case ValueType::kDisplayObject: + return true; + } + + return false; + } + + [[nodiscard]] bool GetBoolean() const + { + assert(IsBoolean()); + return _value.boolean; + } + + [[nodiscard]] std::int32_t GetInt() const + { + assert(IsInt()); + return _value.int32; + } + + [[nodiscard]] double GetNumber() const + { + assert(IsNumber()); + return _value.number; + } + + [[nodiscard]] const char* GetString() const + { + assert(IsString()); + return IsManagedValue() ? *_value.mstring : _value.string; + } + + [[nodiscard]] const wchar_t* GetStringW() const + { + assert(IsStringW()); + return _value.wstring; + } + + [[nodiscard]] std::uint32_t GetUInt() const + { + assert(IsUInt()); + return _value.uint32; + } + + bool CreateEmptyMovieClip(Value* a_value, const char* a_name, std::int32_t a_depth = -1) + { + return _objectInterface->CreateEmptyMovieClip(_value.data, a_value, a_name, a_depth); + } + + bool GetMember(stl::zstring a_name, Value* a_value) const + { + return _objectInterface->GetMember(_value.data, a_name.data(), a_value, IsDisplayObject()); + } + + [[nodiscard]] Movie* GetMovie() const + { + assert(_objectInterface && _objectInterface->movieRoot); + return reinterpret_cast(_objectInterface->movieRoot); + } + + bool GetParent(Value* a_value) const + { + return _objectInterface->GetParent(_value.data, a_value); + } + + bool GetText(Value* a_value) const + { + assert(IsString()); + return _objectInterface->GetText(_value.data, a_value, false); + } + + bool GetTextHTML(Value* a_value) const + { + assert(IsString()); + return _objectInterface->GetText(_value.data, a_value, true); + } + + [[nodiscard]] bool HasMember(stl::zstring a_name) const + { + return _objectInterface->HasMember(_value.data, a_name.data(), IsDisplayObject()); + } + + bool Invoke(const char* a_name, Value* a_result, const Value* a_args, std::size_t a_numArgs) + { + return _objectInterface->Invoke(_value.data, a_result, a_name, a_args, a_numArgs, IsDisplayObject()); + } + + bool Invoke(const char* a_name, Value* a_result = nullptr) + { + return Invoke(a_name, a_result, nullptr, 0); + } + + bool PopBack(Value* a_value = nullptr) + { + return _objectInterface->PopBack(_value.data, a_value); + } + + bool PushBack(const Value& a_value) + { + return _objectInterface->PushBack(_value.data, a_value); + } + + bool RemoveElements(std::uint32_t a_index, std::int32_t a_count = -1) + { + return _objectInterface->RemoveElements(_value.data, a_index, a_count); + } + + bool RemoveElement(std::uint32_t a_index) + { + return RemoveElements(a_index, 1); + } + + bool SetArraySize(std::uint32_t a_size) + { + return _objectInterface->SetArraySize(_value.data, a_size); + } + + bool SetMember(stl::zstring a_name, const Value& a_value) + { + return _objectInterface->SetMember(_value.data, a_name.data(), a_value, IsDisplayObject()); + } + + bool SetText(stl::zstring a_text) + { + return _objectInterface->SetText(_value.data, a_text.data(), false); + } + + bool SetTextHTML(stl::zstring a_text) + { + return _objectInterface->SetText(_value.data, a_text.data(), true); + } + + void VisitElements(ArrayVisitor* a_visitor, std::uint32_t a_index, std::int32_t a_count = -1) + { + _objectInterface->VisitElements(_value.data, a_visitor, a_index, a_count); + } + + void VisitElements(ArrayVisitor* a_visitor) + { + VisitElements(a_visitor, 0); + } + + void VisitMembers(ObjectVisitor* a_visitor) + { + _objectInterface->VisitMembers(_value.data, a_visitor, IsDisplayObject()); + } + + private: + void AcquireManagedValue(const Value& a_rhs) + { + assert(a_rhs._value.data && a_rhs._objectInterface); + _objectInterface = a_rhs._objectInterface; + _objectInterface->ObjectAddRef(this, _value.data); + } + + [[nodiscard]] bool IsManagedValue() const noexcept + { + const auto managed = _type.all(ValueType::kManagedBit); + assert(managed ? _objectInterface != nullptr : true); + return managed; + } + + void ReleaseManagedValue() + { + assert(_value.data && _objectInterface); + _objectInterface->ObjectRelease(this, _value.data); + _objectInterface = nullptr; + } + + // members + ObjectInterface* _objectInterface{}; // 00 + stl::enumeration _type{ ValueType::kUndefined }; // 08 + ValueUnion _value{}; // 10 + std::size_t _dataAux{}; // 18 + }; +} diff --git a/CommonLibSF/include/RE/S/ScaleformPtr.h b/CommonLibSF/include/RE/S/ScaleformPtr.h new file mode 100644 index 00000000..8d601422 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformPtr.h @@ -0,0 +1,230 @@ +#pragma once + +namespace RE::Scaleform +{ + template + class Ptr + { + public: + using element_type = T; + + constexpr Ptr() noexcept = default; + constexpr Ptr(std::nullptr_t) noexcept {} + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + explicit Ptr(Y* a_rhs) : + _ptr(a_rhs) + { + TryAttach(); + } + + Ptr(const Ptr& a_rhs) : + _ptr(a_rhs._ptr) + { + TryAttach(); + } + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + Ptr(const Ptr& a_rhs) : + _ptr(a_rhs._ptr) + { + TryAttach(); + } + + Ptr(Ptr&& a_rhs) noexcept : + _ptr(a_rhs._ptr) + { + a_rhs._ptr = nullptr; + } + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + Ptr(Ptr&& a_rhs) noexcept : + _ptr(a_rhs._ptr) + { + a_rhs._ptr = nullptr; + } + + ~Ptr() { TryDetach(); } + + Ptr& operator=(const Ptr& a_rhs) + { + if (this != std::addressof(a_rhs)) { + TryDetach(); + _ptr = a_rhs._ptr; + TryAttach(); + } + return *this; + } + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + Ptr& operator=(const Ptr& a_rhs) + { + TryDetach(); + _ptr = a_rhs._ptr; + TryAttach(); + return *this; + } + + Ptr& operator=(Ptr&& a_rhs) + { + if (this != std::addressof(a_rhs)) { + TryDetach(); + _ptr = a_rhs._ptr; + a_rhs._ptr = nullptr; + } + return *this; + } + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + Ptr& operator=(Ptr&& a_rhs) + { + TryDetach(); + _ptr = a_rhs._ptr; + a_rhs._ptr = nullptr; + return *this; + } + + void reset() { TryDetach(); } + + template < + class Y, + std::enable_if_t< + std::is_convertible_v< + Y*, + element_type*>, + int> = 0> + void reset(Y* a_ptr) + { + if (_ptr != a_ptr) { + TryDetach(); + _ptr = a_ptr; + TryAttach(); + } + } + + [[nodiscard]] constexpr element_type* get() const noexcept + { + return _ptr; + } + + [[nodiscard]] explicit constexpr operator bool() const noexcept + { + return static_cast(_ptr); + } + + [[nodiscard]] constexpr element_type& operator*() const noexcept + { + assert(static_cast(*this)); + return *_ptr; + } + + [[nodiscard]] constexpr element_type* operator->() const noexcept + { + assert(static_cast(*this)); + return _ptr; + } + + protected: + template + friend class Ptr; + + void TryAttach() + { + if (_ptr) { + _ptr->AddRef(); + } + } + + void TryDetach() + { + if (_ptr) { + _ptr->Release(); + _ptr = nullptr; + } + } + + // members + element_type* _ptr{ nullptr }; // 00 + }; + static_assert(sizeof(Ptr) == 0x8); + + template + [[nodiscard]] Ptr make_shared(Args&&... a_args) + { + auto ptr = Ptr{ new T(std::forward(a_args)...) }; + if (ptr) { + ptr->Release(); + } + + return ptr; + } + + template + [[nodiscard]] constexpr bool operator==(const Ptr& a_lhs, const Ptr& a_rhs) + { + return a_lhs.get() == a_rhs.get(); + } + + template + [[nodiscard]] constexpr bool operator!=(const Ptr& a_lhs, const Ptr& a_rhs) + { + return !(a_lhs == a_rhs); + } + + template + [[nodiscard]] constexpr bool operator==(const Ptr& a_lhs, std::nullptr_t) noexcept + { + return !a_lhs; + } + + template + [[nodiscard]] constexpr bool operator==(std::nullptr_t, const Ptr& a_rhs) noexcept + { + return !a_rhs; + } + + template + [[nodiscard]] constexpr bool operator!=(const Ptr& a_lhs, std::nullptr_t) noexcept + { + return static_cast(a_lhs); + } + + template + [[nodiscard]] constexpr bool operator!=(std::nullptr_t, const Ptr& a_rhs) noexcept + { + return static_cast(a_rhs); + } + + template + Ptr(T*) -> Ptr; +} diff --git a/CommonLibSF/include/RE/S/ScaleformRefCount.h b/CommonLibSF/include/RE/S/ScaleformRefCount.h new file mode 100644 index 00000000..6b3b37b5 --- /dev/null +++ b/CommonLibSF/include/RE/S/ScaleformRefCount.h @@ -0,0 +1,63 @@ +#pragma once + +namespace RE::Scaleform +{ + class RefCountImplCore + { + public: + SF_RTTI_VTABLE(Scaleform__RefCountImplCore); + + RefCountImplCore() = default; + + virtual ~RefCountImplCore() = default; // 00 + + protected: + // members + volatile std::int32_t refCount{ 1 }; // 08 + }; + static_assert(sizeof(RefCountImplCore) == 0x10); + + class RefCountImpl : + public RefCountImplCore // 00 + { + public: + SF_RTTI(Scaleform__RefCountImpl); + + virtual ~RefCountImpl() override = default; // 00 + + void AddRef() + { + stl::atomic_ref myRefCount{ refCount }; + ++refCount; + } + + void Release() + { + stl::atomic_ref myRefCount{ refCount }; + if (--myRefCount == 0) { + delete this; + } + } + }; + static_assert(sizeof(RefCountImpl) == 0x10); + + template + class RefCountBaseStatImpl : + public Base // 00 + { + public: + RefCountBaseStatImpl() = default; + + virtual ~RefCountBaseStatImpl() = default; // 00 + }; + + template + class RefCountBase : + public RefCountBaseStatImpl // 00 + { + public: + RefCountBase() = default; + + virtual ~RefCountBase() = default; // 00 + }; +} diff --git a/CommonLibSF/include/RE/Starfield.h b/CommonLibSF/include/RE/Starfield.h index 877b5203..501dd203 100644 --- a/CommonLibSF/include/RE/Starfield.h +++ b/CommonLibSF/include/RE/Starfield.h @@ -34,15 +34,18 @@ #include "RE/B/BGSTerminal.h" #include "RE/B/BSFixedString.h" #include "RE/B/BSInputEventReceiver.h" +#include "RE/B/BSInputEventUser.h" #include "RE/B/BSIntrusiveRefCounted.h" #include "RE/B/BSReflection.h" #include "RE/B/BSStringPool.h" #include "RE/B/BSStringT.h" +#include "RE/B/BSTArray.h" #include "RE/B/BSTEvent.h" #include "RE/B/BSTList.h" #include "RE/B/BSTSingleton.h" #include "RE/B/BaseFormComponent.h" #include "RE/C/CombatGroup.h" +#include "RE/C/Console.h" #include "RE/C/ConsoleLog.h" #include "RE/E/ExtraDataTypes.h" #include "RE/F/FORM_ENUM_STRING.h" @@ -50,6 +53,7 @@ #include "RE/I/IAnimationGraphManagerHolder.h" #include "RE/I/IFunction.h" #include "RE/I/IKeywordFormBase.h" +#include "RE/I/IMenu.h" #include "RE/I/IMovementInterface.h" #include "RE/I/IMovementPlayerControlsFilter.h" #include "RE/I/IMovementState.h" @@ -73,11 +77,21 @@ #include "RE/P/PlayerCharacter.h" #include "RE/R/RegSettingCollection.h" #include "RE/RTTI.h" +#include "RE/S/ScaleformGFxASMovieRootBase.h" +#include "RE/S/ScaleformGFxFileTypeConstants.h" +#include "RE/S/ScaleformGFxFunctionHandler.h" +#include "RE/S/ScaleformGFxMovie.h" +#include "RE/S/ScaleformGFxState.h" +#include "RE/S/ScaleformGFxStateBag.h" +#include "RE/S/ScaleformGFxValue.h" +#include "RE/S/ScaleformPtr.h" +#include "RE/S/ScaleformRefCount.h" #include "RE/S/Script.h" #include "RE/S/SettingCollection.h" #include "RE/S/SettingCollectionList.h" #include "RE/S/SettingCollectionMap.h" #include "RE/S/Settings.h" +#include "RE/S/SWFToCodeFunctionHandler.h" #include "RE/T/TBO_InstanceData.h" #include "RE/T/TESAIForm.h" #include "RE/T/TESActorBase.h" diff --git a/CommonLibSF/include/RE/U/UI.h b/CommonLibSF/include/RE/U/UI.h index bee954ae..a4ff86a1 100644 --- a/CommonLibSF/include/RE/U/UI.h +++ b/CommonLibSF/include/RE/U/UI.h @@ -2,9 +2,44 @@ namespace RE { - class UI + class IMenu; + + namespace Scaleform + { + template + class Ptr; + } + + struct BIUIMenuVisiblePausedBeginEvent; + struct BIUIMenuVisiblePausedEndEvent; + struct BSCursorRotationChange; + struct BSCursorTypeChange; + struct MenuPauseChangeEvent; + struct MenuPauseCounterChangeEvent; + struct TutorialEvent; + + class UI : + //public BSTSingletonSDM, + public BSInputEventReceiver, // 000 + public BSTEventSource, // 010 + public BSTEventSource, // 038 + public BSTEventSource, // 060 + public BSTEventSource, // 088 + public BSTEventSource, // 0B0 + public BSTEventSource, // 0D8 + public BSTEventSource, // 100 + public BSTEventSource, // 128 + public BSTEventSource // 150 { public: + SF_RTTI_VTABLE(UI); + + template + [[nodiscard]] auto GetEventSource() + { + return static_cast*>(this); + } + inline static UI* GetSingleton() { static REL::Relocation singleton{ REL::ID(878339) }; @@ -17,5 +52,21 @@ namespace RE REL::Relocation func{ REL::ID(187049) }; return func(this, a_name); } + + template + void RegisterSink(BSTEventSink* a_sink) + { + GetEventSource()->RegisterSink(a_sink); + } + + template + void UnregisterSink(BSTEventSink* a_sink) + { + GetEventSource()->UnregisterSink(a_sink); + } + + std::uint8_t pad178[0x278]; // 178 + BSTArray> menuStack; // 3F0 }; + static_assert(offsetof(UI, menuStack) == 0x3F0); } From 0c585314c3f85fa00b8303ccf58520a3b6618da4 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 1 Oct 2023 01:50:01 +0000 Subject: [PATCH 18/21] ci: maintenance `2023-10-01` --- CommonLibSF/include/RE/B/BSTArray.h | 2 +- CommonLibSF/include/RE/C/Console.h | 2 +- CommonLibSF/include/RE/I/IMenu.h | 58 ++--- .../include/RE/S/SWFToCodeFunctionHandler.h | 2 +- .../RE/S/ScaleformGFxASMovieRootBase.h | 198 +++++++++--------- CommonLibSF/include/RE/S/ScaleformGFxMovie.h | 4 +- .../include/RE/S/ScaleformGFxStateBag.h | 6 +- CommonLibSF/include/RE/S/ScaleformGFxValue.h | 2 - CommonLibSF/include/RE/Starfield.h | 3 +- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 11 files changed, 140 insertions(+), 141 deletions(-) diff --git a/CommonLibSF/include/RE/B/BSTArray.h b/CommonLibSF/include/RE/B/BSTArray.h index 110181f8..3696f595 100644 --- a/CommonLibSF/include/RE/B/BSTArray.h +++ b/CommonLibSF/include/RE/B/BSTArray.h @@ -2,7 +2,7 @@ namespace RE { - template + template class BSTArray { public: diff --git a/CommonLibSF/include/RE/C/Console.h b/CommonLibSF/include/RE/C/Console.h index c98df0e5..7c2bad39 100644 --- a/CommonLibSF/include/RE/C/Console.h +++ b/CommonLibSF/include/RE/C/Console.h @@ -4,7 +4,7 @@ namespace RE { - class Console : + class Console : public GameMenuBase // 00 { public: diff --git a/CommonLibSF/include/RE/I/IMenu.h b/CommonLibSF/include/RE/I/IMenu.h index 8bc3f03b..ac24d0b6 100644 --- a/CommonLibSF/include/RE/I/IMenu.h +++ b/CommonLibSF/include/RE/I/IMenu.h @@ -2,9 +2,9 @@ #include "RE/B/BSInputEventUser.h" #include "RE/B/BSTEvent.h" +#include "RE/S/SWFToCodeFunctionHandler.h" #include "RE/S/ScaleformGFxMovie.h" #include "RE/S/ScaleformGFxValue.h" -#include "RE/S/SWFToCodeFunctionHandler.h" namespace RE { @@ -46,34 +46,34 @@ namespace RE virtual void Unk_19(void); // 19 virtual void Unk_1A(void); // 1A - std::int64_t unk058; // 058 - std::int64_t unk060; // 060 - Scaleform::GFx::Value menuObj; // 080 - Scaleform::Ptr uiMovie; // 088 - std::uint64_t unk090; // 090 - std::uint64_t unk098; // 098 - std::uint64_t unk0A0; // 0A0 - std::uint32_t unk0A8; // 0A8 - std::uint32_t unk0AC; // 0AC - BSFixedString menuName; // 0B0 - BSFixedString unk0B8; // 0B8 - std::uint64_t unk0C0; // 0C0 - std::uint32_t unk0C8; // 0C8 - std::uint32_t unk0CC; // 0CC - std::uint32_t unk0D0; // 0D0 - std::uint32_t unk0D4; // 0D4 - std::uint64_t unk0D8; // 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::uint32_t unk108; // 108 - std::uint32_t unk10C; // 10C - std::uint64_t unk110; // 110 - std::uint64_t unk118; // 118 - std::uint64_t unk120; // 120 - std::uint64_t unk128; // 128 + std::int64_t unk058; // 058 + std::int64_t unk060; // 060 + Scaleform::GFx::Value menuObj; // 080 + Scaleform::Ptr uiMovie; // 088 + std::uint64_t unk090; // 090 + std::uint64_t unk098; // 098 + std::uint64_t unk0A0; // 0A0 + std::uint32_t unk0A8; // 0A8 + std::uint32_t unk0AC; // 0AC + BSFixedString menuName; // 0B0 + BSFixedString unk0B8; // 0B8 + std::uint64_t unk0C0; // 0C0 + std::uint32_t unk0C8; // 0C8 + std::uint32_t unk0CC; // 0CC + std::uint32_t unk0D0; // 0D0 + std::uint32_t unk0D4; // 0D4 + std::uint64_t unk0D8; // 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::uint32_t unk108; // 108 + std::uint32_t unk10C; // 10C + std::uint64_t unk110; // 110 + std::uint64_t unk118; // 118 + std::uint64_t unk120; // 120 + std::uint64_t unk128; // 128 }; static_assert(offsetof(IMenu, uiMovie) == 0x088); static_assert(offsetof(IMenu, menuName) == 0x0B0); diff --git a/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h b/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h index f3791690..bd211cae 100644 --- a/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h +++ b/CommonLibSF/include/RE/S/SWFToCodeFunctionHandler.h @@ -16,7 +16,7 @@ namespace RE void Call(const Params&) override { return; } // 01 // add - virtual void MapCodeObjectFunctions() { return; } // 02 + virtual void MapCodeObjectFunctions() { return; } // 02 }; static_assert(sizeof(SWFToCodeFunctionHandler) == 0x10); } diff --git a/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h b/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h index 913b448a..cede8b2d 100644 --- a/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h +++ b/CommonLibSF/include/RE/S/ScaleformGFxASMovieRootBase.h @@ -2,114 +2,114 @@ namespace RE::Scaleform { - template - class ArrayPOD; + template + class ArrayPOD; - class Log; - class String; + class Log; + class String; - namespace Render::Text - { - class Allocator; - } + namespace Render::Text + { + class Allocator; + } } namespace RE::Scaleform::GFx { - class AccelerometerEvent; - class AmpMovieObjectDesc; - class AppLifecycleEvent; - class ASString; - class ASStringManager; - class DisplayObjContainer; - class DisplayObject; - class EventId; - class GeolocationEvent; - class InputEventsQueueEntry; - class InteractiveObject; - class LoadStates; - class LoadQueueEntry; - class MemoryContext; - class MemoryHeap; - class MouseState; - class MovieDefImpl; - class MovieDefRootNode; - class MovieImpl; - class OrientationEvent; + class AccelerometerEvent; + class AmpMovieObjectDesc; + class AppLifecycleEvent; + class ASString; + class ASStringManager; + class DisplayObjContainer; + class DisplayObject; + class EventId; + class GeolocationEvent; + class InputEventsQueueEntry; + class InteractiveObject; + class LoadStates; + class LoadQueueEntry; + class MemoryContext; + class MemoryHeap; + class MouseState; + class MovieDefImpl; + class MovieDefRootNode; + class MovieImpl; + class OrientationEvent; - struct ProcessFocusKeyInfo; + struct ProcessFocusKeyInfo; - enum class FocusMovedType; + enum class FocusMovedType; - class ASMovieRootBase - { - public: - SF_RTTI_VTABLE(Scaleform__GFx__ASMovieRootBase); + class ASMovieRootBase + { + public: + SF_RTTI_VTABLE(Scaleform__GFx__ASMovieRootBase); - virtual ~ASMovieRootBase() = default; // 00 + virtual ~ASMovieRootBase() = default; // 00 - // add - virtual void SetMovie(MovieImpl* a_movie); // 01 - virtual void AdvanceFrame(bool a_nextFrame) = 0; // 02 - virtual void ChangeMouseCursorType(std::uint32_t a_mouseIndex, std::uint32_t a_newCursorType) = 0; // 03 - virtual bool CheckAvm() = 0; // 04 - virtual void ClearDisplayList() = 0; // 05 - virtual MovieDefRootNode* CreateMovieDefRootNode(MemoryHeap* a_heap, MovieDefImpl* a_defImpl, bool a_importFlag) = 0; // 06 - virtual void DoActions() = 0; // 07 - virtual InteractiveObject* FindTarget(const ASString& a_path) const = 0; // 08 - virtual void ForceCollect() = 0; // 09 - virtual void ForceEmergencyCollect() = 0; // 0A - virtual void SuspendGC() = 0; // 0B - virtual void ScheduleGC() = 0; // 0C - virtual void GenerateMouseEvents(std::uint32_t a_mouseIndex) = 0; // 0D - virtual void GenerateTouchEvents(std::uint32_t a_mouseStateIndex); // 0E - virtual void GenerateGestureEvents(void); // 0F - virtual DisplayObjContainer* GetRootMovie(DisplayObject* a_dobj = nullptr) const = 0; // 10 - virtual bool Init(MovieDefImpl* a_movieDef) = 0; // 11 - virtual void NotifyMouseEvent(const InputEventsQueueEntry* a_qe, const MouseState& a_ms, std::int32_t a_mi) = 0; // 12 - virtual void NotifyOnResize() = 0; // 13 - virtual void NotifyQueueSetFocus(InteractiveObject* a_ch, std::uint32_t a_controllerIndex, FocusMovedType a_fmt) = 0; // 14 - virtual void NotifyTransferFocus(InteractiveObject* a_curFocused, InteractiveObject* a_newFocus, std::uint32_t a_controllerIndex) = 0; // 15 - virtual bool NotifyOnFocusChange(InteractiveObject* a_curFocused, InteractiveObject* a_toBeFocused, std::uint32_t a_controllerIndex, FocusMovedType a_fmt, ProcessFocusKeyInfo* a_focusKeyInfo = nullptr) = 0; // 16 - virtual void NotifyGamePadAnalogEvent(const EventId* a_id); // 17 - virtual void NotifyStatusEvent(const EventId* a_id); // 18 - virtual void NotifyAccelerometerEvent(const EventId* a_id, std::int32_t a_evtIDAcc); // 19 - virtual void NotifyGeolocationEvent(const EventId* a_id, std::int32_t a_evtIDGeo); // 1A - virtual void OnMovieFocus(bool a_set) = 0; // 1B - virtual void OnNextFrame() = 0; // 1C - virtual void OnDeviceOrientationChanged(const OrientationEvent&); // 1D - virtual void OnAppLifecycleEvent(const AppLifecycleEvent&); // 1E - virtual void OnAccelerometerEvent(const AccelerometerEvent&); // 1F - virtual void OnGeolocationEvent(const GeolocationEvent&); // 20 - virtual void PrintObjectsReport(std::uint32_t a_flags = 0, Log* a_log = nullptr, const char* a_swfName = nullptr); // 21 - virtual void GetObjectsTree(/* Array>* */ void* a_rootObjects, MemoryHeap* a_heap); // 22 - virtual AmpMovieObjectDesc* GetDisplayObjectsTree(MemoryHeap* a_heap); // 23 - virtual void ProcessLoadQueueEntry(LoadQueueEntry* a_entry, LoadStates* a_ls) = 0; // 24 - virtual void ProcessLoadVarsMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const String& a_data, std::size_t a_fileLen, bool a_succeeded) = 0; // 25 - virtual void ProcessLoadBinaryMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const ArrayPOD& a_data, std::size_t a_fileLen, bool a_succeeded); // 26 - virtual void RegisterAuxASClasses() = 0; // 27 - virtual void ResolveStickyVariables(InteractiveObject* a_character) = 0; // 28 - virtual void SetExternalInterfaceRetVal(const Value&) = 0; // 29 - virtual void SetMemoryParams(std::uint32_t a_frameBetweenCollections, std::uint32_t a_maxRootCount) = 0; // 2A - virtual void Shutdown() = 0; // 2B - virtual void CreateString(Value* a_value, const char* a_string) = 0; // 2C - virtual void CreateStringW(Value* a_value, const wchar_t* a_string) = 0; // 2D - virtual void CreateObject(Value* a_value, const char* a_className = nullptr, const Value* a_args = nullptr, std::uint32_t a_numArgs = 0) = 0; // 2E - virtual void CreateArray(Value* a_value) = 0; // 2F - virtual void CreateFunction(Value* a_value, FunctionHandler* a_fc, void* a_userData = nullptr) = 0; // 30 - virtual bool SetVariable(const char* a_pathToVar, const Value& a_value, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 31 - virtual bool GetVariable(Value* a_val, const char* a_pathToVar) const = 0; // 32 - virtual bool SetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, const void* a_data, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 33 - virtual bool SetVariableArraySize(const char* a_pathToVar, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 35 - virtual std::uint32_t GetVariableArraySize(const char* a_pathToVar) = 0; // 34 - virtual bool GetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, void* a_data, std::uint32_t a_count) = 0; // 36 - virtual bool IsAvailable(const char* a_pathToVar) const = 0; // 37 - virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const Value* a_args, std::uint32_t a_numArgs) = 0; // 39 - virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, ...) = 0; // 38 - virtual bool InvokeArgs(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, std::va_list a_args) = 0; // 3A - virtual MemoryContext* GetMemoryContext() const = 0; // 3B - virtual ASStringManager* GetStringManager() const = 0; // 3C - virtual Render::Text::Allocator* GetTextAllocator() = 0; // 3D - virtual void BroadcastGeolocationStatusEvent(const EventId* a_id) = 0; // 3E - }; + // add + virtual void SetMovie(MovieImpl* a_movie); // 01 + virtual void AdvanceFrame(bool a_nextFrame) = 0; // 02 + virtual void ChangeMouseCursorType(std::uint32_t a_mouseIndex, std::uint32_t a_newCursorType) = 0; // 03 + virtual bool CheckAvm() = 0; // 04 + virtual void ClearDisplayList() = 0; // 05 + virtual MovieDefRootNode* CreateMovieDefRootNode(MemoryHeap* a_heap, MovieDefImpl* a_defImpl, bool a_importFlag) = 0; // 06 + virtual void DoActions() = 0; // 07 + virtual InteractiveObject* FindTarget(const ASString& a_path) const = 0; // 08 + virtual void ForceCollect() = 0; // 09 + virtual void ForceEmergencyCollect() = 0; // 0A + virtual void SuspendGC() = 0; // 0B + virtual void ScheduleGC() = 0; // 0C + virtual void GenerateMouseEvents(std::uint32_t a_mouseIndex) = 0; // 0D + virtual void GenerateTouchEvents(std::uint32_t a_mouseStateIndex); // 0E + virtual void GenerateGestureEvents(void); // 0F + virtual DisplayObjContainer* GetRootMovie(DisplayObject* a_dobj = nullptr) const = 0; // 10 + virtual bool Init(MovieDefImpl* a_movieDef) = 0; // 11 + virtual void NotifyMouseEvent(const InputEventsQueueEntry* a_qe, const MouseState& a_ms, std::int32_t a_mi) = 0; // 12 + virtual void NotifyOnResize() = 0; // 13 + virtual void NotifyQueueSetFocus(InteractiveObject* a_ch, std::uint32_t a_controllerIndex, FocusMovedType a_fmt) = 0; // 14 + virtual void NotifyTransferFocus(InteractiveObject* a_curFocused, InteractiveObject* a_newFocus, std::uint32_t a_controllerIndex) = 0; // 15 + virtual bool NotifyOnFocusChange(InteractiveObject* a_curFocused, InteractiveObject* a_toBeFocused, std::uint32_t a_controllerIndex, FocusMovedType a_fmt, ProcessFocusKeyInfo* a_focusKeyInfo = nullptr) = 0; // 16 + virtual void NotifyGamePadAnalogEvent(const EventId* a_id); // 17 + virtual void NotifyStatusEvent(const EventId* a_id); // 18 + virtual void NotifyAccelerometerEvent(const EventId* a_id, std::int32_t a_evtIDAcc); // 19 + virtual void NotifyGeolocationEvent(const EventId* a_id, std::int32_t a_evtIDGeo); // 1A + virtual void OnMovieFocus(bool a_set) = 0; // 1B + virtual void OnNextFrame() = 0; // 1C + virtual void OnDeviceOrientationChanged(const OrientationEvent&); // 1D + virtual void OnAppLifecycleEvent(const AppLifecycleEvent&); // 1E + virtual void OnAccelerometerEvent(const AccelerometerEvent&); // 1F + virtual void OnGeolocationEvent(const GeolocationEvent&); // 20 + virtual void PrintObjectsReport(std::uint32_t a_flags = 0, Log* a_log = nullptr, const char* a_swfName = nullptr); // 21 + virtual void GetObjectsTree(/* Array>* */ void* a_rootObjects, MemoryHeap* a_heap); // 22 + virtual AmpMovieObjectDesc* GetDisplayObjectsTree(MemoryHeap* a_heap); // 23 + virtual void ProcessLoadQueueEntry(LoadQueueEntry* a_entry, LoadStates* a_ls) = 0; // 24 + virtual void ProcessLoadVarsMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const String& a_data, std::size_t a_fileLen, bool a_succeeded) = 0; // 25 + virtual void ProcessLoadBinaryMT(LoadQueueEntry* a_entry, LoadStates* a_ls, const ArrayPOD& a_data, std::size_t a_fileLen, bool a_succeeded); // 26 + virtual void RegisterAuxASClasses() = 0; // 27 + virtual void ResolveStickyVariables(InteractiveObject* a_character) = 0; // 28 + virtual void SetExternalInterfaceRetVal(const Value&) = 0; // 29 + virtual void SetMemoryParams(std::uint32_t a_frameBetweenCollections, std::uint32_t a_maxRootCount) = 0; // 2A + virtual void Shutdown() = 0; // 2B + virtual void CreateString(Value* a_value, const char* a_string) = 0; // 2C + virtual void CreateStringW(Value* a_value, const wchar_t* a_string) = 0; // 2D + virtual void CreateObject(Value* a_value, const char* a_className = nullptr, const Value* a_args = nullptr, std::uint32_t a_numArgs = 0) = 0; // 2E + virtual void CreateArray(Value* a_value) = 0; // 2F + virtual void CreateFunction(Value* a_value, FunctionHandler* a_fc, void* a_userData = nullptr) = 0; // 30 + virtual bool SetVariable(const char* a_pathToVar, const Value& a_value, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 31 + virtual bool GetVariable(Value* a_val, const char* a_pathToVar) const = 0; // 32 + virtual bool SetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, const void* a_data, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 33 + virtual bool SetVariableArraySize(const char* a_pathToVar, std::uint32_t a_count, Movie::SetVarType a_setType = Movie::SetVarType::kSticky) = 0; // 35 + virtual std::uint32_t GetVariableArraySize(const char* a_pathToVar) = 0; // 34 + virtual bool GetVariableArray(Movie::SetArrayType a_type, const char* a_pathToVar, std::uint32_t a_index, void* a_data, std::uint32_t a_count) = 0; // 36 + virtual bool IsAvailable(const char* a_pathToVar) const = 0; // 37 + virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const Value* a_args, std::uint32_t a_numArgs) = 0; // 39 + virtual bool Invoke(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, ...) = 0; // 38 + virtual bool InvokeArgs(const char* a_pathToMethod, Value* a_result, const char* a_argFmt, std::va_list a_args) = 0; // 3A + virtual MemoryContext* GetMemoryContext() const = 0; // 3B + virtual ASStringManager* GetStringManager() const = 0; // 3C + virtual Render::Text::Allocator* GetTextAllocator() = 0; // 3D + virtual void BroadcastGeolocationStatusEvent(const EventId* a_id) = 0; // 3E + }; } diff --git a/CommonLibSF/include/RE/S/ScaleformGFxMovie.h b/CommonLibSF/include/RE/S/ScaleformGFxMovie.h index 9c39b506..6543f831 100644 --- a/CommonLibSF/include/RE/S/ScaleformGFxMovie.h +++ b/CommonLibSF/include/RE/S/ScaleformGFxMovie.h @@ -1,13 +1,13 @@ #pragma once -#include "RE/S/ScaleformPtr.h" #include "RE/S/ScaleformGFxStateBag.h" +#include "RE/S/ScaleformPtr.h" namespace RE::Scaleform::GFx { class ASMovieRootBase; - class Movie : + class Movie : public RefCountBase, // 00 public StateBag // 10 { diff --git a/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h b/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h index 011b0d42..d411f1a4 100644 --- a/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h +++ b/CommonLibSF/include/RE/S/ScaleformGFxStateBag.h @@ -18,9 +18,9 @@ namespace RE::Scaleform::GFx virtual ~StateBag() = default; // 01 // add - virtual void SetState(State::StateType a_stateType, State* a_state); // 02 - virtual State* GetStateAddRef(State::StateType a_stateType) const; // 03 - virtual void GetStatesAddRef(State** a_states, const State::StateType* a_stateTypes, std::uint32_t a_count) const; // 04 + virtual void SetState(State::StateType a_stateType, State* a_state); // 02 + virtual State* GetStateAddRef(State::StateType a_stateType) const; // 03 + virtual void GetStatesAddRef(State** a_states, const State::StateType* a_stateTypes, std::uint32_t a_count) const; // 04 }; //static_assert(sizeof(StateBag) == 0x8); } diff --git a/CommonLibSF/include/RE/S/ScaleformGFxValue.h b/CommonLibSF/include/RE/S/ScaleformGFxValue.h index 1a1a9656..fa1055bf 100644 --- a/CommonLibSF/include/RE/S/ScaleformGFxValue.h +++ b/CommonLibSF/include/RE/S/ScaleformGFxValue.h @@ -140,7 +140,6 @@ namespace RE::Scaleform::GFx }; static_assert(sizeof(ValueUnion) == 0x8); - class ObjectInterface { public: @@ -167,7 +166,6 @@ namespace RE::Scaleform::GFx virtual ~ObjectInterface() = default; // 00 - void ObjectAddRef(Value* a_val, void* a_obj) { using func_t = decltype(&ObjectInterface::ObjectRelease); diff --git a/CommonLibSF/include/RE/Starfield.h b/CommonLibSF/include/RE/Starfield.h index 501dd203..16b2acdb 100644 --- a/CommonLibSF/include/RE/Starfield.h +++ b/CommonLibSF/include/RE/Starfield.h @@ -50,6 +50,7 @@ #include "RE/E/ExtraDataTypes.h" #include "RE/F/FORM_ENUM_STRING.h" #include "RE/F/FormTypes.h" +#include "RE/G/GameMenuBase.h" #include "RE/I/IAnimationGraphManagerHolder.h" #include "RE/I/IFunction.h" #include "RE/I/IKeywordFormBase.h" @@ -77,6 +78,7 @@ #include "RE/P/PlayerCharacter.h" #include "RE/R/RegSettingCollection.h" #include "RE/RTTI.h" +#include "RE/S/SWFToCodeFunctionHandler.h" #include "RE/S/ScaleformGFxASMovieRootBase.h" #include "RE/S/ScaleformGFxFileTypeConstants.h" #include "RE/S/ScaleformGFxFunctionHandler.h" @@ -91,7 +93,6 @@ #include "RE/S/SettingCollectionList.h" #include "RE/S/SettingCollectionMap.h" #include "RE/S/Settings.h" -#include "RE/S/SWFToCodeFunctionHandler.h" #include "RE/T/TBO_InstanceData.h" #include "RE/T/TESAIForm.h" #include "RE/T/TESActorBase.h" diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index 2ebacc75..a501665f 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-09-30", + "version-date": "2023-10-01", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index e0622086..e90a757e 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-09-30&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-10-01&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies From e4d1fcbbc622b0bac856471f50b4bdd74041ef8b Mon Sep 17 00:00:00 2001 From: Qudix <17361645+Qudix@users.noreply.github.com> Date: Sun, 1 Oct 2023 12:07:03 -0500 Subject: [PATCH 19/21] feat!: make plugin version return Version instead (#129) - set default separator to `.` - simplify `SetOrClearBit` --- CommonLibSF/include/REL/Version.h | 19 +++++++++++++++++-- CommonLibSF/include/SFSE/Interfaces.h | 21 ++++++++++----------- CommonLibSF/src/REL/ID.cpp | 4 ++-- 3 files changed, 29 insertions(+), 15 deletions(-) diff --git a/CommonLibSF/include/REL/Version.h b/CommonLibSF/include/REL/Version.h index 7c945a7a..eedb2122 100644 --- a/CommonLibSF/include/REL/Version.h +++ b/CommonLibSF/include/REL/Version.h @@ -55,7 +55,7 @@ namespace REL [[nodiscard]] constexpr value_type patch() const noexcept { return _impl[2]; } [[nodiscard]] constexpr value_type build() const noexcept { return _impl[3]; } - [[nodiscard]] std::string string(std::string_view a_separator = "-"sv) const + [[nodiscard]] std::string string(std::string_view a_separator = "."sv) const { std::string result; for (auto&& ver : _impl) { @@ -66,7 +66,7 @@ namespace REL return result; } - [[nodiscard]] std::wstring wstring(std::wstring_view a_separator = L"-"sv) const + [[nodiscard]] std::wstring wstring(std::wstring_view a_separator = L"."sv) const { std::wstring result; for (auto&& ver : _impl) { @@ -147,3 +147,18 @@ namespace REL [[nodiscard]] std::optional get_file_version(stl::zwstring a_filename); } + +#ifdef __cpp_lib_format +namespace std +{ + template + struct formatter : formatter + { + template + auto format(const REL::Version a_version, FormatContext& a_ctx) const + { + return formatter::format(a_version.string(), a_ctx); + } + }; +} +#endif diff --git a/CommonLibSF/include/SFSE/Interfaces.h b/CommonLibSF/include/SFSE/Interfaces.h index d55bd9e6..14228b50 100644 --- a/CommonLibSF/include/SFSE/Interfaces.h +++ b/CommonLibSF/include/SFSE/Interfaces.h @@ -129,11 +129,9 @@ namespace SFSE kVersion = 1 }; - constexpr void PluginVersion(std::uint32_t a_version) noexcept { pluginVersion = a_version; } - constexpr void PluginVersion(REL::Version a_version) noexcept { pluginVersion = a_version.pack(); } - [[nodiscard]] constexpr std::uint32_t GetPluginVersion() const noexcept { return pluginVersion; } + [[nodiscard]] constexpr REL::Version GetPluginVersion() const noexcept { return REL::Version::unpack(pluginVersion); } constexpr void PluginName(std::string_view a_plugin) noexcept { SetCharBuffer(a_plugin, std::span{ pluginName }); } @@ -143,19 +141,22 @@ namespace SFSE [[nodiscard]] constexpr std::string_view GetAuthorName() const noexcept { return std::string_view{ author }; } - constexpr void UsesSigScanning(bool a_value) noexcept { addressIndependence = SetOrClearBit(addressIndependence, 1 << 0, a_value); } + constexpr void UsesSigScanning(bool a_value) noexcept { SetOrClearBit(addressIndependence, 1 << 0, a_value); } - constexpr void UsesAddressLibrary(bool a_value) noexcept { addressIndependence = SetOrClearBit(addressIndependence, 1 << 1, a_value); } + constexpr void UsesAddressLibrary(bool a_value) noexcept { SetOrClearBit(addressIndependence, 1 << 1, a_value); } - constexpr void HasNoStructUse(bool a_value) noexcept { structureCompatibility = SetOrClearBit(structureCompatibility, 1 << 0, a_value); } + constexpr void HasNoStructUse(bool a_value) noexcept { SetOrClearBit(structureCompatibility, 1 << 0, a_value); } - constexpr void IsLayoutDependent(bool a_value) noexcept { structureCompatibility = SetOrClearBit(structureCompatibility, 1 << 1, a_value); } + constexpr void IsLayoutDependent(bool a_value) noexcept { SetOrClearBit(structureCompatibility, 1 << 1, a_value); } constexpr void CompatibleVersions(std::initializer_list a_versions) noexcept { // must be zero-terminated assert(a_versions.size() < std::size(compatibleVersions) - 1); - std::ranges::transform(a_versions, std::begin(compatibleVersions), [](const REL::Version& a_version) noexcept { return a_version.pack(); }); + std::ranges::transform(a_versions, std::begin(compatibleVersions), [](const REL::Version& a_version) noexcept + { + return a_version.pack(); + }); } constexpr void MinimumRequiredXSEVersion(REL::Version a_version) noexcept { xseMinimum = a_version.pack(); } @@ -181,14 +182,12 @@ namespace SFSE std::ranges::copy(a_src, a_dst.begin()); } - [[nodiscard]] static constexpr std::uint32_t SetOrClearBit(std::uint32_t a_data, std::uint32_t a_bit, bool a_set) noexcept + static constexpr void SetOrClearBit(std::uint32_t& a_data, std::uint32_t a_bit, bool a_set) noexcept { if (a_set) a_data |= a_bit; else a_data &= ~a_bit; - - return a_data; } }; diff --git a/CommonLibSF/src/REL/ID.cpp b/CommonLibSF/src/REL/ID.cpp index 63cb7a8d..9dabf5e9 100644 --- a/CommonLibSF/src/REL/ID.cpp +++ b/CommonLibSF/src/REL/ID.cpp @@ -170,7 +170,7 @@ namespace REL // sfse only loads plugins from { runtimeDirectory + "Data\\SFSE\\Plugins" } auto file = std::filesystem::current_path(); - file /= std::format("{}\\versionlib-{}", database::LookUpDir, version.string()); + file /= std::format("{}\\versionlib-{}", database::LookUpDir, version.string("-")); _platform = Platform::kUnknown; for (auto& [vendor, registered] : database::VendorModule) { @@ -223,7 +223,7 @@ namespace REL // kDatabaseVersion, runtimeVersion, runtimePlatform "CommonLibSF-Offsets-v{}-{}-{}", std::to_underlying(database::kDatabaseVersion), - a_version.string(), + a_version.string("-"), std::to_underlying(_platform))); stl_assert(mapname.has_value(), From 1ff4ea28e1ff8ffab41e2a2d061d1286e7ba2d70 Mon Sep 17 00:00:00 2001 From: TommInfinite <81481291+TommInfinite@users.noreply.github.com> Date: Sun, 1 Oct 2023 20:07:12 +0300 Subject: [PATCH 20/21] feat: Add details to the error "Failed to find address library". (#128) So users can check where it's supposed to be located. Very useful for Gamepass users. --------- Co-authored-by: Qudix <17361645+Qudix@users.noreply.github.com> --- CommonLibSF/src/REL/ID.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CommonLibSF/src/REL/ID.cpp b/CommonLibSF/src/REL/ID.cpp index 9dabf5e9..db742cde 100644 --- a/CommonLibSF/src/REL/ID.cpp +++ b/CommonLibSF/src/REL/ID.cpp @@ -191,7 +191,7 @@ namespace REL file += ".bin"; stl_assert(std::filesystem::exists(file), - "Failed to find address library file in directory."); + "Failed to find address library file: \n{}", file.string()); return file.wstring(); } From e26887671a95ed26197095d1e5edbdf504b3af34 Mon Sep 17 00:00:00 2001 From: maintenance <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 1 Oct 2023 17:07:55 +0000 Subject: [PATCH 21/21] ci: maintenance `2023-10-01.1` --- CommonLibSF/include/REL/Version.h | 4 ++-- CommonLibSF/include/SFSE/Interfaces.h | 3 +-- CommonLibSF/src/REL/ID.cpp | 2 +- CommonLibSF/vcpkg.json | 2 +- README.md | 2 +- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/CommonLibSF/include/REL/Version.h b/CommonLibSF/include/REL/Version.h index eedb2122..9c4c0386 100644 --- a/CommonLibSF/include/REL/Version.h +++ b/CommonLibSF/include/REL/Version.h @@ -151,10 +151,10 @@ namespace REL #ifdef __cpp_lib_format namespace std { - template + template struct formatter : formatter { - template + template auto format(const REL::Version a_version, FormatContext& a_ctx) const { return formatter::format(a_version.string(), a_ctx); diff --git a/CommonLibSF/include/SFSE/Interfaces.h b/CommonLibSF/include/SFSE/Interfaces.h index 14228b50..2f2463bc 100644 --- a/CommonLibSF/include/SFSE/Interfaces.h +++ b/CommonLibSF/include/SFSE/Interfaces.h @@ -153,8 +153,7 @@ namespace SFSE { // must be zero-terminated assert(a_versions.size() < std::size(compatibleVersions) - 1); - std::ranges::transform(a_versions, std::begin(compatibleVersions), [](const REL::Version& a_version) noexcept - { + std::ranges::transform(a_versions, std::begin(compatibleVersions), [](const REL::Version& a_version) noexcept { return a_version.pack(); }); } diff --git a/CommonLibSF/src/REL/ID.cpp b/CommonLibSF/src/REL/ID.cpp index db742cde..37f11fb4 100644 --- a/CommonLibSF/src/REL/ID.cpp +++ b/CommonLibSF/src/REL/ID.cpp @@ -191,7 +191,7 @@ namespace REL file += ".bin"; stl_assert(std::filesystem::exists(file), - "Failed to find address library file: \n{}", file.string()); + "Failed to find address library file: \n{}", file.string()); return file.wstring(); } diff --git a/CommonLibSF/vcpkg.json b/CommonLibSF/vcpkg.json index a501665f..5f8e83a2 100644 --- a/CommonLibSF/vcpkg.json +++ b/CommonLibSF/vcpkg.json @@ -1,7 +1,7 @@ { "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json", "name": "commonlibsf", - "version-date": "2023-10-01", + "version-date": "2023-10-01.1", "port-version": 0, "description": "A collaborative reverse-engineered library for Starfield.", "homepage": "https://github.com/Starfield-Reverse-Engineering/CommonLibSF", diff --git a/README.md b/README.md index e90a757e..6ce6b735 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![C++23](https://img.shields.io/static/v1?label=standard&message=c%2B%2B23&color=blue&logo=c%2B%2B&&logoColor=red&style=flat)](https://en.cppreference.com/w/cpp/compiler_support) ![Platform](https://img.shields.io/static/v1?label=platform&message=windows&color=dimgray&style=flat&logo=windows) [![Game version](https://img.shields.io/badge/game%20version-1.7.29-orange)](#Developing-with-CommonLibSF) -[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-10-01&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) +[![VCPKG_VER](https://img.shields.io/static/v1?label=vcpkg%20registry&message=2023-10-01.1&color=green&style=flat)](https://github.com/Starfield-Reverse-Engineering/Starfield-RE-vcpkg) [![Main CI](https://img.shields.io/github/actions/workflow/status/Starfield-Reverse-Engineering/CommonLibSF/main_ci.yml)](https://github.com/Starfield-Reverse-Engineering/CommonLibSF/actions/workflows/main_ci.yml) ## Build Dependencies