CommonLibSSE NG
BGSSaveGameBuffer.h
Go to the documentation of this file.
1 #pragma once
2 
3 namespace RE
4 {
5  class Actor;
6  class TESForm;
7  class TESObjectREFR;
8 
10  {
11  public:
12  inline static constexpr auto RTTI = RTTI_BGSSaveGameBuffer;
13  inline static constexpr auto VTABLE = VTABLE_BGSSaveGameBuffer;
14 
15  virtual ~BGSSaveGameBuffer();
16 
17  // add
18  virtual TESForm* GetForm(); // 01 - { return nullptr; }
19  virtual TESObjectREFR* GetReference(); // 02 - { return nullptr; }
20  virtual Actor* GetActor(); // 03 - { return nullptr; }
21 
22  void SaveDataEndian(const void* a_data, std::uint32_t a_size)
23  {
24  using func_t = decltype(&BGSSaveGameBuffer::SaveDataEndian);
25  REL::Relocation<func_t> func{ RELOCATION_ID(35163, 36053) };
26  return func(this, a_data, a_size);
27  }
28 
29  // members
30  void* buffer; // 08
31  std::uint32_t size; // 10
32  std::uint32_t bufferPosition; // 14
33  };
34  static_assert(sizeof(BGSSaveGameBuffer) == 0x18);
35 }
#define RELOCATION_ID(a_se, a_ae)
Definition: PCH.h:724
Definition: Relocation.h:204
Definition: Actor.h:135
Definition: BGSSaveGameBuffer.h:10
void * buffer
Definition: BGSSaveGameBuffer.h:30
static constexpr auto VTABLE
Definition: BGSSaveGameBuffer.h:13
static constexpr auto RTTI
Definition: BGSSaveGameBuffer.h:12
virtual TESForm * GetForm()
virtual TESObjectREFR * GetReference()
virtual ~BGSSaveGameBuffer()
virtual Actor * GetActor()
void SaveDataEndian(const void *a_data, std::uint32_t a_size)
Definition: BGSSaveGameBuffer.h:22
std::uint32_t bufferPosition
Definition: BGSSaveGameBuffer.h:32
std::uint32_t size
Definition: BGSSaveGameBuffer.h:31
Definition: TESForm.h:36
Definition: TESObjectREFR.h:113
Definition: AbsorbEffect.h:6
constexpr REL::VariantID RTTI_BGSSaveGameBuffer(686619, 394462, 0x1f025f8)
constexpr std::array< REL::VariantID, 1 > VTABLE_BGSSaveGameBuffer
Definition: Offsets_VTABLE.h:1992