CommonLibSSE (Parapets fork)
Script.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "RE/B/BSSimpleList.h"
4 #include "RE/C/CommandTable.h"
5 #include "RE/F/FormTypes.h"
6 #include "RE/T/TESForm.h"
7 
8 namespace RE
9 {
10  enum class COMPILER_NAME
11  {
15  };
16 
18  {
19  public:
20  };
21  static_assert(sizeof(ScriptCompiler) == 0x1);
22 
23  class Script : public TESForm
24  {
25  public:
26  inline static constexpr auto RTTI = RTTI_Script;
27  inline static constexpr auto FORMTYPE = FormType::Script;
28 
29  struct RecordFlags
30  {
31  enum RecordFlag : std::uint32_t
32  {
33  };
34  };
35 
36  ~Script() override; // 00
37 
38  // override (TESForm)
39  void InitializeData() override; // 04
40  void ClearData() override; // 05
41  bool Load(TESFile* a_mod) override; // 06
42  void InitItemImpl() override; // 13
43 
44  void ClearCommand();
47  [[nodiscard]] std::string GetCommand() const;
48  void SetCommand(std::string_view a_command);
49 
50  // members
52  std::uint32_t pad34; // 34
53  char* text; // 38
55  float profilerTimer; // 48
56  float questScriptDelay; // 4C
58  std::uint32_t pad54; // 54
62 
63  private:
64  void CompileAndRun_Impl(ScriptCompiler* a_compiler, COMPILER_NAME a_type, TESObjectREFR* a_targetRef);
65  };
66  static_assert(sizeof(Script) == 0x80);
67 }
Definition: BSSimpleList.h:10
Definition: Script.h:18
Definition: Script.h:24
~Script() override
std::string GetCommand() const
float questScriptDelay
Definition: Script.h:56
void CompileAndRun(ScriptCompiler *a_compiler, TESObjectREFR *a_targetRef, COMPILER_NAME a_name=COMPILER_NAME::kSystemWindowCompiler)
SCRIPT_FUNCTION::ScriptData * data
Definition: Script.h:54
void CompileAndRun(TESObjectREFR *a_targetRef, COMPILER_NAME a_name=COMPILER_NAME::kSystemWindowCompiler)
static constexpr auto RTTI
Definition: Script.h:26
static constexpr auto FORMTYPE
Definition: Script.h:27
void InitItemImpl() override
void SetCommand(std::string_view a_command)
char * text
Definition: Script.h:53
float questScriptGetSecondsBuffer
Definition: Script.h:57
void ClearCommand()
void ClearData() override
bool Load(TESFile *a_mod) override
SCRIPT_HEADER header
Definition: Script.h:51
BSSimpleList< ScriptVariable * > variables
Definition: Script.h:61
TESQuest * parentQuest
Definition: Script.h:59
std::uint32_t pad54
Definition: Script.h:58
std::uint32_t pad34
Definition: Script.h:52
BSSimpleList< SCRIPT_REFERENCED_OBJECT * > refObjects
Definition: Script.h:60
void InitializeData() override
float profilerTimer
Definition: Script.h:55
Definition: TESFile.h:14
Definition: TESForm.h:34
Definition: TESObjectREFR.h:105
Definition: TESQuest.h:189
Definition: AbsorbEffect.h:6
COMPILER_NAME
Definition: Script.h:11
constexpr REL::ID RTTI_Script
Definition: Offsets_RTTI.h:5796
string(const CharT(&)[N]) -> string< CharT, N - 1 >
Definition: CommandTable.h:280
Definition: CommandTable.h:117
Definition: Script.h:30
RecordFlag
Definition: Script.h:32