AbstractContainerScreen screens.F for “Deposit Container” and G for “Deposit Inventory`. They only work while the sidebar is visible and the search box is not focused.config/better_beyond_dimensions-settings.json and synchronized with the server when a new screen is opened.SidebarDisplayEvent is fired on the client after the sidebar has been created and before it is displayed. The event can access the current Screen, disable the functionality of individual buttons, override button text or tooltips, or completely disable the sidebar for the current screen. The event only affects the current screen instance and does not modify the server-side menu.
For example, to disable “Deposit Container” on the crafting screen and change its tooltip to “Disabled”:
private static void onSidebarDisplay(SidebarDisplayEvent event)
{
if (event.getScreen() instanceof CraftingScreen)
{
event.disableButton(SidebarDisplayEvent.ButtonId.DEPOSIT_CONTAINER);
event.setButtonTooltip(
SidebarDisplayEvent.ButtonId.DEPOSIT_CONTAINER,
Component.literal("Disabled")
);
}
}