Catch Packet103SetSlot and Packet104WindowItems

Discussion in 'BungeeCord Plugin Development' started by mak, Sep 1, 2013.

  1. mak

    mak

    Hey,
    I'm trying to find an event or an other posibility to catch these packets.
    Is there any way to do this without changing the source of BungeeCord?

    Regards mak
     
  2. md_5

    Administrator Developer

    Unfortunately we don't have any sort of packet api for receiving in BungeeCord, only sending :(
     
  3. mak

    mak

    Okay... :( But isn't there atleast an way to hook into BungeeCoord (Maybe via reflection) to get the recived packet as an ByteBuf? Or isn't there any possibility...
     
  4. mak

    mak

    Ok... i finally found out how to add my own packet:
    Code (Text):
    Vanilla.getInstance().getClasses()[103] = Packet103SetSlot.class;
    In my Packet103SetSlot (extends DefinedPacket) i wrote my own ByteBuf reader and finally got it!
    But theres one problem left i don't know how to cancel the sending of the old packet...
     
  5. mak

    mak

    Ok got it i just had to throw an CancelSendSignal :)
    And i did the same thin for the packet 104
     
    #5 mak, Sep 2, 2013
    Last edited: Sep 2, 2013