Minecraft script anvil menu?

Ka
4

I wanted to script a small system for my Minecraft project (1.8.9)

However, I need the GUI that opens when you click on an anvil. Does any of you know how to do that? If so, please write it to me under the question.

st

Do you want to open the GUI via a command or something or what?

Ka

Yes

st

This is a bit complicated

EntityPlayer internal = ((CraftPlayer) player) .getHandle ();
Location l = player.getLocation ();

BlockPosition pos = new BlockPosition (l.getBlockX (), l.getBlockY (), l.getBlockZ ());

// Here you create the inventory and open it
BlockAnvil.TileEntityContainerAnvil anvil = new BlockAnvil.TileEntityContainerAnvil (internal.world, pos);
internal.openTileEntity (anvil);

// This must be set because there's no real anvil in the position specified above
internal.activeContainer.checkReachable = false;

Ka

I mean script (javascript)