CommonLibVR
PackageLocation.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "RE/B/BSPointerHandle.h"
5 
6 namespace RE
7 {
8  class TESForm;
9 
11  {
12  public:
13  inline static constexpr auto RTTI = RTTI_PackageLocation;
14  inline static constexpr auto VTABLE = VTABLE_PackageLocation;
15 
16  enum class Type
17  {
18  kNone = static_cast<std::underlying_type_t<Type>>(-1),
19  kNearReference = 0,
20  kInCell = 1,
21  kNearPackageStartLocation = 2,
22  kNearEditorLocation = 3,
23  kObjectID = 4,
24  kObjectType = 5,
25  kNearLinkedReference = 6,
26  kAtPackagelocation = 7,
27  kAlias_Reference = 8,
28  kAlias_Location = 9,
29  kNearSelf = 12,
30  };
31 
32  union Data
33  {
34  ~Data() {}
35 
38  };
39  static_assert(sizeof(Data) == 0x8);
40 
41  ~PackageLocation() override; // 00
42 
43  // override (IAIWorldLocationHandle)
44  const IAIWorldLocation* AllocateLocation(AIWorldLocationContext* a_context) override; // 01
45  PackageLocation* GetAsPackageLocation() override; // 02 - { return this; }
46  bool IsRefAtLocation(AIWorldLocationContext* a_context, TESObjectREFR* a_ref) override; // 03
47 
48  // members
50  std::uint8_t pad09; // 09
51  std::uint16_t pad0A; // 0A
52  std::uint32_t rad; // 0C
53  Data data; // 10
54  private:
55  KEEP_FOR_RE()
56  };
57  static_assert(sizeof(PackageLocation) == 0x18);
58 }
#define KEEP_FOR_RE()
Definition: PCH.h:713
Definition: IAIWorldLocationHandle.h:11
Definition: PackageLocation.h:11
static constexpr auto RTTI
Definition: PackageLocation.h:13
Type
Definition: PackageLocation.h:17
const IAIWorldLocation * AllocateLocation(AIWorldLocationContext *a_context) override
std::uint32_t rad
Definition: PackageLocation.h:52
PackageLocation * GetAsPackageLocation() override
Data data
Definition: PackageLocation.h:53
std::uint8_t pad09
Definition: PackageLocation.h:50
static constexpr auto VTABLE
Definition: PackageLocation.h:14
~PackageLocation() override
stl::enumeration< Type, std::uint8_t > locType
Definition: PackageLocation.h:49
std::uint16_t pad0A
Definition: PackageLocation.h:51
bool IsRefAtLocation(AIWorldLocationContext *a_context, TESObjectREFR *a_ref) override
Definition: TESForm.h:40
Definition: TESObjectREFR.h:113
Definition: AbsorbEffect.h:6
constexpr std::array< REL::ID, 1 > VTABLE_PackageLocation
Definition: Offsets_VTABLE.h:12503
@ kNone
Definition: PlayerCharacter.h:85
constexpr REL::ID RTTI_PackageLocation(static_cast< std::uint64_t >(686035))
Definition: PackageLocation.h:33
TESForm * object
Definition: PackageLocation.h:36
~Data()
Definition: PackageLocation.h:34
ObjectRefHandle refHandle
Definition: PackageLocation.h:37