Dieser Commit ist enthalten in:
Ursprung
7209fa8346
Commit
ed70caa3a3
@ -40,7 +40,7 @@ public class InventoryHandler extends PacketHandler {
|
||||
public static void handleInventoryPacket(InventoryPacket packet) {
|
||||
Map<Integer, SWItem> items = new HashMap<>();
|
||||
packet.getItems().forEach((i, item) -> {
|
||||
SWItem it = SWItem.getItemFromJson(JsonParser.parseString(item).getAsJsonObject());
|
||||
@SuppressWarnings("deprecation") SWItem it = SWItem.getItemFromJson(new JsonParser().parse(item).getAsJsonObject());
|
||||
it.setCallback(click -> NetworkSender.send(InventoryCallbackPacket.builder().owner(packet.getPlayer()).position(i).type(InventoryCallbackPacket.CallbackType.CLICK).clickType(InventoryCallbackPacket.ClickType.getByName(click.name())).build()));
|
||||
items.put(i, it);
|
||||
});
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren