kangarko / ChatControl-Red

Issue tracker and documentation for the next generation ChatControl Red, the most advanced chat management plugin.
49 stars 23 forks source link

1.19: Custom Variable seems to break at random #2005

Closed HorusApl closed 2 years ago

HorusApl commented 2 years ago

Hello, I have a custom variable to display a little star symbol if player has X permission. It works fine 99% of the time, but 1% of the time it will simply show the name of my variable, rather then what they're supposed to be seeing. Not sure if there is a better way to do this or if this is a bug, but any help appreciated.

Variable:

getPronoun(); // call the function below that returns the tag or prefix

  function getPronoun() {
      // replace with the tag
      var tag = "{luckperms_check_permission_milestones.10}" == "yes";

      // if the tag is empty, return blank, else return tag
      return tag == "" ? "" : "#a19d94✦";
  }

I have 4 of the above variables, 10, 20, 30 and 40. In my chat.yml format:

  player-milestone:
    Message: '{milestones10}{milestones20}{milestones30}{milestones40}'
    Hover:
    - '&7Click to learn more!'
    Run_Command: /milestones

image

This is what happens that 1% of the time, for basically a single message. After this screenshot, it returned to the normal star and was fine. No lag was occurring on the server at this time, and only had about 12 people on. Minecraft Version: 1.19 MySQL: false BungeeCord: false

kangarko commented 2 years ago

Any console error message? Maybe we stopped executing variable parse because they took longer than expected and there is a console message about it.

HorusApl commented 2 years ago

No console error message.

kangarko commented 2 years ago

Still investigating, let me know when that happens again and include your /chc debug file so I can try reproducing