CommonLibSSE (Parapets fork)
BGSSaveLoadManager.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "RE/B/BSAtomic.h"
4 #include "RE/B/BSFixedString.h"
5 #include "RE/B/BSTArray.h"
6 #include "RE/B/BSTEvent.h"
7 #include "RE/B/BSTMessageQueue.h"
8 #include "RE/B/BSTSmartPointer.h"
9 #include "RE/B/BSThread.h"
10 #include "RE/R/RaceSexMenuEvent.h"
11 #include "RE/R/Request.h"
12 
13 namespace RE
14 {
15  class BSSaveDataEvent;
16  class BSSystemEvent;
17  struct BGSSaveLoadManagerEvent;
18 
20  {
21  public:
22  // members
29  std::uint32_t unk30; // 30
30  std::uint32_t unk34; // 34
31  std::uint32_t unk38; // 38
32  std::uint32_t unk3C; // 3C
33  std::uint32_t unk40; // 40
34  std::uint32_t unk44; // 44
35  std::uint64_t unk48; // 48
36  std::uint64_t unk50; // 50
37  std::uint64_t unk58; // 58
38  std::uint64_t unk60; // 60
39  std::uint64_t unk68; // 68
40  std::uint64_t unk70; // 70
41  };
42  static_assert(sizeof(BGSSaveLoadFileEntry) == 0x78);
43 
45  public BSTEventSink<BSSaveDataEvent>, // 000
46  public BSTEventSink<RaceSexMenuEvent::NameChangedEvent>, // 008
47  public BSTEventSource<BGSSaveLoadManagerEvent>, // 018
48  public BSTEventSink<BSSystemEvent> // 010
49  {
50  public:
51  inline static constexpr auto RTTI = RTTI_BGSSaveLoadManager;
52 
53  class Thread : public BSThread
54  {
55  public:
56  inline static constexpr auto RTTI = RTTI_BGSSaveLoadManager__Thread;
57 
58  ~Thread() override; // 00
59 
60  std::uint32_t ThreadProc() override; // 01
61  void Unk_02(void) override; // 02
62 
63  // members
64  bool isRunnning; // 50
65  bool isBusy; // 51
66  std::uint16_t pad52; // 52
67  std::uint32_t pad54; // 54
70  };
71  static_assert(sizeof(Thread) == 0xC0);
72 
73  ~BGSSaveLoadManager() override; // 00
74 
75  // override (BSTEventSink<BSSaveDataEvent>)
76  BSEventNotifyControl ProcessEvent(const BSSaveDataEvent* a_event, BSTEventSource<BSSaveDataEvent>* a_eventSource) override; // 01
77 
78  // override (BSTEventSink<RaceSexMenuEvent::NameChangedEvent>)
80 
81  // override (BSTEventSink<BSSystemEvent>)
82  BSEventNotifyControl ProcessEvent(const BSSystemEvent* a_event, BSTEventSource<BSSystemEvent>* a_eventSource) override; // 01
83 
85 
86  void Save(const char* a_fileName);
87  void Load(const char* a_fileName);
88 
89  // members
90  std::uint64_t unk070; // 070
91  std::uint32_t unk078; // 078
92  std::uint32_t unk07C; // 07C
93  std::uint32_t unk080; // 080
94  std::uint32_t unk084; // 084
95  std::uint64_t unk088; // 088
96  std::uint64_t unk090; // 090
97  std::uint64_t unk098; // 098
98  std::uint64_t unk0A0; // 0A0
99  std::uint32_t unk0A8; // 0A8
100  std::uint32_t unk0AC; // 0AC
101  std::uint32_t unk0B0; // 0B0
102  std::uint32_t unk0B4; // 0B4
103  std::uint64_t unk0B8; // 0B8
104  std::uint64_t unk0C0; // 0C0
105  std::uint64_t unk0C8; // 0C8
106  std::uint64_t unk0D0; // 0D0
107  std::uint32_t unk0D8; // 0D8
108  std::uint32_t unk0DC; // 0DC
109  std::uint32_t unk0E0; // 0E0
110  std::uint32_t unk0E4; // 0E4
112 
114  std::uint8_t unk118; // 118
115  std::uint8_t unk119; // 119
116  std::uint16_t unk11A; // 11A
117  std::uint32_t unk11C; // 11C
118  std::uint16_t unk120; // 120
119  std::uint16_t unk122; // 122
120  std::uint32_t unk124; // 124
121  std::uint32_t tickCount; // 128
122  std::uint32_t unk12C; // 12C
123  std::uint8_t unk130; // 130
124  std::uint8_t unk131; // 131
125  std::uint16_t unk132; // 132
126  std::uint32_t unk134; // 134
127  std::uint64_t unk138; // 138
128  std::uint64_t unk140; // 140
129  std::uint64_t unk148; // 148
130  std::uint64_t unk150; // 150
131  std::uint64_t unk158; // 158
132  std::uint64_t unk160; // 160
133  std::uint64_t unk168; // 168
134  std::uint64_t unk170; // 170
135  std::uint64_t unk178; // 178
136  std::uint64_t unk180; // 180
137  std::uint64_t unk188; // 188
138  std::uint64_t unk190; // 190
139  std::uint64_t unk198; // 198
140  std::uint64_t unk1A0; // 1A0
141  std::uint64_t unk1A8; // 1A8
142  std::uint64_t unk1B0; // 1B0
143  std::uint64_t unk1B8; // 1B8
144  std::uint64_t unk1C0; // 1C0
145  std::uint64_t unk1C8; // 1C8
146  std::uint64_t unk1D0; // 1D0
147  std::uint64_t unk1D8; // 1D8
148  std::uint64_t unk1E0; // 1E0
149  std::uint64_t unk1E8; // 1E8
150  std::uint64_t unk1F0; // 1F0
151  std::uint64_t unk1F8; // 1F8
152 
153  std::uint64_t unk200; // 200
154  std::uint64_t unk208; // 208
155  std::uint64_t unk210; // 210
156  std::uint64_t unk218; // 218
157  std::uint64_t unk220; // 220
158  std::uint64_t unk228; // 228
159  std::uint64_t unk230; // 230
160  std::uint64_t unk238; // 238
161  std::uint64_t unk240; // 240
162  std::uint64_t unk248; // 248
163  std::uint32_t unk250; // 250
164  std::uint32_t unk254; // 254
165  std::uint64_t unk258; // 258
166  std::uint16_t unk260; // 260
167  std::uint16_t unk262; // 262
168  std::uint32_t unk264; // 264
169  std::uint64_t unk268; // 268
170  std::uint32_t unk270; // 270
171  std::uint32_t unk274; // 274
172  std::uint64_t unk278; // 278
173  std::uint64_t unk280; // 280
174  std::uint32_t unk288; // 288
175  std::uint32_t unk28C; // 28C
176  std::uint64_t unk290; // 290
177  std::uint64_t unk298; // 298
178  std::uint32_t unk2A0; // 2A0
179  std::uint32_t unk2A4; // 2A4
180  std::uint64_t unk2A8; // 2A8
181  Thread unk2B0; // 2B0
182 
184 
185  protected:
186  bool Save_Impl(std::int32_t a_deviceID, std::uint32_t a_outputStats, const char* a_fileName);
187  bool Load_Impl(const char* a_fileName, std::int32_t a_deviceID, std::uint32_t a_outputStats, bool a_checkForMods);
188  };
189  static_assert(sizeof(BGSSaveLoadManager) == 0x3D0);
190 }
Definition: BGSSaveLoadManager.h:20
BSFixedString playTime
Definition: BGSSaveLoadManager.h:27
std::uint32_t unk34
Definition: BGSSaveLoadManager.h:30
std::uint32_t unk3C
Definition: BGSSaveLoadManager.h:32
std::uint64_t unk60
Definition: BGSSaveLoadManager.h:38
BSFixedString fileName
Definition: BGSSaveLoadManager.h:23
BSFixedString raceName
Definition: BGSSaveLoadManager.h:28
BSFixedString location
Definition: BGSSaveLoadManager.h:26
std::uint32_t unk40
Definition: BGSSaveLoadManager.h:33
std::uint64_t unk58
Definition: BGSSaveLoadManager.h:37
BSFixedString playerName
Definition: BGSSaveLoadManager.h:24
std::uint32_t unk30
Definition: BGSSaveLoadManager.h:29
std::uint32_t unk38
Definition: BGSSaveLoadManager.h:31
std::uint32_t unk44
Definition: BGSSaveLoadManager.h:34
BSFixedString playerTitle
Definition: BGSSaveLoadManager.h:25
std::uint64_t unk48
Definition: BGSSaveLoadManager.h:35
std::uint64_t unk70
Definition: BGSSaveLoadManager.h:40
std::uint64_t unk50
Definition: BGSSaveLoadManager.h:36
std::uint64_t unk68
Definition: BGSSaveLoadManager.h:39
Definition: BGSSaveLoadManager.h:54
void Unk_02(void) override
bool isBusy
Definition: BGSSaveLoadManager.h:65
std::uint32_t pad54
Definition: BGSSaveLoadManager.h:67
std::uint32_t ThreadProc() override
static constexpr auto RTTI
Definition: BGSSaveLoadManager.h:56
BSTCommonStaticMessageQueue< BSTSmartPointer< bgs::saveload::Request >, 8 > asyncSaveLoadOperationQueue
Definition: BGSSaveLoadManager.h:69
std::uint16_t pad52
Definition: BGSSaveLoadManager.h:66
BSEventFlag haveTask
Definition: BGSSaveLoadManager.h:68
bool isRunnning
Definition: BGSSaveLoadManager.h:64
Definition: BGSSaveLoadManager.h:49
std::uint64_t unk220
Definition: BGSSaveLoadManager.h:157
BSTCommonStaticMessageQueue< BSTSmartPointer< bgs::saveload::Request >, 8 > unk370
Definition: BGSSaveLoadManager.h:183
static BGSSaveLoadManager * GetSingleton()
std::uint64_t unk140
Definition: BGSSaveLoadManager.h:128
std::uint32_t unk2A4
Definition: BGSSaveLoadManager.h:179
std::uint64_t unk1F0
Definition: BGSSaveLoadManager.h:150
std::uint64_t unk088
Definition: BGSSaveLoadManager.h:95
static constexpr auto RTTI
Definition: BGSSaveLoadManager.h:51
std::uint32_t unk078
Definition: BGSSaveLoadManager.h:91
std::uint64_t unk148
Definition: BGSSaveLoadManager.h:129
std::uint64_t unk278
Definition: BGSSaveLoadManager.h:172
std::uint64_t unk170
Definition: BGSSaveLoadManager.h:134
std::uint64_t unk248
Definition: BGSSaveLoadManager.h:162
std::uint64_t unk1A8
Definition: BGSSaveLoadManager.h:141
std::uint8_t unk118
Definition: BGSSaveLoadManager.h:114
std::uint32_t unk2A0
Definition: BGSSaveLoadManager.h:178
std::uint64_t unk190
Definition: BGSSaveLoadManager.h:138
std::uint32_t unk0B0
Definition: BGSSaveLoadManager.h:101
std::uint32_t unk0E4
Definition: BGSSaveLoadManager.h:110
std::uint64_t unk230
Definition: BGSSaveLoadManager.h:159
BSEventNotifyControl ProcessEvent(const BSSaveDataEvent *a_event, BSTEventSource< BSSaveDataEvent > *a_eventSource) override
std::uint64_t unk1B0
Definition: BGSSaveLoadManager.h:142
std::uint32_t unk250
Definition: BGSSaveLoadManager.h:163
std::uint64_t unk240
Definition: BGSSaveLoadManager.h:161
std::uint32_t unk07C
Definition: BGSSaveLoadManager.h:92
std::uint64_t unk1C8
Definition: BGSSaveLoadManager.h:145
void Save(const char *a_fileName)
std::uint64_t unk1C0
Definition: BGSSaveLoadManager.h:144
BSEventNotifyControl ProcessEvent(const RaceSexMenuEvent::NameChangedEvent *a_event, BSTEventSource< RaceSexMenuEvent::NameChangedEvent > *a_eventSource) override
std::uint16_t unk11A
Definition: BGSSaveLoadManager.h:116
std::uint8_t unk131
Definition: BGSSaveLoadManager.h:124
std::uint32_t unk0DC
Definition: BGSSaveLoadManager.h:108
std::uint64_t unk228
Definition: BGSSaveLoadManager.h:158
std::uint32_t unk270
Definition: BGSSaveLoadManager.h:170
std::uint64_t unk258
Definition: BGSSaveLoadManager.h:165
std::uint64_t unk198
Definition: BGSSaveLoadManager.h:139
std::uint64_t unk1E0
Definition: BGSSaveLoadManager.h:148
std::uint32_t unk12C
Definition: BGSSaveLoadManager.h:122
std::uint16_t unk262
Definition: BGSSaveLoadManager.h:167
std::uint32_t unk0B4
Definition: BGSSaveLoadManager.h:102
std::uint32_t unk254
Definition: BGSSaveLoadManager.h:164
BSEventNotifyControl ProcessEvent(const BSSystemEvent *a_event, BSTEventSource< BSSystemEvent > *a_eventSource) override
bool Load_Impl(const char *a_fileName, std::int32_t a_deviceID, std::uint32_t a_outputStats, bool a_checkForMods)
std::uint32_t unk134
Definition: BGSSaveLoadManager.h:126
std::uint64_t unk0A0
Definition: BGSSaveLoadManager.h:98
std::uint64_t unk2A8
Definition: BGSSaveLoadManager.h:180
std::uint64_t unk280
Definition: BGSSaveLoadManager.h:173
std::uint64_t unk188
Definition: BGSSaveLoadManager.h:137
std::uint16_t unk122
Definition: BGSSaveLoadManager.h:119
std::uint64_t unk290
Definition: BGSSaveLoadManager.h:176
std::uint32_t unk274
Definition: BGSSaveLoadManager.h:171
std::uint64_t unk200
Definition: BGSSaveLoadManager.h:153
BSTArray< void * > unk0E8
Definition: BGSSaveLoadManager.h:111
std::uint64_t unk098
Definition: BGSSaveLoadManager.h:97
std::uint16_t unk132
Definition: BGSSaveLoadManager.h:125
std::uint32_t unk288
Definition: BGSSaveLoadManager.h:174
std::uint32_t unk11C
Definition: BGSSaveLoadManager.h:117
std::uint64_t unk168
Definition: BGSSaveLoadManager.h:133
std::uint8_t unk130
Definition: BGSSaveLoadManager.h:123
std::uint32_t unk0D8
Definition: BGSSaveLoadManager.h:107
std::uint64_t unk0C8
Definition: BGSSaveLoadManager.h:105
std::uint32_t unk0AC
Definition: BGSSaveLoadManager.h:100
std::uint16_t unk260
Definition: BGSSaveLoadManager.h:166
std::uint64_t unk238
Definition: BGSSaveLoadManager.h:160
std::uint32_t unk0E0
Definition: BGSSaveLoadManager.h:109
std::uint32_t unk080
Definition: BGSSaveLoadManager.h:93
std::uint64_t unk1E8
Definition: BGSSaveLoadManager.h:149
std::uint32_t unk084
Definition: BGSSaveLoadManager.h:94
std::uint64_t unk0B8
Definition: BGSSaveLoadManager.h:103
std::uint64_t unk1D8
Definition: BGSSaveLoadManager.h:147
std::uint64_t unk1A0
Definition: BGSSaveLoadManager.h:140
std::uint64_t unk1F8
Definition: BGSSaveLoadManager.h:151
std::uint64_t unk180
Definition: BGSSaveLoadManager.h:136
std::uint64_t unk1D0
Definition: BGSSaveLoadManager.h:146
std::uint64_t unk138
Definition: BGSSaveLoadManager.h:127
void Load(const char *a_fileName)
std::uint64_t unk150
Definition: BGSSaveLoadManager.h:130
std::uint8_t unk119
Definition: BGSSaveLoadManager.h:115
std::uint64_t unk178
Definition: BGSSaveLoadManager.h:135
Thread unk2B0
Definition: BGSSaveLoadManager.h:181
std::uint64_t unk070
Definition: BGSSaveLoadManager.h:90
std::uint64_t unk268
Definition: BGSSaveLoadManager.h:169
~BGSSaveLoadManager() override
std::uint64_t unk160
Definition: BGSSaveLoadManager.h:132
std::uint32_t tickCount
Definition: BGSSaveLoadManager.h:121
std::uint32_t unk124
Definition: BGSSaveLoadManager.h:120
std::uint64_t unk298
Definition: BGSSaveLoadManager.h:177
std::uint32_t unk0A8
Definition: BGSSaveLoadManager.h:99
std::uint32_t unk28C
Definition: BGSSaveLoadManager.h:175
std::uint16_t unk120
Definition: BGSSaveLoadManager.h:118
std::uint64_t unk1B8
Definition: BGSSaveLoadManager.h:143
std::uint64_t unk208
Definition: BGSSaveLoadManager.h:154
BSTArray< BGSSaveLoadFileEntry * > saveGameList
Definition: BGSSaveLoadManager.h:113
std::uint64_t unk218
Definition: BGSSaveLoadManager.h:156
std::uint64_t unk090
Definition: BGSSaveLoadManager.h:96
std::uint32_t unk264
Definition: BGSSaveLoadManager.h:168
std::uint64_t unk210
Definition: BGSSaveLoadManager.h:155
std::uint64_t unk0D0
Definition: BGSSaveLoadManager.h:106
std::uint64_t unk158
Definition: BGSSaveLoadManager.h:131
std::uint64_t unk0C0
Definition: BGSSaveLoadManager.h:104
bool Save_Impl(std::int32_t a_deviceID, std::uint32_t a_outputStats, const char *a_fileName)
Definition: BSAtomic.h:14
Definition: BSTMessageQueue.h:81
Definition: BSTEvent.h:146
Definition: BSTEvent.h:28
Definition: BSThread.h:6
Definition: AbsorbEffect.h:6
constexpr REL::ID RTTI_BGSSaveLoadManager__Thread
Definition: Offsets_RTTI.h:1528
constexpr REL::ID RTTI_BGSSaveLoadManager
Definition: Offsets_RTTI.h:1527
BSEventNotifyControl
Definition: BSTEvent.h:12
Definition: RaceSexMenuEvent.h:9