LeviLamina
Loading...
Searching...
No Matches
PackInstance.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/resources/PackReport.h"
7#include "mc/resources/PackStats.h"
8
9// auto generated forward declare list
10// clang-format off
11class PackSettings;
12class ResourcePack;
13namespace Bedrock::Resources { class PreloadedPathHandle; }
14namespace Core { class Path; }
15// clang-format on
16
17class PackInstance {
18public:
19 // PackInstance inner types define
20 using Callback = ::std::function<void(::Core::Path const&)>;
21
22public:
23 // member variables
24 // NOLINTBEGIN
25 ::ll::TypedStorage<8, 248, ::PackReport> mPackReport;
26 ::ll::TypedStorage<8, 8, ::PackSettings*> mPackSettings;
27 ::ll::TypedStorage<8, 16, ::gsl::not_null<::std::shared_ptr<::ResourcePack>>> mPack;
28 ::ll::TypedStorage<4, 16, ::PackStats> mStats;
29 ::ll::TypedStorage<4, 4, int> mSubpackIndex;
30 ::ll::TypedStorage<1, 1, uchar> mRevision;
31 // NOLINTEND
32
33public:
34 // prevent constructor by default
35 PackInstance(PackInstance const&);
36 PackInstance();
37
38public:
39 // member functions
40 // NOLINTBEGIN
41 MCAPI PackInstance(
42 ::gsl::not_null<::std::shared_ptr<::ResourcePack>> pack,
43 int subpackIndex,
44 bool isDependent,
45 ::PackSettings* packSettings
46 );
47
48 MCAPI PackInstance(
49 ::gsl::not_null<::std::shared_ptr<::ResourcePack>> pack,
50 ::std::string const& subpackName,
51 bool isDependent,
52 ::PackSettings* packSettings
53 );
54
55 MCAPI void
56 forEachIn(::Core::Path const& path, ::std::function<void(::Core::Path const&)> callback, bool recurseAnyways) const;
57
58#ifdef LL_PLAT_C
59 MCAPI bool hasResource(::Core::Path const& resourceName) const;
60#endif
61
62 MCAPI ::PackInstance& operator=(::PackInstance const&);
63
64#ifdef LL_PLAT_C
65 MCAPI ::Bedrock::Resources::PreloadedPathHandle preloadArchive(::Core::Path const& packRelativePath) const;
66#endif
67
68 MCAPI ~PackInstance();
69 // NOLINTEND
70
71public:
72 // constructor thunks
73 // NOLINTBEGIN
74 MCAPI void* $ctor(
75 ::gsl::not_null<::std::shared_ptr<::ResourcePack>> pack,
76 int subpackIndex,
77 bool isDependent,
78 ::PackSettings* packSettings
79 );
80
81 MCAPI void* $ctor(
82 ::gsl::not_null<::std::shared_ptr<::ResourcePack>> pack,
83 ::std::string const& subpackName,
84 bool isDependent,
85 ::PackSettings* packSettings
86 );
87 // NOLINTEND
88
89public:
90 // destructor thunk
91 // NOLINTBEGIN
92 MCAPI void $dtor();
93 // NOLINTEND
94};
Definition PreloadedPathHandle.h:15
Definition Path.h:17
Definition PackSettings.h:19
Definition ResourcePack.h:21