Skip to content

WrapperPlayServerSetSlot always set slot 0 #88

Description

@Aqueuse

Hello,

I try to learn protocolLib with the help of PacketWrapper but I'm facing a strange difficulty.

When I try to send an item to a player using WrapperPlayServerSetSlot it always send it to the slot number 0 of this player, even if I set it to another slot.

Here is my code :

ItemStack clockStack = new ItemStack(Material.FILLED_MAP);

WrapperPlayServerSetSlot wrapperPlayServerSetSlot = new WrapperPlayServerSetSlot();

wrapperPlayServerSetSlot.setSlotData(clockStack);
wrapperPlayServerSetSlot.setWindowId((byte) 0);
wrapperPlayServerSetSlot.setSlot((short)36);

wrapperPlayServerSetSlot.sendPacket(player);

Could you please tell me what I'm doing wrong ?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions