PaperMC / PaperMC/Velocity

sendMessage not working

Open
#1,444 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

type: bug
Dominant language
Java
Stars
2.3k
Forks
959
Avg merge
5d 10h
Merged PRs (30d)
2

Description

Expected Behavior

The player can normally receive system messages.

Actual Behavior

The sendMessage function executed normally, but the player did not receive any packet for any of the chats.
code

  • velocity log
    [02:54:01 INFO]: Booting up Velocity 3.4.0-SNAPSHOT (git-99aaf3ce-b439)...
    [02:54:01 INFO]: Loading localizations...
    [02:54:01 INFO]: Connections will use epoll channels, libdeflate (Linux x86_64) compression, OpenSSL 3.x.x (Linux x86_64) ciphers
    [02:54:01 INFO]: Loading plugins...
    [02:54:02 INFO] [packetevents]: Plugin started
    [02:54:02 INFO]: Loaded plugin packetevents 2.5.0 by retrooper
    [02:54:02 INFO]: Loaded plugin signedvelocity 1.2.4 by 4drian3d
    [02:54:02 INFO]: Loaded plugin xchat 1.0-SNAPSHOT by 
    [02:54:02 INFO]: Loaded 4 plugins
    [02:54:02 INFO] [packetevents]: Injecting packetevents...
    [02:54:02 WARN]: The server channel initializer has been replaced by java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
    [02:54:02 INFO]: Checking for updates, please wait...
    [02:54:02 INFO] [signedvelocity]: Starting SignedVelocity
    [02:54:02 INFO] [xchat]: Initialization XChat plugin
    [02:54:02 INFO]: Listening on /[0:0:0:0:0:0:0:0%0]:25599
    [02:54:02 INFO]: Done (1.21s)!
    [02:54:03 INFO]: You are running the latest release of PacketEvents. Your build: (§a2.5.0§f)
    [02:54:21 INFO]: [connected player] xiao_xigua (/127.0.0.1:38126) has connected
    [02:54:21 INFO]: [server connection] xiao_xigua -> lobby has connected
    [02:54:23 INFO]: Compound{{count=Int(1), components=Compound{{minecraft:custom_name=String("Diamond Swordasdasdasdad")}}, id=String(minecraft:diamond_sword)}}
    [02:54:23 INFO]: com.github.retrooper.packetevents.util.adventure.AdventureNBTSerializer$NbtComponentValue@3a3f9919
    [02:54:23 INFO]: Hello
    
  • client network log
Steps to Reproduce
Environment
  1. set up a Fabric backend and install the two mods: FabricProxy-Lite-2.9.0 and SignedVelocity-Fabric-1.2.4.
  2. set the player-info-forwarding-mode in the Velocity config to modern.
  3. under servers, add the previously created Fabric server.
Velocity Plugin
  1. create a HoverEvent.ShowItem with components.
  2. use ProxyServer.sendMessage to send it.
Plugin List
  • packetevents 2.5.0
  • signedvelocity 1.2.4
Velocity Version

Velocity 3.4.0-SNAPSHOT (git-99aaf3ce-b439)
Copyright 2018-2024 Velocity Contributors. Velocity is licensed under the terms of the GNU General Public License v3.
velocitypowered.com - GitHub

Additional Information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read velocity/src/main/kotlin/org/xiaoxigua/xchat/velocity/listeners/QueryEntityNBTListener.kt and trace the ProxyServer.sendMessage call using HoverEvent.ShowItem components. Reproduce it with the listed Fabric, Velocity, PacketEvents, and SignedVelocity setup, then inspect the client network log to determine whether the message packet is emitted and received. Done means system messages containing the item hover event reach the player.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, kotlin
Domain
api, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.