LeviLamina
Loading...
Searching...
No Matches
WritableBookItem.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/item/Item.h"
7
8// auto generated forward declare list
9// clang-format off
10class CompoundTag;
11class ItemStack;
12class ItemStackBase;
13class Player;
14struct PageContent;
15// clang-format on
16
17class WritableBookItem : public ::Item {
18public:
19 // prevent constructor by default
20 WritableBookItem();
21
22public:
23 // virtual functions
24 // NOLINTBEGIN
25 virtual ::ItemStack& use(::ItemStack& instance, ::Player& player) const /*override*/;
26
27 virtual bool requiresInteract() const /*override*/;
28
29 virtual ::std::string getInteractText(::Player const& player) const /*override*/;
30 // NOLINTEND
31
32public:
33 // member functions
34 // NOLINTBEGIN
35 MCAPI WritableBookItem(::std::string const& name, int id);
36 // NOLINTEND
37
38public:
39 // static functions
40 // NOLINTBEGIN
41 MCAPI static void _addPageAt(::ItemStackBase& book, int index, ::PageContent const& page);
42
43 MCAPI static ::PageContent _deletePage(::ItemStackBase& book, int index);
44
45 MCAPI static void _deletePages(::ItemStackBase& book);
46
47 MCAPI static void _replacePage(::ItemStackBase& book, int index, ::PageContent const& page);
48
49 MCAPI static void _signBookUserData(
50 ::CompoundTag& userData,
51 ::std::string title,
52 ::std::optional<::std::string> filteredTitle,
53 ::std::string author,
54 ::std::optional<::std::string> filteredAuthor,
55 ::std::string xuid
56 );
57
58 MCAPI static void addPageAt(::ItemStack& book, int index, ::PageContent const& page);
59
60 MCAPI static void createUserDataIfEmpty(::ItemStackBase& book);
61
62 MCAPI static ::PageContent deletePage(::ItemStack& book, int index);
63
64 MCAPI static void replacePage(::ItemStack& book, int index, ::PageContent const& page);
65
66 MCAPI static void signBook(
67 ::ItemStack& book,
68 ::std::string title,
69 ::std::optional<::std::string> filteredTitle,
70 ::std::string author,
71 ::std::optional<::std::string> filteredAuthor,
72 ::std::string xuid
73 );
74
75 MCAPI static void swapPages(::ItemStack& book, int page1, int page2);
76 // NOLINTEND
77
78public:
79 // constructor thunks
80 // NOLINTBEGIN
81 MCAPI void* $ctor(::std::string const& name, int id);
82 // NOLINTEND
83
84public:
85 // virtual function thunks
86 // NOLINTBEGIN
87 MCAPI ::ItemStack& $use(::ItemStack& instance, ::Player& player) const;
88
89 MCFOLD bool $requiresInteract() const;
90
91 MCAPI ::std::string $getInteractText(::Player const& player) const;
92
93
94 // NOLINTEND
95
96public:
97 // vftables
98 // NOLINTBEGIN
99 MCAPI static void** $vftable();
100 // NOLINTEND
101};
Definition CompoundTag.h:23
Definition ItemStackBase.h:52
Definition ItemStack.h:35
Definition Player.h:137
Definition PageContent.h:10