LeviLamina
Loading...
Searching...
No Matches
ContainerWeakRef.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/legacy/ActorUniqueID.h"
7#include "mc/world/TypedRuntimeId.h"
8#include "mc/world/inventory/ActorContainerType.h"
9#include "mc/world/level/BlockPos.h"
10
11// auto generated forward declare list
12// clang-format off
13class Actor;
14class BlockSource;
15class Container;
18// clang-format on
19
20class ContainerWeakRef {
21public:
22 // member variables
23 // NOLINTBEGIN
24 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mContainerActor;
25 ::ll::TypedStorage<4, 4, ::ActorContainerType> mActorContainerType;
26 ::ll::TypedStorage<4, 12, ::BlockPos> mBlockPosition;
27 ::ll::TypedStorage<4, 4, ::ContainerRuntimeId> mContainerRuntimeId;
28 ::ll::TypedStorage<8, 16, ::std::weak_ptr<::Container>> mWeakContainer;
29 // NOLINTEND
30
31public:
32 // member functions
33 // NOLINTBEGIN
34 MCAPI ContainerWeakRef();
35
36 MCAPI explicit ContainerWeakRef(::std::weak_ptr<::Container> ref);
37
38 MCAPI ContainerWeakRef(::BlockPos const& blockPos, ::ContainerRuntimeId const& containerRuntimeId);
39
40 MCAPI ContainerWeakRef(
41 ::ActorUniqueID const& actorId,
42 ::ActorContainerType containerType,
43 ::ContainerRuntimeId const& containerRuntimeId
44 );
45
46 MCAPI explicit operator bool() const;
47
48#ifdef LL_PLAT_C
49 MCAPI ::ContainerWeakRefData tryGetContainer(::BlockSource& region) const;
50#endif
51
52 MCAPI ~ContainerWeakRef();
53 // NOLINTEND
54
55public:
56 // static functions
57 // NOLINTBEGIN
58#ifdef LL_PLAT_C
59 MCAPI static ::Container* tryGetActorContainer(::Actor& actor, ::ActorContainerType containerType);
60#endif
61 // NOLINTEND
62
63public:
64 // constructor thunks
65 // NOLINTBEGIN
66 MCAPI void* $ctor();
67
68 MCAPI void* $ctor(::std::weak_ptr<::Container> ref);
69
70 MCAPI void* $ctor(::BlockPos const& blockPos, ::ContainerRuntimeId const& containerRuntimeId);
71
72 MCAPI void* $ctor(
73 ::ActorUniqueID const& actorId,
74 ::ActorContainerType containerType,
75 ::ContainerRuntimeId const& containerRuntimeId
76 );
77 // NOLINTEND
78
79public:
80 // destructor thunk
81 // NOLINTBEGIN
82 MCFOLD void $dtor();
83 // NOLINTEND
84};
Definition Actor.h:123
Definition BlockPos.h:21
Definition BlockSource.h:72
Definition Container.h:34
Definition ActorUniqueID.h:10
Definition ContainerRuntimeIdTag.h:5
Definition ContainerWeakRefData.h:12