Hey! I'm trying to swap two ItemStacks server-side and client-side within the player's inventory. The current function I have is doing absolutely nothing - any ideas why?
private void swap(Integer from, Integer to) {
Integer windowId = mc.thePlayer.inventoryContainer.windowId;
mc.playerController.windowClick(windowId, from, 0, ClickType.PICKUP, mc.thePlayer);
mc.playerController.windowClick(windowId, to, 0, ClickType.SWAP, mc.thePlayer);
mc.playerController.windowClick(windowId, from, 0, ClickType.PICKUP, mc.thePlayer);
}
Thanks in advance!