10 constexpr
Offset() noexcept = default;
12 explicit constexpr
Offset(
std::
size_t a_offset) noexcept:
22 [[nodiscard]] std::uintptr_t
address()
const {
return base() +
offset(); }
24 [[nodiscard]] constexpr std::size_t
offset() const noexcept {
return _offset; }
27 [[nodiscard]]
static std::uintptr_t base() {
return Module::get().
base(); }
29 std::size_t _offset{0};
38 [[maybe_unused]]
std::
size_t a_seOffset,
39 [[maybe_unused]]
std::
size_t a_aeOffset,
40 [[maybe_unused]]
std::
size_t a_vrOffset) noexcept
42 #ifdef ENABLE_SKYRIM_SE
43 _seOffset = a_seOffset;
45 #ifdef ENABLE_SKYRIM_AE
46 _aeOffset = a_aeOffset;
48 #ifdef ENABLE_SKYRIM_VR
49 _vrOffset = a_vrOffset;
53 [[nodiscard]] std::uintptr_t
address()
const
55 auto thisOffset =
offset();
56 return thisOffset ? base() + thisOffset : 0;
62 #ifdef ENABLE_SKYRIM_AE
66 #ifdef ENABLE_SKYRIM_SE
70 #ifdef ENABLE_SKYRIM_VR
82 [[nodiscard]]
static std::uintptr_t base() {
return Module::get().
base(); }
84 #ifdef ENABLE_SKYRIM_SE
85 std::size_t _seOffset{0};
87 #ifdef ENABLE_SKYRIM_AE
88 std::size_t _aeOffset{0};
90 #ifdef ENABLE_SKYRIM_VR
91 std::size_t _vrOffset{0};
#define SKYRIM_REL
Definition: Common.h:38
static Module & get()
Definition: Module.h:82
std::uintptr_t base() const noexcept
Definition: Module.h:201
static SKYRIM_REL Runtime GetRuntime() noexcept
Definition: Module.h:222
constexpr Offset() noexcept=default
std::uintptr_t address() const
Definition: Offset.h:22
constexpr Offset & operator=(std::size_t a_offset) noexcept
Definition: Offset.h:16
constexpr std::size_t offset() const noexcept
Definition: Offset.h:24
std::uintptr_t address() const
Definition: Offset.h:53
SKYRIM_REL std::size_t offset() const noexcept
Definition: Offset.h:59
constexpr VariantOffset() noexcept=default
Definition: ActorValueList.h:28