CommonLibSSE (Parapets fork)
Loading...
Searching...
No Matches
BSSystemFileStorage.h
Go to the documentation of this file.
1#pragma once
2
3#include "RE/B/BSStorage.h"
4
5namespace RE
6{
8 {
9 public:
10 inline static constexpr auto RTTI = RTTI_BSSystemFileStorage;
11
13 {
14 public:
15 enum class Error
16 {
17 kNone = 0,
18 kFileNotFound = 2,
20 kPathNotFound = 4,
21 kWriteProtect = 5,
22 kOther = 6,
23
24 kErrorMask = 0x7FFFFFFF,
25
26 kUnkFlag = 1 << 31 // top bit isn't part of the error, mask 0x7FFFFFFF to get the error
27 };
28
29 // members
31 std::uint32_t pad24; // 04
32 void* handle; // 08
33 };
34 static_assert(sizeof(Attributes) == 0x10);
35
36 ~BSSystemFileStorage() override; // 00
37
38 // override (BSStorage)
39 std::size_t GetSize() const override; // 01
40 std::size_t GetPosition() const override; // 02
41 BSStorageDefs::ErrorCode Seek(std::size_t a_offset, BSStorageDefs::SeekMode a_seekMode) const override; // 03
42 BSStorageDefs::ErrorCode Read(std::size_t a_numBytes, std::byte* a_bytes) const override; // 04
43 BSStorageDefs::ErrorCode Write(std::size_t a_numBytes, const std::byte* a_bytes) override; // 05
44
45 bool IsGoodForRead() const;
46
47 // members
49 bool unk30; // 30
50 bool unk31; // 31
51 bool goodForRead; // 32
52 std::uint8_t pad33; // 33
53 std::uint32_t pad34; // 34
54 };
55 static_assert(sizeof(BSSystemFileStorage) == 0x38);
56}
Definition: BSStorage.h:14
Definition: BSSystemFileStorage.h:8
~BSSystemFileStorage() override
std::uint32_t pad34
Definition: BSSystemFileStorage.h:53
bool IsGoodForRead() const
Attributes attributes
Definition: BSSystemFileStorage.h:48
bool goodForRead
Definition: BSSystemFileStorage.h:51
std::uint8_t pad33
Definition: BSSystemFileStorage.h:52
std::size_t GetPosition() const override
bool unk31
Definition: BSSystemFileStorage.h:50
BSStorageDefs::ErrorCode Seek(std::size_t a_offset, BSStorageDefs::SeekMode a_seekMode) const override
BSStorageDefs::ErrorCode Write(std::size_t a_numBytes, const std::byte *a_bytes) override
bool unk30
Definition: BSSystemFileStorage.h:49
static constexpr auto RTTI
Definition: BSSystemFileStorage.h:10
std::size_t GetSize() const override
BSStorageDefs::ErrorCode Read(std::size_t a_numBytes, std::byte *a_bytes) const override
Definition: PCH.h:216
Definition: AbsorbEffect.h:6
constexpr REL::ID RTTI_BSSystemFileStorage
Definition: Offsets_RTTI.h:2604
Definition: BSSystemFileStorage.h:13
void * handle
Definition: BSSystemFileStorage.h:32
Error
Definition: BSSystemFileStorage.h:16
std::uint32_t pad24
Definition: BSSystemFileStorage.h:31
stl::enumeration< Error, std::uint32_t > lastError
Definition: BSSystemFileStorage.h:30