Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support pulling name heuristics from hover components #72

Closed
Nemo157 opened this issue Nov 9, 2023 · 1 comment
Closed

Support pulling name heuristics from hover components #72

Nemo157 opened this issue Nov 9, 2023 · 1 comment

Comments

@Nemo157
Copy link

Nemo157 commented Nov 9, 2023

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.

@Fourmisain
Copy link
Collaborator

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants