ProtocolLib issues

Discussion in 'Plugin Development' started by Tim_M, Oct 30, 2021.

  1. Offline


    I'm making a custom mob creator, in this creator you can set the sounds that the mobs make. The problem lies within actually playing those sounds. As a test I tried listening for a packet but it doesn't work, here's the code:
    public void listenPackets()
       new PacketAdapter(Main.instance, ListenerPriority.NORMAL, PacketType.Play.Server.ENTITY_SOUND)
       @Overridepublic void onPacketSending(PacketEvent event) {
       if (event.getPacketType() == PacketType.Play.Server.ENTITY_SOUND)
    The weird this is that only ENTITY_SOUND doesn't work, NAMED_SOUND packet works perfectly fine and prints "a", how can I fix this?[/CODE]

Share This Page