LeviLamina
Loading...
Searching...
No Matches
ItemContext.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/shared_types/legacy/item/EquipmentSlot.h"
7
8// auto generated forward declare list
9// clang-format off
10class Container;
11class ItemStack;
12class Mob;
13class Vec3;
14// clang-format on
15
17public:
18 // member variables
19 // NOLINTBEGIN
28 // NOLINTEND
29
30public:
31 // prevent constructor by default
32 ItemContext& operator=(ItemContext const&);
35
36public:
37 // member functions
38 // NOLINTBEGIN
40
41 MCNAPI ::ItemStack const& _getItem() const;
42
43 MCNAPI void _setItem(::ItemStack const& item);
44
45 MCNAPI ::Container* _tryGetContainerFromEntity() const;
46
47 MCNAPI ::Container* _tryGetContainerFromItem() const;
48
49 MCNAPI ::std::optional<::std::vector<::std::string>> getDynamicPropertyIds(::std::string const& collection) const;
50
51 MCNAPI ::std::optional<::std::vector<::std::string>> getLore() const;
52
53 MCNAPI ::std::optional<::std::string> getNameTag() const;
54
55 MCNAPI bool isValid() const;
56
57 MCNAPI bool setAmount(int amount);
58
59 MCNAPI ::std::optional<bool> setCanDestroy(::std::vector<::std::string> const& blockIdentifiers);
60
61 MCNAPI ::std::optional<bool> setCanPlaceOn(::std::vector<::std::string> const& blockIdentifiers);
62
63 MCNAPI bool setDynamicProperty(
64 ::std::string const& collection,
65 ::std::string const& key,
66 ::std::optional<::std::variant<double, float, bool, ::std::string, ::Vec3>> const& optionalValue
67 );
68
69 MCNAPI bool setKeepOnDeath(bool value);
70
71 MCNAPI bool setLore(::std::optional<::std::vector<::std::string>> const& loreList);
72
73 MCNAPI bool setNameTag(::std::optional<::std::string> nameTag);
74
75 MCNAPI ~ItemContext();
76 // NOLINTEND
77
78public:
79 // static functions
80 // NOLINTBEGIN
81 MCNAPI static bool
82 _trySetEquippedSlot(::ItemStack const& item, ::SharedTypes::Legacy::EquipmentSlot equipmentSlot, ::Mob& mob);
83
84 MCNAPI static bool
85 setEquipment(::ItemStack const& item, ::SharedTypes::Legacy::EquipmentSlot equipmentSlot, ::Mob& mob);
86 // NOLINTEND
87
88public:
89 // constructor thunks
90 // NOLINTBEGIN
91 MCNAPI void* $ctor(::ItemContext&&);
92 // NOLINTEND
93
94public:
95 // destructor thunk
96 // NOLINTBEGIN
97 MCNAPI void $dtor();
98 // NOLINTEND
99};
Definition Container.h:30
Definition ItemContext.h:16
MCAPI bool setAmount(int amount)
MCAPI ::std::optional< bool > setCanDestroy(::std::vector<::std::string > const &blockIdentifiers)
static MCAPI bool setEquipment(::ItemStack const &item, ::SharedTypes::Legacy::EquipmentSlot equipmentSlot, ::Mob &mob)
MCAPI ::std::optional<::std::string > getNameTag() const
MCAPI ::std::optional<::std::vector<::std::string > > getDynamicPropertyIds(::std::string const &collection) const
MCAPI bool setNameTag(::std::optional<::std::string > nameTag)
MCAPI::Container * _tryGetContainerFromEntity() const
static MCAPI bool _trySetEquippedSlot(::ItemStack const &item, ::SharedTypes::Legacy::EquipmentSlot equipmentSlot, ::Mob &mob)
MCAPI ::std::optional<::std::vector<::std::string > > getLore() const
MCAPI bool setKeepOnDeath(bool value)
MCAPI bool setLore(::std::optional<::std::vector<::std::string > > const &loreList)
MCAPI ~ItemContext()
MCAPI bool setDynamicProperty(::std::string const &collection, ::std::string const &key, ::std::optional<::std::variant< double, float, bool, ::std::string, ::Vec3 > > const &optionalValue)
MCAPI ::std::optional< bool > setCanPlaceOn(::std::vector<::std::string > const &blockIdentifiers)
MCAPI bool isValid() const
MCAPI ItemContext(::ItemContext &&)
MCAPI void _setItem(::ItemStack const &item)
MCAPI::Container * _tryGetContainerFromItem() const
MCAPI::ItemStack const & _getItem() const
MCAPI void $dtor()
MCAPI void * $ctor(::ItemContext &&)
Definition ItemStack.h:25
Definition Mob.h:47
Definition Vec3.h:10
Definition Alias.h:14