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

belowname bug #1332

Closed
5 tasks done
Szeffffff opened this issue Jul 9, 2024 · 3 comments
Closed
5 tasks done

belowname bug #1332

Szeffffff opened this issue Jul 9, 2024 · 3 comments
Labels
Resolution: Plugin works as described Plugin works as described on the wiki Type: Bug Plugin is not working as described on the wiki

Comments

@Szeffffff
Copy link

Server version

purpur 1.19.4

TAB version

4.1.6

Plugin list

image

Describe the bug

[02:03:08 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "25.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:08 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "25.6" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:09 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "25.6" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:10 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "26.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:10 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "26.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:11 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "27.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:12 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "27.6" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:13 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "27.6" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:13 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "28.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:14 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "28.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:15 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "29.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:15 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "29.1" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:16 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "29.6" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.
[02:03:17 INFO]: [TAB] [WARN] Belowname number is configured to show "%math_1_{player_health}/2%", but returned "30.0" for player Kus0y_CFLAG, which is a decimal number. Truncating to an integer.

Expected behavior

can be seen in the config:

belowname-objective:
enabled: true
number: "%math_1_{player_health}/2%"
text: "&4❤"
fancy-display-players: "&c%health%"
fancy-display-default: "NPC"
disable-condition: '%world%=disabledworld'

Steps to reproduce

Players on the server have 30 hearts by default, I don't know if this has an impact

belowname-objective:
enabled: true
number: "%math_1_{player_health}/2%"
text: "&4❤"
fancy-display-players: "&c%health%"
fancy-display-default: "NPC"
disable-condition: '%world%=disabledworld'

Additional info

players on the server have a default of 30 hearts

Checklist

  • I am running latest version of the plugin
  • I have read the wiki to make sure it's not an issue with configuration
  • I ticked all of the boxes without actually reading them
  • I have read the Compatibility wiki page and am not trying to run the plugin on an unsupported server version / platform
  • I am willing to cooperate to get this issue resolved faster, including providing any additional information requested or testing new builds
@Szeffffff Szeffffff added the Type: Bug Plugin is not working as described on the wiki label Jul 9, 2024
@NEZNAMY
Copy link
Owner

NEZNAMY commented Jul 9, 2024

image
What is the bug? This is a message informing you about an issue in your configuration.

@Szeffffff
Copy link
Author

What is the bug? This is a message informing you about an issue in your configuration.

How to disable/repair it?

@NEZNAMY
Copy link
Owner

NEZNAMY commented Jul 9, 2024

Why don't you use %math_0_{player_health}/2% instead so it rounds the number?

@NEZNAMY NEZNAMY added the Resolution: Plugin works as described Plugin works as described on the wiki label Aug 5, 2024
@NEZNAMY NEZNAMY closed this as not planned Won't fix, can't repro, duplicate, stale Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Plugin works as described Plugin works as described on the wiki Type: Bug Plugin is not working as described on the wiki
Projects
None yet
Development

No branches or pull requests

2 participants