yesdog / Waterdog

Waterdog, a Yesdog fork of Waterfall/BungeeCord that adds Bedrock support.
MIT License
186 stars 37 forks source link

Editing the AvailableCommandsPacket doesn't work with Waterdog #103

Closed Wertzui123 closed 4 years ago

Wertzui123 commented 4 years ago

Version of Waterdog git:Waterdog-Bootstrap:1.15-SNAPSHOT:a1a01bc:298

Expected Behavior The command description and usage should change as expected, after editing the command data.

Actual Behavior Nothing changes.

Crashdump, Backtrace or Other Files

Describe the bug When I edit the command data while listening on a AvailableCommandsPacket, the new data isn't sent to the client. It works on servers without waterdog.

To Reproduce

  1. Make a plugin which listens on the AvailableCommandsPacket and edits the command descriptions
  2. Join the server and type the command to see it's description and usage - it hasn't changed

Screenshots

Server software used: PocketMine-MP 3.11.6

Additional context

Alemiz112 commented 4 years ago

You should specify more information. What do you mean by listens on the AvailableCommandsPacket? Is the plugin for Waterdog or for PMMP?

Alemiz112 commented 4 years ago

Actually Waterdog does not catch or work with this packet. It would help if you could provide some example code.

Wertzui123 commented 4 years ago

For PocketMine, I mean something like

public function onAvailableCommands(DataPacketSendEvent $event){
        if($event->getPacket() instanceof AvailableCommandsPacket) {
            // edit command data
        }
}
Wertzui123 commented 4 years ago

I'm sorry, it was caused by another plugin.