3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/client/gui/DirtyFlag.h"
7#include "mc/client/gui/ViewRequest.h"
8#include "mc/client/gui/screens/controllers/ContainerScreenController.h"
9#include "mc/client/gui/screens/controllers/FadeInIconBehavior.h"
10#include "mc/deps/core/string/HashedString.h"
11#include "mc/world/containers/ContainerEnumName.h"
12#include "mc/world/item/FurnaceItemCategory.h"
25namespace Json {
class Value; }
36 enum class CategoryTabState :
int {
45 ::ll::TypedStorage<4, 4, ::FurnaceItemCategory> category;
46 ::ll::TypedStorage<1, 1, ::ContainerEnumName> containerEnum;
47 ::ll::TypedStorage<8, 32, ::std::string> tabName;
53 MCAPI ~CategoryTabInfo();
66 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::FurnaceContainerManagerController>>
67 mFurnaceContainerManagerController;
68 ::ll::TypedStorage<1, 1, ::ContainerEnumName> mHoveredContainer;
69 ::ll::TypedStorage<1, 1, ::ContainerEnumName const> mIngredientEnumName;
70 ::ll::TypedStorage<4, 4, int> mStartHeldFurnaceResultTime;
71 ::ll::TypedStorage<1, 1, bool> mPocket;
72 ::ll::TypedStorage<1, 1, bool> mEntered;
73 ::ll::TypedStorage<1, 1, bool> mRecipeLocked;
74 ::ll::TypedStorage<1, 1, bool> mUseRecipeUnlocking;
75 ::ll::TypedStorage<4, 4, int> mLayout;
76 ::ll::TypedStorage<4, 4, int> mSavedLayout;
77 ::ll::TypedStorage<1, 1, bool> mSmeltableFilterOn;
78 ::ll::TypedStorage<1, 1, bool> mSearchBarSelected;
79 ::ll::TypedStorage<8, 40, ::std::optional<::std::string>> mDelayedSearchString;
80 ::ll::TypedStorage<1, 1, bool> mHasInitalCategoryTabsState;
81 ::ll::TypedStorage<4, 4, int> mTicksLeftUntilCategoryTabUpdate;
82 ::ll::TypedStorage<4, 4, int> mTabFiltersDirty;
83 ::ll::TypedStorage<8, 48, ::HashedString> mRecipeTag;
84 ::ll::TypedStorage<4, 4, int> mSelectedLeftTab;
85 ::ll::TypedStorage<8, 32, ::std::string> mSelectedCollectionName;
86 ::ll::TypedStorage<4, 4, int> mSelectedCollectionIndex;
91 FurnaceScreenController();
96 virtual ~FurnaceScreenController() ;
98 virtual ::ui::DirtyFlag tick() ;
100 virtual void onEntered() ;
102 virtual void addStaticScreenVars(::Json::Value& globalVars) ;
104 virtual bool _isStillValid() const ;
106 virtual
void _handlePlaceAll(::std::
string const& collectionName,
int index) ;
108 virtual
void _handlePlaceOne(::std::
string const& collectionName,
int index) ;
110 virtual
void _registerCoalesceOrder() ;
112 virtual
void _registerAutoPlaceOrder() ;
114 virtual ::std::
string _getCollectionName(::UIPropertyBag* bag) const ;
116 virtual ::SlotData _reevaluateSlotData(::SlotData&& slotData) const ;
118 virtual ::ItemStackBase const&
119 _getVisualItemStackImpl(::std::
string const& collectionName,
int collectionIndex) const ;
121 virtual
bool _shouldSwap(
122 ::std::
string const& collectionName,
124 ::std::
string const& otherCollectionName,
125 int otherCollectionIndex
128 virtual
void _handleSelectSlot(::std::
string const& collectionName,
int collectionIndex) ;
130 virtual ::std::
string _getButtonADescription() ;
132 virtual ::std::
string _getButtonBDescription() ;
134 virtual ::std::
string _getButtonXDescription() ;
136 virtual ::std::
string _getButtonYDescription() ;
138 virtual ::ui::ViewRequest _onContainerSlotHovered(::std::
string const& collectionName,
int index) ;
140 virtual
bool _isInCreativeContainer(::std::
string const& containerName) const ;
142 virtual
void _sendFlyingItem(
143 ::ItemStackBase const& item,
144 ::std::
string const& fromName,
146 ::std::
string const& toName,
148 ::FadeInIconBehavior fadeInIconBehavior
155 MCAPI FurnaceScreenController(
156 ::std::shared_ptr<::ClientInstanceScreenModel> model,
158 ::BlockPos const& pos,
159 ::ActorUniqueID uniqueId,
160 ::HashedString const& recipeTag
163 MCAPI
int _findNextLeftSideTab(
int dir) const;
165 MCAPI ::std::
string _getExpandoItemGroupName(::std::
string const& collectionName,
int collectionIndex);
167 MCAPI ::FurnaceOptions const& _getFurnaceOptions() const;
169 MCAPI ::std::
string _getRecipeHoverText(::std::
string const& collectionName,
int collectionIndex);
171 MCAPI
void _handleClearGrid();
173 MCAPI
void _handleRecipeBookSelectSlot(::std::
string const& collectionName,
int collectionIndex);
175 MCAPI
bool _isBlocksTabVisible() const;
177 MCAPI
bool _isFoodTabVisible() const;
179 MCAPI
bool _isItemsTabVisible() const;
181 MCAPI
bool _isRecipeIngredientSelected(::std::
string const& collectionName,
int collectionIndex) const;
183 MCAPI
bool _isRecipeLocked(::std::
string const& collectionName,
int collectionIndex) const;
185 MCAPI
void _loadPlayerOptions();
187 MCAPI
void _refreshFilters(
int tabIndex,
bool forceRefresh);
189 MCAPI
void _registerBindings();
191 MCAPI
void _registerEventHandlers();
193 MCAPI
void _registerStateMachine();
195 MCAPI
void _savePlayerOptions();
197 MCAPI
void _selectRecipe(::std::
string const& collectionName,
int collectionIndex);
199 MCAPI
void _setIsFiltering(
bool smeltableFilterOn);
201 MCAPI
void _setLeftSideTab(
int tabIndex);
207 MCAPI static ::std::string_view const& RECIPE_BOOK_COLLECTION_NAME();
209 MCAPI static ::std::unordered_map<
int, ::FurnaceScreenController::
CategoryTabInfo> const& mCategoryTabs();
216 ::std::shared_ptr<::ClientInstanceScreenModel> model,
218 ::BlockPos const& pos,
219 ::ActorUniqueID uniqueId,
220 ::HashedString const& recipeTag
233 MCAPI ::ui::DirtyFlag $tick();
235 MCAPI
void $onEntered();
237 MCAPI
void $addStaticScreenVars(::Json::Value& globalVars);
239 MCFOLD
bool $_isStillValid() const;
241 MCAPI
void $_handlePlaceAll(::std::
string const& collectionName,
int index);
243 MCAPI
void $_handlePlaceOne(::std::
string const& collectionName,
int index);
245 MCAPI
void $_registerCoalesceOrder();
247 MCAPI
void $_registerAutoPlaceOrder();
249 MCAPI ::std::
string $_getCollectionName(::UIPropertyBag* bag) const;
251 MCAPI ::SlotData $_reevaluateSlotData(::SlotData&& slotData) const;
253 MCAPI ::ItemStackBase const&
254 $_getVisualItemStackImpl(::std::
string const& collectionName,
int collectionIndex) const;
256 MCAPI
bool $_shouldSwap(
257 ::std::
string const& collectionName,
259 ::std::
string const& otherCollectionName,
260 int otherCollectionIndex
263 MCAPI
void $_handleSelectSlot(::std::
string const& collectionName,
int collectionIndex);
265 MCAPI ::std::
string $_getButtonADescription();
267 MCAPI ::std::
string $_getButtonBDescription();
269 MCAPI ::std::
string $_getButtonXDescription();
271 MCAPI ::std::
string $_getButtonYDescription();
273 MCAPI ::ui::ViewRequest $_onContainerSlotHovered(::std::
string const& collectionName,
int index);
275 MCAPI
bool $_isInCreativeContainer(::std::
string const& containerName) const;
277 MCAPI
void $_sendFlyingItem(
278 ::ItemStackBase const& item,
279 ::std::
string const& fromName,
281 ::std::
string const& toName,
283 ::FadeInIconBehavior fadeInIconBehavior
Definition ClientInstanceScreenModel.h:5
Definition ContainerScreenController.h:5
Definition FurnaceContainerManagerController.h:22
Definition FurnaceScreenController.h:5
static MCAPI void ** $vftableForEnableNonOwnerReferences()
static MCAPI void ** $vftableForScreenController()
Definition ItemStackBase.h:44
Definition UIPropertyBag.h:5
Definition ActorUniqueID.h:5
Definition FurnaceOptions.h:5
Definition FurnaceScreenController.h:15