Closed stijnb1234 closed 4 years ago
Would you mind attaching a snippet of your code (for both the itemframe and inventory ones)?
public static void render() {
//AFRender is my object where I store the MapWrapper
AFRender render = new AFRender();
BufferedImage img = ...;
MapWrapper wrapper = mapManager.wrapImage(img);
render.setWrapper(wrapper);
for (Player p: Bukkit.getServer().getOnlinePlayers()) {
showForPlayer(p, /* I get the frame from another object */ , render);
}
}
public static void showForPlayer(Player p, ItemFrame frame, AFRender render) {
MapController controller = render.getWrapper().getController();
controller.addViewer(p);
controller.sendContent(p);
controller.showInFrame(p, frame, true);
}
public static void showInInv(Player p, AFRender render) {
render.getWrapper().getController().showInHand(p, true);
}
Fixed in 1.7.6-SNAPSHOT :)
What steps will reproduce the problem?
What were you expecting to happen? What happened instead?
A good image is shown
What version of the plugin are you using? Type /version <Plugin Name>
1.7.5-SNAPTSHOT
What Spigot version are you using? Type /version
1.14.4-R0.1-SNAPSHOT [PaperSpigot build 237]
What plugins are you using? Type /plugins
The image (ArrayImage) is okay.
But it's not shown in the inventory, and it says "Unkown map"