CommonLibSSE (powerof3)
TESObjectACTI.h
Go to the documentation of this file.
1 #pragma once
2 
4 #include "RE/B/BGSKeywordForm.h"
6 #include "RE/F/FormTypes.h"
8 #include "RE/T/TESFullName.h"
11 
12 namespace RE
13 {
14  class TESObjectACTI :
15  public TESBoundAnimObject, // 00
16  public TESFullName, // 30
17  public TESModelTextureSwap, // 40
18  public TESMagicTargetForm, // A8
19  public BGSDestructibleObjectForm, // 78
20  public BGSOpenCloseForm, // 88
21  public BGSKeywordForm // 90
22  {
23  public:
24  inline static constexpr auto RTTI = RTTI_TESObjectACTI;
25  inline static constexpr auto VTABLE = VTABLE_TESObjectACTI;
26  inline static constexpr auto FORMTYPE = FormType::Activator;
27 
28  enum class ActiFlags
29  {
30  kNone = 0,
31  kNoDisplacement = 1 << 0,
32  kIgnoredBySandbox = 1 << 1,
33  kIsProceduralWater = 1 << 2,
34  kIsLODWater = 1 << 3
35  };
36 
37  struct RecordFlags
38  {
39  enum RecordFlag : std::uint32_t
40  {
41  kDeleted = 1 << 5,
42  kHasTreeLOD = 1 << 6,
43  kMustUpdateAnims = 1 << 8,
45  kIgnored = 1 << 12,
46  kHasDistantLOD = 1 << 15,
47  kRandomAnimStart = 1 << 16,
48  kDangerous = 1 << 17,
50  kIsMarker = 1 << 23,
51  kObstacle = 1 << 25,
54  kChildCanUse = 1 << 29,
56  };
57  };
58 
59  ~TESObjectACTI() override; // 00
60 
61  // override (TESBoundAnimObject)
62  void InitializeData() override; // 04
63  void ClearData() override; // 05
64  bool Load(TESFile* a_mod) override; // 06
65  void SaveGame(BGSSaveFormBuffer* a_buf) override; // 0E
66  void LoadGame(BGSLoadFormBuffer* a_buf) override; // 0F
67  void InitItemImpl() override; // 13
68  bool GetIgnoredBySandbox() const override; // 22 - { return (flags >> 1) & 1; }
69  bool IsWater() const override; // 2A - { return waterType != 0; }
70  bool Activate(TESObjectREFR* a_targetRef, TESObjectREFR* a_activatorRef, std::uint8_t a_arg3, TESBoundObject* a_object, std::int32_t a_targetCount) override; // 37
71  TESWaterForm* GetWaterType() const override; // 3D - { return waterType; }
72  bool GetActivateText(TESObjectREFR* a_activator, BSString& a_dst) override; // 4C
73  bool CalculateDoFavor(Actor* a_activator, bool a_arg2, TESObjectREFR* a_toActivate, float a_arg3) override; // 4D
74 
75  // members
78  TESWaterForm* waterForm; // B8 - WNAM
80  std::uint16_t padC2; // C2
81  std::uint32_t padC4; // C4
82  };
83  static_assert(sizeof(TESObjectACTI) == 0xC8);
84 }
Definition: Actor.h:133
Definition: BGSDestructibleObjectForm.h:61
Definition: BGSKeywordForm.h:12
Definition: BGSLoadFormBuffer.h:11
Definition: BGSOpenCloseForm.h:9
Definition: BGSSaveFormBuffer.h:8
Definition: BGSSoundDescriptorForm.h:14
Definition: TESBoundAnimObject.h:8
Definition: TESBoundObject.h:24
Definition: TESFile.h:17
Definition: TESFullName.h:9
Definition: TESMagicTargetForm.h:6
Definition: TESModelTextureSwap.h:10
Definition: TESObjectACTI.h:22
bool GetActivateText(TESObjectREFR *a_activator, BSString &a_dst) override
bool Activate(TESObjectREFR *a_targetRef, TESObjectREFR *a_activatorRef, std::uint8_t a_arg3, TESBoundObject *a_object, std::int32_t a_targetCount) override
BGSSoundDescriptorForm * soundActivate
Definition: TESObjectACTI.h:77
~TESObjectACTI() override
TESWaterForm * waterForm
Definition: TESObjectACTI.h:78
REX::EnumSet< ActiFlags, std::uint16_t > flags
Definition: TESObjectACTI.h:79
static constexpr auto VTABLE
Definition: TESObjectACTI.h:25
ActiFlags
Definition: TESObjectACTI.h:29
BGSSoundDescriptorForm * soundLoop
Definition: TESObjectACTI.h:76
bool GetIgnoredBySandbox() const override
void InitializeData() override
void SaveGame(BGSSaveFormBuffer *a_buf) override
bool IsWater() const override
TESWaterForm * GetWaterType() const override
std::uint16_t padC2
Definition: TESObjectACTI.h:80
static constexpr auto RTTI
Definition: TESObjectACTI.h:24
void LoadGame(BGSLoadFormBuffer *a_buf) override
std::uint32_t padC4
Definition: TESObjectACTI.h:81
void InitItemImpl() override
bool CalculateDoFavor(Actor *a_activator, bool a_arg2, TESObjectREFR *a_toActivate, float a_arg3) override
static constexpr auto FORMTYPE
Definition: TESObjectACTI.h:26
bool Load(TESFile *a_mod) override
void ClearData() override
Definition: TESObjectREFR.h:114
Definition: TESWaterForm.h:83
Definition: AbsorbEffect.h:6
constexpr std::array< REL::ID, 6 > VTABLE_TESObjectACTI
Definition: Offsets_VTABLE.h:12856
constexpr REL::ID RTTI_TESObjectACTI(static_cast< std::uint64_t >(513918))
Definition: TESObjectACTI.h:38
RecordFlag
Definition: TESObjectACTI.h:40
@ kNavMeshGeneration_Filter
Definition: TESObjectACTI.h:52
@ kObstacle
Definition: TESObjectACTI.h:51
@ kNavMeshGeneration_Ground
Definition: TESObjectACTI.h:55
@ kChildCanUse
Definition: TESObjectACTI.h:54
@ kHasTreeLOD
Definition: TESObjectACTI.h:42
@ kDeleted
Definition: TESObjectACTI.h:41
@ kDangerous
Definition: TESObjectACTI.h:48
@ kRandomAnimStart
Definition: TESObjectACTI.h:47
@ kHiddenFromLocalMap
Definition: TESObjectACTI.h:44
@ kIgnoresObjectInteraction
Definition: TESObjectACTI.h:49
@ kIsMarker
Definition: TESObjectACTI.h:50
@ kNavMeshGeneration_BoundingBox
Definition: TESObjectACTI.h:53
@ kHasDistantLOD
Definition: TESObjectACTI.h:46
@ kIgnored
Definition: TESObjectACTI.h:45
@ kMustUpdateAnims
Definition: TESObjectACTI.h:43