Chat Heads

Chat Heads

35M Downloads

Support pulling name heuristics from hover components

Nemo157 opened this issue · 1 comments

commented

On a server I'm on using Styled Nicknames we have the player's account name displayed in a hover text:

image

json text components for the message
[
  {
    "color": "gold",
    "insertion": "Nemo157",
    "clickEvent": {
      "action": "suggest_command",
      "value": "/tell Nemo157 "
    },
    "hoverEvent": {
      "action": "show_text",
      "contents": {
        "text": "Nemo157"
      }
    },
    "extra": [
      {
        "text": "Tést"
      }
    ],
    "text": ""
  },
  {
    "text": ": "
  },
  {
    "text": "test"
  }
]

It would be useful if Chat Heads could look into these text components when using heuristics to find the name.

commented

Implemented in 1d35f87, new versions 0.10.23 are up!

Since hover text could be anything (you never know what mods/plugins are gonna do), I instead checked the sender decorator click event for a /tell command.