Trouble with the event PluginMessageEvent

Hi i’m new with Velocity! i have some trouble with the event ‘PluginMessageEvent’ because it’s never gets fired… Is there any problem with my code or is it a problem with velocity? thanks in advance!

Velocity Version: 1.1.2

Main Class:

package me.rudy.main;

import com.velocitypowered.api.event.Subscribe;
import com.velocitypowered.api.event.connection.PluginMessageEvent;
import com.velocitypowered.api.event.proxy.ProxyInitializeEvent;
import com.velocitypowered.api.plugin.Plugin;
import com.velocitypowered.api.proxy.ProxyServer;
import com.velocitypowered.api.proxy.messages.*;
import org.slf4j.Logger;

@Plugin(id = "test", name = "TestPlugin", version = "1.0-SNAPSHOT", authors = {"iim_rudy"})
public class Main {

    private static final LegacyChannelIdentifier LEGACY_BUNGEE_CHANNEL = new LegacyChannelIdentifier("BungeeCord");
    private static final MinecraftChannelIdentifier MODERN_BUNGEE_CHANNEL = MinecraftChannelIdentifier.create("bungeecord", "main");
    private final ProxyServer server;
    private final Logger logger;

    public Main(ProxyServer server, Logger logger) {
        this.server = server;
        this.logger = logger;

    public void onProxyInitialize(ProxyInitializeEvent event) {
        server.getChannelRegistrar().register(LEGACY_BUNGEE_CHANNEL, MODERN_BUNGEE_CHANNEL);

    public void onPluginMessage(PluginMessageEvent event) {;


Velocity handles the BungeeCord plugin messaging channel itself; you cannot override Velocity’s handling of it until you disable Velocity’s handling of the BungeeCord plugin messaging channel in velocity.toml.

Now it’s working! Really thanks & Merry christmas!