Compare commits

...
3934 Commits
Author SHA1 Message Date
NotAlexNoyle 0f5f7e48dd Update canonical Gitea links 2026-10-30 14:19:35 -04:00
NotAlexNoyle 35e5791926 Update canonical Gitea links 2026-10-30 14:19:35 -04:00
NotAlexNoyle 6ca711435f Exclude CODEOWNERS from language statistics 2026-10-29 16:19:04 -04:00
NotAlexNoyle e8be71a34a Add CODEOWNERS (one staff approval) 2026-10-29 16:19:04 -04:00
NotAlexNoyle 7d0beb6ff2 Add Unions-OG tag 2026-08-09 12:02:07 -04:00
NotAlexNoyleandClaude Fable 5 68d0cdcbe7 TrueOG Network fork of TAB
Soft fork of upstream TAB at 93cfd74, versioned 5.9.9 for Purpur 1.19.4
serving 1.8-1.21.11 clients through ViaVersion/ViaBackwards/ViaRewind.

- Build only Bukkit v1_19_R3, BungeeCord, and Velocity; drop Fabric,
  Forge, NeoForge, and unused NMS modules
- LuckPerms 5.5 (Vault removed), GraalVM JDK 17, one shaded JAR
- Vanish-OG and AFK-OG compatibility, legacy scoreboard team colors,
  disabled scoreboard number formats
- Legacy (1.8-1.12.2) floating nametags: rank brackets dropped, AFK
  badge bolded everywhere, bold rank kept only when the whole tag can
  render bold (legacy width calc counts post-paragraph-l glyphs as bold
  and never receives paragraph-r, else phantom pixels pad the tag end);
  needs ViaBackwards add-teamcolor-to-prefix: false
- Ship live TrueOG Network config values

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N82WDRsXtPi7iRxx1wypXW
2026-07-12 17:58:53 -04:00
NEZNAMY 93cfd74fc0 [Bukkit] Refactor NMS implementation finding 2026-04-03 16:17:09 +02:00
NEZNAMY 79eb6a9078 [Bukkit] Rename classes and add console print 2026-04-03 12:54:07 +02:00
NEZNAMY 2e9e5042e1 Improve handling of IO errors on startup 2026-04-03 12:34:59 +02:00
NEZNAMY bb520edd53 [Bukkit] Catch correct exception and improve error message 2026-03-31 19:13:57 +02:00
NEZNAMY 2beb9563bb [BossBar] Forward UUID to platforms to prepare for 26.1 changes 2026-03-31 17:02:28 +02:00
NEZNAMY 87c15f7611 Bump dependencies 2026-03-31 16:35:52 +02:00
NEZNAMY 655bc176fa [Scoreboard] Fix line score recalculate issue (#1632) 2026-03-30 19:43:59 +02:00
NEZNAMY 66cb30d235 [Commands] Register debug command back to inform users about dump command 2026-03-28 19:32:43 +01:00
NEZNAMY cbe0b25b5f Java 25 and Spigot 26.1 support 2026-03-28 18:22:08 +01:00
NEZNAMY a8ccf4e1c9 Properly initialize minor version for 26.1 2026-03-28 18:17:04 +01:00
NEZNAMY cce29c51e3 Add 26.1 protocol constant 2026-03-25 17:24:49 +01:00
NEZNAMY 242015b0cc [Per world playerlist] Further improve compatibility with vanish plugins (#1621) 2026-03-24 17:41:56 +01:00
NEZNAMY f209e1b0f9 [Per world playerlist] Add vanish check for better compatibility with other plugins (#1621) 2026-03-21 16:16:06 +01:00
NEZNAMY 8a1ab06585 [Bukkit] Update bStats chart 2026-03-21 15:33:21 +01:00
NEZNAMY 50e817a86d [Per world playerlist] Use modern showPlayer/hidePlayer methods with plugin argument for better compatibility with other plugins (#1621) 2026-03-21 10:45:14 +01:00
NEZNAMY dbd596f079 [Belowname / Playerlist objective] Improve parity between the features 2026-03-09 18:43:34 +01:00
NEZNAMY f8e3a07e6f [Belowname / Playerlist objective] Finish vanish support checks after #1629 2026-03-09 17:49:47 +01:00
NEZNAMY ccd4ac3271 Merge pull request #1629 from c0bl/fix/vanished_score_packets
Consider canSee in YellowNumber.java setScore
2026-03-09 17:46:54 +01:00
c m fce1925448 consider canSee when sending scoreboard score packets in yellownumber feature 2026-03-08 21:14:14 -04:00
NEZNAMY 335eb5ef4d [Wiki] Monthly wiki backup for changes made in February 2026 2026-03-08 08:37:45 +01:00
NEZNAMY 654c40b892 [MySQL] Include MySQL driver in the jar for it to work on Velocity and modded platforms (#1620) 2026-03-07 11:46:09 +01:00
NEZNAMY a937243cdf [Dump command] Add proxy players to nametag player table 2026-03-03 17:17:13 +01:00
NEZNAMY 665d6baf1c [Configuration] Add config conversion for the new option (#1626) 2026-03-02 18:41:53 +01:00
NEZNAMY b4d326b52c Merge pull request #1626 from BlvckBytes/placeholders_locale
[Placeholders] Added locale of date-/time-format to config.yml
2026-03-02 18:26:36 +01:00
BlvckBytes 3aacec826b [Placeholders] Added locale of date-/time-format to config.yml 2026-03-01 22:42:27 +01:00
NEZNAMY 3261856385 [Forge/NeoForge] Remove redundant content for easier backporting 2026-02-28 18:05:51 +01:00
NEZNAMY 8cf479bf3b [Forge/NeoForge] Workaround to fix tablist tracking not working properly caused by events being fired too late (#1623) 2026-02-28 11:21:34 +01:00
NEZNAMY 3c3ef636eb [Code style] Remove redundant calls 2026-02-21 21:49:06 +01:00
NEZNAMY 3bd0b13740 [Bukkit] Fix error on Folia 2026-02-15 13:48:34 +01:00
NEZNAMY 92349227a2 Merge pull request #1617 from Arava-0/feat/scoreboard-api-setLines
feat(scoreboard): add setLines method for dynamic line updates
2026-02-13 16:47:01 +01:00
Arava-0 4dfc2a638a feat(scoreboard): add setLines method for dynamic line updates
- Introduces a new method to replace all current scoreboard lines with a provided list.
- Prevents unnecessary updates if the new list is identical to the current one.
2026-02-13 14:58:36 +01:00
NEZNAMY d7c73a8072 [Tablist Formatting] Add information about proxy players to dump output 2026-02-10 17:44:55 +01:00
NEZNAMY 297acc0322 [Belowname & Playerlist objectives] Add information about proxy players to dump output 2026-02-10 17:14:44 +01:00
NEZNAMY 1126b3b471 [Global playerlist] Do not remove players from the same server on quit, let backend handle it (#1611) 2026-02-08 18:07:59 +01:00
NEZNAMY ac59973283 [Tablist] Use ConcurrentHashMap as WeakHashMap was not used the intended way anyway (also may have been causing an issue) 2026-02-08 16:00:15 +01:00
NEZNAMY 4b130ed71d Update Gradle 9.1.0 -> 9.3.1 2026-02-07 18:13:00 +01:00
NEZNAMY ce90a33ce9 [BossBar] Fix unfreezing issue on Velocity and rename some methods (#1610) 2026-02-07 10:09:42 +01:00
NEZNAMY 50fee32218 [Velocity] Bump minimum required Velocity build to 546 (after the bossbar bug was partially fixed) to avoid my head exploding when trying to fix the issue in TAB (and having to make it support the older versions as well) (#1610) 2026-02-06 20:02:51 +01:00
NEZNAMY 39334a4cd9 [Dump command] Add placeholders sent by bridge on proxy installation 2026-02-04 18:26:12 +01:00
NEZNAMY fec2131ba8 [Wiki] Monthly wiki backup for changes made in January 2026 2026-02-02 17:57:02 +01:00
NEZNAMY 7c63436da4 Fix error 2026-02-01 15:05:41 +01:00
NEZNAMY de8fe63bd0 [Components] Partially implement click event and use it in dump command to make the link clickable 2026-01-31 14:40:07 +01:00
NEZNAMY 1c22f2387b [Sorting] Remove redundant variable 2026-01-31 11:16:49 +01:00
NEZNAMY e1b277582a [Sorting] Remove team name note tracking as debug command was deleted and dump already contains this information in a better way 2026-01-31 10:44:11 +01:00
NEZNAMY 94acc4f356 [Placeholders] Create class for holding placeholders to fix issues with re-registering placeholders 2026-01-31 10:39:58 +01:00
NEZNAMY 9afb62a6a4 [Placeholders] Simplify internal placeholder refresh interval handling and make it technically closer to simply pretending they are in the config 2026-01-30 18:58:15 +01:00
NEZNAMY 95ed957d54 [Configuration] Remove comment from default config that is no longer true 2026-01-30 17:10:24 +01:00
NEZNAMY 58814bc2da [API] [Layout] Add method for fixed slot ping as string 2026-01-29 16:07:13 +01:00
NEZNAMY 9e7556c3c1 [Dump Command] Do not show anonymous conditions as they are ugly in the output 2026-01-27 17:42:43 +01:00
NEZNAMY abaf723fb7 [Tablist Formatting] Fix tracked name not being assigned if target player cannot be seen, breaking the feature on server switch 2026-01-26 20:18:51 +01:00
NEZNAMY f52e99c86e [Conditions] Fix conditions not refreshing 2026-01-26 19:05:06 +01:00
NEZNAMY d6e70c35d8 [Dump Command] [Nametags] Dump all display values for all players in a table 2026-01-26 17:55:11 +01:00
NEZNAMY 4c91e73f0e [API] [Layout] Add method for specifying slot count when creating a new layout 2026-01-26 17:16:38 +01:00
NEZNAMY d083fc6e43 [Dump Command] Add table of tablist formatting for all players into dump 2026-01-25 19:47:35 +01:00
NEZNAMY ff2df25e3b [Commands] Delete debug command and update references to dump command 2026-01-25 17:10:40 +01:00
NEZNAMY 86c2342097 Replace most minor version checks with protocol version to prepare for new versioning system. 2026-01-25 16:49:28 +01:00
NEZNAMY 6dbd176683 [Dump Command] Include bridge info about player on proxy installation 2026-01-25 16:06:36 +01:00
NEZNAMY 141aab1c22 [Dump Command] Include list of downloaded PlaceholderAPI expansions 2026-01-25 15:29:10 +01:00
NEZNAMY 126ea4f456 [Dump Command] Print values for all players in belowname and playerlist objectives instead of just the selected player 2026-01-25 15:14:43 +01:00
NEZNAMY a0e5a97594 [Dump Command] Add general config settings to output 2026-01-25 14:54:19 +01:00
NEZNAMY 0420c11937 [Dump Command] Add placeholder-related config sections 2026-01-25 13:46:57 +01:00
NEZNAMY 27472fd387 [Dump Command] Format placeholder values in a table 2026-01-25 12:31:19 +01:00
NEZNAMY 104bdc646f [Dump Command] Improve sorting feature output 2026-01-25 11:44:34 +01:00
NEZNAMY cbc4c275d1 [Description] Update badges 2026-01-24 14:18:17 +01:00
NEZNAMY 372d51f873 Merge branch 'master' of https://github.com/NEZNAMY/TAB
# Conflicts:
#	build.gradle.kts
2026-01-24 14:16:40 +01:00
NEZNAMY 0dfd404215 5.5.0 2026-01-24 11:31:27 +01:00
NEZNAMY 21b7393274 [Dump command] Add more features to output 2026-01-23 20:03:14 +01:00
NEZNAMY dcd5f5a3e6 [Dump command] Improve output and create a class for features with display condition to avoid code duplication 2026-01-23 19:42:29 +01:00
NEZNAMY bf313b3ba1 [Commands] Use better error logging than e.printStackTrace() 2026-01-21 19:50:57 +01:00
NEZNAMY 5b4e3c479c [Commands] Add player info to dump command 2026-01-21 19:40:56 +01:00
NEZNAMY 6dedb05c29 [Commands] Drastically improve the new dump command 2026-01-21 18:18:31 +01:00
NEZNAMY 5f78e01342 [Commands] Initial implementation of /tab dump command 2026-01-18 17:38:07 +01:00
NEZNAMY 881506a3d5 [Tab expansion] Refactor the way data is stored. 2026-01-18 13:59:27 +01:00
NEZNAMY e26fc661b2 [Scoreboard] Execute scoreboard commands in scoreboard thread to avoid error 2026-01-17 20:50:19 +01:00
NEZNAMY f921758ec0 [Placeholders] Small optimization to replacing 2026-01-17 13:21:42 +01:00
NEZNAMY 01d65ba780 [Placeholders] Start rework of placeholder retrieving for better performance and dynamic placeholders 2026-01-17 12:29:55 +01:00
NEZNAMY d77e2d6f45 [Belowname] Clean up and use a different check for vanished players 2026-01-11 18:49:18 +01:00
NEZNAMY 7c30f55f31 [Bukkit] Remove support for several old MC versions 2026-01-11 16:48:47 +01:00
NEZNAMY c2d63865d5 [Bukkit] Repackage paper classes 2026-01-11 15:09:17 +01:00
NEZNAMY f406b518c0 [Bukkit] Add bStats chart 2026-01-11 15:01:42 +01:00
NEZNAMY 78f8c99f11 6.0.0-SNAPSHOT 2026-01-11 14:03:24 +01:00
NEZNAMY f97b9a419f [Performance] Clean up after PR #1600 2026-01-11 12:56:18 +01:00
NEZNAMY f2b88b8cd6 Merge pull request #1600 from groundbreakingmc/master
perf: replace String.format with StringBuilder for faster placeholder…
2026-01-11 12:20:22 +01:00
GroundbreakingMC cd06700c82 perf: implement element-based text parsing for cleaner placeholder replacement 2026-01-11 12:03:50 +01:00
NEZNAMY fa69040e00 Increase thread shutdown timeout to 5000 2026-01-11 11:19:48 +01:00
GroundbreakingMC fd88c1c0bb perf: skip StringBuilder allocation when no placeholders present 2026-01-11 07:22:23 +01:00
GroundbreakingMC cae7d8d061 perf: replace String.format with StringBuilder for faster placeholder replacement 2026-01-11 06:56:11 +01:00
NEZNAMY 2e1e24c225 Merge pull request #1599 from byPixelTV/master
feat: better wildcard support and enhanced pettern matching w/ regex for global player list
2026-01-10 18:47:56 +01:00
Lukas da0307b14f docs(global player list): describe new regex support in the wiki +
old wildcard support
2026-01-10 18:13:26 +01:00
Lukas 082c94ac07 fix(dependencies): change libs disguises repo because the old one is returning a 404 when trying to access it 2026-01-10 18:08:25 +01:00
Lukas 2ed4b1b6fc feat(global player list): enhance wildcard support and add advanced pattern matching w/ regex 2026-01-10 18:06:40 +01:00
NEZNAMY 8c7c8042e5 Merge pull request #1598 from Mattrolol/master
Layout: allow placeholder-based ping values for fixed slots
2026-01-07 18:47:06 +01:00
Mattrolol cca15a2b04 Fix fixed-slot ping validation and warnings 2026-01-07 11:43:05 -06:00
NEZNAMY 5f40411be0 [Debug] Add more messages unload 2026-01-07 18:00:30 +01:00
NEZNAMY 191273a728 [Debug] Add more messages on load/unload 2026-01-07 17:09:05 +01:00
Mattrolol 9eb9e9589f Allow placeholder-based ping values for fixed slots 2026-01-07 02:05:59 -06:00
NEZNAMY fdd45952c7 [Placeholders] Make %online_<server>% work on backend as well 2026-01-06 13:16:52 +01:00
NEZNAMY 98378b222d [Bukkit] Add relational placeholders into tab expansion and parse nested placeholders in normal placeholders 2026-01-03 09:45:52 +01:00
NEZNAMY 15a0446d70 [Conditions] Add warning text if condition is used in the wrong rel / non-rel way 2026-01-02 17:55:12 +01:00
NEZNAMY 7bd1b7c670 [Wiki] Monthly wiki backup for changes made in December 2025 2026-01-01 11:46:28 +01:00
NEZNAMY 46aaa47fdd [Forge] Add hook into a random Vanish mod for checking vanish status 2025-12-31 20:29:04 +01:00
NEZNAMY 2027e9f58e [Forge] Add support for ForgePlaceholderAPI 2025-12-31 17:51:32 +01:00
NEZNAMY 162e4690e9 [Scoreboard] Remove old options from valid key list 2025-12-30 21:06:22 +01:00
NEZNAMY c360575dec [Commands] Support args in dynamic commands 2025-12-28 17:45:56 +01:00
NEZNAMY 5b0354c2c0 [Layout] Rename "condition" to "display-condition" for better consistency with other features 2025-12-27 18:41:13 +01:00
NEZNAMY 52b0f21bd9 [Layout] Small refactor to layout code 2025-12-27 13:39:46 +01:00
NEZNAMY 1e3cbde3b3 [Layout] Merge both fake player layout types due to how similar they are 2025-12-27 12:33:02 +01:00
NEZNAMY 267fb727c7 [Layout] Only mark relational condition as used if actually used as relational 2025-12-26 21:02:50 +01:00
NEZNAMY 68904f58ec [Configuration] Reorder config options for more consistency 2025-12-24 11:54:12 +01:00
NEZNAMY 5cbb1bb5dd [Commands] Return list of messages to send when plugin is disabled as components instead of strings, also fix error when printing them on BungeeCord 2025-12-23 15:21:26 +01:00
NEZNAMY 038d221206 [Performance] Fix conditions being parsed as relational placeholders when not needed 2025-12-23 10:13:55 +01:00
NEZNAMY 22d6ebd0d4 [Performance] Small optimization to condition parsing 2025-12-23 09:21:51 +01:00
NEZNAMY e8dd46c701 [Commands] Modify console vs player check to account for other types of command sender (#1594) 2025-12-22 17:49:54 +01:00
NEZNAMY 1150d07dbe [Configuration] Update config version in default config 2025-12-22 15:52:34 +01:00
NEZNAMY 5c294f4ad3 [Header/Footer] Fix condition update not being processed in feature's thread 2025-12-22 15:51:34 +01:00
NEZNAMY 1b5bf0aab7 [Proxy support] Make channel name partially configurable 2025-12-21 14:13:39 +01:00
NEZNAMY 8d8a03602e [Scoreboard] Make red numbers fully configurable and remove config options related to it as they are redundant now (#1592) 2025-12-21 09:59:23 +01:00
NEZNAMY df7bdb7a0c [Velocity] Change bossbar bug compensation code as it wasn't actually fully fixed yet (#1593) 2025-12-20 10:03:58 +01:00
NEZNAMY 00a5eb2588 [Velocity] Remove header/footer packet modifying since it doesn't work anyway (they are never decoded when coming from backend) 2025-12-19 16:08:39 +01:00
NEZNAMY 90631c66e0 [Velocity] Use internals to inject into pipeline and listen to and modify packets. 2025-12-19 12:52:53 +01:00
NEZNAMY c1ba692a79 Bump version to 5.5.0-SNAPSHOT considering the massive upcoming changes and additions 2025-12-19 12:50:06 +01:00
NEZNAMY 8f3324e0d8 [Layout] Add new slot-count option to default config 2025-12-18 16:01:37 +01:00
NEZNAMY 5a09a9ce78 [Layout] Add support for layouts with less than 4 columns for 1.19.3+ (does not work on Velocity (yet?)) 2025-12-18 15:36:45 +01:00
NEZNAMY 33fcee7641 [Layout] Add support for new relational conditions and relational placeholders 2025-12-17 12:22:45 +01:00
NEZNAMY 12b91940c7 [Conditions] Add support for relational conditions and specifying who to parse placeholders for using %viewer:placeholder% and %target:placeholder% (optional) 2025-12-17 11:57:20 +01:00
NEZNAMY 0e6246f044 [Forge] Update to 1.21.11 2025-12-12 19:01:27 +01:00
NEZNAMY 7f7cf97408 [Tablist] Avoid sending tablist packets of entries which are not in the tablist (yet, on join), which caused a warning message in the client. 2025-12-12 15:46:39 +01:00
NEZNAMY 090fe9ccb6 [Tablist] Start improved tracking of tablist entries 2025-12-10 20:40:54 +01:00
NEZNAMY ffae161282 5.4.1-SNAPSHOT 2025-12-10 18:00:47 +01:00
NEZNAMY 1443850344 [Description] Update badges 2025-12-10 16:58:58 +01:00
NEZNAMY 63f9daf334 5.4.0 2025-12-10 16:45:20 +01:00
NEZNAMY b277d0973a Update to 1.21.11 (except Forge, which is broken) 2025-12-10 16:44:56 +01:00
NEZNAMY 33c0f1672a [Fabric] Update to 1.21.11-rc2 2025-12-05 20:15:39 +01:00
NEZNAMY 4224922ebb [Bukkit] Fix HEARTS render type not working on 1.8 - 1.12 2025-12-04 19:10:40 +01:00
NEZNAMY 6eb30d84b4 [Fabric] Update to 1.21.11-pre4 2025-12-01 18:27:07 +01:00
NEZNAMY 592a75b53f [Wiki] Monthly wiki backup for December 2025 2025-12-01 18:12:35 +01:00
NEZNAMY 8e08ea4e44 [Tablist] Fix gamemode being changed in packets when it shouldn't be (#1568) 2025-11-29 16:19:34 +01:00
NEZNAMY cff1e831d0 [Components] Fix packet decoding error due to too many nested levels caused by disabling MM compacting + resetting magic codes before every color 2025-11-29 09:34:17 +01:00
NEZNAMY 83b5a0f88a [NameTags] Fix nametag being forcibly hidden when player is invisible, making them invisible even in spectator gamemode 2025-11-26 18:25:09 +01:00
NEZNAMY 2ba535111e [Fabric] Update to 1.21.11-pre3 2025-11-26 18:10:48 +01:00
NEZNAMY 4bbf0bb0f1 [Configuration] Change default config to use true/false instead of yes/no to avoid confusion (#1581) 2025-11-24 16:33:51 +01:00
NEZNAMY 1e80070d2d [Fabric] Update to 1.21.11-pre2 2025-11-22 10:59:53 +01:00
NEZNAMY 0afe0f28e1 [Fabric] Update to 1.21.11-pre1 (atlas sprites broke, probably a client bug that will be fixed) 2025-11-20 18:28:50 +01:00
NEZNAMY fbc04b1183 [Commands] Finish custom toggle command registration on Bukkit and remove old command preprocess code (#1578) 2025-11-16 10:58:23 +01:00
NEZNAMY bdd2a139e1 Remove sponge support and bump version to 5.4.0-SNAPSHOT 2025-11-15 18:14:29 +01:00
NEZNAMY e956e59888 [Commands] Turn custom toggle commands into real registered commands for most platforms (bukkit and sponge are left) (#1578) 2025-11-15 17:35:21 +01:00
NEZNAMY 1debc54db6 Update loom to 1.13-SNAPSHOT 2025-11-15 12:36:34 +01:00
NEZNAMY 37786935c3 [NameTags] Fix random error 2025-11-15 10:38:52 +01:00
NEZNAMY 425748af12 [Placeholders] Change int to long to fix overflow (#1576) 2025-11-11 20:19:55 +01:00
NEZNAMY c0deaa40ed [Components] Fix last component style detection, causing team color to not be decided correctly sometimes (again) (#1575) 2025-11-10 17:35:10 +01:00
NEZNAMY 70be098f8a [Components] Fix last component style detection, causing team color to not be decided correctly sometimes 2025-11-06 19:23:01 +01:00
NEZNAMY 838ef437d8 [Wiki] Monthly wiki backup for November 2025 2025-11-02 09:05:52 +01:00
NEZNAMY 44d7473c71 [Placeholders] Change player count related placeholders to check for proxy players and remove overriding attempt (which did not even work with %online_<server>% placeholders 2025-10-31 18:57:56 +01:00
NEZNAMY b8a7dfe543 [Placeholders] Change internal error value to avoid issues when a placeholder actually returned that value 2025-10-31 18:55:21 +01:00
NEZNAMY 4c4bf79371 Merge pull request #1563 from JT122406/master
Gradle 9
2025-10-19 13:54:37 +02:00
NEZNAMY a4b4bd0146 [Velocity] Make bossbar bug compensation dynamic, as it was fixed in build 546 2025-10-19 12:56:51 +02:00
Joseph T. McQuigg 9553e310e4 Disable ShadowJar tasks on Modded platforms 2025-10-18 16:40:44 -04:00
Joseph T. McQuigg e00caddb1e Gradle 9 2025-10-18 11:08:41 -04:00
NEZNAMY 898887225d [Commands] Add offline UUID of player to debug command 2025-10-18 12:28:02 +02:00
NEZNAMY 8eef805418 [Configuration] Avoid console warning during header/footer config conversion 2025-10-13 19:16:39 +02:00
NEZNAMY 8509718d32 [Header/Footer] Remove anti-override logging due to false positives when pipeline lags and fast animations are used 2025-10-11 20:46:40 +02:00
NEZNAMY f2cb7c564f [Adventure hook] Fix object component conversion missing "return" statement 2025-10-10 17:10:29 +02:00
NEZNAMY 9335e5af65 [Velocity] Disable header/footer anti-override, because it does not work properly due to velocity internal logic 2025-10-10 17:01:15 +02:00
NEZNAMY 5a5eadac1f [Bukkit] Use correct method to get gamemode by id to fix error <1.17 and generally avoid risks on all versions 2025-10-09 20:16:37 +02:00
NEZNAMY bcd015b6eb [Header/Footer] Add anti-override to the feature 2025-10-09 20:02:45 +02:00
NEZNAMY 91c6b8f08e 5.3.3-SNAPSHOT 2025-10-09 19:29:26 +02:00
NEZNAMY c7251295a1 [Description] Update badges 2025-10-08 18:47:28 +02:00
NEZNAMY db2110b11e 5.3.2 2025-10-08 18:33:02 +02:00
NEZNAMY be1122ce50 Update to 1.21.10 2025-10-08 17:08:59 +02:00
NEZNAMY cf265987db [Bukkit] Remove override for %player_ping%, since people have probably updated their expansion by now. 2025-10-07 17:54:05 +02:00
NEZNAMY cd82e75514 [Teams] Improve anti-override message to contain source of blocked team and how to fix it. 2025-10-07 17:13:38 +02:00
NEZNAMY 74d36f1ab5 [MySQL] Fix error on upload command and message saying success despite operation not being successful 2025-10-06 20:38:05 +02:00
NEZNAMY 67da0ff32b [GitHub] Add an item to CONTRIBUTING.md 2025-10-06 18:42:03 +02:00
NEZNAMY aabad04e28 [MySQL] Delete data in database on upload first, instead of just overwriting / adding new content 2025-10-05 15:05:20 +02:00
NEZNAMY 9236da40dd [Spectator fix] Rewrite packets to avoid the same packet identity from being sent to all players, causing wrong result from modifying it for another player 2025-10-05 14:51:29 +02:00
NEZNAMY 88ff78b7e3 [Commands] Fix debug command not displaying server name correctly 2025-10-05 11:44:25 +02:00
NEZNAMY 21ebd68607 [API] Restore TabPlayer#getWorld and TabPlayer#getServer 2025-10-05 11:39:31 +02:00
NEZNAMY 9adad40aa9 [Pipeline injection] Change return type of onPacketSend to Object to allow changing the packet 2025-10-05 11:17:46 +02:00
NEZNAMY f63b3de63a [Bukkit] Add Header/Footer sending on 1.7.10 if the method is available (modded server) (#1557) 2025-10-04 19:03:21 +02:00
NEZNAMY 767933e522 [Bukkit] Add craftbukkit package version into debug command output 2025-10-04 18:49:20 +02:00
NEZNAMY 0fb86ddf6c 5.3.2-SNAPSHOT 2025-10-04 17:36:02 +02:00
NEZNAMY d52969597f [Description] Update badges 2025-10-04 17:31:03 +02:00
NEZNAMY 70e1537bc0 5.3.1 2025-10-04 16:49:23 +02:00
NEZNAMY 605a09b290 [Bukkit] Fix error on 1.8 - 1.19.2 2025-10-04 16:11:51 +02:00
NEZNAMY 8e2f8d67f3 Use a separate field for player's version network id for better results on unknown versions 2025-10-04 13:31:58 +02:00
NEZNAMY d00764e548 [Commands] Add more info to debug command 2025-10-04 13:21:46 +02:00
NEZNAMY 953472a41a [Velocity] Add flag for compensating for a bossbar bug that might be fixed soon (and was fixed in a fork) 2025-10-04 11:43:26 +02:00
NEZNAMY 6be5bb4757 [Conditions] Fix anonymous conditions not refreshing 2025-10-03 20:17:50 +02:00
NEZNAMY b48a9e4f22 [Layout] Add support for per-layout default-skin (#1555) 2025-10-03 20:06:26 +02:00
NEZNAMY 6d42e252a1 [Teams] Remove old forgotten code causing nametag visibility to not refresh on proxies (also refresh it properly on join) 2025-10-03 16:22:51 +02:00
NEZNAMY ef98b15c86 5.3.1-SNAPSHOT 2025-10-02 19:59:52 +02:00
NEZNAMY 6945e8ee81 [Description] Update badges 2025-10-02 18:57:13 +02:00
NEZNAMY 9c9edbff75 5.3.0 2025-10-02 18:41:25 +02:00
NEZNAMY b8e3a07980 [Configuration] Change warning message in config conversion 2025-10-02 18:40:05 +02:00
NEZNAMY 06279e3708 [Forge] Update to 1.21.9 2025-10-02 18:39:00 +02:00
NEZNAMY 9812345f71 [MiniMessage support] Add component conversion for object components 2025-10-01 12:45:10 +02:00
NEZNAMY e1f667079a [MiniMessage support] Fix error when object components were used 2025-10-01 11:40:53 +02:00
NEZNAMY 6edc3babc8 Update Bukkit, Paper, BungeeCord, Fabric and NeoForge to 1.21.9 2025-10-01 11:03:15 +02:00
NEZNAMY 309c67969a [Wiki] Monthly wiki backup for October 2025 2025-10-01 09:05:32 +02:00
NEZNAMY bd681229db [Conditions] Recode conditions, add new types and add disable-condition conversion for header/footer 2025-10-01 08:54:41 +02:00
NEZNAMY 4f0a4feb03 [Components] Micro optimization 2025-09-28 19:31:08 +02:00
NEZNAMY 2d84a60c84 [NameTags] Rename caches 2025-09-28 19:29:22 +02:00
NEZNAMY 0f66bc7264 [NameTags] Split cache into prefix and suffix caches 2025-09-28 16:17:57 +02:00
NEZNAMY 9283f969c4 [Header/Footer] Fix display-condition updating and change way the feature is resent on server switch (to also prepare for a future improvement) 2025-09-28 11:05:17 +02:00
NEZNAMY dbcad7b11d [Multi-server support] Fix error on reload 2025-09-27 14:07:24 +02:00
NEZNAMY 8e96fc1595 [Multi-server support] Add debug message about current channel name 2025-09-27 11:37:15 +02:00
NEZNAMY fa46427b1f [Multi-server support] Change channel name to avoid errors when using mixed tab versions 2025-09-27 11:28:29 +02:00
NEZNAMY 5a112bff22 [Header/Footer] Correctly resend the feature on server switch 2025-09-26 20:14:42 +02:00
NEZNAMY 1a8bc5ee34 [Configuration] Change config conversion warning message 2025-09-25 19:05:04 +02:00
NEZNAMY 1001bcd507 [Error Logging] Fix warnings no longer having color 2025-09-25 18:48:47 +02:00
NEZNAMY 2f6f5f4958 [ProxySupport] Add compensation for packets being received in the wrong order 2025-09-25 18:42:37 +02:00
NEZNAMY 863cceb175 [Fabric] Update to 1.21.9-rc1 2025-09-25 18:24:25 +02:00
NEZNAMY d07d604f7c [Configuration] Fix per-server settings using * symbol not working anymore 2025-09-24 18:52:31 +02:00
NEZNAMY 9035f8b57f [Backend] Add %deaths% placeholder (default refresh 1000) 2025-09-23 16:33:57 +02:00
NEZNAMY 43bc22b8be [Fabric] Update to 1.21.9-pre3 2025-09-22 18:02:29 +02:00
NEZNAMY 1d59eb5787 Merge pull request #1550 from GG-MD/master
Packet Handling Safety Enhancement - Null Packet Protection
2025-09-21 18:28:44 +02:00
MGG 5383b87c3f Packet Handling Safety Enhancement - Null Packet Protection 2025-09-21 19:00:47 +03:00
NEZNAMY 5c3815aee0 [BungeeCord / Velocity] Add try/catch to RedisBungee hook 2025-09-21 09:09:27 +02:00
NEZNAMY 69b9acdc83 [Scoreboard] Do not actually unregister scoreboard if another plugin sends its own, just stop slotting it 2025-09-21 09:04:57 +02:00
NEZNAMY 3b68fe9bdd [Layout] Adapt to mineskin no longer supporting skins by id 2025-09-20 18:46:02 +02:00
NEZNAMY 4d9dd1cf83 [GitHub] Add new issue template 2025-09-20 13:48:22 +02:00
NEZNAMY 0854fd674f [Fabric] Update to 1.21.9-pre2 2025-09-20 13:26:36 +02:00
NEZNAMY 75478b59ae [Bukkit] Take advantage of new Java features and remove unnecessary reflection 2025-09-20 13:11:58 +02:00
NEZNAMY d39f6fd061 [Bukkit] [Code style] Use TYPE instead of Object for components 2025-09-17 20:30:34 +02:00
NEZNAMY a532cd4fc1 [Code style] Rename some component classes to avoid conflict with platform classes 2025-09-17 18:39:28 +02:00
NEZNAMY a6afd9de0a [Fabric] Update to 1.21.9-pre1 (thanks Mojang) 2025-09-16 19:43:59 +02:00
NEZNAMY 9a8df8c890 [Configuration] Add missing config conversion of "*" symbol in header/footer 2025-09-15 19:24:32 +02:00
NEZNAMY cd435cc716 [Code style] Remove pointless world/server instance creations 2025-09-15 19:10:56 +02:00
NEZNAMY b0bdc36b59 [Tablist formatting] [Performance] Only try to format players on the same server (or global playerlist group) 2025-09-15 18:58:53 +02:00
NEZNAMY 1971513acc Fix issue from previous commit 2025-09-15 18:56:09 +02:00
NEZNAMY 99646f2113 [Global playerlist] Refactor server groups for future use in other features 2025-09-15 18:07:14 +02:00
NEZNAMY 78349176d6 [Global playerlist] Optimize shouldSee method to reduce canSee calls to other plugins 2025-09-15 13:28:40 +02:00
NEZNAMY 92115ed493 [Global playerlist] Store "spy-server" attribute in Server class instead of player data 2025-09-15 13:04:11 +02:00
NEZNAMY 4ef8508c65 [Code style] Extract project variables from TabConstants class and move it back to source folder 2025-09-15 12:37:25 +02:00
NEZNAMY 1feafa884e [Code style] Create a class for holding servers and worlds and clear it on reload 2025-09-15 12:22:44 +02:00
NEZNAMY 02bff23b1f [Code style] Separate nested class into a regular class 2025-09-15 11:37:16 +02:00
NEZNAMY d80742bf20 [Code style] Separate nested class into a regular class 2025-09-15 11:28:57 +02:00
NEZNAMY 7bde3d9996 [Code style] Separate nested class into a regular class 2025-09-15 11:19:55 +02:00
NEZNAMY 4d86beb268 [Code style] Separate nested class into a regular class 2025-09-15 11:10:16 +02:00
NEZNAMY b039cbb7b6 [Code style] Separate nested class into a regular class 2025-09-15 11:00:29 +02:00
NEZNAMY 7d8af7efc9 [Code style] Separate nested class into a regular class 2025-09-15 10:51:48 +02:00
NEZNAMY 7019044837 [Nametags] Upgrade invisible-nametags option to support conditions 2025-09-14 18:09:17 +02:00
NEZNAMY 5916ec5d07 [Javadoc] Fix typo 2025-09-14 11:50:51 +02:00
NEZNAMY 4508fcf4b3 [Javadoc] Add some missing docs 2025-09-14 11:01:44 +02:00
NEZNAMY 2de69557d2 [Code style] Remove whitespace 2025-09-14 10:51:37 +02:00
NEZNAMY b01e793a26 [Javadoc] Add some missing docs 2025-09-14 10:49:40 +02:00
NEZNAMY 1f67ab7bdb [Code style] Rename variable to avoid shadowing outer scope variable 2025-09-14 10:45:39 +02:00
NEZNAMY 43ae5add60 [Code style] Remove redundant suppression 2025-09-14 10:43:14 +02:00
NEZNAMY 971620818b [Placeholders] No longer show last value of a placeholder when identifier was returned, it caused more harm than good (most notably on proxy installation when not all PAPI expansions are downloaded and therefore placeholders "freezing") 2025-09-13 18:53:55 +02:00
NEZNAMY c997b99935 [Bukkit] Add missing shadowColor implementation on spigot 2025-09-13 18:27:41 +02:00
NEZNAMY ae83ce1f42 [Code style] Remove unnecessary check 2025-09-13 17:38:28 +02:00
NEZNAMY 2410717510 [Code style] Remove no longer needed variable 2025-09-13 17:06:59 +02:00
NEZNAMY 5270a156b3 [Code style] Remove unused classes 2025-09-13 17:03:00 +02:00
NEZNAMY 07d807a7bd [Header/Footer] Rework the feature to allow conditional designs 2025-09-13 15:56:14 +02:00
NEZNAMY 5fb80f5661 5.3.0-SNAPSHOT 2025-09-13 15:47:23 +02:00
NEZNAMY ce6bef7f19 [Fabric] Update to 25w37a 2025-09-10 19:04:56 +02:00
NEZNAMY facedfdea7 [Components] Add config option to disable MiniMessage support (also introduce new config converter) 2025-09-07 12:44:14 +02:00
NEZNAMY e8fa66dac0 [Configuration] Removed forced lowercasing of server names 2025-09-06 19:08:54 +02:00
NEZNAMY 997d824d12 [Code style] Remove redundant call 2025-09-06 14:25:28 +02:00
NEZNAMY 86baf27ca0 [Nametags] Fix empty line being sent to player when toggle message is empty 2025-09-06 14:21:54 +02:00
NEZNAMY 2b8b5303c8 [Components] Properly set team color to used magic codes if both color and magic codes are used 2025-09-06 11:10:09 +02:00
NEZNAMY 24bd58130b [Components] Fix team color affecting prefix/suffix 2025-09-06 09:53:51 +02:00
NEZNAMY 907bbdb52b [Fabric] Update to 25w36b 2025-09-03 15:58:20 +02:00
NEZNAMY 26c491ce22 [Nick compatibility] Add debug message when an API request is made to change expected profile name 2025-09-01 17:26:43 +02:00
NEZNAMY 73def64743 [Wiki] Monthly wiki backup for September 2025 2025-09-01 17:14:40 +02:00
NEZNAMY d021d213f6 [Components] Extend player sprite object component to support player names the intended way and add UUID support 2025-08-30 19:29:44 +02:00
NEZNAMY dfd5ccf525 [Placeholders] Add %uuid% placeholder showing player's UUID 2025-08-30 18:48:07 +02:00
NEZNAMY a4cfe9f81b [Configuration] Replace \n with newline sooner, resulting in them being replaced even inside placeholders like animations 2025-08-30 15:52:56 +02:00
NEZNAMY 8402088cba [MiniMessage hook] Properly handle uppercased color codes and do not throw an error if text contains the § symbol 2025-08-27 20:50:25 +02:00
NEZNAMY 2adcc0d45b [Components] Allow player heads using <head:DEFINITION> using same definition syntax as layout 2025-08-27 19:52:58 +02:00
NEZNAMY da25752b73 [Configuration] Always load skin cache 2025-08-27 19:36:30 +02:00
NEZNAMY ac348cf207 [Components] Add a comment 2025-08-27 18:44:41 +02:00
NEZNAMY 6afe8f0081 [Components] Add PlayerSprite support 2025-08-27 18:24:41 +02:00
NEZNAMY 86c294592f Delete component module and move content to shared 2025-08-27 17:38:45 +02:00
NEZNAMY 3deba4a0f3 [Fabric] Fix error on 25w35a 2025-08-27 16:55:09 +02:00
NEZNAMY cfb3d10a7d [Bukkit] Remove unused dependency 2025-08-26 20:16:29 +02:00
NEZNAMY 458fa4e416 Update Fabric to 25w35a and prepare for new object components 2025-08-26 20:08:24 +02:00
NEZNAMY 6e7d2338a4 [Tablist] Remove unused class 2025-08-24 16:23:17 +02:00
NEZNAMY d0bd1b4b0b [Tablist] Fix possible issue from previous commit not applying forced display name 2025-08-24 12:35:28 +02:00
NEZNAMY 2076b589b4 [Tablist] Avoid sending tablist update packets of entries which are not present (currently the new check only works on BungeeCord, Velocity already worked) 2025-08-24 11:47:59 +02:00
NEZNAMY a4b8c2b730 [Components] Change sprite syntax to <sprite:ATLAS:SPRITE> to match MiniMessage 2025-08-24 09:43:29 +02:00
NEZNAMY 0cc83325bc [Components] Replace spaces with underscores in atlas and sprite 2025-08-23 19:10:31 +02:00
NEZNAMY f2fa63315e [Components] Remove toRawText method and replace its usage with the intended method 2025-08-23 18:58:43 +02:00
NEZNAMY 9631abf430 [Components] Force lowercase atlas and sprite 2025-08-23 18:35:51 +02:00
NEZNAMY 084123132a [Bukkit] Remove fallback using Bukkit API on unsupported versions (this also drops 1.5 - 1.6 support) 2025-08-23 18:18:55 +02:00
NEZNAMY 4e9d2df0b2 [Bukkit] Fix 1.9.4 and 1.10.x 2025-08-23 17:45:35 +02:00
NEZNAMY e3a3a65987 Revert unintended change 2025-08-23 16:39:03 +02:00
NEZNAMY 17feac0501 [Ping Spoof] Rework the feature for a faster check 2025-08-23 16:37:58 +02:00
NEZNAMY 84e280a562 [Bukkit] Include 1.7 in supported versions list 2025-08-23 10:40:02 +02:00
NEZNAMY 906e304018 [Bukkit] Add NMS Implementations for 1.7.x 2025-08-23 10:39:35 +02:00
NEZNAMY 48cdeb7283 [Bukkit] Add NMS Implementations for 1.8.x and 1.9.x 2025-08-23 09:43:24 +02:00
NEZNAMY 4efb55f685 [Code style] Add NMS Implementations for 1.10.x and 1.11.x 2025-08-21 18:08:32 +02:00
NEZNAMY 3ed6f8158d [Code style] Remove unused methods 2025-08-21 17:39:11 +02:00
NEZNAMY c89a38b0da [Bukkit] Add NMS Implementations for 1.13.x and 1.14.x 2025-08-20 18:55:14 +02:00
NEZNAMY eb40cf873f [Bukkit] Check for ObjectComponent in another method 2025-08-20 16:53:37 +02:00
NEZNAMY 892c626312 [Components] Add atlas-sprite support to text parsing 2025-08-20 16:28:47 +02:00
NEZNAMY 7e0d447e75 [Fabric] Update to 25w34b 2025-08-20 15:56:21 +02:00
NEZNAMY 49b2723c19 [Components] Introducing ObjectComponent for future 1.21.9 content 2025-08-20 14:54:55 +02:00
NEZNAMY 5140d912e1 [Bukkit] Add NMS Implementation for 1.15.x 2025-08-20 13:51:03 +02:00
NEZNAMY 0fa1165652 [Bukkit] Add NMS Implementation for 1.16 - 1.16.3 2025-08-20 13:42:57 +02:00
NEZNAMY 375d2297e7 [Bukkit] Remove unused code 2025-08-20 13:23:50 +02:00
NEZNAMY fbd089d87a [Bukkit] Add NMS Implementation for 1.18 - 1.18.1 2025-08-20 13:16:23 +02:00
NEZNAMY 5076c80e2c [Bukkit] Remove reflection entirely now that adapters cover everything reflection did 2025-08-20 13:13:50 +02:00
NEZNAMY 4fcbec7a4a [Spectator fix] Fix memory leak (introduced in fix for #1537) 2025-08-20 12:32:36 +02:00
NEZNAMY cb82d3ad13 [Bukkit] Add NMS Implementation for 1.21.6 - 1.21.8 2025-08-20 12:14:24 +02:00
NEZNAMY a6172c705d [Bukkit] Add NMS Implementation for 1.21.5 2025-08-20 11:44:54 +02:00
NEZNAMY 3c2c480c11 [Bukkit] Add NMS Implementation for 1.21.4 2025-08-20 11:23:00 +02:00
NEZNAMY da1a839014 [Bukkit] Add NMS Implementation for 1.21.2 - 1.21.3 2025-08-20 11:04:24 +02:00
NEZNAMY bf6628c6a2 [Bukkit] Add NMS Implementation for 1.21 - 1.21.1 2025-08-20 10:43:59 +02:00
NEZNAMY 42674bbfdd [Bukkit] Clean up implementation detection 2025-08-20 10:20:48 +02:00
NEZNAMY 225164b7b6 [Bukkit] Add NMS Implementation for 1.20.5 - 1.20.6 2025-08-20 10:16:32 +02:00
NEZNAMY 35ce37acf8 [Bukkit] Add NMS Implementation for 1.20.3 - 1.20.4 2025-08-20 09:48:42 +02:00
NEZNAMY 2df5b00e07 [Bukkit] Add NMS Implementation for 1.20.2 2025-08-20 09:35:40 +02:00
NEZNAMY 3fa25c0662 [Bukkit] Add NMS Implementation for 1.20 - 1.20.1 2025-08-20 09:00:06 +02:00
NEZNAMY b7e233834e [Bukkit] Add NMS Implementation for 1.19.4 2025-08-19 20:35:52 +02:00
NEZNAMY ff80a4807f [Bukkit] Add NMS Implementation for 1.19.3 2025-08-19 20:16:28 +02:00
NEZNAMY c56592c19a [Bukkit] Add constants for enums for better readability 2025-08-19 19:42:55 +02:00
NEZNAMY e93df8e38d [Fabric] Add Fabric API version for 25w33a 2025-08-19 18:57:50 +02:00
NEZNAMY 15664bc9fb Update loom to 1.11 2025-08-19 18:57:24 +02:00
NEZNAMY 9cedbabd75 [Nametags] Fix memory leak 2025-08-19 17:58:33 +02:00
NEZNAMY a98ecee8f3 [Spectator Fix] Force gamemode always, even if not currently in spectator (#1537) 2025-08-19 17:19:52 +02:00
NEZNAMY f64d0d7b41 Merge pull request #1539 from tooobiiii/master
Fix: Compilation errors showing generated src instead of actual src -> introducing blossom 2.1.0
2025-08-19 16:50:30 +02:00
TobisuchtetXD 7a1f1ed484 introducing new blossom version 2.1.0 fixes weird compilation behaviour 2025-08-19 12:32:43 +02:00
NEZNAMY 85ade0dd15 [Spectator Fix] Use packet / periodic detection to make the feature more reliable instead of delays (#1537) 2025-08-18 18:06:05 +02:00
NEZNAMY 9c70f5a187 [Code style] Rename "expectedDisplayName" to "forcedDisplayName" 2025-08-17 18:23:11 +02:00
NEZNAMY f622d0c8b3 [Scoreboard / Bossbar] Fix announce command syntax in docs 2025-08-07 17:09:29 +02:00
NEZNAMY a3c4362a90 [MiniMessage Support] Reset magic codes before every color code to match vanilla behavior 2025-08-03 19:20:54 +02:00
NEZNAMY 05609ca436 [Code style] Remove case insensitivity from spy-servers option for safety due to rewrite 2025-08-03 17:10:05 +02:00
NEZNAMY fde7fefe9f [Performance] Use Server object for storing player servers instead of Strings 2025-08-03 15:23:37 +02:00
NEZNAMY 19f45aeb4d [Code style] Use World object for storing player worlds instead of Strings 2025-08-03 14:43:34 +02:00
NEZNAMY 540eafc41b [Wiki] Monthly wiki backup for August 2025 2025-08-02 13:35:43 +02:00
NEZNAMY 1ba62e0ae9 [Descriptions] Update badges 2025-07-24 17:20:37 +02:00
NEZNAMY 07b213d0af [Playerlist Objective] [Configuration] Fix warning when setting value to 0 (without quotes, resulting in it being an Integer) 2025-07-24 17:18:34 +02:00
NEZNAMY 0528baaa64 [Belowname] [Configuration] Fix warning when setting value to 0 (without quotes, resulting in it being an Integer) 2025-07-22 18:42:29 +02:00
NEZNAMY 264b8e69d8 [Configuration] Add missing config conversion to add register-tab-expansion option (#1524) 2025-07-22 17:31:23 +02:00
NEZNAMY b4c6da418d [Configuration] Fix misinformation and missing link in default config.yml 2025-07-20 15:09:00 +02:00
NEZNAMY 3811f942a1 5.2.6-SNAPSHOT 2025-07-20 15:05:17 +02:00
NEZNAMY 6d295960d5 5.2.5 2025-07-19 17:53:04 +02:00
NEZNAMY 983d6a055b [Sponge] Fix 1.21.5+ error caused by a Sponge bug 2025-07-19 11:48:43 +02:00
NEZNAMY 9de3fc4bbb Update to 1.21.8 2025-07-19 11:31:29 +02:00
NEZNAMY f4c986f0de [Sponge] Set listed tablist entry value 2025-07-19 11:21:27 +02:00
NEZNAMY 434f629c0b [BungeeCord] Update to build 1990 and up 2025-07-15 19:10:35 +02:00
NEZNAMY dac32b6daf [bStats] Fix "1.99.x" version being sent for unknown server versions 2025-07-06 19:44:59 +02:00
NEZNAMY dd845013ce [Layout] [Performance] replace removeAll with removeIf for massively improved performance 2025-07-03 18:02:18 +02:00
NEZNAMY b9bad50dbd 5.2.5-SNAPSHOT 2025-07-03 18:00:59 +02:00
NEZNAMY 56540df419 [Wiki] Monthly wiki backup for July 2025 2025-07-02 17:44:18 +02:00
NEZNAMY d0b0c55ab8 [Description] Update badges 2025-07-01 20:49:11 +02:00
NEZNAMY 6f2b92e044 5.2.4 2025-07-01 20:38:47 +02:00
NEZNAMY 5da16e8055 Update to 1.21.7 2025-07-01 20:33:36 +02:00
NEZNAMY a522ea9902 [Proxy Support] Add try/catch for message decoding 2025-07-01 20:32:55 +02:00
NEZNAMY 36801184a5 5.2.4-SNAPSHOT 2025-06-30 16:39:37 +02:00
NEZNAMY d212eb108d [Bukkit] Remove unused empty lists from plugin.yml to avoid Polymart bug breaking them 2025-06-26 18:32:51 +02:00
NEZNAMY cbc1de0f33 [Description] Update badges 2025-06-23 18:49:25 +02:00
NEZNAMY fcdc04e228 5.2.3 2025-06-23 18:36:49 +02:00
NEZNAMY 890f1ee131 [Velocity] Improve message telling users to install VelocityScoreboardAPI 2025-06-23 18:36:37 +02:00
NEZNAMY f3aec47ac3 [BungeeCord] Send header/footer using API since it no longer throws an error 2025-06-22 10:48:31 +02:00
NEZNAMY bcf1c828b5 [BungeeCord] Update to build 1980 (older versions are no longer supported) 2025-06-22 10:40:34 +02:00
NEZNAMY 5fd319a152 [BossBar] Fix %tab_bossbar_visible% not loading on join when player has bossbar disabled and toggling is saved 2025-06-22 10:04:38 +02:00
NEZNAMY abecb58a8d [API] Add methods for removing bossbars and scoreboards (#1507) 2025-06-21 20:35:22 +02:00
NEZNAMY 135166b01e [Bukkit] Remove ViaVersion hook for sending packets due to many unfixable problems 2025-06-21 18:13:46 +02:00
NEZNAMY 0770293452 [Placeholders] Fix placeholder updating when placeholder returned its identifier not being skipped properly (#1502) 2025-06-21 13:57:16 +02:00
NEZNAMY f3c40ad582 [Bukkit] Disable ViaVersion hook for sending raw packets to newer players due to issues 2025-06-21 13:09:44 +02:00
NEZNAMY aacc115a36 [API] Add functions for getting original prefix/suffix values with placeholders parsed 2025-06-21 12:51:03 +02:00
NEZNAMY b7ba07b78d [Bukkit] Remove redundant SneakyThrows annotations 2025-06-21 10:45:27 +02:00
NEZNAMY e13445f55d [Bukkit] Fix skin writing in ViaVersion hook 2025-06-21 10:41:11 +02:00
NEZNAMY bd527d3868 [Configuration] Fix false positive in configuration checking (#1506) 2025-06-20 18:34:24 +02:00
NEZNAMY f288112eb2 [Bukkit] Fix error in ViaVersion hook 2025-06-20 16:18:03 +02:00
NEZNAMY 6b415e64a8 5.2.3-SNAPSHOT 2025-06-19 17:29:10 +02:00
NEZNAMY cfb2cb6b0a [Description] Update badges 2025-06-18 19:20:23 +02:00
NEZNAMY 622deb6fd7 5.2.2 2025-06-18 18:48:14 +02:00
NEZNAMY 7f41421d65 [Bukkit] Add 1.21.6 to supported versions 2025-06-18 17:34:51 +02:00
NEZNAMY 73e706465a Add 1.21.6 protocol constant 2025-06-18 17:31:54 +02:00
NEZNAMY a8c543ca9e [Paper] Update paperweight to 2.0.0-beta.17 2025-06-18 17:23:38 +02:00
NEZNAMY 9594ff452b Update Gradle to 8.14.2 2025-06-18 17:18:09 +02:00
NEZNAMY d5c81298dd [Modded platforms] Update to 1.21.6 2025-06-18 16:50:36 +02:00
NEZNAMY 88faacb240 [Proxy support] Properly handle out of order redis messages (#1465) 2025-06-17 21:00:49 +02:00
NEZNAMY 0d2a04b3a5 [Proxy support] Make method synchronized to try to avoid concurrent access 2025-06-17 18:06:38 +02:00
NEZNAMY f8a90b28b5 [Code style] Create static methods for initializing components 2025-06-16 19:57:58 +02:00
NEZNAMY a948febb18 [Belowname & Playerlist objective] Suggest a PlaceholderAPI expansion might be missing when a placeholder did not parse 2025-06-16 18:44:58 +02:00
NEZNAMY 8e33481b97 [Proxy support] Massive fixes to handling players who switch servers and temporarily cause the player to be loaded twice (#1465) 2025-06-15 19:03:50 +02:00
NEZNAMY f54be214f9 [Vanish compatibility] Assume a player can always see themselves 2025-06-15 15:03:14 +02:00
NEZNAMY d50b47acb5 [Configuration] Remove case sensitivity when checking for valid properties / configuration option names 2025-06-14 19:35:55 +02:00
NEZNAMY 31011c243a [Fabric] Update to 1.21.6-rc1 2025-06-12 18:52:20 +02:00
NEZNAMY f4aa03f20d [Conditions] Fix issue from recent commits 2025-06-12 18:51:56 +02:00
NEZNAMY 28aacaea45 [Fabric] Update to 1.21.6-pre4 2025-06-10 19:52:30 +02:00
NEZNAMY d4fd9a2b78 [Sorting] Fix PLACEHOLDER type not loading properly when ":" symbol is used in values (#1504) 2025-06-09 18:41:06 +02:00
NEZNAMY 663e0be357 [Tablist] Do not send update packets of vanished players, exposing them to players 2025-06-07 18:43:17 +02:00
NEZNAMY 14d29577c5 [Conditions] Fix condition compiling when delimiter is a part of used placeholder (#1503) 2025-06-07 15:22:48 +02:00
NEZNAMY 951f8072c1 [Placeholders] Add %luckperms-prefixes% and %luckperms-suffixes% placeholders listing all values instead of just the ones with the highest weight 2025-06-07 14:54:13 +02:00
NEZNAMY 05f042eda0 [Conditions] Improve condition type detection (#1503) 2025-06-07 11:37:32 +02:00
NEZNAMY b00c2fbcb4 [Fabric] Update to 1.21.6-pre3 2025-06-07 10:29:37 +02:00
NEZNAMY dde4866e50 [Belowname] Improve warning message 2025-06-05 19:17:42 +02:00
NEZNAMY 9fa6b21c08 [Code style] Extract code into a method 2025-06-03 19:51:04 +02:00
NEZNAMY e95e6fc20c Remove anti-override from config and make it permanently enabled 2025-06-03 17:14:18 +02:00
NEZNAMY c7a3b00c3c Merge pull request #1499 from R00tB33rMan/master
Remove printline when testing TPS & MSPT getter
2025-06-03 07:11:07 +02:00
R00tB33rMan 74bc0e0cb7 Remove printline when testing TPS & MSPT getter 2025-06-02 23:30:02 -04:00
NEZNAMY 6248008b4d [Fabric] Update to 1.21.6-pre2 2025-06-02 18:32:42 +02:00
NEZNAMY 2d91e165ce [Wiki] Monthly wiki backup for June 2025 2025-06-01 18:00:37 +02:00
NEZNAMY b1220550eb [Multi-server support] Code improvements for future issue debugging 2025-06-01 16:52:12 +02:00
NEZNAMY 680ff3412f [Bukkit] Fix wrong supported version range of a module 2025-06-01 16:09:45 +02:00
NEZNAMY 799f6b8215 [Folia] Implement %tps% and %mspt% (#1498) 2025-05-31 16:52:18 +02:00
NEZNAMY 1be224b7de [Fabric] Update to 1.21.6-pre1 2025-05-29 17:56:03 +02:00
NEZNAMY a32adfbfc7 [Bukkit] Add implementations for all paper versions with mojang mappings 2025-05-27 19:48:01 +02:00
NEZNAMY dda415351a Revert "[Fabric] Downgrade to 1.21.5 for release"
This reverts commit 6873c59505.
2025-05-23 17:08:57 +02:00
NEZNAMY 685e4b9faa 5.2.2-SNAPSHOT 2025-05-23 17:08:48 +02:00
NEZNAMY 1f842563b3 [Bukkit] Hotfix error 2025-05-22 21:45:09 +02:00
NEZNAMY f237b61065 [Description] Update badge to 5.2.1 2025-05-22 17:56:44 +02:00
NEZNAMY 19d6d06791 5.2.1 2025-05-22 17:38:48 +02:00
NEZNAMY 6873c59505 [Fabric] Downgrade to 1.21.5 for release 2025-05-22 17:35:43 +02:00
NEZNAMY e7ae62db7b [Playerlist objective] Change default title 2025-05-21 15:51:52 +02:00
NEZNAMY d4362f2ed2 [Bukkit] Only get methods declared by the class, not superclasses (#1492) 2025-05-20 17:21:49 +02:00
NEZNAMY 9247f3d4fb [Fabric] Update to 25w21a 2025-05-20 16:37:09 +02:00
NEZNAMY b4993b657e [Paper] Downgrade to 1.21.4 to fix compilation (code is the same) 2025-05-20 16:32:40 +02:00
NEZNAMY b73aa93d01 [Commands] Ignore cancelled command events 2025-05-20 16:28:50 +02:00
NEZNAMY bce689e672 [Modded platforms] Use reflection instead of access transforming which may fail 2025-05-15 20:10:32 +02:00
NEZNAMY f4468261cf [Fabric] Update to 25w20a 2025-05-13 16:50:24 +02:00
NEZNAMY cc926ff974 [Modded platforms] Decrease required Java version to 17 (where possible) 2025-05-07 17:39:33 +02:00
NEZNAMY 6c3831ded4 [Fabric] Update to 25w19a 2025-05-07 17:30:29 +02:00
NEZNAMY 3c55866d46 [Code style] Move 1.8+ check to avoid duplicating it everywhere 2025-05-01 18:26:56 +02:00
NEZNAMY dfc9359f04 [Plugin messages] Do not write protocol version anymore, since it is not used by bridge anymore 2025-05-01 18:18:09 +02:00
NEZNAMY ea0897db31 [Bukkit] Remove redundant client version usage 2025-05-01 18:12:53 +02:00
NEZNAMY 25cf6c95e8 [Configuration] Print exception class when a file fails to save 2025-05-01 14:49:33 +02:00
NEZNAMY f5e2910e0b [Bukkit] Remove forgotten field from previous commit 2025-05-01 14:36:50 +02:00
NEZNAMY fda35986a4 [Bukkit] Use getters instead of reflection where possible and fix wrong field on 1.16.5 2025-05-01 14:35:59 +02:00
NEZNAMY b97e86c2ed [Wiki] Monthly wiki backup for May 2025 2025-05-01 13:43:03 +02:00
NEZNAMY ebb02717b5 [Scoreboard internals] Fix duplicated team / objective register actually overwriting existing value, causing NPE later (#1481) 2025-05-01 13:16:22 +02:00
NEZNAMY 1b82ebfd25 [Paper] Update version to fix compilation error 2025-05-01 13:10:59 +02:00
NEZNAMY 3fb788ef6d [Fabric] Update to 25w18a 2025-04-29 18:53:55 +02:00
NEZNAMY 11bc06182c [Scoreboard] Use available getter instead of reflection / access transforming (which may not work) 2025-04-27 13:57:22 +02:00
NEZNAMY 2fe5dc833d [Proxy support] Add more debug messages (#1465) 2025-04-27 10:02:56 +02:00
NEZNAMY 317cb975ce [Threading] Avoid throwing error 2025-04-27 09:31:21 +02:00
NEZNAMY 9bb2a97e50 [Threading] Increase thread shutdown timeout from 500ms to 2000ms 2025-04-27 09:28:36 +02:00
NEZNAMY 53dcc60587 [Code style] Use java 21 switches in modded platforms 2025-04-26 17:51:57 +02:00
NEZNAMY db347bc192 [Modded platforms] Create component style with setters to avoid using access transforming 2025-04-26 13:13:38 +02:00
NEZNAMY 608b8307dd [Velocity] Fix error in compatibility check 2025-04-26 12:56:58 +02:00
NEZNAMY 4c027da093 [Modded platforms] Use reflection to access tablist entries field instead of direct access (since access transforming sometimes doesn't work) 2025-04-26 12:52:10 +02:00
NEZNAMY bef60e688c [Bukkit] Fix prefix used in suffix field 2025-04-24 16:56:34 +02:00
NEZNAMY b987ad99f4 [Fabric] Update to 25w17a 2025-04-22 20:56:17 +02:00
NEZNAMY 3036e2d523 [Bukkit] Fix anti-override not working when using a ViaVersion implementation instead of server (#1478) 2025-04-19 11:33:34 +02:00
NEZNAMY 1bab2d0025 [Fabric] Update to 25w16a 2025-04-15 16:56:27 +02:00
NEZNAMY 4cac6c659e [Bukkit] Add v1_19_R1 submodule and remove reflection support for <1.19.3 2025-04-13 20:08:45 +02:00
NEZNAMY c7c59238e1 [Bukkit] Refactor feature implementation loading 2025-04-13 18:16:05 +02:00
NEZNAMY f51e74c066 [Bukkit] Update supported version list 2025-04-13 11:37:08 +02:00
NEZNAMY 52f8801638 [Bukkit] Add 1.17.1 and 1.18.2 submodules and delete the respective NMS reflection 2025-04-13 11:20:18 +02:00
NEZNAMY 4e5c5a7073 [Bukkit] [Code style] Change bossbar presence check 2025-04-13 09:03:49 +02:00
NEZNAMY 436f3879c4 [Bukkit] Remove redundant check 2025-04-13 08:36:56 +02:00
NEZNAMY c1395e26d4 [Fabric] Update to 25w15a 2025-04-09 17:32:03 +02:00
NEZNAMY 3750d6ddb1 [Commands] Fix error when running a property command 2025-04-07 19:02:02 +02:00
NEZNAMY 45c3601b49 [Conditions] Add "!permission:<value>" condition type 2025-04-07 18:29:24 +02:00
NEZNAMY 957da1d040 [Code style] Convert some NotNull annotations to NonNull to throw errors sooner 2025-04-07 18:25:46 +02:00
NEZNAMY 43932eb6b3 [Compilation] More changes to make backporting of mod platforms easier 2025-04-06 19:07:54 +02:00
NEZNAMY 024ddeefb4 [Compilation] Create maps for mod platform versions for easier backporting 2025-04-06 12:30:37 +02:00
NEZNAMY 94190b5cd7 [Velocity] Use new setShowHat tablist feature (and bump minimum required build to 485) 2025-04-05 10:15:55 +02:00
NEZNAMY 5d72f90a0f [Code style] Remove redundant code 2025-04-04 17:36:37 +02:00
NEZNAMY 90c30023c2 [Code style] Simplify 2025-04-02 20:27:59 +02:00
NEZNAMY d39a89659b [Bukkit] Remove reflection NMS support for 1.16.x and use direct 1.16.5 NMS hook 2025-04-02 20:23:36 +02:00
NEZNAMY 79f4386b62 [Bukkit] Remove reflection NMS support for versions below 1.16 (1.8.8 and 1.12.2 are supported directly) 2025-04-02 18:47:09 +02:00
NEZNAMY 39c4d8ae96 [Bukkit] Only send compatibility error messages relevant to server version 2025-04-02 18:12:33 +02:00
NEZNAMY c8b2abbb3e Merge pull request #1470 from JT122406/master
add curseforge link
2025-04-02 18:10:57 +02:00
NEZNAMY 06b7bbd711 [Bukkit] Fix startup error on 1.7.10 2025-04-02 18:05:20 +02:00
NEZNAMY 11afd15610 [Placeholder output replacements] Remove color replacing in output (may not be wanted if used in tab expansion) 2025-04-02 18:04:30 +02:00
Joseph T. McQuigg 4951025e61 add curseforge link 2025-04-02 09:54:48 -04:00
NEZNAMY 2337a122da [Wiki] Monthly wiki backup for April 2025 2025-04-01 17:23:23 +02:00
NEZNAMY 072333bf48 [Description] Use .svg instead of .png 2025-04-01 16:01:38 +02:00
NEZNAMY 2bd8924df7 [Description] Save badges for easier modification in only one place (will be linked to in all descriptions) 2025-04-01 15:58:28 +02:00
NEZNAMY 23cdc3721d [Global playerlist] Fix offline players being added into tablist when disconnecting immediately after switching server 2025-03-31 20:17:35 +02:00
NEZNAMY 957e4ba0c0 5.2.1-SNAPSHOT 2025-03-31 20:16:28 +02:00
NEZNAMY 71a19c63d8 5.2.0 2025-03-31 17:45:05 +02:00
NEZNAMY 657327e7ee [Bukkit] Move viaversion presence check to fix class loader error when it's not present 2025-03-31 17:44:50 +02:00
NEZNAMY efeea7cf0f Merge pull request #1460 from JT122406/master
Forge and NeoForge Support
2025-03-31 17:20:48 +02:00
Joseph T. McQuigg 7a4637368d Hard Versions 2025-03-31 11:18:36 -04:00
NEZNAMY 2e6ccd078b 5.2.0-SNAPSHOT 2025-03-31 17:09:19 +02:00
NEZNAMY 827197f916 5.1.1 2025-03-31 16:52:47 +02:00
Joseph T. McQuigg c8454ec0c1 Add MC versions to mods.toml 2025-03-31 10:52:34 -04:00
Joseph T. McQuigg 7127a77d92 Remove Versions from mods.toml, Fix register 2025-03-31 10:30:31 -04:00
Joseph T. McQuigg b23912b52f Forge/NeoForge Luckperms Hook 2025-03-30 18:57:32 -04:00
Joseph T. McQuigg 4b21148a03 Adjust Scoreboard classes for setDisplaySlot 2025-03-30 15:06:37 -04:00
Joseph T. McQuigg 2d5ef95e54 Update Forge to 1.21.5 2025-03-30 14:52:00 -04:00
Joseph T. McQuigg b5e2d376dd Update NeoForge to 1.21.5 2025-03-30 14:52:00 -04:00
Joseph T. McQuigg c40b337edc Fix Credits 2025-03-30 14:52:00 -04:00
Joseph T. McQuigg f8583642a8 Correct License 2025-03-30 14:52:00 -04:00
Joseph T. McQuigg 707f28df16 Permission check 2025-03-30 14:52:00 -04:00
Joseph T. McQuigg dd78da089d Use Records for platform 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg c4ea65ed70 Forge Port 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg aabba806c4 Drop Parchment 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg 88167fc42d Default to EmptyTabExpansion 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg e4d7005e46 moddedPlatforms List 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg 5ee27f7ed7 Add Credits 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg 9a4492c401 Add Parchment to Fabric, Use LogUtils instead of AW 2025-03-30 14:51:59 -04:00
Joseph T. McQuigg 39a2aee5a0 NeoForge Port 2025-03-30 14:51:58 -04:00
Joseph T. McQuigg 5184ef170f Update to new com.gradleup.shadow plugin
Gradle 8.13, Fabric Loom 1.10
2025-03-30 14:51:56 -04:00
NEZNAMY 29a35cf1cc [ViaVersion hook] Decrease check interval from 100 to 50 2025-03-30 18:51:39 +02:00
NEZNAMY f26516ecae [Code style] Separate objective register and set display slot functions 2025-03-30 18:47:39 +02:00
NEZNAMY f26a7ad2b1 [Bukkit] Add direct NMS hook for v1_8_R3 and v1_12_R1 2025-03-30 17:46:23 +02:00
NEZNAMY 96e0a29573 Merge pull request #1464 from MineLAT/fix/viaversion-delay
Fix ViaVersion packets delay
2025-03-29 17:12:29 +01:00
NEZNAMY f30d667ca8 [Code style] Add return value annotations and remove unused methods in ConfigurationFile 2025-03-29 17:05:53 +01:00
Rubén 8db7a1d6d9 Fix ViaVersion packets delay 2025-03-29 10:04:46 -06:00
NEZNAMY d285a0512e [Multi-server support] Provide some feedback about connection status (success/fail) (doesn't work for redis) 2025-03-29 16:52:13 +01:00
NEZNAMY 256d0d5c84 Revert "[Placeholders] Parse nested PAPI placeholders using {}"
This reverts commit 6501480980.
2025-03-29 09:57:02 +01:00
NEZNAMY b808e1f9d1 [Bukkit] Refactor scoreboard / tablist implementation finding for players 2025-03-29 09:55:52 +01:00
NEZNAMY 07cd781ec1 [Sponge] Drop Sponge 7 module 2025-03-28 15:43:37 +01:00
NEZNAMY 9115b687f4 [Sponge] Drop support for sponge versions 1.16.5 - 1.20.5 2025-03-27 18:51:28 +01:00
NEZNAMY 7c51377203 [Bukkit] Update paper submodule for 1.21.5 and allow it there 2025-03-27 18:24:02 +01:00
NEZNAMY 193cd02072 [Configuration] Fix startup error when some config options were missing 2025-03-27 16:49:01 +01:00
NEZNAMY dbb6d91f0c [Configuration] Add missing playerlist-objective.render-type option to default config 2025-03-26 19:48:20 +01:00
NEZNAMY a82714e811 [BungeeCord] Fix error (#1462) 2025-03-26 19:00:53 +01:00
NEZNAMY bcd1bbac62 5.1.1-SNAPSHOT 2025-03-26 18:53:58 +01:00
NEZNAMY 2fde0e68ca 5.1.0 2025-03-26 17:53:56 +01:00
NEZNAMY e6e9b1c5ae Add 1.21.5 protocol constant 2025-03-25 18:46:53 +01:00
NEZNAMY 48b789c51d [Fabric] Update to 1.21.5 2025-03-25 18:36:41 +01:00
NEZNAMY 433b39209d [Fabric] Remove server version detection as it is no longer used 2025-03-24 18:26:56 +01:00
NEZNAMY b6df7a9f33 [Code style] Improve parity between Fabric and Paper Scoreboard implementations 2025-03-24 17:16:54 +01:00
NEZNAMY ad1d55537f [Code style] Improve parity between Fabric and Paper TabList implementations 2025-03-24 17:02:35 +01:00
NEZNAMY 9982d2c6ef [Fabric] Update to 1.21.5-rc2 2025-03-24 16:32:17 +01:00
NEZNAMY 1e3f622a98 Remove server version checks for new content as everything is now supported thanks to new ViaVersion hook 2025-03-24 16:26:31 +01:00
NEZNAMY ce05d5f6a6 Merge pull request #1443 from MineLAT/feat/viaversion-packets
Add ViaVersion packets support
2025-03-24 16:15:50 +01:00
NEZNAMY 19378e2095 [RGB] Fix gradient pattern for <#RRGGBB></#RRGGBB> to not capture a newer color used inside of it (caused by using one of MiniMessage's RGB syntaxes) 2025-03-23 18:47:57 +01:00
Rubén 0d992f1e50 Execute delayed tasks at once 2025-03-23 10:39:10 -06:00
Rubén de7cabfd54 Add missing method call 2025-03-23 09:31:10 -06:00
Rubén cfe73a00ee Fix early packet send on viaversion decoder 2025-03-23 09:06:11 -06:00
Rubén 35a7acbbd9 Merge remote-tracking branch 'origin/master' into feat/viaversion-packets
# Conflicts:
#	bukkit/src/main/java/me/neznamy/tab/platforms/bukkit/BukkitTabPlayer.java
#	bukkit/src/main/java/me/neznamy/tab/platforms/bukkit/platform/BukkitPlatform.java
2025-03-23 08:53:00 -06:00
NEZNAMY 20eebca395 [Belowname & Playerlist objective] Add startup warn if configured "value" will never evaluate to a number 2025-03-23 15:47:32 +01:00
NEZNAMY 7c2a4deb1a [Code style] Move getSkin() method to TabList 2025-03-23 13:40:27 +01:00
NEZNAMY e227e6a0f4 [Bukkit] Add back Paper submodule, but only for the latest MC version instead of an actual supported range 2025-03-23 13:09:30 +01:00
NEZNAMY e015c29a3d [Code style] Move legacy color rgb codes to TextColor class 2025-03-23 11:26:13 +01:00
NEZNAMY a2859937e2 [Bukkit] [Performance] Avoid using reflection for getting online players on 1.8+ 2025-03-22 19:53:59 +01:00
NEZNAMY cd26252444 [Scoreboard] Fix error when more than 21 lines are defined (will now error at 100) 2025-03-22 10:42:03 +01:00
NEZNAMY 47894a6e74 [Performance] Tiny performance boost of %luckperms-prefix% and suffix placeholders 2025-03-20 18:37:37 +01:00
NEZNAMY bcf94180d5 [Fabric] Update Fabric to 1.21.5-rc1 2025-03-20 18:33:00 +01:00
NEZNAMY 6d2eeda28c Merge pull request #1457 from Radu-Voinea/master2
Added %luckperms-weight% as a built-in placeholder
2025-03-20 12:09:57 +01:00
Radu Voinea 049c768013 Moved player lookup from LP to TabPlayer 2025-03-20 13:05:53 +02:00
Radu Voinea ffae488d1e Removed auto-formatted text 2025-03-20 12:54:36 +02:00
NEZNAMY 3ea0ae6e5b [Performance] Create a constant for empty component to avoid recreating it over and over 2025-03-19 17:54:56 +01:00
NEZNAMY 530c25655c [Error logging] Add missing " into error message 2025-03-19 17:44:03 +01:00
NEZNAMY ca830fd64c [Playerlist Objective] Make render type explicitly configurable 2025-03-19 17:42:16 +01:00
NEZNAMY 4272476230 [Playerlist Objective] Make title configurable (#1454) 2025-03-19 17:05:26 +01:00
NEZNAMY b7e44246ce [Fabric] Update to 1.21.5-pre3 2025-03-18 16:54:18 +01:00
NEZNAMY 33b9578fd1 [BossBar] Add %bossbar_announce_time_left_<bossbar>% and %bossbar_announce_time_total_<bossbar>% placeholders 2025-03-16 15:03:59 +01:00
NEZNAMY df0a96843d [Error Logging] Fix typo 2025-03-16 15:00:32 +01:00
NEZNAMY 5b5f7dfc12 [Code style] Remove unused fields 2025-03-15 16:49:21 +01:00
NEZNAMY 8b094adcca [Nametags] Add a lot more subcommands for manipulating nametag visibility 2025-03-15 16:48:34 +01:00
NEZNAMY de9d9ab844 [Nametags] Refactor classes and create enum for nametag invisibility reason 2025-03-13 18:08:17 +01:00
NEZNAMY 2fd6d2f50b [Fabric] Update to 1.21.5-pre2 2025-03-13 16:35:37 +01:00
Rubén 349c9eca4b Rename classes for more consistency 2025-03-12 18:18:09 -06:00
Rubén 1f119233d7 Move via module into bukkit module 2025-03-11 18:47:46 -06:00
Rubén 17c2d63892 Use instance method 2025-03-11 14:06:13 -06:00
NEZNAMY 79c76e913d [Fabric] Update to 1.21.5-pre1 2025-03-11 17:06:48 +01:00
NEZNAMY 6501480980 [Placeholders] Parse nested PAPI placeholders using {} 2025-03-08 13:40:58 +01:00
NEZNAMY 5ad9bbba37 [Global playerlist] Simplify expression (servers are never equal) 2025-03-08 09:44:31 +01:00
NEZNAMY f012448758 [Description] Improve image generator script 2025-03-07 20:25:11 +01:00
Rubén 99b6d635d7 Remove unchecked object handling 2025-03-07 08:37:14 -06:00
Rubén 5f742627e9 Avoid component italic format being reset 2025-03-07 07:58:19 -06:00
Rubén a9e725002a Use simple text component 2025-03-07 07:51:16 -06:00
Rubén 49150f9b1e Remove ViaVersion configuration support 2025-03-06 22:43:49 -06:00
Rubén 89aa1ba94c Fix class cast 2025-03-06 22:32:14 -06:00
Rubén 6aca313bd8 Use dummy object 2025-03-06 22:31:49 -06:00
Rubén f76d5a958f Fix component writing on newer versions 2025-03-06 22:15:51 -06:00
NEZNAMY b833a10de4 [Fabric] Update to 25w10a 2025-03-05 17:14:38 +01:00
Rubén f3ce5632fb Add safe check for ViaVersion internals usage 2025-03-05 07:54:09 -06:00
Rubén f5bf4c3831 Merge component conversion methods 2025-03-04 07:27:01 -06:00
Rubén 08a3acc5e0 Use direct return for viaversion providers 2025-03-04 07:26:13 -06:00
Rubén 5b63034607 Apply component style on compatible components 2025-03-03 07:36:33 -06:00
Rubén d4543032d9 Use the correct annotation 2025-03-02 09:25:52 -06:00
Rubén 254a91c3bd Fix legacy text check 2025-03-02 09:18:46 -06:00
NEZNAMY 4c01ddaaef [Description] Remove now no longer used images 2025-03-02 14:10:06 +01:00
NEZNAMY 2993d1450a [Description] Change text into code-generated images 2025-03-02 13:49:37 +01:00
Rubén 582c3a4c1a Initial ViaVersion packets support 2025-03-01 16:31:24 -06:00
NEZNAMY dd6b964405 [Fabric] Remove support for all versions below 1.21.4 2025-03-01 18:31:50 +01:00
NEZNAMY 16827bfbac Update references to version 5.1.0 2025-03-01 18:05:53 +01:00
NEZNAMY 3c4d72bb71 Bump version to 5.1.0-SNAPSHOT 2025-03-01 17:26:30 +01:00
NEZNAMY 004036e019 [BungeeCord / Velocity] Read server list from configuration for %online_<server>% placeholders instead of dynamically registering them when used 2025-03-01 16:15:03 +01:00
NEZNAMY ba06f80baa [BungeeCord / Velocity] Block bridge communication messages from player to avoid exploits 2025-03-01 14:07:50 +01:00
NEZNAMY ee47428a80 [Floodgate hook] Remove warning when floodgate is not configured correctly 2025-03-01 09:10:23 +01:00
NEZNAMY 1e40cae27b [Wiki] Monthly wiki backup for March 2025 2025-03-01 08:46:19 +01:00
NEZNAMY f5b7bb5549 [Belowname] Rename messages to use belowname "value" instead of "number" 2025-02-28 16:58:57 +01:00
NEZNAMY 115883f8d0 [Fabric] Update to 25w09b 2025-02-28 16:57:37 +01:00
NEZNAMY a73446a1c5 [Placeholders] Make LP placeholders also use configured value instead of permission refresh interval 2025-02-27 18:45:37 +01:00
NEZNAMY 7501c4f76b [Commands] Make placeholder refresh interval color in cpu output different if it was overridden in config 2025-02-27 18:40:46 +01:00
NEZNAMY 9f038fae63 [Placeholders] Allow placeholder refresh intervals to define overrides for internal placeholders 2025-02-27 18:21:49 +01:00
NEZNAMY a61a520570 [Fabric] Update to 25w09a 2025-02-26 18:27:51 +01:00
NEZNAMY 885783cd9a [Bukkit] Refactor feature provider loaders 2025-02-25 17:16:54 +01:00
NEZNAMY 181f850c58 Fix compilation 2025-02-23 17:39:25 +01:00
NEZNAMY fe8742b580 Merge pull request #1435 from MineLAT/feat/proxy-support
Expand multi-server support
2025-02-23 17:11:33 +01:00
Rubén daeba7caa9 Remove unused belowname code 2025-02-23 10:01:29 -06:00
NEZNAMY 1340e6dc1b [Code style] [Bukkit] Refactor team packet data 2025-02-23 09:24:27 +01:00
NEZNAMY cba7655f0d [Code style] Move method into a different class 2025-02-22 18:32:31 +01:00
NEZNAMY ac7e2a9aef [RGB] Fully support magic codes inside gradients, they no longer must all be at the beginning 2025-02-22 18:27:33 +01:00
Rubén fcc0bfbf32 Optimize dependencies 2025-02-22 10:40:58 -06:00
NEZNAMY a7e86bdb64 [Fabric] Update to 25w08a 2025-02-19 17:57:19 +01:00
Rubén c3eecd8d14 Remove duplicated check 2025-02-18 10:39:48 -06:00
Rubén 25e6da3ac5 Add safe check for already connected players 2025-02-18 10:37:49 -06:00
Rubén a7e5786fee Use global player list instead 2025-02-18 09:56:48 -06:00
Rubén a6bccc3dd3 Add missing config values 2025-02-17 18:12:19 -06:00
Rubén d8cd39dc3e Remove duplicated yellow number send 2025-02-17 14:13:14 -06:00
Rubén 6eacf833f5 Remove duplicated name tag send 2025-02-17 14:11:54 -06:00
Rubén dbdd417e0d Avoid bad configuration update 2025-02-17 14:11:30 -06:00
Rubén 4c8dd52f28 Ignore same player 2025-02-17 13:56:46 -06:00
Rubén 31a2d8a02b Add supported types 2025-02-17 12:49:38 -06:00
Rubén f246d57a7e Add backend messaging 2025-02-17 12:37:15 -06:00
Rubén 4ae856630f Add proxy support via messenger 2025-02-17 12:02:27 -06:00
Rubén 8652baf2ae Rename redis feature 2025-02-17 11:50:18 -06:00
NEZNAMY 4a18853e8c [BungeeCord] Remove warning about a waterfall option as it is now long abandoned 2025-02-16 19:58:03 +01:00
NEZNAMY a60be9d8c1 [Spectator fix] Fix not updating on proxies (#1434) 2025-02-16 19:21:07 +01:00
NEZNAMY e16b47409c [Code style] Keep expected tablist display names as TabComponent instead of platform components 2025-02-16 17:45:57 +01:00
NEZNAMY 6f14cbe746 5.0.8-SNAPSHOT 2025-02-16 16:32:10 +01:00
NEZNAMY ea79c9c5dd 5.0.7 2025-02-16 11:27:35 +01:00
NEZNAMY 650d13ed71 [Reloading] Fix plugin messages being ignored on Velocity on reload due to a check not working correctly 2025-02-15 09:11:50 +01:00
NEZNAMY 169b8b8e94 [Scoreboard] Fix scoreboard chain misconfiguration detection not working correctly 2025-02-14 16:57:15 +01:00
NEZNAMY 8cef4a5bcb [Fabric] Update to 25w07a 2025-02-13 19:16:32 +01:00
NEZNAMY 70b40802cc [Fabric] Remove redundant function split based on server version 2025-02-11 17:45:53 +01:00
NEZNAMY 416e707cda Revert "[Code style] Create a separate module for bossbar API"
This reverts commit 042ab6850b.
2025-02-11 16:32:05 +01:00
NEZNAMY 12578293bc [Bukkit] Delete paper submodule as it was not worth it 2025-02-10 17:14:46 +01:00
NEZNAMY 042ab6850b [Code style] Create a separate module for bossbar API 2025-02-09 20:03:17 +01:00
NEZNAMY 09fc042630 [Chat components] Fix magic codes not being assigned correctly when converting from an adventure component 2025-02-09 14:55:58 +01:00
NEZNAMY c73d351bf1 [Configuration] Update default config to avoid unwanted bold text caused by MiniMessage 2025-02-09 12:42:52 +01:00
NEZNAMY 4d4e0a9c2a [BungeeCord & Velocity] Make compatibility error message more visible 2025-02-08 13:03:25 +01:00
NEZNAMY 2fd29b2347 [Configuration] Disable SnakeYAML's max file size limit (layout skincache can exceed the default 3MB) 2025-02-08 12:45:19 +01:00
NEZNAMY f332068318 [Fabric] Fix 1.16.5 support 2025-02-08 12:28:52 +01:00
NEZNAMY 186c79f93c [Bukkit] Split component converter into multiple classes based on server version interval for better maintainability 2025-02-08 10:19:06 +01:00
NEZNAMY 3770066485 [Code style] Move component folder into a new separate module 2025-02-07 16:19:48 +01:00
NEZNAMY 17b0ffe52b [Bukkit] Fix component style magic codes conversion 2025-02-07 15:35:23 +01:00
NEZNAMY d259b5bb78 5.0.7-SNAPSHOT 2025-02-06 18:05:23 +01:00
NEZNAMY f6c8d24177 5.0.6 2025-02-06 17:54:47 +01:00
NEZNAMY ab3bd61d3c [Bukkit] Fix error 2025-02-06 17:27:46 +01:00
NEZNAMY 6a5cee8f0e [Fabric] Update to 25w06a 2025-02-05 20:15:43 +01:00
NEZNAMY 549732fc8b [Chat components] No longer track modern/legacy converted components, only handle them internally in bungeecord module 2025-02-05 19:13:56 +01:00
NEZNAMY 09d400c6fb [GitHub] Bump version to fix actions 2025-02-05 18:33:49 +01:00
NEZNAMY 7e1cdafa78 [Bukkit] Only enable packetevents bug compensation <1.13 where it's actually needed to avoid scoreboard gradient bug due to forced splitting when the option is enabled and doesn't need to be 2025-02-04 18:39:25 +01:00
NEZNAMY 434c0216d5 [Adventure hook] Fix startup error when an older version of the library is present 2025-02-04 18:28:34 +01:00
NEZNAMY d5a0ae8e71 [Scoreboard] Fix memory leak 2025-02-03 16:56:04 +01:00
NEZNAMY 79e56c6a30 [Chat components] Implement shadowColor field (currently only used for converting components created using MiniMessage) 2025-02-02 17:54:57 +01:00
NEZNAMY 11cc1c3f25 [Code style] Remove unused constructor 2025-02-02 16:12:53 +01:00
NEZNAMY 8b343bcfb6 [Chat components] Fix NPE 2025-02-02 15:36:25 +01:00
NEZNAMY ecd83beb7d [Performance] Replace stream with for loop in vanish check 2025-02-02 14:14:57 +01:00
NEZNAMY 438f21fb11 [BungeeCord] Update to build 1899 (and require it) 2025-02-01 20:43:05 +01:00
NEZNAMY dd1524cf31 [Dependencies] Bump and remove unnecessary 2025-02-01 18:40:02 +01:00
NEZNAMY 0f85aa5384 Fix broken messages from previous commit 2025-02-01 18:23:04 +01:00
NEZNAMY 4644a0ae96 [Code style] Further reduce references to EnumChatFormat class 2025-02-01 18:18:38 +01:00
NEZNAMY 84b3efe0fc [Code style] Simplify some component creations 2025-02-01 17:07:48 +01:00
NEZNAMY 511acbd5ff [Chat components] Rework component creation and converters 2025-02-01 16:45:20 +01:00
NEZNAMY 8749b3b354 [Wiki] Monthly wiki backup for February 2025 2025-02-01 13:09:27 +01:00
NEZNAMY b66e63d242 [Fabric] Implement adventure component conversion to MC components (#1425) 2025-02-01 09:43:03 +01:00
NEZNAMY ba951238c3 [Fabric] Update to 25w05a 2025-01-29 20:08:49 +01:00
NEZNAMY a4eb76f1cf 5.0.6-SNAPSHOT 2025-01-29 20:08:17 +01:00
NEZNAMY c486899dcf 5.0.5 2025-01-29 17:37:10 +01:00
NEZNAMY b212f0d5be [Velocity] Fix some console messages not being colored correctly 2025-01-27 18:44:55 +01:00
NEZNAMY caa534ff7f [MySQL] Fix upload command using wrong file path 2025-01-26 12:15:41 +01:00
NEZNAMY 9c2fac6749 [MiniMessage] Fix critical error when an ancient MM version is present 2025-01-25 19:12:47 +01:00
NEZNAMY 2a4f918a10 [RGB] Convert all RGB/Gradients for MiniMessage parser (#1408, #1414, #1421) 2025-01-25 08:55:22 +01:00
NEZNAMY b45e2afe4c [Code style] Move classes to a different package 2025-01-24 19:16:07 +01:00
NEZNAMY 2c7237e5d9 [RGB] Remove early gradient conversion (for future commits) 2025-01-24 19:10:59 +01:00
NEZNAMY 26477e3150 5.0.5-SNAPSHOT 2025-01-23 18:27:20 +01:00
NEZNAMY cba8cb57d5 5.0.4 2025-01-23 17:24:16 +01:00
NEZNAMY 599b4822e5 [Fabric] Update to 25w04a 2025-01-22 18:31:03 +01:00
NEZNAMY fbd150b353 [API] Expose TabPlayer#getServer, TabPlayer#getWorld and TabPlayer#isBedrockPlayer 2025-01-21 17:33:10 +01:00
NEZNAMY 10b252e934 [Placeholders] Fix placeholders staying incorrectly marked as bridge placeholders under very specific conditions (#1416) 2025-01-19 21:36:27 +01:00
NEZNAMY e9dfcdeb10 [Layout] If trying to use skin of an online player in fixed slot, try to get it from the player's profile if online 2025-01-19 18:16:04 +01:00
NEZNAMY 9cb2f27754 [Error management] Do not print full stack traces when a skin fails to download 2025-01-19 17:41:48 +01:00
NEZNAMY a090a83b7d [Debug] Replace debug messages about downloading skin with downloaded and include time it took 2025-01-19 17:04:44 +01:00
NEZNAMY 992e661e4c [Placeholders] Fix bridge overriding placeholders if they did not exist before a reload (such as conditions) (#1416) 2025-01-19 15:59:51 +01:00
NEZNAMY 3b993d114e [Velocity] Fix errors when plugin is disabled due to a broken configuration file 2025-01-19 15:21:34 +01:00
NEZNAMY d181d62466 [Code style] Call EnumChatFormat#getFormat instead of toString 2025-01-19 14:55:46 +01:00
NEZNAMY 968cef7a12 [Scoreboard & Nametags] Add a config option to enforce <1.13 limits even for 1.13+ players (#1412, #1413) 2025-01-19 13:48:39 +01:00
NEZNAMY 390c2395eb Fix compilation error from previous commits 2025-01-19 13:34:18 +01:00
NEZNAMY adc9444794 [Code style] Make code more readable 2025-01-19 13:25:20 +01:00
NEZNAMY f086318082 [Chat components] Remove redundant checks for player's version 2025-01-19 13:21:18 +01:00
NEZNAMY 1cef4400b9 [Scoreboard] Fix ConcurrentModificationException when using API (#1410) 2025-01-18 14:23:13 +01:00
NEZNAMY 1f879ac91e [Scoreboard] Fix setText API method breaking a line if setting it to empty value (#1410) 2025-01-18 14:12:00 +01:00
NEZNAMY bec129d98e [Scoreboard & Bossbar] Save toggled players by UUID instead of names 2025-01-18 10:44:22 +01:00
NEZNAMY 152c04e68f [Configuration] Remove file header restoration on file modification 2025-01-18 10:41:13 +01:00
NEZNAMY d6cdacef43 [Layout] Fix skins not being saved into memory when downloaded 2025-01-16 19:02:38 +01:00
NEZNAMY 09891a075d [Layout] Add debug messages when a skin is about to be downloaded 2025-01-16 19:02:00 +01:00
NEZNAMY 9500bab5b7 [Scoreboard] Fix resetScoreboard not applying scoreboard correctly (#1411) 2025-01-16 18:15:31 +01:00
NEZNAMY 231edd4bd4 [Chat components] Fix magic code null values being converted to false 2025-01-15 18:55:03 +01:00
NEZNAMY 433572e759 [Fabric] Update to 25w03a 2025-01-15 18:06:51 +01:00
NEZNAMY 3ec772e87f [Feature management] Load all features in plugin's main thread to avoid API calls from load event before a feature actually loads (#1409) 2025-01-10 21:55:55 +01:00
NEZNAMY ae8287157c [Scoreboard] Do not add API scoreboards to the chain of scoreboards to go through (#1409) 2025-01-10 21:32:42 +01:00
NEZNAMY f005907b41 [Fabric] Update to 25w02a 2025-01-09 18:44:55 +01:00
NEZNAMY 8ea16044f1 [Debug] Send a correct message if player does not have any group permission 2025-01-08 18:34:06 +01:00
NEZNAMY e787a28353 [Tablist formatting] Fix formatting applying even if disabled with condition sometimes 2025-01-06 18:59:32 +01:00
NEZNAMY 6925d9564c [Code style] Create Platform#getCommand method instead of storing it in TabConstants 2025-01-04 18:43:37 +01:00
NEZNAMY ccd4ea785a [Logging] Fix outdated value in a message 2025-01-04 18:27:29 +01:00
NEZNAMY 63e88c09d4 [MySQL] Add a startup warn message if database is empty 2025-01-04 18:24:51 +01:00
NEZNAMY 296191b502 [Code style] Replace uses of EnumChatFormat for color codes with the codes directly 2025-01-02 19:20:49 +01:00
NEZNAMY af0151f446 [RGB] Remove now redundant check for modern/legacy colors (partially) 2025-01-02 16:26:06 +01:00
NEZNAMY 2bdfaa167e [RGB] Remove support for |L for manually defining legacy colors 2025-01-02 15:56:49 +01:00
NEZNAMY cd96476f9e [Belowname] Improve a warning message 2025-01-01 19:16:12 +01:00
NEZNAMY 9b0545aa1a [Layout] Fix players on top of tablist if team implementation is not available 2025-01-01 18:57:49 +01:00
NEZNAMY 63823123f8 [BungeeCord] Simplify code 2025-01-01 14:27:43 +01:00
NEZNAMY e91728be98 [Sponge 8] Update sponge gradle plugin to fix warning 2025-01-01 14:02:00 +01:00
NEZNAMY e7ecbf1245 [Velocity] Remove usage of deprecated API 2025-01-01 13:54:17 +01:00
NEZNAMY 28c2363b67 [Wiki] Monthly wiki backup for January 2025 2025-01-01 13:12:21 +01:00
NEZNAMY 21a3d4fb55 [Paper] Fix mistake in magic codes (#1404) 2024-12-30 14:10:52 +01:00
NEZNAMY 4b459a3ed1 [Commands] Add a red message to debug command if assigning groups by permissions and the player has all permissions 2024-12-29 20:09:31 +01:00
NEZNAMY ebc6a1b842 Fix paper compilation 2024-12-29 20:08:10 +01:00
NEZNAMY b72b0f269a [Code style] Remove redundant warning suppression 2024-12-21 17:54:06 +01:00
NEZNAMY 4cbcd69ed2 [Code style] Remove redundant constructor 2024-12-21 17:45:13 +01:00
NEZNAMY 6ef8b7748c [Code style] Remove redundant double coloring 2024-12-21 17:05:35 +01:00
NEZNAMY 8b567cb976 [Code style] Optimize last color of component calculation 2024-12-21 16:15:04 +01:00
NEZNAMY d8c231b9ce [Code style] Further reduce usage of EnumChatFormat class 2024-12-21 15:49:33 +01:00
NEZNAMY cc4347c881 [Code style] Make TabComponent#fetchLastColor Nullable 2024-12-21 13:19:20 +01:00
NEZNAMY 7cc572feb5 [Code style] Replace some references to EnumChatFormat with the actual color codes 2024-12-21 11:58:37 +01:00
NEZNAMY 96d1d1feb4 [Code style] Use TextColor as team color internally to prepare for a potential future MC update 2024-12-21 11:39:36 +01:00
NEZNAMY a7d9bd9ab5 [Code style] Simplify TabComponent#toRawText implementation 2024-12-21 11:15:47 +01:00
NEZNAMY 1cdfdf1d43 [Code style] Simplify 2024-12-18 17:32:54 +01:00
NEZNAMY 0762a5e689 [Code style] Remove redundant method call 2024-12-18 17:22:55 +01:00
NEZNAMY 3e2906ccf8 [Dependencies] Version bump and remove unused 2024-12-18 17:18:09 +01:00
NEZNAMY 13761e032c [Bukkit] Set shadowColor to null instead of 0 (no shadow) (#1400) 2024-12-16 18:51:02 +01:00
NEZNAMY fb8fa3fa54 [MiniMessage] Implement Keybind component support as well (on 1.19+) 2024-12-14 11:34:02 +01:00
NEZNAMY b89bf5933b [MiniMessage] Add support for its translatable components (paper / velocity only) (#1399) 2024-12-13 22:40:20 +01:00
NEZNAMY 1c4f404fd2 [Code style] Remove unused method 2024-12-13 22:22:51 +01:00
NEZNAMY 9fe1560f1a [Sorting] Remove runtime warn spam when configured sorting placeholder is invalid (only keep startup warn) 2024-12-12 18:58:49 +01:00
NEZNAMY 6a9cca37c6 [Scoreboard] Fix toggle command being completely ignored when another plugin has sent scoreboard instead of processing it (to some degree) 2024-12-10 21:30:20 +01:00
NEZNAMY bfde75d4b1 [Configuration] Fix startup error when group name is a number (#1398) 2024-12-09 18:12:03 +01:00
NEZNAMY a83f98580d [Bukkit] Update Paper submodule to 1.21.4 2024-12-07 13:58:47 +01:00
NEZNAMY 673542d8e4 [Code style] Move canSee method into TabPlayer 2024-12-07 12:23:51 +01:00
NEZNAMY 81c5d89a25 Fix broken PR 2024-12-07 12:08:26 +01:00
NEZNAMY bf0bcb0b96 Merge pull request #1394 from WheelerShigley/master
Fabric now has a getTPS() approximation.
2024-12-07 09:57:25 +01:00
WheelerShigley ac7a664303 Fabric now has a getTPS() approximation.
Added Fabric TPS approximation, based on mspt.
2024-12-06 19:58:38 -06:00
NEZNAMY 182dc67a49 5.0.4-SNAPSHOT 2024-12-03 20:27:24 +01:00
NEZNAMY 27ee82d17c 5.0.3 2024-12-03 20:11:13 +01:00
NEZNAMY 9405e4e45d [Bukkit] Add 1.21.4 support 2024-12-03 20:06:48 +01:00
NEZNAMY 8616769e32 [Bukkit] Print component converter initialization error if print flag is enabled 2024-12-03 19:12:37 +01:00
NEZNAMY 5d85c4697b [Bukkit] Fix error when a plugin shades adventure library without relocating it 2024-12-03 19:09:55 +01:00
NEZNAMY c54a2b7353 Mark 1.21.4 as the latest supported version 2024-12-03 18:24:17 +01:00
NEZNAMY 35075e88e3 [Fabric] Update to 1.21.4 2024-12-03 18:18:09 +01:00
NEZNAMY 1266d34176 [Wiki] Monthly wiki backup for December 2024 2024-12-01 20:05:59 +01:00
NEZNAMY 66ddf0e3ca [Fabric] Update to 1.21.4-rc3 2024-11-30 14:37:59 +01:00
NEZNAMY 88ab129737 [Fabric] Update to 1.21.4-rc2 2024-11-29 17:18:43 +01:00
NEZNAMY bcd293a255 [Fabric] Update to 1.21.4-rc1 2024-11-28 17:50:24 +01:00
NEZNAMY 4a5ebe6dbd [Fabric] Mark 1.21.4-pre3 as compatible 2024-11-26 18:23:13 +01:00
NEZNAMY ef1c3b1b3b [BungeeCord] Use new features added in build 1885 (no longer supports older builds) 2024-11-26 18:16:04 +01:00
NEZNAMY f7e68ffb6b [Fabric] Update to 1.21.4-pre3 2024-11-26 18:06:10 +01:00
NEZNAMY 2cf2153c4d 5.0.3-SNAPSHOT 2024-11-26 17:43:19 +01:00
NEZNAMY 7e7d0025fa 5.0.2 2024-11-26 17:27:16 +01:00
NEZNAMY 8252b6486e [Fabric] Update to 1.21.4-pre2 2024-11-25 20:03:28 +01:00
NEZNAMY 378041cb16 Merge pull request #1388 from Syrent/master
fix: avoid using TAB's internal vanish checks when a registered vanish integration is available
2024-11-24 19:57:41 +01:00
syrent ee5ff07565 chore: move pv try/catch inside vanish integration if statement 2024-11-24 20:48:02 +03:30
syrent 80c63dd414 chore: don't check for vanished meta if there's a registered vanish integration 2024-11-24 19:55:57 +03:30
NEZNAMY e182366566 [Scoreboard] Fix detection of scoreboards from other plugins not resetting on server switch 2024-11-23 21:18:31 +01:00
NEZNAMY acee89cce3 [BungeeCord] Add TODO 2024-11-23 20:59:45 +01:00
NEZNAMY 3ef3d14c10 [Vanish detection] Properly hook into vanish plugins on Velocity just like on BungeeCord 2024-11-23 20:58:15 +01:00
NEZNAMY 74365780a7 [Code style] Minor fixes from PR 2024-11-23 14:27:26 +01:00
NEZNAMY f6ad80370f Merge pull request #1387 from Syrent/master
feat: add VanishIntegration api
2024-11-23 11:13:12 +01:00
syrent 87eb544936 feat: add VanishIntegration api 2024-11-23 09:20:39 +03:30
NEZNAMY cde0389380 [Fabric] Update to 1.21.4-pre1 2024-11-20 17:46:25 +01:00
NEZNAMY 9e46ffc4e1 [Nametags] Process API calls in feature's thread instead of caller thread 2024-11-17 10:53:42 +01:00
NEZNAMY f3c35de780 [Configuration] Fix startup error if an element in a list is not a String 2024-11-14 20:20:11 +01:00
NEZNAMY 75f5378c8c [Belowname] Do not send updates of vanished players to those who cannot see them 2024-11-14 18:07:07 +01:00
NEZNAMY 19d32127e8 [Fabric] Update to 24w46a 2024-11-13 16:49:59 +01:00
NEZNAMY 2f00aa7750 [Conditions] Fix mistake from past commits not loading true/false values if not wrapped in "" 2024-11-10 18:24:12 +01:00
NEZNAMY 07f5dc68b5 [Velocity] Use new listOrder API (and bump required velocity build number to 450) 2024-11-10 10:08:35 +01:00
NEZNAMY 96a39d7037 [Configuration] Fix unknown key detection not working 2024-11-09 17:40:54 +01:00
NEZNAMY 409f1c4230 [Fabric] Update to 24w45a 2024-11-06 19:19:51 +01:00
NEZNAMY c3d2f9aeea [Commands] Reuse the same list of valid properties 2024-11-05 17:35:17 +01:00
NEZNAMY 380b3dd1f6 [Scoreboard] Add startup warn if trying to use NumberFormat on <1.20.3 server and runtime warn when trying to send it to <1.20.3 player 2024-11-03 16:52:10 +01:00
NEZNAMY c15a6009a2 [MySQL] Execute MySQL queries in a separate thread 2024-11-03 10:04:45 +01:00
NEZNAMY e4e7c364fd [Code style] Make list mutable 2024-11-03 09:46:14 +01:00
NEZNAMY 438361eed2 [Code style] Make fields final 2024-11-03 09:31:50 +01:00
NEZNAMY 684b35f2df [Code style] Refactor config options loading and add a few more misconfiguration checks 2024-11-03 09:13:41 +01:00
NEZNAMY 1d603ae76f [Conditions] Fix warning from previous commit 2024-11-02 16:18:46 +01:00
NEZNAMY a342b23890 [Conditions] Fix conditions without true/false defined not refreshing correctly 2024-11-02 15:49:37 +01:00
NEZNAMY c0dde2eaa7 [Config] Change default default-skin value in layout as the old one contains extra layer (which will be visible on 1.21.4) 2024-11-01 11:25:35 +01:00
NEZNAMY 6245fe9553 [Wiki] Monthly wiki backup for November 2024 2024-11-01 10:19:39 +01:00
NEZNAMY fb5be9e2aa [Paper] Update direct NMS to 1.21.3 2024-10-31 21:11:40 +01:00
NEZNAMY 918620a7dc [Bukkit & Fabric] Update to 24w44a (predicted on Bukkit) 2024-10-31 20:46:51 +01:00
NEZNAMY d2855449f0 [Layout] Add misconfiguration checks if slot is out of range 2024-10-30 20:56:59 +01:00
NEZNAMY f59326c0ae [Configuration] Add console warning if using invalid property for groups / users 2024-10-30 19:58:12 +01:00
NEZNAMY 033b9ed035 [Configuration] Improve warning messages 2024-10-29 20:37:27 +01:00
NEZNAMY 5c299767ec [Vanish detection] Disable Bukkit canSee support due to issues with vanish plugins 2024-10-29 20:16:30 +01:00
NEZNAMY 818701cd07 [RedisSupport] Register messages for features in constructors instead of load to make sure they run immediately and sync in the main thread 2024-10-29 20:08:58 +01:00
NEZNAMY 9b5e63aa25 [RedisSupport] Slightly improve debug message 2024-10-29 20:04:56 +01:00
NEZNAMY 1ad285bd79 [RedisSupport] Queue incoming messages to avoid tasks running before plugin is fully enabled, causing errors 2024-10-28 18:06:57 +01:00
NEZNAMY 4507bb179a Merge pull request #1374 from Tanguygab/master
Added Text PlaceholderAPI support on Fabric
2024-10-27 18:00:39 +01:00
Tanguygab 2dd79295a9 Fixed spacing 2024-10-27 17:56:25 +01:00
Tanguygab b21d840e60 [Fabric] Added FabricTabExpansion 2024-10-27 17:44:24 +01:00
NEZNAMY f3fa40bb0a [GitHub] Store plugin description in source code as backup (phase 4) 2024-10-27 17:11:38 +01:00
Tanguygab d8e14de0cf Fixed error with Text PAPI placeholder 2024-10-26 21:34:25 +02:00
Tanguygab f7b96eceeb Added support for Text PlaceholderAPI on Fabric 2024-10-26 21:26:22 +02:00
NEZNAMY 6f760939f3 [Placeholders] Add validation check to PlaceholderManagerImpl#getPlaceholder 2024-10-26 21:23:17 +02:00
NEZNAMY 5273ad0c5f [Gradle] Update to 8.10.2 2024-10-26 20:22:51 +02:00
NEZNAMY ac12abfb8b [GitHub] Store plugin description in source code as backup (phase 3) 2024-10-26 19:19:04 +02:00
NEZNAMY e5146e7f53 [Misconfiguration] Fix color codes being parsed in warning messages when they should not be. 2024-10-26 19:09:53 +02:00
NEZNAMY 62d1210872 [RGB] Fix using "<" symbol inside gradient breaking it 2024-10-26 18:59:49 +02:00
NEZNAMY 0d0177cd40 Bump bStats to 3.1.0 (this also somehow magically fixes false positives of anti-viruses) 2024-10-26 14:07:38 +02:00
NEZNAMY 227ecf9c9d [Placeholders] Fix error when registering custom server placeholder on proxy 2024-10-26 11:03:09 +02:00
NEZNAMY 562cd50762 [Belowname] Rename config options to hopefully be more clear 2024-10-26 10:29:21 +02:00
NEZNAMY ec56d530a6 [Scoreboard] Fix startup error when a line is configured to be null 2024-10-25 20:57:39 +02:00
NEZNAMY 6350714508 [GitHub] Store plugin description in source code as backup (phase 2) 2024-10-25 20:42:13 +02:00
NEZNAMY 1b251dad6a [GitHub] Store plugin description in source code as backup (phase 1) 2024-10-24 17:12:04 +02:00
NEZNAMY 7765b51a55 5.0.2-SNAPSHOT 2024-10-23 21:16:18 +02:00
NEZNAMY ff6ba6a8e9 5.0.1 2024-10-23 21:04:39 +02:00
NEZNAMY ce3485c823 [Layout] Fix player group condition not getting refreshed properly 2024-10-23 21:04:09 +02:00
NEZNAMY 90a99d3a79 [Fabric] Update to 1.21.3 2024-10-23 20:08:52 +02:00
NEZNAMY 7248dc4fef [Layout] Make check for 1.21.2+ listOrder support better (and work correctly) 2024-10-23 18:36:15 +02:00
NEZNAMY d704db55fa [Code style] Simplify 2024-10-23 16:26:43 +02:00
NEZNAMY 0f581e47b1 5.0.1-SNAPSHOT 2024-10-23 16:25:29 +02:00
NEZNAMY 48013f9b3c 5.0.0 2024-10-22 19:29:31 +02:00
NEZNAMY 258c8ce989 [Velocity] Use proper API method for creating TabListEntry 2024-10-22 19:29:13 +02:00
NEZNAMY c56a703028 Confirm 1.21.2 protocol version 2024-10-22 18:51:17 +02:00
NEZNAMY 4b9ce1b067 [Fabric] Update to 1.21.2 2024-10-22 18:50:56 +02:00
NEZNAMY 39b56725dd [Fabric] Update to 1.21.2-rc1 2024-10-18 21:44:54 +02:00
NEZNAMY b281b18a4e [Code style] Properly implement Platform#getServerVersion on proxies to avoid incorrect results 2024-10-17 17:30:04 +02:00
NEZNAMY b85487375d [Configuration] Rename version in config conversion 2024-10-16 18:27:03 +02:00
NEZNAMY 9ccdc0cf7e [Fabric] Update to 1.20.2-pre5 2024-10-16 17:58:40 +02:00
NEZNAMY 51b1bcf507 [Fabric] Update to 1.20.2-pre4 2024-10-15 18:59:00 +02:00
NEZNAMY 0afe598f3c [Bukkit] Small NMS cleanup 2024-10-13 11:10:38 +02:00
NEZNAMY 4227b0c702 [Nametags] Fix double team register due to concurrency 2024-10-12 19:19:30 +02:00
NEZNAMY 2a4e4a4e2e [Nametags] Fix team register/unregister duplications in combination of (un)vanishing and disable condition change 2024-10-12 19:18:03 +02:00
NEZNAMY a9fa8291de [Velocity] Avoid new object instantiation 2024-10-12 12:39:58 +02:00
NEZNAMY 007c0abc95 [Plugin messages] Protocol break - Identify packets by their ID instead of name 2024-10-12 11:20:18 +02:00
NEZNAMY f9752b7090 [Performance] Disable CPU tracking in netty because getting system time on every packet send was causing high CPU usage by itself 2024-10-12 10:11:32 +02:00
NEZNAMY b44b91f8cc [GitHub] Update branch name in actions 2024-10-11 21:04:51 +02:00
NEZNAMY 352721540a [Fabric] Update to 1.21.2-pre3 2024-10-11 20:25:31 +02:00
NEZNAMY 1ab5f49c3b [Velocity] Remove TAB-Bridge support for scoreboard packet encoding 2024-10-11 19:27:35 +02:00
NEZNAMY 976e6e397a [Bedrock] Update warning message 2024-10-11 17:15:04 +02:00
NEZNAMY e95139b79e [Placeholders] Fix nested placeholders in relational placeholders updating not triggering the main placeholder refresh 2024-10-09 17:16:25 +02:00
NEZNAMY a75f50dcf6 [Bedrock] No longer disable a feature and implement sidebar workaround as new Geyser build resolves these issues on their side. 2024-10-09 14:13:42 +02:00
NEZNAMY 87334c586c I just love Velocity 2024-10-06 18:20:19 +02:00
NEZNAMY eddec70a99 [Nametags] Fix attempts to send team packets when disabled for player 2024-10-06 16:44:47 +02:00
NEZNAMY d1d3279c8e [Fabric] Update to 24w40a 2024-10-03 18:50:58 +02:00
NEZNAMY 13ff1dfb18 [Velocity] Fix exploit (not specifying more to keep users safe) 2024-10-02 20:36:38 +02:00
NEZNAMY e0d09132dd [Wiki] Monthly wiki backup for October 2024 2024-10-01 20:03:45 +02:00
NEZNAMY 99478e7f33 [Build] Remove publishing script 2024-09-28 13:35:01 +02:00
NEZNAMY 02087c735a [Conditions] Automatically trim all spaces 2024-09-27 17:50:12 +02:00
NEZNAMY cd13d588d6 [Layout] Fix ROWS direction not working on 1.21.2 from previous commit 2024-09-26 21:21:04 +02:00
NEZNAMY 6efc23cc15 [Fabric] ACTUALLY update to 24w39a (while keeping older version support) 2024-09-26 21:10:58 +02:00
NEZNAMY 5c28711b26 [Layout] Take advantage of the new 1.21.2 listOrder tablist sorting field to remove entries from chat complete 2024-09-26 20:05:58 +02:00
NEZNAMY e9ae57aff5 [Fabric] Update to 24w39a 2024-09-25 18:16:12 +02:00
NEZNAMY 92e4b1749e [Velocity] Improve error messages 2024-09-24 18:29:46 +02:00
NEZNAMY 854eed74d7 [Code style] Clean up method 2024-09-22 13:45:17 +02:00
NEZNAMY 7c5ef3aa8a [Bukkit] Bump dependency 2024-09-21 15:11:12 +02:00
NEZNAMY 78670b5d90 [Code style] Simplify code 2024-09-20 21:12:03 +02:00
NEZNAMY f43d54b6f6 [Bukkit] Fix team packet creation issue in a past commit 2024-09-20 20:51:24 +02:00
NEZNAMY db0dd75e27 [Fabric] Update to 24w38a 2024-09-19 18:49:06 +02:00
NEZNAMY d6d1649975 [Performance] Speed up TAB#getPlayer function 2024-09-15 14:04:07 +02:00
NEZNAMY f0f0e40897 [Velocity] Cache team display name objects 2024-09-14 18:11:53 +02:00
NEZNAMY 43c1116ac7 [Code style] Call shorter method 2024-09-14 12:02:08 +02:00
NEZNAMY 225f30a257 [Performance] Add check to speed up function 2024-09-13 22:38:43 +02:00
NEZNAMY ae03436592 [Performance] Fix Bridge response placeholder processing calling RefreshableFeature#refresh for every placeholder that changed instead of just once. 2024-09-13 13:09:00 +02:00
NEZNAMY 8a6014fd02 [Configuration] Add global-playerlist.update-latency adding to config converter 2024-09-13 12:33:09 +02:00
NEZNAMY dcc0fafe66 [Layout] Store properties separately and per layout and drop global properties map. This also fixes a theoretical memory leak if mass-switching to new layouts using the API. 2024-09-13 09:49:14 +02:00
NEZNAMY bc33679a1f [Velocity] Cache TextHolder instances for better performance 2024-09-11 19:22:07 +02:00
NEZNAMY d69efe76e5 [Fabric] Update to 24w37a 2024-09-11 18:26:37 +02:00
NEZNAMY 11babe4293 [BelowName] Fix text refresher not running in belowname thread 2024-09-10 20:55:34 +02:00
NEZNAMY 2ba7492f24 [Performance] Skip redundant check if team exists 2024-09-10 17:40:24 +02:00
NEZNAMY 6c65ffb701 [Error logging] Increase log size limit to 16MB from 1MB 2024-09-09 19:49:30 +02:00
NEZNAMY 864e30b3db [Bukkit] Fix direct NMS code check and split it per function (supported versions will start varying since 1.21.2) 2024-09-09 18:42:48 +02:00
NEZNAMY b9124ef873 [Performance] Micro optimization on Bukkit in Team packet 2024-09-09 18:03:33 +02:00
NEZNAMY 77165a5ffb [Performance] Micro optimization on Bukkit 2024-09-08 20:26:28 +02:00
NEZNAMY 54a519de0b [Layout] Use randomly generated property names for fixes slots instead of building them deterministically 2024-09-07 21:23:08 +02:00
NEZNAMY 462d38373f [Layout] Add API method for getting layout from config by name 2024-09-07 18:19:41 +02:00
NEZNAMY 44234422d0 [Performance] Use saved team/objective pointers instead of getting them from maps 2024-09-06 17:23:48 +02:00
NEZNAMY c71fcf51c1 [Velocity] Change checks for Scoreboard API access for better performance 2024-09-06 16:57:08 +02:00
NEZNAMY 33cc4b2aad [Fabric] Update to 24w36a 2024-09-04 17:59:30 +02:00
NEZNAMY 6485356c74 [Scoreboard] Use separate maps for scoreboard-related properties for faster access (also fix a theoretical memory leak if sending too many custom scoreboards with API) 2024-09-01 16:11:36 +02:00
NEZNAMY d0476a93ba [Wiki] Monthly wiki backup for September 2024 2024-09-01 10:07:12 +02:00
NEZNAMY 2eb3548008 [Performance] [BossBar] Store properties in a separate structure instead of using shared properties map 2024-08-31 15:51:13 +02:00
NEZNAMY 028a58c2ae [BungeeCord] Update to builds 1860+ (no longer works on older versions) 2024-08-29 19:10:25 +02:00
NEZNAMY 7675fc11b6 [Fabric] Fix wrong server version check 2024-08-29 19:08:03 +02:00
NEZNAMY 7a10a9e8f2 [Fabric] Remove redundant SneakyThrows annotations 2024-08-29 17:16:49 +02:00
NEZNAMY 8ee869830b [Fabric] Mark all recent supported snapshots as compatible 2024-08-29 16:53:58 +02:00
NEZNAMY 63ecd7b2a2 [Fabric] Move method to different module to reduce reflection usage 2024-08-29 16:44:24 +02:00
NEZNAMY a125076033 [Fabric] Update to 24w35a 2024-08-29 15:15:43 +02:00
NEZNAMY 12153f5783 [Wiki] Create wiki folder containing a backup of all wiki pages 2024-08-28 19:02:32 +02:00
NEZNAMY fdcec16181 [BungeeCord] Avoid sending UPDATE_LIST_ORDER tablist action to <1.21.2 players (#1359) 2024-08-25 20:09:25 +02:00
NEZNAMY 0c4d653921 [Fabric + Bukkit] Update to 24w34a (not tested) 2024-08-25 10:31:25 +02:00
NEZNAMY f488f18a55 Merge #1357 into v5 (Get skin from profile properties by property name) 2024-08-20 16:07:33 +02:00
NEZNAMY 6164dd8f5f [Performance] Change recursion to while loop 2024-08-18 15:14:33 +02:00
NEZNAMY 270062cfe4 [Code style] Remove redundant tablist tracking code 2024-08-16 16:34:33 +02:00
NEZNAMY 014e197a41 [Code style] Remove some redundancies 2024-08-14 19:25:03 +02:00
NEZNAMY bed587d6ba [Fabric] Split PermissionsAPI hook into a separate class 2024-08-14 19:10:02 +02:00
NEZNAMY c15934fdea [Configuration] Rework config loading (part 2) 2024-08-13 19:45:28 +02:00
NEZNAMY 385516f373 [Configuration] Fix bossbar order not being preserved 2024-08-12 18:29:29 +02:00
NEZNAMY c50f5e7728 [Configuration] Fix bossbar progress config loading 2024-08-12 18:25:50 +02:00
NEZNAMY 494bd7368d [Configuration] Fix config loading running before conversion 2024-08-11 08:38:36 +02:00
NEZNAMY b6e8f4c1a7 [Code style] Store TabList, BossBar and Scoreboard instances in TabPlayer object instead of each implementation 2024-08-10 21:15:06 +02:00
NEZNAMY 392e97df2c [Configuration] Fix global playerlist config loading 2024-08-10 21:07:13 +02:00
NEZNAMY 45dbd8c4b2 [Bukkit] Add 1.21.1 to list of versions supported by paper hook 2024-08-10 19:08:38 +02:00
NEZNAMY a0ac7d3324 [Code style] Change fields in TabFeature into getters and fix some annotations 2024-08-10 18:03:27 +02:00
NEZNAMY 4dd7ce5b98 [Configuration] Rework config loading and add a lot more checks (part 1) 2024-08-10 17:11:01 +02:00
NEZNAMY 1a96101672 Update to 1.21.1 2024-08-10 09:57:50 +02:00
NEZNAMY 88f40ab457 [BossBar] Fix ConcurrentModificationException (#1350) 2024-08-08 16:21:53 +02:00
NEZNAMY 70403042d2 [Layout] Fix API usage causing placeholders to not refresh 2024-08-06 17:56:58 +02:00
NEZNAMY ff5a9fa3a9 [Bukkit] Add null check for non-null field because other plugins can make it null 2024-07-28 11:14:36 +02:00
NEZNAMY 5ead664cf9 Update README.md 2024-07-27 23:02:01 +02:00
NEZNAMY bba2b6f2e8 [Code style] Remove redundant check that will never pass 2024-07-27 17:40:31 +02:00
NEZNAMY 4b25571e1a [Code style] Clean up property loading 2024-07-27 16:47:18 +02:00
NEZNAMY 407d0eaeac [Velocity] Ask people to install VelocityScoreboardAPI 2024-07-27 14:53:50 +02:00
NEZNAMY 05bb3a5fa9 [Code style] Make skin downloading return Skin instead of List<String> 2024-07-27 12:16:36 +02:00
NEZNAMY 714a72c849 Merge pull request #1335 from qdpy/v5
Add a signed_texture skin parameter to avoid an API call
2024-07-27 12:00:34 +02:00
NEZNAMY 9ba8f149f7 [Code style] Remove unused method 2024-07-27 10:23:29 +02:00
NEZNAMY c9bb38c036 [Scoreboard] Add misconfiguration check if scoreboard has more than 15 lines defined 2024-07-26 19:01:19 +02:00
NEZNAMY 3241f1cf41 [Sorting] Fix sorting placeholder using old instance when a placeholder is overridden 2024-07-25 21:01:47 +02:00
NEZNAMY 8a7099a6ab [BungeeCord] Add try/catch for yet another NPE in BungeeCord code 2024-07-25 15:57:25 +02:00
NEZNAMY 65c6adcdb2 [Bukkit] Fix compatibility with random modded server 2024-07-22 19:27:42 +02:00
evlad f3f2e69bcf prevent AIOOB exeception 2024-07-16 06:19:29 +03:00
qdpy 335f0a3d6f Add skin signed texture 2024-07-16 03:52:26 +02:00
NEZNAMY a7e711850c [Performance] Use Map#put return type to get rid of Map#get 2024-07-14 12:28:20 +02:00
NEZNAMY 6fb2a7ce76 [Performance] Switch to ConcurrentHashMap instead of synchronizing a map 2024-07-14 11:59:17 +02:00
NEZNAMY 56a6e34847 [Fix] Wrong boolean value from previous commit 2024-07-11 17:23:48 +02:00
NEZNAMY cfa4c869ca [Code style] Clean up task executing and fix mistakes from previous recodes 2024-07-10 21:38:51 +02:00
NEZNAMY d548fbcb74 [Technical] Remove a layer of task wrapping 2024-07-08 19:20:56 +02:00
NEZNAMY d40fbced1a [Performance] [NameTags] Skip containsTeam call 2024-07-08 19:05:39 +02:00
NEZNAMY 21c251b40b [Performance] Avoid redundant StructuredComponent creation when converting RGB colors to legacy in scoreboard 2024-07-07 21:30:51 +02:00
NEZNAMY ec3371085b [Performance] Avoid double map access on team/objective register 2024-07-07 15:56:49 +02:00
NEZNAMY 3779f38c5d [Playerlist Objective] [Performance] Avoid performing unnecessary operations on disable condition change 2024-07-07 15:46:58 +02:00
NEZNAMY 5b62fe2be7 [BelowName] [Performance] Avoid performing unnecessary operations on disable condition change 2024-07-07 15:40:42 +02:00
NEZNAMY ea223bbcb4 [Performance] Avoid double access to placeholder map 2024-07-07 11:17:09 +02:00
NEZNAMY 7f4a56149a [Placeholders] Make one more method synchronized to prevent incorrect re-register that breaks the placeholder on concurrent access 2024-07-06 21:51:02 +02:00
NEZNAMY 52a620c479 [Placeholders] Make methods synchronized to fix concurrent access potentially breaking some placeholders 2024-07-06 21:38:05 +02:00
NEZNAMY 593aaf8039 [Conditions] Avoid re-registering the same placeholder multiple times 2024-07-06 21:11:04 +02:00
NEZNAMY cebb6ea626 [NameTags] Register visibility refresher subfeature in constructor to prevent issues in placeholder updating when registering the placeholder 2024-07-06 21:02:30 +02:00
NEZNAMY 337dc1c4d5 [Technical] Decode plugin messages in a new separate thread 2024-07-06 19:30:20 +02:00
NEZNAMY e110f942e8 [Scoreboard] Add misconfiguration check for invalid scoreboard properties and improve code for existing features 2024-07-06 16:49:24 +02:00
NEZNAMY 6bd5f9dab1 [Error logging] Print warns when receiving redis message of unknown player and add some debug messages 2024-07-03 21:22:45 +02:00
NEZNAMY 09149c559d [Code style] Add missing NotNull annotation 2024-06-30 21:28:42 +02:00
NEZNAMY f9a1130e4b [Performance] Make some placeholders on proxy trigger-based instead of periodic refreshing 2024-06-29 15:43:44 +02:00
NEZNAMY 91304233aa [Code style] Finish getting rid of global component cache 2024-06-29 14:07:52 +02:00
NEZNAMY 99286578c1 [Code style] Create separate component cache for layout fixed slots 2024-06-29 13:43:07 +02:00
NEZNAMY 81888d9aa5 [Code style] Avoid creating simple components in some cases 2024-06-28 21:50:23 +02:00
NEZNAMY f2e4b1b94a [Debug] Add message showing how long it took to unregister teams, objectives and bossbars on unload 2024-06-28 11:26:36 +02:00
NEZNAMY ab269ad740 [Code style] Dynamically remove player boss bars on unload instead of calculating them inside the feature 2024-06-28 10:44:36 +02:00
NEZNAMY 5a1df75526 [Fix] Forcefully shutdown thread executor after it failed to shut down softly 2024-06-27 21:28:12 +02:00
NEZNAMY b74ed1d14e [Code style] Unregister all teams and objectives dynamically instead of in every feature separately and calculating all logic. Can't believe it took me years to come up with this. 2024-06-27 21:24:33 +02:00
NEZNAMY d087db38e3 [Bug fix] Update disable condition status in feature's thread 2024-06-27 21:08:21 +02:00
NEZNAMY ff8c406823 [Velocity] Avoid errors in VelocityScoreboardAPI hook by handling unexpected situations 2024-06-27 15:33:13 +02:00
NEZNAMY 7e12a75bea [Technical] Include thread name in error message if it failed to shut down 2024-06-27 15:27:40 +02:00
NEZNAMY aa7fb09399 [Teams] Fix vanish status change processing not respecting disable condition 2024-06-27 14:40:07 +02:00
NEZNAMY a805b3fe90 [Bukkit] Mark Paper 1.21 as compatible with direct NMS code 2024-06-27 11:06:13 +02:00
NEZNAMY 63d9122440 [Bossbar] Fix bars being resent on server switch even for <1.20.2 players 2024-06-27 10:54:38 +02:00
NEZNAMY f9293c9c92 [Bug fix] Unregister teams of redis players on unload 2024-06-26 16:11:44 +02:00
NEZNAMY 4892fd5817 [Error fix] Fix async features sometimes still using global onlinePlayers array 2024-06-26 14:37:25 +02:00
NEZNAMY cf4a8ae98d [Error fix] Add check for null team name for redis players (temporarily?) 2024-06-26 14:32:24 +02:00
NEZNAMY f0edfeeebf [Error fix] Add try/catch for RedisBungee message sending 2024-06-26 14:28:50 +02:00
NEZNAMY 4d54ad35ff [Bug fix] Colors not displaying correctly in Fabric and Velocity console 2024-06-26 14:13:46 +02:00
NEZNAMY b6b512f788 Merge pull request #1324 from Miyli/v5
[GitHub] Add build number to artifact
2024-06-25 18:02:00 +02:00
Miyli a6076eb6ac [GitHub] Add build number to artifact 2024-06-25 17:40:20 +02:00
NEZNAMY 01b74f0a6e [Bug fix] Unload features in main thread and wait for tasks to shut down to prevent unloading and loading at the same time on reloads 2024-06-25 15:37:40 +02:00
NEZNAMY 6c6752c348 [Velocity] Introducing: Velocity Scoreboard API 2024-06-25 15:10:40 +02:00
NEZNAMY 73873ac193 [Performance] Remove synchronized modifier from method 2024-06-25 14:20:23 +02:00
NEZNAMY 6542dad7bd [Bug fix] Fix synchronized deadlock in placeholder refreshing 2024-06-24 14:16:16 +02:00
NEZNAMY 9bf4a2b555 [Code style] Add and use Scoreboard#renameTeam method 2024-06-21 13:53:06 +02:00
NEZNAMY 66d18a4469 [Code style] Expose Scoreboard#containsTeam method in interface 2024-06-21 13:40:23 +02:00
NEZNAMY 7a489067e6 [NameTags] Fix unregistering and registering team on rename even for players who should not see the team because player is vanished 2024-06-20 22:27:37 +02:00
NEZNAMY 600d6de132 [Code style] Reduce access level of methods 2024-06-20 19:11:02 +02:00
NEZNAMY 48e35e7abd [Performance] Split Header and Footer caches as the values are practically never the same 2024-06-20 14:30:09 +02:00
NEZNAMY 8613e9d734 [Error fix] Add try/catch for PremiumVanish hook 2024-06-20 14:25:50 +02:00
NEZNAMY 9ed277d80d [Error fix] Make methods synchronized to avoid ConcurrentModificationException 2024-06-20 13:44:16 +02:00
NEZNAMY 26345d00a3 [Code style] Clean up method calls 2024-06-20 13:00:57 +02:00
NEZNAMY be70eea0f8 [Performance] [Global playerlist] Add option to disable latency refreshing and disable it by default 2024-06-20 12:14:06 +02:00
NEZNAMY 01357d9ce4 [Sorting] Fix NPE 2024-06-19 17:40:06 +02:00
NEZNAMY 05afafbc45 [Performance] [Global playerlist] Create object for server groups to compare identity instead of having to do heavy checks (also save spy-server status for fast access) 2024-06-18 19:25:55 +02:00
NEZNAMY 68f7272128 [Bug fix] Make plugin message encoding thread shared and don't shut it down, which caused scoreboard packets to not get sent fully on reload, resulting in "Network Protocol Error" on 1.20.5+ 2024-06-18 17:28:40 +02:00
NEZNAMY caa0ab723a [Code style] Reduce calls to "refresh" method in features 2024-06-18 16:40:47 +02:00
NEZNAMY ee0d6002c8 [Code style] Forward group change into features with a new method specifically for that purpose instead of refresh method 2024-06-18 16:30:03 +02:00
NEZNAMY 48f0d04305 [Performance] Only send tablist update packet once for connected player 2024-06-18 15:24:12 +02:00
NEZNAMY 6516b80bf0 Fix error from previous commit 2024-06-18 14:30:45 +02:00
NEZNAMY b0403ff94b [GitHub] Update build.yml dependencies 2024-06-18 14:23:07 +02:00
NEZNAMY 77f88edf08 [Performance] Submit feature refresh task only once instead of once for every player 2024-06-18 14:10:07 +02:00
NEZNAMY be70664c84 [Performance] Use method reference to avoid new lambda instantiation each time 2024-06-18 12:55:27 +02:00
NEZNAMY 37ca992233 [Performance] Store component flat text instead of calculating it each time 2024-06-18 12:42:57 +02:00
NEZNAMY 620904de1c [Performance] Store last placeholder values inside player with placeholder key instead of placeholder with player key 2024-06-18 12:19:33 +02:00
NEZNAMY 9c0fac5c44 [Performance] [BossBar] Store visible boss bars of a player for fast access 2024-06-18 11:48:36 +02:00
NEZNAMY 8846c5a9fe [Performance] [NameTags] Only initialize set if used 2024-06-18 11:14:18 +02:00
NEZNAMY 880d2a8570 [PremiumVanish hook] Make methods synchronized to fix ConcurrentModificationException 2024-06-18 10:18:02 +02:00
NEZNAMY 45b6591518 [API Break] Require placeholders to return String instead of Object 2024-06-17 20:48:09 +02:00
NEZNAMY c6ce99d527 [Code style] Remove redundant SneakyThrows 2024-06-17 20:45:13 +02:00
NEZNAMY 7a7861fd9c [Performance] [Bukkit] Only set field if value actually changed 2024-06-17 20:10:00 +02:00
NEZNAMY 3c11630a6c [Code style] Simplify 2024-06-17 15:50:51 +02:00
NEZNAMY 3b9f4c9884 [RedisBungee] Recode handling of sub-features and small fixes (#1317?) 2024-06-17 15:00:08 +02:00
NEZNAMY 0757fc4352 [RedisBungee] Fix error (#1317) 2024-06-17 10:54:27 +02:00
NEZNAMY c1af721ad2 [NameTags] Properly update online players 2024-06-16 21:17:29 +02:00
NEZNAMY 0ea04394f9 [RedisBungee] Override %serveronline% to count redis players as well (#1316) 2024-06-16 20:09:34 +02:00
NEZNAMY 576c178b4f [NameTags] Move the feature handling to a new custom thread 2024-06-16 19:05:58 +02:00
NEZNAMY 674708cea6 [Playerlist objective] Fix error 2024-06-16 16:54:45 +02:00
NEZNAMY 179b05f992 [Belowname] Fix error 2024-06-16 16:53:26 +02:00
NEZNAMY e2c768bb56 [Performance] Speed up all placeholders returning int by caching string values 2024-06-16 15:10:57 +02:00
NEZNAMY 79e492b230 [Performance] Speed up %gamemode% placeholder 2024-06-16 14:40:07 +02:00
NEZNAMY 708bc5c302 [Global playerlist] Fix error in placeholder before it's loaded 2024-06-16 13:44:19 +02:00
NEZNAMY 9543cd5b5f [Performance] Access player's world and server variables directly instead of via getter 2024-06-16 12:49:56 +02:00
NEZNAMY 0bc8313897 [Technical] Move global playerlist feature handling to a new custom thread 2024-06-16 12:22:30 +02:00
NEZNAMY 91986926cb [Performance] Avoid redundant text color attempt 2024-06-15 17:34:07 +02:00
NEZNAMY ac638add7a [Performance] [Paper] Only rewrite packet if something changed 2024-06-15 15:58:30 +02:00
NEZNAMY 9551783d49 [Performance] [NameTags] Avoid calculating other team properties when changing visibility rule 2024-06-15 15:00:22 +02:00
NEZNAMY 85cf2b3e91 [Performance] [NameTags] Avoid calculating other team properties when changing collision rule 2024-06-15 14:25:05 +02:00
NEZNAMY f98ccb9e44 [Performance] [NameTags] Avoid calculating nametag visibility when only updating prefix/suffix 2024-06-15 13:54:56 +02:00
NEZNAMY 066d50e492 [Performance] Save LuckPerms User object instead of getting it on every request 2024-06-15 12:58:21 +02:00
NEZNAMY 6c823e86fe [Performance] [Scoreboard] Check player's active scoreboard instead of set of players who can see the scoreboard 2024-06-15 12:16:13 +02:00
NEZNAMY 6d3ea577d5 [Error fix] Make method synchronized to avoid ConcurrentModificationException 2024-06-15 11:29:21 +02:00
NEZNAMY 2826e39ea2 [Code style] Make paper a submodule of bukkit 2024-06-15 09:58:48 +02:00
NEZNAMY d855f04612 [Performance] [Fabric] Save enum values in an array for fast access 2024-06-14 23:27:25 +02:00
NEZNAMY 99eb93e66f [Performance] [Bukkit] Add native NMS implementations on 1.20.5+ Paper (where mojang mappings are used) 2024-06-14 23:24:52 +02:00
NEZNAMY e91110d049 [Performance] Avoid double map access 2024-06-14 19:45:44 +02:00
NEZNAMY 8e1bb8519c [Performance] [Bukkit] Save PlayerConnection for sending packets instead of getting it using reflection each time 2024-06-14 19:12:09 +02:00
NEZNAMY 61df01ed1c [Performance] Massively boost last color of prefix getting, also remove cache and save it inside the component 2024-06-14 18:38:15 +02:00
NEZNAMY c219aa83b1 [Code style] Remove unused imports 2024-06-14 15:26:03 +02:00
NEZNAMY 71109b397d [Code style] Remove redundant initialization 2024-06-14 15:23:42 +02:00
NEZNAMY 4fe4c2981d [Code style] Add NotNull annotation 2024-06-14 15:15:16 +02:00
NEZNAMY 2f9f2f722c [Code style] Add NotNull annotation 2024-06-14 15:06:33 +02:00
NEZNAMY 40009d018c [Code style] Clean up code by passing Objective parameter instead of its values 2024-06-14 15:03:29 +02:00
NEZNAMY 251480fd4a [MiniMessage] Add dummy character to parsed text to disable color compacting (#1312) 2024-06-14 14:23:42 +02:00
NEZNAMY 6295145d5b [Scoreboard] Disable check to fix error on reload 2024-06-14 12:09:26 +02:00
NEZNAMY 17f2e67334 [Code style] Construct platform's team immediately to avoid nullability warn 2024-06-14 11:50:39 +02:00
NEZNAMY fe4130a846 [Bukkit] Fix text cutting not considering client version (#1313) 2024-06-14 10:52:57 +02:00
NEZNAMY 141201b7aa [Sponge 7] Add missing text cutting to 32 characters 2024-06-13 21:39:50 +02:00
NEZNAMY 3b3c511572 Change build.yml to use v5 branch 2024-06-13 21:15:10 +02:00
NEZNAMY 8c6cf8ee22 Add 1.21 support 2024-06-13 21:14:05 +02:00
NEZNAMY 231fd36ce9 [Performance] Save FixedFormat across all platforms and store it inside TabComponent class to reduce need for a cache 2024-06-12 20:50:13 +02:00
NEZNAMY fb9dd0a899 [Code style] Extend class to avoid code duplication 2024-06-12 20:02:50 +02:00
NEZNAMY d98bcdb4e8 [Fix] Concurrent access to online players causing features to try to work with players before loading them 2024-06-12 19:15:33 +02:00
NEZNAMY f94a87e6d5 [Performance] Use more efficient caching of last team prefix color 2024-06-12 17:39:30 +02:00
NEZNAMY 1501d5e71e [Performance] Store serialized json of a component inside of it instead of using a cache 2024-06-12 17:24:16 +02:00
NEZNAMY a7d955266d [Code style] Make cache efficiency calculation more accurate 2024-06-12 17:08:01 +02:00
NEZNAMY 9633a6c176 [Code style] Make cache efficiency calculation more accurate 2024-06-12 17:04:33 +02:00
NEZNAMY 9d50090dbd [Performance] Create separate component caches for scoreboard and nametags 2024-06-12 17:02:50 +02:00
NEZNAMY 8b96a8e654 [Performance] Add missing caching for Redis sub-features 2024-06-12 14:15:54 +02:00
NEZNAMY 453288bf77 [Performance] Convert text to TabComponent in BossBar immediately and cache it 2024-06-12 14:08:59 +02:00
NEZNAMY 26fb0ec2e9 [Performance] Split component caches for some features as they usually never share the same inputs across features, reducing efficiency 2024-06-12 13:53:03 +02:00
NEZNAMY 2671052cad [Code style] Remove redundant SneakyThrows 2024-06-11 22:08:20 +02:00
NEZNAMY 7f1bcd69c8 [Code style] Save platform's scoreboard teams and objectives inside TAB's classes for fast access 2024-06-11 21:23:18 +02:00
NEZNAMY 5fe83af514 [Fix] Make scoreboard methods synchronized to prevent values not getting saved when accessing from multiple threads (despite being concurrent) 2024-06-11 21:12:54 +02:00
NEZNAMY 89dc2f09fc [Fix] Make player properties ConcurrentHashMap to fix issues with parallel access 2024-06-11 20:53:15 +02:00
NEZNAMY 7ce564409a [Fix] Disable instance activity check as internals were accidentally triggering it, especially with parallel processing 2024-06-11 18:32:05 +02:00
NEZNAMY 2e34069d14 [Fix] Add "synchronized" to method to fix concurrent access error 2024-06-11 18:27:21 +02:00
NEZNAMY e435501501 [Sorting] Fix sorting by pre-defined values space trimming inconsistency 2024-06-11 15:38:38 +02:00
NEZNAMY 51402637c6 [Fabric] Update to 1.21-rc1 2024-06-10 16:29:25 +02:00
NEZNAMY 44593f7a75 [Code style] Create custom thread executor class for easier usage 2024-06-10 14:10:27 +02:00
NEZNAMY 48596efa77 [Technical] Process Belowname and Playerlist Objective feature in a separate custom thread 2024-06-10 13:10:11 +02:00
NEZNAMY 3e323df70d [Fix] Process Header/Footer disable condition change in its own thread 2024-06-10 11:01:50 +02:00
NEZNAMY 0d89cef519 [Technical] Process SpectatorFix feature in a separate custom thread 2024-06-09 13:00:03 +02:00
NEZNAMY f758fdf8f3 [Code style] Create runnables instead of using lambdas for cleaner stack traces 2024-06-09 12:43:15 +02:00
NEZNAMY 44b9f06087 [Technical] Process Scoreboard feature in a separate custom thread 2024-06-09 12:12:22 +02:00
NEZNAMY d1155d5e7a [Fabric] Update to 1.21-pre4 2024-06-07 18:39:15 +02:00
NEZNAMY 51ccd029ca [Layout] Fix feature attempting to format tablist names of players who have them disabled with condition 2024-06-07 15:26:48 +02:00
NEZNAMY 1df83dac91 [Fix] RejectedExecutionException in feature threads on reload 2024-06-07 14:49:21 +02:00
NEZNAMY a3c1d643fd [Fix] Refresh call not being called in feature's thread 2024-06-07 14:05:21 +02:00
NEZNAMY 4350e311e7 [Fix] Throwables not being logged when thrown thrown in new threads 2024-06-07 13:48:39 +02:00
NEZNAMY 89ec9355bd [Technical] Process PingSpoof feature in a separate custom thread 2024-06-07 12:15:58 +02:00
NEZNAMY f2be7220f3 [Layout] Send fake ping if ping spoof is enabled immediately instead of having to rewrite it 2024-06-07 12:05:08 +02:00
NEZNAMY 0cbac252a5 [Technical] Process BossBar feature in a separate custom thread 2024-06-07 11:43:16 +02:00
NEZNAMY 3ea60971be [Fix] ConcurrentModificationException on high player counts 2024-06-06 22:09:48 +02:00
NEZNAMY 8ea76e2016 [Technical] Create Runnables instead of using lambdas for cleaner stack traces 2024-06-06 22:01:02 +02:00
NEZNAMY 86d2d732eb [BungeeCord] Fix NPE in packet reader 2024-06-06 18:15:08 +02:00
NEZNAMY 55ce84a5ae [Technical] Process Header/Footer in a separate custom thread (and prepare other features) 2024-06-06 18:07:40 +02:00
NEZNAMY 0f0e4de682 [Code style] Replace forEach with for loop for shorter stack traces 2024-06-06 14:54:20 +02:00
NEZNAMY ad60372cf2 [Error handling] Properly print errors if thrown in recently added threads 2024-06-06 14:29:42 +02:00
NEZNAMY 3cf5fd7cbd [Technical] Run plugin message encode and send in a new custom thread 2024-06-06 13:48:18 +02:00
NEZNAMY ce090566cc [Technical] Run tablist entry anti-override task in a new custom thread 2024-06-05 22:19:58 +02:00
NEZNAMY 866f645eed [Code style] Replace forEach with for loop for shorter stack traces 2024-06-05 22:17:35 +02:00
NEZNAMY 64f3bebd3d [Fabric] Update to 1.21-pre3 2024-06-05 15:50:49 +02:00
NEZNAMY 239cc461d5 [Code style] Use shorter alternative 2024-06-05 11:28:57 +02:00
NEZNAMY b832784977 [Code style] Refactor pipeline injection on BungeeCord 2024-06-05 11:09:59 +02:00
NEZNAMY 0f37b0be54 [RedisBungee] Add config option for disabling RedisBungee hook 2024-06-03 17:10:11 +02:00
NEZNAMY bb428af3af [Configuration] Add another misconfiguration check 2024-06-03 11:37:03 +02:00
NEZNAMY 1c4d9704f2 [Commands] Fix error when setting property value to ' or " 2024-06-01 16:48:24 +02:00
NEZNAMY 53a5eae721 [Fabric] Update to 1.21-pre2 2024-05-31 20:45:42 +02:00
NEZNAMY 049ab257e2 [Placeholders] Fix server placeholders not returning proper value on request sometimes 2024-05-30 16:28:38 +02:00
NEZNAMY 0ece5319ea [Fabric] Update to 1.21-pre1 2024-05-29 20:32:10 +02:00
NEZNAMY b847cc1178 [Teams] [Bukkit] Fix team action not being taken correctly on 1.8 - 1.12, causing issues with previous commit 2024-05-29 13:36:22 +02:00
NEZNAMY 422da3e1ba [Commands] Fix error in debug command 2024-05-28 14:52:40 +02:00
NEZNAMY 868c6baebf [Teams] Fix another instance of "Network Protocol Error" disconnect on 1.20.5+ 2024-05-28 14:27:47 +02:00
NEZNAMY 9a3cf167ed [Performance] Change way placeholder values are stored in plugin's PlaceholderAPI expansion for better performance 2024-05-27 22:46:10 +02:00
NEZNAMY cdf47ebab0 [Visuals] Refresh permission groups in another thread (also split its CPU usage tracking to 2 parts) 2024-05-27 22:06:00 +02:00
NEZNAMY 929d1f945b [Code style] Replace try/catch with SneakyThrows 2024-05-27 15:46:01 +02:00
NEZNAMY 2671242d2c [Code style] Remove duplicate class mapping 2024-05-27 14:25:34 +02:00
NEZNAMY 78cff8dea8 [Bukkit] Add support for latest 1.21 snapshot 2024-05-27 13:43:32 +02:00
NEZNAMY 7ac3840831 [Javadoc] Fix typo 2024-05-27 13:42:51 +02:00
NEZNAMY 556ee6df01 [Sorting] Make number padding correct (may rarely only insert 1 character) 2024-05-26 12:48:28 +02:00
NEZNAMY 2eca28e497 [Sorting] Fix number compression bug (#1297) 2024-05-26 12:37:35 +02:00
NEZNAMY 76ff5d49e2 [Code style] Simplify array creation 2024-05-25 21:50:43 +02:00
NEZNAMY 2a919aa6b7 [Performance] Fix Header/Footer components not being cached on some platforms from recent commits 2024-05-25 14:21:12 +02:00
NEZNAMY c83f806e4c [Code style] Store expected TabList display names by UUID instead of TabPlayer 2024-05-25 14:07:50 +02:00
NEZNAMY afbfd38dfd [Bukkit] Add back fallback solutions for Scoreboards using Paper API and Bukkit API 2024-05-23 13:51:11 +02:00
NEZNAMY 6874916ce0 [Javadoc] Update class description 2024-05-23 13:10:39 +02:00
NEZNAMY 143c4fc7e4 [Code style] Remove expected header/footer tracking, since it's not used anyway (for now) 2024-05-23 13:04:49 +02:00
NEZNAMY f85e945a32 [Bukkit] Fix compatibility wih Mojang mapped servers jars 2024-05-22 21:21:24 +02:00
NEZNAMY d0110c9a4f [Fabric] Update to 24w21b 2024-05-22 20:54:15 +02:00
NEZNAMY 4307768bee [Code style] Split TabList class into an interface and abstract class 2024-05-22 20:24:59 +02:00
NEZNAMY 88773e3232 [BossBar] Fix error when trying to display bossbar that was not visible on join 2024-05-22 10:14:06 +02:00
NEZNAMY 8f32772f83 Add TODO 2024-05-21 18:09:02 +02:00
NEZNAMY 17b3c28d91 [Performance] Only track placeholder usage if cpu tracking is enabled 2024-05-21 17:58:34 +02:00
NEZNAMY 45945d9a13 [Sponge 8] Add 1.20.6 support 2024-05-21 16:57:45 +02:00
NEZNAMY ba9741a084 [Code style] Split Scoreboard class into and interface and abstract class with tracking, also resend content on server switch using tracked values instead of from each feature individually 2024-05-21 16:04:35 +02:00
NEZNAMY 3bcad371d2 [Code style] Create a class for BossBar managing all safety checks and extend it in all implementations and resend them on server switch internally instead of using bossbar feature itself 2024-05-20 22:06:49 +02:00
NEZNAMY 1e9bf68671 [BossBar] Fix Network Protocol Error disconnect on server switch 2024-05-20 12:37:31 +02:00
NEZNAMY f57df6a536 [BossBar] Make %countdown% return 0 after announcement is over instead of going to negative numbers 2024-05-20 11:18:44 +02:00
NEZNAMY 793536d2d3 [Fix] Fix typo 2024-05-18 18:18:00 +02:00
NEZNAMY 9a348da34f [Code style] Simplify 2024-05-18 17:45:03 +02:00
NEZNAMY 4819bf63b6 [Bukkit] Add back fallback solutions for Header/Footer using Paper API and Bukkit API if NMS fails to load 2024-05-18 17:32:43 +02:00
NEZNAMY 5777d49861 [Performance] [Bukkit] Use Adventure API for BossBars if available for massively improved performance 2024-05-18 12:28:46 +02:00
NEZNAMY 7540c61fde [Code style] Create fields for adventure components from TAB component to allow multiple options in the future 2024-05-18 11:57:59 +02:00
NEZNAMY 308da4cbac [Code style] Create field for feature name and define it in constructor instead of creating abstract functions 2024-05-17 22:17:11 +02:00
NEZNAMY 615af41de8 [Performance] Return placeholder values as strings to prevent boxing objects being created 2024-05-17 20:24:46 +02:00
NEZNAMY 7c473a4e3f [Performance] Change functional interface usage to avoid int -> Integer boxing 2024-05-17 18:58:03 +02:00
NEZNAMY 79b4f9821b [Performance] Add cooldown to player vanish check 2024-05-17 17:23:16 +02:00
NEZNAMY 80825ee701 [Code style] Mark fields of class as NonNull 2024-05-17 16:51:09 +02:00
NEZNAMY aa0e60b091 [Fix] Fix startup error caused by one of the previous commits 2024-05-17 16:50:49 +02:00
NEZNAMY 718cfb682d [Code style] Improve readability of some sorting functions (also probably fix sorting API not working in layout) 2024-05-17 12:49:02 +02:00
NEZNAMY 66f0426e6a [Code style] Remove unused method 2024-05-17 12:25:55 +02:00
NEZNAMY 145671ecdd [Code style] Remove unused methods 2024-05-17 12:22:08 +02:00
NEZNAMY 43d71f7e49 [Code style] Remove unused import 2024-05-17 12:20:26 +02:00
NEZNAMY 150de771d5 [Code style] Initialize map values in construction instead of creating anonymous class 2024-05-17 12:20:16 +02:00
NEZNAMY 50da728abf [Code style] Remove redundant checks 2024-05-17 11:05:28 +02:00
NEZNAMY 656ce6ecad [Performance] Create player data classes for Tablist formatting and teams to avoid Map lookup each time 2024-05-17 11:01:54 +02:00
NEZNAMY 8a758dffec [Performance] Create player data class for Belowname to avoid Map lookup each time 2024-05-16 21:14:07 +02:00
NEZNAMY 52bd538ed0 [Performance] Create player data class for Playerlist objective to avoid Map lookup each time 2024-05-16 20:58:49 +02:00
NEZNAMY 115c5ac890 [Bug fix] Fix disabled tablist formatting referencing wrong variable 2024-05-16 20:43:46 +02:00
NEZNAMY 0f7d15a4d0 [Performance] Create player data class for Header/Footer to avoid Map lookup each time 2024-05-16 20:39:04 +02:00
NEZNAMY 5b6e07d5d3 [Fabric] Update to 24w20a 2024-05-15 17:22:15 +02:00
NEZNAMY 8579ed322d [Code style] Remove redundant class wrapper for a Map 2024-05-15 15:19:53 +02:00
NEZNAMY 44464b605d [Fabric] Replace Minecraft version check with fabric networking api check (which is what is preventing the mod from working there) 2024-05-14 11:30:08 +02:00
NEZNAMY e8124dd280 [Fabric] Replace Fabric API call with direct NMS call 2024-05-13 22:25:19 +02:00
NEZNAMY 0105fc2087 [Fabric] Remove unused field 2024-05-12 14:10:28 +02:00
NEZNAMY 39e7b26128 [Fabric] Remove entity packets from access widener 2024-05-12 14:05:58 +02:00
NEZNAMY ddbc13fc27 [Scoreboard] Remove respect-other-plugins config option, it is now forced 2024-05-12 13:57:15 +02:00
NEZNAMY 80660fa6cf [Performance] Small optimization of scoreboard packet processing 2024-05-12 13:16:52 +02:00
NEZNAMY b4a94e8da5 [Code style] Remove unused method 2024-05-12 12:34:32 +02:00
NEZNAMY 051c9a8c85 [BossBar] Add console warn if used color or style is invalid 2024-05-12 12:27:28 +02:00
NEZNAMY 840b1ea4a2 [Code style] Remove unused field 2024-05-12 11:32:14 +02:00
NEZNAMY ea57695a31 [Fix] Remove forgotten references to deleted unlimited nametag feature 2024-05-12 11:28:49 +02:00
NEZNAMY 90778bc84c Merge branch 'master' into v5 2024-05-11 21:31:45 +02:00
NEZNAMY 949216325f [Nametags] Only make nametags of invisible players invisible for 1.8 players to compensate for the bug instead of everyone (#1287) 2024-05-11 21:29:55 +02:00
NEZNAMY cdb521de1f [BungeeCord] Initialize different BossBar instance for 1.8 players to avoid version check every time 2024-05-11 17:01:49 +02:00
NEZNAMY e50b39c559 [Javadoc] Document more methods 2024-05-11 14:36:01 +02:00
NEZNAMY 80afb497e0 [Code style] Remove unused field 2024-05-11 13:34:53 +02:00
NEZNAMY e83a12aaee [Fabric] Mark 1.17 as supported again 2024-05-11 13:24:12 +02:00
NEZNAMY 461860bb17 Delete unlimited nametag and wither bossbar features 2024-05-11 13:22:00 +02:00
NEZNAMY cff4e3e6b0 5.0.0-SNAPSHOT 2024-05-11 12:20:46 +02:00
NEZNAMY dddf0b35a2 [Code style] Add missing access level to field 2024-05-11 11:43:51 +02:00
NEZNAMY 35ec2bf215 [Code style] Make fields final 2024-05-11 11:43:05 +02:00
NEZNAMY 607b60b323 [Code style] Remove unused method 2024-05-11 11:41:35 +02:00
NEZNAMY bb6ad72962 [Code style] Improve presence check of Player#getPing method 2024-05-10 17:05:47 +02:00
NEZNAMY 4fb8420d69 [Code style] Remove unused method 2024-05-10 16:59:11 +02:00
NEZNAMY 74af19a9d9 [Code style] Move field to a local variable 2024-05-10 16:53:51 +02:00
NEZNAMY 737ac70e6e [Fabric] Update to 24w19a 2024-05-10 16:28:39 +02:00
NEZNAMY bfc72b735c [Fabric] Add another submodule for 1.18.2 to avoid hardcoding method and class names 2024-05-10 16:05:09 +02:00
NEZNAMY 323412f935 [Code style] Decrease field visibility 2024-05-10 14:56:00 +02:00
NEZNAMY db34ba4995 [Fabric] Improve check for Fabric API features availability 2024-05-10 14:54:01 +02:00
NEZNAMY 15d7eb6d91 [Javadoc] Document more methods 2024-05-10 14:50:02 +02:00
NEZNAMY e2b95df2e4 [Bukkit] Explicitly specify constructor to fix compatibility with forge mods that widen a constructor access, causing TAB to choose the wrong one on 1.19.3+ (#1276) 2024-05-10 13:42:50 +02:00
NEZNAMY 1117094412 [Bug fix] Update library to fix error 2024-05-09 14:54:46 +02:00
NEZNAMY 4bab076642 [Bug fix] Fix group change from Bridge not being processed correctly (#1281) 2024-05-09 13:38:36 +02:00
NEZNAMY d602818f67 [Bug fix] Disable tablist containsEntry usage due to a race condition that sometimes makes it not work properly until a better solution is found (#1284) 2024-05-08 09:37:35 +02:00
NEZNAMY 1a76321062 [Fabric] Update to 24w18a 2024-05-04 20:37:08 +02:00
NEZNAMY 4b056529dd [Fix] Add cpu usage of placeholders inside plugin's main thread instead of placeholder thread to avoid incorrect numbers when it's overloaded 2024-05-04 20:29:21 +02:00
NEZNAMY bdbf3ba5b1 [Velocity] Remove message printing if attempting to send plugin message to a player who is not connected to any server (#1248) 2024-05-03 22:35:29 +02:00
NEZNAMY aab9a650b0 Fix startup error when using a plugin that shades MiniMessage without shading component serializers (#1280) 2024-05-03 14:47:25 +02:00
NEZNAMY f8487f07a6 Create array of component decorations to take values from to avoid instantiation each time 2024-05-02 21:06:15 +02:00
NEZNAMY e38721fa69 Speed up function 2024-05-02 19:30:22 +02:00
NEZNAMY 18e52f2f10 Add 1.20.6 to known versions 2024-04-29 18:06:16 +02:00
NEZNAMY f1300410b8 Update Fabric to 1.20.6 2024-04-29 18:03:52 +02:00
NEZNAMY e17059f1f7 Update library to fix error (1276) 2024-04-29 12:26:29 +02:00
NEZNAMY f3e9f7cf06 [BungeeCord] Remove console warn regarding ViaVersion on BungeeCord as it no longer breaks anything 2024-04-28 18:08:50 +02:00
NEZNAMY 63ed24d136 [Bukkit] Use Spigot internals over Paper API as a primary TPS getter (uses 10x less CPU and 100x less memory allocations) 2024-04-28 14:01:33 +02:00
NEZNAMY 66008cd767 [Velocity] Fix "Received packet for unknown scoreboard objective: TAB-BelowName" on server switch 2024-04-27 19:03:46 +02:00
NEZNAMY 1852c1b5c4 Create array to iterate over to prevent creating new instance every time 2024-04-26 20:12:45 +02:00
NEZNAMY 9a4fc2fc73 Fix field type 2024-04-26 11:52:55 +02:00
NEZNAMY 6846a78833 Require plugin list in a bug report 2024-04-26 11:52:15 +02:00
NEZNAMY d3d9e85a7f Merge branch '4.1.5'
# Conflicts:
#	build.gradle.kts
2024-04-26 11:47:03 +02:00
NEZNAMY f867b6b2ea 4.1.5-SNAPSHOT 2024-04-23 21:09:31 +02:00
NEZNAMY 6b38954694 4.1.4 2024-04-23 20:57:31 +02:00
NEZNAMY 9eb350df30 Fix startup on 1.19.3 - 1.20.4 2024-04-23 20:57:12 +02:00
NEZNAMY 639aa5e251 Fix startup on 1.19.3 - 1.20.4 2024-04-23 20:56:06 +02:00
NEZNAMY f089e26998 Added 1.20.5 support to Bukkit 2024-04-23 19:30:14 +02:00
NEZNAMY 9070a6aadc 4.1.3 2024-04-23 19:11:24 +02:00
NEZNAMY c68e135c66 Added 1.20.5 support to Bukkit 2024-04-23 19:11:17 +02:00
NEZNAMY 8693b4fe8f Mark 1.20.5 as latest supported version 2024-04-23 17:37:21 +02:00
NEZNAMY 9390a402ff Update Fabric to 1.20.5 2024-04-23 17:35:38 +02:00
NEZNAMY 7fda2c5f88 Add 1.20.5 ProtocolVersion constant 2024-04-23 17:35:15 +02:00
NEZNAMY cb394007a4 Update Fabric to 1.20.5 2024-04-23 17:25:00 +02:00
NEZNAMY cd92910281 Add 1.20.5 ProtocolVersion constant 2024-04-23 17:24:35 +02:00
NEZNAMY 7f0b2e2b13 Initialize feature data structured on declaration to make it cleaner & fix error 2024-04-23 16:16:51 +02:00
NEZNAMY bdc44d46c8 Add Exception throwing when attempting to use API class instances that got discarded on reload. 2024-04-23 16:10:24 +02:00
NEZNAMY 8d8480469a Update Fabric to 1.20.5-rc3 2024-04-23 15:28:30 +02:00
NEZNAMY a91fe6db36 Remove unused SneakyThrows 2024-04-23 12:51:41 +02:00
NEZNAMY 20d734aa80 Add missing action mapping 2024-04-23 12:43:20 +02:00
NEZNAMY f053bbd544 Access Team packet data directly on 1.17+ Fabric instead of using reflection 2024-04-23 12:40:14 +02:00
NEZNAMY 7eba26cab1 Rename class to match version number 2024-04-23 12:15:47 +02:00
NEZNAMY 5f77dd0adb Rename class to match version number 2024-04-23 12:14:42 +02:00
NEZNAMY 4ef94d3c60 Update Fabric to 1.20.5-rc3 2024-04-22 17:03:08 +02:00
NEZNAMY 36006045e2 Add "listed" TabList flag support into internal API 2024-04-22 16:54:39 +02:00
NEZNAMY d5d025c2c9 Store information about player meeting a feature's disable condition inside player class to improve performance by avoiding Map lookup each time 2024-04-22 14:41:34 +02:00
NEZNAMY 5b7053d500 Store feature data of players inside TabPlayer class to improve performance by avoiding Map lookup 2024-04-22 14:06:37 +02:00
NEZNAMY ce2e60c268 4.1.4-SNAPSHOT 2024-04-21 21:43:25 +02:00
NEZNAMY 8e9b575c37 Update Fabric to 1.20.5-rc2 2024-04-19 20:13:26 +02:00
NEZNAMY beab7d5a4f Update Fabric to 1.20.5-rc1 2024-04-18 16:26:16 +02:00
NEZNAMY d2f5fc4d69 Update Fabric to 1.20.5-pre4 2024-04-17 15:57:16 +02:00
NEZNAMY fb9a7f693b Update Fabric to 1.20.5-pre3 2024-04-16 16:48:03 +02:00
NEZNAMY 1d2d636270 Fix compilation warning on Fabric 1.14.4 submodule 2024-04-16 09:28:35 +02:00
NEZNAMY 37ec5ee442 Update Fabric to 1.20.5-pre2 2024-04-15 19:08:50 +02:00
NEZNAMY 5ed67cf5f8 Remove recently added config option that doesn't add any real value 2024-04-13 13:21:04 +02:00
NEZNAMY 76fc47d5bd Fix client lag when another plugin removes player from team (#1193) 2024-04-13 13:11:35 +02:00
NEZNAMY aa856beee1 Refactor team anti-override code to avoid duplicating code 2024-04-13 11:37:50 +02:00
NEZNAMY e6f2cc3eda Simplify 2024-04-12 15:00:32 +02:00
NEZNAMY 02fd45587b Fix replacements to %group% changing the group name inside plugin internals as well 2024-04-12 14:45:32 +02:00
NEZNAMY 7cef6eeb61 Update Fabric to 1.20.5-pre1 2024-04-10 19:11:43 +02:00
NEZNAMY da919bc43b Add BuiltByBit link to download links 2024-04-05 22:52:13 +02:00
NEZNAMY 2b661d6c5b Downgrade Java requirement on Fabric back to 17 2024-04-04 19:01:58 +02:00
NEZNAMY ee0ced63ef Update Fabric to 24w14a and Java version to 21 2024-04-03 21:22:35 +02:00
NEZNAMY 736dad5819 Merge pull request #1263 from JT122406/master
Update Loom and Gradle to Latest
2024-04-03 19:08:45 +02:00
Joseph T. McQuigg 11f36e8a22 Update Loom and Gradle to Latest 2024-04-03 13:05:57 -04:00
NEZNAMY 2cddf0b313 Add version compatibility check on Velocity 2024-03-31 12:03:58 +02:00
NEZNAMY 36a2d449b7 Add player version printing to debug command 2024-03-30 13:48:42 +01:00
NEZNAMY b6786456a2 Fix wrong method being overridden 2024-03-30 13:28:14 +01:00
NEZNAMY 76e8e1af6f Remove redundant .toLowerCase() 2024-03-30 12:33:49 +01:00
NEZNAMY ff55838a54 Remove unused imports 2024-03-29 14:21:21 +01:00
NEZNAMY b14b6828cc Move accesswidener file to resources/ folder instead of root in the compiled jar 2024-03-28 10:58:03 +01:00
NEZNAMY be7fb67988 Move configuration files to config/ folder instead of root in the compiled jar 2024-03-28 10:49:53 +01:00
NEZNAMY ae0be45d7d Drop 1.17(.0) support on Fabric (1.17.1 still supported) 2024-03-28 10:36:47 +01:00
NEZNAMY ba237d5dc4 Update Fabric to 24w13a 2024-03-28 10:27:22 +01:00
NEZNAMY bdf5cd8751 Remove unused constructor 2024-03-28 10:27:06 +01:00
NEZNAMY 9a6d309840 Update Fabric to 24w12a 2024-03-20 17:42:51 +01:00
NEZNAMY 9a6e92a58c Micro optimization of placeholder output replacements 2024-03-20 15:05:20 +01:00
NEZNAMY 1bc018918b Use common implementation of a method as default instead of making it abstract 2024-03-20 14:49:37 +01:00
NEZNAMY f32f8f5cdd Convert components in scoreboard class instead of each subclass 2024-03-20 14:39:46 +01:00
NEZNAMY 39585de3f0 Remove fallback solutions for Scoreboard on Bukkit 2024-03-20 14:16:18 +01:00
NEZNAMY 9ce81fc68e Convert component in abstract TabList class instead of manually in every class 2024-03-20 13:54:14 +01:00
NEZNAMY 0d56f0da98 Remove backup solutions for header/footer on Bukkit and only use packets 2024-03-20 13:49:31 +01:00
NEZNAMY 14a3d8da12 Save converted components as a field in TAB component instead of a separate cache that requires lookup, making it slower 2024-03-19 12:57:35 +01:00
NEZNAMY e4fa99b865 Use packets as primary solution for header/footer on Bukkit 2024-03-19 09:42:48 +01:00
NEZNAMY 96af2cb573 Drop native <gradient:#RRGGBB:#RRGGBB>Text</gradient> support to fix unexpected results when used in a way supported by MiniMessage but not this TAB function (and also because TAB called that function first) (#1252) 2024-03-18 22:40:57 +01:00
NEZNAMY f53ec58b2f Fix redundant empty component creation when using magic code after color code 2024-03-18 21:58:46 +01:00
NEZNAMY 2ff30dda83 Use HashMap instead of ConcurrentHashMap for better performance 2024-03-18 18:38:56 +01:00
NEZNAMY c0972f8faf Simplify 2024-03-18 15:52:25 +01:00
NEZNAMY 9663e1aa7e Remove redundant check 2024-03-18 15:46:28 +01:00
NEZNAMY d83a61b30a Replace &#RRGGBB with #RRGGBB sooner to save resources while refreshing 2024-03-18 15:35:59 +01:00
NEZNAMY 96d83da9b7 Remove unused method 2024-03-18 15:23:31 +01:00
NEZNAMY f1d881e0ba Add more checks to API methods 2024-03-18 13:41:23 +01:00
NEZNAMY d1285c7e04 Only send belowname update packets to players in the same world and server 2024-03-18 11:31:41 +01:00
NEZNAMY d4476e2d4c Optimize tablist packet creation on 1.19.3+ Bukkit & Fabric 2024-03-18 10:57:47 +01:00
NEZNAMY 3124d51381 Micro optimization of permission conditions 2024-03-18 10:19:12 +01:00
NEZNAMY b6ae1a79d4 Fix breaking errors on Fabric 1.16 - 1.18.2 2024-03-15 21:29:49 +01:00
NEZNAMY 42d7b598bf Improve comments in accesswidener 2024-03-15 21:29:00 +01:00
NEZNAMY 052e828d5a Split player spawn packet reading on Fabric based on version 2024-03-15 20:51:38 +01:00
NEZNAMY 55d4f8da6b Use logger directly on Fabric 1.18.2+ 2024-03-15 20:33:52 +01:00
NEZNAMY 1c5a4bbacc Simplify channel getting on BungeeCord 2024-03-15 16:54:27 +01:00
NEZNAMY 565d4bdeec Add java version requirement to fabric.mod.json 2024-03-15 15:47:56 +01:00
NEZNAMY 3d9ef7d252 Remove no longer needed SneakyThrows annotation 2024-03-15 15:39:23 +01:00
NEZNAMY 161bcbb236 Merge scoreboard packet listener methods into one 2024-03-15 15:22:23 +01:00
NEZNAMY c8af0ab5bc Use access widener on Fabric instead of reflection where easily possible 2024-03-14 20:46:04 +01:00
NEZNAMY 98e9c167c5 Update Fabric to 24w11a 2024-03-14 18:52:44 +01:00
NEZNAMY ed815c5767 Remove unintended return type 2024-03-14 16:14:14 +01:00
NEZNAMY f6e53ac91f Fix raw generic usage 2024-03-14 16:09:15 +01:00
NEZNAMY 3e5df50f9e Rename generic types 2024-03-14 16:05:44 +01:00
NEZNAMY 1e28a93c5f Replace star import with class imports 2024-03-14 16:02:13 +01:00
NEZNAMY 717bdd3550 Catch everything 2024-03-12 22:55:44 +01:00
NEZNAMY 3bee514bb9 Actually fix the previous error at its source 2024-03-12 10:32:56 +01:00
NEZNAMY 678d4b8db7 Use ConcurrentHashMap to fix ConcurrentModificationException 2024-03-12 10:02:06 +01:00
NEZNAMY d76e5e7f9b Simplify method (also probably speed it up) 2024-03-11 16:03:25 +01:00
NEZNAMY 9629192305 Simplify 2024-03-11 16:00:52 +01:00
NEZNAMY eef7debdba Remove unnecessary full class name 2024-03-09 11:35:23 +01:00
NEZNAMY 138d9f7f46 Initialize more variables in constructor 2024-03-08 12:52:47 +01:00
NEZNAMY e4abd9ec2f Refactor multi-version support on Fabric 2024-03-08 11:21:42 +01:00
NEZNAMY 8efce72e26 Remove component serialization code as it is no longer used 2024-03-07 19:04:27 +01:00
NEZNAMY 15ebca2d11 Use direct component conversion on Fabric instead of serializing and deserializing json 2024-03-07 18:47:55 +01:00
NEZNAMY 6583489523 Remove json deserializer support on Bukkit and only use direct component conversion 2024-03-07 17:15:53 +01:00
NEZNAMY 5610d52813 Remove part of a comment 2024-03-07 17:03:42 +01:00
NEZNAMY 618b61dd60 Use Adventure API to serialize components on Velocity 2024-03-07 17:03:24 +01:00
NEZNAMY 2de58f7a3b Remove RGB support in ViaBossbar (1.16+ clients on 1.8 server) 2024-03-07 16:44:50 +01:00
NEZNAMY 2bd94158f9 Remove redundant code 2024-03-07 14:47:56 +01:00
NEZNAMY 4e7ab43ac9 Update Fabric to 24w10a 2024-03-06 22:38:08 +01:00
NEZNAMY 33529d0cfd Slightly optimize vanish check and usage 2024-03-06 21:00:40 +01:00
NEZNAMY a5b929bdf5 Optimize tablist packet check on 1.19.3+ 2024-03-06 20:37:01 +01:00
NEZNAMY d10bd3358d Simplify 2024-03-05 15:58:14 +01:00
NEZNAMY ffe928fbe8 Save EnumSet for each tablist action into map and retrieve it instead of creating new Set on every packet send. 2024-03-05 15:51:16 +01:00
NEZNAMY fd61739d96 Remove deleted option from default config 2024-03-04 17:03:30 +01:00
NEZNAMY e1602a5655 Refactor TabList class to extract common content from each subclass into the main one 2024-03-04 13:48:53 +01:00
NEZNAMY a936302fd2 Rework tablist anti-override to save expected names and then restore the save values instead of creating them again 2024-03-04 11:45:18 +01:00
NEZNAMY 7f0d4df6ca Save teams for later use instead of recreating them every time 2024-03-03 21:23:47 +01:00
NEZNAMY 35ab0c67c5 Remove unused dependencies 2024-03-02 18:41:05 +01:00
NEZNAMY 090633140f Remove bug compensation 2024-03-02 17:21:16 +01:00
NEZNAMY 8efe02c2ef Further improve performance of command listener method (#1237) 2024-03-01 21:01:02 +01:00
NEZNAMY 2dbcaf029c Improve performance of a method if both scoreboard and bossbar features are disabled (#1237) 2024-03-01 20:28:50 +01:00
NEZNAMY ce758534bd Remove ClickEvent support as it's never used by the plugin 2024-03-01 11:58:19 +01:00
NEZNAMY 15caf70170 Update Bukkit 1.20.5 draft to 24w09a 2024-03-01 10:54:04 +01:00
NEZNAMY c07c3a3a4f Update Fabric to 24w09a 2024-03-01 10:37:43 +01:00
NEZNAMY b9000af55e Implement direct component conversion on Bukkit and use it as primary option. 2024-02-29 21:32:29 +01:00
NEZNAMY ed15ba29bb Create separate class for component conversion on Bukkit (will be extended soon) 2024-02-29 12:42:00 +01:00
NEZNAMY 2fb8da022a Fix startup on <1.8 2024-02-29 12:28:49 +01:00
NEZNAMY ed65088cb8 Add API method for setting player's expected game profile name (#1240) 2024-02-29 09:24:45 +01:00
NEZNAMY f367542096 Replace unoptimized online player check with an instant one 2024-02-28 14:19:38 +01:00
NEZNAMY 00e457542d Remove TabPlayer#isOnline as it was never really used 2024-02-28 14:12:22 +01:00
NEZNAMY b0c423b2dd Change sortingPlaceholder data type to avoid retrieving it each time 2024-02-27 20:57:32 +01:00
NEZNAMY eb5e3d637c Split method into multiple for better readability 2024-02-27 14:45:03 +01:00
NEZNAMY 4acd24b829 Make permission-related options refresh interval configurable 2024-02-27 13:59:58 +01:00
NEZNAMY f8576834fe Optimize method 2024-02-27 13:12:40 +01:00
NEZNAMY 1e9888a8b5 Optimize method 2024-02-27 13:08:17 +01:00
NEZNAMY d99b6643e9 Fix team color defaulting to black on Sponge 2024-02-27 11:17:16 +01:00
NEZNAMY 0b98d98867 Add Sponge 1.20.4 support 2024-02-27 11:04:55 +01:00
NEZNAMY d040b0faf5 Save global playerlist server group mapping instead of computing it on each request 2024-02-27 10:16:55 +01:00
NEZNAMY d53c20da56 Do not respawn armor stands on sneak for flying players (#1236). 2024-02-26 20:28:06 +01:00
NEZNAMY fad035699f Revert broken commit 2024-02-26 19:00:28 +01:00
NEZNAMY c7ab2b93a3 Move armor stands instead of teleporting them when players move. This should result in a significantly better sync. May also help with #1236 a bit. 2024-02-26 18:46:51 +01:00
NEZNAMY 4b75144276 Create cache for last color of prefix 2024-02-26 11:16:30 +01:00
NEZNAMY 99edcf68c1 Use new TabList method for better performance 2024-02-25 15:05:56 +01:00
NEZNAMY 9b6f1ce955 Add TabList#containsEntry method 2024-02-25 15:00:34 +01:00
NEZNAMY b570020944 Only send global playerlist latency update packets of players a player can actually see 2024-02-23 20:44:57 +01:00
NEZNAMY e91ba4ef79 Slightly speed up method 2024-02-23 19:14:45 +01:00
NEZNAMY a1fbefb13f Set use-numbers to true by default because buggy clients don't work without it and will not fix it anytime soon 2024-02-22 23:42:57 +01:00
NEZNAMY 340592d951 Document class 2024-02-22 11:59:45 +01:00
NEZNAMY a1c0bf7dec Use new Paper API for Scoreboard NumberFormat in fallback PaperScoreboard implementation 2024-02-20 18:49:52 +01:00
NEZNAMY a62f20469e Replace NotNull with NonNull in Scoreboard class for better troubleshooting 2024-02-19 20:22:17 +01:00
NEZNAMY 3f1f78315b Add Getter 2024-02-19 20:12:18 +01:00
NEZNAMY 12d8bc75cd Replace NotNull with NonNull in TabList class for better troubleshooting 2024-02-19 20:10:26 +01:00
NEZNAMY c1cf02ee9f Fix ConcurrentModificationException 2024-02-19 16:17:13 +01:00
NEZNAMY 7ac240af76 Update Fabric to 24w07a 2024-02-15 09:29:33 +01:00
NEZNAMY 82c34a33b5 Do not update tablist format for players on different servers who the player cannot see (#1232) 2024-02-14 18:08:04 +01:00
NEZNAMY d2330337ef Simplify method 2024-02-14 16:56:45 +01:00
NEZNAMY af38bd0383 Fix double score send on join 2024-02-14 11:52:07 +01:00
NEZNAMY c0a9ede377 Add runtime warn when belowname / playerlist objective placeholder returned decimal number 2024-02-14 11:45:40 +01:00
NEZNAMY 555ba3eb73 Split method into multiple for better readability and clean up 2024-02-11 20:24:54 +01:00
NEZNAMY 6f0e757ad6 Add console warn if condition type is needed but not configured 2024-02-11 20:07:59 +01:00
NEZNAMY 077b8fee96 Add more info into error message 2024-02-11 16:11:55 +01:00
NEZNAMY 643df47437 (Attempt to) fix deadlock (#1230) 2024-02-11 10:28:43 +01:00
NEZNAMY 9e1ea4678d Create shared empty instance for PlaceholderReplacementPattern to avoid new instances even if nothing is configured 2024-02-10 17:37:20 +01:00
NEZNAMY f3576b678b Make MySQL errors more user-friendly 2024-02-10 11:22:52 +01:00
NEZNAMY 2b49bce998 Add config option to disable SSL certification in MySQL if the database is not using it 2024-02-10 10:22:42 +01:00
NEZNAMY 896048ffff Replace "featureName" field with getter 2024-02-09 16:56:12 +01:00
NEZNAMY 04cb14f790 Add some more Javadoc 2024-02-09 16:12:16 +01:00
NEZNAMY bd22b0c08b Properly remove disconnected player from bossbars 2024-02-09 15:47:47 +01:00
NEZNAMY 95ce52bbeb Add TODO note 2024-02-09 11:04:40 +01:00
NEZNAMY 6b411f5cce Slightly optimize method 2024-02-09 10:56:59 +01:00
NEZNAMY c15b0d178b Create array field to iterate over for slightly better performance 2024-02-09 10:40:48 +01:00
NEZNAMY f5ffb69675 Disable tab expansion by default 2024-02-08 20:59:18 +01:00
NEZNAMY 24e59d970f Initialize NotNull field just in case 2024-02-08 17:10:55 +01:00
NEZNAMY 4ece4b66cd Only initialize map if used 2024-02-07 22:02:50 +01:00
NEZNAMY 7852d244bb Fix #1227 2024-02-07 21:37:27 +01:00
NEZNAMY d1c2487ba4 Enable CPU usage tracking only after running /tab cpu for the first time 2024-02-07 20:43:32 +01:00
NEZNAMY 4ea789efcf Add config option to disable refreshing placeholders in another thread (boosts performance) 2024-02-07 20:17:02 +01:00
NEZNAMY 43fc97c671 Update Fabric to 24w06a 2024-02-07 18:28:09 +01:00
NEZNAMY a20378d5cb Change abstract class to interface 2024-02-06 21:58:35 +01:00
NEZNAMY 7c0384c96b Create local variable to prevent spamming Map#get 2024-02-06 18:51:22 +01:00
NEZNAMY 7d4419b300 Override some methods in EmptyTabExpansion to avoid unnecessary operations 2024-02-06 17:56:28 +01:00
NEZNAMY 393af9b5c5 Add check to avoid unnecessary operations 2024-02-06 17:55:12 +01:00
NEZNAMY 559e423a1d Vastly improve performance of CPU usage tracking 2024-02-06 17:43:45 +01:00
NEZNAMY a2d68e14e6 Simplify 2024-02-06 17:10:21 +01:00
NEZNAMY 580b67d9ed Fix thread submitting tasks to itself 2024-02-06 16:45:57 +01:00
NEZNAMY 080654f703 Increase scoreboard line length limit by 2 characters on <1.13 2024-02-05 20:14:36 +01:00
NEZNAMY 002a002749 Remove redundant check 2024-02-05 19:19:51 +01:00
NEZNAMY 7e888e46f9 Implement best parts of #1219 2024-02-05 10:57:40 +01:00
NEZNAMY 199ca94acd Add compensation for 1.8.0 client-sided bug directly into TabList class (#1225) 2024-02-04 22:03:29 +01:00
NEZNAMY 67455bd47d Fix replacements not applying in nested placeholders 2024-02-04 18:32:21 +01:00
NEZNAMY fbb0e252c5 Allow -1 in refresh intervals 2024-02-04 17:57:44 +01:00
NEZNAMY 2566972ac7 Recode internal component class 2024-02-03 18:12:37 +01:00
NEZNAMY 9455294060 Simplify 2024-02-03 13:24:57 +01:00
NEZNAMY 6870b42a1a Merge branch 'master' of https://github.com/NEZNAMY/TAB 2024-02-03 11:22:45 +01:00
NEZNAMY 32cd414a51 Merge pull request #1224 from XXMA16/fix-spongeforge
Fix SpongeForge startup crash
2024-02-03 11:22:35 +01:00
XXMA16 35f63b7075 Fix code style
Signed-off-by: XXMA16 <xxma1610@gmail.com>
2024-02-03 02:43:51 +02:00
XXMA16 f9097b11b6 Fix SpongeForge startup crash
Signed-off-by: XXMA16 <xxma1610@gmail.com>
2024-02-02 19:37:19 +02:00
NEZNAMY dc5acdf729 Add default implementation to method instead of making it abstract 2024-02-01 22:09:49 +01:00
NEZNAMY e5fb25daee Update Bukkit 1.20.5 draft to match 24w05b changes 2024-02-01 20:47:03 +01:00
NEZNAMY 33b6867c02 Update Fabric to 24w05b 2024-02-01 20:39:16 +01:00
NEZNAMY d572973b60 Add console hint when configuring redundant placeholder replacement pattern using "else" 2024-01-31 19:28:30 +01:00
NEZNAMY 3d240f0f7d Fix NPE 2024-01-31 19:12:13 +01:00
NEZNAMY 3a4973d760 Change sidebar team naming 2024-01-29 11:43:25 +01:00
NEZNAMY 811c9716a2 Fix message 2024-01-28 13:26:04 +01:00
NEZNAMY 771f6db89a Remove unused imports 2024-01-28 10:55:44 +01:00
NEZNAMY 97f515f573 Remove placeholder output replacement from default config 2024-01-27 20:19:17 +01:00
NEZNAMY c589dfb281 Fix per-world settings of unlimited nametags not updating on world switch 2024-01-27 20:01:41 +01:00
NEZNAMY 82efe5b4d1 Simplify 2024-01-27 13:57:25 +01:00
NEZNAMY 765f593b88 Specify locale in .toLowerCase to avoid error when java is using a weird language 2024-01-27 13:52:01 +01:00
NEZNAMY 21e5de25cb Remove console warn when ViaVersion returns unknown version, because kids kept asking about it on ViaVersion discord despite the message clearly saying to update TAB. 2024-01-27 13:42:06 +01:00
NEZNAMY 4333e44f6d Fix false warn on proxy when bukkit permissions are enabled 2024-01-26 21:21:40 +01:00
NEZNAMY 7070fd886b Add support for Bukkit jars without CraftBukkit relocation (#1220) 2024-01-25 15:15:12 +01:00
NEZNAMY 89480a9018 Remove cpu report printing into console if overloaded and debug is enabled 2024-01-24 18:16:15 +01:00
NEZNAMY 19ce873037 Update Fabric to 24w04a 2024-01-24 17:30:58 +01:00
NEZNAMY 977007b427 Do not cache subcomponents on bungeecord (#1211) 2024-01-24 17:07:37 +01:00
NEZNAMY 218c1c9d9a Remove global serverVersion field and only use it in each platform if needed 2024-01-24 15:32:38 +01:00
NEZNAMY f358ac9d9c Create and use Platform#isProxy method 2024-01-24 14:02:38 +01:00
NEZNAMY 58fe2b4582 Make "enable-collision" support conditions 2024-01-24 13:08:03 +01:00
NEZNAMY 211624b1a9 Improve style of iteration 2024-01-24 11:56:01 +01:00
NEZNAMY 6874369a48 Simplify animation placeholder creation 2024-01-24 11:53:52 +01:00
NEZNAMY f8c52d3577 Initialize player group in declaration to prevent "Vault through Bridge" returning null on the first time (#1211) 2024-01-24 09:58:16 +01:00
NEZNAMY 376bf5314d Actually fix trying to process offline players (players are still marked as online by Bukkit API even after they disconnect) 2024-01-23 18:18:12 +01:00
NEZNAMY 2346df67a0 Fix trying to process offline players in placeholder update task 2024-01-23 18:05:01 +01:00
NEZNAMY e63c7b43e1 Show a runtime warn if belowname / playerlist objective cannot be evaluated to a number 2024-01-23 18:04:18 +01:00
NEZNAMY 578691fe8c Document and clean up class 2024-01-22 19:15:07 +01:00
NEZNAMY 189d8a82d5 Update default config to account for missing NumberFormat in scoreboards in bedrock edition 2024-01-22 17:43:45 +01:00
NEZNAMY 9412d9cc28 Add %bedrock% placeholder returning true for bedrock clients 2024-01-22 17:40:02 +01:00
NEZNAMY 75b2bfa14c Implement TabPlayer#isOnline on Fabric 2024-01-22 15:40:09 +01:00
NEZNAMY 7fcb5c8aa3 Create functions for different error types instead of printing them directly 2024-01-22 15:15:59 +01:00
NEZNAMY 9827711111 Simplify 2024-01-22 13:41:06 +01:00
NEZNAMY 16aecd65e6 Add error message when permission plugin returned null group 2024-01-22 13:32:29 +01:00
NEZNAMY c143ecc6ae Remove redundant Getter annotation 2024-01-20 17:56:29 +01:00
NEZNAMY 2935f9e205 Clean up 2024-01-20 17:54:51 +01:00
NEZNAMY a6a33a79d4 Attempt to fix error (#1218) 2024-01-20 17:22:23 +01:00
NEZNAMY 82f9d8ddee Attempt to fix error (#1218) 2024-01-20 11:08:59 +01:00
NEZNAMY daa6012b36 Simplify 2024-01-20 11:05:45 +01:00
NEZNAMY 5001c82f23 Update Fabric to 24w03b 2024-01-18 21:17:10 +01:00
NEZNAMY 59dbad9abf Fix snapshot name in fabric.mod.json 2024-01-18 12:12:13 +01:00
NEZNAMY 945c7cc7b8 Draft 1.20.5 support on Bukkit 2024-01-18 11:19:30 +01:00
NEZNAMY 3391f7646c Simplify 2024-01-17 23:27:27 +01:00
NEZNAMY 88070aa2b2 Use different constructor to simplify usage 2024-01-17 23:06:15 +01:00
NEZNAMY c792296746 Use reflection to get rid of 2 Fabric submodules 2024-01-17 23:06:06 +01:00
NEZNAMY 18a13f777d Allow empty output in sorting by pre-defined values 2024-01-17 22:27:34 +01:00
NEZNAMY 469529b324 Update Fabric to 24w03a 2024-01-17 21:15:26 +01:00
NEZNAMY 4715a5ab9d Use static number as a start of numbering if use-numbers is enabled 2024-01-17 19:08:46 +01:00
NEZNAMY be305162a6 Fix scoreboard use-numbers duplicating numbers 2024-01-17 19:08:17 +01:00
NEZNAMY 7a1bc16e9d Fix NPE 2024-01-17 11:27:36 +01:00
NEZNAMY eb2c80deb8 Add try/catch for ViaVersion hook (#1201) 2024-01-16 21:56:51 +01:00
NEZNAMY 0863b77bf0 Remove unused import 2024-01-16 20:51:16 +01:00
NEZNAMY 769a698509 Fix NPE and replace it with a warning (#1198) 2024-01-16 20:50:51 +01:00
NEZNAMY 53870b2c81 Fix anti-override on Velocity and Sponge no longer working after players are removed & added back to the tablist by another plugin 2024-01-16 12:54:52 +01:00
NEZNAMY e198a5df88 Another attempt to fix #1212 2024-01-16 11:17:28 +01:00
NEZNAMY ac947f698b Fix ClassCastException (#1213) 2024-01-16 11:05:06 +01:00
NEZNAMY ecabd62b6b Catch another exception (#1212) 2024-01-15 10:35:09 +01:00
NEZNAMY f350d200ac Fix memory leak 2024-01-14 20:28:35 +01:00
NEZNAMY 97d5a3f7ef Print all exceptions in a chain, not just the last one 2024-01-14 13:25:59 +01:00
NEZNAMY f15f3efc3f Add plugin's name prefix into console messages on Fabric 2024-01-14 11:48:24 +01:00
NEZNAMY 7563b6b946 Convert \n to newline if snakeyaml does not do it because text is in '' and not "" 2024-01-13 18:52:21 +01:00
NEZNAMY 421c53e6be Replace forEach with for 2024-01-13 18:06:16 +01:00
NEZNAMY 3db8666951 Hide spectator effect for players who unvanished (#1209) 2024-01-13 12:58:00 +01:00
NEZNAMY ecc6e01cf9 Add links to Tanguygab's new discord server where he will provide support to kids 2024-01-12 10:39:12 +01:00
NEZNAMY becf81db00 Merge 2 fields into 1 2024-01-10 15:04:50 +01:00
NEZNAMY 92f5b337c9 Use dummy implementation if original one is not available & remove redundant class 2024-01-10 14:26:56 +01:00
NEZNAMY 3ddf884c23 Get CraftBukkit classes using package name instead of version as recommended by Paper 2024-01-10 14:18:54 +01:00
NEZNAMY 116117af55 Create method to simplify usage 2024-01-09 18:20:51 +01:00
NEZNAMY 0980bcfca5 Merge pull request #1202 from Jake-Moore/master
Support to use Global Playerlist `server-groups` as Header/Footer `per-server` keys.
2024-01-09 18:12:05 +01:00
NEZNAMY 20e2e8ded6 Fix relational placeholders not refreshing properly & nested relational placeholders not being marked as used by the feature (and therefore not refreshing properly) (#1203) 2024-01-09 18:06:35 +01:00
Jake Moore 13af0b7b2b Improve handling of failed cases 2024-01-08 20:58:19 -08:00
Jake Moore cbcbfdcbf1 Adds support to use Global Playerlist server-groups as Header/Footer keys in per-server. Allowing for configuration of a server group with several velocity servers which can have a unique header-footer section. 2024-01-08 17:07:44 -08:00
NEZNAMY 38eb294667 Move version check 2024-01-08 12:24:50 +01:00
NEZNAMY 71d16ff906 Only send messages that actually affect the user 2024-01-08 12:22:19 +01:00
NEZNAMY 395058d771 Send console message saying how long NMS hook took to load 2024-01-08 12:13:58 +01:00
NEZNAMY d8af7c454c Simplify 2024-01-07 23:07:38 +01:00
NEZNAMY 2f10084e7a Replace more fields with functional interfaces 2024-01-07 22:56:08 +01:00
NEZNAMY 5af387b32d Move ScorePacketData to a separate class 2024-01-07 21:41:10 +01:00
NEZNAMY 4b7144f705 Replace fields with functional interfaces for NMS access 2024-01-07 21:20:24 +01:00
NEZNAMY 0fbbbb6485 Simplify 2024-01-07 20:23:09 +01:00
NEZNAMY f033d78785 Optionally print compatibility exception into console 2024-01-07 20:08:44 +01:00
NEZNAMY 2ea79eb57d Remove unused import 2024-01-07 14:44:49 +01:00
NEZNAMY 226ee0db9d Include supported version range in compatibility error message 2024-01-06 22:45:21 +01:00
NEZNAMY 8a62f21e84 Improve compatibility error messages 2024-01-06 22:25:33 +01:00
NEZNAMY c353c39086 Make entity view compatibility on Bukkit optional 2024-01-06 21:33:19 +01:00
NEZNAMY 2b2c877ab2 Add more Javadoc 2024-01-06 21:15:20 +01:00
NEZNAMY 016af4bfee Make DummyEntityView methods do nothing instead of throwing 2024-01-06 20:54:23 +01:00
NEZNAMY b3d26d91de Add console warn when waterfall option causing issues is enabled 2024-01-06 17:23:41 +01:00
NEZNAMY a7a7f409eb Fix sorting note getting overridden on refresh when set using API 2024-01-06 15:52:24 +01:00
NEZNAMY f44ccec712 Remove StaticLine class and use LongLine instead for the same effect 2024-01-06 14:29:08 +01:00
NEZNAMY 1c0887733c Initialize property names to random values instead of specific names 2024-01-06 14:14:33 +01:00
NEZNAMY 7ee3c35785 Rename some cpu usage categories to make them easier to understand 2024-01-06 14:01:13 +01:00
NEZNAMY 01b725cf38 Define team color immediately and forward it instead of figuring it out later 2024-01-05 21:30:43 +01:00
NEZNAMY 1ac6d90633 Add a runtime warn when sorting element is not in list (group, placeholder, or no permission) 2024-01-02 16:27:08 +01:00
NEZNAMY 9704193237 Add a runtime warn when numeric placeholder in condition did not return a number 2024-01-02 15:43:22 +01:00
NEZNAMY 69b150b391 Make team color always white for scoreboard lines (#1189) 2024-01-02 14:13:17 +01:00
NEZNAMY 7ffb3edda5 Spawn entity using bundle packet for 1.19.4+ to prevent frame being rendered between packets, causing visible armor stands for a single frame (#1168) 2024-01-02 13:10:20 +01:00
NEZNAMY 046eb68ce6 Split MisconfigurationHelper class into 3 for different message types 2024-01-01 22:03:08 +01:00
NEZNAMY 816d80a27c Construct ArmorStand with non-null level on Fabric (#1191) (one more) 2023-12-31 11:27:17 +01:00
NEZNAMY 957037e5f4 Construct ArmorStand with non-null level on Fabric (#1191) 2023-12-30 15:38:54 +01:00
NEZNAMY 9ca179a71f Make BungeeCord compatibility error message more clear about what exactly went wrong (#1190). 2023-12-30 15:34:12 +01:00
NEZNAMY cb4d96f1ba Remove unused imports 2023-12-29 22:15:05 +01:00
NEZNAMY 7d57522775 Add more Javadoc 2023-12-29 22:04:54 +01:00
NEZNAMY 902565f1b1 Remove TabList.Entry.Builder class and build entries directly 2023-12-29 19:07:13 +01:00
NEZNAMY 2f8de436af Improve Javadoc 2023-12-29 18:56:17 +01:00
NEZNAMY 38bd035d99 Create separate class for each incoming plugin message and move handling method to ProxyPlatform class 2023-12-29 18:29:51 +01:00
NEZNAMY 88b6d1a3ca Remove redundant SneakyThrows and replace some instances with throws 2023-12-29 14:40:17 +01:00
NEZNAMY a74878e7bb Make PacketSender an instance class 2023-12-29 14:17:29 +01:00
NEZNAMY 2b6eba7c4d Replace star import with direct imports 2023-12-26 12:21:06 +01:00
NEZNAMY 0de1b86ef5 Remove unnecessary static modifier 2023-12-26 12:19:46 +01:00
NEZNAMY ae0ab6471b Remove unused import 2023-12-26 12:17:58 +01:00
NEZNAMY c24cdaa8a4 Fix json syntax error when sorting character ends up being \ (#1184) 2023-12-24 23:17:07 +01:00
NEZNAMY df1442dd8a Fix YellowNumber & BelowName sending score update to disabled players 2023-12-24 15:30:57 +01:00
NEZNAMY b17d5306db Create and use TabFeature#config method for shorter code in all features 2023-12-24 15:08:34 +01:00
NEZNAMY 88d5294b8e Skip placeholder refreshing code if no placeholders are being refreshed 2023-12-24 14:25:25 +01:00
NEZNAMY 8c3405d01f Replace streams with direct code for better performance 2023-12-24 14:23:13 +01:00
NEZNAMY 9f83ba700c Fix bossbar & scoreboard writing into file on every join when remembering toggle choice is enabled even if value didn't change 2023-12-23 23:06:08 +01:00
NEZNAMY ae147211ca Code style 2023-12-23 22:58:01 +01:00
NEZNAMY 01d305eba0 Move scoreboard packet listening from pipeline class to scoreboard class 2023-12-23 21:54:26 +01:00
NEZNAMY 08c30574a9 Code style 2023-12-23 21:01:25 +01:00
NEZNAMY 39c4725a2f Change access from public to private 2023-12-23 19:45:32 +01:00
NEZNAMY 7002aeefaf Create constants for "magic numbers" 2023-12-23 17:28:19 +01:00
NEZNAMY f1201cc5bc Code style 2023-12-23 16:30:14 +01:00
NEZNAMY 0b99d4ac52 Extract duplicated code into a method 2023-12-23 16:29:11 +01:00
NEZNAMY 642cb701dd Remove unused import 2023-12-23 15:42:49 +01:00
NEZNAMY 66d6aee115 Move method to avoid duplication 2023-12-23 15:39:01 +01:00
NEZNAMY 38d8eb1108 Simplify 2023-12-23 15:20:09 +01:00
NEZNAMY f9941c5dff Add some more Javadocs 2023-12-23 14:48:26 +01:00
NEZNAMY 855a6f447a Use constants for bStats plugin ids 2023-12-23 13:59:02 +01:00
NEZNAMY fa0a1f8553 Create and use ProtocolVersion#supportsRGB instead of manually comparing number each time. 2023-12-23 13:55:52 +01:00
NEZNAMY 0d1fee1636 Add missing Javadoc to Fabric 2023-12-23 13:48:35 +01:00
NEZNAMY ec8269332f Add missing Javadoc to Bukkit 2023-12-23 13:31:16 +01:00
NEZNAMY 00fe9400e6 Add missing Javadoc to BungeeCord 2023-12-23 12:40:59 +01:00
NEZNAMY 8389b1e151 Add missing Javadoc to API 2023-12-23 12:31:09 +01:00
NEZNAMY 2289d10d6c Add missing Javadoc to Sponge and Velocity 2023-12-23 12:22:01 +01:00
NEZNAMY b30af4f144 Remove redundant "new" when creating arrays 2023-12-23 12:00:05 +01:00
NEZNAMY 041322c53f Update latest known version field 2023-12-23 11:21:03 +01:00
NEZNAMY 548968bcfc Print console warn on startup if error log has reaches its size limit 2023-12-22 20:37:31 +01:00
NEZNAMY 6d405b70e7 Properly apply replacements to server placeholders initially 2023-12-22 17:27:02 +01:00
NEZNAMY 1b4d4acc63 Fix map merging mistake 2023-12-22 17:26:24 +01:00
NEZNAMY 6f498089fb Add back option to disable tab expansion 2023-12-22 15:32:53 +01:00
NEZNAMY 8e27cba0f6 Fix compilation 2023-12-22 15:30:05 +01:00
NEZNAMY ae48041a96 Simplify 2023-12-21 23:55:57 +01:00
NEZNAMY bad16a4cdc Update Fabric to 23w51b 2023-12-21 20:50:16 +01:00
NEZNAMY 07baf769dd Suppress random irrelevant warnings 2023-12-21 20:21:23 +01:00
NEZNAMY ab409643f6 Convert class to record 2023-12-21 18:00:36 +01:00
NEZNAMY c745a61601 Recode placeholder refreshing to make refreshing thread not do anything more than placeholder requests & various minor performance improvements 2023-12-21 17:57:47 +01:00
NEZNAMY c4e8e83d1e Add check to improve method's performance 2023-12-21 13:03:49 +01:00
NEZNAMY 9133f3d792 Repackage classes and remove unused interface 2023-12-21 09:54:22 +01:00
NEZNAMY b779d584a5 Speed up placeholder replacement code if nothing is configured 2023-12-20 17:31:22 +01:00
NEZNAMY 05bb61b3ab Improve performance of a method 2023-12-20 15:50:25 +01:00
NEZNAMY 5d2885e662 Wrap maps into synchronizedMap to avoid deadlock on concurrent access 2023-12-20 15:48:26 +01:00
NEZNAMY ef645c1058 Fix random NPE 2023-12-17 20:16:09 +01:00
NEZNAMY 52a476fd0a Print cpu report into console if plugin is overloaded and debug is enabled 2023-12-17 11:19:08 +01:00
NEZNAMY 7386c45f06 Implement TabList class on Bukkit for 1.7, implement a backup solution using API and make the loading optional 2023-12-16 15:53:51 +01:00
NEZNAMY 1a508ddedf Fix error on old versions 2023-12-16 14:28:31 +01:00
NEZNAMY a8675f254a Move sendPacket call 2023-12-15 18:46:03 +01:00
NEZNAMY 0f70cd789e Move team anti-override to scoreboard class 2023-12-15 14:53:47 +01:00
NEZNAMY b8f594f42c Move tablist packet processing to tablist class 2023-12-15 12:20:17 +01:00
NEZNAMY 7857527ce1 Add console warn if floodgate is not configured correctly 2023-12-11 20:40:14 +01:00
NEZNAMY 05c41a5469 Create separate class for PremiumVanish hook & add check for outdated version to avoid an error (#1171) 2023-12-11 15:11:46 +01:00
NEZNAMY f11f8afdc4 Update README.md 2023-12-11 09:05:28 +01:00
NEZNAMY fa499aa46d Merge pull request #1170 from NicoNekoDev/master
Add NexEngine gradient
2023-12-10 13:25:05 +01:00
NicoNekoDev e8a7cc026f Documentation 2023-12-10 14:09:53 +02:00
NicoNekoDev 433ef6a8a7 Placeholders and legacy text 2023-12-10 14:08:09 +02:00
NicoNekoDev fc4b5a7bcd Fix codestyle 2023-12-10 13:40:44 +02:00
NicoNekoDev bd43134d58 Fix text 2023-12-10 13:26:34 +02:00
NicoNekoDev 557970ba4e Add NexEngine gradient
https://github.com/nulli0n/NexEngine-spigot/wiki/Configuration-Tips
2023-12-10 11:18:41 +02:00
NEZNAMY d3418e0067 Remove duplicate method 2023-12-09 20:52:44 +01:00
NEZNAMY b8d1845d4e Change way of detecting 1.19.4+ flag 2023-12-09 19:03:11 +01:00
NEZNAMY 32e360409d Create and use method for retrieving a CraftBukkit class instead of doing it manually each time (the method might also change in the future according to Paper devs, this will also make modifying and maintenance easier) 2023-12-09 19:00:46 +01:00
NEZNAMY c54a778af9 Fix RGB color conversion from adventure component to internal component 2023-12-09 15:26:55 +01:00
NEZNAMY ce25698f87 Do not cache nested components 2023-12-09 14:26:49 +01:00
NEZNAMY 4d95cc838a Change way of multi-version code handling on Fabric to significantly reduce complexity, module count and compilation time 2023-12-09 14:14:31 +01:00
NEZNAMY 67fa0a231e Add more misconfiguration checks for layout feature 2023-12-09 11:23:39 +01:00
NEZNAMY 3c2e8c81c4 4.1.3-SNAPSHOT 2023-12-08 09:50:11 +01:00
NEZNAMY 484d46252b 4.1.2 2023-12-08 09:47:09 +01:00
NEZNAMY a2e3c67298 Fix MiniMessage parsing causing issues to different syntax rules (#1166) 2023-12-08 09:46:36 +01:00
NEZNAMY b2ea05d8dd Merge 1.14.4 and 1.15.2 fabric modules for faster compilation 2023-12-07 20:26:13 +01:00
NEZNAMY 1477f47962 Merge 1.17 and 1.17.1 fabric modules for faster compilation 2023-12-07 19:18:25 +01:00
NEZNAMY 273ce49c14 4.1.2-SNAPSHOT 2023-12-07 19:16:56 +01:00
NEZNAMY 96b6790646 4.1.1 2023-12-07 18:50:30 +01:00
NEZNAMY 38227ec878 Update Fabric to 1.20.4 2023-12-07 18:48:08 +01:00
NEZNAMY 11da632972 Add 1.20.4 to version list 2023-12-07 17:46:51 +01:00
NEZNAMY 3721b9fe22 Fix MiniMessage not working in scoreboard 2023-12-07 14:12:13 +01:00
NEZNAMY ecb697e5fb Update default config to match recent scoreboard change (using ||) 2023-12-07 13:31:51 +01:00
NEZNAMY c754772280 Remove warn if ViaVersion returns -1 version (finally got to reproduce it & make tests) 2023-12-06 18:21:58 +01:00
NEZNAMY 5f2b4ba0b3 Fix disconnect on BungeeCord on 1.20.3 2023-12-06 13:46:21 +01:00
NEZNAMY 0ab60becfc Change scoreboard line number format split sequence to || instead of | to prevent false trigger when trying to actually display the character. 2023-12-05 23:01:54 +01:00
NEZNAMY 1dcfb7d6dc 4.1.1-SNAPSHOT 2023-12-05 23:01:11 +01:00
NEZNAMY 3c0b44b365 4.1.0 2023-12-05 20:45:58 +01:00
NEZNAMY ec4aec50ef Mark 1.20.3 as latest known version 2023-12-05 18:55:42 +01:00
NEZNAMY 9c86cfe056 Add Vault to softdepend to avoid console warn 2023-12-05 18:53:49 +01:00
NEZNAMY 6bb2337276 Print warn if RedisSupport received unknown message instead of throwing a NPE 2023-12-05 18:49:53 +01:00
NEZNAMY 4702ca255b Update Fabric to 1.20.3 2023-12-05 18:48:54 +01:00
NEZNAMY ab47aa36cc Confirm network id of 1.20.3 2023-12-05 18:40:55 +01:00
NEZNAMY 4bb14c4a4e Rename new config options 2023-12-05 17:27:24 +01:00
NEZNAMY 1dd75162f9 Add a version to list 2023-12-04 21:09:37 +01:00
NEZNAMY a2242e3c27 Move server version check 2023-12-04 20:52:29 +01:00
NEZNAMY 26ecf494a9 Little fix 2023-12-04 20:45:51 +01:00
NEZNAMY 659af5d0b3 Completely get rid of NMSStorage class 2023-12-04 20:33:23 +01:00
NEZNAMY 382a5ee7fc Move packet sending method to a separate class and make loading optional 2023-12-04 19:17:51 +01:00
NEZNAMY 7364496844 Move ping retrieving method to a separate class 2023-12-04 17:52:32 +01:00
NEZNAMY d342316b87 Reduce dependence on the main NMS class on Bukkit 2023-12-04 17:29:25 +01:00
NEZNAMY b38141da88 Add &f at the beginning of scoreboard lines for 1.13+ players to prevent color field from coloring text if no color is used 2023-12-04 16:40:06 +01:00
NEZNAMY 98f80f7dae Remove unused methods 2023-12-03 21:36:22 +01:00
NEZNAMY c134ec6bfe Simplify class loading 2023-12-03 21:32:00 +01:00
NEZNAMY 4e3f759243 Use NMS prefix only once instead of every usage 2023-12-03 21:03:08 +01:00
NEZNAMY a5f2e0157b Make player game profile getting optional instead of throwing a compatibility error 2023-12-03 20:52:29 +01:00
NEZNAMY fd21032e51 Make pipeline injection compatibility optional and print a warning if a compatibility error is found 2023-12-03 19:22:33 +01:00
NEZNAMY c4f5f9b7d3 Update comment 2023-12-03 18:11:40 +01:00
NEZNAMY 6baf5a7068 Fix NPE 2023-12-03 17:28:41 +01:00
NEZNAMY d3460174de Enable fallback solutions for Scoreboard implementation on Bukkit 2023-12-03 16:07:05 +01:00
NEZNAMY f9f19628ca Fix BukkitScoreboard class issues 2023-12-03 15:38:22 +01:00
NEZNAMY 04e48fea5d Clean up method 2023-12-01 20:22:41 +01:00
NEZNAMY 3e99e22fce Simplify 2023-12-01 19:18:58 +01:00
NEZNAMY 0b244d5ff7 Refactor PacketScoreboard class and draft 1.20.3 support 2023-12-01 19:15:56 +01:00
NEZNAMY 703f2ff316 Fix potentially wrong uuid write 2023-12-01 09:35:47 +01:00
NEZNAMY 34a2bbdbae Simplify 2023-12-01 09:34:14 +01:00
NEZNAMY cd8697c1a4 Add exclusions for some dependencies 2023-11-30 19:15:20 +01:00
NEZNAMY ed2dc2dd51 Avoid rare error on Velocity 2023-11-30 18:50:53 +01:00
NEZNAMY 2dfdc1b993 Update Fabric to 1.20.3-rc1 2023-11-30 18:27:49 +01:00
NEZNAMY 6f2d7f1194 Fix 1.20.3 client crash on BungeeCord 2023-11-30 17:52:01 +01:00
NEZNAMY 30009ef127 Attempt to fix error (#1146) 2023-11-29 17:19:11 +01:00
NEZNAMY 051a422331 Update Fabric to 1.20.3-pre4 2023-11-29 16:56:35 +01:00
NEZNAMY fab6489e9c Fix compilation 2023-11-28 16:12:27 +01:00
NEZNAMY a448614e4a Slightly better organize method 2023-11-27 18:54:28 +01:00
NEZNAMY 84ad874b2a Split complex method into 2 2023-11-27 18:43:43 +01:00
NEZNAMY 19ba978291 Simplify 2023-11-27 18:16:48 +01:00
NEZNAMY e304469e55 Remove star import 2023-11-27 18:10:28 +01:00
NEZNAMY 7ce9e2592a Update README.md 2023-11-27 18:07:35 +01:00
NEZNAMY 681b812c7b Rename feature in /tab cpu output 2023-11-26 13:59:29 +01:00
NEZNAMY ee1ab6785d Rename objective 2023-11-26 12:36:12 +01:00
NEZNAMY 57704b6622 Move a few classes around 2023-11-26 11:15:23 +01:00
NEZNAMY 7fe804e0fc Fix disconnect on bungeecord on 1.20.3 due to null text in component 2023-11-25 22:24:02 +01:00
NEZNAMY a71529b641 Simplify 2023-11-25 18:07:47 +01:00
NEZNAMY 4055173bdb Replace .length() == 0 with .isEmpty() 2023-11-25 17:09:20 +01:00
NEZNAMY 3f8841a276 Update to latest BungeeCord (for the 3rd time in a row) 2023-11-25 17:04:34 +01:00
NEZNAMY 15c38851bc Add misconfiguration check and prevent startup error 2023-11-25 16:56:11 +01:00
NEZNAMY 05030ae817 Update outdated message 2023-11-25 13:05:57 +01:00
NEZNAMY 255fa11371 Fix NPE 2023-11-24 18:41:08 +01:00
NEZNAMY a074c0bf74 Simplify 2023-11-24 10:49:12 +01:00
NEZNAMY 6ccd649fc4 Remove unused imports 2023-11-24 10:46:59 +01:00
NEZNAMY 21dbea07dd Add support for nested relational placeholders (#1153) 2023-11-23 20:28:21 +01:00
NEZNAMY 4c21d9d127 Remove unused import 2023-11-23 20:27:16 +01:00
NEZNAMY 766002b079 Delete aligned suffix feature, since 1.20.3 now has it naturally using playerlist objective (rip 1.20.2-) 2023-11-23 19:39:47 +01:00
NEZNAMY 2ce430ec41 Add support for all Fabric versions in a single jar 2023-11-23 19:18:31 +01:00
NEZNAMY cf2b151045 Bump Velocity version and use new method 2023-11-19 16:57:22 +01:00
NEZNAMY 92216179df Replace try/catch with SneakyThrows annotation 2023-11-19 16:27:06 +01:00
NEZNAMY a2a95b8591 Replace scoreboard enums with fields 2023-11-19 10:50:54 +01:00
NEZNAMY 4a22dc111a Fix attempt to send header/footer to 1.7 players on bungeecord, causing disconnect 2023-11-19 10:16:27 +01:00
NEZNAMY 5df7ecc245 Fix compatibility error message 2023-11-18 20:49:24 +01:00
NEZNAMY d4ef520f26 Print required bridge version in debug command if not connected 2023-11-18 20:39:09 +01:00
NEZNAMY e0f8737865 Use direct code for bungeecord instead of reflection and drop support for old versions 2023-11-18 20:37:37 +01:00
NEZNAMY 37b13a54a7 Create classes for plugin message types instead of writing all content on each usage + bump bridge version to 5 due to braking changes 2023-11-18 14:44:22 +01:00
NEZNAMY d9d28d31d0 Prepare for new 1.20.3 scoreboard features 2023-11-17 20:21:17 +01:00
NEZNAMY 66bf5da3f5 Delete CustomLine class due to not being viable 2023-11-17 11:41:11 +01:00
NEZNAMY 840c721afc Simplify, the performance gain was pretty much zero 2023-11-17 10:59:28 +01:00
NEZNAMY 859e705a48 Drop multi-version code for fabric (hard to maintain + a lot of it didn't actually work) 2023-11-16 22:10:45 +01:00
NEZNAMY 7375070b21 oops (#1144) 2023-11-15 16:53:42 +01:00
NEZNAMY 3e2eda6a71 Add ClickEvent to components 2023-11-11 20:17:22 +01:00
NEZNAMY 798d327dcb Fix plugin not removing redundant character width overrides from config 2023-11-11 18:11:37 +01:00
NEZNAMY f5ca9139e6 Fix double bossbar on Velocity on server switch (#1139) 2023-11-11 14:02:07 +01:00
NEZNAMY f35e8cfa51 Improve vanish tracking for nametag feature 2023-11-10 21:31:21 +01:00
NEZNAMY 0f6953711b Update build.yml 2023-11-10 15:57:34 +01:00
NEZNAMY e2c5e6f9ac Allow empty text for fixed slots in layout 2023-11-10 15:46:26 +01:00
NEZNAMY 5ef5d6ddba Update README.md 2023-11-10 12:51:41 +01:00
NEZNAMY 5b19a5d798 Only unregister team for other players when player is vanishing 2023-11-10 11:02:35 +01:00
NEZNAMY bf804e8923 Merge pull request #1137 from NEZNAMY/vanish-patch
Alternate implementation of #1136
2023-11-09 18:53:45 +01:00
NEZNAMY f47b8b5528 Alternate implementation of #1136 2023-11-09 18:30:56 +01:00
NEZNAMY c353f6787a Fix endsWith condition (#1134) 2023-11-07 17:37:52 +01:00
NEZNAMY 1b7d5c1a5c Add support for latest BungeeCord (yes, again), as well as some previous versions and remove compatibility check. 2023-11-06 17:12:26 +01:00
NEZNAMY 956456f157 4.1.0-SNAPSHOT 2023-11-06 13:41:51 +01:00
NEZNAMY 49077bd798 Create enum constants for packet actions for better readability and understanding of code 2023-11-05 21:16:07 +01:00
NEZNAMY 019a0287b2 4.0.9 2023-11-05 14:27:55 +01:00
NEZNAMY a71dac28c0 Hotfix after adding support for latest bungeecord (#1132) 2023-11-05 14:21:25 +01:00
NEZNAMY 155886e000 Fix typo 2023-11-04 15:39:45 +01:00
NEZNAMY ed4c303d2e 4.0.8 2023-11-04 14:55:32 +01:00
NEZNAMY 9da0db5f74 Disable creation of blank issues 2023-11-04 11:55:58 +01:00
NEZNAMY 562a973c84 Create new issue template 2023-11-04 11:53:10 +01:00
NEZNAMY 967980ddf7 Update bug_report.yml 2023-11-03 21:27:24 +01:00
NEZNAMY 81d3675a87 Check for bundle packet on 1.19.4+ when reading entity packets for unlimited nametags 2023-11-03 21:25:21 +01:00
NEZNAMY 7be786bbaf Fix vanish change being called on join even if vanish status did not change 2023-11-02 17:24:02 +01:00
NEZNAMY f41c9be1f7 Fix race condition on Velocity causing errors on shutdown 2023-11-02 17:21:48 +01:00
NEZNAMY e88062d028 Fix unvanish method not being called on server switch when clearing vanish status 2023-11-02 16:08:15 +01:00
NEZNAMY edb2828643 Fix wrong java instruction 2023-11-02 15:58:34 +01:00
NEZNAMY 58c189cd0e Catch all exceptions/errors on load/unload to prevent players from getting kicked on bungeecord if something changes again in the future 2023-10-31 16:41:29 +01:00
NEZNAMY 012994847e Unregister teams of players who vanished for those who cannot see vanished players to prevent 3rd party clients from revealing vanished players by finding out who is vanished and who actually left. 2023-10-30 20:39:21 +01:00
NEZNAMY d87801be5f Add support for latest BungeeCord (#1123) 2023-10-30 16:02:31 +01:00
NEZNAMY 6d78c0c104 Create a class storing values of minecraft limitations 2023-10-29 15:25:00 +01:00
NEZNAMY 3a83519122 Fix tablist entry related issues on both BungeeCord and Velocity (each one was affected by a different issue) 2023-10-27 22:27:42 +02:00
NEZNAMY a9f940ebed Avoid attempts to send packets to offline players on bungeecord 2023-10-27 19:17:56 +02:00
NEZNAMY db73d9ef81 Simplify 2023-10-24 17:46:25 +02:00
NEZNAMY e2bd21c717 Cache adventure components & use Paper API for header/footer by default. This has reduced CPU usage of the feature by 50% in the test I have done. 2023-10-24 17:40:22 +02:00
NEZNAMY 871215b7b5 Do not attempt to send scoreboard-related packets between login packet send and process 2023-10-24 15:18:17 +02:00
NEZNAMY a6153ef46f Force-fix NPE that doesn't make sense 2023-10-24 13:42:55 +02:00
NEZNAMY 35475a6103 Fix the previous error on Fabric & Sponge as well 2023-10-24 13:42:35 +02:00
NEZNAMY bf77ffc1a5 Fix error (#1117) 2023-10-22 23:01:53 +02:00
NEZNAMY 7a64a9a534 Code style 2023-10-22 20:08:27 +02:00
NEZNAMY 68e057b99c Fabric - Implement world name recognition and everything related to it (#1115) 2023-10-22 17:44:34 +02:00
NEZNAMY 7338afff96 Fix error when using 3 years old version of PlaceholderAPI 2023-10-21 11:27:38 +02:00
NEZNAMY 97ae7813aa Add vanish status updating to RedisBungee (#1109) 2023-10-18 16:48:01 +02:00
NEZNAMY c0f3667ac1 4.0.8-SNAPSHOT 2023-10-18 16:47:37 +02:00
NEZNAMY d5c5502abe 4.0.7 2023-10-16 20:45:35 +02:00
NEZNAMY 194e8ffbd9 Code style 2023-10-15 20:39:06 +02:00
NEZNAMY ef39458abd With all the problems on 1.20.2 BungeeCord it turns out that Velocity isn't that bad. 2023-10-15 17:39:21 +02:00
NEZNAMY 6a6907fb0a Process login packet with a delay to avoid problems 2023-10-15 17:33:06 +02:00
NEZNAMY 8bb7c4a4a6 Adapt redis support subfeatures to recent changes 2023-10-15 17:00:55 +02:00
NEZNAMY 91700e7ed0 Fix global playerlist not readding players for 1.20.2 clients on server switch 2023-10-15 17:00:16 +02:00
NEZNAMY 661c2e6fc3 Simplify 2023-10-15 15:37:38 +02:00
NEZNAMY 3d053a6149 Implement backup solutions if header/footer fields fail to initialize 2023-10-15 15:35:25 +02:00
NEZNAMY 34179e4f62 Fix startup on old versions due to wrong enum names 2023-10-15 14:56:40 +02:00
NEZNAMY a23e5d9f50 Remove toComponent method from Platform interface and only keep it in platforms that actually use it 2023-10-15 14:26:09 +02:00
NEZNAMY 1cbcbf70d9 Fix aligned playerlist attempting to send packets to players who just left 2023-10-15 14:08:35 +02:00
NEZNAMY 0a7371aaec Micro optimizations with enum conversions 2023-10-14 13:55:52 +02:00
NEZNAMY da13e2d861 Fix Bridge still injecting placeholders that are not used on proxy anymore 2023-10-13 12:27:12 +02:00
NEZNAMY 5b18fa8c25 Fix PingSpoof spoofing everything instead of just online players (or their respective layout entries) 2023-10-13 11:34:38 +02:00
NEZNAMY 347231850a Fix error 2023-10-13 09:51:40 +02:00
NEZNAMY b1f9bdc26c Resend BossBar on server switch for 1.20.2 players as Login packet now clears it 2023-10-12 20:51:50 +02:00
NEZNAMY 03c9b95041 Listen to login packet instead of server switch delay for 1.20.2 players for better consistency (also fix layout not being resent on server switch on 1.20.2) 2023-10-12 19:20:22 +02:00
NEZNAMY 6e7e1d783b Fix rare placeholder formatting error 2023-10-12 16:33:58 +02:00
NEZNAMY cfb9b0a029 Fix compatibility with some random 1.8.8 overpriced fork (#1105) 2023-10-12 14:32:21 +02:00
NEZNAMY b7ea6e5af6 Fix wrong exception being caught causing the try/catch to not work (#1092) 2023-10-12 09:33:50 +02:00
NEZNAMY 44104df712 Change error message about invalid team/objective actions to a debug message. They don't cause any issues as they are properly caught and debugging is hard, especially if reporter has no interest in cooperating (#1083) 2023-10-11 19:35:57 +02:00
NEZNAMY 5de20d1c58 Add try/catch for BungeeCord sendPacket method to avoid a NPE in BungeeCord code (#1090, #1092) 2023-10-11 16:24:43 +02:00
NEZNAMY d156303740 Remove warn when placeholders use too much CPU. Since they have been moved to another thread, they will no longer prevent the plugin from working. While the warning can be useful for more advanced users, this is a public plugin used by many and most of them don't care about performance at all. This has resulted in having to answer people who would have never contacted me otherwise. 2023-10-10 15:04:00 +02:00
NEZNAMY 6e36eb3554 Add back fabric class for multi-version code for easier backport 2023-10-09 21:49:21 +02:00
NEZNAMY f7f3891817 Avoid attempts to send plugin message to offline players on bungeecord (#1090? #1092?) that may? cause errors on 1.20.2 2023-10-08 12:41:12 +02:00
NEZNAMY 1ec28856ff Avoid attempts to send packets to offline players on bungeecord (#1090? #1092?) that may? cause errors on 1.20.2 2023-10-06 11:41:32 +02:00
NEZNAMY 9658e0b74d Add debug message showing how long bridge took to respond to player join plugin message 2023-10-06 11:31:09 +02:00
NEZNAMY 86cd8d4151 Make feature loading more readable 2023-10-05 17:39:27 +02:00
NEZNAMY 2418eb206e Improve unknown version handling code & error messages 2023-10-05 13:57:56 +02:00
NEZNAMY 08fa715d26 Fix runtime warns false triggering on proxy when placeholders are not loaded due to bridge not having a chance to respond yet (#1088) 2023-10-04 14:16:08 +02:00
NEZNAMY 52426de283 Remove double method call 2023-10-04 14:04:57 +02:00
NEZNAMY 64b3da14c4 It's called disable condition, not display condition 2023-10-02 20:38:21 +02:00
NEZNAMY bf7341c52c Change way getProfile method is retrieved (#1089) 2023-10-02 19:09:53 +02:00
NEZNAMY e3490564a2 4.0.7-SNAPSHOT 2023-10-02 19:07:05 +02:00
NEZNAMY 6218f0ed16 4.0.6 2023-10-01 16:35:39 +02:00
NEZNAMY 54e8e1ea98 Add a temporary workaround for https://github.com/SpigotMC/BungeeCord/issues/3542 2023-10-01 16:35:33 +02:00
NEZNAMY 4cd50fb3d5 Use sendPacketQueued method on BungeeCord to avoid error on 1.20.2 clients 2023-10-01 16:31:25 +02:00
NEZNAMY 590286a6c2 4.0.5 2023-09-27 21:12:58 +02:00
NEZNAMY 6c96650dcc Add support for new Spigot build that uses mojang mappings for fields and methods 2023-09-27 21:12:22 +02:00
NEZNAMY 7c83a74fd8 Fix plugin trying to send scoreboard packets to players who left already 2023-09-27 19:20:32 +02:00
NEZNAMY 7b3f60cb3b 4.0.5-SNAPSHOT 2023-09-23 16:37:02 +02:00
NEZNAMY bfc845088a Merge pull request #1084 from GsTio86/master
Fix Arclight compatibility
2023-09-23 12:36:32 +02:00
Galen Huang e67d93a592 Update DataWatcher.java 2023-09-23 16:58:19 +08:00
gstio86 b518b980ae Fix Arclight compatibility 2023-09-23 14:35:06 +08:00
NEZNAMY 744bc1403a Remove tps placeholder from config entirely, the negation was wrong as well 2023-09-22 11:01:35 +02:00
NEZNAMY e11113073f 4.0.4 2023-09-22 09:00:37 +02:00
NEZNAMY 3615818812 Add condition to default config to prevent %tps% being displayed on BungeeCord in scoreboard, as the message is too long 2023-09-22 08:59:31 +02:00
NEZNAMY 0cdef12caf Add support for BungeeCord 1.20.2 2023-09-22 08:56:19 +02:00
NEZNAMY dda8c6c053 Fix another error on Bukkit 1.20.2 2023-09-21 22:21:46 +02:00
NEZNAMY 8c3327f553 Fix error on Bukkit 1.20.2 2023-09-21 20:49:29 +02:00
NEZNAMY c037a14e1f Update Bukkit to 1.20.2 2023-09-21 19:45:06 +02:00
NEZNAMY bd661360ee Delete %server_uptime% from default config as it's a PlaceholderAPI placeholder, which is not always guaranteed to work. (#1077) 2023-09-21 18:33:27 +02:00
NEZNAMY 317fabbc87 Update Fabric to 1.20.2 2023-09-21 18:31:49 +02:00
NEZNAMY 87161446c5 Add 1.20.2 to protocol versions 2023-09-21 18:25:22 +02:00
NEZNAMY 7db8b2e84b Send warn if trying to use parse command from the console with "me" player name argument 2023-09-21 15:04:03 +02:00
NEZNAMY 5f3fa2b317 Layout - Fix ROWS direction type not working properly & avoid real players appearing on top when teams are disabled 2023-09-19 22:14:37 +02:00
NEZNAMY 64c15730a6 Add missing correct Placeholder#update implementations (#1075) 2023-09-17 18:48:41 +02:00
NEZNAMY e5ab46b8ad Initialize scoreboard placeholders to avoid them rarely not parsing due to not being set 2023-09-17 15:01:51 +02:00
NEZNAMY 3060d8cc2b Add override for %player_ping% placeholder because 1.20.2 will have a breaking change to prevent github issues reporting server expansion not supporting new version 2023-09-16 10:30:05 +02:00
NEZNAMY f5d6ba462e Remove unnecessary fully qualified class names 2023-09-15 15:21:39 +02:00
NEZNAMY 81fdeece96 Port new Velocity anti-override to Sponge as well 2023-09-15 14:21:20 +02:00
NEZNAMY 8f60439ef3 Fix multiple sorting types with same priority separated with | not actually working 2023-09-14 16:13:44 +02:00
NEZNAMY c5420ead90 Send gamemode update packet on world switch when spectator fix is enabled as the server may resend gamemode on world switch back to spectator (#1069) 2023-09-13 16:55:21 +02:00
NEZNAMY 99d372d03c Fix refresh interval config conversion ignoring random invalid user-made maps and then causing error on load 2023-09-12 14:32:15 +02:00
NEZNAMY 1219a9822f Remove unused dependency 2023-09-10 10:42:37 +02:00
NEZNAMY d40c182af9 Clean up repositories 2023-09-10 10:39:12 +02:00
NEZNAMY 785e986a72 Fix component cache including child components 2023-09-09 21:04:41 +02:00
NEZNAMY e8b80f455b Replace converter methods with arrays for fast access 2023-09-09 11:33:16 +02:00
NEZNAMY 2d545f1bf1 Fix potential blocking of other plugins in new anti-override for Velocity 2023-09-09 08:22:45 +02:00
NEZNAMY d4713dc7f4 Use direct code for LibsDisguises hook instead of reflection and move it into a separate class 2023-09-08 23:54:21 +02:00
NEZNAMY cd96c13670 Remove unused imports 2023-09-08 23:07:13 +02:00
NEZNAMY 808607faf0 Add try/catch for Fabric loading to send warn on unsupported versions instead of throwing an error (#1068) 2023-09-08 21:30:54 +02:00
NEZNAMY bc403f5c23 Fix ConcurrentModificationException on Velocity 2023-09-08 19:04:00 +02:00
NEZNAMY bfc67e1953 Allow the new anti-override to be disabled with standard settings 2023-09-08 08:21:42 +02:00
NEZNAMY a186c16c34 Implement anti-override for tablist display names on Velocity 2023-09-07 21:37:33 +02:00
NEZNAMY f9be9d4c4b Improve check to reduce errors thrown 2023-09-07 18:09:38 +02:00
NEZNAMY 79fc3ce33f Fix BossBars getting resent when output of placeholder used in display condition changed even if condition result didn't change (#1065) 2023-09-06 21:14:35 +02:00
NEZNAMY 055ff8749e Add support for custom fonts in configuration 2023-09-05 21:38:38 +02:00
NEZNAMY d36410e851 Simplify 2023-09-05 21:32:01 +02:00
NEZNAMY 0fed5dca7f Add font field and conversion to component class and quality of life changes for component conversion 2023-09-05 15:30:42 +02:00
NEZNAMY dd34ffc5b2 Create internal enum for scoreboard display type instead of using a boolean 2023-09-04 21:00:17 +02:00
NEZNAMY 2cd5ac85f9 Simplify 2023-09-04 18:20:17 +02:00
NEZNAMY 571f949f50 Remove unnecessary player version check 2023-09-04 17:58:38 +02:00
NEZNAMY 81e32957b2 Fix startup error 2023-09-04 17:57:20 +02:00
NEZNAMY 4639016ffb Preload NMS GameModes instead of calling Enum#valueOf every time 2023-09-04 17:41:26 +02:00
NEZNAMY dabc2b49dc Remove unused fields and methods 2023-09-03 17:52:29 +02:00
NEZNAMY 2dec389c8c Load NMS method by parameter types instead of name 2023-09-01 11:26:05 +02:00
NEZNAMY bfe5b5960e Fix error in per world playerlist on <1.8 2023-08-31 21:04:36 +02:00
NEZNAMY e352967a17 Improve parse command and fix color-related issues on bukkit 2023-08-31 18:48:04 +02:00
NEZNAMY 930917f285 Fill auto-complete suggestions in plugin's PlaceholderAPI expansion 2023-08-30 21:04:49 +02:00
NEZNAMY b9747f7fbe Fix NPE when user deletes default-refresh-interval option from config (1052) 2023-08-28 13:39:39 +02:00
NEZNAMY 5ac9dcec37 Fix startup on Sponge 7 2023-08-28 13:00:11 +02:00
NEZNAMY 8328b43783 Fix NPE when using relational placeholder with multiple proxies 2023-08-25 22:28:23 +02:00
NEZNAMY 131fcfe144 Remove redundant annotation 2023-08-24 17:36:16 +02:00
NEZNAMY 709cb967b5 Fix plugin sometimes trying to format tablist entries for 1.7 players 2023-08-24 12:16:16 +02:00
NEZNAMY 3370b83087 Fix issue in config conversion 2023-08-24 12:06:04 +02:00
NEZNAMY 5c44bd500c Simplify 2023-08-24 10:05:21 +02:00
NEZNAMY ab8a345944 Small style changes 2023-08-24 09:45:23 +02:00
NEZNAMY 337dd56c87 Simplify 2023-08-24 09:38:54 +02:00
NEZNAMY de78ae30db Copy the previous fix to aligned playerlist as well 2023-08-22 14:29:04 +02:00
NEZNAMY 3f64185389 Fix disable condition not being respected in playerlist in one method (#1037) 2023-08-22 14:23:32 +02:00
NEZNAMY 5077cbbc9a Return empty list instead of new list 2023-08-22 14:01:50 +02:00
NEZNAMY 4d522ba5f5 Improve bossbar command to match scoreboard command features 2023-08-22 13:57:45 +02:00
NEZNAMY 4f1180b3f5 Boost performance of tablist getter on BungeeCord 2023-08-17 17:53:22 +02:00
NEZNAMY 577a3f2551 Add support for Mohist 1.18.2 2023-08-13 17:54:42 +02:00
NEZNAMY 8623ab053e Remove some unnecessary local variables 2023-08-12 20:51:25 +02:00
NEZNAMY 6d0f99eaf1 Change WeakHashMap key to use own player object instead of server's to prevent map getting big when another plugin has a memory leak 2023-08-12 19:04:30 +02:00
NEZNAMY f9490d2652 Move field into local variable 2023-08-12 15:08:15 +02:00
NEZNAMY 9d321e4a31 Remove unused parameter and simplify 2023-08-11 22:12:00 +02:00
NEZNAMY b8c2625b80 Only show placeholder retrieve time message if debug is enabled 2023-08-09 20:22:38 +02:00
NEZNAMY 8e42f328dc Register plugin's PlaceholderAPI expansion automatically without having to enable a config option 2023-08-09 20:13:26 +02:00
NEZNAMY 0c6b4efba5 Simplify 2023-08-09 17:02:25 +02:00
NEZNAMY 0821ed4dae Bukkit - Make NMS loading less dependent on the main NMS class 2023-08-09 17:00:20 +02:00
NEZNAMY 8bc38e25f9 Fix empty line detection sometimes not working 2023-08-07 21:51:43 +02:00
NEZNAMY 7a7a4e6da2 Global playerlist - Do not remove & add self on server switch 2023-08-07 14:04:25 +02:00
NEZNAMY f7d703ed1e Placeholders - Decrease return time warn threshold from 1000ms to 50ms 2023-08-07 13:40:35 +02:00
NEZNAMY 443d7fd082 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2023-08-07 13:38:47 +02:00
NEZNAMY b6114625c1 Remove duplicate check 2023-08-07 12:18:13 +02:00
NEZNAMY 4a3eb78f12 Add back ping spoof feature 2023-08-06 11:32:02 +02:00
NEZNAMY fa117a671a Simplify placeholder registration 2023-08-05 23:04:36 +02:00
NEZNAMY 6448fb975a Fix scoreboard title limit 2023-08-05 14:41:40 +02:00
NEZNAMY 1c685ce0bb Bukkit - Properly play around Bukkit API limits in scoreboard 2023-08-05 14:36:14 +02:00
NEZNAMY 1662fa8d60 Bukkit - Implement scoreboard handler using Bukkit API (still unused) 2023-08-05 13:23:03 +02:00
NEZNAMY 2787b1735b Header/Footer - Fix being sent on server switch even if disable condition is met & fix being sent twice 2023-08-04 22:07:06 +02:00
NEZNAMY e58390e30b Add some missing NotNull / Nullable annotations 2023-08-04 20:43:58 +02:00
NEZNAMY 41a10a61bf Small refactoring 2023-08-03 22:56:05 +02:00
NEZNAMY fdcc7d5e7c Global Playerlist - Add support for * symbol in server-groups 2023-08-01 13:35:06 +02:00
NEZNAMY 50b39e462f Remove unnecessary full manual import 2023-07-28 23:18:49 +02:00
NEZNAMY 4bc781f0da Refresh placeholders in a different thread, so they can no longer kill the plugin 2023-07-28 22:33:33 +02:00
NEZNAMY aca4c00083 Do not refresh placeholders in PlaceholderManager on join, as it can cause error when updating nested placeholder in a feature that's not loaded yet 2023-07-28 17:17:07 +02:00
NEZNAMY 77b820ad4d Do not spawn armor stands of dead players on join (#1005) 2023-07-28 17:02:42 +02:00
NEZNAMY 328f604236 Add pipeline injection for fabric 2023-07-28 17:02:13 +02:00
NEZNAMY 2f77bf3d10 Create a separate class for CPU report 2023-07-28 13:05:04 +02:00
NEZNAMY 23eb55aa06 Add back support for mojang-mapped server jars 2023-07-26 16:19:21 +02:00
NEZNAMY 32b7356bc0 Send console hint if both layout and prevent-spectator-effect are enabled 2023-07-25 18:22:34 +02:00
NEZNAMY 6091641ed9 Add warn if both layout and yellow-number features are enabled 2023-07-25 18:16:01 +02:00
NEZNAMY e368213d18 Add misconfiguration check for scoreboard chaining 2023-07-25 15:17:41 +02:00
NEZNAMY 58f9bb6fca Add unlimited nametag mode to Fabric (with a few missing things) 2023-07-24 22:26:24 +02:00
NEZNAMY 79798199b8 More abstraction of unlimited nametag mode 2023-07-24 20:53:14 +02:00
NEZNAMY c8d20f8479 Move NMS loading of classes 2023-07-24 17:59:17 +02:00
NEZNAMY c0498a60b4 Remove some console messages on startup 2023-07-24 16:46:00 +02:00
NEZNAMY faa01ddfc2 Add back compatibility attempt for nick plugins (#974) 2023-07-23 12:47:16 +02:00
NEZNAMY a2f628e267 Add try/catch for PremiumVanish hook due to its bug (#993) 2023-07-23 11:54:04 +02:00
NEZNAMY 66007b9121 Decrease component cache size to 1000 entries 2023-07-22 01:25:28 +02:00
NEZNAMY 9e0056b603 Improve source code parity between platforms (Sponge 7, Sponge 8 and Fabric) and improvements to Fabric 2023-07-22 01:22:13 +02:00
NEZNAMY b15cc3a6af Improve source code parity between platforms (BungeeCord and Velocity) 2023-07-21 22:33:55 +02:00
NEZNAMY 5393f869e7 Remove option to disable global playerlist latency update. The performance drop is almost zero and updating is actually needed as initial ping value can be invalid ((#990) 2023-07-20 18:05:39 +02:00
NEZNAMY f8088402e8 Make it more obvious that %tps% is a backend-only placeholder (#990) 2023-07-20 17:48:27 +02:00
NEZNAMY 979ff7d2b8 Move %mspt% placeholder registration into backend package 2023-07-19 23:29:07 +02:00
NEZNAMY bdbde58f42 Drop krypton platform as author abandoned it 2023-07-19 21:33:07 +02:00
NEZNAMY 1e26e0bd13 Change backend placeholder registration method 2023-07-19 19:34:36 +02:00
NEZNAMY be3c00d17e Fix colors in error messages 2023-07-16 12:53:46 +02:00
NEZNAMY d542bb67de Add a console warn if anti-override is disabled 2023-07-16 12:09:16 +02:00
NEZNAMY a79cdfaa1c Add a console warn if placeholder used in numeric sorting did not return a valid number 2023-07-16 11:46:07 +02:00
NEZNAMY 42db715421 Fix NPE 2023-07-15 21:16:10 +02:00
NEZNAMY 2228d5a35d Small cleanup 2023-07-15 21:08:18 +02:00
NEZNAMY c434d0eafd Remove component cache from Sponge 7 2023-07-15 21:01:27 +02:00
NEZNAMY 414a3a971f Optimize placeholder high_to_low and low_to_high to only take 3 characters instead of 10 and slightly increase range as well 2023-07-15 18:32:58 +02:00
NEZNAMY b8a22a2561 Fix layout fixed slot updating issue when switching between layouts 2023-07-15 15:06:25 +02:00
NEZNAMY bc1dc2f84f Fix layout skins not working on sponge 8 2023-07-15 14:24:01 +02:00
NEZNAMY 904c4f27aa Add check if a placeholder's refresh interval is configured same as default interval 2023-07-14 16:28:21 +02:00
NEZNAMY b19e5435ef Add check for redundant per-server / per-world overrides for header/footer 2023-07-14 15:45:18 +02:00
NEZNAMY 78fbcd829a Construct player object async 2023-07-14 14:22:56 +02:00
NEZNAMY a255844a92 Create separate methods for logging info/warn and use them 2023-07-14 14:19:22 +02:00
NEZNAMY c7a548c575 Fix placeholders in tablist formatting getting stuck when on bungeecord and joining into disabled server 2023-07-14 11:50:18 +02:00
NEZNAMY 90a4bab114 Fix global playerlist formatting tablist names for players meeting disable condition 2023-07-13 23:47:28 +02:00
NEZNAMY a1633d146a Fix NPE when using relational placeholders on bungeecord 2023-07-12 22:42:21 +02:00
NEZNAMY 87bf4b03df Add misconfiguration checks for bossbar properties 2023-07-12 17:58:17 +02:00
NEZNAMY 7731aea0d6 Create %player_ping% placeholder on bukkit to override the PAPI one and avoid issues like #972 when ping field changes 2023-07-10 21:37:33 +02:00
NEZNAMY e66350111e Make detectPlaceholders method 7x faster when text only consists of 1 placeholder 2023-07-09 22:27:13 +02:00
NEZNAMY 7e5df68626 Round animation change interval instead of decreasing it when invalid value is used 2023-07-09 21:25:10 +02:00
NEZNAMY 8e3e7de4ee Send warn if a placeholder took longer than 1000ms to return value 2023-07-09 18:35:03 +02:00
NEZNAMY 0ee535fbd5 Small code style improvements from PR 2023-07-09 10:45:05 +02:00
NEZNAMY 1b471d266c Merge pull request #970 from TFSMads/master
Added support for different default skins depending on the slot index in the layout feature
2023-07-09 10:38:44 +02:00
NEZNAMY 19a4f6ea1f Merge pull request #971 from misteeka/master
@NotNull marked function actually can return null
2023-07-08 19:10:36 +02:00
misteeka 7cc8d71224 Fix typo 2023-07-08 19:42:30 +03:00
_Mads b843475a0a Remove unnecessary imports and debug message 2023-07-08 15:18:05 +02:00
_Mads 027c0fa771 Added support for different default skins depending on the slot index 2023-07-08 15:09:50 +02:00
NEZNAMY c08e76f110 Fix startup error when refresh intervals are misconfigured (#969) 2023-07-08 12:46:39 +02:00
NEZNAMY b837fe7d15 4.0.4-SNAPSHOT 2023-07-08 12:34:21 +02:00
NEZNAMY d4d1bed408 4.0.3 2023-07-07 22:51:41 +02:00
NEZNAMY 8870295d54 Fix compatibility with bukkit/forge hybrids if they use different mappings 2023-07-07 22:50:32 +02:00
NEZNAMY 79cd6e4ae2 Add null check for messages form bridge (for future updates to avoid NPE / protocol break) 2023-07-07 17:36:44 +02:00
NEZNAMY 8e5ea29c40 Define decimal separator in one more way to make sure it works properly (#967) 2023-07-07 15:25:11 +02:00
NEZNAMY 287b51a0bf Send warn if using debug command on player who is not loaded (#959) 2023-07-06 20:55:16 +02:00
NEZNAMY 28cbf952fa Send warn if both per world playerlist and layout are enabled 2023-07-06 15:12:28 +02:00
NEZNAMY 598c35a3aa Simplify 2023-07-06 12:37:24 +02:00
NEZNAMY b8b67a64ab Simplify nms loading 2023-07-06 12:33:47 +02:00
NEZNAMY 7f6020ef34 Fix loading on catserver 2023-07-06 12:13:12 +02:00
NEZNAMY aeed453e15 Move named field loading to respective classes 2023-07-05 23:41:54 +02:00
NEZNAMY 71dddcca4c Drop support for mojang mapped server jar 2023-07-05 21:49:54 +02:00
NEZNAMY 46cdf79e20 Use all arg constructor for spawn entity packet on 1.17+ (using the wrong packet still spawns the entity) 2023-07-05 21:12:47 +02:00
NEZNAMY d7af96823b Merge pull request #962 from MachineBreaker/patch-1
Fix ViaVersion bug returning -1 version
2023-07-04 23:11:08 +02:00
MachineBreaker 5a228bd6b3 Fix ViaVersion bug returning -1 version
Explanation:

Both TAB and ViaVersion PlayerJoinEvent priority are LOWEST and seems that TAB registers earlier than ViaVersion the listeners, this causes TAB not being able to get the client protocol version due to ViaVersion not being able to register it firstly.

There might be another way to workaround this since i don't know changing the priority would cause any issue with TAB itself.
2023-07-04 16:19:07 -04:00
NEZNAMY fcd95655ce Send warn when trying to use parse command without any placeholders 2023-07-04 11:09:14 +02:00
NEZNAMY 7f5b57f8d2 Merge pull request #956 from Tanguygab/master
Update skins in Layout's FixedSlots
2023-07-03 17:07:01 +02:00
NEZNAMY f596877716 Fix forwarding unlimited nametag disable status to backend 2023-07-02 17:30:58 +02:00
NEZNAMY 1802c8fd90 Fix debug command not showing properties from unlimited nametag as disabled when they are 2023-07-02 17:30:35 +02:00
Tanguygab e05856facc only update name if skin didn't update 2023-07-02 13:51:37 +02:00
Tanguygab 45cfc3abb0 simplified FixedSlot skin updating 2023-07-02 13:40:08 +02:00
Tanguygab 2d39579861 added support for placeholders in layout's fixed-slots' skins 2023-07-02 13:27:37 +02:00
NEZNAMY 431f4bb4d5 Change Velocity policy 2023-07-02 00:39:10 +02:00
NEZNAMY 7bc9d38176 Slightly improve debug messages 2023-07-01 20:15:50 +02:00
NEZNAMY 7536447a8f Update README.md 2023-06-29 20:47:33 +02:00
NEZNAMY 059b796061 Update CONTRIBUTING.md 2023-06-29 20:35:44 +02:00
NEZNAMY a89942484f Layout - Fix duplicate internal names causing issues 2023-06-28 21:03:13 +02:00
NEZNAMY c28be3fd65 Add (another) warn if plugin's CPU usage is high 2023-06-26 21:04:26 +02:00
NEZNAMY 5f1116795c Add Folia support (#919) 2023-06-25 12:11:41 +02:00
NEZNAMY 4f54d2f6b2 4.0.3-SNAPSHOT 2023-06-25 10:59:05 +02:00
NEZNAMY 6b7bedbe2d Fix NPE when placeholder returns null 2023-06-24 14:30:44 +02:00
NEZNAMY 20ff225c31 Add missing set team color 2023-06-23 22:03:32 +02:00
NEZNAMY af2700798e 4.0.2 2023-06-22 13:07:44 +02:00
NEZNAMY f9c280bbdc Add back vault, so people stop asking 2023-06-22 12:50:36 +02:00
NEZNAMY 6ee31c2c3f Fix unlimited nametag property changes on world switch if per-world settings are used 2023-06-22 11:10:21 +02:00
NEZNAMY cbd944f6f2 Remove redundant field initialization 2023-06-19 21:19:48 +02:00
NEZNAMY cc20748f31 Move ping field initialization 2023-06-19 21:16:20 +02:00
NEZNAMY c9545165aa Rename a few classes 2023-06-19 20:38:19 +02:00
NEZNAMY 05c10bf2e7 Move all scoreboard packet fields & methods to PacketScoreboard class 2023-06-19 19:18:53 +02:00
NEZNAMY 67aeae2094 Create scoreboard implementation using paper api (not used yet) 2023-06-19 17:53:20 +02:00
NEZNAMY 1cc85a0647 Add API function for getting player's team name (#939) 2023-06-19 17:29:04 +02:00
NEZNAMY 988c0f8b4c Construct player object sync 2023-06-19 16:34:03 +02:00
NEZNAMY 62306fa5d6 More cleanup using @SneakyThrows annotation 2023-06-19 12:44:06 +02:00
NEZNAMY 641c5a49c3 Remove unused import 2023-06-19 11:12:16 +02:00
NEZNAMY 5637402435 Fix startup on some bukkit versions & improve compatibility error message 2023-06-18 20:54:25 +02:00
NEZNAMY 728d6c9a25 Make compatibility checks slightly more strict and remove package check. 2023-06-17 23:55:20 +02:00
NEZNAMY 22d3ba2877 Remove layout view on quit to avoid permission checks for offline players 2023-06-17 22:26:38 +02:00
NEZNAMY d1e032e010 Rename methods to reflect on recent change 2023-06-17 21:09:58 +02:00
NEZNAMY 80c4316826 Use Player#getPing() instead of NMS for 1.17+ where it was added 2023-06-17 21:01:02 +02:00
NEZNAMY 3addeba256 Bump bridge protocol 2023-06-17 17:43:21 +02:00
NEZNAMY c52db733b7 Fix potential issue with spectator fix not working if joining with spectator gamemode 2023-06-17 17:42:46 +02:00
NEZNAMY 07a492e353 Forward gamemode from bridge for spectator fix to work on online mode bungee (#934) 2023-06-17 17:42:03 +02:00
NEZNAMY 3c1ec478c2 Small code cleanup using lombok 2023-06-17 11:25:42 +02:00
NEZNAMY f3f614c3de Fix spacing 2023-06-16 17:27:50 +02:00
NEZNAMY a6627ac6c6 Merge pull request #933 from Golfing7/master
Fix loading on velocity
2023-06-16 17:26:14 +02:00
Golfing8 8d1040518f Fix loading on velocity 2023-06-16 11:11:20 -04:00
NEZNAMY ca5d17e6ec Merge pull request #930 from NEZNAMY/v4
Merge v4
2023-06-16 09:08:55 +02:00
NEZNAMY b9fab42510 Update supported version range in error message 2023-06-15 17:31:18 +02:00
NEZNAMY 22f1ef43c4 Add missing return to fix error (#927) 2023-06-15 09:44:14 +02:00
NEZNAMY ffbd4bf26b Move bungee component conversion to shared 2023-06-14 17:59:13 +02:00
NEZNAMY 4d6f93e975 Build adventure components with ProtocolVersion for manually defined legacy colors to actually work 2023-06-14 12:23:51 +02:00
NEZNAMY cb45cff77f 4.0.2-SNAPSHOT 2023-06-14 12:22:29 +02:00
NEZNAMY 4718040345 4.0.1 2023-06-13 00:11:20 +02:00
NEZNAMY afffefcce1 1.20.1 2023-06-13 00:11:10 +02:00
NEZNAMY 4580f47563 Fix bungee kick on 1.7 (#921) 2023-06-12 22:41:07 +02:00
NEZNAMY e51f4bb3a1 Remove unused methods 2023-06-12 13:34:30 +02:00
NEZNAMY e8c8d1dee7 Fix TabComplete on Sponge 7 2023-06-11 19:21:54 +02:00
NEZNAMY 3559afaef7 Fix TabComplete on Fabric 2023-06-11 18:26:39 +02:00
NEZNAMY fc29420eb3 Fix TabComplete on Sponge 8+ 2023-06-11 17:09:42 +02:00
NEZNAMY 023cd3fb75 4.0.0 2023-06-08 14:16:19 +02:00
NEZNAMY 2781d9f232 Fix errors when platform doesn't support unlimited nametags, but it's enabled in config 2023-06-08 14:15:34 +02:00
NEZNAMY d31e5de449 Fix NPE 2023-06-08 13:59:36 +02:00
NEZNAMY 245fcdf917 Update to 1.20 2023-06-08 13:50:47 +02:00
NEZNAMY e3ef3ffa68 Refactor scoreboard command and change /tab announce scoreboard to /tab scoreboard announce 2023-06-07 14:04:36 +02:00
NEZNAMY 95c3608c3f Fix typo 2023-06-07 14:03:34 +02:00
NEZNAMY 7c2236dc96 Not ready yet 2023-06-07 14:03:23 +02:00
NEZNAMY b83ef0e352 API - Add functions for force-updating placeholder values 2023-06-06 11:49:49 +02:00
NEZNAMY 2865871d04 Add check for ViaVersion bug returning -1 version 2023-06-06 11:30:42 +02:00
NEZNAMY 7f7b76a11e Fabric - Remove multi version class 2023-05-28 20:30:20 +02:00
NEZNAMY 52569e4c65 Create method in event listener class for replacing player instead of manually creating it in every class 2023-05-28 20:18:06 +02:00
NEZNAMY 0a0ae6c83b Fabric - Replace player object on respawn because it changes 2023-05-28 20:13:40 +02:00
NEZNAMY 6c8a41388e Unlimited NameTags - Fix disable-condition not working properly when set for the main feature 2023-05-28 16:43:52 +02:00
NEZNAMY fe94e33d85 Use PremiumVanish API code directly instead of reflection 2023-05-28 15:40:33 +02:00
NEZNAMY ca1be457cf Remove error message that was never actually sent 2023-05-25 21:20:22 +02:00
NEZNAMY 550b6350ea Change server version info into a method instead of field and provide more info 2023-05-25 13:38:42 +02:00
NEZNAMY 76470c880d Create player object on join async (broke it in a recode) 2023-05-25 12:23:48 +02:00
NEZNAMY a315bd88b3 Fix MySQL 2023-05-24 21:25:05 +02:00
NEZNAMY bb62930525 Simplify permission plugin data structure 2023-05-24 19:05:43 +02:00
NEZNAMY b7490f0002 Rename a few methods and fields 2023-05-24 13:21:56 +02:00
NEZNAMY 42f3851339 API - Small improvements/fixes and more documentation 2023-05-24 12:37:20 +02:00
NEZNAMY 34f39ac8d5 Fix compilation 2023-05-23 13:02:34 +02:00
NEZNAMY 8c16330119 API - Remove getApiVersion method, since everyone should be up-to-date and users are unlikely to check for it anyway 2023-05-23 12:56:33 +02:00
NEZNAMY 8323c21c3e Move ProtocolVersion enum out of API 2023-05-23 12:49:56 +02:00
NEZNAMY 2a3ca932a4 API - Add functions for unregistering placeholders 2023-05-23 12:41:48 +02:00
NEZNAMY e339928caa Conditions - Fix startsWith and endsWith types (how could they even have worked before?) 2023-05-23 12:40:22 +02:00
NEZNAMY 3eeb025f23 Add API for Layout and move team names to a new sorting class 2023-05-22 21:03:28 +02:00
NEZNAMY f19c1f1baa Another way of breaking the plugin was found by a customer 2023-05-20 18:56:17 +02:00
NEZNAMY 003e6a6adb Forward placeholder output replacements to bridge 2023-05-18 12:01:19 +02:00
NEZNAMY 95d435d61c Create field for viewer instead of passing as parameter 2023-05-17 14:25:19 +02:00
NEZNAMY bbc4e1d767 Unlimited nametags - Compensate for new 1.19.4 bug calling sneak event on vehicle leave with value "true", but never calling with "false" (#894) 2023-05-17 14:01:41 +02:00
NEZNAMY ae46adf8b9 Layout - Make layouts per-player, allowing hiding vanished players and opening new possibilities for the future 2023-05-17 13:31:02 +02:00
NEZNAMY 461ef988d3 Make Platform class an interface and make each implementation override sendConsoleMessage 2023-05-16 20:33:57 +02:00
NEZNAMY 307d21cc85 Remove nickname field, since plugin doesn't track name changes anymore 2023-05-16 19:01:51 +02:00
NEZNAMY e2beac6570 A couple of fixes for disable-conditions 2023-05-16 18:48:02 +02:00
NEZNAMY 75e455f078 Replace NonNull annotation with NotNull for internal methods 2023-05-16 12:52:04 +02:00
NEZNAMY 19c832d370 Rename a few classes 2023-05-16 11:34:02 +02:00
NEZNAMY 9cd4afe1d4 Rework disabled worlds/servers into disable conditions 2023-05-16 11:32:37 +02:00
NEZNAMY 3b00f07f78 Unlimited NameTags - Update visibility on vehicle enter/leave instantly (also maybe fix #894?) 2023-05-16 11:25:15 +02:00
NEZNAMY 0b5008c087 Remove unused fields 2023-05-14 21:59:44 +02:00
NEZNAMY 76f210db03 Print console warn if some placeholder's usage exceeds 50% 2023-05-14 17:43:29 +02:00
NEZNAMY 85c8d9f1b9 Bukkit - Add ViaRewind to softdepend to avoid console warn 2023-05-14 17:12:02 +02:00
NEZNAMY a795fc7f77 BossBar - Send console warn if progress could not be evaluated to a number between 0 and 100 2023-05-14 17:10:39 +02:00
NEZNAMY 7742ab8220 Add native support for multi-character symbols for aligned tabsuffix 2023-05-13 13:18:12 +02:00
NEZNAMY 3e235a8f18 Construct packet class with null title instead of empty string for unregister 2023-05-11 23:56:50 +02:00
NEZNAMY 30f9888f6a Split layout loading into multiple methods for better readability 2023-05-11 19:14:58 +02:00
NEZNAMY d1f8886e2b Layout - Add misconfiguration checks 2023-05-11 16:56:01 +02:00
NEZNAMY 3c037f9aa6 Create and use enums for team visibility and collision 2023-05-11 15:16:45 +02:00
NEZNAMY c70346c57c Fix NPE in injection when player is not loaded yet (#891) 2023-05-09 22:16:36 +02:00
NEZNAMY bd40dd85af Global PlayerList - Properly display players on other servers as spectators if enabled (#890) 2023-05-09 16:42:21 +02:00
NEZNAMY eacd929b0f Remove redundant fully qualified name of imported classes 2023-05-04 01:04:31 +02:00
NEZNAMY 0ff5f17b7d Create and use more constants instead of literal strings 2023-05-04 00:57:46 +02:00
NEZNAMY 57fa01151e Move command implementation for platforms into separate classes instead of being a nested class inside main class 2023-05-04 00:29:51 +02:00
NEZNAMY e7bc1fc74b Move sendPlayerListHeaderFooter method from TabPlayer to TabList 2023-04-29 21:32:40 +02:00
NEZNAMY 897f35ab53 Remove BulkUpdateTabList class and make all implementations update entries one by one 2023-04-29 16:32:51 +02:00
NEZNAMY 7f8b738a69 Add more NotNull / NonNull / Nullable annotations to methods 2023-04-29 15:10:30 +02:00
NEZNAMY 079302fb05 Small code cleanup 2023-04-28 23:31:31 +02:00
NEZNAMY 630fcc9e50 Remove underscore from class names 2023-04-27 16:08:20 +02:00
NEZNAMY c1601ca487 Remove nick compatibility hook, as it should no longer be needed 2023-04-27 14:03:47 +02:00
NEZNAMY d035b9cb80 Fix NPE 2023-04-27 13:20:49 +02:00
NEZNAMY 8db5e4d8ba Add NotNull / NonNull / Nullable annotations to fields and methods 2023-04-26 15:33:06 +02:00
NEZNAMY 4d51bb39d7 Print warn if both global playerlist and layout are enabled 2023-04-25 23:19:16 +02:00
NEZNAMY 7eb0231e08 Move floodgate hook into a separate class 2023-04-25 22:57:30 +02:00
NEZNAMY 6412461576 Simplify 2023-04-25 19:46:07 +02:00
NEZNAMY 5732eb366b Remove unused fields and methods 2023-04-25 19:36:03 +02:00
NEZNAMY ed3df8bb68 Recode redisbungee support and fix many bugs 2023-04-25 19:07:13 +02:00
NEZNAMY 787f531203 Remove unused fields 2023-04-25 19:00:57 +02:00
NEZNAMY cf5d888901 Remove unused parameter 2023-04-23 22:08:59 +02:00
NEZNAMY 1969e5f755 Global playerlist - Remove redundant entry removal on server switch (proxy removes it) 2023-04-23 15:57:43 +02:00
NEZNAMY 8d12ee0958 Remove unused import 2023-04-23 15:57:10 +02:00
NEZNAMY c3bbc89c5b Add final modifier where possible 2023-04-23 15:56:57 +02:00
NEZNAMY 625c7cf3c2 Fix issue with legacy color codes 2023-04-23 11:58:35 +02:00
NEZNAMY 14f0321992 Reduce static usage 2023-04-22 22:43:25 +02:00
NEZNAMY e5294c596a Change way of detection for presence of other plugins 2023-04-22 21:04:57 +02:00
NEZNAMY c83290a99a Fix error in RedisBungee 2023-04-22 20:56:48 +02:00
NEZNAMY 8c66310af0 Add RedisBungee support to Velocity as well 2023-04-22 19:17:05 +02:00
NEZNAMY 5ae91bf89e Update config comment (global playerlist will no longer duplicate players if this issue occurs) 2023-04-22 13:44:13 +02:00
NEZNAMY d5dc1b7bdb Simplify 2023-04-22 13:39:12 +02:00
NEZNAMY 864eee3349 Spectator Fix - Resend on server switch 2023-04-22 13:32:43 +02:00
NEZNAMY 88932e3a5e Move bungee component conversion out of shared to avoid class not found error 2023-04-20 21:59:04 +02:00
NEZNAMY 4ebc60ff00 Print original error instead of the current one 2023-04-20 21:43:05 +02:00
NEZNAMY b0cb63b05d Remove weird code in error printing 2023-04-20 21:19:08 +02:00
NEZNAMY 1db40ee2d5 Fix layout loading 2023-04-19 21:20:50 +02:00
NEZNAMY fd3f0ebd21 Move classes into packages 2023-04-19 11:46:22 +02:00
NEZNAMY ce73069345 Remove hover/click event from chat components 2023-04-18 13:54:06 +02:00
NEZNAMY 088f2748e3 Print amount of startup warns into the console 2023-04-17 20:39:35 +02:00
NEZNAMY d9a8c69f43 Refactor ViaVersion hook and drop ProtocolSupport hook as the plugin is abandoned 2023-04-17 19:23:54 +02:00
NEZNAMY 16ff503b6a Add back task queue while plugin is loading 2023-04-17 18:20:54 +02:00
NEZNAMY 68c78b9c73 Make field public 2023-04-17 18:04:17 +02:00
NEZNAMY 0c9d78a644 Fix method name 2023-04-15 18:59:54 +02:00
NEZNAMY 99d22642e2 Scoreboard - Fix placeholders not being updated in title on scoreboard switch 2023-04-15 15:22:02 +02:00
NEZNAMY dc762eacf8 Fill all fields in plugin.yml 2023-04-13 20:47:01 +02:00
NEZNAMY 5a44f30140 Reorder permission constants 2023-04-13 20:37:53 +02:00
NEZNAMY 82e86b0f8a Fix NPE on reload 2023-04-13 18:02:21 +02:00
NEZNAMY 9c4eb4359c Document empty methods 2023-04-12 21:53:32 +02:00
NEZNAMY 827c380463 Move more reflection related methods to ReflectionUtils 2023-04-12 21:50:01 +02:00
NEZNAMY 7c4fc324c8 Simplify 2023-04-12 21:18:29 +02:00
NEZNAMY 46215f3304 Fix indentation 2023-04-12 21:15:16 +02:00
NEZNAMY 1accc21365 Avoid possible NPE 2023-04-12 21:11:29 +02:00
NEZNAMY b74c2f62f7 Replace star import with explicit imports 2023-04-12 21:08:38 +02:00
NEZNAMY 9d14c0c923 Resend header/footer on server switch because velocity clears it 2023-04-12 16:17:12 +02:00
NEZNAMY 650fda5781 Reorder class loading to make it cleaner 2023-04-11 16:43:40 +02:00
NEZNAMY 286ccf5836 Reorder class loading to make it cleaner 2023-04-10 19:08:54 +02:00
NEZNAMY dfa310666c Move reflection related methods to ReflectionUtils 2023-04-10 19:02:35 +02:00
NEZNAMY 06595241ab Remove plugins from softdepend which are no longer being hooked into 2023-04-10 18:38:57 +02:00
NEZNAMY 0f80dd1cfd Simplify 2023-04-10 18:33:02 +02:00
NEZNAMY 7bc5be264c Define dependencies directly instead of using versions file 2023-04-10 16:23:44 +02:00
NEZNAMY e31784fb1e Include initial task delay to prevent errors while plugin is still loading 2023-04-10 13:15:14 +02:00
NEZNAMY ae156f424b Move layout to config.yml 2023-04-10 13:11:41 +02:00
NEZNAMY cfe0b3883e Remove deleted placeholder from default configuration 2023-04-10 12:49:54 +02:00
NEZNAMY fc6beaa0a5 Add removing of removed config option to converter 2023-04-10 12:45:11 +02:00
NEZNAMY 5f2140b147 Make placeholder output replacements no longer require splitting config section with each "." used in placeholder 2023-04-10 12:43:28 +02:00
NEZNAMY c497bdff39 Swap condition registration order for proper detection of type 2023-04-10 12:22:16 +02:00
NEZNAMY 7c84b6432e Simplify condition classes (or maybe just make them more complicated?) 2023-04-10 01:21:14 +02:00
NEZNAMY 3f787c3b0b Create separate Platform class for consistency 2023-04-10 00:00:32 +02:00
NEZNAMY 2046a39e99 Simplify 2023-04-09 23:42:32 +02:00
NEZNAMY 2ccf89e396 Further simplify Fabric code changes for older server versions 2023-04-08 22:45:43 +02:00
NEZNAMY efaebc3cb0 Simplify code changes for older versions on Fabric 2023-04-08 17:03:56 +02:00
NEZNAMY d7c952cc36 Fix placeholders from bridge not updating if player is not loaded yet when response is sent 2023-04-08 15:19:56 +02:00
NEZNAMY 1d3ea37129 Prevent bridge form re-registering placeholders that got deleted from config 2023-04-08 15:06:58 +02:00
NEZNAMY 1e9c47398d Add bridge connection status to debug command 2023-04-08 14:43:05 +02:00
NEZNAMY 5a1f48f1a5 Apparently it cannot be null 2023-04-08 14:25:03 +02:00
NEZNAMY ed65554d30 Remove duplication in player/playeruuid/group commands 2023-04-07 22:36:35 +02:00
NEZNAMY 0f19970401 Clean up ChatModifier serialization 2023-04-07 22:04:57 +02:00
NEZNAMY b419499710 Remove unnecessary fully qualified name 2023-04-07 21:58:38 +02:00
NEZNAMY 14a5f30b74 Split method for processing plugin messages into multiple 2023-04-07 21:48:38 +02:00
NEZNAMY 302cdf200f Small refactor of classes implemented by platforms 2023-04-07 21:32:15 +02:00
NEZNAMY bdde257cac Remove unused fields 2023-04-07 13:01:25 +02:00
NEZNAMY 73af013bca Change usage of methods which didn't exist before on fabric 2023-04-06 18:26:26 +02:00
Callum Seabrook e421427007 Disabled access widener validation task for Fabric 2023-04-06 16:17:51 +01:00
NEZNAMY 169a180d68 Remove unused imports 2023-04-06 16:28:28 +02:00
Callum Seabrook 16a19bf578 Switched to access wideners for player info entries on Fabric 2023-04-06 14:29:43 +01:00
Callum Seabrook 5b39204a8a Cleaned up Krypton code 2023-04-06 13:54:54 +01:00
Callum Seabrook b2bb125248 Switched Krypton tab list to API and removed server dependency 2023-04-06 13:35:08 +01:00
NEZNAMY 980354104b Remove fabric constant that is only used once 2023-04-06 00:18:15 +02:00
NEZNAMY b27571dcaa Catch UnsupportedOperationException 2023-04-05 22:27:44 +02:00
NEZNAMY b215bf9000 Fix dumb mistake 2023-04-05 21:10:04 +02:00
NEZNAMY ab75b13b3f Add option to choose target minecraft version on Fabric all the way down to 1.17 2023-04-05 20:42:51 +02:00
Callum Seabrook 31cd2aeb08 Made getFeature generic and removed casts 2023-04-05 19:18:39 +01:00
Callum Seabrook 8b6b33b314 Fixed compile 2023-04-05 18:40:10 +01:00
Callum Seabrook 1b66257ece Removed chat session from ProxyTabPlayer 2023-04-05 18:30:52 +01:00
Callum Seabrook bed9fcf212 Show new blank scoreboard to joining players on Krypton 2023-04-05 18:22:01 +01:00
Callum Seabrook 692f309750 Switched to API instead of packets for Krypton scoreboard 2023-04-05 16:30:19 +01:00
Callum Seabrook 2c9c9b502a Renamed Main to KryptonTAB for consistency 2023-04-05 15:48:50 +01:00
Callum Seabrook 3da8fd2a77 Fixed failed startup without Spark present on Krypton 2023-04-05 15:45:56 +01:00
Callum Seabrook ba6826f3d1 Added variable to change target Minecraft version for Fabric 2023-04-05 12:19:59 +01:00
Callum Seabrook 68b3629437 Added permissions API support for Fabric 2023-04-05 12:08:32 +01:00
Callum Seabrook 8bc5962d1c Use reflection for changing player info entries 2023-04-05 11:55:25 +01:00
NEZNAMY b8aa1982e4 Improve ViaVersion check on Fabric 2023-04-05 00:57:35 +02:00
NEZNAMY e0a427732e Update README.md 2023-04-04 23:25:38 +02:00
NEZNAMY 8d1f60f5fa Fix github actions 2023-04-04 23:16:15 +02:00
NEZNAMY 5cd7fdf385 Small improvements and fixes to fabric 2023-04-04 23:14:51 +02:00
Callum Seabrook e54d342ac5 Made relocations have a consistent pattern 2023-04-04 21:30:52 +01:00
Callum Seabrook 9019261c2a Fabric support 2023-04-04 21:27:55 +01:00
Callum Seabrook b1a5092053 Added Adventure-based boss bar handler for platforms using Adventure 2023-04-04 20:11:27 +01:00
NEZNAMY ef8bdbb40f Spectator fix - Add delay on join to avoid being too early 2023-04-04 21:08:19 +02:00
Callum Seabrook 0d67826b3d Removed message component cache on Bukkit 2023-04-04 19:34:24 +01:00
NEZNAMY 6c99e28d51 Improve code style in Scoreboard class 2023-04-04 17:21:38 +02:00
NEZNAMY 13931aafa5 Rethrow exceptions as IllegalStateException instead of RuntimeException 2023-04-04 17:01:17 +02:00
NEZNAMY 089e7ce8b5 Move class out of package 2023-04-04 15:52:01 +02:00
NEZNAMY 54287c8a29 Fix color getter 2023-04-04 15:41:18 +02:00
NEZNAMY 5ebc5dee21 Make gamemode change detection a periodic task instead of listening to packets 2023-04-04 15:29:34 +02:00
NEZNAMY bedbdbcca9 Remove redundant interface class 2023-04-04 14:44:37 +02:00
NEZNAMY a1c35adf4c Convert to adventure components directly instead of deserializing string 2023-04-04 14:34:56 +02:00
NEZNAMY 81b6a9be8b Remove redundant component deserialization attempts 2023-04-04 13:50:21 +02:00
Callum Seabrook 88eee58329 Moved chat system out of API 2023-04-02 22:49:15 +01:00
Callum Seabrook 2f02a5bda4 Removed unlimited nametags from Krypton 2023-04-02 21:11:05 +01:00
Callum Seabrook ba716df634 Removed unlimited nametags from Sponge 8 2023-04-02 20:12:30 +01:00
NEZNAMY 988292b82a XD 2023-04-02 16:30:06 +02:00
Callum Seabrook d52cfdd6e6 Start of Fabric 2023-04-02 13:55:38 +01:00
Callum Seabrook b13a49539f Updated to Gradle 8 2023-04-02 13:47:37 +01:00
NEZNAMY 32a39a361c Improve marking vanish placeholder as used for features listening to vanish status change 2023-04-02 13:46:20 +02:00
NEZNAMY 0e2e9b9ae6 Fix playerlist formatting not updating on unvanish 2023-04-02 13:41:14 +02:00
NEZNAMY 331faefde2 Fix compilation 2023-04-02 12:57:46 +02:00
NEZNAMY 1603ebe9fc Remove unused parameter 2023-04-02 12:43:15 +02:00
NEZNAMY bad4359469 Remove usage of separated initializers 2023-04-02 12:17:16 +02:00
NEZNAMY a860b463ed Merge ifs 2023-04-02 12:13:01 +02:00
NEZNAMY b3b0a96bb8 Remove commented out code that will never come back 2023-04-02 12:11:20 +02:00
NEZNAMY c211724d13 RedisBungee - Don't send yellow number / belowname if feature is disabled (#861) 2023-04-02 12:02:01 +02:00
NEZNAMY 0fb9a832ca Fix raw generic use 2023-04-02 00:34:42 +02:00
NEZNAMY 7ce1a97c93 Remove player from map on quit 2023-04-02 00:10:33 +02:00
NEZNAMY 1d461c1adf Make Scoreboard class generic to avoid massive casting 2023-04-02 00:02:31 +02:00
NEZNAMY 5ec09c37bc Remove things from API which shouldn't be there 2023-04-01 22:10:11 +02:00
NEZNAMY 95a20766c3 Simplify redisbungee belowname/yellow number forwarding 2023-04-01 17:41:25 +02:00
NEZNAMY 87feb1c2bf Improve misconfiguration checks and management 2023-04-01 17:33:34 +02:00
NEZNAMY 8c732ac7e9 Use defined constant instead of literal string 2023-04-01 13:01:26 +02:00
NEZNAMY 977c1f4d74 Remove unused field 2023-04-01 12:46:04 +02:00
NEZNAMY 65ac22aadb Perform scoreboard objective & team re-registration on server switch instead of listening to Login packet, which is assumed to be sent always 2023-04-01 12:37:02 +02:00
NEZNAMY 8e7a14bdb8 PlayerList - Format players after they un-vanish 2023-04-01 12:07:19 +02:00
NEZNAMY 4693a297b6 Remove unused field 2023-04-01 01:41:03 +02:00
NEZNAMY af69dcd9b5 Add this branch to github actions 2023-04-01 01:20:56 +02:00
NEZNAMY 71110fc722 Remove redundant conversion from older versions 2023-04-01 01:16:50 +02:00
NEZNAMY c2af5632a2 Remove hidden ghost player fix feature 2023-04-01 01:13:21 +02:00
NEZNAMY 399e813ca4 Remove placeholder refresh intervals categories to reduce confusion, split them in code based on identifier 2023-04-01 01:10:05 +02:00
NEZNAMY daac7c6171 Rename config conversion methods 2023-04-01 00:52:30 +02:00
NEZNAMY 940352ef2c Replace null checks with @NonNull 2023-04-01 00:47:21 +02:00
NEZNAMY c70b909c0f Remove disabled worlds/servers from bossbar and scoreboard, since conditions can achieve the same 2023-04-01 00:43:36 +02:00
NEZNAMY dcc2eb9217 Remove vault hook, vault placeholders and %afk% placeholder 2023-04-01 00:34:12 +02:00
NEZNAMY 5425b3b6ea Finish previous commit and remove pet fix feature 2023-04-01 00:17:48 +02:00
NEZNAMY a90ea3e3fa Remove ping spoof feature 2023-04-01 00:03:21 +02:00
NEZNAMY 6d52b7b615 4.0.0-SNAPSHOT 2023-04-01 00:01:43 +02:00
NEZNAMY 51635a7322 3.3.2 2023-03-31 20:44:09 +02:00
NEZNAMY 481b33ba55 Print error message if plugin message could not be sent 2023-03-31 15:30:30 +02:00
NEZNAMY 22c785fc99 Add error message when plugin message could not be processed 2023-03-31 15:21:53 +02:00
NEZNAMY 42d4159b69 Global PlayerList - Register placeholders in constructor to avoid it being registered as PAPI placeholder 2023-03-31 14:41:21 +02:00
NEZNAMY 6d95a2f06d Fix error on concurrent access 2023-03-31 13:40:50 +02:00
NEZNAMY 7f0b1d8a2e Fix rare error on /btab reload 2023-03-31 13:40:37 +02:00
NEZNAMY a3fecd0fea Unregister tab expansion on unload to fix compatibility with latest PAPI release 2023-03-30 21:17:09 +02:00
NEZNAMY f3d6a54a2a Merge remote-tracking branch 'origin/master' 2023-03-29 17:24:21 +02:00
NEZNAMY 1d434f2557 Add more documentation 2023-03-29 17:24:11 +02:00
NEZNAMY b3500086e4 Merge pull request #856 from zelvalea/master
optimizations in CPUManager
2023-03-28 23:23:48 +02:00
Amoeba bf9202af38 added time constants 2023-03-28 20:31:29 +03:00
Amoeba bd2c683568 fixed happens before and cpu usage statistics 2023-03-28 20:09:51 +03:00
Amoeba c03feaab23 fixed nanosToPercent 2023-03-28 19:44:11 +03:00
Amoeba 9cb9ccbd2a optimize 2023-03-28 19:21:48 +03:00
Callum Seabrook 4606ebd588 Use single thread for tasks and remove ThreadManager from API 2023-03-28 12:32:13 +01:00
Callum Seabrook 679be83c5a Merge pull request #854 from zelvalea/master 2023-03-28 11:51:03 +01:00
NEZNAMY afe868bb95 Fix group update through bridge after recoding group updating 2023-03-28 01:21:29 +02:00
ZelvaLea c9ce3aa23e reduced number of threads in the pool, fixed races 2023-03-28 01:15:04 +03:00
NEZNAMY 11a49c4874 Remove unnecessary full import 2023-03-27 21:21:27 +02:00
NEZNAMY 65d2a0fba9 Remove unused field 2023-03-27 21:19:15 +02:00
NEZNAMY c1219195c7 Remove workarounds for fixing compilation, which are no longer needed 2023-03-26 17:06:57 +02:00
NEZNAMY fca0dfc91b More constant extraction to plugin.yml & bungee.yml 2023-03-26 17:02:32 +02:00
NEZNAMY 7f1cc3063c Move text cutting to 16/32 characters to avoid duplication 2023-03-26 16:53:47 +02:00
NEZNAMY e444c25287 Convert krypton to java 2023-03-26 16:36:51 +02:00
NEZNAMY 476354e407 Change thrown exception 2023-03-25 23:25:07 +01:00
NEZNAMY 9f84d3f22f Remove cpu measurement of chosen methods 2023-03-25 23:22:28 +01:00
NEZNAMY 4608ff360c Simplify 2023-03-25 23:12:48 +01:00
NEZNAMY 68b12e199d Placeholders - Measure per-placeholder cpu usage on join as well 2023-03-25 20:54:53 +01:00
NEZNAMY 4b1151f769 Use defined value instead of duplicating it in build settings 2023-03-25 20:25:27 +01:00
NEZNAMY 6687214f2a Sponge - Add support all the way down to Sponge 5 2023-03-25 19:22:07 +01:00
NEZNAMY a57757258e Sponge - Use API for scoreboards instead of packets (also small bug fix) 2023-03-25 18:41:56 +01:00
NEZNAMY 3a6060c45d Fix display name change on 1.7 2023-03-25 14:29:27 +01:00
NEZNAMY ee375c1b60 Unify tablist management between proxies 2023-03-25 14:22:40 +01:00
NEZNAMY c9d870cca0 Use placeholder refreshing engine for refreshing player groups instead of creating another thread 2023-03-23 14:52:19 +01:00
NEZNAMY 3ad8015cc1 Placeholder manager - Initialize task with the lowest refresh interval immediately instead of re-initializing 2023-03-23 14:19:42 +01:00
NEZNAMY 33609c322f Remove duplicated Field#setAccessible 2023-03-22 00:59:02 +01:00
NEZNAMY 431b89c487 Create constant for "textures" String in skin data 2023-03-22 00:33:16 +01:00
NEZNAMY 35a146992c Remove redundant checks and simplify 2023-03-22 00:27:46 +01:00
NEZNAMY dedee114c4 BungeeCord - Split boss bar handler into 2 classes 2023-03-21 20:07:11 +01:00
NEZNAMY 9d42af0388 Bukkit - Split boss bar handler into 3 classes 2023-03-21 18:39:08 +01:00
NEZNAMY 8f5d81bc33 Remove redundant annotation 2023-03-21 18:38:41 +01:00
NEZNAMY b17f5563dd Remove unused method 2023-03-21 14:09:57 +01:00
NEZNAMY 0ab8bb363a Unlimited NameTags - Force marker tag for 1.8.x and remove config option 2023-03-20 22:33:56 +01:00
NEZNAMY ac5fca86bd Split TabFeature into multiple interfaces based on used methods 2023-03-20 19:36:40 +01:00
NEZNAMY 28c2c2e193 Fix armor stand metadata on spawn 2023-03-20 16:25:37 +01:00
NEZNAMY 904c0b6a17 Fix anti-override for tablist name formatting (and possibly ping spoof & spectator fix) 2023-03-20 16:21:23 +01:00
NEZNAMY f3c31bc92c Fix error 2023-03-20 12:42:42 +01:00
NEZNAMY 6016b84889 BungeeCord - Fix bossbar color & style update 2023-03-19 22:24:13 +01:00
NEZNAMY cfb5cb3a9f Create object for calling bossbar methods 2023-03-19 22:07:45 +01:00
NEZNAMY 1746f6b1d0 Bukkit - Send all tablist packets grouped, ViaVersion splits them properly for 1.7 players 2023-03-19 21:21:33 +01:00
NEZNAMY 9c3979a0d9 More tablist fixes on 1.7 2023-03-19 21:04:52 +01:00
NEZNAMY 810676c69f Bukkit - Fix NPE on <1.8 servers 2023-03-19 16:44:55 +01:00
NEZNAMY d0892a245a BungeeCord - Fix NPE kick on 1.7 2023-03-19 16:40:53 +01:00
NEZNAMY f539b1b93b BungeeCord - Split TabList class into 3 based on version & make 1.7 actually work (potential future use?) 2023-03-19 14:50:02 +01:00
NEZNAMY adfa64a29f Scoreboard - Fix unregistering teams of lines that aren't displayed due to placeholder output being empty 2023-03-19 14:07:44 +01:00
NEZNAMY d4f86ee79d Remove redundant declaration 2023-03-19 13:43:06 +01:00
NEZNAMY 6ebe31b737 Add @NonNull / @Nullable annotations to TeamManager (#843) 2023-03-19 13:38:58 +01:00
NEZNAMY dcbd5e62d4 Fix packet un-cancel breaking PetFix (#842) 2023-03-19 13:26:24 +01:00
NEZNAMY a7e6e49363 Fix #845 (1.7 requires non-null title in scoreboard unregister action) 2023-03-19 12:52:56 +01:00
NEZNAMY d115257ff7 Move DisplaySlot class inside Scoreboard 2023-03-18 23:53:49 +01:00
NEZNAMY d578be276c Remove duplicated caches 2023-03-18 22:35:16 +01:00
NEZNAMY e338f57441 Completely get rid of PacketBuilder class 2023-03-18 22:25:05 +01:00
Callum Seabrook c87321b5b0 Rewrote packet injection for Krypton 2023-03-18 19:37:34 +00:00
NEZNAMY 84bb9b449b Add methods for manipulating entities instead of using sendPacket 2023-03-18 19:22:29 +01:00
NEZNAMY 9d613fc24d Rework tablist packet management to make it more API-style 2023-03-18 17:44:43 +01:00
NEZNAMY 3f2ae3131e Add back a default animation, which is still used in default scoreboard 2023-03-18 00:14:56 +01:00
NEZNAMY 0e9f53bd58 Fix wrong action on objective unregister 2023-03-17 18:20:47 +01:00
NEZNAMY 3981815b63 Create Scoreboard interface for calling scoreboard-related methods 2023-03-17 15:04:55 +01:00
NEZNAMY 3ef99e4e7c Better abstraction of pipeline injection 2023-03-16 15:16:24 +01:00
NEZNAMY 76767a0958 Use API-style managing of scoreboard teams 2023-03-16 13:53:50 +01:00
NEZNAMY 1683943d58 Use API-style managing of scoreboard objectives 2023-03-16 01:07:21 +01:00
NEZNAMY cc0dbe8623 Move sendPluginMessage method to ProxyTabPlayer 2023-03-16 00:03:13 +01:00
NEZNAMY b056251e07 Remove calculating of packets sent by the plugin 2023-03-15 23:50:23 +01:00
NEZNAMY 3b352c66e2 Change way how scoreboard score and display objective packets are sent 2023-03-15 23:31:30 +01:00
NEZNAMY b4f0ea73c1 Supplier with Exception is Callable 2023-03-15 21:43:27 +01:00
NEZNAMY 1c683788b5 BungeeCord - Create cleaner methods for player info action conversion 2023-03-15 21:29:58 +01:00
NEZNAMY 250597df2d Sponge 8 - Fix class cast exception 2023-03-15 21:07:20 +01:00
NEZNAMY 0d2d1d5aaa Sponge 8 - Use direct code instead of reflection for entity teleport packet 2023-03-15 21:00:42 +01:00
NEZNAMY 061375d1e7 3.3.2-SNAPSHOT 2023-03-15 21:00:14 +01:00
NEZNAMY 5b05614305 Remove unused field 2023-03-15 20:13:29 +01:00
NEZNAMY 69db2e0e53 Use API style code for bossbars since packets were not used anymore 2023-03-15 20:03:10 +01:00
NEZNAMY 00ef364324 Use APIs for header/footer instead of packets where possible (rip bukkit) 2023-03-15 16:13:31 +01:00
NEZNAMY de68312b6b Use APIs for chat messages instead of packets 2023-03-15 14:36:25 +01:00
NEZNAMY ddac08bcbc Fix bungee compilation (did md5 break something?) 2023-03-15 14:31:59 +01:00
NEZNAMY 517e285bb3 Fix bossbar error on <1.9 from recode 2023-03-15 14:29:13 +01:00
NEZNAMY 81a08a6b51 3.3.1 2023-03-14 19:18:01 +01:00
NEZNAMY 4dfef1d032 1.19.4 support 2023-03-14 19:15:15 +01:00
NEZNAMY 5d38e28cae Extract more constants and add config option 2023-03-14 18:35:25 +01:00
NEZNAMY 66a12d10c4 Layout - Resend on server switch on Velocity 2023-03-14 17:27:27 +01:00
NEZNAMY 1a4027c8d5 Remove unused fields and methods 2023-03-14 16:15:55 +01:00
NEZNAMY 2a0243c51a RedisSupport - Add missing packet source 2023-03-14 15:24:13 +01:00
NEZNAMY 4851d09e70 More abstraction of unlimited nametag mode & packets it uses 2023-03-14 15:20:49 +01:00
NEZNAMY 3cdf3accfd Remove redundant checks 2023-03-14 10:46:27 +01:00
NEZNAMY fd1f094216 Layout - Small cleanup in code 2023-03-14 00:22:02 +01:00
NEZNAMY 25ece1ecb8 Move ViaVersion hook (and remove safety checks, hopefully it works correctly now) 2023-03-13 23:31:10 +01:00
NEZNAMY 802e65c280 Change constructor fields to getters in features 2023-03-13 23:04:22 +01:00
NEZNAMY 882688f056 Layout - Cache remove packet 2023-03-13 21:52:29 +01:00
NEZNAMY 97d60d0ab3 Bungee - Remove unused field (and simplify) 2023-03-13 21:33:48 +01:00
NEZNAMY 9ef99daed1 Revert feature loading as references were not null when they were supposed to be 2023-03-13 21:31:48 +01:00
NEZNAMY 71c85d9d39 NameTags - Speed up unloading 2023-03-13 19:36:05 +01:00
NEZNAMY b981ab46be Add debug messages about feature unloading times 2023-03-13 19:35:45 +01:00
NEZNAMY 016633e494 BelowName - Speed up reloads by caching values for players (tested with 100 bots, reloads were 2x faster) 2023-03-13 19:22:00 +01:00
NEZNAMY 1db862ab56 NameTags - Speed up reloading (tested with 100 bots, reload was 3x faster) 2023-03-13 19:15:45 +01:00
NEZNAMY 3563786310 PlayerList - Drastically speed up reloads (up to 10+ times with high player counts) 2023-03-13 19:01:26 +01:00
NEZNAMY ac8851dd6a Cache EnumSets for info packet for better performance 2023-03-13 18:22:16 +01:00
NEZNAMY 53ab2d9793 Commands - Do not load widths for widthcheck command unless command is used 2023-03-13 18:03:55 +01:00
NEZNAMY 2a58c86ffc Move code from initializer to load 2023-03-13 16:35:30 +01:00
NEZNAMY fa46d527ae Spectator Fix - Don't send useless packets on load/unload 2023-03-13 15:17:13 +01:00
NEZNAMY 667bd38305 Velocity - Fix Velocity being Velocity exception 2023-03-13 14:51:52 +01:00
NEZNAMY faba439466 Global PlayerList - Send all affected entries in a single packet, reducing amount of packets sent and improving performance 2023-03-13 14:47:29 +01:00
NEZNAMY c301157758 Global PlayerList - No longer delay task on quit as I was not able to reproduce the bug; Update placeholders periodically as they didn't update properly on vanish change anyway 2023-03-13 14:14:06 +01:00
NEZNAMY 8d09d425a4 Global PlayerList - No longer prevent other sources from removing players, better organize adding on server switch as well 2023-03-13 13:26:12 +01:00
NEZNAMY 11f03d5a10 Simplify 2023-03-13 12:58:19 +01:00
NEZNAMY 83625202a1 Merge pull request #841 from NEZNAMY/better-pipeline-injection
Better pipeline injection
2023-03-12 14:39:19 +01:00
Callum Seabrook eb4b715a88 Move pipeline injection to its own package 2023-03-12 13:35:47 +00:00
Callum Seabrook 89dce941cf Add RequiredArgsConstructor to NettyPipelineInjector 2023-03-12 13:31:58 +00:00
Callum Seabrook 6371b67e9e Removed player Channel and moved Netty injection to NettyPipelineInjector 2023-03-12 13:23:16 +00:00
NEZNAMY 966e27418a Bukkit - Attempt to fix error on ArrayList#remove 2023-03-11 15:35:31 +01:00
NEZNAMY 4adf7d1734 Bukkit - Fix NoSuchElementException that doesn't make sense 2023-03-11 15:25:06 +01:00
NEZNAMY 1a4c4a6fe8 Add more debug messages about feature loading times 2023-03-11 15:14:12 +01:00
NEZNAMY 7ff36592ae Do not re-initialize ErrorManager 2023-03-11 14:27:23 +01:00
NEZNAMY 1b513412d2 Remove redundant import 2023-03-10 13:20:14 +01:00
NEZNAMY f2bb43fbcd Make tabExpansion variable not null and add default empty implementation 2023-03-10 13:16:22 +01:00
NEZNAMY df5d07d885 Include forgotten code from previous commit 2023-03-10 13:13:21 +01:00
NEZNAMY 0ad2f33c4c Further clean up feature loading and mutual hooks 2023-03-10 12:45:28 +01:00
NEZNAMY dee48fccb3 Partially de-spaghetti feature loading and mutual hooking 2023-03-09 00:13:15 +01:00
NEZNAMY 9ca372ab13 Velocity is XD 2023-03-07 23:07:26 +01:00
NEZNAMY 58a849a902 Update README.md 2023-03-06 18:15:04 +01:00
NEZNAMY 895072ec35 Update README.md 2023-03-06 18:07:14 +01:00
NEZNAMY 2b2c4d2c39 Update README.md 2023-03-06 12:03:45 +01:00
NEZNAMY d534b6e2e8 Layout - Make fixed slots take priority over player groups if a slot is used in both 2023-03-05 15:31:14 +01:00
NEZNAMY 783e9d9931 Fix wrong values in widths.txt 2023-03-02 21:06:15 +01:00
NEZNAMY a109d9b55b Enable widthcheck command and fix error in it 2023-03-02 20:54:28 +01:00
NEZNAMY 5ce59ce44f Fix compilation 2023-03-02 20:33:37 +01:00
NEZNAMY 1e9195a9bc Velocity - Add try/catch for calling new methods on old versions 2023-03-01 18:49:41 +01:00
NEZNAMY 3099d16468 Create SECURITY.md 2023-03-01 12:23:39 +01:00
NEZNAMY c9c6af346c Add new issue templates 2023-03-01 12:18:23 +01:00
NEZNAMY af80a43628 Catch Throwable in pipeline instead of Exception to reduce chance of plugin causing player disconnect in future unsupported versions 2023-02-28 23:33:31 +01:00
NEZNAMY dc3c98ec91 Bukkit - Change how ViaVersion is detected (to avoid wrong detection due to a plugin order load bug in 1.17.1) 2023-02-25 18:41:25 +01:00
NEZNAMY dffa2c83f6 Typo 2023-02-24 23:45:40 +01:00
NEZNAMY dc66f253a7 Config converter - Remove placeholder that got deleted 2023-02-24 23:42:35 +01:00
NEZNAMY 17498cbfc2 BungeeCord - Fix bytebuf deserialization from previous commits 2023-02-24 23:15:01 +01:00
NEZNAMY 96e4d30168 Include 1.5 in supported version range 2023-02-24 16:48:56 +01:00
NEZNAMY c9d1934bb9 Use lombok for empty private constructor 2023-02-24 16:33:39 +01:00
NEZNAMY 8bec083194 Remove redundant duplicated checks 2023-02-24 16:30:34 +01:00
NEZNAMY abf047be23 Fix global playerlist class being instantiated twice 2023-02-24 16:22:02 +01:00
NEZNAMY 4a95399d56 3.3.1-SNAPSHOT 2023-02-24 16:19:01 +01:00
NEZNAMY 885bf5154e NameTags - Fix updating nametag visibility of players in disabled world/server 2023-02-24 15:43:58 +01:00
NEZNAMY 3e146fc496 Simplify 2023-02-24 15:41:30 +01:00
NEZNAMY 95710bcaf5 Sorting - Fix team name change registering teams for players in disabled worlds/servers 2023-02-24 15:37:40 +01:00
NEZNAMY edd620f17d BelowName - Fix text refreshing packets being sent to players in disabled worlds/servers 2023-02-24 15:25:09 +01:00
NEZNAMY 9c466d8b1e Update comment 2023-02-24 14:57:56 +01:00
NEZNAMY b385ab70fb Simplify 2023-02-24 14:52:22 +01:00
NEZNAMY 140224840b Remove double registration of sorting feature 2023-02-23 21:24:10 +01:00
NEZNAMY 2078cd5a5f Downgrade sponge API dependencies to confirm support 2023-02-21 18:46:43 +01:00
NEZNAMY 27bae7fdbd 3.3.0 2023-02-21 17:03:39 +01:00
NEZNAMY 174b4214de Bukkit - Fix error from previous commits 2023-02-21 13:52:21 +01:00
NEZNAMY 4ac524840c Remove non-existing branch from build.yml 2023-02-20 20:42:48 +01:00
NEZNAMY dd4ce4e2c3 Remove redundant library (gson) 2023-02-20 17:34:38 +01:00
NEZNAMY 2a03d69628 Add @SuppressWarnings annotation to a method 2023-02-20 17:33:44 +01:00
NEZNAMY c28252e6ce RGB - Fix redundant color codes in conversion to legacy, causing issues with limits (#827) 2023-02-20 17:02:20 +01:00
NEZNAMY da1768d833 Further code cleanup 2023-02-20 16:43:49 +01:00
NEZNAMY b58c3e6b47 Fix typos 2023-02-20 12:11:58 +01:00
NEZNAMY c7575bdc8f Remove redundant throws and empty method 2023-02-20 12:00:01 +01:00
NEZNAMY e275d22061 Bukkit - Fix startup on <1.8 2023-02-20 00:35:50 +01:00
NEZNAMY b5600ef22a Fix merge conflict 2023-02-20 00:29:05 +01:00
NEZNAMY b8e14c9256 Merge branch 'master' of https://github.com/NEZNAMY/TAB
 Conflicts:
	krypton/src/main/kotlin/me/neznamy/tab/platforms/krypton/KryptonPlaceholderRegistry.kt
2023-02-19 23:58:11 +01:00
NEZNAMY 1af5b9a308 Bukkit - Further split NMS loading and packet creation 2023-02-19 23:58:01 +01:00
Callum Seabrook 2dd719c3a5 Added Spark placeholder support back to Krypton 2023-02-19 21:08:04 +00:00
NEZNAMY 45d94694cd Bukkit - Split NMS fields and initialization into multiple classes 2023-02-19 21:15:10 +01:00
NEZNAMY 3ce8c6a192 Code style - Extract duplicated code 2023-02-19 17:41:06 +01:00
NEZNAMY 7deb86f105 Fix typo 2023-02-19 17:28:25 +01:00
NEZNAMY d9b4f6a43f Bukkit - Move data watcher serializer initialization 2023-02-19 17:15:58 +01:00
NEZNAMY 54a7fb8721 Code style - Extract duplicated code for permission plugin detection 2023-02-19 16:08:02 +01:00
NEZNAMY d1dcb2f437 Merge remote-tracking branch 'origin/master' 2023-02-18 17:35:03 +01:00
NEZNAMY a92bab617a Unlimited nametags - Fix error caused by wrong method being called 2023-02-18 17:34:52 +01:00
Callum Seabrook 57e34bc595 Updated to latest Krypton and added TAB prefix to console 2023-02-15 23:58:25 +00:00
Callum Seabrook 953baa273c Build Krypton targeting Java 8 2023-02-15 20:23:39 +00:00
NEZNAMY c403cb3187 Fix startup after recode 2023-02-15 21:03:19 +01:00
NEZNAMY ffd6dc5bb9 Disable krypton compilation to fix Sponge 7 startup (due to a Sponge 7 bug) 2023-02-15 20:53:06 +01:00
NEZNAMY 0f6504a3dc Remove unused local variable 2023-02-15 20:28:55 +01:00
NEZNAMY f376fea598 Formatting 2023-02-15 20:26:50 +01:00
NEZNAMY 4896cdff91 Further extend lombok usage 2023-02-15 19:17:29 +01:00
NEZNAMY b4c87431bc Scoreboard - Fix placeholders rarely not refreshing in title 2023-02-15 19:16:29 +01:00
NEZNAMY 1cffbab97d Remove plugin message text from /tab cpu due to being impossible to read 2023-02-15 15:14:30 +01:00
NEZNAMY 9b0711075a Code style - Use constants in more places 2023-02-15 15:06:15 +01:00
NEZNAMY 17a8e902eb Velocity - Use data folder given by the platform instead of manually defining it 2023-02-15 15:01:16 +01:00
Callum Seabrook 4bdb5ba245 Use more constants for plugin info 2023-02-15 12:16:48 +00:00
NEZNAMY fd7748d280 Merge remote-tracking branch 'origin/master' 2023-02-15 12:51:36 +01:00
NEZNAMY 317b0292ff Fix error on sponge (and redundancy on bukkit) 2023-02-15 12:51:19 +01:00
Callum Seabrook b87be649bc Made ARMOR_STAND_ID constant and removed packet builder singleton for Sponge 2023-02-15 11:51:09 +00:00
Callum Seabrook e2dda54011 Added sneaking support for unlimited nametags Sponge 2023-02-15 11:43:05 +00:00
NEZNAMY d17518c39b Sponge7 - Fix broken scoreboards 2023-02-14 23:19:33 +01:00
NEZNAMY 48541dd0bd Placeholders - Fix NPE 2023-02-14 22:29:28 +01:00
NEZNAMY b83b023fee Sponge8 - Add ViaVersion hook 2023-02-14 22:29:13 +01:00
NEZNAMY 60e0c78033 Add Sponge7 module 2023-02-14 22:28:32 +01:00
NEZNAMY a395f7f01f Unlimited NameTags - Fix entity type detection from previous commits 2023-02-14 18:46:17 +01:00
NEZNAMY 09c36ef69e Relocate yamlassist as well 2023-02-14 18:28:45 +01:00
NEZNAMY 9d5fa685a0 Rename folder as well 2023-02-14 18:25:08 +01:00
NEZNAMY 6794f593fa Rename sponge module to sponge8 2023-02-14 17:39:41 +01:00
NEZNAMY 5e9965276f Code style - Change how packet builder is initialized in Platform class 2023-02-14 16:54:58 +01:00
NEZNAMY 1473038955 Code style - Fix redundant imports, throws, extract constants, grammar 2023-02-14 16:39:21 +01:00
Callum Seabrook 2041ca57f3 Finished Sponge support 2023-02-14 14:38:09 +00:00
NEZNAMY 098782d820 3.3.0-SNAPSHOT 2023-02-14 12:53:10 +01:00
NEZNAMY 87e9a6defd 3.2.5 2023-02-13 16:40:36 +01:00
NEZNAMY 3d896ff828 More abstraction of unlimited nametag mode (also a small fix from previous commit) 2023-02-13 14:25:38 +01:00
NEZNAMY bf93240888 Unlimited NameTags - Make armor stands visible for spectators (#785) 2023-02-13 13:57:49 +01:00
NEZNAMY 0b0e30c3c9 Disable sponge module until compilation is fixed 2023-02-13 12:54:05 +01:00
NEZNAMY 84d3816bd1 Fix NPE 2023-02-12 12:51:37 +01:00
NEZNAMY 04ff606947 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2023-02-12 12:29:06 +01:00
NEZNAMY 1cb8e6e238 Almost finish Sponge 8 2023-02-12 12:29:01 +01:00
NEZNAMY 4a2226170d Merge pull request #819 from Tanguygab/master
added support for *server or *world (just like server* and world*)
2023-02-12 12:27:03 +01:00
Tanguygab 1469124cfc added support for *server or *world (just like server* and world*) 2023-02-12 11:41:11 +01:00
NEZNAMY 0826095e73 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2023-02-11 15:34:05 +01:00
NEZNAMY 1bd698adde Code style - Create custom cache object to avoid code duplication 2023-02-11 14:33:31 +00:00
Callum Seabrook 1058d269ff Start of rewrite of Sponge for v8 over v7 2023-02-11 14:13:05 +00:00
NEZNAMY bacd87b78e Code style - Create custom cache object to avoid code duplication 2023-02-11 13:08:20 +01:00
Callum Seabrook 5befbe8780 Updated Sponge platform 2023-02-10 23:11:38 +00:00
Callum Seabrook e159b2adae Finished Sponge implementation (mostly) 2023-02-10 23:08:21 +00:00
Callum Seabrook 52f7418853 The start of Sponge 2023-02-10 23:08:21 +00:00
Callum Seabrook 76061f7ccd Set up Sponge skeleton project 2023-02-10 23:08:21 +00:00
NEZNAMY 7d39e21eae Fix mistake after recode 2023-02-11 00:07:10 +01:00
NEZNAMY fee3723474 Code style - More abstraction of features and feature loading 2023-02-10 23:06:52 +01:00
NEZNAMY 2f0e4c6888 Merge remote-tracking branch 'origin/master' 2023-02-10 12:58:49 +01:00
NEZNAMY b04cb6d3c5 Config converter - Reverse old config detection (#762) 2023-02-10 12:58:07 +01:00
Callum Seabrook a9228a698a Fixed NPE being thrown when player info data name is null for Krypton 2023-02-09 16:18:13 +00:00
NEZNAMY 27102495d8 Code style - Use lombok in more locations 2023-02-08 00:49:48 +01:00
NEZNAMY d1bf96ab33 Code style - Use lombok for getters/setters 2023-02-07 23:14:02 +01:00
NEZNAMY 3360dbb468 Update README.md 2023-02-07 20:21:14 +01:00
NEZNAMY d224e7584e Create CONTRIBUTING.md 2023-02-07 20:20:31 +01:00
Callum Seabrook 6373540076 Updated Krypton platform and removed Indra 2023-02-07 16:56:58 +00:00
NEZNAMY 5f78aca997 Hide proxy-only methods into proxy player object 2023-02-07 15:33:24 +01:00
NEZNAMY 145d944d33 Bukkit - Remove unused (and incorrectly implemented) code 2023-02-07 15:26:01 +01:00
NEZNAMY ac91940e3b Velocity - Send packet using wanted player uuid instead of random if entry does not exist (apparently it goes through even if not registered) 2023-01-31 21:36:26 +01:00
NEZNAMY ef8452be73 Code style - Simplify BungeeCord info packet read/write based on client version 2023-01-31 18:23:24 +01:00
NEZNAMY 47e0810697 Placeholders - Remove %essentialsnick% placeholder due to being pretty redundant (keeping empty implementation so users don't get it suddenly broken) 2023-01-31 17:11:45 +01:00
NEZNAMY 1f30f225c7 Code style - Use reflection for PremiumVanish API instead of direct code with dependencies 2023-01-31 16:17:33 +01:00
NEZNAMY fcbfd60ddb Code style - Call method directly when command sender is console 2023-01-31 15:55:28 +01:00
NEZNAMY 46f9033713 Code style - Add final modifier to variable 2023-01-31 15:54:48 +01:00
NEZNAMY 7e65018a0e Velocity - Switch to non-deprecated method 2023-01-31 15:51:28 +01:00
NEZNAMY 9ef3485968 Code style - Create a method for convenience to avoid duplicated code 2023-01-27 15:52:38 +01:00
NEZNAMY 257f8f1145 Commands - Remove properly length from debug output 2023-01-27 15:24:26 +01:00
NEZNAMY 8d65cbb0e5 3.2.5-SNAPSHOT 2023-01-26 10:35:08 +01:00
NEZNAMY 20d221e3ca Merge pull request #806 from NotAlexNoyle/proposal
Propose adopting open source license
2023-01-25 12:17:56 +01:00
NEZNAMY 94072acf10 3.2.4 2023-01-25 10:39:44 +01:00
NEZNAMY 0422cc2597 Update issue templates 2023-01-24 14:00:13 +01:00
NEZNAMY 58f61e645b 3.2.4-SNAPSHOT 2023-01-24 10:45:11 +01:00
NEZNAMY 5f416bd9e5 Unlimited NameTags - Avoid Bukkit API NPE (#800, #804) 2023-01-24 10:44:35 +01:00
NotAlexNoyle 64528c913c Propose adopting open source license 2023-01-23 22:33:21 -05:00
NEZNAMY 357e7c6a49 Revert "Remove redundant try/catch"
This reverts commit 1777d8bf01.
2023-01-23 14:39:54 +01:00
NEZNAMY 81dd202053 3.2.3 2023-01-21 14:58:34 +01:00
NEZNAMY 189797aa73 Bukkit - Use the other constructor for player info packet which is cleaner (also #797) 2023-01-21 00:18:19 +01:00
NEZNAMY 1ae2ef7cad Fix compilation 2023-01-21 00:17:02 +01:00
NEZNAMY de14e14d33 Revert "Placeholders - Add timeout for placeholders to return value, causing TAB to freeze"
This reverts commit 37caed3123.
2023-01-19 22:30:09 +01:00
NEZNAMY 19892c14c1 Revert "Placeholders - Increase placeholder retrieve timeout to 500ms (#792)"
This reverts commit 6d85875fde.
2023-01-19 22:29:59 +01:00
NEZNAMY 2e00c4c002 Revert "NameTags - Fix error that doesn't make sense (#794)"
This reverts commit 12f5dd52b4.
2023-01-19 22:29:52 +01:00
NEZNAMY 97aa367629 Revert "Fix thread pool not being single threaded (maybe #781?)"
This reverts commit 87cc9a030b.
2023-01-19 22:28:22 +01:00
NEZNAMY 87cc9a030b Fix thread pool not being single threaded (maybe #781?) 2023-01-19 22:01:11 +01:00
NEZNAMY 8ba83d1cb1 BossBar - Fix errors when progress is below 0 or above 100 2023-01-19 16:59:05 +01:00
NEZNAMY 9f0e60bd47 Per world PlayerList - Remove redundant task schedule to main thread 2023-01-19 16:58:45 +01:00
NEZNAMY 93b2a25b2e Merge pull request #795 from Chris6ix/update-actions
Update Actions
2023-01-17 22:01:37 +01:00
Chris 4242d7a839 Remove Test Build Trigger 2023-01-17 21:33:33 +01:00
Chris 0ddb99bd46 Trigger Test Build 2023-01-17 21:29:34 +01:00
Chris 969672e3ad Update Actions 2023-01-17 21:26:40 +01:00
NEZNAMY 2423fbb150 Update README.md 2023-01-17 20:28:47 +01:00
NEZNAMY a99928dbf5 Placeholders - Colorize output of relational placeholders as well 2023-01-17 20:25:06 +01:00
NEZNAMY 12f5dd52b4 NameTags - Fix error that doesn't make sense (#794) 2023-01-17 15:38:20 +01:00
NEZNAMY 2bd105446e Bukkit - Properly send RGB messages into console (only for Paper+, Spigot doesn't support RGB at all) 2023-01-17 14:11:51 +01:00
NEZNAMY 6d85875fde Placeholders - Increase placeholder retrieve timeout to 500ms (#792) 2023-01-16 18:49:23 +01:00
NEZNAMY 42810aa490 3.2.3-SNAPSHOT 2023-01-16 18:47:42 +01:00
NEZNAMY bd31521bd3 3.2.2 2023-01-15 12:02:05 +01:00
NEZNAMY ec0deb8378 Yellow Number - Disable the feature for Bedrock players 2023-01-12 21:57:56 +01:00
NEZNAMY ae66b6e9a1 RGB - Fix MiniMessage->Bukkit conversion being after Bukkit->TAB, making it not translate anymore 2023-01-12 14:55:41 +01:00
NEZNAMY 3b86becebd Header/Footer - Do not add &r after \n anymore 2023-01-12 14:53:38 +01:00
NEZNAMY 4a8d86825b Configuration - Small changes to default configuration files 2023-01-10 18:56:34 +01:00
NEZNAMY 54a3bd81b4 Global PlayerList - Increase player removal prevention delay to 2000ms from 500ms 2023-01-10 16:49:16 +01:00
NEZNAMY b6768cca99 CPU manager - Add try/catch for task scheduling (#781) 2023-01-10 16:48:28 +01:00
NEZNAMY 60c414deed Bukkit - Remove redundant methods in nms loader 2023-01-05 16:48:16 +01:00
NEZNAMY 009283a83f Update README.md 2023-01-05 16:04:38 +01:00
Callum Seabrook 4a430b97df Merge pull request #779 from JT122406/master
Updates
2023-01-04 22:50:08 +00:00
NEZNAMY 722333da2e Fix RejectedExecutionException (#769) 2023-01-04 19:15:56 +01:00
NEZNAMY 1215af5262 Bukkit - Add 1.5.0 support 2023-01-04 18:28:24 +01:00
NEZNAMY 254088c37b Bukkit - Repackage nms loaders (also fix startup on Thermos) 2023-01-04 18:14:39 +01:00
J.T. McQuiggandCallum Seabrook cb2ce4acca Update gradle/libs.versions.toml
Co-authored-by: Callum Seabrook <callum.seabrook@prevarinite.com>
2023-01-04 11:20:55 -05:00
J.T.McQuigg 872adca8fd Updates 2023-01-03 23:09:35 -05:00
J.T.McQuigg f37cc0bdd8 Gradle 7.6 2023-01-03 23:02:04 -05:00
NEZNAMY 4063578ac3 Code style - Remove duplicate .toLowerCase() 2023-01-02 20:45:23 +01:00
NEZNAMY 2528de7eeb Code style - Use built-in String#trim function 2023-01-02 20:25:11 +01:00
NEZNAMY 37caed3123 Placeholders - Add timeout for placeholders to return value, causing TAB to freeze 2022-12-23 14:49:31 +01:00
NEZNAMY 27fe9dfb12 Commands - Make player command update player instantly if uuid is used instead of player name 2022-12-21 22:00:58 +01:00
NEZNAMY 0169cbd4d2 Bukkit - Fix wrong method taken sometimes, causing player kick with unlimited nametag mode 2022-12-20 15:08:18 +01:00
NEZNAMY ed760aec08 Aligned PlayerList - Fix rare error that makes no sense 2022-12-20 15:04:48 +01:00
NEZNAMY 858cbcefeb Code style - Add toString override 2022-12-20 15:04:21 +01:00
NEZNAMY 8a87d581a9 Scoreboard - Do not send packets to players who cannot see that specific scoreboard 2022-12-18 17:16:26 +01:00
NEZNAMY 6d642f4e51 NameTags - Fix players getting unregistered with wrong team name 2022-12-17 19:12:00 +01:00
NEZNAMY aca63640bc Attempt to fix rare NPE 2022-12-17 19:08:32 +01:00
NEZNAMY 1845a35315 3.2.2-SNAPSHOT 2022-12-16 22:25:39 +01:00
NEZNAMY cab5f89a95 Remove redundant check 2022-12-16 22:03:21 +01:00
NEZNAMY 1777d8bf01 Remove redundant try/catch 2022-12-16 21:14:47 +01:00
NEZNAMY 91b0bfaa9d Configuration - Simplify file copying, since default files already are encoded with UTF-8 encoding 2022-12-16 15:04:52 +01:00
NEZNAMY f1cf994d10 3.2.1 2022-12-16 11:27:48 +01:00
NEZNAMY 69957be933 Pet name fix - Fix excessive CPU usage caused by heavy operation and not caching the result 2022-12-15 00:22:23 +01:00
NEZNAMY b78eb5efb6 Bukkit - Remove forgotten debug stack trace printing 2022-12-15 00:21:28 +01:00
NEZNAMY 3577ad1964 Bukkit - Fix NPE in packet creation on <1.13 (#763) 2022-12-14 18:02:04 +01:00
NEZNAMY 4510491177 3.2.0 2022-12-12 09:46:21 +01:00
NEZNAMY 01b3a12377 1.19.3 support 2022-12-12 09:46:12 +01:00
NEZNAMY 64ae9863fb Bukkit - Drop old event API system 2022-12-10 12:27:51 +01:00
NEZNAMY ecd315a407 Sorting - Fix error from previous commit (.toLowerCase made string longer) 2022-12-08 11:20:58 +01:00
NEZNAMY 678eed288e Conditions - Add OR type for anonymous conditions using "|" symbol 2022-12-06 10:32:41 +01:00
NEZNAMY 9510455cb1 Conditions - Fix anonymous conditions not updating from previous commit 2022-12-06 10:31:29 +01:00
NEZNAMY e925ce23d0 Conditions - Fix nested conditions not working if they are defined below the condition using them 2022-12-06 09:51:16 +01:00
NEZNAMY c68cad6a1e Global PlayerList - Fix feature breaking nick/skin changes (minecraft mechanic changed in 1.19) (#752) 2022-12-06 09:50:00 +01:00
NEZNAMY 01d6eda4fb Configuration - Use luckperms placeholders instead of vault in default configuration (and make them return empty value if LP is not found) 2022-12-04 14:19:21 +01:00
NEZNAMY 73e7119bbc Configuration - add hidden server-name option for %server% value (useful with MySQL) 2022-12-04 11:49:59 +01:00
NEZNAMY cea781382a Sorting - Fix wrong team name being unregistered (#727) 2022-12-03 21:18:38 +01:00
NEZNAMY cf25b84e86 Commands - Fix debug command showing sorting is disabled even if layout is enabled for sorting 2022-12-03 21:16:29 +01:00
NEZNAMY 86e1d22390 Sorting - Only use 1 character for sorting by groups, permissions and predefined values; Improve debug output of sorting results 2022-12-03 12:16:38 +01:00
NEZNAMY 1625be111f Global PlayerList - Make server names in server groups and spy-servers not case-sensitive 2022-12-02 23:18:40 +01:00
NEZNAMY 00cda3b2aa Placeholders - Load all used placeholders on join in placeholder manager to make cpu usage appear under that "feature" instead of a feature actually using the placeholders 2022-12-01 22:46:40 +01:00
NEZNAMY 85a00a4436 Code style - Extract minimum placeholder refresh interval into an editable constant 2022-12-01 22:36:33 +01:00
NEZNAMY 37aec1a497 Global PlayerList - Add %playerlist-group_<group>% placeholder for online count in each group 2022-12-01 22:32:43 +01:00
NEZNAMY ef637616ee Placeholders - Improve error message 2022-11-27 17:13:24 +01:00
NEZNAMY af3b5067fb BossBar - Ignore players in disabled worlds/servers in announce command (#748) 2022-11-25 11:23:48 +01:00
NEZNAMY 53e5b15f96 Tab Expansion - Fix error in nested placeholder parsing 2022-11-24 11:01:55 +01:00
NEZNAMY 6a3afae607 Implement empty method 2022-11-16 12:24:03 +01:00
NEZNAMY 2e05c7d9d1 Another attempt for #727 2022-11-15 19:15:49 +01:00
NEZNAMY fb698a04b7 Configuration - Merge default config.yml files into one 2022-11-12 19:11:36 +01:00
NEZNAMY 52bdf30ddb Merge remote-tracking branch 'origin/master' 2022-11-09 22:34:22 +01:00
NEZNAMY a92f07aa40 Tab Expansion - Resend values to bridge on server switch (#740) 2022-11-09 22:34:09 +01:00
NEZNAMY 003ff7f99d Merge pull request #739 from CoachYT1/patch-1
bump org.yaml:snakeyaml to 1.33
2022-11-09 21:59:08 +01:00
NEZNAMY 47b9806ae7 Tab Expansion - Parse nested placeholders in replace function 2022-11-07 22:26:17 +01:00
CoachYT d2a7c65e08 bump org.yaml:snakeyaml to 1.33
snakeyaml 1.30 is affected by 5 vulnerabilities and should be upgraded to the latest version
2022-11-07 17:53:24 +01:00
NEZNAMY e232336a5f Add check for modifying non-existing teams (#727) 2022-11-06 22:42:23 +01:00
NEZNAMY 8816c75212 BungeeCord - Fix crash on 1.7 caused by unregistering non-existing objectives (login packet cleared them) (#727) 2022-11-04 13:31:34 +01:00
NEZNAMY f9d54751ba Fix rare ConcurrentModificationException 2022-11-04 12:53:00 +01:00
NEZNAMY 43d41ee761 BungeeCord - Improve unsupported BungeeCord build message 2022-11-01 17:55:43 +01:00
NEZNAMY 4512ba8d5e NameTags - Print a console warn if both unlimited nametags and invisible nametags are enabled 2022-10-30 17:56:00 +01:00
NEZNAMY 8b55bca564 Remove redundant variable 2022-10-30 13:40:32 +01:00
NEZNAMY d8d54970d3 Code style - Clean up vanish check code 2022-10-30 13:29:45 +01:00
NEZNAMY 15ea4482f9 Bukkit - Drop direct Essentials hook for vanishing as it supports metadata 2022-10-30 13:27:24 +01:00
NEZNAMY 87f9f38eac Update issue templates 2022-10-29 18:35:11 +02:00
NEZNAMY dba559f041 Layout - Fix startup error caused by invalid number as slot 2022-10-29 12:17:04 +02:00
NEZNAMY c610b6f323 PlayerList - Fix name applying on server switch when pipeline injection is disabled 2022-10-26 17:36:08 +02:00
NEZNAMY a5fb900e19 API - Add back TabPlayer#getTeamName() 2022-10-24 14:05:39 +02:00
NEZNAMY 09d6e455f5 Layout - Implement a fix for compatibility with plugins which add empty player name into their 2022-10-21 19:55:59 +02:00
NEZNAMY e68097b0f4 Layout - Fix startup error if slots is a single number instead of interval 2022-10-16 15:32:26 +02:00
NEZNAMY 0744fed953 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2022-10-16 14:40:42 +02:00
NEZNAMY de0adf4067 MySQL - Attempt to fix startup error (#717) 2022-10-16 13:12:54 +02:00
NEZNAMY 76bf2b3efc Update links in README 2022-10-16 13:11:56 +02:00
NEZNAMY c089badeb4 Configuration - Remove owner and admin settings from default configuration 2022-10-15 19:15:38 +02:00
NEZNAMY b3b99d366a Placeholders - Fix relational placeholders updating causing normal placeholders to not refresh 2022-10-14 19:28:05 +02:00
NEZNAMY 4a36486f65 Bukkit - Fix startup on 1.8 2022-10-08 12:41:05 +02:00
NEZNAMY 75126d00d9 BossBar - Fix countdown placeholder not activating on usage in PlaceholderAPI 2022-10-06 16:43:06 +02:00
NEZNAMY 17ebf95d5b BossBar - Fix announcement bars disappearing on refresh 2022-10-06 16:42:32 +02:00
NEZNAMY c764420cfe Code Style - Simplify field value assignment 2022-10-06 15:33:50 +02:00
Callum Seabrook 28f05fc2af Changed publishing artifact IDs to begin with "tab-" 2022-10-06 12:02:28 +01:00
Callum Seabrook a420892887 Fixed publishing ID 2022-10-06 11:54:06 +01:00
NEZNAMY d910dc5913 Header / Footer - Prioritize world over server in config.yml as well 2022-10-06 11:11:00 +02:00
NEZNAMY c9c1cbc349 Layout - Fix anti-override for playerlist names being disabled even when no layout is visible 2022-09-26 11:02:14 +02:00
NEZNAMY fd4704f75e 3.1.5 2022-09-20 15:46:28 +02:00
NEZNAMY 5400ca637f Global PlayerList - Do not fill display name for 1.7 players 2022-09-19 18:23:16 +02:00
NEZNAMY 79d2610117 Global PlayerList - Fix server switch when pipeline injection is disabled 2022-09-17 18:38:06 +02:00
NEZNAMY 6a51f4cb9d BungeeCord - Fix 1.7 players not being processed fully on server switch (reapplying scoreboards) 2022-09-13 18:33:52 +02:00
NEZNAMY c190776665 Scoreboard - Fix show command enabling scoreboard for players who disabled it using toggle command 2022-09-13 18:32:54 +02:00
NEZNAMY 3765a1232e Merge pull request #697 from JT122406/master
Updates and Velocity Deprecation Fix
2022-08-27 19:48:00 +02:00
J.T. McQuigg 28866eba21 More Updates and Build Fix 2022-08-27 13:07:28 -04:00
J.T. McQuigg 08adee3dc3 Recomment this out for PR 2022-08-27 11:57:34 -04:00
J.T. McQuigg 8a1adaf2cd More Updates 2022-08-27 11:57:08 -04:00
J.T. McQuigg fdb9accaa6 Updates and don't use Deprecation in Velocity module 2022-08-27 11:42:15 -04:00
NEZNAMY 4f7656748b Merge pull request #695 from Tanguygab/master
added StartWith `|-` and EndsWith `-|` condition types
2022-08-25 22:25:48 +02:00
Tanguygab 03e4495ac7 added |- and -| conditions 2022-08-25 15:15:21 +02:00
NEZNAMY 01af5cb9e1 Placeholders - Fix nested placeholders not being applied when updating from nested?!! (#694) 2022-08-24 16:52:01 +02:00
NEZNAMY 8d49f32df2 Code style - Change the way API instance is set 2022-08-22 20:30:16 +02:00
NEZNAMY 8a955b3bc8 Javadoc - Further improve documentation 2022-08-22 20:27:20 +02:00
NEZNAMY ead40cb413 Merge pull request #691 from Tanguygab/master
Commands - Added target and -s arguments for /tab nametag preview/toggle (#690)
2022-08-22 16:22:32 +02:00
Tanguygab 5e07f78d4f updated messages.yml 2022-08-22 16:20:43 +02:00
Tanguygab c7d98795bc Revert "* for all players in /tab scoreboard show"
This reverts commit e4f33b58f7.
2022-08-22 16:13:46 +02:00
Tanguygab 9f637e3d6a added target and -s arguments for /tab nametag preview/toggle 2022-08-22 16:09:23 +02:00
Tanguygab 2d5f074c78 Merge remote-tracking branch 'upstream/master' 2022-08-22 15:35:23 +02:00
NEZNAMY 3be6ba484d API - Fix show_item hover event on 1.16+ 2022-08-18 22:36:43 +02:00
NEZNAMY d9d74e7a32 Placeholders - Fix NPE in %essentialsnick% event listener due to Essentials bug (#684) 2022-08-18 12:46:54 +02:00
NEZNAMY 887306a5ed Bukkit - Include 1.19.2 in supported version range 2022-08-16 01:25:15 +02:00
NEZNAMY 4b2542eb4f Global Playerlist - Add config option to disable (and enable) profile key filling (#680) 2022-08-15 13:28:56 +02:00
NEZNAMY 66bd3baa3e Layout - Add config option to show vanished players in layout 2022-08-14 15:41:19 +02:00
NEZNAMY bf32004f8f Layout - Do not format original entries in any way (can cause spaces) 2022-08-13 17:50:28 +02:00
NEZNAMY bfb2df9c95 Commands - Show storage type in debug output 2022-08-13 17:44:46 +02:00
Callum Seabrook ddeb05e408 Merge pull request #662 from JT122406/Updates
Update Gradle Wrapper to 7.5
2022-08-12 16:58:38 +01:00
Callum Seabrook 9312d61258 Fix some more BS 2022-08-12 16:49:30 +01:00
Callum Seabrook d44909bc42 Fixed some BS 2022-08-12 16:41:26 +01:00
Callum Seabrook 1d77df335c Switched to Indra for publishing and improved code reuse in build scripts 2022-08-12 16:29:12 +01:00
NEZNAMY a268dc25f4 BungeeCord - Use direct code for proxy module again 2022-08-12 15:46:14 +02:00
NEZNAMY 8c5696faa0 Bukkit - Register universal placeholders after bukkit ones to fix reference issue with nested placeholders 2022-08-12 15:05:40 +02:00
NEZNAMY 94f3ccfb7d Javadoc - Further improve documentation 2022-08-12 15:04:49 +02:00
NEZNAMY 576329214d Add 1.19.2 to known versions 2022-08-11 17:57:49 +02:00
NEZNAMY 5c13c2e225 Velocity - Remove join processing delay since the required delay is already included elsewhere 2022-08-11 17:49:42 +02:00
NEZNAMY 1070f85617 Placeholders - Retry updateValue if player is not loaded yet (might fix #564) 2022-08-11 17:48:26 +02:00
NEZNAMY 7c9dc87fcb NameTags - Make canSeeFriendlyInvisibles flag configurable 2022-08-09 14:12:14 +02:00
NEZNAMY 363e58bf91 API - Expose another method 2022-08-04 17:06:30 +02:00
NEZNAMY daca3f5b71 3.1.4 2022-08-04 15:43:53 +02:00
NEZNAMY a7d2ec084b Use profile key in player info packet (#673) 2022-08-03 12:57:48 +02:00
NEZNAMY 167f8cd0ff BungeeCord - Remove Waterfall tablist rewrite hook since the option doesn't work as I expected 2022-08-03 11:14:10 +02:00
NEZNAMY 170307f45f Catch everything 2022-07-29 15:49:59 +02:00
NEZNAMY 2f36377780 Revert "Placeholder output replacements - Apply again after applying nested placeholders"
This reverts commit 2706cd5881.
2022-07-29 12:48:13 +02:00
NEZNAMY 48c565d85d 3.1.3 2022-07-28 17:59:15 +02:00
NEZNAMY 86b3cc4044 Sorting - Fix startup error caused by misconfiguration (#664) 2022-07-28 11:40:42 +02:00
NEZNAMY 6a2d5091b8 Bukkit - Add 1.19.1 support 2022-07-28 11:30:34 +02:00
J.T. McQuigg dc09e77190 Update Gradle Wrapper to 7.5 2022-07-26 17:16:56 -04:00
NEZNAMY 4fc139c0c6 Remove synchronized lock from sendCustomPacket method 2022-07-26 21:57:36 +02:00
NEZNAMY e5d800f469 API - Expose a few more methods 2022-07-26 21:56:16 +02:00
NEZNAMY 4879ac28b5 PingSpoof - Add Layout compatibility 2022-07-25 15:34:33 +02:00
NEZNAMY bd0badab48 Feature management - Don't deserialize objective packets if no feature is listening to them 2022-07-24 21:20:55 +02:00
NEZNAMY 5575a26d3b Placeholders - Use event instead of refresh task for %essentialsnick% placeholder 2022-07-24 20:27:43 +02:00
NEZNAMY d8cbe96949 BossBar - Fix issues with hidden-by-default enabled 2022-07-24 17:55:04 +02:00
NEZNAMY cfb506a7ff BossBar - Make Wither's size (nearly) zero on 1.8 (#654) 2022-07-24 13:28:18 +02:00
Tanguygab d5b0ff7f40 Merge remote-tracking branch 'upstream/master' 2022-07-24 13:11:11 +02:00
NEZNAMY 31d259210c Bukkit - Add support for mojang mapped jars 2022-07-21 12:56:23 +02:00
NEZNAMY 39112b8d41 Tab expansion - Add %tab_nametag_visibility% and rename %tab_ntpreview% to %tab_nametag_preview% 2022-07-20 00:14:38 +02:00
NEZNAMY 4c92286ebb Thread management - Increase max thread pool size to 20 2022-07-19 14:02:44 +02:00
NEZNAMY a317aeba85 Plugin message handling - Fix ClassCastException when a placeholder is externally registered as a server placeholder 2022-07-19 13:30:32 +02:00
NEZNAMY dcaf17294e Aligned PlayerList - Fix commit ebd67dd - Do not save config if no changes were made 2022-07-19 12:00:16 +02:00
NEZNAMY 0bc734689a Unlimited Nametags - Fix per-world formatting not applying on world switch 2022-07-19 00:22:11 +02:00
NEZNAMY d0c2c00cc9 BungeeCord - Respect Waterfall's tablist rewrite config option (#652) 2022-07-18 19:25:07 +02:00
NEZNAMY fd02328af9 Aligned PlayerList - Update widths.txt for 1.19 2022-07-18 14:55:05 +02:00
NEZNAMY 3b7de31324 Aligned PlayerList - Add a subcommand (disabled by default) for mass-verifying character widths 2022-07-18 14:52:44 +02:00
NEZNAMY ebd67dd025 Aligned PlayerList - Remove custom widths from config that match default value 2022-07-17 21:30:56 +02:00
NEZNAMY 4557a39ae2 RGB - Fix &r getting removed 2022-07-17 21:29:59 +02:00
NEZNAMY ce1eb299d3 Conditions - Fix conditions being 1 loop behind nested placeholders 2022-07-16 22:58:37 +02:00
Callum Seabrook 20ab3f0a72 Disabled JavaDoc generation for all but API and added property to enable for API 2022-07-16 20:11:58 +01:00
NEZNAMY d61f90c25c Code style - use api module instead of shared where possible 2022-07-16 20:56:59 +02:00
NEZNAMY 90474e7592 Layout - Fix startup error when a layout is missing groups section 2022-07-16 19:15:18 +02:00
NEZNAMY a2e28003bc Code style - Move TabConstants class to api module 2022-07-16 19:13:31 +02:00
NEZNAMY 6e409c3dcd Thread management - Use scheduled executor for repeating and delayed tasks 2022-07-16 18:39:13 +02:00
NEZNAMY 85a699c8de Commands - Only show announcement bars in auto-complete for bossbar announcement command 2022-07-16 18:33:57 +02:00
NEZNAMY a788d1fb23 Commands - Add missing permission check when toggling scoreboard using player argument 2022-07-16 14:14:35 +02:00
NEZNAMY ab5b72375c Code style - Remove redundant suppression and cast 2022-07-13 16:42:36 +02:00
NEZNAMY 3a023c51b5 Catch NoClassDefFoundError which is rarely thrown on reloads and leads to memory leaks 2022-07-13 16:24:17 +02:00
NEZNAMY 0ad91bcafe Sorting - Fix space in sorting types causing it to not work 2022-07-13 15:25:30 +02:00
NEZNAMY f41ea3bcab Unlimited Nametags - Improve heights to match vanilla & remove config option for space between lines, since original value was found 2022-07-13 14:57:07 +02:00
NEZNAMY 327dc4b416 Unlimited Nametags - Fix sneaking not being detected immediately on reload 2022-07-13 14:55:39 +02:00
NEZNAMY 27e7779456 Unlimited Nametags - Do not spawn for <1.8 players 2022-07-13 14:02:33 +02:00
NEZNAMY a7b2f5bb22 BungeeCord - Fix NPE on <1.8 clients 2022-07-13 13:32:53 +02:00
NEZNAMY 19fcb7c946 Layout - Do not send latency update packets to <1.8 clients 2022-07-13 13:32:23 +02:00
NEZNAMY 2706cd5881 Placeholder output replacements - Apply again after applying nested placeholders 2022-07-13 12:17:39 +02:00
NEZNAMY 4e2abd9c5b Bukkit - Fix startup on 1.7.x and 1.8.0 2022-07-13 12:04:21 +02:00
NEZNAMY 51ba2fa80a Placeholder output replacements - Fix exact match detection when input is not colored (new placeholderapi version) 2022-07-11 00:28:14 +02:00
NEZNAMY fd60cd0a21 Change the way the module is disabled 2022-07-06 22:00:52 +02:00
NEZNAMY 5025372c05 Revert "Code style - Remove unused method" 2022-07-06 21:15:54 +02:00
NEZNAMY 4806bd075f Configuration - Fix NPE when disabled world/server is null 2022-07-05 19:09:56 +02:00
NEZNAMY 370d17757a Add poor and unreliable MiniMessage support 2022-07-04 18:06:19 +02:00
NEZNAMY a648d7e75f Scoreboard - Fix NPE when using show command from console without player argument (#639) 2022-07-04 14:05:44 +02:00
NEZNAMY 518e1c5310 AlignedPlayerList - Fix rare NPE caused by multi-thread access 2022-07-04 13:46:29 +02:00
NEZNAMY 11539d8290 Commands - Allow removing per-world/server values 2022-07-04 13:44:08 +02:00
Tanguygab e4f33b58f7 * for all players in /tab scoreboard show 2022-07-04 13:34:04 +02:00
NEZNAMY 073caa9515 Compilation - Bump Authlib version 2022-07-04 13:33:00 +02:00
NEZNAMY 2b06b11916 Scoreboard - Fix same lines of text not appearing with use-numbers true 2022-06-24 21:16:45 +02:00
NEZNAMY 032b0f8a41 Configuration - Fix NPE when copying bukkit config to bungeecord 2022-06-19 14:05:59 +02:00
NEZNAMY 9391363f9b Unlimited Nametags - Disable on boat with chest as well (#625) 2022-06-19 12:36:35 +02:00
NEZNAMY 467fb2e9c7 Bukkit - Use reflection for LibsDisguises hook 2022-06-18 16:12:53 +02:00
NEZNAMY 257893b8de Downgrade dependency to fix compilation 2022-06-18 16:12:09 +02:00
NEZNAMY e919839de5 Merge pull request #623 from JT122406/Updates
Repo Bumps
2022-06-18 14:12:41 +02:00
J.T. McQuigg 77d372cbee Use new RedisBungee 2022-06-18 07:42:38 -04:00
J.T. McQuigg 03e9facaf7 Repo Bumps 2022-06-18 07:35:45 -04:00
NEZNAMY f3e459d911 Revert "BungeeCord - Retry plugin message processing if player isn't loaded for any reason (#564)"
This reverts commit dffac5deb8.
2022-06-17 14:15:39 +02:00
NEZNAMY 36feff0e04 Sorting - Fix off-by-1 possibly causing sorting to not work correctly for players without sorting group/permission 2022-06-16 18:53:42 +02:00
NEZNAMY 0320140a1b BungeeCord - Fix vanish/invisible status not resetting on server switch 2022-06-12 14:16:20 +02:00
NEZNAMY 4fb1b1c9f9 3.1.2 2022-06-11 18:01:17 +02:00
NEZNAMY 37f3896a41 Update to 1.19 2022-06-11 18:01:08 +02:00
NEZNAMY e1c152d95d Add missing change in previous commit 2022-06-11 18:00:08 +02:00
NEZNAMY dffac5deb8 BungeeCord - Retry plugin message processing if player isn't loaded for any reason (#564) 2022-06-11 17:57:18 +02:00
NEZNAMY 8aa3bbfad3 Scoreboard - Fix RGB codes not translating into legacy correctly in long lines 2022-06-09 23:10:44 +02:00
NEZNAMY 5bb4006e55 Scoreboard - Fix additional empty lines when use-numbers is enabled 2022-06-08 00:46:32 +02:00
NEZNAMY e06a406682 Clean up repositories 2022-06-08 00:45:21 +02:00
NEZNAMY a19719be4b Configuration - Remove deleted placeholder from default config 2022-06-03 23:47:41 +02:00
NEZNAMY 35856a9f3d Merge branch 'master' of https://github.com/NEZNAMY/TAB 2022-06-02 15:50:46 +02:00
NEZNAMY cf1d5d5ee2 Code style - Remove unused method 2022-06-01 20:23:16 +02:00
NEZNAMY f69a845e51 Bukkit - Implement chat message sending on <1.7 2022-05-31 12:21:07 +02:00
NEZNAMY db67e93bb8 Disable compilation of a module 2022-05-31 11:51:21 +02:00
NEZNAMY 313f089222 Aligned Suffix - Fix memory leak 2022-05-20 01:10:00 +02:00
NEZNAMY 458c08ded7 Tab expansion - Slightly optimize placeholder retrieving 2022-05-18 01:39:20 +02:00
NEZNAMY fe6cc7417f Placeholders - Fix refresh interval forwarding to bridge (#597) (2nd attempt) 2022-05-17 19:00:23 +02:00
NEZNAMY 181c94a808 Code style - Extract strings into constants 2022-05-13 00:42:30 +02:00
NEZNAMY 9ff6f02d8d Code style - Remove unused code and other minor changes 2022-05-12 22:49:41 +02:00
NEZNAMY 3cf74516d9 Bukkit - Remove unused data watcher registries 2022-05-12 22:25:18 +02:00
NEZNAMY 31f5502c16 BungeeCord - Delete TAB's bungeecord events (to make users switch to universal ones) 2022-05-12 22:04:37 +02:00
NEZNAMY 671d60bd72 API - Throw user-friendly exception if player is not loaded yet (#585) 2022-05-10 18:32:09 +02:00
NEZNAMY 294e866501 Placeholders - Fix refresh interval forwarding to bridge (#597) 2022-05-10 18:21:13 +02:00
NEZNAMY 96789100e3 Bukkit - Wrap incoming components instead of deserializing and then serializing them 2022-05-10 13:22:27 +02:00
NEZNAMY ea934fc7fb GroupManager - Add null check for player group from permission plugin 2022-05-08 12:48:06 +02:00
NEZNAMY d529b7b340 Sorting - Allow placeholders with ":" inside to work properly in PLACEHOLDER sorting type 2022-05-08 12:47:40 +02:00
NEZNAMY 092ca7f9f8 Aligned Suffix - Assume players can see themselves when vanished 2022-05-03 18:03:29 +02:00
NEZNAMY 79f4bdb869 Unlimited Nametags - Do not delay respawn by 1 tick anymore to fix OOM 2022-05-01 13:07:42 +02:00
NEZNAMY b0d2d0f7dc NickCompatibility - Clean up code 2022-04-30 20:01:40 +02:00
NEZNAMY cdf58c1dfe Teams - set canSeeFriendlyInvisibles to true 2022-04-30 18:21:46 +02:00
NEZNAMY 4680de6022 Feature management - Add try/catch for each feature in join processing (#560) 2022-04-30 17:22:03 +02:00
NEZNAMY e8f61181b6 Error logging - Log (critical) errors into console even when error file is full 2022-04-30 17:20:24 +02:00
NEZNAMY 75e9e007d0 Fix disabled worlds not loading correctly (from #6f07cf4) 2022-04-28 17:27:23 +02:00
NEZNAMY 3574ef7c0b Belowname - Do not update score when entering disabled world 2022-04-28 12:20:54 +02:00
NEZNAMY 86158036d2 Commands - Make permission group assigning more obvious in debug output 2022-04-28 11:55:21 +02:00
NEZNAMY e73beb47a3 API - Fix scoreboard Line#setText not working 2022-04-26 23:23:42 +02:00
NEZNAMY 0db5f1dd73 Scoreboard - Fix NPE when a line is null 2022-04-23 14:18:30 +02:00
NEZNAMY 6dcdc2aa58 PetFix - Fix attack packet cancellation 2022-04-20 10:46:08 +02:00
NEZNAMY 64601137e8 Scoreboard - Show empty lines when defined as empty, only hide when placeholder output is empty 2022-04-15 00:07:44 +02:00
NEZNAMY af7697b670 BungeeCord - Fixed NPE from moving to reflection 2022-04-14 23:24:45 +02:00
NEZNAMY 9e4f46088b Commands - Do not force refresh players who are not loaded yet (#560) 2022-04-12 11:21:06 +02:00
NEZNAMY 91e71a9b9c Layout - Fixed NPE when player had no layout visible 2022-04-10 23:32:13 +02:00
NEZNAMY 1198ffb847 BungeeCord - Use reflection for proxy module access due to the repository no longer being available 2022-04-10 23:31:51 +02:00
NEZNAMY 72116ecd0c Javadoc - Further improve documentation 2022-04-10 21:08:19 +02:00
NEZNAMY 04ebb7123d Code style - Move NMS object declaration and initialization 2022-04-10 20:28:29 +02:00
NEZNAMY 43096beafe Bukkit - Use ConsoleCommandSender for colored messages (#555) 2022-04-09 18:27:37 +02:00
NEZNAMY 2a08c62456 Tab expansion - Fix server placeholders not loading on join 2022-04-07 15:44:58 +02:00
NEZNAMY b62d74c3fa Code style - Remove unnecessary reflection 2022-04-06 20:38:03 +02:00
NEZNAMY 652fb5a6ad Bukkit - Switch from Paper to Purpur API 2022-04-06 19:11:19 +02:00
NEZNAMY d1f25cc19f Bukkit - Disable checking for plugins with compatibility issue 2022-04-06 18:25:12 +02:00
NEZNAMY dc6a9d9761 Fix layout startup 2022-04-06 13:44:16 +02:00
NEZNAMY 838d725715 Code style - Removed redundant static modifiers 2022-04-06 13:31:31 +02:00
NEZNAMY c45acb39ca Code style - Clean up variable initialization 2022-04-06 13:10:11 +02:00
NEZNAMY 957edf2a52 Javadoc - Fixed compilation warn 2022-04-06 12:44:54 +02:00
NEZNAMY d969c6ed0e Code style - Change way of checking if server is proxy 2022-04-06 12:41:20 +02:00
NEZNAMY dd6fca961c Code style - Clean up configuration loading 2022-04-06 12:34:39 +02:00
NEZNAMY e88a6df456 Config - remove hidden unregister-before-register option and remove the function entirely. Hopefully with improved checks this should not be necessary anymore. It caused client errors, as well as #549 2022-04-06 11:35:03 +02:00
NEZNAMY 3a4530c999 RGB - Finish #552 - Only replace clean gradients in property initialization 2022-04-05 23:24:37 +02:00
NEZNAMY b623dba40a Merge branch 'master' of https://github.com/NEZNAMY/TAB 2022-04-05 23:20:13 +02:00
NEZNAMY e2fd945109 Merge pull request #552 from lucypoulton/feat/kyori-rgb-format
Add support for Kyori MiniMessage RGB format
2022-04-05 23:19:52 +02:00
NEZNAMY e6dc3cda31 Unlimited nametags - Manually destroy armor stands on world switch 2022-04-05 20:21:36 +02:00
Lucy Poulton 18d8ff127a add support for kyori minimessage rgb format 2022-04-05 14:25:22 +01:00
NEZNAMY 4a9526451f Code style - Remove redundant "triggerMode" flag from Placeholder class due being redundant. Setting refresh to -1 has the same effect. 2022-04-04 19:03:51 +02:00
NEZNAMY 669d89c870 Code style - Move tab expansion code to interface 2022-04-04 18:15:06 +02:00
NEZNAMY 39161f2af5 Nametags - Reduced CPU usage of anti-override 2022-04-04 16:02:32 +02:00
NEZNAMY be8c33e3fc Velocity - Delay join event processing to avoid unformatted tablist names 2022-04-03 14:08:19 +02:00
NEZNAMY 7c1a27f9df Javadoc - Further improve documentation 2022-04-02 19:07:18 +02:00
NEZNAMY 342cc93dbf Code style - Clean up code 2022-04-02 13:17:15 +02:00
NEZNAMY 6f07cf439b Code style - Clean up loading of disabled servers/worlds 2022-04-01 23:40:04 +02:00
NEZNAMY 1d4d00b69b Code style - Clean up code with usage of @Inject 2022-04-01 23:21:30 +02:00
NEZNAMY 54cb3e4d54 3.1.1 2022-04-01 10:02:26 +02:00
NEZNAMY b0fc2caef9 RedisBungee - Detect player name change from other proxies 2022-03-31 21:54:51 +02:00
NEZNAMY 1221509d24 MySQL - Do not lowercase _DEFAULT_ group name, which caused it to not load (#546) (for real this time) 2022-03-31 20:52:12 +02:00
NEZNAMY 17f5f60504 MySQL - Do not lowercase _DEFAULT_ group name, which caused it to not load (#546) 2022-03-31 17:02:12 +02:00
NEZNAMY a8b0b488c6 Layout - Implement latency updating for player slots (#545) 2022-03-31 15:45:14 +02:00
NEZNAMY 6d922d5b70 Unlimited nametags - Fix NPE when player moves too quickly after joining 2022-03-31 14:50:54 +02:00
NEZNAMY 1ab62a33e3 Placeholders - Improve refresh task interval adaptation (#543) 2022-03-31 10:01:10 +02:00
NEZNAMY f9540a1e78 Tab Expansion - Fix placeholders not loading on player join 2022-03-29 11:17:04 +02:00
NEZNAMY a720bf2c8b Unlimited nametags - Do not allow preview command when armor stands are disabled for player 2022-03-28 21:25:42 +02:00
NEZNAMY c143eab6fb Global playerlist - Fix player possibly being removed from playerlist after reconnecting rapidly (#539) 2022-03-28 20:57:47 +02:00
NEZNAMY 1afb20af8b Code style - Avoid reassigning parameters 2022-03-28 12:57:31 +02:00
NEZNAMY c6f27c839d Code style - Document empty method body 2022-03-28 12:49:37 +02:00
NEZNAMY 742f1708c5 Code style - Remove unused import 2022-03-28 12:47:19 +02:00
NEZNAMY ac9601a48b Unlimited nametags - Fix nametag toggle command not hiding vanilla name on players with disabled armor stands via API 2022-03-28 12:13:23 +02:00
NEZNAMY 4cd109a5fc Javadoc - Update style and fix alignment after replacing tabs with spaces 2022-03-26 23:13:19 +01:00
NEZNAMY 078554a8b0 RedisBungee - Fix /btab reload removing players from tablist when global playerlist is disabled 2022-03-25 14:46:59 +01:00
NEZNAMY 464e2f4f64 RedisBungee - Fix duplicated team names through proxies 2022-03-25 14:46:22 +01:00
NEZNAMY b84f55aa18 RedisBungee - Fix errors and issues when unlimited nametag mode is enabled 2022-03-25 14:45:55 +01:00
NEZNAMY be2f780bfa Drop LuckPerms event hook and go back to periodic task. Too many issues related to events. 2022-03-25 10:27:36 +01:00
NEZNAMY 262d8493a6 fix NPE 2022-03-25 09:33:32 +01:00
NEZNAMY 24e12e871b finish #534 2022-03-24 22:33:18 +01:00
NEZNAMY a2ee75339c 3.1.1-pre2 2022-03-24 22:20:25 +01:00
NEZNAMY 9c28c4d63c add auto complete for group names in group command 2022-03-22 22:12:55 +01:00
NEZNAMY 7d57da1424 fix disableArmorStands method not destroying armor stands 2022-03-22 13:06:28 +01:00
NEZNAMY b77b20ba4d expose placeholder output getters in the API 2022-03-22 11:54:30 +01:00
NEZNAMY 57ae58f093 call super.onQuit as it should 2022-03-21 20:26:56 +01:00
NEZNAMY b29c878688 Merge remote-tracking branch 'origin/master' 2022-03-21 08:51:52 +01:00
NEZNAMY 5a5a6c76c1 another banger that took a week to fix 2022-03-21 08:51:32 +01:00
NEZNAMY f6a53f537c fix NPE 2022-03-21 08:46:02 +01:00
NEZNAMY d86ed37208 allow negative values in replacement intervals using ~ 2022-03-20 17:55:17 +01:00
NEZNAMY 92b945f28d Merge pull request #534 from itsmemac/master
fix nametag preview help text
2022-03-20 15:03:07 +01:00
Mac cb164f0055 fix nametag preview help text
it seems new update `/tab ntpreview` has been replaced with `/tab nametag preview`
Help text was not updated
2022-03-20 19:31:38 +05:30
NEZNAMY acfe37c1b5 fix NPE 2022-03-20 12:50:30 +01:00
NEZNAMY 44ded26df4 change method call order in which groups are refreshed 2022-03-19 16:13:39 +01:00
NEZNAMY 6dbd92a010 remove players from map on quit 2022-03-19 16:12:06 +01:00
NEZNAMY f729ca0ad2 fix NPE 2022-03-19 16:11:45 +01:00
NEZNAMY 065490c077 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2022-03-18 17:12:20 +01:00
NEZNAMY da6425dd93 Merge pull request #530 from CoachYT1/master
Update dependencies & GitHub actions
2022-03-15 08:25:12 +01:00
CoachYT 250dcbc676 Update build.yml 2022-03-14 12:18:41 +01:00
CoachYT de4ca4a88f Update libs.versions.toml 2022-03-14 12:15:58 +01:00
NEZNAMY 723a0c890e fix NPE 2022-03-13 22:36:37 +01:00
NEZNAMY 7085e7df20 do not forward group if assigning by permissions 2022-03-13 22:36:25 +01:00
NEZNAMY 09496d60f3 add argument check 2022-03-13 13:19:05 +01:00
NEZNAMY bf6bc26a5c add check into API for all the users who shade API into their projects 2022-03-13 13:16:20 +01:00
NEZNAMY a7217eae15 fix placeholders used only in tab expansion not refreshing 2022-03-13 13:12:37 +01:00
NEZNAMY 2a532ef9b7 update README.md 2022-03-13 13:11:37 +01:00
NEZNAMY c304ded924 avoid thread spam from LP events 2022-03-11 15:06:13 +01:00
NEZNAMY 4d8c47a505 #517 - make group names not case-sensitive when connected to MySQL 2022-03-09 10:22:51 +01:00
NEZNAMY d3e0ccbf34 forward nametag preview on server switch 2022-03-09 09:08:49 +01:00
NEZNAMY 3c82b46148 fix updating of invalid score on server switch when pipeline injection is disabled 2022-03-08 23:09:29 +01:00
NEZNAMY 07d7f2cc17 catch StackOverflowError as well 2022-03-08 21:50:10 +01:00
NEZNAMY 54d4f09ab1 fix StackOverflowError when using placeholder identifier inside its own replacements (will act the same as %value%) 2022-03-08 21:45:11 +01:00
NEZNAMY e8c698b5e8 #517 - fix mysql header/footer download/upload 2022-03-07 22:14:49 +01:00
NEZNAMY b096906ffd 3.1.1-pre1 2022-03-07 18:59:40 +01:00
NEZNAMY 5a9cec12fa WeakHashMap isn't so weak after all (fixed memory leak) 2022-03-07 18:59:22 +01:00
NEZNAMY a2ed71751f fix NPE 2022-03-07 18:58:10 +01:00
NEZNAMY 5a3a2df920 simplify 2022-03-07 15:50:24 +01:00
NEZNAMY 9d07e669ea merge ifs 2022-03-07 15:50:12 +01:00
NEZNAMY aa18f1cc35 remove unnecessary full path 2022-03-07 14:03:04 +01:00
NEZNAMY 668d78ea64 remove redundant constructor 2022-03-07 13:59:38 +01:00
NEZNAMY 6f62581d6e print OOM into file instead of throwing into console 2022-03-07 12:53:12 +01:00
NEZNAMY 06686ada5c add synchronized lock to printError method 2022-03-07 12:21:47 +01:00
NEZNAMY 4380482606 remove direct reference to player channel on bukkit 2022-03-07 12:21:24 +01:00
NEZNAMY d5112b3d32 fix group refreshing introduced in previous commit which in the end didn't even fix the issue it was supposed to 2022-03-06 20:26:49 +01:00
NEZNAMY ef67506640 fix error caused by concurrent access 2022-03-06 12:01:50 +01:00
NEZNAMY c2ea4d2793 #516 - skin signature can be null 2022-03-05 16:29:16 +01:00
NEZNAMY f0d8d479bd 3.1.0 2022-03-04 22:46:16 +01:00
NEZNAMY 2d46d70c92 Fix super rare permission group detecting issue when using TAB on bungeecord with assigning by permissions with using backend permissions with many online players. Jesus. 2022-03-04 22:38:43 +01:00
NEZNAMY 4320bb7cb4 try to fix rare error that doesn't make sense 2022-03-04 22:36:53 +01:00
NEZNAMY 398e8ed5ff remove redundant space 2022-03-04 12:31:43 +01:00
NEZNAMY 4e8b804337 prefer per-world settings over per-server 2022-03-04 10:39:45 +01:00
NEZNAMY de7c664e0d remove redundant check 2022-03-02 14:17:05 +01:00
NEZNAMY c7600a2e3d fix issues for players with unknown version 2022-03-02 13:34:29 +01:00
NEZNAMY 8b34e82aab simplify 2022-03-02 12:49:26 +01:00
NEZNAMY c96efe8802 use Logger for console messages 2022-03-02 12:46:33 +01:00
NEZNAMY 0a1bfd3a2e 3.1.0-pre3 2022-03-02 10:57:23 +01:00
NEZNAMY 755cf9ce43 1.18.2 2022-03-02 10:56:46 +01:00
NEZNAMY c6aca74396 fix NPE when assigning groups by permissions on bungeecord 2022-03-01 22:37:37 +01:00
NEZNAMY b5b7f3c16c add try/catch for PremiumVanish hook 2022-02-28 23:26:53 +01:00
NEZNAMY 293162b484 show name of file with syntax error correctly in error message 2022-02-28 15:27:17 +01:00
NEZNAMY bd543b7b9d fix rare NPE (#504) 2022-02-25 20:49:40 +01:00
NEZNAMY 994fe9f482 fix conversion error when bossbar names are numbers (#506) 2022-02-25 20:48:28 +01:00
NEZNAMY f657bdb14c update README.md 2022-02-22 23:42:16 +01:00
NEZNAMY a4238e1191 compensate for 1.8.0 client sided bug (#501) 2022-02-22 08:05:45 +01:00
NEZNAMY daf08423b4 3.1.0-pre2 2022-02-21 19:01:40 +01:00
NEZNAMY 91367f3d3a fix wrong text displayed 2022-02-21 16:33:21 +01:00
NEZNAMY 9dbd52b638 replace tabs with 4 spaces 2022-02-21 16:15:52 +01:00
NEZNAMY 22c6be2770 fix names not updating when new max player joins 2022-02-21 16:05:51 +01:00
NEZNAMY fb261c9f90 cleanup 2022-02-21 12:43:23 +01:00
NEZNAMY 638e35bf90 more abstraction 2022-02-21 12:40:15 +01:00
NEZNAMY 25d13862ae initialize server version & data folder constants instead of having per-platform getters 2022-02-21 12:30:02 +01:00
NEZNAMY 1c8f483138 split content of plugin message handler classes into other classes 2022-02-21 11:57:43 +01:00
NEZNAMY 92ad215873 more code abstraction 2022-02-21 11:06:02 +01:00
NEZNAMY 7ed3cfbb7c fix vanish status not refreshing correctly on bungeecord 2022-02-20 23:42:43 +01:00
NEZNAMY 53e75a27be avoid bytebuf instance check entirely if deserialization is disabled 2022-02-20 23:08:15 +01:00
NEZNAMY 1b67819c3c only forward relevant properties to expansion and fix values not updating 2022-02-20 15:16:12 +01:00
NEZNAMY 07f8020f79 fix syntax error in default file 2022-02-20 14:53:31 +01:00
NEZNAMY b12d0680d8 massively optimize some API methods 2022-02-20 14:50:05 +01:00
NEZNAMY 64247d913e implement "/tab nametag toggle" command hiding nametags of all players for command sender 2022-02-19 21:29:22 +01:00
NEZNAMY 3575cdae85 move code & respawn armor stands on world switch if preview is enabled 2022-02-19 14:27:04 +01:00
NEZNAMY f71a542247 add check for directory existence 2022-02-19 13:56:59 +01:00
NEZNAMY 46cc59138b skip action if list is empty 2022-02-19 13:31:00 +01:00
NEZNAMY 46bfa5112e for some reason this check is needed as well 2022-02-19 13:29:32 +01:00
NEZNAMY fcdff51783 use pre-allocated enum values array (again) 2022-02-19 13:29:18 +01:00
NEZNAMY a4be4ae419 fix check not working properly 2022-02-19 13:28:05 +01:00
NEZNAMY 7083352b9a cache enum values to reduce memory allocations 2022-02-18 23:37:27 +01:00
NEZNAMY 956a0f46c0 name the second thread pool as well 2022-02-18 23:26:26 +01:00
NEZNAMY aea1864627 iterate over arrays to reduce allocations 2022-02-18 23:01:29 +01:00
NEZNAMY 803b87111a make packet deserializing on BungeeCord use 30x less CPU 2022-02-18 22:40:36 +01:00
NEZNAMY f64a641b63 fix NPE caused by a dumb mistake 2022-02-18 12:49:28 +01:00
NEZNAMY 7f9bb354d7 remove wrong null checks 2022-02-18 12:48:08 +01:00
NEZNAMY 4b7b6284f8 move code to avoid duplication 2022-02-18 12:38:55 +01:00
NEZNAMY bbccd26415 remove %maxplayers% placeholder 2022-02-18 12:35:31 +01:00
NEZNAMY bab7c737b3 add more precondition checks 2022-02-18 12:31:06 +01:00
NEZNAMY 3169787b41 fix NPE on /btab parse 2022-02-18 11:13:34 +01:00
NEZNAMY f29bbc6657 move config option loading 2022-02-17 23:04:21 +01:00
NEZNAMY f53cd5ae11 fix armor stands heights not updating 2022-02-17 22:39:59 +01:00
NEZNAMY 38d36b5ab5 remove unused softdependency 2022-02-17 21:33:54 +01:00
NEZNAMY 8f8f596abc drop direct UltraPermissions hook (still supported via Vault) 2022-02-17 16:28:43 +01:00
NEZNAMY 2afc8abdb2 rename fields from "method" to "action" 2022-02-17 16:19:57 +01:00
NEZNAMY 38dd948306 cleanup 2022-02-17 11:37:28 +01:00
NEZNAMY e393cf0a10 make code more universal 2022-02-17 11:35:36 +01:00
NEZNAMY 4f451017e3 make PacketBuilder not abstract and add default implementation to delete a redundant class 2022-02-17 11:17:27 +01:00
NEZNAMY 9cb31af48a class cleanup using consumer 2022-02-17 10:56:45 +01:00
NEZNAMY 2c17041b27 universal registration of %online_<server>% on proxies 2022-02-17 10:34:55 +01:00
NEZNAMY 72c75a443e more abstraction of RedisBungee feature 2022-02-16 20:04:06 +01:00
NEZNAMY 1ba6384647 update README.md 2022-02-16 18:57:40 +01:00
NEZNAMY e2edf9a37c delete unused file 2022-02-16 17:35:23 +01:00
NEZNAMY cb0bfd095d 3.1.0-pre1 2022-02-15 13:05:53 +01:00
NEZNAMY ec03dd4755 fix long line creating empty line above it 2022-02-15 13:05:21 +01:00
NEZNAMY de44f5ae42 update issue templates 2022-02-14 21:34:22 +01:00
NEZNAMY 5ee6796172 implement #347 and probably fix original issue in #475 2022-02-14 21:13:38 +01:00
NEZNAMY d034fca513 add MySQL data conversion commands 2022-02-14 15:58:28 +01:00
NEZNAMY f65c3fb29a remove unused code 2022-02-14 00:02:38 +01:00
NEZNAMY 7192bc9d69 resend objectives/teams on server switch even when pipeline injection is disabled 2022-02-14 00:02:06 +01:00
NEZNAMY d7636a05f4 drastically reduce amount of permission checks by the feature 2022-02-13 23:05:47 +01:00
NEZNAMY bd93301634 send missing packets on that thing through bridge 2022-02-13 21:58:32 +01:00
NEZNAMY b0558ba0a2 just one \t 2022-02-13 21:57:53 +01:00
NEZNAMY 251934bb4b fix NPE on group info when mysql is enabled 2022-02-13 17:01:13 +01:00
NEZNAMY f2c9ef5d30 implement tab expansion on BungeeCord through bridge 2022-02-13 16:43:17 +01:00
NEZNAMY 15a072bbaa fix weird NPE 2022-02-13 13:52:07 +01:00
NEZNAMY 8f1c303862 implement /tab groups and /tab group <name> subcommands 2022-02-12 14:07:23 +01:00
NEZNAMY c79d2e3e6e fix BossBar placeholders not updating when changing value while it was hidden 2022-02-11 19:41:59 +01:00
NEZNAMY f45d8d860b default condition type to AND instead of OR 2022-02-11 19:40:54 +01:00
NEZNAMY 88f31184a0 add back \t for stack traces 2022-02-11 17:54:11 +01:00
NEZNAMY d5368baab4 add final modifier 2022-02-11 17:22:14 +01:00
NEZNAMY 10f645226c fix bridge placeholder refreshing from replacements 2022-02-11 17:12:54 +01:00
NEZNAMY 322c572cd6 add new issue template for wiki changes 2022-02-11 14:19:24 +01:00
NEZNAMY fdfeb178b5 update error.yml 2022-02-10 21:04:37 +01:00
NEZNAMY 1c63cdba91 update error.yml 2022-02-10 21:03:31 +01:00
NEZNAMY 289d0db8e3 create error template 2022-02-10 21:02:26 +01:00
NEZNAMY 9adacca77f upgrade bug report template 2022-02-10 20:59:12 +01:00
NEZNAMY 7dc6813274 avoid NegativeArraySizeException when copying collection by avoiding that operation 2022-02-10 17:53:30 +01:00
NEZNAMY 77bf1cfbb9 #494 2022-02-10 15:44:07 +01:00
NEZNAMY 8f28350579 initial unlimited nametags on bungee support 2022-02-10 15:33:35 +01:00
NEZNAMY 2d06d0c1d3 fix compatibility issue with other plugins 2022-02-06 13:21:35 +01:00
NEZNAMY 7e8301afcd goodbye 3 days of my life 2022-02-05 13:59:12 +01:00
NEZNAMY 2600e8f856 send empty player slots in a single packet 2022-02-03 22:58:35 +01:00
NEZNAMY 914748e14e add toString override to Skin 2022-02-03 22:32:54 +01:00
NEZNAMY 21a7b633e7 simplify 2022-02-01 19:15:57 +01:00
NEZNAMY a77d4352e2 convert classes into anonymous ones 2022-02-01 18:54:01 +01:00
NEZNAMY a7a21e0e51 fix another config conversion bug 2022-02-01 14:49:53 +01:00
NEZNAMY a0a14cd285 fix NPE 2022-02-01 14:18:03 +01:00
NEZNAMY 44b7bedd53 fix bossbar never showing when joining disabled world/server 2022-02-01 14:16:04 +01:00
NEZNAMY 409a0808c1 fix NumberFormatException with Placeholder sorting type 2022-02-01 14:08:22 +01:00
NEZNAMY 4214d02fad send join plugin message on server switch as well 2022-02-01 12:52:02 +01:00
NEZNAMY bc1abb1b58 more javadocs and moved some variables around 2022-01-31 21:37:10 +01:00
NEZNAMY 2f2f53ba4d #488 2022-01-31 20:26:19 +01:00
NEZNAMY cbeb4c151d remove errorDescription parameter from submitted tasks 2022-01-30 19:01:22 +01:00
NEZNAMY 1d5ca70790 remove bridge placeholder usage from cpu command since it's no longer measured 2022-01-30 18:38:03 +01:00
NEZNAMY 1f619ff4d3 allow enabling pet fix feature on proxy and forward status to bridge 2022-01-30 00:43:55 +01:00
NEZNAMY f5acdebe60 bridge recode to drastically reduce packet flow & allow relational placeholder support 2022-01-30 00:34:00 +01:00
NEZNAMY bd59922204 more docs, general cleanup 2022-01-29 15:49:55 +01:00
NEZNAMY c4d9482c79 remove unused code 2022-01-28 21:12:31 +01:00
NEZNAMY 8faef8f017 class cleanup 2022-01-28 20:56:02 +01:00
NEZNAMY 284161db77 create and use Skin class instead of forwarding Objects 2022-01-28 20:54:33 +01:00
NEZNAMY 78db2b66ef placeholder cleanup, unification and performance improvements 2022-01-28 17:18:52 +01:00
NEZNAMY 0d71643ecb make ping value of layout slots configurable 2022-01-28 16:25:39 +01:00
NEZNAMY 9a7a105e7b fix %serveronline% and %worldonline% inaccuracies 2022-01-28 11:25:13 +01:00
NEZNAMY f54d024d97 3.0.2 2022-01-27 20:43:29 +01:00
NEZNAMY 94338bd53f update nested placeholders immediately on plugin message 2022-01-27 13:17:24 +01:00
NEZNAMY 1a9ecc0313 fix belowname update packets being sent in disabled worlds / servers 2022-01-26 22:04:13 +01:00
NEZNAMY 4baeb7b945 properly cancel delayed tasks on shutdown / reload 2022-01-26 18:24:24 +01:00
NEZNAMY baee479fb5 3.0.2-pre6 2022-01-26 01:03:29 +01:00
NEZNAMY 5ad4b2e9c4 so many issues from one wrong method call 2022-01-25 22:57:31 +01:00
NEZNAMY 26657cddfc code style suggestions by intellij 2022-01-25 22:56:52 +01:00
NEZNAMY 947a922f8c reduce amount of logged warns in console 2022-01-25 16:08:46 +01:00
NEZNAMY a2be76184e use tab's thread manager for scoreboard and bossbar announcing 2022-01-25 00:43:57 +01:00
NEZNAMY 8ddb733dc3 do not freeze tab's thread with delayed tasks 2022-01-25 00:33:44 +01:00
NEZNAMY 94e016129b run repeating task for the first time with initial delay 2022-01-25 00:33:21 +01:00
NEZNAMY 5e653ded5d process events in a single thread on velocity as well 2022-01-23 22:04:47 +01:00
NEZNAMY 1bf8097c3f 3.0.2-pre5 2022-01-23 21:39:16 +01:00
NEZNAMY 3d2f11ffd2 move enable call just in case 2022-01-23 18:28:08 +01:00
NEZNAMY 5e77a22d7a further javadoc progress 2022-01-23 18:27:46 +01:00
NEZNAMY 1dffcb1dc3 remove all thread safety checks since they are no longer needed 2022-01-23 17:24:26 +01:00
NEZNAMY edc18cbafb run all tasks in the same thread 2022-01-23 16:49:50 +01:00
NEZNAMY 2f23194432 3.0.2-pre4 2022-01-23 11:06:42 +01:00
NEZNAMY 20709472be fix vehicle / passenger handling 2022-01-23 11:06:16 +01:00
NEZNAMY 7a8c6a0cec some more velocity fixes 2022-01-22 23:11:51 +01:00
NEZNAMY 88558e40a7 round health even when copying max health 2022-01-21 14:49:27 +01:00
NEZNAMY 79386b2b6b allow 64 character scoreboard on <1.13 using "Long|" line prefix 2022-01-21 13:12:03 +01:00
NEZNAMY 3aad8d3cb5 allow per-server / per-world properties through commands 2022-01-21 10:49:06 +01:00
NEZNAMY 272a6f37ad fix NPE 2022-01-20 18:49:33 +01:00
NEZNAMY e10081025d fix load() method not executing methods in correct order resulting in enormous load times with large player counts 2022-01-20 18:31:04 +01:00
NEZNAMY e03a6d8f11 attempt to fix rare error probably caused by concurrent access 2022-01-20 18:29:37 +01:00
NEZNAMY 98e7dc0321 match velocity fixes in AlignedPlayerList as well 2022-01-20 18:24:52 +01:00
NEZNAMY 74438c5d74 so this is why someone was getting a NPE 2022-01-20 18:02:14 +01:00
NEZNAMY 0c4e548565 further increase event processing delay on velocity 2022-01-20 17:06:03 +01:00
NEZNAMY cc70e01e96 merge classes together 2022-01-20 14:34:19 +01:00
NEZNAMY 7c635748af simplify 2022-01-20 13:58:05 +01:00
NEZNAMY 0c874ad56d only keep lowercase entries in sorting map 2022-01-20 13:51:24 +01:00
NEZNAMY 2fb7f80b71 always display bossbars in defined order 2022-01-20 13:14:40 +01:00
NEZNAMY 3f7c3414ce increase server switch processing delay on velocity 2022-01-18 11:23:04 +01:00
NEZNAMY 97165db44d fix bridge placeholders rarely not working in scoreboard 2022-01-18 11:11:10 +01:00
NEZNAMY 82cdf04cf0 add feature override check for onServerChange 2022-01-18 11:10:34 +01:00
NEZNAMY 171d899609 3.0.2-pre3 2022-01-14 20:51:37 +01:00
NEZNAMY 6432278d5d fix scoreboard detection from other plugins not resetting on server switch 2022-01-14 20:41:15 +01:00
NEZNAMY ccaff12451 fix NPE caused by concurrent access 2022-01-14 20:40:54 +01:00
NEZNAMY 11347c080b more debug messages 2022-01-14 15:50:13 +01:00
NEZNAMY 553676c3f9 catch LinkageError instead of more specific ones 2022-01-14 15:49:49 +01:00
NEZNAMY 40b70e7418 fix compatibility with forks that set version field to "Unknown" 2022-01-14 14:22:52 +01:00
NEZNAMY 0ea75019ae catch NoSuchMethodError as well 2022-01-14 14:21:46 +01:00
NEZNAMY dbc092df77 add some missing bossbar command feedback (#462) 2022-01-14 11:09:15 +01:00
NEZNAMY 68049f0dca extract duplicated code into method (and also cancel tasks if plugin fails to load) 2022-01-13 20:54:58 +01:00
NEZNAMY 9db5dfc175 fix NPE when getting last value but placeholder threw error 2022-01-13 20:48:49 +01:00
NEZNAMY 039a316b3b clear players if plugin fails to load 2022-01-13 20:48:16 +01:00
NEZNAMY f4b529f1ce update README.md 2022-01-11 18:50:44 +01:00
NEZNAMY 9c6d606103 code cleanup 2022-01-11 17:57:15 +01:00
NEZNAMY 6cdc06aae7 fix config option path 2022-01-11 17:45:54 +01:00
NEZNAMY 2684654e7b drop redundant remove-strings option 2022-01-11 17:45:07 +01:00
NEZNAMY 25bcc33204 remove harming check 2022-01-10 20:44:41 +01:00
Callum Seabrook e5b3f6215b Added relocation for event 2022-01-10 15:03:16 +00:00
NEZNAMY 9306eadd90 a couple of config conversion fixes 2022-01-09 18:42:13 +01:00
NEZNAMY a27fbb5b8b MessageFile now extends YamlConfigurationFile 2022-01-08 17:27:28 +01:00
NEZNAMY cd4c82b0b8 Merge pull request #477 from JannesStroehlein/master
Fixed localization issue when dealing with floats numbers
2022-01-08 14:45:57 +01:00
Jannes Ströhlein aa6179ee9e made all decimal seperators points instead of some being commas. The commas made the placeholder replacement logic malfunction (2,43 -> 243 instead of 2.43) 2022-01-08 14:39:11 +01:00
NEZNAMY 6594b8c2dc fix replacements being applied twice for bridge placeholders (#476) 2022-01-07 10:47:19 +01:00
NEZNAMY d4c2cdf003 fix startup error when using placeholders with colors inside 2022-01-06 18:41:05 +01:00
NEZNAMY 2b529c37f5 fix rare concurrent modification 2022-01-06 17:55:16 +01:00
NEZNAMY 8599cd925b fix %vanished% refreshing with a much higher delay than it should on bungeecord 2022-01-05 14:32:22 +01:00
NEZNAMY 89f37b4b9e add synchronized modifier to stay safe 2022-01-04 16:46:40 +01:00
NEZNAMY f3136e85ee use equals instead of equalsIgnoreCase for better performance 2022-01-04 16:21:18 +01:00
NEZNAMY 845743073c fix wrong mysql checks 2022-01-04 15:33:36 +01:00
NEZNAMY b2c7bacaf9 fix errors when eventbus fails to load 2022-01-04 15:16:34 +01:00
NEZNAMY ed1673f032 fix #472 2022-01-04 15:15:53 +01:00
NEZNAMY bac9d443ea process all bungee events async 2022-01-03 20:32:28 +01:00
NEZNAMY 90e3868c08 use WeakHashMap for player mysql data & fix playeruuid not working 2022-01-03 15:53:07 +01:00
NEZNAMY c428572e01 add null check that doesn't really make sense, but someone needs it 2022-01-03 14:33:16 +01:00
NEZNAMY 884b5755ec 3.0.2-pre2 2022-01-02 22:47:51 +01:00
NEZNAMY 32d7366795 several fixes in redisbungee support when global playerlist is disabled 2022-01-02 22:47:11 +01:00
NEZNAMY 21bf4a5450 fix using % symbol without any placeholders resulting in %% being displayed 2022-01-02 22:38:59 +01:00
NEZNAMY 8042b02cf5 update README.md 2022-01-02 21:59:08 +01:00
NEZNAMY ae7cdd3982 no longer sending redundant packets on server/world switch 2022-01-01 22:03:19 +01:00
NEZNAMY 9ba945ad76 cache components on velocity as well 2022-01-01 21:51:18 +01:00
NEZNAMY 9cd04c3660 small optimization 2022-01-01 19:12:01 +01:00
NEZNAMY 444bc19781 fix pipeline injection detection on velocity 2022-01-01 18:23:46 +01:00
NEZNAMY eb08c4ba04 convert %afk% replacement when upgrading from free version as well 2022-01-01 14:34:57 +01:00
NEZNAMY 5846e24a29 improve placeholder API 2022-01-01 01:33:03 +01:00
NEZNAMY 9c2c09e433 remove debug messages 2021-12-31 14:20:08 +01:00
NEZNAMY 3c4329697b add PlayerLoadEvent#isJoin() method 2021-12-31 14:12:36 +01:00
NEZNAMY af9951d993 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-31 13:54:52 +01:00
NEZNAMY 630f6df2f5 Merge pull request #467 from NamiUni/patch-1
Correctly display the number of players online.
2021-12-31 13:54:38 +01:00
Namiu/うにたろう fcf07b8e7b Correctly display the number of players online. 2021-12-31 21:49:12 +09:00
NEZNAMY 4824c2f626 send remove packet always, just to stay safe 2021-12-30 14:01:05 +01:00
NEZNAMY 2b6b2e1b63 create a constant to reduce memory allocations 2021-12-29 18:02:22 +01:00
NEZNAMY 6926c1e57f redisbungee should not add/remove players when global playerlist is disabled 2021-12-29 17:12:16 +01:00
NEZNAMY 6a00a7f1ca fix wrong map key type 2021-12-29 00:32:51 +01:00
NEZNAMY 288c3d4c87 add onClickCopyToClipBoard method to ChatModifier class 2021-12-29 00:27:11 +01:00
NEZNAMY ac497bcc41 ignore vanished players in layout 2021-12-28 22:31:45 +01:00
NEZNAMY 7b8d0d6845 fix startup error when fixes slots list is null 2021-12-28 22:05:44 +01:00
NEZNAMY a9a4589fae disable logging of invalid numbers due to false positive on BungeeCord before bridge placeholders are initialized 2021-12-28 18:53:29 +01:00
NEZNAMY b8f972a774 disable scoreboard score packet check due to problems it causes 2021-12-28 18:44:14 +01:00
NEZNAMY 305e388478 translate to a more user-friendly exception when bossbar.yml is missing when trying to convert configuration 2021-12-26 15:18:42 +01:00
NEZNAMY 97e7848a78 add catch for IllegalStateException which may be thrown when using plugman 2021-12-26 15:15:16 +01:00
NEZNAMY d33058a924 fix rare error caused by concurrent access 2021-12-26 15:14:53 +01:00
NEZNAMY eda3cc1f17 fix yellow number & belowname not appearing after client reset packet (on server switch) 2021-12-26 14:47:02 +01:00
NEZNAMY 47043ad4ad fix check if injection is loaded by external plugin 2021-12-24 01:10:26 +01:00
NEZNAMY acf20088cc do not send packet if not needed 2021-12-24 01:09:43 +01:00
NEZNAMY 374cb2766c initialize array just in case 2021-12-24 00:54:31 +01:00
NEZNAMY 31685b9ba5 unregister-before-register should always be disabled on proxy 2021-12-24 00:35:38 +01:00
NEZNAMY 722ff4ce52 3.0.2-pre1 2021-12-23 21:05:45 +01:00
NEZNAMY 161b375043 add floodgate as softdepend to avoid md5 message 2021-12-23 21:04:17 +01:00
NEZNAMY 2c14191cde do not send yellow number to players in disabled worlds/servers 2021-12-23 20:48:45 +01:00
NEZNAMY 486546918f (probably) fix #455 2021-12-23 19:18:09 +01:00
NEZNAMY 23d08e58a4 make help menu text configurable (#448) 2021-12-23 19:15:55 +01:00
NEZNAMY 4c4c34ecaa fix #453 2021-12-23 18:55:29 +01:00
NEZNAMY bd3f2fd70a initialize EventBus in declaration 2021-12-23 18:52:59 +01:00
NEZNAMY b80e42a635 fix NPE in custom lines 2021-12-23 15:32:19 +01:00
NEZNAMY 9446a034d0 fix layout resetting on server switch on velocity 2021-12-23 13:41:13 +01:00
NEZNAMY da0c6ab3fd remove unused import 2021-12-23 11:58:57 +01:00
NEZNAMY c1adb27ee5 remove PacketAPI class as it's no longer needed 2021-12-22 20:54:03 +01:00
NEZNAMY 980d3027e3 use defined constant 2021-12-22 19:23:21 +01:00
NEZNAMY 53ba533f9b small optimizations in reducing amount of sent packets 2021-12-22 19:20:27 +01:00
NEZNAMY e40827da65 don't send empty packets 2021-12-22 18:45:15 +01:00
NEZNAMY b9848b6a96 add debug message for player quit processing time 2021-12-22 18:09:03 +01:00
NEZNAMY 147593b11a use WeakHashMap to store player data in features to not need to remove it on quit 2021-12-22 18:08:47 +01:00
NEZNAMY 21652f928b remove online placeholder update on join/leave 2021-12-22 16:05:07 +01:00
NEZNAMY 5b0352aff0 only unregister teams, no need for scores as well 2021-12-22 15:18:21 +01:00
NEZNAMY b2da2fa096 update README.md 2021-12-22 15:04:12 +01:00
NEZNAMY 0cbb01a2a8 fix #447 2021-12-22 15:02:55 +01:00
NEZNAMY 179840968d Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-22 15:00:53 +01:00
NEZNAMY 3b9c1649a1 Merge pull request #452 from kacperleague9/v3
Setup workflow artifact
2021-12-22 14:47:41 +01:00
NEZNAMY 5750c7dbe1 Merge pull request #440 from NEZNAMY/common-events
Added platform agnostic event system
2021-12-22 14:01:16 +01:00
Callum Seabrook 7ceca359be Let's not recreate the event bus on reload 2021-12-22 12:42:48 +00:00
Callum Seabrook 0f8152a6ed Remove priorities, make events interfaces, and expose bus to API 2021-12-22 11:44:56 +00:00
Callum Seabrook b3258bb020 Added platform agnostic event system 2021-12-22 11:43:30 +00:00
Kacper Smoliński 4b2e705cbc Update build.yml 2021-12-22 08:43:48 +01:00
Kacper Smoliński 31e41382f8 Update build.yml 2021-12-22 08:39:30 +01:00
Kacper Smoliński ecda7192dc Update build.yml 2021-12-22 08:22:32 +01:00
Kacper Smoliński 9a48562b9f test gradle workflow 2021-12-22 08:20:18 +01:00
NEZNAMY c181b58bc1 fix NPE that makes no sense 2021-12-21 17:18:32 +01:00
NEZNAMY 2624afa2ed update README.md 2021-12-21 12:04:18 +01:00
Callum Seabrook 3690af1e35 Removed vanished placeholder from Krypton registry 2021-12-20 18:09:13 +00:00
NEZNAMY 98966d3b38 update README.md 2021-12-20 19:06:09 +01:00
NEZNAMY 41fdd16ce1 fix error when running /tab scoreboard show 2021-12-19 18:52:25 +01:00
NEZNAMY 1bc94859c0 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-19 18:42:23 +01:00
Callum Seabrook 60f6f36437 Error manager good print stack trace bad 2021-12-19 13:16:43 +00:00
Callum Seabrook 82267ba16a Updated dependencies 2021-12-19 13:10:02 +00:00
NEZNAMY 14260deef8 make method synchronized to avoid rare bug caused by misconfiguration 2021-12-18 23:41:11 +01:00
NEZNAMY 8ba7342ccf register vanish placeholder in universal since implementation is same 2021-12-18 12:19:32 +01:00
NEZNAMY f6b935d78e fix double vanish status request on placeholder refresh 2021-12-18 12:17:39 +01:00
NEZNAMY 8cf3ae2091 ping spoof should only affect real players (#444) 2021-12-17 14:55:40 +01:00
NEZNAMY e02b997521 do not use %tps% in default config on bungeecord 2021-12-17 14:50:20 +01:00
NEZNAMY 229cef13c9 add cooldowns for attribute refreshing to prevent massive packet spam with many online players 2021-12-17 14:37:14 +01:00
NEZNAMY f503d6f896 move initialization to declaration to try to fix #442 2021-12-17 14:36:33 +01:00
NEZNAMY d851166bb7 add check for duplicated objectives and score updates without objectives 2021-12-17 13:56:44 +01:00
NEZNAMY 638a861350 display plugin message content in sent packets logging 2021-12-16 20:41:09 +01:00
NEZNAMY 20d7e4cbb0 fix entries with same value skipped in /tab cpu 2021-12-16 20:40:27 +01:00
NEZNAMY 36ccedd7c6 remove unused import 2021-12-16 18:08:38 +01:00
NEZNAMY 31854ba7a6 fix world being requested from bridge twice on reload 2021-12-16 18:07:22 +01:00
NEZNAMY 2639f07f5c recode and fixed 11 issues in config conversion 2021-12-16 17:56:29 +01:00
NEZNAMY b6e13f557f small fix in default config 2021-12-16 17:02:41 +01:00
NEZNAMY 6333d90059 remove redundant check 2021-12-16 17:02:27 +01:00
NEZNAMY fea5d0ec56 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-16 11:07:50 +01:00
NEZNAMY c77f02d1fd disable LD hook until they fix the repository 2021-12-16 11:04:43 +01:00
NEZNAMY c498965cae add API to return player's active scoreboard 2021-12-16 11:03:54 +01:00
Callum Seabrook cdaa77071d Updated Krypton to 0.59.2 2021-12-14 11:48:25 +00:00
NEZNAMY 6a72678c8d simplify 2021-12-14 10:19:47 +01:00
NEZNAMY bb67fc622f fix errors when redisbungee is not enabled correctly 2021-12-13 18:22:16 +01:00
NEZNAMY 5b50c02d93 fix replacements not working in some placeholders 2021-12-13 16:36:54 +01:00
NEZNAMY ffec7e3266 fix world/server groups loading in header/footer 2021-12-13 14:09:56 +01:00
NEZNAMY 039c1e7027 fix velocity compilation 2021-12-11 21:27:29 +01:00
NEZNAMY b27a21b3b8 remove unused variable and imports 2021-12-11 20:03:44 +01:00
NEZNAMY 2bcb5f617e create constants for feature names 2021-12-11 19:51:11 +01:00
NEZNAMY 7bf5294f9f remove redundant check 2021-12-11 17:43:49 +01:00
NEZNAMY c2fd1940f0 separate character width file loading into another method 2021-12-11 17:41:35 +01:00
NEZNAMY 2d095ce6db fix compilation 2021-12-11 17:24:57 +01:00
NEZNAMY e88bc36fca remove unused field 2021-12-11 17:23:20 +01:00
NEZNAMY 5613ea4f77 fix placeholders not updating in replacements 2021-12-11 17:12:58 +01:00
NEZNAMY 9c41599d60 remove redundant escape (again) 2021-12-11 16:04:40 +01:00
NEZNAMY 5f8dd869e0 remove redundant escape in RGB patterns 2021-12-11 15:58:45 +01:00
NEZNAMY fb17df0b7e add registered placeholders to command complete in parse command 2021-12-11 14:53:38 +01:00
NEZNAMY 900ae83028 3.0.1 2021-12-11 12:11:58 +01:00
NEZNAMY 2c09db25b7 Merge pull request #432 from LeonMangler/patch-1
Load TAB after PremiumVanish
2021-12-11 12:10:26 +01:00
NEZNAMY 004e53fa29 Merge pull request #437 from Tanguygab/master
fix NPE when executing scoreboard cmd from console
2021-12-11 12:10:01 +01:00
NEZNAMY e285b143d5 3.0.0-pre3 2021-12-11 00:15:44 +01:00
NEZNAMY f78eb0ffed add API to change group temporarily 2021-12-11 00:14:13 +01:00
NEZNAMY 4d761e1d6e allow decimals in sorting by placeholder 2021-12-11 00:04:20 +01:00
NEZNAMY 4a8c975319 fix startup on bungeecord when assigning groups by permissions AND using bukkit permission manager 2021-12-10 23:45:55 +01:00
NEZNAMY fe56b7ed2d add LP group event listener as well & fix refreshing when assigning by permissions 2021-12-10 23:21:40 +01:00
NEZNAMY 5a74654807 fix scoreboard being enabled by default when converting config 2021-12-10 22:16:08 +01:00
NEZNAMY 533ce4a529 remove unused import 2021-12-10 20:55:19 +01:00
Tanguygab 4ea3780114 fix NPE when executing cmd from console 2021-12-10 19:36:45 +01:00
NEZNAMY 0d229ee26c do not send objective changes before they are registered 2021-12-10 18:25:56 +01:00
NEZNAMY 29079ecad5 add 1.18.1 to recognized versions 2021-12-10 16:01:21 +01:00
NEZNAMY ea88401a58 fix NPE when placeholder returns null 2021-12-10 15:25:17 +01:00
NEZNAMY 298cef4d1f fix startup error if replacement value is null 2021-12-10 15:24:45 +01:00
NEZNAMY a51e9495de add player load status checks to other placeholder types as well 2021-12-10 15:12:43 +01:00
NEZNAMY eead8ca1e2 attempt to avoid rare concurrent modification 2021-12-10 15:11:39 +01:00
NEZNAMY a30712bc38 unregister on bungeecord as well to avoid issues with new bukkit-focused check 2021-12-10 14:56:06 +01:00
NEZNAMY 07b443fb21 actually fixed the error 2021-12-10 14:54:23 +01:00
NEZNAMY 61d927305c add very likely useless check to try to prevent errors 2021-12-10 13:24:29 +01:00
NEZNAMY 8f21c2f27d fix mohist (again) 2021-12-09 22:34:20 +01:00
NEZNAMY 9fcf76e0c4 3.0.1-pre2 2021-12-09 14:53:16 +01:00
NEZNAMY 773afe2fb5 fix _DEFAULT_ not being used when using MySQL (#433) 2021-12-09 14:05:28 +01:00
NEZNAMY 83ce5bd476 Drop <#RRGGBB> format due to conflict with the gradient pattern starting the same way (#430) 2021-12-09 13:50:04 +01:00
NEZNAMY 75a341c240 fix placeholder refreshing being broken for time travelers 2021-12-09 13:44:51 +01:00
NEZNAMY 921a793b5c return identifier instead of null for sync placeholders before initialized 2021-12-09 13:05:31 +01:00
NEZNAMY c1b92868cd fix world forwarding on bungeecord 2021-12-08 20:39:51 +01:00
NEZNAMY 94d19d728d fix condition refresh when only trigger placeholders are used inside 2021-12-08 20:38:39 +01:00
NEZNAMY 8ef518f7e2 add null check for tablist properties when refreshing 2021-12-08 19:11:43 +01:00
NEZNAMY 79fd1148a9 add back animation format converting from 2.8.10 -> 2.9.0 2021-12-08 18:51:00 +01:00
NEZNAMY 313ba8d765 attempt to fix error caused by concurrent access 2021-12-08 18:43:22 +01:00
NEZNAMY c12c422357 fix NPE when editing unknown bossbar 2021-12-08 18:37:56 +01:00
NEZNAMY b14c97d18a add try/catch for ConcurrentModificationException 2021-12-08 18:34:39 +01:00
NEZNAMY 2fe345cb65 add back "barcolors" animation since it's used in default config 2021-12-08 18:11:03 +01:00
NEZNAMY 96ff81370c fix animations lagging when using nested animations 2021-12-08 18:09:48 +01:00
Leon Mangler c4a1f41673 Load TAB after PremiumVanish
When BungeeTabPlayer#isVanished uses PV's API, PV needs to actually be enabled, not just loaded. A soft-dependency should ensure that PV is fully enabled before TAB's onEnable() uses the API.
2021-12-08 17:37:13 +01:00
NEZNAMY ca4c8ccb20 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-08 15:57:51 +01:00
Callum Seabrook 7471006f8a Updated to Krypton 0.58 2021-12-07 18:14:23 +00:00
NEZNAMY 896c709824 fix small memory leak 2021-12-04 22:41:55 +01:00
NEZNAMY 473a37cb6a fix NPE 2021-12-04 22:29:10 +01:00
NEZNAMY 9e84d96051 Add back %essentialsnick% for all the crybabies we get in #community-support who didn't even bother reading changelog of a major plugin update which is supposed to hint big changes were made and the changelog should be read. 2021-12-04 20:56:30 +01:00
NEZNAMY 019466d84d remove unused code 2021-12-04 19:27:02 +01:00
NEZNAMY c222061529 slightly optimize width calculation & partially avoid #347 2021-12-04 19:15:36 +01:00
NEZNAMY acdd99404c use different functions for file operations 2021-12-04 19:08:58 +01:00
NEZNAMY 799381bff3 properly convert objects to string 2021-12-04 19:02:11 +01:00
NEZNAMY b3654977ca cast to long 2021-12-04 18:59:03 +01:00
NEZNAMY b67d1928b5 add "final" modifier 2021-12-04 18:58:00 +01:00
NEZNAMY 052748d2b9 simplify 2021-12-04 18:47:18 +01:00
NEZNAMY e265187ff8 call function instead of duplicating code 2021-12-04 18:10:44 +01:00
NEZNAMY c622a95550 use fixed interval to avoid startup error 2021-12-04 17:09:40 +01:00
NEZNAMY 94d71a245b Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-04 13:28:23 +01:00
NEZNAMY a9403269be add LP softdepend on bungeecord 2021-12-04 13:26:16 +01:00
Callum Seabrook dfe6768eb5 Moved YamlAssist to Krypton repository version 2021-12-04 12:19:55 +00:00
Callum Seabrook d88bf65806 Setup publishing for all but the JAR module 2021-12-04 12:05:35 +00:00
NEZNAMY 30929062d6 what happened here 2021-12-04 12:20:56 +01:00
NEZNAMY 747e3d692d clear registered teams on login packet 2021-12-04 12:16:07 +01:00
Callum Seabrook 1d3ecbb7ed Somehow forgot that display name is now nullable 2021-12-04 10:28:25 +00:00
Callum Seabrook 39b88b0dd5 Updated Krypton to 0.57 2021-12-04 10:24:18 +00:00
NEZNAMY d13d3eb055 bridge placeholders will return identifier until they are initialized instead of null 2021-12-03 16:21:04 +01:00
NEZNAMY f8f72b9074 rgb support for remaining players text as well 2021-12-03 15:47:51 +01:00
NEZNAMY a9d0b0a0ae 3.0.1-pre1 2021-12-03 15:38:46 +01:00
NEZNAMY 37bd624537 double-fix for bungeecord bug kick 2021-12-03 15:37:23 +01:00
NEZNAMY e19f4ed771 reorder bungee.yml to match PluginDescription.java order 2021-12-03 12:11:27 +01:00
NEZNAMY c828fa8d52 Merge remote-tracking branch 'origin/master' 2021-12-03 12:00:36 +01:00
NEZNAMY 9e080a5f5c add argument check 2021-12-03 12:00:20 +01:00
NEZNAMY 7d7d4c05ab remove debug message 2021-12-03 11:59:34 +01:00
NEZNAMY d4c7044708 add proper color support to layout more players text 2021-12-02 20:36:38 +01:00
Callum Seabrook 52dd8c7c8b Added run folder to gitignore for test servers 2021-12-02 18:49:11 +00:00
NEZNAMY 398ac8b6cf register invalid relational placeholders on proxy correctly, so it doesn't throw errors 2021-12-02 18:12:53 +01:00
NEZNAMY 911792b214 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-12-02 13:50:21 +01:00
Callum Seabrook 8e54989502 Setup new publish repository for API 2021-12-02 12:49:11 +00:00
NEZNAMY 4f16579063 support mineskin by uuid 2021-12-02 11:01:19 +01:00
NEZNAMY e1f1698413 fix startup on mohist 1.12.2 2021-12-02 10:09:25 +01:00
NEZNAMY 5eb999b98a fixed typos, capital letters, more docs 2021-12-01 15:52:18 +01:00
NEZNAMY 5e7af835d8 %online% cannot be trigger due to vanish checks 2021-12-01 10:12:05 +01:00
NEZNAMY f19f2c5a20 add conversion for multiple groups with same sorting priority 2021-12-01 08:57:24 +01:00
NEZNAMY ff2aceb781 fix placeholder in default layout.yml 2021-12-01 08:50:37 +01:00
NEZNAMY dc1410adbb update README 2021-11-30 22:05:57 +01:00
NEZNAMY 49af38f3c5 3.0.0 2021-11-30 19:42:48 +01:00
NEZNAMY 09cf4dcd07 actually fix krypton compilation 2021-11-30 19:42:37 +01:00
Callum Seabrook 95c92285b9 Fixed Krypton 2021-11-30 18:05:07 +00:00
NEZNAMY 81b7be9205 remove tpsbar from default config (it's on wiki now) 2021-11-30 18:19:06 +01:00
NEZNAMY c308cde139 fix condition default value of "false" 2021-11-29 18:47:27 +01:00
NEZNAMY 49889cd2cc fix %afk% conversion 2021-11-29 12:33:28 +01:00
NEZNAMY d0ea71f0c9 fix method name 2021-11-28 21:42:25 +01:00
NEZNAMY a6f93dae1e Merge pull request #418 from KryptonMC/v3
Added blossom for plugin version source replacement
2021-11-28 13:34:09 +01:00
Callum Seabrook f968999393 Added blossom for plugin version source replacement 2021-11-28 12:21:15 +00:00
NEZNAMY 37348ed1f4 3.0.0-pre4 2021-11-28 12:19:41 +01:00
NEZNAMY 8602d39d7c fix mysql & load playerdata on every join 2021-11-28 12:14:34 +01:00
NEZNAMY fd41390e20 Merge pull request #417 from NEZNAMY/revert-416-v3
Revert "Switched to adapters over whacky NMSStorage"
2021-11-28 00:44:36 +01:00
NEZNAMY 712064bced Revert "Switched to adapters over whacky NMSStorage" 2021-11-28 00:44:25 +01:00
NEZNAMY 771a696de0 Merge pull request #416 from KryptonMC/v3
Switched to adapters over whacky NMSStorage
2021-11-28 00:02:01 +01:00
Callum Seabrook a56cbcc2f4 Added 1_17_R1 adapter 2021-11-27 23:01:11 +00:00
Callum Seabrook 8e659a2c97 Switched to adapters over whacky NMSStorage 2021-11-27 22:41:04 +00:00
NEZNAMY 423bd0adb8 1.18 2021-11-27 21:28:41 +01:00
NEZNAMY 1987848f8b fix weird NPE 2021-11-27 21:28:36 +01:00
NEZNAMY 13ac8541f2 fix utf symbol in default config 2021-11-27 21:04:31 +01:00
NEZNAMY 0e42d61ffa add %tab_scoreboard_name% placeholder 2021-11-27 18:09:35 +01:00
NEZNAMY 64b4cb1bb9 fix component cloning missing color 2021-11-27 14:08:13 +01:00
NEZNAMY efd723deec add else statement 2021-11-26 21:19:46 +01:00
NEZNAMY 4c2d2068a4 Merge pull request #415 from AlessioGr/v3
Improve TAB Completion for /tab width command
2021-11-25 11:14:37 +01:00
AlessioGr 32529dd7e9 Improve TAB Completion for /tab width command
Signed-off-by: AlessioGr <alessio@gravili.de>
2021-11-25 11:12:04 +01:00
NEZNAMY 3ad54d5f21 Merge pull request #414 from AlessioGr/v3
Further improve Width command
2021-11-25 10:56:38 +01:00
AlessioGr 6d81c37645 Further improve Width command
Signed-off-by: AlessioGr <alessio@gravili.de>
2021-11-25 10:50:53 +01:00
NEZNAMY da1c51eb5b Merge pull request #413 from AlessioGr/v3
Improve /tab width command
2021-11-25 10:18:26 +01:00
AlessioGr 70c37fb9f2 fix Codacy Static Code Analysis warning
Signed-off-by: AlessioGr <alessio@gravili.de>
2021-11-25 10:17:01 +01:00
AlessioGr 5e565be35b Improve /tab width command
Signed-off-by: AlessioGr <alessio@gravili.de>
2021-11-25 10:07:32 +01:00
NEZNAMY eeb39ca228 code style 2021-11-25 09:09:56 +01:00
NEZNAMY 2d5bc2bc52 on load as well 2021-11-24 15:08:47 +01:00
NEZNAMY 4fb517c8cb fix #412 2021-11-24 15:08:07 +01:00
NEZNAMY de376cd9f4 fix onServerChange not being called when it should be 2021-11-24 15:06:52 +01:00
NEZNAMY d939984f08 refresh animations at their original rate while keeping sync 2021-11-24 14:47:19 +01:00
NEZNAMY 89edcb7a38 fix %online_<server>% placeholders 2021-11-24 14:17:53 +01:00
NEZNAMY ac16a0fb26 set gradients first to fix issue from latest new format 2021-11-24 07:39:39 +01:00
NEZNAMY 9189fb2082 3.0.0-pre3 2021-11-23 00:03:38 +01:00
NEZNAMY a2e7670560 Merge branch 'v3' of https://github.com/NEZNAMY/TAB into v3 2021-11-22 23:13:55 +01:00
NEZNAMY 7c9f14b4d9 Merge pull request #411 from KryptonMC/v3
Added Java components for publishing and sources and javadoc jars
2021-11-22 23:13:29 +01:00
NEZNAMY f05849aada fix error on reload 2021-11-22 21:14:00 +01:00
NEZNAMY 66e91ee4e8 don't set numbers if disabled 2021-11-22 21:10:01 +01:00
NEZNAMY 015d8de101 fix error with static lines 2021-11-22 21:08:54 +01:00
Callum Seabrook 69e575e0ef Added Java components for publishing and sources and javadoc jars 2021-11-22 18:46:14 +00:00
NEZNAMY 6c84e49a7f improve default files 2021-11-22 10:01:37 +01:00
NEZNAMY f4e5e8fd72 fix startup error 2021-11-22 09:51:13 +01:00
NEZNAMY fe8c738196 only catch ClassNotFoundException in fabric check 2021-11-22 09:37:20 +01:00
NEZNAMY 665dfac5ea remove unnecessary String.valueOf 2021-11-21 21:50:33 +01:00
NEZNAMY 57f9806819 fix /tab reload breaking external placeholders 2021-11-21 21:32:44 +01:00
NEZNAMY 7874135014 update scoreboard scores when line hides/shows 2021-11-21 21:32:28 +01:00
NEZNAMY f86e7b17ef add another rgb format 2021-11-21 21:04:51 +01:00
NEZNAMY 3803173745 Merge branch 'v3' of https://github.com/NEZNAMY/TAB into v3 2021-11-21 13:31:56 +01:00
NEZNAMY 6af30bf6df improve placeholder registration at runtime 2021-11-21 13:31:43 +01:00
NEZNAMY 7bea6a214a Merge pull request #410 from KryptonMC/v3
Updated Krypton, added vehicle support, and fixed many features being non-functional
2021-11-21 13:30:51 +01:00
Callum Seabrook 9becc35fa1 Fixed many features in Krypton 2021-11-21 12:24:52 +00:00
NEZNAMY 7212a4cd7f round health up 2021-11-21 12:09:24 +01:00
NEZNAMY c604640ab9 fix placeholder registration at runtime 2021-11-21 11:23:13 +01:00
NEZNAMY 23fee2b7b7 fix LP suffix placeholder 2021-11-20 23:44:32 +01:00
NEZNAMY c3d521960e only call onDisable if placeholder was used 2021-11-20 23:09:44 +01:00
NEZNAMY 484396cce1 move %online% update to a better spot and fix NPE 2021-11-20 22:50:49 +01:00
NEZNAMY ce4dec6136 disable krypton compilation 2021-11-20 21:13:59 +01:00
NEZNAMY 67f42f518e implement trigger placeholders 2021-11-20 21:13:50 +01:00
Callum Seabrook 0a0e947282 Added option to specify the config name to use 2021-11-20 19:46:26 +00:00
Callum Seabrook 8a4127574a Fixed NPEs from packets and formatting on Spark placeholders 2021-11-20 18:33:20 +00:00
Callum Seabrook b29d3e5d6a Updated to Krypton 0.50 and made vehicle refresher actually work 2021-11-20 17:41:46 +00:00
NEZNAMY daaece8d36 Merge branch 'v3' of https://github.com/NEZNAMY/TAB into v3 2021-11-20 11:48:49 +01:00
NEZNAMY 0e5b1aaf0e obtain channel instance 2021-11-20 11:48:28 +01:00
NEZNAMY e672e49435 Merge pull request #409 from KryptonMC/v3
Updated Krypton to latest and added support for newest changes
2021-11-20 11:13:50 +01:00
NEZNAMY b9a38a486d make packetBuilder field editable 2021-11-20 10:59:21 +01:00
Callum Seabrook d34c46658d Added refresh display names to refresher constructors 2021-11-19 23:54:48 +00:00
Callum Seabrook e120b647ea Cleaned up Krypton platform and added support for new features 2021-11-19 23:52:46 +00:00
Callum Seabrook 936b8ae903 Updated to Krypton 0.48.1 2021-11-19 23:52:19 +00:00
NEZNAMY 147fe2c277 fix krypton 2021-11-20 00:14:06 +01:00
NEZNAMY 84413aa490 define refresh display name in super() call 2021-11-19 23:13:19 +01:00
NEZNAMY 3fea95f8c5 instance is never null 2021-11-19 22:51:53 +01:00
NEZNAMY b839bce010 change display name and split elsewhere in cpu output 2021-11-19 22:51:05 +01:00
NEZNAMY fc70c098a9 add "final" modifier to all fields possible 2021-11-18 23:00:09 +01:00
NEZNAMY 7b74d73a9a add getter for defined lines into API 2021-11-18 20:38:54 +01:00
NEZNAMY 44ee3bbdfe using shortcuts 2021-11-18 18:30:05 +01:00
NEZNAMY 673285baf8 copy files automatically in UTF-8 encoding 2021-11-18 15:47:10 +01:00
NEZNAMY 2b22e327e3 cache player name widths in aligned suffix
and maybe introduce new bugs, who knows
2021-11-18 15:20:25 +01:00
NEZNAMY 95d65236f6 in NPE 2021-11-18 14:11:02 +01:00
NEZNAMY 8971172444 fix typo in messages 2021-11-18 14:08:05 +01:00
NEZNAMY 6ff5836ca9 fix NPE on fabric 2021-11-18 12:01:47 +01:00
NEZNAMY 8e9a4e9601 use the other way of checking server minor version 2021-11-18 11:54:17 +01:00
NEZNAMY 1ce5c05622 use more universal code 2021-11-18 11:48:52 +01:00
NEZNAMY 7f83e83aed refresh boats in vehicle refresher as well 2021-11-18 11:33:37 +01:00
NEZNAMY e677e7345b remove vehicle on quit 2021-11-18 11:18:11 +01:00
NEZNAMY ae52aa2c55 instant vehicle enter teleport instead of an animation 2021-11-18 11:13:40 +01:00
NEZNAMY b83f6e93bf refreshing vehicles and preview using placeholder engine instead of refreshing task 2021-11-18 11:01:37 +01:00
NEZNAMY 3606ee6275 fix startup on fabric 2021-11-17 21:28:48 +01:00
NEZNAMY 70571cccfe replace stacked reflection exceptions with ReflectiveOperationException 2021-11-17 21:20:12 +01:00
NEZNAMY 87fe02b0b4 attempt to clean up NMSStorage class 2021-11-17 21:05:23 +01:00
NEZNAMY 8e48087f65 load config options in field declarations instead of constructors 2021-11-17 18:45:58 +01:00
NEZNAMY 4e7c3ee2f1 remove duplicated file 2021-11-17 13:33:17 +01:00
NEZNAMY 60a7549662 move constants 2021-11-17 13:32:51 +01:00
NEZNAMY fe7c9488d8 rework property API per-feature 2021-11-16 16:51:31 +01:00
NEZNAMY b7d39e55b6 send armor stand destroy without delay as well 2021-11-16 16:10:51 +01:00
NEZNAMY 805d8030b4 add option to disable unlimited nametags for specific player using API 2021-11-16 16:08:06 +01:00
NEZNAMY 4c6fc5d2d2 fix #408
caused by unregister-register operation on server switch being removed in v3 due to per-world/per-server scoreboards being removed
2021-11-16 12:18:30 +01:00
NEZNAMY 913b8ee238 avoid duplicating code 2021-11-16 11:49:54 +01:00
NEZNAMY 3688e4d938 Merge pull request #407 from KryptonMC/gradle
Gradle!
2021-11-15 21:58:41 +01:00
Callum Seabrook 03842db57f Removed SonarQube and updated workflow to match 2021-11-15 20:56:19 +00:00
Callum Seabrook 6f34157a84 Added inclusion for gradle wrapper 2021-11-15 20:56:19 +00:00
Callum Seabrook 86a82faa15 Fixed Krypton and Velocity annotation processors not working 2021-11-15 20:56:19 +00:00
Callum Seabrook 2e506b72a6 Fixed incorrect shading 2021-11-15 20:56:19 +00:00
Callum Seabrook d2ba0a22d5 These should be this 2021-11-15 20:56:19 +00:00
Callum Seabrook cfc3488a8c Switched build to Gradle 2021-11-15 20:56:17 +00:00
NEZNAMY 0463e82470 Merge pull request #406 from NEZNAMY/revert-405-v3
Revert "Made Krypton a separate JAR"
2021-11-15 18:12:08 +01:00
NEZNAMY 93b151b377 Revert "Made Krypton a separate JAR" 2021-11-15 18:11:47 +01:00
NEZNAMY 1c6fa28d87 Merge pull request #405 from KryptonMC/v3
Made Krypton a separate JAR
2021-11-15 18:06:23 +01:00
Callum Seabrook 71d01263b5 Made Krypton a separate JAR 2021-11-15 17:04:50 +00:00
NEZNAMY 23268907bd compile krypton with java 8 2021-11-15 17:22:43 +01:00
NEZNAMY 076e3061b3 fix pauseTeamHandling not disabling unlimited nametags 2021-11-15 17:15:33 +01:00
NEZNAMY d9f8fa2ed0 split feature elements in cpu output 2021-11-15 16:03:13 +01:00
NEZNAMY c33f9a6d61 drop latency refresher since it doesn't work with new change anymore 2021-11-15 15:49:57 +01:00
NEZNAMY 07f71f3d4d add support for CMI's {#RRGGBB<>} shortcut 2021-11-15 15:40:46 +01:00
NEZNAMY 48f8a4c718 fix spectators exposed for players who joined
caused by pipeline injection being late (async)
2021-11-15 15:03:33 +01:00
NEZNAMY ff29b1badf remove deleted options from conversion 2021-11-15 14:54:49 +01:00
NEZNAMY 05d3233c03 fix typo 2021-11-15 14:50:19 +01:00
NEZNAMY 203b5d925b fix wrong argument 2021-11-15 14:30:08 +01:00
NEZNAMY b2f6338b0b fix krypton 2021-11-15 14:12:32 +01:00
NEZNAMY 26e526d5fe create constants for permission checks 2021-11-15 13:55:03 +01:00
NEZNAMY 054d6c58cb rename class 2021-11-15 13:22:42 +01:00
NEZNAMY cc6b5ea0f5 add missing repository 2021-11-15 13:16:32 +01:00
NEZNAMY 495985ace8 Merge branch 'v3' of https://github.com/NEZNAMY/TAB into v3 2021-11-15 12:36:55 +01:00
NEZNAMY a304853a7b rework command output messages and rename file translation.yml -> messages.yml 2021-11-15 12:36:52 +01:00
NEZNAMY eb2c58f0e9 Merge pull request #404 from KryptonMC/feature/krypton
Added support for Krypton
2021-11-15 12:09:31 +01:00
NEZNAMY 125429bccd ignore case when getting player by name 2021-11-15 11:23:33 +01:00
Callum Seabrook c5bf1b65ba Added online placeholders and made spark placeholders server placeholders 2021-11-14 15:09:35 +00:00
Callum Seabrook 5286a018df Added support for Krypton 2021-11-14 15:09:34 +00:00
NEZNAMY c408744385 add back %% transforming into a single % 2021-11-14 14:19:05 +01:00
NEZNAMY 5efd5f310f change names of slots 2021-11-13 23:52:15 +01:00
NEZNAMY e35c14d8e3 measure NMS hook load time 2021-11-13 22:07:55 +01:00
NEZNAMY d49fcc2307 properly send action bar messages on velocity 2021-11-13 18:48:49 +01:00
NEZNAMY afc1dfcf10 remove redundant initialization 2021-11-13 14:49:17 +01:00
NEZNAMY 2dd06ed0c3 cleanup in placeholder registration 2021-11-13 13:35:28 +01:00
NEZNAMY 2ca223cd2c drop AntiAFKPlus hook 2021-11-13 13:24:29 +01:00
NEZNAMY f6cf018625 update supported versions 2021-11-13 13:18:45 +01:00
NEZNAMY 1d7806c96e fill exception message 2021-11-12 17:18:05 +01:00
NEZNAMY 650fd892f8 fix error when output is not a number 2021-11-12 16:52:52 +01:00
NEZNAMY 83710b14b1 add "me" player name completion to /tab parse 2021-11-12 16:47:49 +01:00
NEZNAMY 1eeb22f579 do not send score changes when player is not loaded yet 2021-11-12 16:47:31 +01:00
NEZNAMY 1d70e73106 add null check for redisbungee api instance 2021-11-12 13:57:37 +01:00
NEZNAMY 9d93b52be1 only process nicking once instead of for every online player 2021-11-12 13:21:52 +01:00
NEZNAMY 4431772007 create instance of CollisionManager on 1.8 to prevent NPEs 2021-11-12 13:15:14 +01:00
NEZNAMY f17fafbb48 shorter alternative 2021-11-11 22:41:31 +01:00
NEZNAMY 8d30399f33 initial support for nick plugins 2021-11-11 22:20:59 +01:00
NEZNAMY 5feb934a4a add space 2021-11-11 18:06:30 +01:00
NEZNAMY 9466b96f69 properly forward team flags in packets 2021-11-11 13:08:40 +01:00
NEZNAMY ad00d1b145 only start layout feature on 1.8+ 2021-11-11 13:08:06 +01:00
NEZNAMY 89ea9ba8a0 return empty list instead of null 2021-11-11 11:57:24 +01:00
NEZNAMY e08fb3eeb6 fix skin saving 2021-11-11 11:52:58 +01:00
NEZNAMY 5800c8910e split skinmanager class into multiple 2021-11-11 11:48:55 +01:00
NEZNAMY 1ec77cb0b5 don't refresh collision if no disguise plugin is available 2021-11-11 11:09:37 +01:00
NEZNAMY 3329514066 decrease default time to 10000 since it can't get higher than that anyway 2021-11-11 10:41:11 +01:00
NEZNAMY addc3f322f load feature after registering placeholders correctly to avoid wrong registration 2021-11-11 10:40:56 +01:00
NEZNAMY 79dcd16d37 only refresh visibility if 1.8.x clients are accepted 2021-11-11 10:09:58 +01:00
NEZNAMY 802c72a9aa don't refresh collision if it's disabled already 2021-11-10 22:53:01 +01:00
NEZNAMY bf96676df5 properly update collision on api call 2021-11-10 22:48:21 +01:00
NEZNAMY d245b93196 remove unnecessary this. 2021-11-10 21:51:59 +01:00
NEZNAMY 6f96b555e9 split collision management into separate class + placeholder based refreshing instead of repeating task 2021-11-10 21:47:48 +01:00
NEZNAMY 872700d1be create placeholder for visibility check instead of refreshing task 2021-11-10 21:01:07 +01:00
NEZNAMY 1ac08ee1f2 try/catch for more exception types 2021-11-10 20:34:06 +01:00
NEZNAMY ada433150c fix forceTeamName method not working 2021-11-10 13:58:02 +01:00
NEZNAMY ee40a69e57 use cleaner alternative 2021-11-10 13:57:37 +01:00
NEZNAMY d6fcaffa99 add team name changing support to redisbungee 2021-11-10 13:45:42 +01:00
NEZNAMY fe4bdda549 fix property name in debug output 2021-11-10 13:01:08 +01:00
NEZNAMY 6a1016a383 move &r 2021-11-10 12:59:14 +01:00
NEZNAMY c53f08d0a7 surround deserialize method with try/catch instead of throwing 2021-11-10 11:59:51 +01:00
NEZNAMY 2807ff30e6 fix premiumconfig not being deleted 2021-11-10 11:23:41 +01:00
NEZNAMY cf3b9c21dd apply rgb formats later so raw value returns actual raw value 2021-11-09 11:07:28 +01:00
NEZNAMY ee616412d6 simplify 2021-11-08 19:13:45 +01:00
NEZNAMY 341c6f8722 3.0.0-pre2 2021-11-07 15:27:25 +01:00
NEZNAMY 978df99e5c create dummy placeholder instead of thread for cpu stats reset 2021-11-06 19:19:03 +01:00
NEZNAMY a91e2a90b4 fix substring size 2021-11-06 15:25:44 +01:00
NEZNAMY 49c54c6a58 Merge pull request #402 from Tanguygab/v3
added texture skin type for Layout SkinManager
2021-11-04 12:17:38 +01:00
Tanguygab 6b72163dbe added texture: skin type 2021-11-04 12:09:14 +01:00
NEZNAMY 93a04c64d2 fix startup error with relational placeholders 2021-11-03 22:41:15 +01:00
NEZNAMY d01d814778 show configured fake ping instead of 0 2021-11-02 21:33:39 +01:00
NEZNAMY af15c256b9 use more accurate task name 2021-11-02 21:32:16 +01:00
NEZNAMY dde0056ba2 fix nested placeholders not working in replacements 2021-11-02 20:34:25 +01:00
NEZNAMY dede5b548c reduce memory allocations of property loading 2021-11-02 14:55:02 +01:00
NEZNAMY 7be0831e7c do not use split function if not needed 2021-11-02 14:33:54 +01:00
NEZNAMY 660275dc74 change List to array 2021-11-02 13:37:45 +01:00
NEZNAMY 957e01fbf2 dynamic placeholder refresh task interval based on fastest placeholder 2021-11-02 00:41:14 +01:00
NEZNAMY b01ffaf763 simplify 2021-11-02 00:00:54 +01:00
NEZNAMY 8d6d53a448 use stringbuilder 2021-11-01 22:34:45 +01:00
NEZNAMY 8f13bfcb4a merge ifs 2021-11-01 22:32:29 +01:00
NEZNAMY ddf45bf7a7 remove unnecessary {} 2021-11-01 22:31:36 +01:00
NEZNAMY 9fabeac7e1 remove redundant cast 2021-11-01 22:30:15 +01:00
NEZNAMY 758b1f9365 simplify return 2021-11-01 22:29:34 +01:00
NEZNAMY 0050d34d0e remove redundant check 2021-11-01 22:27:09 +01:00
NEZNAMY fd547383c4 remove unused methods 2021-11-01 22:02:35 +01:00
NEZNAMY edb640f496 add expected team name into logging 2021-11-01 21:38:35 +01:00
NEZNAMY 4569fa3e86 optimize method 2021-11-01 21:22:58 +01:00
NEZNAMY 33af012352 remove redundant call 2021-11-01 20:58:42 +01:00
NEZNAMY 5cc6688d9c optimize disabled world checking for unlimited nametags 2021-11-01 20:45:40 +01:00
NEZNAMY f8a5f610bb remove redundant null check 2021-11-01 18:57:12 +01:00
NEZNAMY 877ac8adc7 GroupManager refreshing engine change from repeating task to placeholder core 2021-11-01 18:22:36 +01:00
NEZNAMY 39040c263e refresh world on switch instead of periodically on proxy 2021-11-01 17:03:05 +01:00
NEZNAMY 08759762a1 fix global playerlist on velocity 2021-11-01 15:50:12 +01:00
NEZNAMY 7897fbcf36 fix tablist format on server switch on velocity 2021-11-01 15:45:09 +01:00
NEZNAMY ce93bb1afb fix NPE with component sent to console 2021-11-01 15:12:44 +01:00
NEZNAMY 3e8085f460 fix sorting startup with layout on proxy 2021-11-01 15:06:09 +01:00
NEZNAMY 2ab201d278 print LibsDisguises hook error once instead of spamming it 2021-11-01 14:42:09 +01:00
NEZNAMY ccdac844b9 move plugin info component to command class 2021-11-01 14:39:34 +01:00
NEZNAMY 4474939c51 small code structure change 2021-11-01 14:19:31 +01:00
NEZNAMY f32975ccb0 decrease wither distance to 60 blocks 2021-11-01 14:17:05 +01:00
NEZNAMY 4f92b22955 use placeholder refreshing engine for bossbar updating instead of repeating task
this will also reduce teleports if players don't move
2021-11-01 14:07:24 +01:00
NEZNAMY 1d8ac0ab45 warn in console about Tablisknu compatibility issue 2021-11-01 12:52:33 +01:00
NEZNAMY 4cfc5258b2 add separate cpu measuring of hasPermission method 2021-11-01 12:30:48 +01:00
NEZNAMY 14b7415005 cache floodgate presence 2021-11-01 00:29:48 +01:00
NEZNAMY f482b712ca save registered scoreboards in array to reduce allocations from iteration 2021-11-01 00:25:40 +01:00
NEZNAMY c40a5cbaaa changed parse command syntax to include player name 2021-11-01 00:13:14 +01:00
NEZNAMY 9d0efca1e5 avoid any possible double bossbar create 2021-10-29 13:03:37 +02:00
NEZNAMY cf4d76e9a4 make method synchronized to avoid rare error 2021-10-28 15:58:12 +02:00
NEZNAMY 56569509f9 use ConcurrentHashMap to avoid ConcurrentModificationException 2021-10-27 21:07:05 +02:00
NEZNAMY a0904be305 use more appropriate names for anonymous conditions 2021-10-26 21:15:14 +02:00
NEZNAMY 7d156fb47b fix rare NPE 2021-10-26 21:04:34 +02:00
NEZNAMY e1796d24ad fix mysql 2021-10-24 10:48:19 +02:00
NEZNAMY 2899b1f8eb add announcement-bar property instead of listing default-bars 2021-10-21 13:14:14 +02:00
NEZNAMY 335a033091 fix NPE 2021-10-21 09:24:22 +02:00
NEZNAMY 80aa2367b0 add back width command
as well as showing character sequence if a multi-character symbol is entered
2021-10-20 21:06:17 +02:00
NEZNAMY e6ca5884a3 only decrease interval instead of possibly increasing 2021-10-20 20:14:59 +02:00
NEZNAMY ef52c84e25 calculate condition refresh intervals based on fastest placeholder 2021-10-20 19:03:25 +02:00
NEZNAMY 478f2fc9ae add back support for ; and * for groups in per-world / per-server 2021-10-20 18:25:21 +02:00
NEZNAMY 98afededa6 create method to clean up code 2021-10-20 18:04:03 +02:00
NEZNAMY 7ad2ca9f16 add viaversion compatibility check 2021-10-20 18:02:13 +02:00
NEZNAMY 03ab379c63 remove default-scoreboard option when converting config 2021-10-20 17:51:38 +02:00
NEZNAMY bd71efd22b update readme to reflect this branch 2021-10-19 22:52:27 +02:00
NEZNAMY 87b7a1c759 initial RedisBungee support
this update was only slightly tested and may contain bugs, which will eventually be fixed
2021-10-19 22:49:40 +02:00
NEZNAMY 5c59c3b1b8 fix server switch listener on bungeecord 2021-10-19 21:18:08 +02:00
NEZNAMY bb98db4568 remove and rename placeholders 2021-10-19 20:42:23 +02:00
NEZNAMY 80f0afd600 disable layout by default 2021-10-19 14:17:56 +02:00
NEZNAMY 5bc37b51bb fix player initialization 2021-10-19 14:10:04 +02:00
NEZNAMY 0f68892d11 add sorting by player name to conversion 2021-10-18 18:23:50 +02:00
NEZNAMY 37e731c2fd fix typo 2021-10-18 14:10:06 +02:00
NEZNAMY 8312ae30f1 add getter for spyServers list 2021-10-18 13:58:50 +02:00
NEZNAMY 28ec42dddf improve parity between platforms 2021-10-17 20:45:25 +02:00
NEZNAMY d9f572188e bump YamlAssist version 2021-10-17 16:54:47 +02:00
NEZNAMY 720a95d472 3.0.0-pre1 2021-10-17 12:12:35 +02:00
NEZNAMY 74ba60f4f1 fix resetScoreboard not working 2021-10-16 21:35:52 +02:00
NEZNAMY e717473a21 code style 2021-10-16 00:39:26 +02:00
NEZNAMY aca1e26c3b attempt to fix concurrent modification 2021-10-15 21:27:18 +02:00
NEZNAMY 0b1bcebc72 move initialization 2021-10-15 21:07:16 +02:00
NEZNAMY 058a5dca17 fix NPE 2021-10-15 20:43:17 +02:00
NEZNAMY da21131f9c code style 2021-10-15 20:35:25 +02:00
NEZNAMY 30fd9f84e0 code style 2021-10-15 20:29:35 +02:00
NEZNAMY 291f881e61 remove unused import 2021-10-15 19:52:13 +02:00
NEZNAMY bdb465b54e change return type from Future<?> to Future<Void> 2021-10-15 19:46:26 +02:00
NEZNAMY e39a10da22 code style 2021-10-15 17:37:48 +02:00
NEZNAMY 8f4ab6a7f1 fix premiumconfig absence when using free version 2021-10-15 17:20:22 +02:00
NEZNAMY 3259fc1a52 improve console message 2021-10-15 17:16:32 +02:00
NEZNAMY 05d85a0dc1 rethrow exceptions 2021-10-15 17:05:24 +02:00
NEZNAMY e7c4658805 add missing collision option conversion 2021-10-15 17:02:14 +02:00
NEZNAMY 51220bcae6 fix startup when sorting placeholder is not valid 2021-10-15 17:01:47 +02:00
NEZNAMY e8ff42dd75 fix typos 2021-10-15 17:01:15 +02:00
NEZNAMY 6bd54ccf2b Merge pull request #393 from Tanguygab/v3
Added 2.9.2 -> 3.0 config converter
2021-10-15 16:42:54 +02:00
NEZNAMY c3bcaba61e reduce retry count and only print error if debug is enabled 2021-10-15 16:40:37 +02:00
Tanguygab 14693b4a6e converting _OTHER_ to _DEFAULT_ 2021-10-13 15:12:12 +02:00
Tanguygab b1a75df507 Merge remote-tracking branch 'upstream/v3' into v3 2021-10-13 14:58:57 +02:00
NEZNAMY 42d65cf0dd create a copy of map to avoid error on modification 2021-10-10 17:08:30 +02:00
NEZNAMY b18803e343 add null check 2021-10-10 17:00:15 +02:00
NEZNAMY a36a071dbe update sorting error message to match new config 2021-10-10 16:53:39 +02:00
NEZNAMY edc95e1fa0 create dummy entity to use in packet constructor instead of using first player
which randomly caused NoSuchElementException
2021-10-10 16:51:14 +02:00
NEZNAMY 11b3d3ef41 remove unnecessary null check from previous testing 2021-10-10 16:45:10 +02:00
NEZNAMY 64f339b1fa synchronize list to avoid rare toArray null element issue 2021-10-10 16:09:09 +02:00
Tanguygab a6eefa7afd using File.separator instead of \\ 2021-10-09 00:53:26 +02:00
Tanguygab 837d1fb43d check if legacy config 2021-10-09 00:44:56 +02:00
Tanguygab 0d190b4ade checking if file already exists 2021-10-09 00:30:25 +02:00
Tanguygab fbc7acea60 wrong config 2021-10-09 00:25:29 +02:00
Tanguygab e6676e1a05 added 2.9.2 -> 3.0 config conversion 2021-10-09 00:22:28 +02:00
Tanguygab b9a56c6c65 Intellij didn't recognize API's classes without that for some reasons 2021-10-09 00:21:42 +02:00
NEZNAMY 520c152cc6 add debug message when missing config option was added 2021-10-08 23:35:20 +02:00
NEZNAMY f7ddf6f872 add null check 2021-10-07 09:57:05 +02:00
NEZNAMY e6997d81c1 do not show layout to bedrock and 1.7 players 2021-10-06 09:57:16 +02:00
NEZNAMY 31923fc73c attempt to fix rare error 2021-10-03 23:30:33 +02:00
NEZNAMY 5dbfc97780 fix placeholders only used in tab expansion not refreshing 2021-10-03 23:30:11 +02:00
NEZNAMY da525fa1c8 no longer require nametag sorting feature for layout to work 2021-09-23 18:39:01 +02:00
NEZNAMY 372866ee95 fix typo 2021-09-23 14:41:10 +02:00
NEZNAMY d1e1df01c0 only recalculate used placeholders if changed 2021-09-23 11:53:20 +02:00
NEZNAMY b12d9f352b port changes from #389 2021-09-20 22:38:48 +02:00
NEZNAMY b3dc4b617b change lists back to sets to avoid duplicates and cpu leak 2021-09-20 20:18:54 +02:00
NEZNAMY 67e3ff368d create class for placeholder replacements and reduce memory allocations 2021-09-20 18:25:48 +02:00
NEZNAMY 569ad41894 separate groupmanager class and fix loading order 2021-09-19 00:42:55 +02:00
NEZNAMY bd5225967d replace all sets with lists 2021-09-15 18:14:45 +02:00
NEZNAMY 9c9df4ee3b pre-parse static numeric values in conditions for better performance and lower memory allocations 2021-09-13 21:26:10 +02:00
NEZNAMY a859a20062 fix API scoreboard overridden on world/server switch 2021-09-13 21:03:43 +02:00
NEZNAMY 4fd8e736f9 add option to disable remaining players text in layout 2021-09-13 20:56:46 +02:00
NEZNAMY 41fc9b329b improve placeholder exception catching 2021-09-12 13:37:29 +02:00
NEZNAMY 3ea9408103 optimize conditions using functions 2021-09-11 23:33:44 +02:00
NEZNAMY 589170ac8a catch specific exceptions and remove redundant catch 2021-09-11 23:29:26 +02:00
NEZNAMY 54bd6cd402 use more optimized check and avoid exception throwing 2021-09-11 22:41:35 +02:00
NEZNAMY 9374b56ec7 fix method not working correctly after recode 2021-09-11 22:39:36 +02:00
NEZNAMY f6a3ea79ef use Bukkit.getTPS() if possible 2021-09-11 19:25:23 +02:00
NEZNAMY 840e2610c5 remove unused field 2021-09-08 13:44:04 +02:00
NEZNAMY d673dbf1cc fix memory leak in layouts 2021-09-07 23:27:18 +02:00
NEZNAMY 26c5de3122 include layout name in fixed slot property name to fix clash 2021-09-07 22:59:55 +02:00
NEZNAMY 7c5d2647c8 fix NPE 2021-09-07 21:49:17 +02:00
NEZNAMY 3a6256179c code cleanup with shorter load alternative 2021-09-07 19:59:39 +02:00
NEZNAMY 1d4e5fbd70 share Yaml instance across configuration files 2021-09-07 19:24:32 +02:00
NEZNAMY a456fffe45 placeholder classes no longer need to be abstract 2021-09-07 18:55:12 +02:00
NEZNAMY 3240924b2c aligned playerlist class now extends playerlist 2021-09-07 18:20:09 +02:00
NEZNAMY 670406991c match _OTHER_ being renamed to _DEFAULT_ 2021-09-07 14:56:55 +02:00
NEZNAMY 839543bbdd fix memory leak 2021-09-07 01:09:45 +02:00
NEZNAMY 47511b33a3 remove placeholder refresh interval check 2021-09-07 01:09:38 +02:00
NEZNAMY 264fd0b3a4 merge methods 2021-09-06 20:41:25 +02:00
NEZNAMY f10af90c14 remove redundant check 2021-09-06 20:34:08 +02:00
NEZNAMY 782a82ea30 use essentials directly instead of reflection 2021-09-06 20:05:25 +02:00
NEZNAMY bc0d6bb09e drop AFK+ support since it has papi support 2021-09-06 19:39:44 +02:00
NEZNAMY 54fd9d9492 rethrow InterruptedException 2021-09-06 16:15:21 +02:00
NEZNAMY 59f804c96a replace lambdas with method references 2021-09-06 16:12:51 +02:00
NEZNAMY fba1325abe remove forgotten debug message 2021-09-06 16:06:53 +02:00
NEZNAMY 4b634ad67a add support for multiple layouts with conditions 2021-09-06 16:02:17 +02:00
NEZNAMY 3990ba055a use first color in case of 1 character gradient instead of middle color 2021-09-06 15:33:40 +02:00
NEZNAMY 48784a3d7a fix random NPE which should never be thrown 2021-09-06 15:09:24 +02:00
NEZNAMY 61e87718da avoid NPE caused by invalid data sent 2021-09-06 15:02:49 +02:00
NEZNAMY a55dd34eda initialize world on proxy to prevent NPE 2021-09-06 13:20:35 +02:00
NEZNAMY fc304e5dc7 fix string comparison 2021-09-06 11:26:13 +02:00
NEZNAMY 3870950e29 avoid duplicating code 2021-09-06 01:21:54 +02:00
NEZNAMY fc97830d22 change abstract class to interface and save as array to save memory when iterating 2021-09-06 00:45:35 +02:00
NEZNAMY c7579c259b cache property names 2021-09-06 00:19:52 +02:00
NEZNAMY 1272e09a73 fix sync placeholders registering non-sync version if they didn't parse 2021-09-05 20:19:10 +02:00
NEZNAMY 79b4cbe7f1 fix gradient if text is only 1 character long 2021-09-05 17:26:44 +02:00
NEZNAMY 9a000f7881 fix startup if injection is not enabled 2021-09-05 17:16:28 +02:00
NEZNAMY 30367ad328 fix tps placeholder in default configs 2021-09-05 17:12:15 +02:00
NEZNAMY d67b447895 include plugin message packets in packet count 2021-09-05 16:28:42 +02:00
NEZNAMY 0d9c727dde remove separate measurement of component conversion methods 2021-09-05 16:26:37 +02:00
NEZNAMY 321a56d5cf add override check to onQuit as well 2021-09-05 13:36:20 +02:00
NEZNAMY fbbc4ee864 change display name of cpu value 2021-09-05 00:21:03 +02:00
NEZNAMY 36f6e792db only refresh belowname in same world (and server) 2021-09-05 00:11:30 +02:00
NEZNAMY f71c7c5076 show N/A for %world% on proxy if bridge is missing 2021-09-04 23:49:16 +02:00
NEZNAMY 33ec5a5cce remove internal: prefix from vanish placeholder since literal output is not used directly and add it on bukkit as well 2021-09-04 23:43:16 +02:00
NEZNAMY bbcf0add3f don't deserialize bytebufs if no features use it 2021-09-04 23:40:02 +02:00
NEZNAMY 80aa041d1c fix desync between my workspace and github (2/2) 2021-09-04 20:27:33 +02:00
NEZNAMY 35617e97a5 fix desync between my workspace and github (1/2) 2021-09-04 20:26:07 +02:00
NEZNAMY 9a802c0db9 fix vanished player removal 2021-09-04 20:24:32 +02:00
NEZNAMY d588f2fdee new config example equal to purpur's tpsbar 2021-09-04 13:10:26 +02:00
NEZNAMY ad0424175d partially redocument api package 2021-09-02 21:35:35 +02:00
NEZNAMY 3bf9856c26 fix nearby players registration 2021-09-01 23:35:24 +02:00
NEZNAMY 2395ee05f9 save cached placeholder array in Placeholder type 2021-08-31 20:33:10 +02:00
NEZNAMY 2a5168e800 add API methods used by addon 2021-08-31 15:32:20 +02:00
NEZNAMY da861cc73c sorting by name is no longer forced and is configurable 2021-08-29 11:35:32 +02:00
NEZNAMY 4cd974cb0e ignore empty collections 2021-08-29 11:23:27 +02:00
NEZNAMY 14cb32fc58 don't start task if no permission plugin is found 2021-08-29 11:08:15 +02:00
NEZNAMY 3197671950 use placeholder refresh core to refresh team names instead of repeating task 2021-08-29 11:07:22 +02:00
NEZNAMY cd29baf9cc fix sync placeholders from v3 placeholder loading recode 2021-08-28 22:41:29 +02:00
NEZNAMY 03ca76e679 add config option to disable latency updating 2021-08-28 22:21:05 +02:00
NEZNAMY 933855baac add override check to all methods to not have cpu output spammed with 0s 2021-08-28 22:15:54 +02:00
NEZNAMY ee61259114 rework placeholder registration methods 2021-08-28 18:06:42 +02:00
NEZNAMY d26f88e0f1 add check which should not be necessary 2021-08-28 17:24:23 +02:00
NEZNAMY c8fc144b8a replace field with local variable 2021-08-28 17:07:49 +02:00
NEZNAMY d8ae647140 again 2021-08-28 16:59:01 +02:00
NEZNAMY ab5767bee8 move some methods around 2021-08-28 16:49:07 +02:00
NEZNAMY 7c63d3c176 nah 2021-08-28 16:27:50 +02:00
NEZNAMY d837dfdd77 remove duplication 2021-08-28 16:10:50 +02:00
NEZNAMY 31612a7cb1 refer to EnumChatFormat class for colorizing and color char 2021-08-28 16:04:26 +02:00
NEZNAMY 3d25ec32c0 create and use platform-specific config file 2021-08-28 15:06:03 +02:00
NEZNAMY e3cda07f0f fix NPE during startup 2021-08-28 14:54:11 +02:00
NEZNAMY 18762961e1 count cpu usage of LP event listener 2021-08-28 14:22:18 +02:00
NEZNAMY 9cc1112a3e use event listener for LP group refreshing instead of repeating task 2021-08-28 11:22:08 +02:00
NEZNAMY 2204a8437f remove method that is no longer used 2021-08-28 11:21:26 +02:00
NEZNAMY c37e0d2fab avoid NPE 2021-08-28 11:03:28 +02:00
NEZNAMY 4ce85692a7 fix method from recode 2021-08-28 11:00:43 +02:00
NEZNAMY 860658f367 move PermissionPlugin instance to GroupRefresher class 2021-08-27 21:29:49 +02:00
NEZNAMY 4310ce95ea increase refresh interval 2021-08-27 18:28:37 +02:00
NEZNAMY 66ae6b2a33 hook into LD directly instead of using reflection 2021-08-27 18:17:00 +02:00
NEZNAMY 5f45a38f08 save nearby players into array 2021-08-27 18:03:44 +02:00
NEZNAMY c26cd30dfd fix component cache between legacy and modern versions and cache raw strings for bungeecord as well 2021-08-27 16:32:24 +02:00
NEZNAMY 4b0fe94f34 handle 1.9 bossbar packet using VV API instead of directt packets 2021-08-27 15:52:15 +02:00
NEZNAMY 7fc80f8e10 fix bossbar load/unload on <1.9 2021-08-27 15:51:23 +02:00
NEZNAMY 2875676308 update URL 2021-08-27 14:50:17 +02:00
NEZNAMY 814726d545 fix startup on fabric 2021-08-27 13:18:28 +02:00
NEZNAMY 0ae60a0463 Update PipelineInjector.java 2021-08-27 12:33:16 +02:00
NEZNAMY c96bef9ac5 remove remove-strings array instead of list 2021-08-25 22:11:26 +02:00
NEZNAMY db9fd9e4d5 cache variables for %afk% placeholder 2021-08-25 21:55:12 +02:00
NEZNAMY 90ab2f0dbd remove redundant catch 2021-08-25 17:05:57 +02:00
NEZNAMY f8f6cb3cc2 simplify 2021-08-25 17:04:37 +02:00
NEZNAMY 72d741f795 move constructors 2021-08-25 16:56:29 +02:00
NEZNAMY e784f4bcf0 create constants instead of copying strings 2021-08-25 13:58:54 +02:00
NEZNAMY a50f34d2b4 merge calls 2021-08-25 01:22:11 +02:00
NEZNAMY dce58a7793 increase quit delay 2021-08-24 23:11:15 +02:00
NEZNAMY 5c9de8de7c fix placeholders only called through expansion not refreshing 2021-08-24 23:11:06 +02:00
NEZNAMY c1c2ceb33e no longer needed 2021-08-24 23:10:13 +02:00
NEZNAMY b39eca0e0e call placeholder directly since it's possible now 2021-08-24 23:07:53 +02:00
NEZNAMY cadcc69eef rename field 2021-08-24 18:55:18 +02:00
NEZNAMY 120f2b2d44 save bukkit bossbar style formats instead of replacing 2021-08-24 16:07:35 +02:00
NEZNAMY 495d7ecf19 save Formatter instance instead of creating new one every time 2021-08-24 15:47:38 +02:00
NEZNAMY 140a45a7cb cache enabled plugin booleans 2021-08-24 12:59:38 +02:00
NEZNAMY bd12ff73f8 cache created components to reduce memory allocations and speed up code 2021-08-23 18:33:24 +02:00
NEZNAMY 7b4182dce3 add floodgate hook to use numbered scoreboard for bedrock users 2021-08-23 17:36:45 +02:00
NEZNAMY f8098423a3 add header/footer API 2021-08-23 17:11:01 +02:00
NEZNAMY 9e1a8c29ac remove redundant .toString() call 2021-08-22 21:59:58 +02:00
NEZNAMY 157833d806 prevent NPE 2021-08-22 21:58:34 +02:00
NEZNAMY 91a61eb014 fix sorting not updating in layout 2021-08-22 18:29:39 +02:00
NEZNAMY 1f037dbda7 cache used placeholder keyset 2021-08-22 17:43:52 +02:00
NEZNAMY d9c68e7360 remove redundant check 2021-08-22 16:51:12 +02:00
NEZNAMY 51507d3905 use correct description 2021-08-22 16:50:34 +02:00
NEZNAMY 31e83ebbb5 use feature subcategories in sent packets in /tab cpu 2021-08-22 16:21:40 +02:00
NEZNAMY 3e2f1fb5a8 make layout display condition checking placeholder based instead of refreshing 2021-08-22 14:00:59 +02:00
NEZNAMY 5ad360eaf2 make bossbar display condition checking placeholder based instead of refreshing 2021-08-22 13:30:15 +02:00
NEZNAMY b7b8cd3fea make scoreboard display condition checking placeholder based instead of refreshing 2021-08-22 13:27:28 +02:00
NEZNAMY 243fccac9e make vanish status refreshing for global playerlist placeholder based 2021-08-22 13:07:01 +02:00
NEZNAMY 51b3035434 fix check 2021-08-21 22:10:54 +02:00
NEZNAMY be9fba23ac fix PLACEHOLDER sorting type requiring lowercase values 2021-08-21 19:00:36 +02:00
NEZNAMY 0ac9b703d5 remove redundant call 2021-08-21 17:40:02 +02:00
NEZNAMY 21c51ff074 remove debug message 2021-08-21 17:39:43 +02:00
NEZNAMY a735b2f0b0 split subfeatures for better cpu tracking 2021-08-21 17:31:56 +02:00
NEZNAMY 0baea2c5ea add remaining players text to layout 2021-08-21 17:14:53 +02:00
NEZNAMY ca2463567e bring fix from v2 2021-08-21 14:12:50 +02:00
NEZNAMY c950dc5f53 improve debug and fix sorting type name 2021-08-20 22:08:08 +02:00
NEZNAMY 5c6a29f2d7 colorize and use | instead of space for same priority 2021-08-20 22:07:33 +02:00
NEZNAMY 6e12a9d22e bring fix from v2 2021-08-20 16:51:13 +02:00
NEZNAMY df819853ef cache sorted players in layout 2021-08-20 10:56:12 +02:00
NEZNAMY d8c3fb4190 how did this get here 2021-08-20 09:55:28 +02:00
NEZNAMY 25e5ecfe61 disable belowname by default 2021-08-20 01:33:41 +02:00
NEZNAMY 809b5bbe18 cleaner check and return server version if hook failed 2021-08-19 14:54:48 +02:00
NEZNAMY 1ec9139307 remove one of 2 old methods 2021-08-18 23:13:21 +02:00
NEZNAMY 293ea1f6cf using strings instead of UsageType enum 2021-08-18 22:55:05 +02:00
NEZNAMY ed43a47ad7 added comment 2021-08-18 21:44:49 +02:00
NEZNAMY 82980639c8 drastically optimize unlimited nametags 2021-08-18 19:33:20 +02:00
NEZNAMY 01dd493475 fix inaccessible constructor 2021-08-17 20:39:33 +02:00
NEZNAMY 0b29c8c51b create and call method instead of copypasting 2021-08-17 19:35:34 +02:00
NEZNAMY 7c2f4277c3 small nms loading method changes 2021-08-17 19:31:03 +02:00
NEZNAMY 8c515f542c define all variables manually instead of using maps 2021-08-17 19:11:45 +02:00
NEZNAMY 73d80b136f fix NPE when disabled worlds/servers are not defined 2021-08-16 23:37:13 +02:00
NEZNAMY 93c5cf70a0 fix method name 2021-08-16 15:33:18 +02:00
NEZNAMY e2a098c3ff remove debug code 2021-08-16 15:32:13 +02:00
NEZNAMY c766048224 add fabric support via CardBoard 2021-08-16 13:45:06 +02:00
NEZNAMY 9eb87fae62 return methods by other parameters than name itself
let's see how many hotfixes will this require
2021-08-15 23:32:37 +02:00
NEZNAMY 7f2f4d8e3b easier way 2021-08-15 21:26:52 +02:00
NEZNAMY ce5f9c0f08 use existing field 2021-08-15 20:27:11 +02:00
NEZNAMY cf443ed217 create method instead of copypasting content 2021-08-15 20:25:17 +02:00
NEZNAMY bde582d8ff rename fields 2021-08-15 20:17:33 +02:00
NEZNAMY 0a00332580 implement /tab scoreboard show <name> [player] 2021-08-15 16:17:08 +02:00
NEZNAMY 137d7bf240 use scoreboard name in property names to avoid issues 2021-08-15 15:56:21 +02:00
NEZNAMY 302c7ef455 properly register and unregister lines when using via API 2021-08-15 15:50:34 +02:00
NEZNAMY 87b54a44c0 remove unused field 2021-08-15 15:29:52 +02:00
NEZNAMY f9eee0de93 improve tabcomplete 2021-08-15 15:18:22 +02:00
NEZNAMY 1114d2d30d register sorting placeholders for refreshing 2021-08-15 13:51:09 +02:00
NEZNAMY 65d50d046c mighty replace function 2021-08-14 12:03:57 +02:00
NEZNAMY b2ef957682 implement all data watcher registry values 2021-08-14 12:03:47 +02:00
NEZNAMY 56be23e304 specify placeholder in debug message 2021-08-14 00:03:27 +02:00
NEZNAMY 215869037b rename artifact 2021-08-13 23:54:28 +02:00
NEZNAMY f5d4581911 add and use custom packet classes for entity packets 2021-08-13 23:30:29 +02:00
NEZNAMY 5848efdf67 rename interface 2021-08-13 22:31:04 +02:00
NEZNAMY c79277afaf add &r after every sorting element 2021-08-13 21:59:42 +02:00
NEZNAMY 59c8e1ae1c increase access level 2021-08-12 20:10:21 +02:00
NEZNAMY d50678649a fix async event call 2021-08-12 15:28:32 +02:00
NEZNAMY c19f440094 add getter 2021-08-12 15:28:23 +02:00
NEZNAMY b60160f2b9 rename field 2021-08-12 13:33:37 +02:00
NEZNAMY e54c4ed435 use method reference instead 2021-08-12 13:32:47 +02:00
NEZNAMY 749774cd03 remove redundant throws 2021-08-12 13:31:13 +02:00
NEZNAMY 7cc609fdc3 remove wrong IF 2021-08-12 13:29:51 +02:00
NEZNAMY 2cc8bed203 apparently fix locale issue 2021-08-12 13:24:04 +02:00
NEZNAMY 175f02a1c3 fix forgotten change 2021-08-12 01:53:13 +02:00
NEZNAMY 8a8ac0ccde use default group name instead of null 2021-08-12 01:47:27 +02:00
NEZNAMY 168427f24e avoid code duplicates in pipeline injection 2021-08-12 01:13:36 +02:00
NEZNAMY 8338518405 armor stand API test 2021-08-12 00:49:24 +02:00
NEZNAMY 95783b7ff3 add, rename and repackage events 2021-08-12 00:14:34 +02:00
NEZNAMY f7a4f956d7 correctly update latency in global playerlist 2021-08-11 14:24:06 +02:00
NEZNAMY feea4d4785 not anymore 2021-08-11 13:00:42 +02:00
NEZNAMY e267623025 remove duplicated check 2021-08-11 12:59:57 +02:00
NEZNAMY 5c22583a52 correctly show arrays in output 2021-08-11 12:57:02 +02:00
NEZNAMY 7ba93c9742 rework scoreboard assign logic (simplify for users) 2021-08-11 12:53:05 +02:00
NEZNAMY b4b40bf82f remove unused parameter 2021-08-11 12:19:58 +02:00
NEZNAMY b96218f305 catch NoClassDefFoundError 2021-08-11 00:12:23 +02:00
NEZNAMY e4013a616f finish scoreboard line change API 2021-08-11 00:12:12 +02:00
NEZNAMY 6f3ab8f974 oops 2021-08-10 23:31:44 +02:00
NEZNAMY c47fc61b73 catch IllegalArgument 2021-08-10 23:27:09 +02:00
NEZNAMY 01042bbc54 api changes and stuff [buffering] 2021-08-10 20:53:55 +02:00
NEZNAMY e75f8b75c5 add catserver support 2021-08-09 00:10:15 +02:00
NEZNAMY ae5e77925a shorter code alternative 2021-08-08 23:33:26 +02:00
NEZNAMY b1f2a0e057 do not send bossbars if condition is not met 2021-08-08 22:13:38 +02:00
NEZNAMY 6f61d5aa11 drop direct per-world bossbar support (still doable with conditions) 2021-08-08 22:10:11 +02:00
NEZNAMY 9562f06fea remove warn 2021-08-08 21:49:17 +02:00
NEZNAMY c6eaf4ae03 do not show warning with default group 2021-08-08 20:47:19 +02:00
NEZNAMY 24c994dfb5 properly clone extra components 2021-08-07 19:16:55 +02:00
NEZNAMY f623e5d004 hexcode variable no longer uses # as prefix 2021-08-07 17:20:49 +02:00
NEZNAMY 9ac03a00d8 apply gradients in animations once instead of every refresh 2021-08-07 14:37:29 +02:00
NEZNAMY 52b819a1b7 use same feature name everywhere 2021-08-06 23:37:29 +02:00
NEZNAMY 3ad32e0fc7 iterating over arrays instead of lists where possible 2021-08-06 13:01:21 +02:00
NEZNAMY 18c4a55518 only initialize if used 2021-08-06 12:11:28 +02:00
NEZNAMY 0d8a889556 return if no rgb codes are used 2021-08-06 12:11:10 +02:00
NEZNAMY 25f180a297 change return type of nested placeholders to String[] 2021-08-06 12:01:29 +02:00
NEZNAMY ae2f2d8294 create string once instead of every refresh 2021-08-06 11:33:22 +02:00
NEZNAMY d3ac95d1f6 change return type of getOnlinePlayers to TabPlayer[] 2021-08-06 11:08:02 +02:00
NEZNAMY a138c4a1c7 significantly optimize PropertyImpl#update() method in specific cases 2021-08-06 01:31:57 +02:00
NEZNAMY 0f359e84d6 do not call parseFloat if not needed 2021-08-06 01:27:16 +02:00
NEZNAMY 49d73b7d4f simplify 2021-08-06 00:24:11 +02:00
NEZNAMY 33dc7b82ea do not warn about null group 2021-08-03 18:51:08 +02:00
NEZNAMY 4714ea6037 add back required checks until thread management code 2021-08-03 18:45:24 +02:00
NEZNAMY c2e5f241b0 give thread pool a custom name 2021-08-03 17:49:18 +02:00
NEZNAMY 7f0e299b74 getting my try/catch back 2021-08-03 17:06:43 +02:00
NEZNAMY e418ccf8e0 using StringBuilder 2021-08-03 16:54:32 +02:00
NEZNAMY 53e119c0ce only create a single instance of nms Scoreboard 2021-08-03 15:54:02 +02:00
NEZNAMY f934d3b7b1 display placeholderapi errors when debug is enabled 2021-08-03 15:53:21 +02:00
NEZNAMY 12d5b9f6f6 fix papi placeholder error causing last value to not apply 2021-08-03 14:05:48 +02:00
NEZNAMY 727a5cfbf5 remove unnecessary casts and calls 2021-08-03 13:40:26 +02:00
NEZNAMY 6345080769 initialize server placeholders on load and move task 2021-08-03 13:34:56 +02:00
NEZNAMY 928f3d32cd fix sorting by predefined placeholder 2021-08-03 13:08:35 +02:00
NEZNAMY 81fd2dc82f do not mass allocate memory (might break addon loading) 2021-08-03 01:50:37 +02:00
NEZNAMY 225918ac52 how did this even happen 2021-08-03 01:39:40 +02:00
NEZNAMY 796343bc5e cleanup and remove duplicated code 2021-08-03 01:39:00 +02:00
NEZNAMY cdb86f6c11 fix placeholder registration in anonymous conditions 2021-08-03 01:38:34 +02:00
NEZNAMY 625e26f01f change placeholder type to fix nested player placeholders 2021-08-03 01:05:54 +02:00
NEZNAMY 21f0429fd6 return type changes 2021-08-03 01:01:57 +02:00
NEZNAMY e7a30048cf replace Map with byte[] for better performance and memory 2021-08-02 23:04:44 +02:00
NEZNAMY ed952e19eb hopefully small optimizations with stringbuilder 2021-08-02 22:19:41 +02:00
NEZNAMY e4a7bdd0eb disable by default 2021-08-02 22:16:40 +02:00
NEZNAMY 13e394bbfe use arrays instead of lists 2021-08-02 21:40:05 +02:00
NEZNAMY a6b95064d9 optimize method's memory allocation 2021-08-02 21:33:17 +02:00
NEZNAMY c30a556bdc obviously update method names 2021-08-02 20:44:17 +02:00
NEZNAMY 2bebba740e fix NPE when player is not loaded 2021-08-02 20:26:33 +02:00
NEZNAMY 57dfb02689 fix false negative when nested placeholder changed value
also nested placeholders in conditions not being registered
2021-08-02 00:01:37 +02:00
NEZNAMY 7931d8b26e reformat 2021-08-01 14:50:43 +02:00
NEZNAMY 434d50b2d1 add skin support to layout 2021-08-01 14:44:05 +02:00
NEZNAMY fad905a426 simplify method 2021-08-01 01:01:55 +02:00
NEZNAMY 475c3b690b fix NPE when skin is null 2021-08-01 00:53:42 +02:00
NEZNAMY 88eae3cb9a fix NPE when placeholder returns null 2021-08-01 00:49:04 +02:00
NEZNAMY 0021c7233c fix placeholders used only in conditions not refreshing 2021-07-31 20:11:46 +02:00
NEZNAMY 725224b6c7 move method 2021-07-31 16:44:22 +02:00
NEZNAMY 28f399079d remove redundant check 2021-07-31 16:33:50 +02:00
NEZNAMY 3e0d594e29 remove unused code 2021-07-31 16:33:08 +02:00
NEZNAMY 9092b1f9b0 remove unused method 2021-07-31 16:21:10 +02:00
NEZNAMY 4ac30ff7b2 remove animation file conversion 2021-07-31 16:20:27 +02:00
NEZNAMY 803d3395d6 split method 2021-07-31 16:11:10 +02:00
NEZNAMY 51288231cd add displayname refreshing & aligned suffix support in layout 2021-07-31 15:25:09 +02:00
NEZNAMY a44cd528ef better YellowNumber integration with layout 2021-07-31 15:13:09 +02:00
NEZNAMY cfbe0b031e add way to not duplicate properties in layout 2021-07-31 14:57:34 +02:00
NEZNAMY bf7fb1620e use function that doesn't throw patern exception 2021-07-31 14:41:22 +02:00
NEZNAMY 50056fd301 implement backwards hoverable conversion 2021-07-30 22:23:15 +02:00
NEZNAMY 927b134996 move class to correct package 2021-07-29 23:35:40 +02:00
NEZNAMY 9d66619cda removed unnecessary cast 2021-07-29 23:25:39 +02:00
NEZNAMY c9670536cc fix conditions loading 2021-07-29 23:21:30 +02:00
NEZNAMY 731518a4fc implement chat hoverable conversion 2021-07-29 22:54:18 +02:00
NEZNAMY 764df316a7 fix startup 2021-07-29 16:29:13 +02:00
NEZNAMY 1ecfdafbe8 small fixes 2021-07-29 16:20:05 +02:00
NEZNAMY 4b09aeefd6 . 2021-07-29 16:11:09 +02:00
NEZNAMY 71e407c3a5 split IChatBaseComponent class 2021-07-29 15:14:30 +02:00
NEZNAMY 48c4e7432d . 2021-07-29 12:33:37 +02:00
NEZNAMY 202194c16f fix github compilation 2021-07-28 23:54:08 +02:00
NEZNAMY 0af5713483 more stuff 2021-07-28 23:51:08 +02:00
NEZNAMY 3b6a5c353c massively reduced memory allocations 2021-07-27 23:42:04 +02:00
NEZNAMY e6d8f34db0 more random things for code analysis websites 2021-07-26 16:42:50 +02:00
NEZNAMY ef97a0d184 . 2021-07-26 16:04:17 +02:00
NEZNAMY 40866754d1 . 2021-07-26 15:01:29 +02:00
NEZNAMY d5fb7d094c more random changes 2021-07-26 14:35:47 +02:00
NEZNAMY 48b861054c temporarily disable code 2021-07-26 13:07:04 +02:00
NEZNAMY 568b7541a4 random stuff 2021-07-26 13:05:19 +02:00
NEZNAMY 914a6e6a57 Update build.yml 2021-07-26 11:58:26 +02:00
NEZNAMY d1e737dc96 Update plugin.yml 2021-07-26 11:51:16 +02:00
NEZNAMY ae68a05f87 cpu boost and rip child groups 2021-07-26 02:11:27 +02:00
NEZNAMY 79e6f3ef1c further progress 2021-07-25 17:31:56 +02:00
NEZNAMY 5f137f4055 more api stuff 2021-07-24 23:31:14 +02:00
NEZNAMY 4f5215a312 more recoding and per-world support on bungee 2021-07-23 23:51:38 +02:00
NEZNAMY 06ea8f6cb1 initial mysql support 2021-07-15 21:54:03 +02:00
NEZNAMY 2e2890d8d3 config recode and more 2021-07-13 01:11:25 +02:00
NEZNAMY a07ef6c273 API & feature recode part 1 2021-07-12 00:11:01 +02:00
NEZNAMY a02acc9c67 remove file 2021-07-11 15:55:28 +02:00
NEZNAMY bc5e61b04b make conditional placeholders refresh intervals configurable 2021-07-11 15:43:41 +02:00
NEZNAMY 665036189d always show sync placeholders red 2021-07-11 15:34:36 +02:00
NEZNAMY 8fe72e7f2e remove cputest subcommand 2021-07-11 15:21:36 +02:00
NEZNAMY 4a373015de send different message when reload fails due to internal error 2021-07-11 15:17:56 +02:00
NEZNAMY 31ad540286 do not allow same bossbar announced multiple times at once 2021-07-11 15:07:01 +02:00
NEZNAMY 448faebfad ignore players who are not loaded
will fix double bossbar bug
2021-07-11 15:02:22 +02:00
NEZNAMY 3b7f25071e remove spigot link 2021-07-11 00:46:51 +02:00
NEZNAMY c661395bb0 Update README.md 2021-07-10 13:25:11 +02:00
NEZNAMY c231220b42 2.9.2 2021-07-10 13:01:29 +02:00
NEZNAMY 1c6e5bec73 fix IllegalArgument 2021-07-10 12:57:16 +02:00
NEZNAMY 8919aaad94 add missing config option 2021-07-09 16:42:10 +02:00
NEZNAMY ff6a2fe734 equals 2021-07-09 11:58:18 +02:00
NEZNAMY 5ca4f7e411 2.9.2-pre3 2021-07-07 17:13:01 +02:00
NEZNAMY 2c105718b0 1.17.1 support 2021-07-07 17:10:37 +02:00
NEZNAMY 9cc471f66f catch throwable in pipeline 2021-07-06 21:20:47 +02:00
NEZNAMY e18867c938 do not ignore Errors 2021-07-06 21:01:46 +02:00
NEZNAMY 27bd942c4c fix NoSuchFieldError on <1.11 2021-07-06 21:01:36 +02:00
NEZNAMY 234ca72e73 tab out stack traces 2021-07-06 21:01:17 +02:00
NEZNAMY f35a09a34d avoid rare NPE 2021-07-06 19:54:19 +02:00
NEZNAMY fa6d06a4ac 2.9.2-pre2 2021-07-06 09:50:48 +02:00
NEZNAMY ec6daeeadb colorize text immediately instead of in every refresh 2021-07-04 13:50:05 +02:00
NEZNAMY f24f25f071 apparently this method is required 2021-07-04 12:05:10 +02:00
NEZNAMY dbf0e3af9f small cpu and memory optimization in pet fix feature 2021-07-04 00:02:56 +02:00
NEZNAMY 6ecb607c0b add private constructor 2021-07-03 20:48:18 +02:00
NEZNAMY 1bf6b00be0 remove unnecessary code 2021-07-03 20:47:56 +02:00
NEZNAMY 4b4f52e39a use constants instead of literal strings 2021-07-03 20:35:50 +02:00
NEZNAMY 1170efbe02 cache disabled worlds 2021-07-03 19:52:42 +02:00
NEZNAMY 3e86e73fed refactor to avoid duplication 2021-07-03 16:51:49 +02:00
NEZNAMY dd43861572 cache methods for placeholders (mostly %afk%) 2021-07-03 16:32:37 +02:00
NEZNAMY 61a19ca9e0 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-07-03 16:19:20 +02:00
NEZNAMY d02af31e7c Merge pull request #342 from etil2jz/patch-1
Update README.md
2021-07-03 16:16:38 +02:00
Arthur B ab7b88b67b Update README.md
Correct isPremium line
2021-07-03 16:13:52 +02:00
NEZNAMY b80c816c5a relocate json-simple 2021-07-01 18:56:51 +02:00
NEZNAMY c0ad6f49e7 minor changes 2021-07-01 18:53:24 +02:00
NEZNAMY 91a56a8c2c remove IllegalArgument throws forwarding 2021-07-01 12:09:09 +02:00
NEZNAMY 135a473dc5 more abstraction to remove duplications 2021-07-01 11:14:41 +02:00
NEZNAMY a8b53b07e4 increase delay and repeat times 2021-07-01 10:04:19 +02:00
NEZNAMY 171cbd4497 NPE fix when plugin is disabled and user does not have reload permission 2021-06-30 21:24:27 +02:00
NEZNAMY a1383612bc making code analysis websites happy part 6
+ switching to bukkit metrics shading instead of copying classes
2021-06-30 18:03:21 +02:00
NEZNAMY fe798c19f3 making code analysis websites happy part 5 2021-06-30 13:32:15 +02:00
NEZNAMY ead3add4cc making code analysis websites happy part 4 2021-06-30 11:54:14 +02:00
NEZNAMY db13c2d1c5 making code analysis websites happy part 3 2021-06-30 10:58:39 +02:00
NEZNAMY f2daab4b80 making code analysis websites happy part 2 2021-06-30 00:55:26 +02:00
NEZNAMY 6fd02c83ab attempt 2 2021-06-30 00:02:02 +02:00
NEZNAMY c288a0503a test 2021-06-29 23:54:12 +02:00
NEZNAMY 2e2b65a4bb making code analysis websites happy part 1 2021-06-29 23:48:23 +02:00
NEZNAMY 982d0a53f9 correctly set bossbar progress on add 2021-06-29 19:01:46 +02:00
NEZNAMY f89ecfb595 remove unused options 2021-06-29 14:10:42 +02:00
NEZNAMY bddb96a5fa increase default refresh 2021-06-29 14:05:57 +02:00
NEZNAMY 39b29d12e4 problem solved ez game ez life
referring to expansion download errors while jar file was modified such as https://paste.gg/p/anonymous/449c3eb326f34015993b4025002be355
2021-06-29 13:59:47 +02:00
NEZNAMY 6cb1e2c06d debug option is now public 2021-06-29 13:49:46 +02:00
NEZNAMY d932a9a862 add VV as softdepend to avoid troll console message 2021-06-29 13:29:19 +02:00
NEZNAMY 341b552d0b 2.9.2-pre1 2021-06-25 08:25:25 +02:00
NEZNAMY 1586bd9768 implement correct interface 2021-06-24 21:55:06 +02:00
NEZNAMY e8dde3a756 reuse the same instance 2021-06-24 21:51:37 +02:00
NEZNAMY bb591bf56d spigot fixed the bug 2021-06-24 20:18:07 +02:00
NEZNAMY 8cf83b276a fix the feature on 1.17 2021-06-23 21:59:24 +02:00
NEZNAMY a1547a7288 cleaner implementation of #322 2021-06-23 21:56:10 +02:00
NEZNAMY 0722403a23 remove duplicated line 2021-06-22 21:27:59 +02:00
NEZNAMY cd4a91d975 return afk if at least 1 plugin says player is afk 2021-06-22 20:42:26 +02:00
NEZNAMY c7870b4e9d fix NPE in API when feature is not enabled 2021-06-21 22:52:59 +02:00
NEZNAMY 239dae5a65 change reference type to player name 2021-06-21 22:43:47 +02:00
NEZNAMY 13c89d18d7 remove unused field since 1.17 support 2021-06-21 21:47:18 +02:00
NEZNAMY c5dc42eafe cleanup 2021-06-21 14:47:56 +02:00
NEZNAMY 59b3faab1e fix team name note message in console 2021-06-21 13:41:15 +02:00
NEZNAMY b88beb5002 added null check to placeholder registration 2021-06-21 12:58:46 +02:00
NEZNAMY 9fea35c25d retry viaversion call if it returned -1 2021-06-21 12:03:33 +02:00
NEZNAMY 372013bcc6 add online status into debug message 2021-06-21 11:07:21 +02:00
NEZNAMY 20ca58b570 fix NPE 2021-06-20 21:49:48 +02:00
NEZNAMY 9c4cca20fb just an attempt 2021-06-19 11:43:40 +02:00
NEZNAMY 6b8536a86e fix possible memory leak? 2021-06-19 11:41:46 +02:00
NEZNAMY 3b41857637 fixed NPE caused by misconfiguration 2021-06-19 09:27:33 +02:00
NEZNAMY fa78ac2157 fix it again? 2021-06-18 13:39:05 +02:00
NEZNAMY 0a0bb9c83c swap order to avoid NPE when player is not loaded 2021-06-18 12:28:19 +02:00
NEZNAMY 36834a039e 2.9.1 2021-06-17 18:43:34 +02:00
NEZNAMY 4960c898bb memory leak? 2021-06-17 18:35:35 +02:00
NEZNAMY af61edbc5c added replacements support to relational placeholders 2021-06-17 15:53:24 +02:00
NEZNAMY 237bfc08a1 forward raw packets instead, no idea why was it not working 2021-06-17 15:52:39 +02:00
NEZNAMY 032e9a089d bump supported versions 2021-06-17 12:50:37 +02:00
NEZNAMY ba83779dde create and use new field getter method 2021-06-16 21:51:51 +02:00
NEZNAMY 267d72f844 spacing 2021-06-16 21:38:24 +02:00
NEZNAMY b533cdb89f send deserialized packets instead of malformed bytebufs 2021-06-16 17:26:05 +02:00
NEZNAMY 3f118ac76b add option to define custom character widths 2021-06-16 16:24:08 +02:00
NEZNAMY 08a8f0097c fix wrong constructor taken on random 1.8.8 forks 2021-06-16 16:23:26 +02:00
NEZNAMY c7a3599e46 update maven repository 2021-06-16 14:22:45 +02:00
NEZNAMY 62f80baa69 version bump 2021-06-16 14:01:31 +02:00
NEZNAMY 09dc8cd437 version bump 2021-06-16 13:52:27 +02:00
NEZNAMY c613ba401b remove unnecessary this. 2021-06-16 13:03:52 +02:00
NEZNAMY 866df0b5cf remove duplicate content 2021-06-16 11:12:43 +02:00
NEZNAMY 8f2b56ba05 2.9.0 2021-06-16 10:09:20 +02:00
NEZNAMY 2049885f11 more accurate error message 2021-06-16 09:56:15 +02:00
NEZNAMY 4caef337d5 ANOTHER BOSSBAR API BUG IN ANOTHER PLATFORM HAHA LOL 2021-06-15 23:37:02 +02:00
NEZNAMY a644792bf6 simplify 2021-06-15 22:50:16 +02:00
NEZNAMY 54c7f8fc6a drop the rest of title packet 2021-06-15 22:49:23 +02:00
NEZNAMY 2e59b87bbe use getters instead of fields 2021-06-15 22:46:42 +02:00
NEZNAMY f89242ad8f add and use magic code Boolean getters 2021-06-15 22:40:02 +02:00
NEZNAMY 845903788c remove unused code 2021-06-15 22:39:32 +02:00
NEZNAMY 53a9047c20 fix conflict between hidden-by-default and remember-toggle-choice 2021-06-15 22:36:55 +02:00
NEZNAMY a2b74bbc30 correctly display used color codes in parse error messages 2021-06-15 22:36:31 +02:00
NEZNAMY 50ef93cc45 fix stack overflow and stretch with relational placeholders 2021-06-15 22:36:00 +02:00
NEZNAMY e2a5da9c14 deserialize other scoreboard packets as well 2021-06-15 22:35:24 +02:00
NEZNAMY bf31116d0d split method 2021-06-15 22:34:42 +02:00
NEZNAMY d79fa8c4f3 drop title packet 2021-06-15 22:34:31 +02:00
NEZNAMY 87e0a7bea3 remove unused fields 2021-06-15 22:33:33 +02:00
NEZNAMY b34cabd55c optimize check 2021-06-15 22:32:50 +02:00
NEZNAMY 704bd36c77 do not try to use rgb on <1.16 servers 2021-06-14 09:35:23 +02:00
NEZNAMY 5c2c4d0f4b improved error message 2021-06-14 08:43:36 +02:00
NEZNAMY 80cca5cb34 fix #329 2021-06-14 08:22:37 +02:00
NEZNAMY dcd603f2f5 null check to prevent errors 2021-06-13 22:10:30 +02:00
NEZNAMY 1bee3b49bf sending bossbar using bukkit api 2021-06-13 20:46:16 +02:00
NEZNAMY 11bcccb8f9 fix reload from previous commit 2021-06-13 20:24:39 +02:00
NEZNAMY 7425493706 initialization cleanup 2021-06-13 19:09:34 +02:00
NEZNAMY dca0cfd424 removed old value from config 2021-06-13 17:09:03 +02:00
NEZNAMY 21314def89 fix #328 2021-06-13 15:57:06 +02:00
NEZNAMY 90e544d279 option to take groups from backend servers 2021-06-13 11:54:03 +02:00
NEZNAMY 89e21558a1 2.8.11-pre19 2021-06-12 23:23:15 +02:00
NEZNAMY b28cc51457 spigot one dot god damn seventeen 2021-06-12 23:19:09 +02:00
NEZNAMY 2d0a203b5f increased initial delay 2021-06-12 14:28:44 +02:00
NEZNAMY 2948666c1d 2.8.11-pre18 2021-06-11 19:14:47 +02:00
NEZNAMY b2a2659546 added little comment 2021-06-11 17:14:03 +02:00
NEZNAMY e2eb7102c9 removed unnecessary 'throws' from methods 2021-06-10 21:22:15 +02:00
NEZNAMY 56301e653b splitting method into multiple 2021-06-10 21:13:40 +02:00
NEZNAMY 1d825e08d2 using correct uuid all the time 2021-06-10 19:38:46 +02:00
NEZNAMY c81a27709c 1.17 bungeecord 2021-06-10 17:22:58 +02:00
NEZNAMY 2b143172f8 spacing 2021-06-10 17:19:55 +02:00
NEZNAMY 84330ec6eb Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-06-10 17:19:25 +02:00
NEZNAMY 0bd703de7f Merge pull request #325 from Camotoy/viaversion4.0.0
Update to ViaVersion 4.0.0
2021-06-10 17:17:55 +02:00
Camotoy e6a55b7d5c Change packet ID if using 1.17 2021-06-10 11:13:45 -04:00
Camotoy b6ec7631d2 Update to ViaVersion 4.0.0
Tested on 1.17 and the bossbar showed up with no error in console.
2021-06-10 10:53:36 -04:00
NEZNAMY 5abbd00d63 fixed unloading when entering disabled world 2021-06-10 11:22:07 +02:00
NEZNAMY 515c94976e removed internal methods from TabPlayer API interface 2021-06-09 21:06:01 +02:00
NEZNAMY 912adad8f6 player 2021-06-09 20:08:36 +02:00
NEZNAMY 70fdd193a3 Merge branch 'master' of https://github.com/NEZNAMY/TAB 2021-06-09 19:43:08 +02:00
NEZNAMY 9d83e968fc Merge pull request #323 from Score2/bukkit-permission
Support to obtain bukkit permissions from bungee.
2021-06-09 19:42:35 +02:00
83669 04329da133 resolve. 2021-06-10 01:41:32 +08:00
83669 19ccfbb1a6 Merge branch 'master' of https://github.com/NEZNAMY/TAB into bukkit-permission
 Conflicts:
	velocity-1.1.0/src/main/resources/velocityconfig.yml
2021-06-10 01:29:02 +08:00
83669 c53ab09abc Support to obtain bukkit permissions from bungee. 2021-06-10 01:24:23 +08:00
NEZNAMY a4d8daac1d fixed wrong logic causing name formatting to not work 2021-06-09 16:12:33 +02:00
NEZNAMY 99d566d521 wrong action order 2021-06-09 16:05:08 +02:00
NEZNAMY aa37f73161 fixed wrong config option name 2021-06-09 15:54:12 +02:00
NEZNAMY 087518378d pom.xml cleanup 2021-06-09 15:39:57 +02:00
NEZNAMY 913d27929b shortcut and no longer requiring guava 2021-06-09 15:24:04 +02:00
NEZNAMY 530d39bec5 added property name into exception message 2021-06-09 10:47:42 +02:00
NEZNAMY cf70dc3845 fixed priorities (caused <= and >= to not work) 2021-06-08 23:17:31 +02:00
NEZNAMY d1421fee3f new colors 2021-06-08 21:58:18 +02:00
NEZNAMY 3ec490b36e only the the API now 2021-06-08 09:58:46 +02:00
NEZNAMY ee42685179 Added API to disable team handling of a player 2021-06-07 13:31:44 +02:00
NEZNAMY e02d687771 PingSpoof and SpectatorFix now properly load/unload 2021-06-06 14:55:47 +02:00
NEZNAMY dddb592253 update to default config comments 2021-06-05 20:22:20 +02:00
NEZNAMY d0ad88d317 fixed potential security issue when player is not loaded due to an error 2021-06-05 20:20:02 +02:00
NEZNAMY 3d3ce0151f added gamemode getter to TabPlayer 2021-06-05 19:56:37 +02:00
NEZNAMY f017b0e562 %canseeonline% now uses vanish detection from previous commits instead of PV API on bungeecord 2021-06-05 19:47:03 +02:00
NEZNAMY 4ba2bb669b added back 1.5 and 1.6 support 2021-06-05 16:26:32 +02:00
NEZNAMY 9fc2424736 Create FUNDING.yml 2021-06-03 16:55:26 +02:00
NEZNAMY 980c01ea70 this never happened 2021-06-01 13:25:01 +02:00
NEZNAMY 758edcaf5c fixed NPE in API usage 2021-05-30 20:48:49 +02:00
NEZNAMY 950f825e31 added unnecessary softdependency due to md5's troll console message 2021-05-30 20:47:48 +02:00
NEZNAMY 0a985f5c78 using method from component to save color codes due to limits 2021-05-28 11:43:17 +02:00
NEZNAMY 58353f4e6d wrong variable 2021-05-28 11:41:22 +02:00
NEZNAMY c3d2b5c4b0 fixed error in initialization 2021-05-28 11:19:45 +02:00
NEZNAMY c2764b4b8a removed redundant ; 2021-05-28 11:19:31 +02:00
NEZNAMY 9bc8ad0d23 typo 2021-05-28 09:47:02 +02:00
NEZNAMY 488c3540a8 using more reliable check 2021-05-27 19:58:17 +02:00
NEZNAMY 1d03950a64 removed technically useless check 2021-05-27 19:51:21 +02:00
NEZNAMY e24ea7df2e added null check, continuation of previous commit 2021-05-27 18:06:09 +02:00
NEZNAMY fe5e3d6405 better compatibility with forks that use "Unknown" server version
by using a minor version check which is more reliable
2021-05-27 16:20:08 +02:00
NEZNAMY db8584e40b correctly translating colors 2021-05-27 16:18:43 +02:00
NEZNAMY 2e4db38d1a properly compensating for the bug on all horse types 2021-05-25 14:31:44 +02:00
NEZNAMY f82470c1b1 2.8.11-pre17 2021-05-24 22:37:10 +02:00
NEZNAMY 650cc93fc0 fixed placeholders not refreshing when updating properties with API 2021-05-24 22:35:02 +02:00
NEZNAMY e61070307a fixed rare NPE 2021-05-23 23:27:56 +02:00
NEZNAMY 2fa46867e5 moved repeating task to separate method 2021-05-23 18:51:39 +02:00
NEZNAMY 636b2e760a fixed wrong check 2021-05-23 18:46:10 +02:00
NEZNAMY 8cecf46310 NPE fix 2021-05-23 00:38:16 +02:00
NEZNAMY a7bcda7eba fixed NPEs when running commands from console 2021-05-22 20:48:09 +02:00
NEZNAMY a610dd2c70 cleanup 2021-05-22 16:49:30 +02:00
NEZNAMY df98c77a48 java 8 shortcut 2021-05-22 16:48:01 +02:00
NEZNAMY 331dc33c86 removed redundant method 2021-05-22 16:46:56 +02:00
NEZNAMY 8493b37171 recoded feature to fix issues, worked 2021-05-22 16:41:56 +02:00
NEZNAMY 2449c46165 using default locale
https://support-system.xyz/redirect?link=https://cdn.discordapp.com/attachments/690574378454483034/845273706287988807/ticket-844852135032127489.html
2021-05-21 14:16:55 +02:00
NEZNAMY a642c2d344 moved code to new method to avoid duplication 2021-05-20 16:59:48 +02:00
NEZNAMY 88c7b988e7 not displaying the error message anymore 2021-05-19 20:40:07 +02:00
NEZNAMY 36651260c6 added debug messages 2021-05-19 18:10:54 +02:00
NEZNAMY 6c0072dc54 using new method (also supports essentials vanish now) 2021-05-18 21:12:54 +02:00
NEZNAMY e38f5a77c0 added support for bukkit vanish plugins into global playerlist via bridge 2021-05-18 21:11:41 +02:00
NEZNAMY 6443926a79 added a reminder since even I forgot 2021-05-18 19:55:36 +02:00
NEZNAMY 489deb9ee6 2.8.11-pre16 2021-05-16 22:06:22 +02:00
NEZNAMY a2039110e0 improved compatibility with vanish plugins 2021-05-16 22:01:25 +02:00
NEZNAMY f1666b64ee moved shared module to top to avoid compilation error on first compilation 2021-05-16 21:11:45 +02:00
NEZNAMY d7e419c88b added getters to bossbar interface 2021-05-16 21:10:01 +02:00
NEZNAMY de8f8053be recalculating more often, seems to have fixed the issue 2021-05-16 20:56:15 +02:00
NEZNAMY 7aadef5c21 resending packet with a delay when anti-override is disabled 2021-05-16 20:55:26 +02:00
NEZNAMY f8384dfbdf removed character ID from widths for lower file size & counting them internally while loading 2021-05-16 20:52:38 +02:00
NEZNAMY b91cbf827c removed redundant check 2021-05-16 20:51:46 +02:00
NEZNAMY 096619d9f7 moved teleport event back to packets to avoid various issues 2021-05-16 13:00:28 +02:00
NEZNAMY 7b8006406c should fix rare issue caused by multi-thread access 2021-05-16 12:58:48 +02:00
NEZNAMY 90483d549a removed width command & loading since the file is now complete 2021-05-15 21:26:16 +02:00
NEZNAMY 5473055c1c found a way to measure & added arabic characters 2021-05-15 21:23:41 +02:00
NEZNAMY f3b082b8e1 removed unnecessary cast 2021-05-15 19:57:04 +02:00
NEZNAMY 52fe99a080 fixed stack overflow on sync placeholders 2021-05-15 13:33:57 +02:00
NEZNAMY 68b1e941d1 correctly formatting tablist name in packets sent on world change 2021-05-13 18:51:15 +02:00
NEZNAMY 109fce9b1a updated line number reference 2021-05-13 18:50:45 +02:00
NEZNAMY 014d73dd3f ignoring info packet on <1.8 clients so nametag feature can display prefixes 2021-05-13 18:50:08 +02:00
NEZNAMY ad82744e91 added configuration simplification console message 2021-05-09 16:12:41 +02:00
NEZNAMY 638f66ade4 added catch for ArrayIndexOutOfBoundsException 2021-05-09 16:11:22 +02:00
NEZNAMY c190efa7c4 removed config conversion
users had enough time to update to 2.8.10 which converts everything, only keeping 2.8.10 ->2.9.0 changes
2021-05-09 12:35:17 +02:00
NEZNAMY b071eb3366 added purpur afk api support for %afk% 2021-05-08 18:03:57 +02:00
NEZNAMY a7c7a86a90 removed feature interface not used by the main plugin 2021-05-08 17:18:57 +02:00
NEZNAMY 0c21519cf6 listening to respawn event directly in features instead of globally and being unused for most servers 2021-05-08 00:45:33 +02:00
NEZNAMY d7f805b26e goodbye 2021-05-07 21:14:11 +02:00
NEZNAMY 4f702feab3 random feature request in my private messages 2021-05-07 20:24:52 +02:00
NEZNAMY 46175ceb1f fixed error on that platform made by a group of friendly and amazing people 2021-05-07 20:24:07 +02:00
NEZNAMY c206860736 removed redundant code 2021-05-02 22:20:09 +02:00
NEZNAMY b97c222490 remove modify-npc-names config option
all NPC plugins offer configuration of NPC names, modification can be performed by competent server owners there instead
2021-05-02 17:32:38 +02:00
NEZNAMY 53ad5e3cec added debug messages 2021-05-02 13:15:04 +02:00
NEZNAMY e67ce8dbf4 possible issue fix 2021-05-01 23:39:58 +02:00
NEZNAMY ac661be5c4 manually adding yes/no keys to replacements to compensate for snakeyaml conversion 2021-05-01 22:23:26 +02:00
NEZNAMY ab4e386491 small visual code update, functionality remains same 2021-05-01 22:11:32 +02:00
NEZNAMY aa125b535e Update README.md 2021-05-01 00:49:46 +02:00
NEZNAMY 29df3bb5e2 version bump 2021-04-30 15:36:14 +02:00
NEZNAMY 80ee30a532 map must be linked, found a way to do both synchronized and linked 2021-04-28 20:47:08 +02:00
NEZNAMY a20b1bcd89 added hidden config option to disable pipeline injection 2021-04-28 10:33:39 +02:00
NEZNAMY 4269abd2ca 2.8.11-pre15 2021-04-27 20:51:35 +02:00
NEZNAMY a73397065c added fix for rare NPE due to multi-thread access 2021-04-27 20:47:58 +02:00
NEZNAMY 5805a6c5a3 fixed rare concurrent modification 2021-04-27 17:43:30 +02:00
NEZNAMY e813077c92 check is no longer in constructor, must be added elsewhere 2021-04-27 17:38:27 +02:00
NEZNAMY b1ae68e8c2 not spamming class initializations and getting field values directly 2021-04-26 14:45:52 +02:00
NEZNAMY b6162b2d4a not refreshing header/footer on world switch if values did not change 2021-04-26 14:07:45 +02:00
NEZNAMY 0da7854f7f using concurrent hashmap to not need to copy value collection each time it's iterated 2021-04-26 14:00:41 +02:00
NEZNAMY a073747e66 added comment 2021-04-26 13:25:00 +02:00
NEZNAMY 0975e31371 better instance check 2021-04-26 13:23:25 +02:00
NEZNAMY a1231f1708 anti-override was removed already 2021-04-26 09:14:41 +02:00
NEZNAMY 3581da0fe7 only running toString once instead of every loop 2021-04-26 08:43:51 +02:00
NEZNAMY 531810e633 remake using switch 2021-04-25 13:53:16 +02:00
NEZNAMY 36a1db78e2 separate method to reduce complexity 2021-04-25 13:50:50 +02:00
NEZNAMY 0e58009ced starting tasks in separate methods 2021-04-25 13:48:18 +02:00
NEZNAMY ecdcc6894b fixed wrong cpu calculation 2021-04-25 00:16:19 +02:00
NEZNAMY 677a2f9396 reduced memory allocations 2021-04-25 00:14:53 +02:00
NEZNAMY b14f30d4d1 using isInstance instead of equals for better performance 2021-04-23 20:30:17 +02:00
NEZNAMY 4396df55ae updated dependency 2021-04-22 22:07:00 +02:00
NEZNAMY de6ce93a31 partially reverted pre6 recode + fixed disabled worlds not working
also deleted SneakEventListener class and replaced it with direct event lisener
2021-04-22 16:31:01 +02:00
NEZNAMY b449b7cdfc fixed errors on <1.16 2021-04-22 14:52:15 +02:00
NEZNAMY de4412fcff 2.8.11-pre14 2021-04-21 18:02:09 +02:00
NEZNAMY 8e9b34125d added placeholder value printing into team name note in debug 2021-04-21 17:45:57 +02:00
NEZNAMY 024b3175fa updated link 2021-04-20 19:48:33 +02:00
NEZNAMY 9fadc6df3b removed links 2021-04-20 19:47:48 +02:00
NEZNAMY f51f8f0f2d updated info 2021-04-20 15:51:48 +02:00
NEZNAMY d805df4887 no longer required 2021-04-20 15:50:41 +02:00
NEZNAMY d161c6c074 no need for reflection since jar is manual
also fixed title packet
2021-04-20 15:40:24 +02:00
NEZNAMY 6603c9e682 removed redundant file 2021-04-20 15:23:58 +02:00
NEZNAMY 157360c26c added dependency exclusions 2021-04-20 14:11:03 +02:00
NEZNAMY e16199b360 defined encoding to avoid warn in compilation 2021-04-20 11:58:13 +02:00
NEZNAMY df42424970 more cleanup 2021-04-20 11:42:30 +02:00
NEZNAMY 22ce6ce75e more cleanup 2021-04-20 11:36:55 +02:00
NEZNAMY e8dde142d2 another savestate before I break something 2021-04-20 11:25:05 +02:00
NEZNAMY 44fe272ce5 making another savestate of a working project 2021-04-20 11:23:41 +02:00
NEZNAMY 23a8f32910 pom.xml cleanup and resource fix 2021-04-20 11:12:04 +02:00
NEZNAMY d523c0408e Merge pull request #300 from A248/fix-modularization
Fix modularization
2021-04-20 01:51:37 +02:00
A248 0c2edba316 Add all resources and delete target folders 2021-04-19 19:49:47 -04:00
A248 7cfc643522 Add more to .gitignore 2021-04-19 19:42:32 -04:00
A248 98b446efd2 Shade all the modules into single jar + Fix filename of velocity 2
Changed velocity/2.0.0/libs/Velocity 2.0.0jar to Velocity-2.0.0.jar
2021-04-19 19:40:24 -04:00
NEZNAMY bbf9aaed64 initial modulatization 2021-04-20 01:11:57 +02:00
NEZNAMY 13d36457af repackage 2021-04-19 15:12:39 +02:00
NEZNAMY 4f850b0f2e it's shutdown 2021-04-18 21:45:42 +02:00
NEZNAMY 7118e0d9d3 fixed magic code error in gradients due to recent gradient apply changes 2021-04-18 20:59:35 +02:00
NEZNAMY 900edef407 fixed NPE when player is not loaded 2021-04-18 15:13:33 +02:00
NEZNAMY a7e4b99ce6 2.8.11-pre13 2021-04-18 12:27:12 +02:00
NEZNAMY 0463667270 Update README.md 2021-04-16 21:03:23 +02:00
NEZNAMY d179bc20ae now with link 2021-04-16 20:07:31 +02:00
NEZNAMY bc658a9223 Update README.md 2021-04-16 20:03:30 +02:00
NEZNAMY e32e3baf3a added anti-smartass message 2021-04-16 14:52:57 +02:00
NEZNAMY 4436f4cf42 new sorting type 2021-04-15 01:28:15 +02:00
NEZNAMY 1dc7b40ee9 found a workaround, works fine 2021-04-15 00:36:34 +02:00
NEZNAMY fb2221d281 removed unnecessary local variables 2021-04-15 00:36:09 +02:00
NEZNAMY b5a295970b correctly moving to the bottom even when more than 9 groups are defined 2021-04-15 00:02:38 +02:00
NEZNAMY 485a453b27 added misconfiguration check 2021-04-14 19:36:39 +02:00
NEZNAMY 03d9ba9579 removed debug message 2021-04-14 19:29:08 +02:00
NEZNAMY ead7adea31 increased delay because requested 2021-04-14 19:28:17 +02:00
NEZNAMY 9793fdfc06 added debug messages 2021-04-14 19:27:50 +02:00
NEZNAMY 60b73e5c0d fixed NPE when modifier is null 2021-04-13 17:37:01 +02:00
NEZNAMY ed374c83d1 moving to API methods where possible 2021-04-13 15:24:56 +02:00
NEZNAMY f53828e01a no longer needed after updating setBossbarVisible method 2021-04-13 14:04:55 +02:00
NEZNAMY 91ab50fa6a removed unused method 2021-04-13 13:22:24 +02:00
NEZNAMY bee0d9d086 fixed issue from previous commits 2021-04-13 01:36:15 +02:00
NEZNAMY b38f09f118 moved symbol into constructor 2021-04-13 01:17:30 +02:00
NEZNAMY 65f57e8bf1 wrote the method from scratch for better performance & memory 2021-04-13 01:13:02 +02:00
NEZNAMY e424e42e05 matching change made to TextColor constructor 2021-04-13 00:48:11 +02:00
NEZNAMY a22cd5338d initializing value only once instead of every time it's used 2021-04-13 00:35:54 +02:00
NEZNAMY f921737d1c converting color object instead of calling fromString(.toString()) 2021-04-13 00:28:37 +02:00
NEZNAMY 2f760afc70 the constructor expects # 2021-04-13 00:06:59 +02:00
NEZNAMY 4ce56433f9 fowarding StringBuilder 2021-04-12 16:57:22 +02:00
NEZNAMY f8ace5fbb5 merged ifs 2021-04-12 16:51:26 +02:00
NEZNAMY f89778e969 not initializing map when unused 2021-04-12 16:35:56 +02:00
NEZNAMY 99f74d3824 using String.valueOf for less allocations 2021-04-12 16:28:13 +02:00
NEZNAMY dec9c42edc shorter alternative 2021-04-12 16:05:06 +02:00
NEZNAMY 34365c13cb calling int method directly if possible for better performance & memory 2021-04-12 15:20:39 +02:00
NEZNAMY 8a4c780fb1 parsing gradients only once instead of every refresh 2021-04-12 14:39:53 +02:00
NEZNAMY bed49408da only checking plugin presence on startup 2021-04-12 13:12:24 +02:00
NEZNAMY 5dd400bdc5 only initializing once 2021-04-12 13:01:04 +02:00
NEZNAMY 07d5a03a95 using AtomicInteger to avoid internal Integer.valueOf(int) call 2021-04-12 12:44:19 +02:00
NEZNAMY d53e7665d7 only initializing hexcodes once instead of every time 2021-04-12 12:17:33 +02:00
NEZNAMY 4021d7cbac fix from previous commit 2021-04-12 12:16:44 +02:00
NEZNAMY 2634ca5f28 not initializing list if not needed 2021-04-11 23:24:02 +02:00
840 changed files with 60001 additions and 89056 deletions

No files matched your search

+8
View File
@@ -0,0 +1,8 @@
* text=auto
*.sh text eol=lf
gradlew text eol=lf
*.bat text eol=crlf
*.jar binary
.gitea/CODEOWNERS linguist-detectable=false
+3
View File
@@ -0,0 +1,3 @@
# Pull requests request review from the eligible staff team(s).
# One approval from either an Admin or Developer satisfies branch protection.
* @trueog/Admins @trueog/Developers
-28
View File
@@ -1,28 +0,0 @@
---
name: Bug report
about: Report a bug
title: ''
labels: ''
assignees: ''
---
**Server version**
**Plugin version** ("latest" is not a version)
**Describe the bug**
**How to reproduce**
**Expected behavior**
**Actual behavior**
**Additional info** (errors, screenshots, ...)
+10 -6
View File
@@ -1,8 +1,7 @@
# Compiled class file
*.class
/bin/
/target/
/src/test/
bin/
target/
# Log file
*.log
@@ -31,8 +30,13 @@ hs_err_pid*
.project
# intellij
/.idea/
.idea/
# other
.gitattributes
*.iml
*.iml
run/
# Gradle
.gradle/
build/
!gradle/wrapper/gradle-wrapper.jar
+12
View File
@@ -0,0 +1,12 @@
If this plugin has helped you in any way, and you would like to return something back
to make the plugin even better, there is a lot of ways to contribute:
* Open a **pull request** containing a new feature or a bug fix, which you believe many users will benefit from.
* Make detailed high-quality **bug reports**. The difference between a bug getting fixed in 1 week vs 1 hour
is in quality of the report (typically providing correct steps to reproduce that actually work).
* Test **experimental builds**, which can be found in [GitHub Actions](https://github.com/NEZNAMY/TAB/actions) for problems of any kind including bugs.
This way you will help make the actual releases more stable / help get stable releases sooner.
* Help improve the wiki by opening a [Wiki change issue](https://github.com/NEZNAMY/TAB/issues/new?assignees=&labels=Wiki&template=wiki_change.yml),
where you can improve existing descriptions, add information you found missing, fix typos / grammar mistakes or add more examples.
* Create spark reports and then send them to me. I will analyze them and try to find optimizations to make the plugin run faster. Commands:
* `/spark profiler start --timeout 300 --thread * --interval 0.1`
* `/spark profiler start --timeout 300 --thread * --interval 0.1 --alloc`
+1 -28
View File
@@ -1,4 +1,4 @@
Apache License
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -172,30 +172,3 @@ Apache License
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25 -47
View File
@@ -1,49 +1,27 @@
## Introduction
Here it is. After countless requests to go opensource, I did it to make those people quiet. It worked.
It's already been a year and I still can't see any positives of it. This way I just made it easier for everyone to make a plugin as good, so people can stop using it and switch to something better.
## Compiling
Plugin can be compiled using maven.
# TAB-OG
## Premium code
The source contains content of premium version as well. However, this must be activated by setting [this line to return true](https://github.com/NEZNAMY/TAB/blob/master/src/main/java/me/neznamy/tab/shared/TAB.java#L79).
## Links
Free version
    Spigot (releases): https://www.spigotmc.org/resources/57806/
    Pre-releases https://github.com/NEZNAMY/TAB/releases
Premium version
    Polymart (releases): https://polymart.org/resource/484
    MC-Market (releases): https://www.mc-market.org/resources/14009/
    Pre-releases on discord for verified buyers
Bukkit bridge https://www.spigotmc.org/resources/83966/
Wiki https://github.com/NEZNAMY/TAB/wiki
Discord invite link: https://discord.gg/EaSvdk6
## Downloads
Official release: https://www.spigotmc.org/resources/57806/
Pre-releases: https://github.com/NEZNAMY/TAB/releases
## Maven Repository
```
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
TAB-OG is a soft fork of [TAB](https://github.com/NEZNAMY/TAB) for
[TrueOG Network](https://true-og.net/), based on upstream commit `93cfd74`.
<dependencies>
<!-- TAB -->
<dependency>
<groupId>com.github.NEZNAMY</groupId>
<artifactId>TAB-API</artifactId>
<version>2.8.10</version>
</dependency>
</dependencies>
```
Differences from upstream TAB:
- Versioned `5.9.9` (upstream is on `6.x`), targeting Purpur 1.19.4 serving 1.8–1.21.11
clients through ViaVersion, ViaBackwards, and ViaRewind.
- Builds only Bukkit `v1_19_R3`, BungeeCord, and Velocity; drops Fabric, Forge, NeoForge,
and the unused Bukkit/Paper NMS modules.
- Uses LuckPerms `5.5` (Vault removed) with a GraalVM JDK 17 toolchain, producing one
universal shaded JAR.
- TrueOG compatibility fixes: [Vanish-OG](https://git.trueog.net/trueog/Vanish-OG), the
[AFK-OG](https://git.trueog.net/trueog/AFK-OG) indicator, legacy scoreboard team colors,
and disabled scoreboard number formats.
- Legacy (1.8–1.12.2) nametag rendering: over-head names drop the rank brackets (the
tablist keeps them), sit one space after the rank in its color, bold the AFK indicator
for every client, and fit within the 16-character team prefix/suffix limits. A bold
rank is kept only when the whole tag can render bold — legacy clients width-count
everything after `§l` as bold and never receive a `§r`, so a plain-rendered name after
a bold rank pads the nametag end with phantom pixels; when it cannot fit, bold is
stripped over-head. Keeping bold requires `add-teamcolor-to-prefix: false` in the
ViaBackwards config, otherwise the appended team color un-bolds the name again.
- Ships live TrueOG Network config values.
Build with `./gradlew build` (JAR in `jar/build/libs/`). Requires LuckPerms; bold legacy
nametags additionally require ViaBackwards with `add-teamcolor-to-prefix: false`.
+2
View File
@@ -0,0 +1,2 @@
# Security Policy
If you found a security issue, send me a private message anywhere.
+7
View File
@@ -0,0 +1,7 @@
dependencies {
compileOnlyApi("org.jetbrains:annotations:26.0.2")
}
tasks.javadoc {
enabled = project.hasProperty("enable-javadoc")
}
@@ -0,0 +1,135 @@
package me.neznamy.tab.api;
import java.util.UUID;
import lombok.NonNull;
import lombok.Setter;
import me.neznamy.tab.api.bossbar.BossBarManager;
import me.neznamy.tab.api.event.EventBus;
import me.neznamy.tab.api.placeholder.PlaceholderManager;
import me.neznamy.tab.api.scoreboard.ScoreboardManager;
import me.neznamy.tab.api.tablist.SortingManager;
import me.neznamy.tab.api.tablist.HeaderFooterManager;
import me.neznamy.tab.api.tablist.TabListFormatManager;
import me.neznamy.tab.api.nametag.NameTagManager;
import me.neznamy.tab.api.tablist.layout.LayoutManager;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* The primary API class to get instances of other API classes
*/
public abstract class TabAPI {
/** Instance of the API */
@Setter private static TabAPI instance;
/**
* Returns API instance. If instance was not set by the plugin, throws
* {@code IllegalStateException}. This is usually caused by shading the API
* into own project, which is not allowed. Another option is calling the method
* before plugin was able to load.
*
* @return API instance
* @throws IllegalStateException
* If instance is {@code null}
*/
public static @NotNull TabAPI getInstance() {
if (instance == null) throw new IllegalStateException("The API instance is null. This can have 2 possible causes: \n" +
"#1 - API was called before TAB was loaded. This means your plugin was loaded before TAB was. To make sure your " +
"plugin loads after TAB, add it as a depend or soft depend of your plugin.\n" +
"#2 - You shaded TAB's classes into your plugin, instead of only using them. This is not allowed. To verify this " +
"is your case, unzip your plugin and check for TAB's classes. If they are there, you will need to fix your compiler " +
"to not include them, such as scope provided for maven compilation.");
return instance;
}
/**
* Returns player object from given UUID
*
* @param id
* Player UUID
* @return player object from given UUID
*/
public abstract @Nullable TabPlayer getPlayer(@NonNull UUID id);
/**
* Returns player object from given name
*
* @param name
* Player name
* @return player object from given name
*/
public abstract @Nullable TabPlayer getPlayer(@NonNull String name);
/**
* Returns collection of all online players. Will return empty list if plugin is disabled (due to a broken configuration file for example).
*
* @return collection of online players
*/
public abstract @NotNull TabPlayer[] getOnlinePlayers();
/**
* Return BossBar manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return BossBar manager
*/
public abstract @Nullable BossBarManager getBossBarManager();
/**
* Returns scoreboard manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return scoreboard manager
*/
public abstract @Nullable ScoreboardManager getScoreboardManager();
/**
* Returns team manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return team manager
*/
public abstract @Nullable NameTagManager getNameTagManager();
/**
* Returns header/footer manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return Header/footer manager
*/
public abstract @Nullable HeaderFooterManager getHeaderFooterManager();
/**
* Returns PlaceholderManager instance
*
* @return PlaceholderManager instance
*/
public abstract @NotNull PlaceholderManager getPlaceholderManager();
/**
* Returns TabList name format manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return TabList name format manager
*/
public abstract @Nullable TabListFormatManager getTabListFormatManager();
/**
* Returns Layout manager instance if the feature is enabled. If not, returns {@code null}.
*
* @return Layout manager
*/
public abstract @Nullable LayoutManager getLayoutManager();
/**
* Returns Sorting manager instance if at least one feature capable of sorting players is enabled.
* If not, returns {@code null}.
*
* @return Sorting manager
*/
public abstract @Nullable SortingManager getSortingManager();
/**
* Gets the event bus for registering listeners for TAB events.
*
* @return the event bus
*/
public abstract @Nullable EventBus getEventBus();
}
@@ -0,0 +1,125 @@
package me.neznamy.tab.api;
import lombok.NonNull;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.UUID;
/**
* An interface representing a player
*/
@SuppressWarnings("unused") // API class
public interface TabPlayer {
/**
* Returns player's name
*
* @return Player's name
*/
@NotNull
String getName();
/**
* Returns player's UUID
*
* @return Player's UUID
*/
@NotNull
UUID getUniqueId();
/**
* Returns platform-specific entity
*
* @return platform's player object
*/
@NotNull
Object getPlayer();
/**
* Returns true once the player is successfully loaded (onJoin method ran through all methods)
*
* @return {@code true} if player is fully loaded, {@code false} otherwise
*/
boolean isLoaded();
/**
* Returns player's primary permission group. If group has been changed using
* {@link #setTemporaryGroup(String)}, returns that value. Otherwise, returns group
* detected by standard group assign logic
*
* @return player's primary permission group
*/
@NotNull
String getGroup();
/**
* Temporarily overrides player's group and applies all changes coming from new group.
* This includes all properties and sorting, if used.
* Set to {@code null} to reset back.
*
* @param group
* New group to use
* @see #hasTemporaryGroup()
*/
void setTemporaryGroup(@Nullable String group);
/**
* Returns {@code true} if a temporary group was applied to the player using {@link #setTemporaryGroup(String)}.
* If no group was set, returns {@code false}
*
* @return {@code true} if group is set, {@code false} if not
* @see #setTemporaryGroup(String)
*/
boolean hasTemporaryGroup();
/**
* Changes expected profile name of the player. This adapts all name-bound features
* to use this new profile name if another plugin changed profile name of the player. <p>
* Automatic profile name change detection is available on Bukkit, BungeeCord and Fabric,
* therefore using this is redundant there. This function is only needed on Velocity,
* where the detection is not available. <p>
* Warning: This function does NOT change player's profile name, it only updates the tracked
* name inside the plugin.
*
* @param profileName
* New expected profile name
*/
void setExpectedProfileName(@NonNull String profileName);
/**
* Returns player's expected profile name. This defaults to player's username, but may
* get changed by other plugins and then detected by TAB.
*
* @return Player's expected profile name
*/
@NotNull
String getExpectedProfileName();
/**
* Returns name of the server the player is connected to.
* This requires TAB on proxy.
* On backend installation, this method returns {@code "N/A"}.
*
* @return Player's server on proxy or {@code "N/A"} on backend installation
*/
@NotNull
String getServer();
/**
* Returns name of the world the player is in.
* On proxy installation, TAB-Bridge must be installed to forward this info to the proxy.
* Otherwise, it will return {@code "N/A"}.
*
* @return Player's world or {@code "N/A"} on proxy installation without TAB-Bridge installed
*/
@NotNull
String getWorld();
/**
* Returns {@code true} if this player is a bedrock player, {@code false} if not.
*
* @return {@code true} if this player is a bedrock player, {@code false} if not
*/
boolean isBedrockPlayer();
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.api.bossbar;
/**
* An enum representing all available BossBar colors.
* Calling ordinal() will return color's network ID.
*/
@SuppressWarnings("unused") // API class
public enum BarColor {
/** Pink color */
PINK,
/** Blue color */
BLUE,
/** Red color */
RED,
/** Green color */
GREEN,
/** Yellow color */
YELLOW,
/** Purple color */
PURPLE,
/** White color */
WHITE
}
@@ -0,0 +1,24 @@
package me.neznamy.tab.api.bossbar;
/**
* An enum representing all available BossBar styles.
* Calling ordinal() will return style's network ID.
*/
@SuppressWarnings("unused") // API class
public enum BarStyle {
/** Fully solid line */
PROGRESS,
/** Line segmented into 6 parts */
NOTCHED_6,
/** Line segmented into 10 parts */
NOTCHED_10,
/** Line segmented into 12 parts */
NOTCHED_12,
/** Line segmented into 20 parts */
NOTCHED_20
}
@@ -0,0 +1,213 @@
package me.neznamy.tab.api.bossbar;
import java.util.List;
import java.util.UUID;
import lombok.NonNull;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
/**
* An interface representing a BossBar line.
* <p>
* It uses 1.9+ BossBar feature, allowing configurable styles
* and colors, as well as display several bars at once. Limit of maximum
* displayed BossBars depends on client resolution and GUI scale, up to
* 9 concurrent BossBars displayed at once.
*/
public interface BossBar {
/**
* Returns name of this BossBar. If it was defined in config, returns
* the name specified in config. If it was made using the API, returns
* randomly generated ID given to this BossBar when creating.
*
* @return name of BossBar
*/
@NotNull String getName();
/**
* Returns randomly generated uuid of this BossBar used internally to match
* the BossBar in client with packets or with Bukkit API BossBar instances.
*
* @return uuid of this BossBar
*/
@NotNull UUID getUniqueId();
/**
* Changes BossBar title to specified string, supporting placeholders.
* <p>
* If title contains new placeholders not used before, they are registered using
* standard registration logic and refreshed periodically. No need to call
* this method to try to keep placeholder values up to date.
* <p>
* If specified title is equal to the current one, nothing happens.
*
* @param title
* New title to display in this BossBar
*/
void setTitle(@NonNull String title);
/**
* Changes BossBar progress to specified string, supporting placeholders.
* The string must be a string version of a float value, or a placeholder that
* outputs a float value with range 0-100.
* <p>
* If progress contains new placeholders not used before, they are registered using
* standard registration logic and refreshed periodically. No need to call
* this method to try to keep placeholder values up to date.
* <p>
* If specified progress is equal to the current one, nothing happens.
*
* @param progress
* New progress to use in this BossBar
*/
void setProgress(@NonNull String progress);
/**
* Changes BossBar progress to specified value ranging from 0 to 100.
* <p>
* If specified progress is equal to the current one, nothing happens.
*
* @param progress
* New progress to use in this BossBar
*/
void setProgress(float progress);
/**
* Changes BossBar color to specified string, supporting placeholders.
* The string must be a string version of one of the supported values,
* or a placeholder that outputs one of them.
* <p>
* If color contains new placeholders not used before, they are registered using
* standard registration logic and refreshed periodically. No need to call
* this method to try to keep placeholder values up to date.
* <p>
* If specified color is equal to the current one, nothing happens.
*
* @param color
* New color to use in this BossBar
*/
void setColor(@NonNull String color);
/**
* Changes BossBar color to specified enum constant.
* <p>
* If specified color is equal to the current one, nothing happens.
*
* @param color
* New color to use in this BossBar
*/
void setColor(@NonNull BarColor color);
/**
* Changes BossBar style to specified string, supporting placeholders.
* The string must be a string version of one of the supported values,
* or a placeholder that outputs one of them.
* <p>
* If style contains new placeholders not used before, they are registered using
* standard registration logic and refreshed periodically. No need to call
* this method to try to keep placeholder values up to date.
* <p>
* If specified style is equal to the current one, nothing happens.
*
* @param style
* New style to use in this BossBar
*/
void setStyle(@NonNull String style);
/**
* Changes BossBar style to specified enum constant.
* <p>
* If specified style is equal to the current one, nothing happens.
*
* @param style
* New style to use in this BossBar
*/
void setStyle(@NonNull BarStyle style);
/**
* Returns current title of the BossBar in raw format. If it contains placeholders,
* their raw identifiers are used in the result.
*
* @return title of the BossBar
*/
@NotNull String getTitle();
/**
* Returns progress of the BossBar as a string, which is either entered string
* containing placeholders or entered number converted to string
*
* @return entered progress as a string
*/
@NotNull String getProgress();
/**
* Returns color of the BossBar as a string, which is either entered string
* containing placeholders or entered enum value converted to string
*
* @return entered color as a string
*/
@NotNull String getColor();
/**
* Returns style of the BossBar as a string, which is either entered string
* containing placeholders or entered enum value converted to string
*
* @return entered style as a string
*/
@NotNull String getStyle();
/**
* Registers this BossBar to specified player.
* <p>
* If the player already sees this BossBar, nothing happens.
*
* @param player
* Player to register this BossBar to
*/
void addPlayer(@NonNull TabPlayer player);
/**
* Unregisters this BossBar from specified player.
* <p>
* If the player does not see this BossBar, nothing happens.
*
* @param player
* Player to unregister this BossBar from
*/
void removePlayer(@NonNull TabPlayer player);
/**
* Returns list of players who can see this BossBar.
* <p>
* The returned list can only be used to read. Writing
* will not work properly. For adding/removing players see {@link #addPlayer(TabPlayer)}
* and {@link #removePlayer(TabPlayer)}.
*
* @return List of players seeing this BossBar
*/
@NotNull List<TabPlayer> getPlayers();
/**
* Returns {@code true} if this bossbar is visible to specified player based on
* display condition or adding via {@link #addPlayer(TabPlayer)}, {@code false} if not.
* <p>
* This may return {@code true} even if player cannot physically see the bossbar due to
* having it disabled via toggle command or {@link BossBarManager#toggleBossBar(TabPlayer, boolean)}
* (or {@link BossBarManager#setBossBarVisible(TabPlayer, boolean, boolean)}).
*
* @param player
* Player to check
* @return {@code true} if player is allowed to see this Boss Bar, {@code false} if not.
*/
boolean containsPlayer(@NonNull TabPlayer player);
/**
* Returns {@code true} if this boss bar is configured as announcement-only bar,
* {@code false} if not.
*
* @return {@code true} if bar is announcement only, {@code false} if not
*/
boolean isAnnouncementBar();
}
@@ -0,0 +1,179 @@
package me.neznamy.tab.api.bossbar;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.List;
import java.util.Map;
/**
* An interface allowing work with BossBars such as creating, sending
* and toggling.
* <p>
* Instance can be obtained using {@link TabAPI#getBossBarManager()}.
* This requires the BossBar feature to be enabled in config, otherwise the method will
* return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface BossBarManager {
/**
* Creates BossBar with specified parameters and registers it to BossBar manager,
* allowing to retrieve it later.
*
* @param title
* Title to display, supports placeholders
* @param progress
* Progress to use. Must be between 0 and 100
* @param color
* Color to use
* @param style
* Style to use
* @return The newly created BossBar
*/
@NotNull BossBar createBossBar(@NonNull String title, float progress, @NonNull BarColor color, @NonNull BarStyle style);
/**
* Creates BossBar with specified parameters and registers it to BossBar manager,
* allowing to retrieve it later.
*
* @param title
* Title to display, supports placeholders
* @param progress
* Progress to use. Must be a string version of a number, or
* a placeholder that returns a number
* @param color
* Color to use. Must be a string version of one of enum constants, or
* a placeholder that returns one of them
* @param style
* Style to use. Must be a string version of one of enum constants, or
* a placeholder that returns one of them
* @return The newly created BossBar
*/
@NotNull BossBar createBossBar(@NonNull String title, @NonNull String progress, @NonNull String color, @NonNull String style);
/**
* Returns registered BossBar with given name. For BossBars from config it is the name
* they were created with, for API BossBars their randomly generated name, which can be
* retrieved using {@link me.neznamy.tab.api.bossbar.BossBar#getName()}.
* Returns {@code null} if no such BossBar exists.
*
* @param name
* Name of registered BossBar
* @return BossBar with specified name
*/
@Nullable BossBar getBossBar(@NonNull String name);
/**
* Returns a map of all registered BossBars. This includes both BossBars from config
* and those registered via API.
* <p>
* Map key is BossBar's name available in {@link me.neznamy.tab.api.bossbar.BossBar#getName()},
* map value is the BossBar interface.
*
* @return all registered BossBars
*/
@NotNull Map<String, BossBar> getRegisteredBossBars();
/**
* Removes BossBar with specified name from the manager, making it no longer available.
* If BossBar was displayed to any players, it is removed.
*
* @param name
* Name of registered BossBar to remove
* @throws IllegalArgumentException
* if no BossBar with specified name exists
*/
void removeBossBar(@NonNull String name);
/**
* Removes BossBar from the manager, making it no longer available.
* If BossBar was displayed to any players, it is removed.
*
* @param bossBar
* BossBar to remove
* @throws IllegalArgumentException
* if specified BossBar is not registered
*/
void removeBossBar(@NonNull BossBar bossBar);
/**
* Toggles BossBar for this player and sends toggle message if {@code sendToggleMessage} is true.
*
* @param player
* Player to toggle BossBar for
* @param sendToggleMessage
* {@code true} if toggle message should be sent, {@code false} if not
* @see #hasBossBarVisible(TabPlayer)
* @see #setBossBarVisible(TabPlayer, boolean, boolean)
*/
void toggleBossBar(@NonNull TabPlayer player, boolean sendToggleMessage);
/**
* Returns true if player can see BossBars, false if toggled via command or API.
*
* @param player
* Player to check toggle status of
* @return {@code true} if visible, {@code false} if disabled (toggled)
* @see #toggleBossBar(TabPlayer, boolean)
* @see #setBossBarVisible(TabPlayer, boolean, boolean)
*/
boolean hasBossBarVisible(@NonNull TabPlayer player);
/**
* Sets BossBar visibility of player to set value. If value did not change, nothing happens.
* If visibility changed, toggle message is sent if {@code sendToggleMessage} is {@code true}.
*
* @param player
* Player to set BossBar visibility of
* @param visible
* {@code true} if BossBar should be visible, {@code false} if not
* @param sendToggleMessage
* {@code true} if toggle message should be sent if value changed, {@code false} if not
* @see #toggleBossBar(TabPlayer, boolean)
* @see #hasBossBarVisible(TabPlayer)
*/
void setBossBarVisible(@NonNull TabPlayer player, boolean visible, boolean sendToggleMessage);
/**
* Temporarily displays registered BossBar to player for specified amount of time in seconds.
*
* @param player
* Player to show BossBar to
* @param bossBar
* Name of registered BossBar to show
* @param duration
* In seconds for how long should BossBar be displayed
* @throws IllegalArgumentException
* if no BossBar with specified name exists
* @see #announceBossBar(String, int)
* @see #getAnnouncedBossBars()
*/
void sendBossBarTemporarily(@NonNull TabPlayer player, @NonNull String bossBar, int duration);
/**
* Temporarily displays registered BossBar to all players for specified amount of time in seconds.
*
* @param bossBar
* Name of registered BossBar to show
* @param duration
* In seconds for how long should BossBar be displayed
* @throws IllegalArgumentException
* if no BossBar with specified name exists
* @see #sendBossBarTemporarily(TabPlayer, String, int)
* @see #getAnnouncedBossBars()
*/
void announceBossBar(@NonNull String bossBar, int duration);
/**
* Returns list of BossBars which are currently being announced.
*
* @return list of currently active BossBar announcements
* @see #sendBossBarTemporarily(TabPlayer, String, int)
* @see #announceBossBar(String, int)
*/
@NotNull List<BossBar> getAnnouncedBossBars();
}
@@ -0,0 +1,56 @@
package me.neznamy.tab.api.event;
import lombok.NonNull;
/**
* The event bus. This is used to register event listeners/handlers for
* handling events that may be fired by TAB.
*/
@SuppressWarnings("unused") // API class
public interface EventBus {
/**
* Scans the given listener for any method that is annotated with
* {@link Subscribe} and registers it as a listener to this event bus.
*
* <p>All methods in this class that are annotated with {@link Subscribe}
* must meet the following criteria:
* <ul>
* <li>It must be <strong>public</strong>.</li>
* <li>It must <strong>not</strong> be abstract.</li>
* <li>It must have exactly <strong>one</strong> parameter.</li>
* <li>Its single parameter must be <strong>an event</strong>.</li>
* </ul>
* If a method does not meet the above criteria, an exception <strong>will</strong>
* be thrown.
*
* @param listener the listener to register
* @throws RuntimeException if a method does not meet the criteria
*/
void register(@NonNull Object listener);
/**
* Registers the given handler to this event bus.
*
* @param type the class type of the event
* @param handler the handler to register
* @param <E> the type of the event
*/
<E extends TabEvent> void register(@NonNull Class<E> type, @NonNull EventHandler<E> handler);
/**
* Scans the given listener for any method that is annotated with
* {@link Subscribe} and unregisters it from this event bus.
*
* @param listener the listener to unregister
*/
void unregister(@NonNull Object listener);
/**
* Unregisters the given handler from this event bus.
*
* @param handler the handler to unregister
* @param <E> the type of the event
*/
<E extends TabEvent> void unregister(@NonNull EventHandler<E> handler);
}
@@ -0,0 +1,18 @@
package me.neznamy.tab.api.event;
/**
* A handler for an event. This allows listening for events in a more
* functional style.
*
* @param <E> the type of event this handler handles
*/
@FunctionalInterface
public interface EventHandler<E> {
/**
* Called when the given event is fired from an event bus.
*
* @param event the event to handle
*/
void handle(E event);
}
@@ -0,0 +1,14 @@
package me.neznamy.tab.api.event;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Subscribes to a {@link TabEvent}.
*/
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface Subscribe {
}
@@ -0,0 +1,10 @@
package me.neznamy.tab.api.event;
/**
* An event that may be fired by TAB when something occurs.
*
* <p>This is a marker interface. All events <strong>must</strong> implement this
* interface.
*/
public interface TabEvent {
}
@@ -0,0 +1,26 @@
package me.neznamy.tab.api.event.player;
import me.neznamy.tab.api.TabPlayer;
import me.neznamy.tab.api.event.TabEvent;
import org.jetbrains.annotations.NotNull;
/**
* Called when the player has been fully loaded by TAB.
*/
public interface PlayerLoadEvent extends TabEvent {
/**
* Gets the player that was loaded.
*
* @return the player that was loaded
*/
@NotNull TabPlayer getPlayer();
/**
* Returns {@code true} if player was loaded because they joined,
* {@code false} if the player was loaded because tab reload command was executed
*
* @return {@code true} if player joined, {@code false} if plugin was reloaded
*/
boolean isJoin();
}
@@ -0,0 +1,9 @@
package me.neznamy.tab.api.event.plugin;
import me.neznamy.tab.api.event.TabEvent;
/**
* Called when TAB is fully loaded.
*/
public interface TabLoadEvent extends TabEvent {
}
@@ -0,0 +1,85 @@
package me.neznamy.tab.api.integration;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import java.util.ArrayList;
import java.util.List;
@Getter
@RequiredArgsConstructor
public abstract class VanishIntegration {
/** List of all registered VanishIntegration handlers */
private static final List<VanishIntegration> HANDLERS = new ArrayList<>();
/** Name of the plugin this integration is associated with */
@NotNull
private final String plugin;
/**
* Determines if a viewer can see a target player.
*
* @param viewer
* The player attempting to view another player
* @param target
* The player being viewed
* @return {@code true} if the viewer can see the target, {@code false} otherwise
*/
public abstract boolean canSee(@NotNull TabPlayer viewer, @NotNull TabPlayer target);
/**
* Checks if the specified player is in a vanished state.
*
* @param player
* The player to check
* @return {@code true} if the player is vanished, {@code false} otherwise
*/
public abstract boolean isVanished(@NotNull TabPlayer player);
/**
* Registers this integration handler to the global list of handlers.
*/
public void register() {
registerHandler(this);
}
/**
* Unregisters this integration handler from the global list of handlers.
*/
public void unregister() {
unregisterHandler(this);
}
/**
* Adds a VanishIntegration handler to the global list of handlers.
*
* @param handler
* The handler to register
*/
public static void registerHandler(@NotNull VanishIntegration handler) {
HANDLERS.add(handler);
}
/**
* Removes a VanishIntegration handler from the global list of handlers.
*
* @param handler
* The handler to unregister
*/
public static void unregisterHandler(@NotNull VanishIntegration handler) {
HANDLERS.remove(handler);
}
/**
* Retrieves the list of all registered VanishIntegration handlers.
*
* @return A list of registered VanishIntegration handlers
*/
@NotNull
public static List<VanishIntegration> getHandlers() {
return HANDLERS;
}
}
@@ -0,0 +1,289 @@
package me.neznamy.tab.api.nametag;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* Interface for manipulating player name tags.
* <p>
* Instance can be obtained using {@link TabAPI#getNameTagManager()}.
* This requires the Team feature to be enabled in config, otherwise the method will
* return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface NameTagManager {
/**
* Makes player's NameTag globally invisible
*
* @param player
* player to hide name tag of
* @see #showNameTag(TabPlayer)
* @see #hasHiddenNameTag(TabPlayer)
*/
void hideNameTag(@NonNull TabPlayer player);
/**
* Hides player's NameTag for specified player until it's shown again
*
* @param player
* player to hide name tag of
* @param viewer
* player to hide name tag for
*/
void hideNameTag(@NonNull TabPlayer player, @NonNull TabPlayer viewer);
/**
* Makes player's NameTag visible again
*
* @param player
* player to show name tag of
* @see #hideNameTag(TabPlayer)
* @see #hasHiddenNameTag(TabPlayer)
*/
void showNameTag(@NonNull TabPlayer player);
/**
* Shows player's NameTag for specified viewer if it was hidden before
*
* @param player
* player to show name tag of
* @param viewer
* player to show NameTag back for
*/
void showNameTag(@NonNull TabPlayer player, @NonNull TabPlayer viewer);
/**
* Return whether player has hidden NameTag or not
*
* @param player
* player to check name tag visibility status of
* @return Whether player has hidden NameTag or not
* @see #hideNameTag(TabPlayer)
* @see #showNameTag(TabPlayer)
*/
boolean hasHiddenNameTag(@NonNull TabPlayer player);
/**
* Returns true if NameTag is hidden for specified viewer, false if not
*
* @param player
* player to check visibility status of
* @param viewer
* player to check visibility status for
* @return true if hidden, false if not
*/
boolean hasHiddenNameTag(@NonNull TabPlayer player, @NonNull TabPlayer viewer);
/**
* Unregisters player's team and no longer handles it, as well as disables anti-override for teams.
* This can be resumed using resumeTeamHandling(). If team handling was paused already, nothing happens.
*
* @param player
* player to pause team handling of
*/
void pauseTeamHandling(@NonNull TabPlayer player);
/**
* Resumes team handling if it was before paused using pauseTeamHandling(), if not, nothing happens
*
* @param player
* player to resume team handling of
*/
void resumeTeamHandling(@NonNull TabPlayer player);
/**
* Returns true if team handling is paused for this player using pauseTeamHandling(), false if not, or
* it was resumed already using resumeTeamHandling
*
* @param player
* player to check handling status of
* @return true if paused, false if not
*/
boolean hasTeamHandlingPaused(@NonNull TabPlayer player);
/**
* Forces collision rule for the player. Setting it to null will remove forced value
*
* @param player
* player to set collision rule of
* @param collision
* forced collision rule
*/
void setCollisionRule(@NonNull TabPlayer player, @Nullable Boolean collision);
/**
* Returns forced collision rule or null if collision is not forced using setCollisionRule
*
* @param player
* player to get forced collision of
* @return forced value or null if not forced
*/
@Nullable Boolean getCollisionRule(@NonNull TabPlayer player);
/**
* Changes player's prefix to provided value. Supports placeholders,
* as well as any supported RGB formats. Use {@code null} to reset
* value back to original.
*
* @param player
* player to change prefix of
* @param prefix
* new prefix value
* @see #getCustomPrefix(TabPlayer)
* @see #getOriginalRawPrefix(TabPlayer)
*/
void setPrefix(@NonNull TabPlayer player, @Nullable String prefix);
/**
* Changes player's suffix to provided value. Supports placeholders,
* as well as any supported RGB formats. Use {@code null} to reset
* value back to original.
*
* @param player
* player to change prefix of
* @param suffix
* new suffix value
* @see #getCustomSuffix(TabPlayer)
* @see #getOriginalRawSuffix(TabPlayer)
*/
void setSuffix(@NonNull TabPlayer player, @Nullable String suffix);
/**
* Returns custom prefix assigned using {@link #setPrefix(TabPlayer, String)}.
* If no custom prefix is set, returns {@code null}.
*
* @param player
* Player to get custom prefix of
* @return Custom prefix assigned using the API.
* @see #setPrefix(TabPlayer, String)
* @see #getOriginalRawPrefix(TabPlayer)
*/
@Nullable
String getCustomPrefix(@NonNull TabPlayer player);
/**
* Returns custom suffix assigned using {@link #setSuffix(TabPlayer, String)}.
* If no custom suffix is set, returns {@code null}.
*
* @param player
* Player to get custom suffix of
* @return Custom suffix assigned using the API.
* @see #setSuffix(TabPlayer, String)
* @see #getOriginalRawSuffix(TabPlayer)
*/
@Nullable
String getCustomSuffix(@NonNull TabPlayer player);
/**
* Returns original prefix assigned by the plugin using internal logic.
* @param player
* Player to get original prefix of
* @return Original prefix assigned by the plugin's internal logic.
* @see #getCustomPrefix(TabPlayer)
*/
@NotNull
String getOriginalRawPrefix(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic.
* @param player
* Player to get original suffix of
* @return Original suffix assigned by the plugin's internal logic.
* @see #getCustomSuffix(TabPlayer)
*/
@NotNull
String getOriginalRawSuffix(@NonNull TabPlayer player);
/**
* Returns original prefix assigned by the plugin using internal logic with all placeholders replaced.
* @param player
* Player to get replaced original prefix of
* @return Original prefix assigned by the plugin's internal logic.
* @see #getCustomPrefix(TabPlayer)
*/
@NotNull
String getOriginalReplacedPrefix(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic with all placeholders replaced.
* @param player
* Player to get replaced original suffix of
* @return Original suffix assigned by the plugin's internal logic.
* @see #getCustomSuffix(TabPlayer)
*/
@NotNull
String getOriginalReplacedSuffix(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic.
* @param player
* Player to get replaced original prefix of
* @return Original prefix assigned by the plugin's internal logic.
* @see #getCustomPrefix(TabPlayer)
* @deprecated Use {@link #getOriginalRawPrefix(TabPlayer)} instead.
*/
@Deprecated
@NotNull
String getOriginalPrefix(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic.
* @param player
* Player to get replaced original suffix of
* @return Original suffix assigned by the plugin's internal logic.
* @see #getCustomSuffix(TabPlayer)
* @deprecated Use {@link #getOriginalRawSuffix(TabPlayer)} instead.
*/
@Deprecated
@NotNull
String getOriginalSuffix(@NonNull TabPlayer player);
/**
* Toggles name tag visibility view on all players for specified player.
* On first call, name tags of all players will become invisible for specified
* player. On the second call, they will become visible again.
*
* @param player
* player to toggle name tag visibility view for
* @param sendToggleMessage
* {@code true} if the configured toggle message should be sent, {@code false} if not
*/
void toggleNameTagVisibilityView(@NonNull TabPlayer player, boolean sendToggleMessage);
/**
* Shows back name tag visibility view on all players for specified player.
* If the view is not hidden, nothing happens.
*
* @param player
* player to show name tag visibility view for
* @param sendToggleMessage
* {@code true} if the configured toggle message should be sent, {@code false} if not
*/
void showNameTagVisibilityView(@NonNull TabPlayer player, boolean sendToggleMessage);
/**
* Hides name tag visibility view on all players for specified player.
* If the view is already hidden, nothing happens.
*
* @param player
* player to show name tag visibility view for
* @param sendToggleMessage
* {@code true} if the configured toggle message should be sent, {@code false} if not
*/
void hideNameTagVisibilityView(@NonNull TabPlayer player, boolean sendToggleMessage);
/**
* Returns {@code true} if player has hidden name tags by either calling
* {@link #toggleNameTagVisibilityView(TabPlayer, boolean)} or using a command,
* {@code false} if not.
*
* @param player
* player to check
* @return {@code true} if hidden, {@code false} if not
*/
boolean hasHiddenNameTagVisibilityView(@NonNull TabPlayer player);
}
@@ -0,0 +1,23 @@
package me.neznamy.tab.api.placeholder;
import org.jetbrains.annotations.NotNull;
/**
* An interface representing some kind of placeholder
*/
public interface Placeholder {
/**
* Returns refresh interval of this placeholder
*
* @return refresh interval of this placeholder
*/
int getRefresh();
/**
* Returns placeholder's identifier
*
* @return placeholder's identifier
*/
@NotNull String getIdentifier();
}
@@ -0,0 +1,103 @@
package me.neznamy.tab.api.placeholder;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import java.util.function.BiFunction;
import java.util.function.Function;
import java.util.function.Supplier;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* An interface allowing placeholder registration. Instance can be
* obtained using {@link TabAPI#getPlaceholderManager()}
*/
@SuppressWarnings("unused") // API class
public interface PlaceholderManager {
/**
* Registers a server placeholder (placeholder with same output for all players)
*
* @param identifier
* Placeholder identifier
* @param refresh
* Refresh interval
* @param supplier
* Supplier for placeholder output
* @return Registered placeholder for further use
* @throws IllegalArgumentException
* If {@code identifier} does not start and end with {@code %} or
* {@code refresh} is not divisible by 50
*/
@NotNull ServerPlaceholder registerServerPlaceholder(@NonNull String identifier, int refresh, @NonNull Supplier<String> supplier);
/**
* Registers a player placeholder (placeholder different output per player)
*
* @param identifier
* Placeholder identifier
* @param refresh
* Refresh interval
* @param function
* Function for placeholder output
* @return Registered placeholder for further use
* @throws IllegalArgumentException
* If {@code identifier} does not start and end with {@code %} or
* {@code refresh} is not divisible by 50
*/
@NotNull PlayerPlaceholder registerPlayerPlaceholder(@NonNull String identifier, int refresh, @NonNull Function<TabPlayer, String> function);
/**
* Registers a relational placeholder (placeholder with output different for each player duo)
*
* @param identifier
* Placeholder identifier
* @param refresh
* Refresh interval
* @param function
* Function for placeholder output
* @return Registered placeholder for further use
* @throws IllegalArgumentException
* If {@code identifier} does not start and end with {@code %},
* does not start with {@code %rel_} or
* {@code refresh} is not divisible by 50
*/
@NotNull RelationalPlaceholder registerRelationalPlaceholder(@NonNull String identifier, int refresh, @NonNull BiFunction<TabPlayer, TabPlayer, String> function);
void registerServerPlaceholder(@NonNull Pattern identifier, int refresh, @NonNull Function<Matcher, Supplier<String>> function);
void registerPlayerPlaceholder(@NonNull Pattern identifier, int refresh,
@NonNull Function<Matcher, Function<me.neznamy.tab.api.TabPlayer, String>> function);
void registerRelationalPlaceholder(@NonNull Pattern identifier, int refresh,
@NonNull Function<Matcher, BiFunction<me.neznamy.tab.api.TabPlayer, me.neznamy.tab.api.TabPlayer, String>> function);
/**
* Returns placeholder from specified identifier. If it does not exist, it is registered
* as a PlaceholderAPI placeholder and returned.
*
* @param identifier
* Placeholder identifier
* @return Placeholder with specified identifier
*/
@NotNull Placeholder getPlaceholder(@NonNull String identifier);
/**
* Unregisters placeholder and makes plugin no longer refresh it.
*
* @param placeholder
* Placeholder to unregister
*/
void unregisterPlaceholder(@NonNull Placeholder placeholder);
/**
* Unregisters placeholder and makes plugin no longer refresh it.
*
* @param identifier
* identifier of placeholder to unregister
*/
void unregisterPlaceholder(@NonNull String identifier);
}
@@ -0,0 +1,31 @@
package me.neznamy.tab.api.placeholder;
import lombok.NonNull;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.Nullable;
/**
* Interface for player placeholders (placeholders returning different value for each player)
*/
public interface PlayerPlaceholder extends Placeholder {
/**
* Force-updates placeholder value. It will still be overridden by periodic refresh later,
* so this is (only) useful for force an update when value is supposed to change, and you have
* a high refresh interval set.
*
* @param player
* Player to update value for
* @param value
* New value
*/
void updateValue(@NonNull TabPlayer player, @Nullable String value);
/**
* Force-updates placeholder value using previously provided update function.
*
* @param player
* Player to update value for
*/
void update(@NonNull TabPlayer player);
}
@@ -0,0 +1,36 @@
package me.neznamy.tab.api.placeholder;
import lombok.NonNull;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.Nullable;
/**
* An interface for relational placeholders (returning different value for each player duo)
*/
@SuppressWarnings("unused") // API class
public interface RelationalPlaceholder extends Placeholder {
/**
* Force-updates placeholder value. It will still be overridden by periodic refresh later,
* so this is (only) useful for force an update when value is supposed to change, and you have
* a high refresh interval set.
*
* @param viewer
* Placeholder viewer
* @param target
* Placeholder target
* @param value
* New value
*/
void updateValue(@NonNull TabPlayer viewer, @NonNull TabPlayer target, @Nullable String value);
/**
* Force-updates placeholder value using previously provided update function.
*
* @param viewer
* Placeholder viewer
* @param target
* Placeholder target
*/
void update(@NonNull TabPlayer viewer, @NonNull TabPlayer target);
}
@@ -0,0 +1,24 @@
package me.neznamy.tab.api.placeholder;
import org.jetbrains.annotations.Nullable;
/**
* An interface for server placeholders (returning same value for all players)
*/
public interface ServerPlaceholder extends Placeholder {
/**
* Force-updates placeholder value. It will still be overridden by periodic refresh later,
* so this is (only) useful for force an update when value is supposed to change, and you have
* a high refresh interval set.
*
* @param value
* New value
*/
void updateValue(@Nullable String value);
/**
* Force-updates placeholder value using previously provided update function.
*/
void update();
}
@@ -0,0 +1,32 @@
package me.neznamy.tab.api.scoreboard;
import lombok.NonNull;
import org.jetbrains.annotations.NotNull;
/**
* An interface allowing to work with a line of
* text in scoreboard.
*
*/
public interface Line {
/**
* Returns configured raw text of this line. Placeholders
* remain in raw format.
*
* @return raw text of this line
*/
@NotNull String getText();
/**
* Changes text to new value. Supports placeholders, which are
* automatically registered if needed and refreshed periodically
* based on configuration. No need to call this method to try to
* keep placeholders up to date. If value is identical to previous
* one, nothing happens.
*
* @param text
* Raw text to display in the line
*/
void setText(@NonNull String text);
}
@@ -0,0 +1,107 @@
package me.neznamy.tab.api.scoreboard;
import lombok.NonNull;
import org.jetbrains.annotations.NotNull;
import java.util.List;
/**
* An interface allowing to work with scoreboard, such as adding players,
* removing players and changing lines. New instance can be created using
* {@link ScoreboardManager#createScoreboard(String, String, List)},
* for scoreboards from config {@link ScoreboardManager#getRegisteredScoreboards()}.
*/
@SuppressWarnings("unused") // API class
public interface Scoreboard {
/**
* Returns internal name of this scoreboard. Name is defined in registration,
* scoreboards from config use name they were defined with. This value is
* used internally and in /tab scoreboard announce command.
*
* @return custom name of this scoreboard
*/
@NotNull String getName();
/**
* Returns raw title of this scoreboard. Placeholders stay in their
* raw format.
*
* @return scoreboard title
* @see #setTitle(String)
*/
@NotNull String getTitle();
/**
* Sets title to specified value. Placeholders are refreshed automatically
* with refresh intervals defined in config. No need to call this method
* to try to keep placeholders up to date. Supports RGB codes using any of
* the supported formats.
* <p>
* Length is limited to 32 characters on &lt;1.13. If the limit is exceeded,
* text will be cut to 32 characters.
* <p>
* Calling this method with same title as before will not do anything.
*
* @param title
* New title to use with placeholder support
* @see #getTitle()
*/
void setTitle(@NonNull String title);
/**
* Returns list of lines in this scoreboard in the order they appear
* in game (first line is on top). This list should only be used for reading,
* for adding/removing lines see {@link #addLine(String)} and {@link #removeLine(int)}.
*
* @return list of lines in this scoreboard
* @see #addLine(String)
* @see #removeLine(int)
*/
@NotNull List<Line> getLines();
/**
* Adds line with specified text on the bottom of scoreboard. Supports
* placeholders, which will automatically be refreshed.
*
* @param text
* Text to display
* @see #getLines()
* @see #removeLine(int)
*/
void addLine(@NonNull String text);
/**
* Removes line with specified index. Index starts at {@code 0} and ends at
* {@link #getLines()}.size()-1.
*
* @param index
* Index of line to remove, starting at 0
* @throws IndexOutOfBoundsException
* if the index is out of range (index &lt; 0 || index &gt;= {@link #getLines()}.size())
* @see #getLines()
* @see #addLine(String)
*/
void removeLine(int index);
/**
* Replaces all current lines with the provided list.
* Supports placeholders, which will automatically be refreshed.
* Client can only see up to 15 lines at a time.
* If the new list is identical to the current one, nothing happens.
*
* @param lines
* New list of lines to display
* @throws NullPointerException
* if {@code lines} is {@code null}
* @see #getLines()
* @see #addLine(String)
* @see #removeLine(int)
*/
void setLines(@NonNull List<String> lines);
/**
* Unregisters this scoreboard from all players who can see it.
*/
void unregister();
}
@@ -0,0 +1,193 @@
package me.neznamy.tab.api.scoreboard;
import lombok.NonNull;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.List;
import java.util.Map;
/**
* Interface allowing work with scoreboards, such as creating,
* sending, toggling and modifying.
* <p>
* Instance can be obtained using {@link me.neznamy.tab.api.TabAPI#getScoreboardManager()}.
* This requires the scoreboard feature to be enabled in config,
* the method will return {@code null} otherwise.
*/
@SuppressWarnings("unused") // API class
public interface ScoreboardManager {
/**
* Creates new scoreboard, registers and returns it. {@code name}
* is internal name of the scoreboard, which it will be registered
* with and further work where scoreboard name is used allowed.
* <p>
* Scoreboard {@code title} is limited to 32 characters on &lt;1.13. If needed,
* it will be cut to 32 character for those players (after replacing
* placeholders). RGB is supported using any of the supported formats.
* Placeholders are supported.
* <p>
* {@code lines} will display in the same order as contained in the list.
* Client can only see up to 15 lines at a time, however you can define
* more, if some of them only consist of placeholder that might be empty.
*
* @param name
* Internal name of the scoreboard
* @param title
* The scoreboard title
* @param lines
* Lines of text in scoreboard (supports placeholders)
* @return The new scoreboard with given parameters
* @throws NullPointerException
* if {@code name} or {@code lines} is {@code null}
*/
@NotNull Scoreboard createScoreboard(@NonNull String name, @NonNull String title, @NonNull List<String> lines);
/**
* Returns map of registered scoreboards via config and API.
* Map key is name of scoreboard, which is defined either in config
* or using {@link #createScoreboard(String, String, List)}.
* Map value is reference to the actual scoreboard.
*
* @return map of registered scoreboards
*/
@NotNull Map<String, Scoreboard> getRegisteredScoreboards();
/**
* Removes scoreboard with specified name from list of scoreboards. If it was displayed to anyone,
* it will be removed from their display as well. Then, those players will receive a new scoreboard based
* on configuration.
*
* @param name Name of scoreboard to remove
* @throws IllegalArgumentException
* if scoreboard with such name does not exist
*/
void removeScoreboard(@NonNull String name);
/**
* Removes scoreboard from list of scoreboards. If it was displayed to anyone,
* it will be removed from their display as well. Then, those players will receive a new scoreboard based
* on configuration.
*
* @param scoreboard
* Scoreboard to remove
* @throws IllegalArgumentException
* if specified scoreboard is not registered
*/
void removeScoreboard(@NonNull Scoreboard scoreboard);
/**
* Displays scoreboard to defined player. This will disable all display
* condition checks until the scoreboard is unregistered using
* {@link #resetScoreboard(TabPlayer)}. If the player already sees
* this scoreboard, nothing will happen.
*
* @param player
* Player to send scoreboard to
* @param scoreboard
* Scoreboard to display
* @throws NullPointerException
* if {@code player} or {@code scoreboard} is {@code null}
* @see #hasCustomScoreboard(TabPlayer)
* @see #resetScoreboard(TabPlayer)
*/
void showScoreboard(@NonNull TabPlayer player, @NonNull Scoreboard scoreboard);
/**
* Returns {@code true} if player has custom scoreboard set using
* {@link #showScoreboard(TabPlayer, Scoreboard)}, {@code false} if not.
*
* @param player
* Player to check
* @return {@code true} if player has custom scoreboard set using API,
* {@code false} if not
* @see #showScoreboard(TabPlayer, Scoreboard)
* @see #resetScoreboard(TabPlayer)
*/
boolean hasCustomScoreboard(@NonNull TabPlayer player);
/**
* Hides custom scoreboard sent using {@link #showScoreboard(TabPlayer, Scoreboard)}
* and re-enables internal display logic with conditions. If player does not
* have any forced scoreboard, nothing happens.
*
* @param player
* Player to hide custom scoreboard from
* @see #showScoreboard(TabPlayer, Scoreboard)
* @see #hasCustomScoreboard(TabPlayer)
*/
void resetScoreboard(@NonNull TabPlayer player);
/**
* Returns {@code true} if player has scoreboard enabled, {@code false}
* if disabled (toggled) using either toggle command,
* {@link #toggleScoreboard(TabPlayer, boolean)} or
* {@link #setScoreboardVisible(TabPlayer, boolean, boolean)}.
*
* @param player
* Player to get visibility status of
* @return {@code true} if visible, {@code false} if disabled
* @see #setScoreboardVisible(TabPlayer, boolean, boolean)
* @see #toggleScoreboard(TabPlayer, boolean)
*/
boolean hasScoreboardVisible(@NonNull TabPlayer player);
/**
* Sets scoreboard visibility of player to defined value. If visibility status
* is same as player had before, nothing happens. If this call changes
* visibility, scoreboard is toggled. If {@code sendToggleMessage} is {@code true},
* toggle message defined in configuration is sent.
*
* @param player
* Player to set visibility for
* @param visible
* New visibility status
* @param sendToggleMessage
* whether to send toggle message if status changed or not
* @see #toggleScoreboard(TabPlayer, boolean)
* @see #hasScoreboardVisible(TabPlayer)
*/
void setScoreboardVisible(@NonNull TabPlayer player, boolean visible, boolean sendToggleMessage);
/**
* Toggles scoreboard for specified player. If player had scoreboard visible,
* hides it. If hidden, shows it. If {@code sendToggleMessage} is {@code true},
* toggle message defined in configuration is sent.
*
* @param player
* Player to toggle scoreboard for
* @param sendToggleMessage
* Whether to send toggle message or not
* @see #hasScoreboardVisible(TabPlayer)
* @see #setScoreboardVisible(TabPlayer, boolean, boolean)
*/
void toggleScoreboard(@NonNull TabPlayer player, boolean sendToggleMessage);
/**
* Temporarily displays scoreboard to all players for specified amount of
* time (in milliseconds). Scoreboard name is either defined in config, or
* through API in {@link #createScoreboard(String, String, List)}.
*
* @param scoreboard
* Scoreboard from config or registered via API
* @param duration
* Duration in milliseconds
* @throws IllegalArgumentException
* if no scoreboard was found with such name or {@code duration}
* is &lt; 0.
*/
void announceScoreboard(@NonNull String scoreboard, int duration);
/**
* Returns player's currently displayed scoreboard. This can be either with
* configuration, overridden with commands or the API. Will return {@code null}
* if player does not see any scoreboard due to not meeting any display condition.
*
* @param player
* player to get active scoreboard of
* @return player's active scoreboard or {@code null} if player has no scoreboard
*/
@Nullable Scoreboard getActiveScoreboard(@NonNull TabPlayer player);
}
@@ -0,0 +1,58 @@
package me.neznamy.tab.api.tablist;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.Nullable;
/**
* Interface allowing to send header/footer to players.
* <p>
* Instance can be obtained using {@link TabAPI#getHeaderFooterManager()}.
* This requires the Header/footer feature to be enabled in config, otherwise
* the method will return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface HeaderFooterManager {
/**
* Sets raw value of header to specified value. This overrides plugin
* configuration until reset is called. Has full placeholder support
* and will send update packet whenever a placeholder used inside
* changes its value. Use {@code null} to reset value back to original.
*
* @param player
* Player to set header for
* @param header
* Raw header value
*/
void setHeader(@NonNull TabPlayer player, @Nullable String header);
/**
* Sets raw value of footer to specified value. This overrides plugin
* configuration until reset is called. Has full placeholder support
* and will send update packet whenever a placeholder used inside
* changes its value. Use {@code null} to reset value back to original.
*
* @param player
* Player to set header for
* @param footer
* Raw footer value
*/
void setFooter(@NonNull TabPlayer player, @Nullable String footer);
/**
* Sets raw value of header and footer to specified values. This overrides plugin
* configuration until reset is called. Has full placeholder support
* and will send update packet whenever a placeholder used inside
* changes its value. Use {@code null} to reset value back to original.
*
* @param player
* Player to set header for
* @param header
* Raw header value
* @param footer
* Raw footer value
*/
void setHeaderAndFooter(@NonNull TabPlayer player, @Nullable String header, @Nullable String footer);
}
@@ -0,0 +1,46 @@
package me.neznamy.tab.api.tablist;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* Interface for managing player sorting by directly configuring
* team names of players. Instance can be obtained using
* {@link TabAPI#getSortingManager()}. If the feature is disabled,
* it will return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface SortingManager {
/**
* Forces new team name for the player until this method is called again with null argument and
* performs all actions to change player's team name
*
* @param player
* player to set team name of
* @param teamName
* forced team name
*/
void forceTeamName(@NonNull TabPlayer player, @Nullable String teamName);
/**
* Returns forced team name of player or null if not forced
*
* @param player
* player to check forced team name of
* @return forced team name of player or null if not forced
*/
@Nullable String getForcedTeamName(@NonNull TabPlayer player);
/**
* Returns original team name of the player set by the plugin.
*
* @param player
* Player to get team name of
* @return Player's team name based on configuration.
*/
@NotNull String getOriginalTeamName(@NonNull TabPlayer player);
}
@@ -0,0 +1,202 @@
package me.neznamy.tab.api.tablist;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* An interface allowing to modify TabList display names
* of players.
* <p>
* Instance can be obtained using {@link TabAPI#getTabListFormatManager()}.
* This requires the feature to be enabled in config, otherwise the method will
* return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface TabListFormatManager {
/**
* Changes player's prefix to provided value. Supports placeholders,
* as well as any supported RGB formats. Use {@code null} to reset
* value back to original.
*
* @param player
* player to change prefix of
* @param prefix
* new prefix value
* @see #getCustomPrefix(TabPlayer)
* @see #getOriginalRawPrefix(TabPlayer)
*/
void setPrefix(@NonNull TabPlayer player, @Nullable String prefix);
/**
* Changes player's name to provided value. Supports placeholders,
* as well as any supported RGB formats. Use {@code null} to reset
* value back to original.
*
* @param player
* player to change prefix of
* @param customName
* new customName value
* @see #getCustomName(TabPlayer)
* @see #getOriginalRawName(TabPlayer)
*/
void setName(@NonNull TabPlayer player, @Nullable String customName);
/**
* Changes player's suffix to provided value. Supports placeholders,
* as well as any supported RGB formats. Use {@code null} to reset
* value back to original.
*
* @param player
* player to change prefix of
* @param suffix
* new suffix value
* @see #getCustomSuffix(TabPlayer)
* @see #getOriginalRawSuffix(TabPlayer)
*/
void setSuffix(@NonNull TabPlayer player, @Nullable String suffix);
/**
* Returns prefix assigned using {@link #setPrefix(TabPlayer, String)} method.
* If the method was not used, {@code null} is returned.
*
* @param player
* player to get custom prefix of
* @return player's custom prefix or {@code null} if not defined
* @see #setPrefix(TabPlayer, String)
* @see #getOriginalRawPrefix(TabPlayer)
*/
@Nullable String getCustomPrefix(@NonNull TabPlayer player);
/**
* Returns custom name assigned using {@link #setName(TabPlayer, String)} method.
* If the method was not used, {@code null} is returned.
*
* @param player
* player to get custom name of
* @return player's custom name or {@code null} if not defined
* @see #setName(TabPlayer, String)
* @see #getOriginalName(TabPlayer)
*/
@Nullable String getCustomName(@NonNull TabPlayer player);
/**
* Returns suffix assigned using {@link #setSuffix(TabPlayer, String)} method.
* If the method was not used, {@code null} is returned.
*
* @param player
* player to get custom suffix of
* @return player's custom suffix or {@code null} if not defined
* @see #setSuffix(TabPlayer, String)
* @see #getOriginalSuffix(TabPlayer)
*/
@Nullable String getCustomSuffix(@NonNull TabPlayer player);
/**
* Returns player's original prefix applied using plugin's internal logic.
* This value is not affected by API calls in any way.
*
* @param player
* player to get original prefix of
* @return player's original prefix
* @see #setPrefix(TabPlayer, String)
* @see #getCustomPrefix(TabPlayer)
* @deprecated Use {@link #getOriginalRawPrefix(TabPlayer)} instead.
*/
@NotNull
@Deprecated
String getOriginalPrefix(@NonNull TabPlayer player);
/**
* Returns player's original name applied using plugin's internal logic.
* This value is not affected by API calls in any way.
*
* @param player
* player to get original name of
* @return player's original name
* @see #setName(TabPlayer, String)
* @see #getCustomName(TabPlayer)
* @deprecated Use {@link #getOriginalRawName(TabPlayer)} instead.
*/
@NotNull
@Deprecated
String getOriginalName(@NonNull TabPlayer player);
/**
* Returns player's original suffix applied using plugin's internal logic.
* This value is not affected by API calls in any way.
*
* @param player
* player to get original suffix of
* @return player's original suffix
* @see #setSuffix(TabPlayer, String)
* @see #getCustomSuffix(TabPlayer)
* @deprecated Use {@link #getOriginalRawSuffix(TabPlayer)} instead.
*/
@NotNull
@Deprecated
String getOriginalSuffix(@NonNull TabPlayer player);
/**
* Returns original prefix assigned by the plugin using internal logic.
* @param player
* Player to get original prefix of
* @return Original prefix assigned by the plugin's internal logic.
* @see #getCustomPrefix(TabPlayer)
*/
@NotNull
String getOriginalRawPrefix(@NonNull TabPlayer player);
/**
* Returns original name assigned by the plugin using internal logic.
* @param player
* Player to get original name of
* @return Original name assigned by the plugin's internal logic.
* @see #getCustomName(TabPlayer)
*/
@NotNull
String getOriginalRawName(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic.
* @param player
* Player to get original suffix of
* @return Original suffix assigned by the plugin's internal logic.
* @see #getCustomSuffix(TabPlayer)
*/
@NotNull
String getOriginalRawSuffix(@NonNull TabPlayer player);
/**
* Returns original prefix assigned by the plugin using internal logic with all placeholders replaced.
* @param player
* Player to get replaced original prefix of
* @return Original prefix assigned by the plugin's internal logic.
* @see #getCustomPrefix(TabPlayer)
*/
@NotNull
String getOriginalReplacedPrefix(@NonNull TabPlayer player);
/**
* Returns original name assigned by the plugin using internal logic with all placeholders replaced.
* @param player
* Player to get replaced original name of
* @return Original name assigned by the plugin's internal logic.
* @see #getCustomName(TabPlayer)
*/
@NotNull
String getOriginalReplacedName(@NonNull TabPlayer player);
/**
* Returns original suffix assigned by the plugin using internal logic with all placeholders replaced.
* @param player
* Player to get replaced original suffix of
* @return Original suffix assigned by the plugin's internal logic.
* @see #getCustomSuffix(TabPlayer)
*/
@NotNull
String getOriginalReplacedSuffix(@NonNull TabPlayer player);
}
@@ -0,0 +1,93 @@
package me.neznamy.tab.api.tablist.layout;
import lombok.NonNull;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* Interface representing a layout.
*/
@SuppressWarnings("unused") // API class
public interface Layout {
/**
* Returns name of the layout.
*
* @return name of the layout
*/
@NotNull String getName();
/**
* Adds fixed slot with specified parameters
*
* @param slot
* Slot (1-80)
* @param text
* Text to display
*/
void addFixedSlot(int slot, @NonNull String text);
/**
* Adds fixed slot with specified parameters
*
* @param slot
* Slot (1-80)
* @param text
* Text to display
* @param skin
* Skin definition like in config
*/
void addFixedSlot(int slot, @NonNull String text, @NonNull String skin);
/**
* Adds fixed slot with specified parameters
*
* @param slot
* Slot (1-80)
* @param text
* Text to display
* @param ping
* Slot's ping
*/
void addFixedSlot(int slot, @NonNull String text, int ping);
/**
* Adds fixed slot with specified parameters
*
* @param slot
* Slot (1-80)
* @param text
* Text to display
* @param skin
* Skin definition like in config
* @param ping
* Slot's ping
*/
void addFixedSlot(int slot, @NonNull String text, @NonNull String skin, int ping);
/**
* Adds fixed slot with specified parameters
*
* @param slot
* Slot (1-80)
* @param text
* Text to display
* @param skin
* Skin definition like in config
* @param ping
* Slot's ping, accepts placeholders that evaluate to a number
*/
void addFixedSlot(int slot, @NonNull String text, @NonNull String skin, @NonNull String ping);
/**
* Adds a player group.
*
* @param condition
* Condition that must be met for player to appear in the group.
* May be null for no requirement. Syntax is like in config -
* either condition name or short format.
* @param slots
* Slots for this player group
*/
void addGroup(@Nullable String condition, int[] slots);
}
@@ -0,0 +1,70 @@
package me.neznamy.tab.api.tablist.layout;
import lombok.NonNull;
import me.neznamy.tab.api.TabAPI;
import me.neznamy.tab.api.TabPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* Interface for working with layouts. Instance can be obtained using
* {@link TabAPI#getLayoutManager()}. If the feature is disabled in
* config, it will return {@code null}.
*/
@SuppressWarnings("unused") // API class
public interface LayoutManager {
/**
* Creates new layout
*
* @param name
* Unique layout name
* @return Created layout
*/
@NotNull
Layout createNewLayout(@NonNull String name);
/**
* Creates new layout with given name and slot count (1.19.3+ only).
*
* @param name
* Unique layout name
* @param slotCount
* Amount of slots to use for 1.19.3+ players
* @return Created layout
*/
@NotNull
Layout createNewLayout(@NonNull String name, int slotCount);
/**
* Returns defined layout from config by name. If no such layout is defined in config,
* {@code null} is returned.
*
* @param name
* Name of layout defined in config
* @return Layout defined in config by name or {@code null} if no such layout is defined
*/
@Nullable
Layout getLayout(@NonNull String name);
/**
* Sends layout to player. Set to {@code null} to make player not see
* any layout, but default TabList instead.
*
* @param player
* Player to send layout to
* @param layout
* Layout to send
* @see #resetLayout(TabPlayer)
*/
void sendLayout(@NonNull TabPlayer player, @Nullable Layout layout);
/**
* Reset layout back to original one based on configuration.
*
* @param player
* Player to reset layout for
* @see #sendLayout(TabPlayer, Layout)
*/
void resetLayout(@NonNull TabPlayer player);
}
+8
View File
@@ -0,0 +1,8 @@
plugins {
`kotlin-dsl`
}
dependencies {
implementation("com.gradleup.shadow:shadow-gradle-plugin:9.4.0")
implementation("io.freefair.gradle:lombok-plugin:9.2.0")
}
+12
View File
@@ -0,0 +1,12 @@
rootProject.name = "build-logic"
dependencyResolutionManagement {
repositories {
maven("https://maven.fabricmc.net/")
maven("https://maven.architectury.dev/")
maven("https://maven.minecraftforge.net/")
maven("https://maven.neoforged.net/releases/")
gradlePluginPortal()
mavenCentral()
}
}
@@ -0,0 +1,37 @@
import org.apache.tools.ant.filters.ReplaceTokens
plugins {
`java-library`
id("io.freefair.lombok")
}
tasks {
processResources {
filter<ReplaceTokens>("tokens" to mapOf(
"id" to rootProject.ext.get("id")!!.toString(),
"name" to rootProject.name,
"version" to project.version,
"description" to project.description,
"website" to rootProject.ext.get("website")!!.toString(),
"author" to rootProject.ext.get("author")!!.toString()
))
}
javadoc {
// This saves a decent bit of processing power on slow machines
enabled = false
options.encoding = Charsets.UTF_8.name()
(options as StandardJavadocDocletOptions).addStringOption("Xdoclint:none", "-quiet")
}
compileJava {
options.encoding = Charsets.UTF_8.name()
options.release.set(17)
options.compilerArgs.addAll(listOf("-nowarn", "-Xlint:-unchecked", "-Xlint:-deprecation"))
}
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
vendor.set(JvmVendorSpec.GRAAL_VM)
}
}
Whitespace-only changes.
@@ -0,0 +1,26 @@
plugins {
id("tab.standard-conventions")
id("com.gradleup.shadow")
}
tasks.withType<Zip>().configureEach {
isZip64 = true
}
tasks {
shadowJar {
archiveFileName.set("${rootProject.name}-${project.name}-${project.version}.jar")
relocate("org.bstats", "me.neznamy.tab.libs.org.bstats")
relocate("org.json.simple", "me.neznamy.tab.libs.org.json.simple")
relocate("net.kyori.event", "me.neznamy.tab.libs.net.kyori.event")
relocate("me.neznamy.yamlassist", "me.neznamy.tab.libs.me.neznamy.yamlassist")
relocate("org.yaml.snakeyaml", "me.neznamy.tab.libs.org.yaml.snakeyaml")
relocate("redis.clients.jedis", "me.neznamy.tab.libs.redis.clients.jedis")
relocate("org.apache.commons.pool2", "me.neznamy.tab.libs.org.apache.commons.pool2")
relocate("org.json", "me.neznamy.tab.libs.org.json")
relocate("com.rabbitmq", "me.neznamy.tab.libs.com.rabbitmq")
relocate("com.saicone.delivery4j", "me.neznamy.tab.libs.com.saicone.delivery4j")
relocate("com.mysql", "me.neznamy.tab.libs.com.mysql")
relocate("com.google.protobuf", "me.neznamy.tab.libs.com.google.protobuf")
}
}
@@ -0,0 +1,8 @@
plugins {
id("tab.base-conventions")
}
java {
withSourcesJar()
withJavadocJar()
}
+45
View File
@@ -0,0 +1,45 @@
plugins {
eclipse
id("tab.parent")
}
allprojects {
group = "me.neznamy"
version = "5.9.9"
description = "An all-in-one solution that works"
ext.set("id", "tab")
ext.set("website", "https://git.trueog.net/trueog/TAB-OG")
ext.set("author", "NEZNAMY")
ext.set("credits", "Joseph T. McQuigg (JT122406)")
}
val platformPaths = setOf(
":bukkit",
":bukkit:v1_19_R3",
":bungeecord",
":velocity"
)
val specialPaths = setOf(
":api",
":shared"
)
subprojects {
when (path) {
in platformPaths -> plugins.apply("tab.platform-conventions")
in specialPaths -> plugins.apply("tab.standard-conventions")
else -> plugins.apply("tab.base-conventions")
}
}
val copyShadowJar by tasks.registering(Copy::class) {
dependsOn(":jar:shadowJar")
from(project(":jar").tasks.named("shadowJar"))
into(layout.buildDirectory.dir("libs"))
}
tasks.register("build") {
dependsOn(copyShadowJar)
}
+14
View File
@@ -0,0 +1,14 @@
dependencies {
api(projects.shared)
implementation("org.bstats:bstats-bukkit:3.1.0")
compileOnly("org.purpurmc.purpur:purpur-api:1.19.4-R0.1-SNAPSHOT")
compileOnly("me.clip:placeholderapi:2.11.6")
compileOnly("LibsDisguises:LibsDisguises:10.0.21") {
exclude("org.spigotmc", "spigot")
exclude("org.spigotmc", "spigot-api")
exclude("com.github.dmulloy2", "ProtocolLib")
exclude("org.ow2.asm", "asm")
exclude("net.md-5", "bungeecord-chat")
}
compileOnly("com.github.LeonMangler:PremiumVanishAPI:2.8.8")
}
+28
View File
@@ -0,0 +1,28 @@
plugins {
id("io.papermc.paperweight.userdev") version "2.0.0-beta.19"
}
repositories {
maven("https://jitpack.io") // YamlAssist
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.viaversion.com/")
maven {
name = "luck-repo"
url = uri("https://repo.lucko.me/")
content {
includeModule("me.lucko", "spark-api")
}
}
}
val version = "1.20.6-R0.1-SNAPSHOT" // 1.20.5 has a broken dependency, but there were no changes, so it's ok
dependencies {
implementation(projects.bukkit)
paperweight.paperDevBundle(version)
compileOnly("io.papermc.paper:paper-api:${version}")
}
tasks.compileJava {
options.release.set(21)
}
@@ -0,0 +1,64 @@
package me.neznamy.tab.platforms.bukkit.paper_1_20_5;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import net.minecraft.network.chat.*;
import net.minecraft.resources.ResourceLocation;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct mojang-mapped code.
*/
public class NMSComponentConverter extends ComponentConverter<Component> {
@Override
@NotNull
public Component newTextComponent(@NotNull String text) {
return Component.literal(text);
}
@Override
@NotNull
public Component newTranslatableComponent(@NotNull String key) {
return Component.translatable(key);
}
@Override
@NotNull
public Component newKeybindComponent(@NotNull String keybind) {
return Component.keybind(keybind);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabAtlasSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabPlayerSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
public void applyStyle(@NotNull Component nmsComponent, @NotNull TabStyle modifier) {
Style style = Style.EMPTY
.withColor(modifier.getColor() == null ? null : TextColor.fromRgb(modifier.getColor().getRgb()))
.withBold(modifier.getBold())
.withItalic(modifier.getItalic())
.withUnderlined(modifier.getUnderlined())
.withStrikethrough(modifier.getStrikethrough())
.withObfuscated(modifier.getObfuscated())
.withFont(modifier.getFont() == null ? null : ResourceLocation.tryParse(modifier.getFont()));
((MutableComponent)nmsComponent).setStyle(style);
}
@Override
public void addSibling(@NotNull Component parent, @NotNull Component child) {
((MutableComponent)parent).append(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.paper_1_20_5;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct Mojang-mapped NMS code for paper 1.20.5 - 1.21.1.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().connection.connection.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return player.getPlayer().getPing();
}
}
@@ -0,0 +1,176 @@
package me.neznamy.tab.platforms.bukkit.paper_1_20_5;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.ChatFormatting;
import net.minecraft.network.chat.numbers.FixedFormat;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.*;
import net.minecraft.world.scores.PlayerTeam;
import net.minecraft.world.scores.Scoreboard;
import net.minecraft.world.scores.criteria.ObjectiveCriteria;
import net.minecraft.world.scores.criteria.ObjectiveCriteria.RenderType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
import java.util.Optional;
/**
* Scoreboard implementation using direct mojang-mapped code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ChatFormatting[] formats = ChatFormatting.values();
private static final net.minecraft.world.scores.Team.CollisionRule[] collisions = net.minecraft.world.scores.Team.CollisionRule.values();
private static final net.minecraft.world.scores.Team.Visibility[] visibilities = net.minecraft.world.scores.Team.Visibility.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final Field players = ReflectionUtils.getOnlyField(ClientboundSetPlayerTeamPacket.class, Collection.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = new net.minecraft.world.scores.Objective(
dummyScoreboard,
objective.getName(),
ObjectiveCriteria.DUMMY,
objective.getTitle().convert(),
RenderType.values()[objective.getHealthDisplay().ordinal()],
false,
objective.getNumberFormat() == null ? null : objective.getNumberFormat().toFixedFormat(FixedFormat::new)
);
objective.setPlatformObjective(obj);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new ClientboundSetDisplayObjectivePacket(
net.minecraft.world.scores.DisplaySlot.values()[objective.getDisplaySlot().ordinal()],
(net.minecraft.world.scores.Objective) objective.getPlatformObjective()
));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new ClientboundSetObjectivePacket((net.minecraft.world.scores.Objective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = (net.minecraft.world.scores.Objective) objective.getPlatformObjective();
obj.setDisplayName(objective.getTitle().convert());
obj.setRenderType(RenderType.values()[objective.getHealthDisplay().ordinal()]);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
sendPacket(new ClientboundSetScorePacket(
score.getHolder(),
score.getObjective().getName(),
score.getValue(),
Optional.ofNullable(score.getDisplayName() == null ? null : score.getDisplayName().convert()),
Optional.ofNullable(score.getNumberFormat() == null ? null : score.getNumberFormat().toFixedFormat(FixedFormat::new))
));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new ClientboundResetScorePacket(score.getHolder(), score.getObjective().getName()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new PlayerTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.getPlayers().addAll(team.getPlayers());
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket(t, true));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(ClientboundSetPlayerTeamPacket.createRemovePacket((PlayerTeam) team.getPlatformTeam()));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket((PlayerTeam) team.getPlatformTeam(), false));
}
private void updateTeamProperties(@NonNull Team team) {
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setColor(formats[team.getColor().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setPlayerPrefix(team.getPrefix().convert());
t.setPlayerSuffix(team.getSuffix().convert());
}
@Override
@SneakyThrows
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundSetDisplayObjectivePacket display) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, display.getSlot().ordinal(), display.getObjectiveName());
}
if (packet instanceof ClientboundSetObjectivePacket objective) {
TAB.getInstance().getFeatureManager().onObjective(player, objective.getMethod(), objective.getObjectiveName());
}
if (packet instanceof ClientboundSetPlayerTeamPacket team) {
int action = getMethod(team);
if (action != TeamAction.UPDATE) {
players.set(team, onTeamPacket(action, team.getName(), team.getPlayers() == null ? Collections.emptyList() : team.getPlayers()));
}
}
return packet;
}
private int getMethod(@NonNull ClientboundSetPlayerTeamPacket team) {
if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 0;
} else if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 1;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 3;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 4;
} else {
return 2;
}
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.sendPacket(packet);
}
}
@@ -0,0 +1,200 @@
package me.neznamy.tab.platforms.bukkit.paper_1_20_5;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import lombok.NonNull;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import net.minecraft.network.chat.Component;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import net.minecraft.network.protocol.game.ClientboundTabListPacket;
import net.minecraft.world.level.GameType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.*;
/**
* TabList implementation using direct mojang-mapped code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> addPlayer = EnumSet.allOf(ClientboundPlayerInfoUpdatePacket.Action.class);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateDisplayName = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateLatency = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateGameMode = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListed = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void removeEntry(@NonNull UUID entry) {
sendPacket(new ClientboundPlayerInfoRemovePacket(Collections.singletonList(entry)));
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(updateDisplayName, entry, "", null, false, 0, 0, displayName);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(updateLatency, entry, "", null, false, latency, 0, null);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(updateGameMode, entry, "", null, false, 0, gameMode, null);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
sendPacket(updateListed, entry, "", null, listed, 0, 0, null);
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
// Added in 1.21.2
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
// Added in 1.21.4
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(addPlayer, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.isListed(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(new ClientboundTabListPacket(header.convert(), footer.convert()));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().getProperties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.value(), property.signature());
}
@Override
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundTabListPacket tablist) {
if (header == null || footer == null) return packet;
if (tablist.header() != header.convert() || tablist.footer() != footer.convert()) {
return new ClientboundTabListPacket(header.convert(), footer.convert());
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket info) {
EnumSet<ClientboundPlayerInfoUpdatePacket.Action> actions = info.actions();
List<ClientboundPlayerInfoUpdatePacket.Entry> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : info.entries()) {
boolean rewriteEntry = false;
Component displayName = nmsData.displayName();
int latency = nmsData.latency();
int gameMode = nmsData.gameMode().getId();
boolean listed = nmsData.listed();
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME)) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(nmsData.profileId());
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE)) {
if (getBlockedSpectators().contains(nmsData.profileId()) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY)) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED)) {
if (allPlayersHidden && nmsData.profileId().getMostSignificantBits() != 0) { // Filter out layout entries
listed = false;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, nmsData.profileId(), nmsData.profile().getName());
}
updatedList.add(rewriteEntry ? new ClientboundPlayerInfoUpdatePacket.Entry(
nmsData.profileId(), nmsData.profile(), listed, latency, GameType.byId(gameMode), displayName,
nmsData.chatSession()
) : nmsData);
}
if (rewritePacket) return new ClientboundPlayerInfoUpdatePacket(actions, updatedList);
}
return packet;
}
private void sendPacket(@NonNull EnumSet<ClientboundPlayerInfoUpdatePacket.Action> action, @NonNull UUID id, @NonNull String name, @Nullable Skin skin,
boolean listed, int latency, int gameMode, @Nullable TabComponent displayName) {
ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(action, new ClientboundPlayerInfoUpdatePacket.Entry(
id,
action.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER) ? createProfile(id, name, skin) : null,
listed,
latency,
GameType.byId(gameMode),
displayName == null ? null : displayName.convert(),
null
));
sendPacket(packet);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
GameProfile profile = new GameProfile(id, name);
if (skin != null) {
profile.getProperties().put(TabList.TEXTURES_PROPERTY,
new Property(TabList.TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return profile;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.platforms.bukkit.paper_1_20_5;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
@Override
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof ClientboundPlayerInfoRemovePacket remove) {
for (UUID id : remove.profileIds()) {
tablistEntries.remove(id);
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket update) {
if (update.actions().contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : update.entries()) {
tablistEntries.add(nmsData.profileId());
}
}
}
}
}
+28
View File
@@ -0,0 +1,28 @@
plugins {
id("io.papermc.paperweight.userdev") version "2.0.0-beta.19"
}
repositories {
maven("https://jitpack.io") // YamlAssist
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.viaversion.com/")
maven {
name = "luck-repo"
url = uri("https://repo.lucko.me/")
content {
includeModule("me.lucko", "spark-api")
}
}
}
val version = "1.21.11-R0.1-SNAPSHOT"
dependencies {
implementation(projects.bukkit)
paperweight.paperDevBundle(version)
compileOnly("io.papermc.paper:paper-api:${version}")
}
tasks.compileJava {
options.release.set(21)
}
@@ -0,0 +1,84 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_11;
import com.google.common.collect.ImmutableMultimap;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import com.mojang.authlib.properties.PropertyMap;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import me.neznamy.tab.shared.platform.TabList;
import net.minecraft.network.chat.*;
import net.minecraft.network.chat.contents.objects.AtlasSprite;
import net.minecraft.network.chat.contents.objects.PlayerSprite;
import net.minecraft.resources.Identifier;
import net.minecraft.world.item.component.ResolvableProfile;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct mojang-mapped code.
*/
public class NMSComponentConverter extends ComponentConverter<Component> {
@Override
@NotNull
public Component newTextComponent(@NotNull String text) {
return Component.literal(text);
}
@Override
@NotNull
public Component newTranslatableComponent(@NotNull String key) {
return Component.translatable(key);
}
@Override
@NotNull
public Component newKeybindComponent(@NotNull String keybind) {
return Component.keybind(keybind);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabAtlasSprite sprite) {
return Component.object(new AtlasSprite(Identifier.parse(sprite.getAtlas()), Identifier.parse(sprite.getSprite())));
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabPlayerSprite sprite) {
ResolvableProfile profile;
if (sprite.getId() != null) {
profile = ResolvableProfile.createUnresolved(sprite.getId());
} else if (sprite.getName() != null) {
profile = ResolvableProfile.createUnresolved(sprite.getName());
} else if (sprite.getSkin() != null) {
ImmutableMultimap.Builder<String, Property> builder = ImmutableMultimap.builder();
builder.put(TabList.TEXTURES_PROPERTY, new Property(TabList.TEXTURES_PROPERTY, sprite.getSkin().getValue(), sprite.getSkin().getSignature()));
profile = ResolvableProfile.createResolved(new GameProfile(NIL_UUID, "", new PropertyMap(builder.build())));
} else {
throw new IllegalStateException("Player head component does not have id, name or skin set");
}
return Component.object(new PlayerSprite(profile, sprite.isShowHat()));
}
@Override
public void applyStyle(@NotNull Component nmsComponent, @NotNull TabStyle modifier) {
Style style = Style.EMPTY
.withColor(modifier.getColor() == null ? null : TextColor.fromRgb(modifier.getColor().getRgb()))
.withBold(modifier.getBold())
.withItalic(modifier.getItalic())
.withUnderlined(modifier.getUnderlined())
.withStrikethrough(modifier.getStrikethrough())
.withObfuscated(modifier.getObfuscated())
.withFont(modifier.getFont() == null ? null : new FontDescription.Resource(Identifier.parse(modifier.getFont())));
if (modifier.getShadowColor() != null) style = style.withShadowColor(modifier.getShadowColor()); // withShadowColor takes int instead of Integer, bug?
((MutableComponent)nmsComponent).setStyle(style);
}
@Override
public void addSibling(@NotNull Component parent, @NotNull Component child) {
((MutableComponent)parent).append(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_11;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct Mojang-mapped NMS code for paper 1.21.11.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().connection.connection.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return player.getPlayer().getPing();
}
}
@@ -0,0 +1,176 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_11;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.ChatFormatting;
import net.minecraft.network.chat.numbers.FixedFormat;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.*;
import net.minecraft.world.scores.PlayerTeam;
import net.minecraft.world.scores.Scoreboard;
import net.minecraft.world.scores.criteria.ObjectiveCriteria;
import net.minecraft.world.scores.criteria.ObjectiveCriteria.RenderType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
import java.util.Optional;
/**
* Scoreboard implementation using direct mojang-mapped code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ChatFormatting[] formats = ChatFormatting.values();
private static final net.minecraft.world.scores.Team.CollisionRule[] collisions = net.minecraft.world.scores.Team.CollisionRule.values();
private static final net.minecraft.world.scores.Team.Visibility[] visibilities = net.minecraft.world.scores.Team.Visibility.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final Field players = ReflectionUtils.getOnlyField(ClientboundSetPlayerTeamPacket.class, Collection.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = new net.minecraft.world.scores.Objective(
dummyScoreboard,
objective.getName(),
ObjectiveCriteria.DUMMY,
objective.getTitle().convert(),
RenderType.values()[objective.getHealthDisplay().ordinal()],
false,
objective.getNumberFormat() == null ? null : objective.getNumberFormat().toFixedFormat(FixedFormat::new)
);
objective.setPlatformObjective(obj);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new ClientboundSetDisplayObjectivePacket(
net.minecraft.world.scores.DisplaySlot.values()[objective.getDisplaySlot().ordinal()],
(net.minecraft.world.scores.Objective) objective.getPlatformObjective()
));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new ClientboundSetObjectivePacket((net.minecraft.world.scores.Objective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = (net.minecraft.world.scores.Objective) objective.getPlatformObjective();
obj.setDisplayName(objective.getTitle().convert());
obj.setRenderType(RenderType.values()[objective.getHealthDisplay().ordinal()]);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
sendPacket(new ClientboundSetScorePacket(
score.getHolder(),
score.getObjective().getName(),
score.getValue(),
Optional.ofNullable(score.getDisplayName() == null ? null : score.getDisplayName().convert()),
Optional.ofNullable(score.getNumberFormat() == null ? null : score.getNumberFormat().toFixedFormat(FixedFormat::new))
));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new ClientboundResetScorePacket(score.getHolder(), score.getObjective().getName()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new PlayerTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.getPlayers().addAll(team.getPlayers());
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket(t, true));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(ClientboundSetPlayerTeamPacket.createRemovePacket((PlayerTeam) team.getPlatformTeam()));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket((PlayerTeam) team.getPlatformTeam(), false));
}
private void updateTeamProperties(@NonNull Team team) {
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setColor(formats[team.getColor().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setPlayerPrefix(team.getPrefix().convert());
t.setPlayerSuffix(team.getSuffix().convert());
}
@Override
@SneakyThrows
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundSetDisplayObjectivePacket display) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, display.getSlot().ordinal(), display.getObjectiveName());
}
if (packet instanceof ClientboundSetObjectivePacket objective) {
TAB.getInstance().getFeatureManager().onObjective(player, objective.getMethod(), objective.getObjectiveName());
}
if (packet instanceof ClientboundSetPlayerTeamPacket team) {
int action = getMethod(team);
if (action != TeamAction.UPDATE) {
players.set(team, onTeamPacket(action, team.getName(), team.getPlayers() == null ? Collections.emptyList() : team.getPlayers()));
}
}
return packet;
}
private int getMethod(@NonNull ClientboundSetPlayerTeamPacket team) {
if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 0;
} else if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 1;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 3;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 4;
} else {
return 2;
}
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,204 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_11;
import com.google.common.collect.ImmutableMultimap;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import com.mojang.authlib.properties.PropertyMap;
import lombok.NonNull;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import net.minecraft.network.chat.Component;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import net.minecraft.network.protocol.game.ClientboundTabListPacket;
import net.minecraft.world.level.GameType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.*;
/**
* TabList implementation using direct mojang-mapped code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> addPlayer = EnumSet.allOf(ClientboundPlayerInfoUpdatePacket.Action.class);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateDisplayName = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateLatency = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateGameMode = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListed = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListOrder = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LIST_ORDER);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateHat = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_HAT);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void removeEntry(@NonNull UUID entry) {
sendPacket(new ClientboundPlayerInfoRemovePacket(Collections.singletonList(entry)));
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(updateDisplayName, entry, "", null, false, 0, 0, displayName, 0, false);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(updateLatency, entry, "", null, false, latency, 0, null, 0, false);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(updateGameMode, entry, "", null, false, 0, gameMode, null, 0, false);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
sendPacket(updateListed, entry, "", null, listed, 0, 0, null, 0, false);
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
sendPacket(updateListOrder, entry, "", null, false, 0, 0, null, listOrder, false);
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
sendPacket(updateHat, entry, "", null, false, 0, 0, null, 0, showHat);
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(addPlayer, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.isListed(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName(), entry.getListOrder(), entry.isShowHat());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(new ClientboundTabListPacket(header.convert(), footer.convert()));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().properties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.value(), property.signature());
}
@Override
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundTabListPacket tablist) {
if (header == null || footer == null) return packet;
if (tablist.header() != header.convert() || tablist.footer() != footer.convert()) {
return new ClientboundTabListPacket(header.convert(), footer.convert());
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket info) {
EnumSet<ClientboundPlayerInfoUpdatePacket.Action> actions = info.actions();
List<ClientboundPlayerInfoUpdatePacket.Entry> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : info.entries()) {
boolean rewriteEntry = false;
Component displayName = nmsData.displayName();
int latency = nmsData.latency();
int gameMode = nmsData.gameMode().getId();
boolean listed = nmsData.listed();
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME)) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(nmsData.profileId());
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE)) {
if (getBlockedSpectators().contains(nmsData.profileId()) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY)) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED)) {
if (allPlayersHidden && nmsData.profileId().getMostSignificantBits() != 0) { // Filter out layout entries
listed = false;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, nmsData.profileId(), nmsData.profile().name());
}
updatedList.add(rewriteEntry ? new ClientboundPlayerInfoUpdatePacket.Entry(
nmsData.profileId(), nmsData.profile(), listed, latency, GameType.byId(gameMode), displayName,
nmsData.showHat(), nmsData.listOrder(), nmsData.chatSession()
) : nmsData);
}
if (rewritePacket) return new ClientboundPlayerInfoUpdatePacket(actions, updatedList);
}
return packet;
}
private void sendPacket(@NonNull EnumSet<ClientboundPlayerInfoUpdatePacket.Action> action, @NonNull UUID id, @NonNull String name, @Nullable Skin skin,
boolean listed, int latency, int gameMode, @Nullable TabComponent displayName, int listOrder, boolean showHat) {
ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(action, new ClientboundPlayerInfoUpdatePacket.Entry(
id,
action.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER) ? createProfile(id, name, skin) : null,
listed,
latency,
GameType.byId(gameMode),
displayName == null ? null : displayName.convert(),
showHat,
listOrder,
null
));
sendPacket(packet);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
ImmutableMultimap.Builder<String, Property> builder = ImmutableMultimap.builder();
if (skin != null) {
builder.put(TEXTURES_PROPERTY, new Property(TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return new GameProfile(id, name, new PropertyMap(builder.build()));
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_11;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
@Override
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof ClientboundPlayerInfoRemovePacket remove) {
for (UUID id : remove.profileIds()) {
tablistEntries.remove(id);
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket update) {
if (update.actions().contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : update.entries()) {
tablistEntries.add(nmsData.profileId());
}
}
}
}
}
+28
View File
@@ -0,0 +1,28 @@
plugins {
id("io.papermc.paperweight.userdev") version "2.0.0-beta.19"
}
repositories {
maven("https://jitpack.io") // YamlAssist
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.viaversion.com/")
maven {
name = "luck-repo"
url = uri("https://repo.lucko.me/")
content {
includeModule("me.lucko", "spark-api")
}
}
}
val version = "1.21.3-R0.1-SNAPSHOT" // 1.21.2 causes gradle error, but the versions are interchangeable
dependencies {
implementation(projects.bukkit)
paperweight.paperDevBundle(version)
compileOnly("io.papermc.paper:paper-api:${version}")
}
tasks.compileJava {
options.release.set(21)
}
@@ -0,0 +1,67 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_2;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.Style;
import net.minecraft.network.chat.TextColor;
import net.minecraft.resources.ResourceLocation;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct mojang-mapped code.
*/
public class NMSComponentConverter extends ComponentConverter<Component> {
@Override
@NotNull
public Component newTextComponent(@NotNull String text) {
return Component.literal(text);
}
@Override
@NotNull
public Component newTranslatableComponent(@NotNull String key) {
return Component.translatable(key);
}
@Override
@NotNull
public Component newKeybindComponent(@NotNull String keybind) {
return Component.keybind(keybind);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabAtlasSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabPlayerSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
public void applyStyle(@NotNull Component nmsComponent, @NotNull TabStyle modifier) {
Style style = Style.EMPTY
.withColor(modifier.getColor() == null ? null : TextColor.fromRgb(modifier.getColor().getRgb()))
.withBold(modifier.getBold())
.withItalic(modifier.getItalic())
.withUnderlined(modifier.getUnderlined())
.withStrikethrough(modifier.getStrikethrough())
.withObfuscated(modifier.getObfuscated())
.withFont(modifier.getFont() == null ? null : ResourceLocation.tryParse(modifier.getFont()));
((MutableComponent)nmsComponent).setStyle(style);
}
@Override
public void addSibling(@NotNull Component parent, @NotNull Component child) {
((MutableComponent)parent).append(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_2;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct Mojang-mapped NMS code for paper 1.21.2 - 1.21.3.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().connection.connection.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return player.getPlayer().getPing();
}
}
@@ -0,0 +1,176 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_2;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.ChatFormatting;
import net.minecraft.network.chat.numbers.FixedFormat;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.*;
import net.minecraft.world.scores.PlayerTeam;
import net.minecraft.world.scores.Scoreboard;
import net.minecraft.world.scores.criteria.ObjectiveCriteria;
import net.minecraft.world.scores.criteria.ObjectiveCriteria.RenderType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
import java.util.Optional;
/**
* Scoreboard implementation using direct mojang-mapped code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ChatFormatting[] formats = ChatFormatting.values();
private static final net.minecraft.world.scores.Team.CollisionRule[] collisions = net.minecraft.world.scores.Team.CollisionRule.values();
private static final net.minecraft.world.scores.Team.Visibility[] visibilities = net.minecraft.world.scores.Team.Visibility.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final Field players = ReflectionUtils.getOnlyField(ClientboundSetPlayerTeamPacket.class, Collection.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = new net.minecraft.world.scores.Objective(
dummyScoreboard,
objective.getName(),
ObjectiveCriteria.DUMMY,
objective.getTitle().convert(),
RenderType.values()[objective.getHealthDisplay().ordinal()],
false,
objective.getNumberFormat() == null ? null : objective.getNumberFormat().toFixedFormat(FixedFormat::new)
);
objective.setPlatformObjective(obj);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new ClientboundSetDisplayObjectivePacket(
net.minecraft.world.scores.DisplaySlot.values()[objective.getDisplaySlot().ordinal()],
(net.minecraft.world.scores.Objective) objective.getPlatformObjective()
));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new ClientboundSetObjectivePacket((net.minecraft.world.scores.Objective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = (net.minecraft.world.scores.Objective) objective.getPlatformObjective();
obj.setDisplayName(objective.getTitle().convert());
obj.setRenderType(RenderType.values()[objective.getHealthDisplay().ordinal()]);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
sendPacket(new ClientboundSetScorePacket(
score.getHolder(),
score.getObjective().getName(),
score.getValue(),
Optional.ofNullable(score.getDisplayName() == null ? null : score.getDisplayName().convert()),
Optional.ofNullable(score.getNumberFormat() == null ? null : score.getNumberFormat().toFixedFormat(FixedFormat::new))
));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new ClientboundResetScorePacket(score.getHolder(), score.getObjective().getName()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new PlayerTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.getPlayers().addAll(team.getPlayers());
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket(t, true));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(ClientboundSetPlayerTeamPacket.createRemovePacket((PlayerTeam) team.getPlatformTeam()));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket((PlayerTeam) team.getPlatformTeam(), false));
}
private void updateTeamProperties(@NonNull Team team) {
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setColor(formats[team.getColor().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setPlayerPrefix(team.getPrefix().convert());
t.setPlayerSuffix(team.getSuffix().convert());
}
@Override
@SneakyThrows
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundSetDisplayObjectivePacket display) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, display.getSlot().ordinal(), display.getObjectiveName());
}
if (packet instanceof ClientboundSetObjectivePacket objective) {
TAB.getInstance().getFeatureManager().onObjective(player, objective.getMethod(), objective.getObjectiveName());
}
if (packet instanceof ClientboundSetPlayerTeamPacket team) {
int action = getMethod(team);
if (action != TeamAction.UPDATE) {
players.set(team, onTeamPacket(action, team.getName(), team.getPlayers() == null ? Collections.emptyList() : team.getPlayers()));
}
}
return packet;
}
private static int getMethod(@NonNull ClientboundSetPlayerTeamPacket team) {
if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 0;
} else if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 1;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 3;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 4;
} else {
return 2;
}
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.sendPacket(packet);
}
}
@@ -0,0 +1,202 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_2;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import lombok.NonNull;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import net.minecraft.network.chat.Component;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import net.minecraft.network.protocol.game.ClientboundTabListPacket;
import net.minecraft.world.level.GameType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.*;
/**
* TabList implementation using direct mojang-mapped code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> addPlayer = EnumSet.allOf(ClientboundPlayerInfoUpdatePacket.Action.class);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateDisplayName = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateLatency = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateGameMode = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListed = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListOrder = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LIST_ORDER);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void removeEntry(@NonNull UUID entry) {
sendPacket(new ClientboundPlayerInfoRemovePacket(Collections.singletonList(entry)));
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(updateDisplayName, entry, "", null, false, 0, 0, displayName, 0);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(updateLatency, entry, "", null, false, latency, 0, null, 0);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(updateGameMode, entry, "", null, false, 0, gameMode, null, 0);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
sendPacket(updateListed, entry, "", null, listed, 0, 0, null, 0);
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
sendPacket(updateListOrder, entry, "", null, false, 0, 0, null, listOrder);
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
// Added in 1.21.4
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(addPlayer, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.isListed(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName(), entry.getListOrder());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(new ClientboundTabListPacket(header.convert(), footer.convert()));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().getProperties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.value(), property.signature());
}
@Override
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundTabListPacket tablist) {
if (header == null || footer == null) return packet;
if (tablist.header() != header.convert() || tablist.footer() != footer.convert()) {
return new ClientboundTabListPacket(header.convert(), footer.convert());
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket info) {
EnumSet<ClientboundPlayerInfoUpdatePacket.Action> actions = info.actions();
List<ClientboundPlayerInfoUpdatePacket.Entry> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : info.entries()) {
boolean rewriteEntry = false;
Component displayName = nmsData.displayName();
int latency = nmsData.latency();
int gameMode = nmsData.gameMode().getId();
boolean listed = nmsData.listed();
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME)) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(nmsData.profileId());
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE)) {
if (getBlockedSpectators().contains(nmsData.profileId()) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY)) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED)) {
if (allPlayersHidden && nmsData.profileId().getMostSignificantBits() != 0) { // Filter out layout entries
listed = false;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, nmsData.profileId(), nmsData.profile().getName());
}
updatedList.add(rewriteEntry ? new ClientboundPlayerInfoUpdatePacket.Entry(
nmsData.profileId(), nmsData.profile(), listed, latency, GameType.byId(gameMode), displayName,
nmsData.listOrder(), nmsData.chatSession()
) : nmsData);
}
if (rewritePacket) return new ClientboundPlayerInfoUpdatePacket(actions, updatedList);
}
return packet;
}
private void sendPacket(@NonNull EnumSet<ClientboundPlayerInfoUpdatePacket.Action> action, @NonNull UUID id, @NonNull String name, @Nullable Skin skin,
boolean listed, int latency, int gameMode, @Nullable TabComponent displayName, int listOrder) {
ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(action, new ClientboundPlayerInfoUpdatePacket.Entry(
id,
action.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER) ? createProfile(id, name, skin) : null,
listed,
latency,
GameType.byId(gameMode),
displayName == null ? null : displayName.convert(),
listOrder,
null
));
sendPacket(packet);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
GameProfile profile = new GameProfile(id, name);
if (skin != null) {
profile.getProperties().put(TabList.TEXTURES_PROPERTY,
new Property(TabList.TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return profile;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_2;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
@Override
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof ClientboundPlayerInfoRemovePacket remove) {
for (UUID id : remove.profileIds()) {
tablistEntries.remove(id);
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket update) {
if (update.actions().contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : update.entries()) {
tablistEntries.add(nmsData.profileId());
}
}
}
}
}
+28
View File
@@ -0,0 +1,28 @@
plugins {
id("io.papermc.paperweight.userdev") version "2.0.0-beta.19"
}
repositories {
maven("https://jitpack.io") // YamlAssist
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.viaversion.com/")
maven {
name = "luck-repo"
url = uri("https://repo.lucko.me/")
content {
includeModule("me.lucko", "spark-api")
}
}
}
val version = "1.21.4-R0.1-SNAPSHOT"
dependencies {
implementation(projects.bukkit)
paperweight.paperDevBundle(version)
compileOnly("io.papermc.paper:paper-api:${version}")
}
tasks.compileJava {
options.release.set(21)
}
@@ -0,0 +1,65 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_4;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import net.minecraft.network.chat.*;
import net.minecraft.resources.ResourceLocation;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct mojang-mapped code.
*/
public class NMSComponentConverter extends ComponentConverter<Component> {
@Override
@NotNull
public Component newTextComponent(@NotNull String text) {
return Component.literal(text);
}
@Override
@NotNull
public Component newTranslatableComponent(@NotNull String key) {
return Component.translatable(key);
}
@Override
@NotNull
public Component newKeybindComponent(@NotNull String keybind) {
return Component.keybind(keybind);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabAtlasSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabPlayerSprite sprite) {
return Component.literal(TabObjectComponent.ERROR_MESSAGE);
}
@Override
public void applyStyle(@NotNull Component nmsComponent, @NotNull TabStyle modifier) {
Style style = Style.EMPTY
.withColor(modifier.getColor() == null ? null : TextColor.fromRgb(modifier.getColor().getRgb()))
.withBold(modifier.getBold())
.withItalic(modifier.getItalic())
.withUnderlined(modifier.getUnderlined())
.withStrikethrough(modifier.getStrikethrough())
.withObfuscated(modifier.getObfuscated())
.withFont(modifier.getFont() == null ? null : ResourceLocation.tryParse(modifier.getFont()));
if (modifier.getShadowColor() != null) style = style.withShadowColor(modifier.getShadowColor()); // withShadowColor takes int instead of Integer, bug?
((MutableComponent)nmsComponent).setStyle(style);
}
@Override
public void addSibling(@NotNull Component parent, @NotNull Component child) {
((MutableComponent)parent).append(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_4;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct Mojang-mapped NMS code for paper 1.21.4 - 1.21.8.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().connection.connection.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return player.getPlayer().getPing();
}
}
@@ -0,0 +1,176 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_4;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.ChatFormatting;
import net.minecraft.network.chat.numbers.FixedFormat;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.*;
import net.minecraft.world.scores.PlayerTeam;
import net.minecraft.world.scores.Scoreboard;
import net.minecraft.world.scores.criteria.ObjectiveCriteria;
import net.minecraft.world.scores.criteria.ObjectiveCriteria.RenderType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
import java.util.Optional;
/**
* Scoreboard implementation using direct mojang-mapped code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ChatFormatting[] formats = ChatFormatting.values();
private static final net.minecraft.world.scores.Team.CollisionRule[] collisions = net.minecraft.world.scores.Team.CollisionRule.values();
private static final net.minecraft.world.scores.Team.Visibility[] visibilities = net.minecraft.world.scores.Team.Visibility.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final Field players = ReflectionUtils.getOnlyField(ClientboundSetPlayerTeamPacket.class, Collection.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = new net.minecraft.world.scores.Objective(
dummyScoreboard,
objective.getName(),
ObjectiveCriteria.DUMMY,
objective.getTitle().convert(),
RenderType.values()[objective.getHealthDisplay().ordinal()],
false,
objective.getNumberFormat() == null ? null : objective.getNumberFormat().toFixedFormat(FixedFormat::new)
);
objective.setPlatformObjective(obj);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new ClientboundSetDisplayObjectivePacket(
net.minecraft.world.scores.DisplaySlot.values()[objective.getDisplaySlot().ordinal()],
(net.minecraft.world.scores.Objective) objective.getPlatformObjective()
));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new ClientboundSetObjectivePacket((net.minecraft.world.scores.Objective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = (net.minecraft.world.scores.Objective) objective.getPlatformObjective();
obj.setDisplayName(objective.getTitle().convert());
obj.setRenderType(RenderType.values()[objective.getHealthDisplay().ordinal()]);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
sendPacket(new ClientboundSetScorePacket(
score.getHolder(),
score.getObjective().getName(),
score.getValue(),
Optional.ofNullable(score.getDisplayName() == null ? null : score.getDisplayName().convert()),
Optional.ofNullable(score.getNumberFormat() == null ? null : score.getNumberFormat().toFixedFormat(FixedFormat::new))
));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new ClientboundResetScorePacket(score.getHolder(), score.getObjective().getName()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new PlayerTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.getPlayers().addAll(team.getPlayers());
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket(t, true));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(ClientboundSetPlayerTeamPacket.createRemovePacket((PlayerTeam) team.getPlatformTeam()));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket((PlayerTeam) team.getPlatformTeam(), false));
}
private void updateTeamProperties(@NonNull Team team) {
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setColor(formats[team.getColor().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setPlayerPrefix(team.getPrefix().convert());
t.setPlayerSuffix(team.getSuffix().convert());
}
@Override
@SneakyThrows
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundSetDisplayObjectivePacket display) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, display.getSlot().ordinal(), display.getObjectiveName());
}
if (packet instanceof ClientboundSetObjectivePacket objective) {
TAB.getInstance().getFeatureManager().onObjective(player, objective.getMethod(), objective.getObjectiveName());
}
if (packet instanceof ClientboundSetPlayerTeamPacket team) {
int action = getMethod(team);
if (action != TeamAction.UPDATE) {
players.set(team, onTeamPacket(action, team.getName(), team.getPlayers() == null ? Collections.emptyList() : team.getPlayers()));
}
}
return packet;
}
private int getMethod(@NonNull ClientboundSetPlayerTeamPacket team) {
if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 0;
} else if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 1;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 3;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 4;
} else {
return 2;
}
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,204 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_4;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import lombok.NonNull;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import net.minecraft.network.chat.Component;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import net.minecraft.network.protocol.game.ClientboundTabListPacket;
import net.minecraft.world.level.GameType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.*;
/**
* TabList implementation using direct mojang-mapped code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> addPlayer = EnumSet.allOf(ClientboundPlayerInfoUpdatePacket.Action.class);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateDisplayName = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateLatency = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateGameMode = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListed = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListOrder = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LIST_ORDER);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateHat = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_HAT);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void removeEntry(@NonNull UUID entry) {
sendPacket(new ClientboundPlayerInfoRemovePacket(Collections.singletonList(entry)));
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(updateDisplayName, entry, "", null, false, 0, 0, displayName, 0, false);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(updateLatency, entry, "", null, false, latency, 0, null, 0, false);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(updateGameMode, entry, "", null, false, 0, gameMode, null, 0, false);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
sendPacket(updateListed, entry, "", null, listed, 0, 0, null, 0, false);
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
sendPacket(updateListOrder, entry, "", null, false, 0, 0, null, listOrder, false);
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
sendPacket(updateHat, entry, "", null, false, 0, 0, null, 0, showHat);
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(addPlayer, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.isListed(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName(), entry.getListOrder(), entry.isShowHat());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(new ClientboundTabListPacket(header.convert(), footer.convert()));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().getProperties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.value(), property.signature());
}
@Override
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundTabListPacket tablist) {
if (header == null || footer == null) return packet;
if (tablist.header() != header.convert() || tablist.footer() != footer.convert()) {
return new ClientboundTabListPacket(header.convert(), footer.convert());
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket info) {
EnumSet<ClientboundPlayerInfoUpdatePacket.Action> actions = info.actions();
List<ClientboundPlayerInfoUpdatePacket.Entry> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : info.entries()) {
boolean rewriteEntry = false;
Component displayName = nmsData.displayName();
int latency = nmsData.latency();
int gameMode = nmsData.gameMode().getId();
boolean listed = nmsData.listed();
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME)) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(nmsData.profileId());
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE)) {
if (getBlockedSpectators().contains(nmsData.profileId()) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY)) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED)) {
if (allPlayersHidden && nmsData.profileId().getMostSignificantBits() != 0) { // Filter out layout entries
listed = false;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, nmsData.profileId(), nmsData.profile().getName());
}
updatedList.add(rewriteEntry ? new ClientboundPlayerInfoUpdatePacket.Entry(
nmsData.profileId(), nmsData.profile(), listed, latency, GameType.byId(gameMode), displayName,
nmsData.showHat(), nmsData.listOrder(), nmsData.chatSession()
) : nmsData);
}
if (rewritePacket) return new ClientboundPlayerInfoUpdatePacket(actions, updatedList);
}
return packet;
}
private void sendPacket(@NonNull EnumSet<ClientboundPlayerInfoUpdatePacket.Action> action, @NonNull UUID id, @NonNull String name, @Nullable Skin skin,
boolean listed, int latency, int gameMode, @Nullable TabComponent displayName, int listOrder, boolean showHat) {
ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(action, new ClientboundPlayerInfoUpdatePacket.Entry(
id,
action.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER) ? createProfile(id, name, skin) : null,
listed,
latency,
GameType.byId(gameMode),
displayName == null ? null : displayName.convert(),
showHat,
listOrder,
null
));
sendPacket(packet);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
GameProfile profile = new GameProfile(id, name);
if (skin != null) {
profile.getProperties().put(TabList.TEXTURES_PROPERTY,
new Property(TabList.TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return profile;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_4;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
@Override
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof ClientboundPlayerInfoRemovePacket remove) {
for (UUID id : remove.profileIds()) {
tablistEntries.remove(id);
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket update) {
if (update.actions().contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : update.entries()) {
tablistEntries.add(nmsData.profileId());
}
}
}
}
}
+28
View File
@@ -0,0 +1,28 @@
plugins {
id("io.papermc.paperweight.userdev") version "2.0.0-beta.19"
}
repositories {
maven("https://jitpack.io") // YamlAssist
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.viaversion.com/")
maven {
name = "luck-repo"
url = uri("https://repo.lucko.me/")
content {
includeModule("me.lucko", "spark-api")
}
}
}
val version = "1.21.9-R0.1-SNAPSHOT"
dependencies {
implementation(projects.bukkit)
paperweight.paperDevBundle(version)
compileOnly("io.papermc.paper:paper-api:${version}")
}
tasks.compileJava {
options.release.set(21)
}
@@ -0,0 +1,84 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_9;
import com.google.common.collect.ImmutableMultimap;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import com.mojang.authlib.properties.PropertyMap;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import me.neznamy.tab.shared.platform.TabList;
import net.minecraft.network.chat.*;
import net.minecraft.network.chat.contents.objects.AtlasSprite;
import net.minecraft.network.chat.contents.objects.PlayerSprite;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.item.component.ResolvableProfile;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct mojang-mapped code.
*/
public class NMSComponentConverter extends ComponentConverter<Component> {
@Override
@NotNull
public Component newTextComponent(@NotNull String text) {
return Component.literal(text);
}
@Override
@NotNull
public Component newTranslatableComponent(@NotNull String key) {
return Component.translatable(key);
}
@Override
@NotNull
public Component newKeybindComponent(@NotNull String keybind) {
return Component.keybind(keybind);
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabAtlasSprite sprite) {
return Component.object(new AtlasSprite(ResourceLocation.parse(sprite.getAtlas()), ResourceLocation.parse(sprite.getSprite())));
}
@Override
@NotNull
public Component newObjectComponent(@NotNull TabPlayerSprite sprite) {
ResolvableProfile profile;
if (sprite.getId() != null) {
profile = ResolvableProfile.createUnresolved(sprite.getId());
} else if (sprite.getName() != null) {
profile = ResolvableProfile.createUnresolved(sprite.getName());
} else if (sprite.getSkin() != null) {
ImmutableMultimap.Builder<String, Property> builder = ImmutableMultimap.builder();
builder.put(TabList.TEXTURES_PROPERTY, new Property(TabList.TEXTURES_PROPERTY, sprite.getSkin().getValue(), sprite.getSkin().getSignature()));
profile = ResolvableProfile.createResolved(new GameProfile(NIL_UUID, "", new PropertyMap(builder.build())));
} else {
throw new IllegalStateException("Player head component does not have id, name or skin set");
}
return Component.object(new PlayerSprite(profile, sprite.isShowHat()));
}
@Override
public void applyStyle(@NotNull Component nmsComponent, @NotNull TabStyle modifier) {
Style style = Style.EMPTY
.withColor(modifier.getColor() == null ? null : TextColor.fromRgb(modifier.getColor().getRgb()))
.withBold(modifier.getBold())
.withItalic(modifier.getItalic())
.withUnderlined(modifier.getUnderlined())
.withStrikethrough(modifier.getStrikethrough())
.withObfuscated(modifier.getObfuscated())
.withFont(modifier.getFont() == null ? null : new FontDescription.Resource(ResourceLocation.parse(modifier.getFont())));
if (modifier.getShadowColor() != null) style = style.withShadowColor(modifier.getShadowColor()); // withShadowColor takes int instead of Integer, bug?
((MutableComponent)nmsComponent).setStyle(style);
}
@Override
public void addSibling(@NotNull Component parent, @NotNull Component child) {
((MutableComponent)parent).append(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_9;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct Mojang-mapped NMS code for paper 1.21.9 - 1.21.10.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().connection.connection.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return player.getPlayer().getPing();
}
}
@@ -0,0 +1,176 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_9;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.ChatFormatting;
import net.minecraft.network.chat.numbers.FixedFormat;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.*;
import net.minecraft.world.scores.PlayerTeam;
import net.minecraft.world.scores.Scoreboard;
import net.minecraft.world.scores.criteria.ObjectiveCriteria;
import net.minecraft.world.scores.criteria.ObjectiveCriteria.RenderType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
import java.util.Optional;
/**
* Scoreboard implementation using direct mojang-mapped code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ChatFormatting[] formats = ChatFormatting.values();
private static final net.minecraft.world.scores.Team.CollisionRule[] collisions = net.minecraft.world.scores.Team.CollisionRule.values();
private static final net.minecraft.world.scores.Team.Visibility[] visibilities = net.minecraft.world.scores.Team.Visibility.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final Field players = ReflectionUtils.getOnlyField(ClientboundSetPlayerTeamPacket.class, Collection.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = new net.minecraft.world.scores.Objective(
dummyScoreboard,
objective.getName(),
ObjectiveCriteria.DUMMY,
objective.getTitle().convert(),
RenderType.values()[objective.getHealthDisplay().ordinal()],
false,
objective.getNumberFormat() == null ? null : objective.getNumberFormat().toFixedFormat(FixedFormat::new)
);
objective.setPlatformObjective(obj);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new ClientboundSetDisplayObjectivePacket(
net.minecraft.world.scores.DisplaySlot.values()[objective.getDisplaySlot().ordinal()],
(net.minecraft.world.scores.Objective) objective.getPlatformObjective()
));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new ClientboundSetObjectivePacket((net.minecraft.world.scores.Objective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
net.minecraft.world.scores.Objective obj = (net.minecraft.world.scores.Objective) objective.getPlatformObjective();
obj.setDisplayName(objective.getTitle().convert());
obj.setRenderType(RenderType.values()[objective.getHealthDisplay().ordinal()]);
sendPacket(new ClientboundSetObjectivePacket(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
sendPacket(new ClientboundSetScorePacket(
score.getHolder(),
score.getObjective().getName(),
score.getValue(),
Optional.ofNullable(score.getDisplayName() == null ? null : score.getDisplayName().convert()),
Optional.ofNullable(score.getNumberFormat() == null ? null : score.getNumberFormat().toFixedFormat(FixedFormat::new))
));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new ClientboundResetScorePacket(score.getHolder(), score.getObjective().getName()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new PlayerTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.getPlayers().addAll(team.getPlayers());
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket(t, true));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(ClientboundSetPlayerTeamPacket.createRemovePacket((PlayerTeam) team.getPlatformTeam()));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(ClientboundSetPlayerTeamPacket.createAddOrModifyPacket((PlayerTeam) team.getPlatformTeam(), false));
}
private void updateTeamProperties(@NonNull Team team) {
PlayerTeam t = (PlayerTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setColor(formats[team.getColor().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setPlayerPrefix(team.getPrefix().convert());
t.setPlayerSuffix(team.getSuffix().convert());
}
@Override
@SneakyThrows
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundSetDisplayObjectivePacket display) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, display.getSlot().ordinal(), display.getObjectiveName());
}
if (packet instanceof ClientboundSetObjectivePacket objective) {
TAB.getInstance().getFeatureManager().onObjective(player, objective.getMethod(), objective.getObjectiveName());
}
if (packet instanceof ClientboundSetPlayerTeamPacket team) {
int action = getMethod(team);
if (action != TeamAction.UPDATE) {
players.set(team, onTeamPacket(action, team.getName(), team.getPlayers() == null ? Collections.emptyList() : team.getPlayers()));
}
}
return packet;
}
private int getMethod(@NonNull ClientboundSetPlayerTeamPacket team) {
if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 0;
} else if (team.getTeamAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 1;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.ADD) {
return 3;
} else if (team.getPlayerAction() == ClientboundSetPlayerTeamPacket.Action.REMOVE) {
return 4;
} else {
return 2;
}
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,206 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_9;
import com.google.common.collect.ImmutableMultimap;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import com.mojang.authlib.properties.PropertyMap;
import lombok.NonNull;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import net.minecraft.network.chat.Component;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import net.minecraft.network.protocol.game.ClientboundTabListPacket;
import net.minecraft.world.level.GameType;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.*;
/**
* TabList implementation using direct mojang-mapped code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> addPlayer = EnumSet.allOf(ClientboundPlayerInfoUpdatePacket.Action.class);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateDisplayName = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateLatency = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateGameMode = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListed = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateListOrder = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LIST_ORDER);
private static final EnumSet<ClientboundPlayerInfoUpdatePacket.Action> updateHat = EnumSet.of(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_HAT);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void removeEntry(@NonNull UUID entry) {
sendPacket(new ClientboundPlayerInfoRemovePacket(Collections.singletonList(entry)));
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(updateDisplayName, entry, "", null, false, 0, 0, displayName, 0, false);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(updateLatency, entry, "", null, false, latency, 0, null, 0, false);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(updateGameMode, entry, "", null, false, 0, gameMode, null, 0, false);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
sendPacket(updateListed, entry, "", null, listed, 0, 0, null, 0, false);
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
sendPacket(updateListOrder, entry, "", null, false, 0, 0, null, listOrder, false);
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
sendPacket(updateHat, entry, "", null, false, 0, 0, null, 0, showHat);
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(addPlayer, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.isListed(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName(), entry.getListOrder(), entry.isShowHat());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(new ClientboundTabListPacket(header.convert(), footer.convert()));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().properties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.value(), property.signature());
}
@Override
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof ClientboundTabListPacket tablist) {
if (header == null || footer == null) return packet;
if (tablist.header() != header.convert() || tablist.footer() != footer.convert()) {
return new ClientboundTabListPacket(header.convert(), footer.convert());
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket info) {
EnumSet<ClientboundPlayerInfoUpdatePacket.Action> actions = info.actions();
List<ClientboundPlayerInfoUpdatePacket.Entry> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : info.entries()) {
boolean rewriteEntry = false;
Component displayName = nmsData.displayName();
int latency = nmsData.latency();
int gameMode = nmsData.gameMode().getId();
boolean listed = nmsData.listed();
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME)) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(nmsData.profileId());
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE)) {
if (getBlockedSpectators().contains(nmsData.profileId()) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LATENCY)) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.UPDATE_LISTED)) {
if (allPlayersHidden && nmsData.profileId().getMostSignificantBits() != 0) { // Filter out layout entries
listed = false;
rewriteEntry = rewritePacket = true;
}
}
if (actions.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, nmsData.profileId(), nmsData.profile().name());
}
updatedList.add(rewriteEntry ? new ClientboundPlayerInfoUpdatePacket.Entry(
nmsData.profileId(), nmsData.profile(), listed, latency, GameType.byId(gameMode), displayName,
nmsData.showHat(), nmsData.listOrder(), nmsData.chatSession()
) : nmsData);
}
if (rewritePacket) return new ClientboundPlayerInfoUpdatePacket(actions, updatedList);
}
return packet;
}
private void sendPacket(@NonNull EnumSet<ClientboundPlayerInfoUpdatePacket.Action> action, @NonNull UUID id, @NonNull String name, @Nullable Skin skin,
boolean listed, int latency, int gameMode, @Nullable TabComponent displayName, int listOrder, boolean showHat) {
ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(action, new ClientboundPlayerInfoUpdatePacket.Entry(
id,
action.contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER) ? createProfile(id, name, skin) : null,
listed,
latency,
GameType.byId(gameMode),
displayName == null ? null : displayName.convert(),
showHat,
listOrder,
null
));
sendPacket(packet);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
ImmutableMultimap.Builder<String, Property> builder = ImmutableMultimap.builder();
if (skin != null) {
builder.put(TabList.TEXTURES_PROPERTY,
new Property(TabList.TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return new GameProfile(id, name, new PropertyMap(builder.build()));
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().connection.send(packet);
}
}
@@ -0,0 +1,30 @@
package me.neznamy.tab.platforms.bukkit.paper_1_21_9;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoRemovePacket;
import net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
@Override
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof ClientboundPlayerInfoRemovePacket remove) {
for (UUID id : remove.profileIds()) {
tablistEntries.remove(id);
}
}
if (packet instanceof ClientboundPlayerInfoUpdatePacket update) {
if (update.actions().contains(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER)) {
for (ClientboundPlayerInfoUpdatePacket.Entry nmsData : update.entries()) {
tablistEntries.add(nmsData.profileId());
}
}
}
}
}
@@ -0,0 +1,69 @@
package me.neznamy.tab.platforms.bukkit;
import lombok.RequiredArgsConstructor;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.EventListener;
import me.neznamy.tab.shared.platform.TabPlayer;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerChangedWorldEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerQuitEvent;
import org.jetbrains.annotations.NotNull;
/**
* The core for bukkit forwarding events into all enabled features
*/
@RequiredArgsConstructor
public class BukkitEventListener implements EventListener<Player>, Listener {
/** Platform reference */
private final BukkitPlatform platform;
/**
* Listens to player quit event.
*
* @param e
* Disconnect event
*/
@EventHandler(priority = EventPriority.HIGHEST)
public void onQuit(PlayerQuitEvent e) {
quit(e.getPlayer().getUniqueId());
}
/**
* Listens to player join event.
*
* @param e
* Join event
*/
@EventHandler(priority = EventPriority.LOW)
public void onJoin(PlayerJoinEvent e) {
TAB.getInstance().addTablistTracker(
e.getPlayer().getUniqueId(),
platform.getImplementationProvider().getChannel(e.getPlayer()),
platform.getImplementationProvider().newTabListEntryTracker()
);
join(e.getPlayer());
}
/**
* Listens to world change event.
*
* @param e
* World change event
*/
@EventHandler(priority = EventPriority.LOWEST)
public void onWorldChange(PlayerChangedWorldEvent e) {
worldChange(e.getPlayer().getUniqueId(), e.getPlayer().getWorld().getName());
}
@Override
@NotNull
public TabPlayer createPlayer(@NotNull Player player) {
return new BukkitTabPlayer(platform, player);
}
}
@@ -0,0 +1,26 @@
package me.neznamy.tab.platforms.bukkit;
import io.netty.channel.Channel;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.shared.features.injection.NettyPipelineInjector;
import me.neznamy.tab.shared.platform.TabPlayer;
import org.jetbrains.annotations.NotNull;
/**
* Pipeline injection for Bukkit 1.8+.
*/
public class BukkitPipelineInjector extends NettyPipelineInjector {
/**
* Constructs new instance
*/
public BukkitPipelineInjector() {
super("packet_handler");
}
@Override
@NotNull
protected Channel getChannel(@NotNull TabPlayer player) {
return ((BukkitPlatform)player.getPlatform()).getImplementationProvider().getChannel(((BukkitTabPlayer) player).getPlayer());
}
}
@@ -0,0 +1,36 @@
package me.neznamy.tab.platforms.bukkit;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.platforms.bukkit.platform.FoliaPlatform;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.util.ReflectionUtils;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;
/**
* Main class for Bukkit.
*/
public class BukkitTAB extends JavaPlugin {
@Override
public void onEnable() {
boolean folia = ReflectionUtils.classExists("io.papermc.paper.threadedregions.RegionizedServer");
try {
TAB.create(folia ? new FoliaPlatform(this) : new BukkitPlatform(this));
} catch (IllegalStateException e) {
Bukkit.getConsoleSender().sendMessage("§c[TAB] ================================================================================");
Bukkit.getConsoleSender().sendMessage("§c[TAB] Your server version (" + Bukkit.getBukkitVersion().split("-")[0] + ") is not supported.");
Bukkit.getConsoleSender().sendMessage("§c[TAB] This jar only supports 1.7.10, 1.8.8, 1.9.4 - 1.15.x, 1.16.5, 1.17.1, 1.18.2 - 1.21.11.");
Bukkit.getConsoleSender().sendMessage("§c[TAB] If you just updated to a new Minecraft version, check for TAB updates.");
Bukkit.getConsoleSender().sendMessage("§c[TAB] If you are using an unsupported 1.x version, use an older version of TAB (latest TAB 5.x supports all MC 1.x versions).");
Bukkit.getConsoleSender().sendMessage("§c[TAB] Thrown error message: " + e.getMessage());
Bukkit.getConsoleSender().sendMessage("§c[TAB] ================================================================================");
}
}
@Override
public void onDisable() {
if (TAB.getInstance() == null) return;
TAB.getInstance().unload();
}
}
@@ -0,0 +1,50 @@
package me.neznamy.tab.platforms.bukkit;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.TabConstants;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.TabPlayer;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.command.TabCompleter;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
import java.util.Collections;
import java.util.List;
/**
* Command handler for /tab command
*/
public class BukkitTabCommand implements CommandExecutor, TabCompleter {
@Override
public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command, @NotNull String label, @NotNull String[] args) {
if (TAB.getInstance().isPluginDisabled()) {
for (TabComponent message : TAB.getInstance().getDisabledCommand().execute(args, sender.hasPermission(TabConstants.Permission.COMMAND_RELOAD), sender.hasPermission(TabConstants.Permission.COMMAND_ALL))) {
sender.sendMessage(((BukkitPlatform)TAB.getInstance().getPlatform()).toBukkitFormat(message));
}
} else {
TabPlayer p = null;
if (sender instanceof Player) {
p = TAB.getInstance().getPlayer(((Player)sender).getUniqueId());
if (p == null) return true; //player not loaded correctly
}
TAB.getInstance().getCommand().execute(p, args);
}
return false;
}
@Override
@NotNull
public List<String> onTabComplete(@NotNull CommandSender sender, @NotNull Command command, @NotNull String alias, @NotNull String[] args) {
TabPlayer p = null;
if (sender instanceof Player) {
p = TAB.getInstance().getPlayer(((Player)sender).getUniqueId());
if (p == null) return Collections.emptyList(); //player not loaded correctly
}
return TAB.getInstance().getCommand().complete(p, args);
}
}
@@ -0,0 +1,95 @@
package me.neznamy.tab.platforms.bukkit;
import me.neznamy.tab.platforms.bukkit.hook.LibsDisguisesHook;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.shared.backend.BackendTabPlayer;
import me.neznamy.tab.shared.chat.component.TabComponent;
import org.bukkit.Statistic;
import org.bukkit.entity.Player;
import org.bukkit.metadata.MetadataValue;
import org.bukkit.potion.PotionEffectType;
import org.jetbrains.annotations.NotNull;
/**
* TabPlayer implementation for Bukkit platform
*/
@SuppressWarnings("deprecation")
public class BukkitTabPlayer extends BackendTabPlayer {
/**
* Constructs new instance with given bukkit player
*
* @param platform
* Server platform
* @param p
* bukkit player
*/
public BukkitTabPlayer(@NotNull BukkitPlatform platform, @NotNull Player p) {
super(platform, p, p.getUniqueId(), p.getName(), p.getWorld().getName(), platform.getServerVersion().getNetworkId());
}
@Override
public boolean hasPermission(@NotNull String permission) {
return getPlayer().hasPermission(permission);
}
@Override
public int getPing() {
return getPlatform().getImplementationProvider().getPing(this);
}
@Override
public void sendMessage(@NotNull TabComponent message) {
getPlayer().sendMessage(getPlatform().toBukkitFormat(message));
}
@Override
public boolean hasInvisibilityPotion() {
return getPlayer().hasPotionEffect(PotionEffectType.INVISIBILITY);
}
@Override
public boolean isDisguised() {
return LibsDisguisesHook.isDisguised(this);
}
@Override
@NotNull
public Player getPlayer() {
return (Player) player;
}
@Override
public BukkitPlatform getPlatform() {
return (BukkitPlatform) platform;
}
@Override
public boolean isVanished0() {
for (MetadataValue v : getPlayer().getMetadata("vanished")) {
if (v.asBoolean()) return true;
}
return false;
}
@Override
public int getDeaths() {
return getPlayer().getStatistic(Statistic.DEATHS);
}
@Override
public int getGamemode() {
return getPlayer().getGameMode().getValue();
}
@Override
public double getHealth() {
return getPlayer().getHealth();
}
@Override
@NotNull
public String getDisplayName() {
return getPlayer().getDisplayName();
}
}
@@ -0,0 +1,76 @@
package me.neznamy.tab.platforms.bukkit.bossbar;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.api.bossbar.BarColor;
import me.neznamy.tab.api.bossbar.BarStyle;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.platform.decorators.SafeBossBar;
import me.neznamy.tab.shared.util.ReflectionUtils;
import org.bukkit.Bukkit;
import org.bukkit.boss.BossBar;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* BossBar for 1.9+ servers where Bukkit API is used. If ViaVersion is used
* to allow 1.8 players, it will handle the entity and teleporting by itself.
*/
@RequiredArgsConstructor
public class BukkitBossBar extends SafeBossBar<BossBar> {
/** Flag indicating whether this class is available or not */
@Getter
private static final boolean available = ReflectionUtils.classExists("org.bukkit.boss.BossBar");
/** Style array because names do not match */
private static final org.bukkit.boss.BarStyle[] styles = available ? org.bukkit.boss.BarStyle.values() : null;
/** Player this handler belongs to */
@NotNull
private final BukkitTabPlayer player;
@Override
@NotNull
public BossBar constructBossBar(@NotNull UUID id, @NotNull TabComponent title, float progress, @NotNull BarColor color, @NotNull BarStyle style) {
BossBar bar = Bukkit.createBossBar(
player.getPlatform().toBukkitFormat(title),
org.bukkit.boss.BarColor.valueOf(color.name()),
styles[style.ordinal()]
);
bar.setProgress(progress);
return bar;
}
@Override
public void show(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().addPlayer(player.getPlayer());
}
@Override
public void updateTitle(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().setTitle(player.getPlatform().toBukkitFormat(bar.getTitle()));
}
@Override
public void updateProgress(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().setProgress(bar.getProgress());
}
@Override
public void updateStyle(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().setStyle(styles[bar.getStyle().ordinal()]);
}
@Override
public void updateColor(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().setColor(org.bukkit.boss.BarColor.valueOf(bar.getColor().name()));
}
@Override
public void hide(SafeBossBar<BossBar>.@NotNull BossBarInfo bar) {
bar.getBossBar().removePlayer(player.getPlayer());
}
}
@@ -0,0 +1,70 @@
package me.neznamy.tab.platforms.bukkit.bossbar;
import com.viaversion.viaversion.api.Via;
import com.viaversion.viaversion.api.legacy.bossbar.BossBar;
import com.viaversion.viaversion.api.legacy.bossbar.BossColor;
import com.viaversion.viaversion.api.legacy.bossbar.BossStyle;
import lombok.RequiredArgsConstructor;
import me.neznamy.tab.api.bossbar.BarColor;
import me.neznamy.tab.api.bossbar.BarStyle;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.platform.decorators.SafeBossBar;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Handler for 1.9+ players on 1.8 server using ViaVersion API.
*/
@RequiredArgsConstructor
public class ViaBossBar extends SafeBossBar<BossBar> {
/** Style array for fast access */
private static final BossStyle[] styles = BossStyle.values();
/** Player this handler belongs to */
@NotNull
private final BukkitTabPlayer player;
@Override
@NotNull
public BossBar constructBossBar(@NotNull UUID id, @NotNull TabComponent title, float progress, @NotNull BarColor color, @NotNull BarStyle style) {
return Via.getAPI().legacyAPI().createLegacyBossBar(
title.toLegacyText(),
progress,
BossColor.valueOf(color.name()),
styles[style.ordinal()]
);
}
@Override
public void show(@NotNull BossBarInfo bar) {
bar.getBossBar().addPlayer(player.getPlayer().getUniqueId());
}
@Override
public void updateTitle(@NotNull BossBarInfo bar) {
bar.getBossBar().setTitle(bar.getTitle().toLegacyText());
}
@Override
public void updateProgress(@NotNull BossBarInfo bar) {
bar.getBossBar().setHealth(bar.getProgress());
}
@Override
public void updateStyle(@NotNull BossBarInfo bar) {
bar.getBossBar().setStyle(styles[bar.getStyle().ordinal()]);
}
@Override
public void updateColor(@NotNull BossBarInfo bar) {
bar.getBossBar().setColor(BossColor.valueOf(bar.getColor().name()));
}
@Override
public void hide(@NotNull BossBarInfo bar) {
bar.getBossBar().removePlayer(player.getPlayer().getUniqueId());
}
}
@@ -0,0 +1,148 @@
package me.neznamy.tab.platforms.bukkit.features;
import lombok.Getter;
import me.clip.placeholderapi.PlaceholderAPI;
import me.clip.placeholderapi.expansion.PlaceholderExpansion;
import me.clip.placeholderapi.expansion.Relational;
import me.neznamy.tab.api.placeholder.Placeholder;
import me.neznamy.tab.shared.ProjectVariables;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.features.PlaceholderManagerImpl;
import me.neznamy.tab.shared.placeholders.expansion.TabExpansion;
import me.neznamy.tab.shared.placeholders.types.RelationalPlaceholderImpl;
import me.neznamy.tab.shared.platform.TabPlayer;
import me.neznamy.tab.shared.util.ReflectionUtils;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
/**
* TAB's expansion for PlaceholderAPI
*/
@Getter
public class BukkitTabExpansion extends PlaceholderExpansion implements TabExpansion, Relational {
/** List of all placeholders offered by the plugin for command suggestions */
@NotNull
private final List<String> placeholders = Collections.unmodifiableList(Arrays.asList(
"%tab_tabprefix%",
"%tab_tabsuffix%",
"%tab_tagprefix%",
"%tab_tagsuffix%",
"%tab_customtabname%",
"%tab_tabprefix_raw%",
"%tab_tabsuffix_raw%",
"%tab_tagprefix_raw%",
"%tab_tagsuffix_raw%",
"%tab_customtabname_raw%",
"%tab_scoreboard_name%",
"%tab_scoreboard_visible%",
"%tab_bossbar_visible%",
"%tab_nametag_visibility%",
"%tab_replace_<placeholder>%",
"%tab_placeholder_<placeholder>%"
));
@Override
public boolean persist() {
return true;
}
@Override
@NotNull
public String getAuthor() {
return ProjectVariables.PLUGIN_AUTHOR;
}
@Override
@NotNull
public String getIdentifier() {
return ProjectVariables.PLUGIN_ID;
}
@Override
@NotNull
public String getVersion() {
return ProjectVariables.PLUGIN_VERSION;
}
@Override
@NotNull
public List<String> getPlaceholders() {
return placeholders;
}
@Override
@Nullable
public String onPlaceholderRequest(@Nullable Player player, @NotNull String identifier) {
if (identifier.startsWith("replace_")) {
String text = "%" + identifier.substring(8) + "%";
String textBefore;
do {
textBefore = text;
for (String placeholder : PlaceholderManagerImpl.detectPlaceholders(text)) {
text = text.replace(placeholder, TAB.getInstance().getPlaceholderManager().findReplacement(placeholder,
PlaceholderAPI.setPlaceholders(player, placeholder)));
}
} while (!textBefore.equals(text));
return text;
}
if (player == null) return "<Player cannot be null>";
TabPlayer p = TAB.getInstance().getPlayer(player.getUniqueId());
if (p == null) return "<Player is not loaded>";
if (identifier.startsWith("placeholder_")) {
String requestedPlaceholder = "%" + identifier.substring("placeholder_".length()) + "%";
PlaceholderManagerImpl pm = TAB.getInstance().getPlaceholderManager();
pm.addUsedPlaceholder(requestedPlaceholder, pm);
return pm.getPlaceholder(requestedPlaceholder).parse(p);
}
return p.expansionData.getValue(identifier);
}
@Override
public String onPlaceholderRequest(@NotNull Player viewer, @NotNull Player target, @NotNull String identifier) {
if (identifier.startsWith("replace_")) {
String text = "%" + identifier.substring(8) + "%";
String textBefore;
do {
textBefore = text;
for (String placeholder : PlaceholderManagerImpl.detectPlaceholders(text)) {
text = text.replace(placeholder, TAB.getInstance().getPlaceholderManager().findReplacement(placeholder,
PlaceholderAPI.setRelationalPlaceholders(viewer, target, placeholder)));
}
} while (!textBefore.equals(text));
return text;
}
if (identifier.startsWith("placeholder_")) {
String requestedPlaceholder = "%" + identifier.substring("placeholder_".length()) + "%";
PlaceholderManagerImpl pm = TAB.getInstance().getPlaceholderManager();
pm.addUsedPlaceholder(requestedPlaceholder, pm);
Placeholder placeholder = pm.getPlaceholder(requestedPlaceholder);
if (placeholder instanceof RelationalPlaceholderImpl) {
RelationalPlaceholderImpl rel = (RelationalPlaceholderImpl) placeholder;
TabPlayer v = TAB.getInstance().getPlayer(viewer.getUniqueId());
TabPlayer t = TAB.getInstance().getPlayer(target.getUniqueId());
if (v == null || t == null) return "<Player is not loaded>";
return rel.getLastValue(v, t);
} else {
return "<Not a relational placeholder: " + requestedPlaceholder + ">";
}
}
return "<Unknown identifier: \"" + identifier + "\">";
}
@Override
@SuppressWarnings({"UnstableApiUsage", "deprecation"})
public void unregisterExpansion() {
if (ReflectionUtils.methodExists(PlaceholderExpansion.class, "unregister")) {
// Added in 2.10.7 (Jul 28, 2020)
unregister();
} else {
PlaceholderAPI.unregisterExpansion(this);
}
}
}
@@ -0,0 +1,179 @@
package me.neznamy.tab.platforms.bukkit.features;
import me.neznamy.tab.platforms.bukkit.platform.BukkitPlatform;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.TabConstants;
import me.neznamy.tab.shared.features.PerWorldPlayerListConfiguration;
import me.neznamy.tab.shared.features.types.Loadable;
import me.neznamy.tab.shared.features.types.TabFeature;
import me.neznamy.tab.shared.features.types.UnLoadable;
import me.neznamy.tab.shared.features.types.VanishListener;
import me.neznamy.tab.shared.platform.TabPlayer;
import me.neznamy.tab.shared.util.ReflectionUtils;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.HandlerList;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerChangedWorldEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.metadata.MetadataValue;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.java.JavaPlugin;
import org.jetbrains.annotations.NotNull;
import java.util.List;
import java.util.Map.Entry;
/**
* Per-world-PlayerList feature handler
*/
@SuppressWarnings("deprecation")
public class PerWorldPlayerList extends TabFeature implements Listener, Loadable, UnLoadable, VanishListener {
/** Reference to platform */
@NotNull
private final BukkitPlatform platform;
/** Config options */
@NotNull
private final PerWorldPlayerListConfiguration configuration;
/** Check for presence of modern (1.12.2+) methods that take plugin as argument to avoid conflict */
private final boolean modernMethodsAvailable = ReflectionUtils.methodExists(Player.class, "hidePlayer", Plugin.class, Player.class);
/**
* Constructs new instance and registers events.
*
* @param plugin
* Plugin instance to register events
* @param platform
* Platform reference
* @param configuration
* Feature configuration
*/
public PerWorldPlayerList(@NotNull JavaPlugin plugin, @NotNull BukkitPlatform platform, @NotNull PerWorldPlayerListConfiguration configuration) {
this.configuration = configuration;
this.platform = platform;
Bukkit.getPluginManager().registerEvents(this, plugin);
}
@Override
public void load() {
for (Player p : platform.getOnlinePlayers()) {
checkPlayer(p);
}
}
@Override
public void unload() {
for (Player p : platform.getOnlinePlayers()) {
for (Player pl : platform.getOnlinePlayers()) {
showPlayer(p, pl);
}
}
HandlerList.unregisterAll(this);
}
/**
* Join event listener to synchronously perform hiding.
*
* @param e
* Join event
*/
@EventHandler
public void onJoin(PlayerJoinEvent e) {
long time = System.nanoTime();
checkPlayer(e.getPlayer());
TAB.getInstance().getCPUManager().addTime(getFeatureName(), TabConstants.CpuUsageCategory.PLAYER_JOIN, System.nanoTime()-time);
}
/**
* World change listener to synchronously perform player showing/hiding.
*
* @param e
* World change event
*/
@EventHandler
public void onWorldChange(PlayerChangedWorldEvent e) {
long time = System.nanoTime();
checkPlayer(e.getPlayer());
TAB.getInstance().getCPUManager().addTime(getFeatureName(), TabConstants.CpuUsageCategory.WORLD_SWITCH, System.nanoTime()-time);
}
/**
* Performs visibility check on the player. Shows players this player should see and does not,
* hides players the player should not see, shows the player to those who should see player and hides
* from those, who should not see.
*
* @param p
* Player to update
*/
private void checkPlayer(@NotNull Player p) {
for (Player all : platform.getOnlinePlayers()) {
if (all == p) continue;
if (shouldSee(p, all)) {
showPlayer(p, all);
} else {
hidePlayer(p, all);
}
if (shouldSee(all, p)) {
showPlayer(all, p);
} else {
hidePlayer(all, p);
}
}
}
private void hidePlayer(@NotNull Player viewer, @NotNull Player target) {
if (modernMethodsAvailable) {
viewer.hidePlayer(platform.getPlugin(), target);
} else {
viewer.hidePlayer(target);
}
}
private void showPlayer(@NotNull Player viewer, @NotNull Player target) {
if (modernMethodsAvailable) {
viewer.showPlayer(platform.getPlugin(), target);
} else {
viewer.showPlayer(target);
}
}
/**
* Returns {@code true} if viewer should see target player, {@code false} if not.
* @param viewer
* Player viewing the TabList
* @param target
* Target displayed in the TabList
* @return {@code true} if viewer should see target, {@code false} if not.
*/
private boolean shouldSee(@NotNull Player viewer, @NotNull Player target) {
if (target == viewer) return true;
for (MetadataValue v : target.getMetadata("vanished")) {
if (v.asBoolean() && !viewer.hasPermission(TabConstants.Permission.SEE_VANISHED)) return false;
}
if ((configuration.isAllowBypassPermission() && viewer.hasPermission(TabConstants.Permission.PER_WORLD_PLAYERLIST_BYPASS)) || configuration.getIgnoredWorlds().contains(viewer.getWorld().getName())) return true;
String viewerWorldGroup = viewer.getWorld().getName() + "-default"; //preventing unwanted behavior when some group is called exactly like a world
String targetWorldGroup = target.getWorld().getName() + "-default";
for (Entry<String, List<String>> group : configuration.getSharedWorlds().entrySet()) {
if (group.getValue() != null) {
if (group.getValue().contains(viewer.getWorld().getName())) viewerWorldGroup = group.getKey();
if (group.getValue().contains(target.getWorld().getName())) targetWorldGroup = group.getKey();
}
}
return viewerWorldGroup.equals(targetWorldGroup);
}
@NotNull
@Override
public String getFeatureName() {
return "Per world PlayerList";
}
@Override
public void onVanishStatusChange(@NotNull TabPlayer player) {
platform.runSync((Player) player.getPlayer(), () -> checkPlayer((Player) player.getPlayer()));
}
}
@@ -0,0 +1,23 @@
package me.neznamy.tab.platforms.bukkit.hook;
import de.myzelyam.api.vanish.VanishAPI;
import me.neznamy.tab.api.TabPlayer;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.hook.PremiumVanishHook;
import org.jetbrains.annotations.NotNull;
/**
* PremiumVanish hook for Bukkit.
*/
public class BukkitPremiumVanishHook extends PremiumVanishHook {
@Override
public boolean canSee(@NotNull TabPlayer viewer, @NotNull TabPlayer target) {
return VanishAPI.canSee(((BukkitTabPlayer)viewer).getPlayer(), ((BukkitTabPlayer)target).getPlayer());
}
@Override
public boolean isVanished(@NotNull TabPlayer player) {
return VanishAPI.isInvisible(((BukkitTabPlayer)player).getPlayer());
}
}
@@ -0,0 +1,33 @@
package me.neznamy.tab.platforms.bukkit.hook;
import me.libraryaddict.disguise.DisguiseAPI;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.platform.TabPlayer;
import me.neznamy.tab.shared.util.ReflectionUtils;
/**
* Class for hooking into LibsDisguises to get disguise status of players.
*/
public class LibsDisguisesHook {
/** Flag tracking if LibsDisguises is installed or not */
private static boolean installed = ReflectionUtils.classExists("me.libraryaddict.disguise.DisguiseAPI");
/**
* Returns {@code true} if LibsDisguises is installed and player is disguised,
* {@code false} otherwise.
*
* @param player
* Player to check
* @return {@code true} if disguised, {@code false} otherwise
*/
public static boolean isDisguised(TabPlayer player) {
try {
return installed && DisguiseAPI.isDisguised(((BukkitTabPlayer)player).getPlayer());
} catch (LinkageError e) {
//java.lang.NoClassDefFoundError: Could not initialize class me.libraryaddict.disguise.DisguiseAPI
installed = false;
return false;
}
}
}
@@ -0,0 +1,502 @@
package me.neznamy.tab.platforms.bukkit.platform;
import lombok.Getter;
import lombok.Setter;
import lombok.SneakyThrows;
import me.clip.placeholderapi.PlaceholderAPI;
import me.clip.placeholderapi.PlaceholderAPIPlugin;
import me.clip.placeholderapi.expansion.PlaceholderExpansion;
import me.neznamy.tab.platforms.bukkit.BukkitEventListener;
import me.neznamy.tab.platforms.bukkit.BukkitPipelineInjector;
import me.neznamy.tab.platforms.bukkit.BukkitTabCommand;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.bossbar.BukkitBossBar;
import me.neznamy.tab.platforms.bukkit.bossbar.ViaBossBar;
import me.neznamy.tab.platforms.bukkit.features.BukkitTabExpansion;
import me.neznamy.tab.platforms.bukkit.features.PerWorldPlayerList;
import me.neznamy.tab.platforms.bukkit.hook.BukkitPremiumVanishHook;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.*;
import me.neznamy.tab.shared.backend.BackendPlatform;
import me.neznamy.tab.shared.chat.TabTextColor;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.chat.component.TabKeybindComponent;
import me.neznamy.tab.shared.chat.component.TabTextComponent;
import me.neznamy.tab.shared.chat.component.TabTranslatableComponent;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.shared.features.PerWorldPlayerListConfiguration;
import me.neznamy.tab.shared.features.injection.PipelineInjector;
import me.neznamy.tab.shared.features.types.TabFeature;
import me.neznamy.tab.shared.placeholders.expansion.EmptyTabExpansion;
import me.neznamy.tab.shared.placeholders.expansion.TabExpansion;
import me.neznamy.tab.shared.placeholders.types.PlayerPlaceholderImpl;
import me.neznamy.tab.shared.platform.BossBar;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabPlayer;
import me.neznamy.tab.shared.platform.impl.AdventureBossBar;
import me.neznamy.tab.shared.platform.impl.DummyBossBar;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.kyori.adventure.audience.Audience;
import org.bstats.bukkit.Metrics;
import org.bstats.charts.SimplePie;
import org.bukkit.Bukkit;
import org.bukkit.command.Command;
import org.bukkit.command.CommandSender;
import org.bukkit.command.PluginCommand;
import org.bukkit.command.SimpleCommandMap;
import org.bukkit.command.defaults.BukkitCommand;
import org.bukkit.entity.Entity;
import org.bukkit.entity.Player;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.java.JavaPlugin;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.io.File;
import java.util.*;
import java.util.function.BiConsumer;
/**
* Implementation of Platform interface for Bukkit platform
*/
@Getter
public class BukkitPlatform implements BackendPlatform {
/** Plugin instance for registering tasks and events */
@NotNull
private final JavaPlugin plugin;
/** Server version */
private final ProtocolVersion serverVersion = ProtocolVersion.fromFriendlyName(Bukkit.getBukkitVersion().split("-")[0]);
/** Variables checking presence of other plugins to hook into */
private final boolean placeholderAPI = ReflectionUtils.classExists("me.clip.placeholderapi.PlaceholderAPI");
/** Spigot field for tracking TPS, the array is final and only being modified instead of re-instantiated */
private double[] recentTps;
/** Detection for presence of Paper's TPS getter */
private final boolean paperTps = ReflectionUtils.methodExists(Bukkit.class, "getTPS");
/** Detection for presence of Paper's MSPT getter */
private final boolean paperMspt = ReflectionUtils.methodExists(Bukkit.class, "getAverageTickTime");
/** Package name of the server implementation, null on Paper 1.20.5+ / Spigot 26+ */
@Nullable
private final String serverPackage;
/** Implementation for creating new instances using content available on the server */
@NotNull
@Setter
private ImplementationProvider implementationProvider;
private final boolean modernOnlinePlayers;
/** Command map for dynamic command registering */
private final SimpleCommandMap commandMap;
private final Map<String, Command> knownCommands;
/** List of custom commands registered to be able to unregister them on reload */
private final List<Command> customCommands = new ArrayList<>();
/**
* Constructs new instance with given plugin.
*
* @param plugin
* Plugin
*/
@SneakyThrows
@SuppressWarnings("unchecked")
public BukkitPlatform(@NotNull JavaPlugin plugin) {
this.plugin = plugin;
modernOnlinePlayers = Bukkit.class.getMethod("getOnlinePlayers").getReturnType() == Collection.class;
String CRAFTBUKKIT_PACKAGE = Bukkit.getServer().getClass().getPackage().getName();
String[] array = CRAFTBUKKIT_PACKAGE.split("\\.");
serverPackage = array.length > 3 ? array[3] : null;
implementationProvider = findImplementationProvider();
logInfo(new TabTextComponent("Found NMS implementation: " + implementationProvider.getClass().getName(), TabTextColor.GRAY));
try {
Object server = Bukkit.getServer().getClass().getMethod("getServer").invoke(Bukkit.getServer());
recentTps = ((double[]) server.getClass().getField("recentTps").get(server));
} catch (ReflectiveOperationException ignored) {
//not spigot
}
if (Bukkit.getPluginManager().isPluginEnabled("PremiumVanish")) {
new BukkitPremiumVanishHook().register();
}
commandMap = (SimpleCommandMap) Bukkit.getServer().getClass().getMethod("getCommandMap").invoke(Bukkit.getServer());
knownCommands = (Map<String, Command>) ReflectionUtils.getField(SimpleCommandMap.class, "knownCommands").get(commandMap);
}
/**
* Finds implementation provider for current server software and version.
*
* @return Implementation provider for current server
* @throws IllegalStateException
* If no implementation was found
*/
@NotNull
private ImplementationProvider findImplementationProvider() {
if (serverPackage != null) {
// Paper <1.20.5 or Spigot 1.x
try {
// Does not actually support flat 1.19, but whatever, no one is using it anyway
return (ImplementationProvider) Class.forName("me.neznamy.tab.platforms.bukkit." + serverPackage + ".NMSImplementationProvider").getConstructor().newInstance();
} catch (ReflectiveOperationException ignored) {
throw new IllegalStateException("Implementation for version \"" + serverPackage + "\" was not found.");
}
}
Map<ProtocolVersion, String> spigotVersions = new LinkedHashMap<>();
spigotVersions.put(ProtocolVersion.V26_1, "v26_1");
Map<ProtocolVersion, String> paperVersions = new LinkedHashMap<>();
paperVersions.put(ProtocolVersion.V1_20_5, "paper_1_20_5");
paperVersions.put(ProtocolVersion.V1_20_6, "paper_1_20_5");
paperVersions.put(ProtocolVersion.V1_21, "paper_1_20_5");
paperVersions.put(ProtocolVersion.V1_21_1, "paper_1_20_5");
paperVersions.put(ProtocolVersion.V1_21_2, "paper_1_21_2");
paperVersions.put(ProtocolVersion.V1_21_3, "paper_1_21_2");
paperVersions.put(ProtocolVersion.V1_21_4, "paper_1_21_4");
paperVersions.put(ProtocolVersion.V1_21_5, "paper_1_21_4");
paperVersions.put(ProtocolVersion.V1_21_6, "paper_1_21_4");
paperVersions.put(ProtocolVersion.V1_21_7, "paper_1_21_4");
paperVersions.put(ProtocolVersion.V1_21_8, "paper_1_21_4");
paperVersions.put(ProtocolVersion.V1_21_9, "paper_1_21_9");
paperVersions.put(ProtocolVersion.V1_21_10, "paper_1_21_9");
paperVersions.put(ProtocolVersion.V1_21_11, "paper_1_21_11");
String software;
Map<ProtocolVersion, String> versions;
if (paperTps) { // This needs a better check
software = "Paper";
versions = paperVersions;
} else {
software = "Spigot";
versions = spigotVersions;
}
String serverVersionString = Bukkit.getBukkitVersion().split("-")[0];
String implementation = versions.get(serverVersion);
if (implementation == null) {
throw new IllegalStateException(String.format("No implementation is available for your server version (%s %s).", software, serverVersionString));
}
try {
return (ImplementationProvider) Class.forName("me.neznamy.tab.platforms.bukkit." + implementation + ".NMSImplementationProvider").getConstructor().newInstance();
} catch (ClassNotFoundException e) {
throw new IllegalStateException(String.format("Your server version (%s %s) is marked as compatible, but the implementation does not exist. This is probably a bug.", software, serverVersionString), e);
} catch (ReflectiveOperationException e) {
throw new IllegalStateException(String.format("Failed to initialize implementation for %s %s. This is probably a bug.", software, serverVersionString), e);
}
}
@Override
public void loadPlayers() {
for (Player p : getOnlinePlayers()) {
TAB.getInstance().addPlayer(new BukkitTabPlayer(this, p));
}
}
@Override
@Nullable
public PipelineInjector createPipelineInjector() {
return ReflectionUtils.classExists("io.netty.channel.Channel") ? new BukkitPipelineInjector() : null;
}
@Override
@NotNull
public TabExpansion createTabExpansion() {
if (placeholderAPI) {
BukkitTabExpansion expansion = new BukkitTabExpansion();
expansion.register();
return expansion;
}
return new EmptyTabExpansion();
}
@Override
@Nullable
public TabFeature getPerWorldPlayerList(@NotNull PerWorldPlayerListConfiguration configuration) {
return new PerWorldPlayerList(plugin, this, configuration);
}
@Override
public void registerUnknownPlaceholder(@NotNull String identifier) {
if (!placeholderAPI) {
registerDummyPlaceholder(identifier);
return;
}
if (identifier.startsWith("%rel_")) {
//relational placeholder
TAB.getInstance().getPlaceholderManager().registerRelationalPlaceholder(identifier, (viewer, target) ->
PlaceholderAPI.setRelationalPlaceholders((Player) viewer.getPlayer(), (Player) target.getPlayer(), identifier));
} else if (identifier.startsWith("%sync:")) {
registerSyncPlaceholder(identifier);
} else if (identifier.startsWith("%server_")) {
boolean stripLeadingAsterisk = identifier.startsWith("%server_tps");
TAB.getInstance().getPlaceholderManager().registerServerPlaceholder(identifier,
() -> {
String out = PlaceholderAPI.setPlaceholders(null, identifier);
return stripLeadingAsterisk && out != null && out.startsWith("*") ? out.substring(1) : out;
});
} else {
TAB.getInstance().getPlaceholderManager().registerPlayerPlaceholder(identifier,
p -> PlaceholderAPI.setPlaceholders((Player) p.getPlayer(), identifier));
}
}
/**
* Registers a sync placeholder with given identifier and automatically decided refresh.
*
* @param identifier
* Placeholder identifier
*/
public void registerSyncPlaceholder(@NotNull String identifier) {
String syncedPlaceholder = "%" + identifier.substring(6);
PlayerPlaceholderImpl[] ppl = new PlayerPlaceholderImpl[1];
ppl[0] = TAB.getInstance().getPlaceholderManager().registerPlayerPlaceholder(identifier, p -> {
Bukkit.getScheduler().runTask(plugin, () -> {
long time = System.nanoTime();
ppl[0].updateValue(p, placeholderAPI ? PlaceholderAPI.setPlaceholders((Player) p.getPlayer(), syncedPlaceholder) : identifier);
long totalTime = System.nanoTime()-time;
TAB.getInstance().getCPUManager().addPlaceholderTime(identifier, totalTime);
TAB.getInstance().getCpu().addTime(TAB.getInstance().getPlaceholderManager().getFeatureName(), TabConstants.CpuUsageCategory.PLACEHOLDER_REQUEST, totalTime);
});
return null;
});
}
@Override
public void logInfo(@NotNull TabComponent message) {
Bukkit.getConsoleSender().sendMessage("[TAB] " + toBukkitFormat(message));
}
@Override
public void logWarn(@NotNull TabComponent message) {
Bukkit.getConsoleSender().sendMessage("§c[TAB] [WARN] " + toBukkitFormat(message));
}
@Override
public void registerListener() {
Bukkit.getPluginManager().registerEvents(new BukkitEventListener(this), plugin);
}
@Override
public void registerCommand() {
PluginCommand command = Bukkit.getPluginCommand(getCommand());
if (command != null) {
BukkitTabCommand cmd = new BukkitTabCommand();
command.setExecutor(cmd);
command.setTabCompleter(cmd);
} else {
logWarn(new TabTextComponent("Failed to register command, is it defined in plugin.yml?", TabTextColor.RED));
}
}
@Override
public void startMetrics() {
Metrics metrics = new Metrics(plugin, TabConstants.BSTATS_PLUGIN_ID_BUKKIT);
metrics.addCustomChart(new SimplePie(TabConstants.MetricsChart.PERMISSION_SYSTEM,
() -> TAB.getInstance().getGroupManager().getPermissionPlugin()));
metrics.addCustomChart(new SimplePie("tab_6_0_0_servers", serverVersion::getFriendlyName));
}
@Override
@NotNull
public File getDataFolder() {
return plugin.getDataFolder();
}
@Override
@NotNull
public Object convertComponent(@NotNull TabComponent component) {
return implementationProvider.getComponentConverter().convert(component);
}
@Override
@NotNull
public Scoreboard createScoreboard(@NotNull TabPlayer player) {
return implementationProvider.newScoreboard((BukkitTabPlayer) player);
}
@Override
@NotNull
public BossBar createBossBar(@NotNull TabPlayer player) {
//noinspection ConstantValue
if (AdventureBossBar.isAvailable() && Audience.class.isAssignableFrom(Player.class)) return new AdventureBossBar(player);
// 1.9+ server, handle using API, potential 1.8 players are handled by ViaVersion
if (BukkitBossBar.isAvailable()) return new BukkitBossBar((BukkitTabPlayer) player);
// 1.9+ player on 1.8 server, handle using ViaVersion API
if (player.getVersion().getNetworkId() >= ProtocolVersion.V1_9.getNetworkId()) return new ViaBossBar((BukkitTabPlayer) player);
// 1.8- server and player, no implementation
return new DummyBossBar();
}
@Override
@NotNull
public TabList createTabList(@NotNull TabPlayer player) {
return implementationProvider.newTabList((BukkitTabPlayer) player);
}
@Override
public boolean supportsScoreboards() {
return true;
}
@Override
public boolean supportsListed() {
return serverVersion.getNetworkId() >= ProtocolVersion.V1_19_3.getNetworkId();
}
@Override
public boolean supportsListOrder() {
return serverVersion.getNetworkId() >= ProtocolVersion.V1_21_2.getNetworkId();
}
@Override
public boolean isSafeFromPacketEventsBug() {
return serverVersion.getMinorVersion() >= 13;
}
@Override
public void registerCustomCommand(@NotNull String commandName, @NotNull BiConsumer<TabPlayer, String[]> function) {
Command cmd = new BukkitCommand(commandName) {
@Override
public boolean execute(@NotNull CommandSender commandSender, @NotNull String alias, @NotNull String[] args) {
if (commandSender instanceof Player) {
TabPlayer p = TAB.getInstance().getPlayer(((Player) commandSender).getUniqueId());
if (p == null) return false; //player not loaded correctly
function.accept(p, args);
} else {
commandSender.sendMessage(toBukkitFormat(
TabComponent.fromColoredText(TAB.getInstance().getConfiguration().getMessages().getCommandOnlyFromGame())
));
}
return false;
}
};
commandMap.register(commandName, cmd);
customCommands.add(cmd);
}
@Override
public void unregisterAllCustomCommands() {
for (Command command : customCommands) {
knownCommands.remove(command.getName());
knownCommands.remove(command.getName() + ":" + command.getName());
command.unregister(commandMap);
}
}
@Override
public double getTPS() {
if (recentTps != null) {
return recentTps[0];
} else if (paperTps) {
return Bukkit.getTPS()[0];
} else {
return -1;
}
}
@Override
public double getMSPT() {
if (paperMspt) return Bukkit.getAverageTickTime();
return -1;
}
/**
* Runs task in the main thread for given entity.
*
* @param entity
* Entity's main thread
* @param task
* Task to run
*/
public void runSync(@NotNull Entity entity, @NotNull Runnable task) {
Bukkit.getScheduler().runTask(plugin, task);
}
/**
* Converts component to string using bukkit RGB format if supported by the server.
* If not, closest legacy color is used instead.
*
* @param component
* Component to convert
* @return Converted string using bukkit color format
*/
@NotNull
public String toBukkitFormat(@NotNull TabComponent component) {
StringBuilder sb = new StringBuilder();
if (component.getModifier().getColor() != null) {
if (serverVersion.getNetworkId() >= ProtocolVersion.V1_16.getNetworkId()) {
String hexCode = component.getModifier().getColor().getHexCode();
sb.append('§').append("x").append('§').append(hexCode.charAt(0)).append('§').append(hexCode.charAt(1))
.append('§').append(hexCode.charAt(2)).append('§').append(hexCode.charAt(3))
.append('§').append(hexCode.charAt(4)).append('§').append(hexCode.charAt(5));
} else {
sb.append('§').append(component.getModifier().getColor().getLegacyColor().getCharacter());
}
}
sb.append(component.getModifier().getMagicCodes());
if (component instanceof TabTextComponent) {
sb.append(((TabTextComponent) component).getText());
} else if (component instanceof TabTranslatableComponent) {
sb.append(((TabTranslatableComponent) component).getKey());
} else if (component instanceof TabKeybindComponent) {
sb.append(((TabKeybindComponent) component).getKeybind());
} else if (component instanceof TabObjectComponent) {
sb.append(component.toLegacyText());
} else {
throw new IllegalStateException("Unexpected component type: " + component.getClass().getName());
}
for (TabComponent extra : component.getExtra()) {
sb.append(toBukkitFormat(extra));
}
return sb.toString();
}
/**
* Returns online players from Bukkit API.
* This method may use reflections, because the return type changed in 1.7.10,
* and we want to avoid errors.
*
* @return Online players from Bukkit API.
*/
@SneakyThrows
@NotNull
public Collection<? extends Player> getOnlinePlayers() {
if (modernOnlinePlayers) {
return Bukkit.getOnlinePlayers();
}
return Arrays.asList((Player[]) Bukkit.class.getMethod("getOnlinePlayers").invoke(null));
}
@Override
@NotNull
public Object dump() {
Map<String, Object> map = new LinkedHashMap<>();
map.put("server-type", "Bukkit");
map.put("server-name", Bukkit.getName());
map.put("server-version", Bukkit.getBukkitVersion().split("-")[0]);
map.put("craftbukkit-package", serverPackage);
map.put("tab-version", ProjectVariables.PLUGIN_VERSION);
Map<String, Object> plugins = new LinkedHashMap<>();
for (Plugin p : Bukkit.getPluginManager().getPlugins()) {
plugins.put(p.getDescription().getName(), p.getDescription().getVersion());
}
map.put("plugins", plugins);
if (placeholderAPI) {
Map<String, String> expansions = new LinkedHashMap<>();
for (PlaceholderExpansion p : PlaceholderAPIPlugin.getInstance().getLocalExpansionManager().getExpansions()) {
expansions.put(p.getIdentifier(), p.getVersion());
}
map.put("placeholderapi-expansions", expansions);
}
return map;
}
}
@@ -0,0 +1,146 @@
package me.neznamy.tab.platforms.bukkit.platform;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.clip.placeholderapi.PlaceholderAPI;
import me.neznamy.tab.platforms.bukkit.features.PerWorldPlayerList;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.TabConstants;
import me.neznamy.tab.shared.cpu.TimedCaughtTask;
import me.neznamy.tab.shared.data.World;
import me.neznamy.tab.shared.placeholders.types.PlayerPlaceholderImpl;
import me.neznamy.tab.shared.platform.TabPlayer;
import org.bukkit.Bukkit;
import org.bukkit.entity.Entity;
import org.bukkit.entity.Player;
import org.bukkit.event.player.PlayerChangedWorldEvent;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.java.JavaPlugin;
import org.jetbrains.annotations.NotNull;
import java.text.DecimalFormat;
import java.text.DecimalFormatSymbols;
import java.util.function.Consumer;
import java.util.function.Function;
/**
* Platform override for Folia.
*/
public class FoliaPlatform extends BukkitPlatform {
/**
* Constructs new instance with given plugin.
*
* @param plugin
* Plugin
*/
public FoliaPlatform(@NotNull JavaPlugin plugin) {
super(plugin);
}
@Override
public void loadPlayers() {
super.loadPlayers();
// Folia never calls PlayerChangedWorldEvent, this is a workaround
TAB.getInstance().getCpu().getProcessingThread().repeatTask(new TimedCaughtTask(TAB.getInstance().getCpu(), () -> {
for (TabPlayer player : TAB.getInstance().getOnlinePlayers()) {
World actualWorld = World.byName(((Player) player.getPlayer()).getWorld().getName());
if (player.world != actualWorld) {
TAB.getInstance().getFeatureManager().onWorldChange(player.getUniqueId(), actualWorld);
PerWorldPlayerList pwp = TAB.getInstance().getFeatureManager().getFeature(TabConstants.Feature.PER_WORLD_PLAYER_LIST);
if (pwp != null) {
runSync((Entity) player.getPlayer(), () -> pwp.onWorldChange(new PlayerChangedWorldEvent((Player) player.getPlayer(), ((Player) player.getPlayer()).getWorld())));
}
}
}
}, "Folia compatibility", "Refreshing world"), 100);
}
@Override
public void registerPlaceholders() {
super.registerPlaceholders();
DecimalFormat decimal2;
DecimalFormatSymbols symbols = new DecimalFormatSymbols();
symbols.setDecimalSeparator('.');
decimal2 = new DecimalFormat("#.##", symbols);
registerInternalSyncPlaceholder(TabConstants.Placeholder.MSPT, p -> decimal2.format(Bukkit.getAverageTickTime()));
registerInternalSyncPlaceholder(TabConstants.Placeholder.TPS, p -> decimal2.format(Math.min(20, Bukkit.getTPS()[0])));
}
@Override
public void registerSyncPlaceholder(@NotNull String identifier) {
String syncedPlaceholder = "%" + identifier.substring(6);
PlayerPlaceholderImpl[] ppl = new PlayerPlaceholderImpl[1];
ppl[0] = TAB.getInstance().getPlaceholderManager().registerPlayerPlaceholder(identifier, p -> {
runSync((Entity) p.getPlayer(), () -> {
long time = System.nanoTime();
String output = isPlaceholderAPI() ? PlaceholderAPI.setPlaceholders((Player) p.getPlayer(), syncedPlaceholder) : identifier;
long totalTime = System.nanoTime()-time;
TAB.getInstance().getCPUManager().addPlaceholderTime(identifier, totalTime);
TAB.getInstance().getCpu().addTime(TAB.getInstance().getPlaceholderManager().getFeatureName(), TabConstants.CpuUsageCategory.PLACEHOLDER_REQUEST, totalTime);
TAB.getInstance().getCPUManager().runTask(() -> ppl[0].updateValue(p, output)); // To ensure player is loaded
});
return null;
});
}
private void registerInternalSyncPlaceholder(@NonNull String identifier, @NonNull Function<TabPlayer, String> function) {
PlayerPlaceholderImpl[] ppl = new PlayerPlaceholderImpl[1];
ppl[0] = TAB.getInstance().getPlaceholderManager().registerPlayerPlaceholder(identifier, p -> {
runSync((Entity) p.getPlayer(), () -> {
long time = System.nanoTime();
String output = function.apply((TabPlayer) p);
long totalTime = System.nanoTime()-time;
TAB.getInstance().getCPUManager().addPlaceholderTime(identifier, totalTime);
TAB.getInstance().getCpu().addTime(TAB.getInstance().getPlaceholderManager().getFeatureName(), TabConstants.CpuUsageCategory.PLACEHOLDER_REQUEST, totalTime);
TAB.getInstance().getCPUManager().runTask(() -> ppl[0].updateValue(p, output)); // To ensure player is loaded
});
return null;
});
}
/**
* Overriding the method to fix initial error caused by ServerPlaceholder implementation trying to
* retrieve the value in constructor, but folia does not support that. Overriding this function to avoid the
* MSPT function being called in the wrong thread.
*
* @return -1
*/
@Override
public double getMSPT() {
return -1;
}
/**
* Overriding the method to fix initial error caused by ServerPlaceholder implementation trying to
* retrieve the value in constructor, but folia does not support that. Overriding this function to avoid the
* TPS function being called in the wrong thread.
*
* @return -1
*/
@Override
public double getTPS() {
return -1;
}
/**
* Runs task using player's entity scheduler. It's using reflection, because
* Folia uses Java 17 while TAB maintains Java 8 compatibility for compatibility
* with MC versions older than their player base.
*
* @param entity
* entity to run task for
* @param task
* Task to run
*/
@Override
@SneakyThrows
@SuppressWarnings("JavaReflectionMemberAccess")
public void runSync(@NotNull Entity entity, @NotNull Runnable task) {
Object entityScheduler = Entity.class.getMethod("getScheduler").invoke(entity);
Consumer<?> consumer = $ -> task.run(); // Reflection and lambdas don't go together
entityScheduler.getClass().getMethod("run", Plugin.class, Consumer.class, Runnable.class)
.invoke(entityScheduler, getPlugin(), consumer, null);
}
}
@@ -0,0 +1,134 @@
package me.neznamy.tab.platforms.bukkit.provider;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.TabKeybindComponent;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.shared.chat.component.TabTextComponent;
import me.neznamy.tab.shared.chat.component.TabTranslatableComponent;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import org.jetbrains.annotations.NotNull;
import java.util.UUID;
/**
* Interface for converting TAB components into NMS components (1.7+).
*
* @param <T>
* NMS component type
*/
public abstract class ComponentConverter<T> {
/** Empty UUID for creating dummy profiles */
protected final UUID NIL_UUID = new UUID(0, 0);
/**
* Converts TAB component to NMS component.
*
* @param component
* Component to convert
* @return Converted component
*/
@NotNull
public T convert(@NotNull TabComponent component) {
// Component type
T nmsComponent;
if (component instanceof TabTextComponent) {
nmsComponent = newTextComponent(((TabTextComponent) component).getText());
} else if (component instanceof TabTranslatableComponent) {
nmsComponent = newTranslatableComponent(((TabTranslatableComponent) component).getKey());
} else if (component instanceof TabKeybindComponent) {
nmsComponent = newKeybindComponent(((TabKeybindComponent)component).getKeybind());
} else if (component instanceof TabObjectComponent) {
if ((((TabObjectComponent) component).getContents() instanceof TabAtlasSprite)) {
nmsComponent = newObjectComponent((TabAtlasSprite) ((TabObjectComponent) component).getContents());
} else if ((((TabObjectComponent) component).getContents() instanceof TabPlayerSprite)) {
nmsComponent = newObjectComponent((TabPlayerSprite) ((TabObjectComponent) component).getContents());
} else {
throw new IllegalArgumentException("Unexpected object component type: " + ((TabObjectComponent) component).getContents().getClass().getName());
}
} else {
throw new IllegalArgumentException("Unexpected component type: " + component.getClass().getName());
}
// Component style
applyStyle(nmsComponent, component.getModifier());
// Extra
for (TabComponent extra : component.getExtra()) {
addSibling(nmsComponent, convert(extra));
}
return nmsComponent;
}
/**
* Creates a new text component with given text.
*
* @param text
* Text to display
* @return Text component with given text
*/
@NotNull
public abstract T newTextComponent(@NotNull String text);
/**
* Creates a new translatable component with the given key.
*
* @param key
* Key to translate
* @return Translatable component with the given key
*/
@NotNull
public abstract T newTranslatableComponent(@NotNull String key);
/**
* Creates a new keybind component with given keybind.
*
* @param keybind
* Keybind to show
* @return Keybind component with given keybind
*/
@NotNull
public abstract T newKeybindComponent(@NotNull String keybind);
/**
* Creates a new object component with given atlas and sprite.
*
* @param sprite Sprite to use
* @return Object component with given atlas and sprite
*/
@NotNull
public abstract T newObjectComponent(@NotNull TabAtlasSprite sprite);
/**
* Creates a new head component with given skin.
*
* @param sprite
* Skin to use
* @return Head component with given skin
*/
@NotNull
public abstract T newObjectComponent(@NotNull TabPlayerSprite sprite);
/**
* Converts given chat modifier to minecraft style and applies it to the component.
*
* @param nmsComponent
* Component to apply style to
* @param style
* Style to convert and apply
*/
public abstract void applyStyle(@NotNull T nmsComponent, @NotNull TabStyle style);
/**
* Appends child to the given parent component.
*
* @param parent
* Parent to append the child to
* @param child
* Child component to append
*/
public abstract void addSibling(@NotNull T parent, @NotNull T child);
}
@@ -0,0 +1,71 @@
package me.neznamy.tab.platforms.bukkit.provider;
import io.netty.channel.Channel;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/**
* An interface to provide platform-specific implementations of various features in various Minecraft versions.
*/
public interface ImplementationProvider {
/**
* Creates a new instance of scoreboard for the given player.
*
* @param player
* Player to create scoreboard for
* @return Newly created scoreboard
*/
@NotNull
Scoreboard newScoreboard(@NotNull BukkitTabPlayer player);
/**
* Creates a new instance of tab list for the given player.
*
* @param player
* Player to create tab list for
* @return Newly created tab list
*/
@NotNull
TabList newTabList(@NotNull BukkitTabPlayer player);
/**
* Returns component converter to be used for converting TAB components to NMS components.
*
* @return Component converter
*/
@NotNull
ComponentConverter<?> getComponentConverter();
/**
* Gets player's channel. If not available, returns {@code null}.
*
* @param player
* Player to get channel of
* @return Player's channel or {@code null} if not supported
*/
@Nullable
Channel getChannel(@NotNull Player player);
/**
* Creates a new instance of tab list entry tracker.
*
* @return Newly created tab list entry tracker
*/
@NotNull
TabListEntryTracker newTabListEntryTracker();
/**
* Returns ping of the given player.
*
* @param player
* Player to get ping of
* @return Player's ping
*/
int getPing(@NotNull BukkitTabPlayer player);
}
+101
View File
@@ -0,0 +1,101 @@
main: me.neznamy.tab.platforms.bukkit.BukkitTAB
name: @name@
version: @version@
description: @description@
api-version: 1.13 # Defining to avoid legacy plugin warn
load: POSTWORLD
author: @author@
website: "@website@"
depend:
- LuckPerms
softdepend: [PlaceholderAPI, LibsDisguises, ViaVersion, ViaRewind, floodgate]
prefix: TAB
folia-supported: true
commands:
tab:
description: Plugin's main command
permissions:
tab.admin:
description: Grants all TAB permissions
default: op
tab.tabcomplete:
description: Allows player to complete all TAB commands
default: op
tab.reload:
description: Allows player to run /tab reload
default: op
tab.cpu:
description: Allows player to run /tab cpu
default: op
tab.dump:
description: Allows player to run /tab dump <player>
default: op
tab.groupinfo:
description: Allows player to run /tab group <group>
default: op
tab.grouplist:
description: Allows player to run /tab groups
default: op
tab.parse:
description: Allows player to run /tab parse <player> <placeholder>
default: op
tab.setcollision:
description: Allows player to run /tab setcollision <player> <true/false>
default: op
tab.remove:
description: Allows player to remove group/user using commands
default: op
tab.change.*:
description: Allows player to change property using command
default: op
tab.announce.bar:
description: Allows player to run /tab bossbar announce
default: op
tab.bossbar.toggle:
description: Allows player to run /tab bossbar
default: op
tab.send.bar:
description: Allows player to run /tab bossbar send
default: op
tab.mysql.download:
description: Allows player to run /tab mysql download
default: op
tab.mysql.upload:
description: Allows player to run /tab mysql upload
default: op
tab.nametag.toggle:
description: Allows player to run /tab nametag toggle
default: op
tab.nametag.toggle.other:
description: Allows player to run /tab nametag toggle [other player]
default: op
tab.announce.scoreboard:
description: Allows player to run /tab scoreboard announce
default: op
tab.scoreboard.toggle:
description: Allows player to run /tab scoreboard
default: op
tab.scoreboard.toggle.other:
description: Allows player to run /tab scoreboard for other players
default: op
tab.scoreboard.show:
description: Allows player to run /tab scoreboard show
default: op
tab.scoreboard.show.other:
description: Allows player to run /tab scoreboard show for other players
default: op
tab.staff:
description: Makes player counted in %staffonline% placeholder
default: op
tab.group.*:
description: Considers player in group if assigning by permissions
default: op
tab.bypass:
description: Makes player bypass per world playerlist if bypass permission is enabled
default: op
tab.seevanished:
description: Marks player as able to see vanished players for features hooking into vanish plugins
default: op
tab.spectatorbypass:
description: Makes player bypass spectator fix
default: op
+4
View File
@@ -0,0 +1,4 @@
dependencies {
implementation(projects.bukkit)
compileOnly("org.bukkit:craftbukkit:1.10.2-R0.1-SNAPSHOT")
}
@@ -0,0 +1,62 @@
package me.neznamy.tab.platforms.bukkit.v1_10_R1;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import net.minecraft.server.v1_10_R1.*;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct NMS code.
*/
public class NMSComponentConverter extends ComponentConverter<IChatBaseComponent> {
@Override
@NotNull
public IChatBaseComponent newTextComponent(@NotNull String text) {
return new ChatComponentText(text);
}
@Override
@NotNull
public IChatBaseComponent newTranslatableComponent(@NotNull String key) {
return new ChatMessage(key);
}
@Override
@NotNull
public IChatBaseComponent newKeybindComponent(@NotNull String keybind) {
return new ChatComponentText("<Keybind components were added in 1.12>");
}
@Override
@NotNull
public IChatBaseComponent newObjectComponent(@NotNull TabAtlasSprite sprite) {
return new ChatComponentText(TabObjectComponent.ERROR_MESSAGE);
}
@Override
@NotNull
public IChatBaseComponent newObjectComponent(@NotNull TabPlayerSprite sprite) {
return new ChatComponentText(TabObjectComponent.ERROR_MESSAGE);
}
@Override
public void applyStyle(@NotNull IChatBaseComponent nmsComponent, @NotNull TabStyle modifier) {
nmsComponent.setChatModifier(new ChatModifier()
.setColor(modifier.getColor() == null ? null : EnumChatFormat.valueOf(modifier.getColor().getLegacyColor().name()))
.setBold(modifier.getBold())
.setItalic(modifier.getItalic())
.setUnderline(modifier.getUnderlined())
.setStrikethrough(modifier.getStrikethrough())
.setRandom(modifier.getObfuscated())
);
}
@Override
public void addSibling(@NotNull IChatBaseComponent parent, @NotNull IChatBaseComponent child) {
parent.addSibling(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.v1_10_R1;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.v1_10_R1.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct NMS code for 1.10.x.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().playerConnection.networkManager.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return ((CraftPlayer)player.getPlayer()).getHandle().ping;
}
}
@@ -0,0 +1,164 @@
package me.neznamy.tab.platforms.bukkit.v1_10_R1;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.Limitations;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.server.v1_10_R1.*;
import org.bukkit.craftbukkit.v1_10_R1.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
/**
* Scoreboard implementation using direct NMS code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ScoreboardTeamBase.EnumNameTagVisibility[] visibilities = ScoreboardTeamBase.EnumNameTagVisibility.values();
private static final ScoreboardTeamBase.EnumTeamPush[] collisions = ScoreboardTeamBase.EnumTeamPush.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final IScoreboardCriteria INTEGER = new ScoreboardBaseCriteria("dummy");
private static final IScoreboardCriteria HEARTS = new ScoreboardHealthCriteria("health");
private static final Field TeamPacket_NAME = ReflectionUtils.getFields(PacketPlayOutScoreboardTeam.class, String.class).get(0);
private static final Field TeamPacket_ACTION = ReflectionUtils.getInstanceFields(PacketPlayOutScoreboardTeam.class, int.class).get(1);
private static final Field TeamPacket_PLAYERS = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardTeam.class, Collection.class);
private static final Field Objective_OBJECTIVE_NAME = ReflectionUtils.getFields(PacketPlayOutScoreboardObjective.class, String.class).get(0);
private static final Field Objective_METHOD = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardObjective.class, int.class);
private static final Field DisplayObjective_OBJECTIVE_NAME = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardDisplayObjective.class, String.class);
private static final Field DisplayObjective_POSITION = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardDisplayObjective.class, int.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
IScoreboardCriteria healthDisplay = objective.getHealthDisplay() == HealthDisplay.INTEGER ? INTEGER : HEARTS;
ScoreboardObjective obj = new ScoreboardObjective(dummyScoreboard, objective.getName(), healthDisplay);
obj.setDisplayName(maybeCut(objective.getTitle().toLegacyText(), Limitations.SCOREBOARD_TITLE_PRE_1_13));
objective.setPlatformObjective(obj);
sendPacket(new PacketPlayOutScoreboardObjective(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new PacketPlayOutScoreboardDisplayObjective(objective.getDisplaySlot().ordinal(), (ScoreboardObjective) objective.getPlatformObjective()));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new PacketPlayOutScoreboardObjective((ScoreboardObjective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
IScoreboardCriteria healthDisplay = objective.getHealthDisplay() == HealthDisplay.INTEGER ? INTEGER : HEARTS;
ScoreboardObjective obj = new ScoreboardObjective(dummyScoreboard, objective.getName(), healthDisplay);
obj.setDisplayName(maybeCut(objective.getTitle().toLegacyText(), Limitations.SCOREBOARD_TITLE_PRE_1_13));
sendPacket(new PacketPlayOutScoreboardObjective(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
ScoreboardScore s = new ScoreboardScore(dummyScoreboard, (ScoreboardObjective) score.getObjective().getPlatformObjective(), score.getHolder());
s.setScore(score.getValue());
sendPacket(new PacketPlayOutScoreboardScore(s));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new PacketPlayOutScoreboardScore(score.getHolder()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new ScoreboardTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
ScoreboardTeam t = (ScoreboardTeam) team.getPlatformTeam();
t.getPlayerNameSet().addAll(team.getPlayers());
sendPacket(new PacketPlayOutScoreboardTeam(t, TeamAction.CREATE));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(new PacketPlayOutScoreboardTeam((ScoreboardTeam) team.getPlatformTeam(), TeamAction.REMOVE));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(new PacketPlayOutScoreboardTeam((ScoreboardTeam) team.getPlatformTeam(), TeamAction.UPDATE));
}
private void updateTeamProperties(@NonNull Team team) {
ScoreboardTeam t = (ScoreboardTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setCanSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setPrefix(maybeCut(team.getPrefix().toLegacyText(), Limitations.TEAM_PREFIX_SUFFIX_PRE_1_13));
t.setSuffix(maybeCut(team.getSuffix().toLegacyText(), Limitations.TEAM_PREFIX_SUFFIX_PRE_1_13));
}
@Override
@SneakyThrows
@SuppressWarnings("unchecked")
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof PacketPlayOutScoreboardDisplayObjective) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, DisplayObjective_POSITION.getInt(packet),
(String) DisplayObjective_OBJECTIVE_NAME.get(packet));
}
if (packet instanceof PacketPlayOutScoreboardObjective) {
TAB.getInstance().getFeatureManager().onObjective(player,
Objective_METHOD.getInt(packet), (String) Objective_OBJECTIVE_NAME.get(packet));
}
if (packet instanceof PacketPlayOutScoreboardTeam) {
int action = TeamPacket_ACTION.getInt(packet);
if (action != TeamAction.UPDATE) {
Collection<String> players = (Collection<String>) TeamPacket_PLAYERS.get(packet);
if (players == null) players = Collections.emptyList();
TeamPacket_PLAYERS.set(packet, onTeamPacket(action, (String) TeamPacket_NAME.get(packet), players));
}
}
return packet;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().playerConnection.sendPacket(packet);
}
@NotNull
private String maybeCut(@NonNull String string, int length) {
if (player.getVersion().getMinorVersion() < 13 || TAB.getInstance().getConfiguration().getConfig().isPacketEventsCompensation()) {
return cutTo(string, length);
}
return string;
}
}
@@ -0,0 +1,232 @@
package me.neznamy.tab.platforms.bukkit.v1_10_R1;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.shared.chat.component.TabComponent;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.decorators.TrackedTabList;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.server.v1_10_R1.*;
import net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo.EnumPlayerInfoAction;
import org.bukkit.craftbukkit.v1_10_R1.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.util.*;
/**
* TabList implementation using direct NMS code.
*/
public class NMSPacketTabList extends TrackedTabList<BukkitTabPlayer> {
// PlayerInfoData subclass is broken, using reflection to get it
private static final Class<?> PlayerInfoData = Arrays.stream(PacketPlayOutPlayerInfo.class.getDeclaredClasses()).filter(c -> !c.isEnum() && c.getConstructors().length > 0).findFirst().get();
private static final Constructor<?> newPlayerInfoData = ReflectionUtils.getOnlyConstructor(PlayerInfoData);
private static final Field ACTION = ReflectionUtils.getOnlyField(PacketPlayOutPlayerInfo.class, EnumPlayerInfoAction.class);
private static final Field PLAYERS = ReflectionUtils.getOnlyField(PacketPlayOutPlayerInfo.class, List.class);
private static final Field PlayerInfoData_Profile = ReflectionUtils.getOnlyField(PlayerInfoData, GameProfile.class);
private static final Field PlayerInfoData_Latency = ReflectionUtils.getFields(PlayerInfoData, int.class).get(0);
private static final Field PlayerInfoData_DisplayName = ReflectionUtils.getOnlyField(PlayerInfoData, IChatBaseComponent.class);
private static final Field PlayerInfoData_GameMode = ReflectionUtils.getOnlyField(PlayerInfoData, EnumGamemode.class);
private static final Field HEADER = ReflectionUtils.getFields(PacketPlayOutPlayerListHeaderFooter.class, IChatBaseComponent.class).get(0);
private static final Field FOOTER = ReflectionUtils.getFields(PacketPlayOutPlayerListHeaderFooter.class, IChatBaseComponent.class).get(1);
/**
* Constructs new instance.
*
* @param player
* Player this tablist will belong to
*/
public NMSPacketTabList(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
@SneakyThrows
public void removeEntry(@NonNull UUID entry) {
sendPacket(EnumPlayerInfoAction.REMOVE_PLAYER, entry, "", null, 0, 0, null);
}
@Override
public void updateDisplayName0(@NonNull UUID entry, @Nullable TabComponent displayName) {
sendPacket(EnumPlayerInfoAction.UPDATE_DISPLAY_NAME, entry, "", null, 0, 0, displayName);
}
@Override
public void updateLatency(@NonNull UUID entry, int latency) {
sendPacket(EnumPlayerInfoAction.UPDATE_LATENCY, entry, "", null, latency, 0, null);
}
@Override
public void updateGameMode(@NonNull UUID entry, int gameMode) {
sendPacket(EnumPlayerInfoAction.UPDATE_GAME_MODE, entry, "", null, 0, gameMode, null);
}
@Override
public void updateListed(@NonNull UUID entry, boolean listed) {
// Added in 1.19.3
}
@Override
public void updateListOrder(@NonNull UUID entry, int listOrder) {
// Added in 1.21.2
}
@Override
public void updateHat(@NonNull UUID entry, boolean showHat) {
// Added in 1.21.4
}
@Override
public void addEntry0(@NonNull Entry entry) {
sendPacket(EnumPlayerInfoAction.ADD_PLAYER, entry.getUniqueId(), entry.getName(), entry.getSkin(), entry.getLatency(),
entry.getGameMode(), entry.getDisplayName());
}
@Override
public void setPlayerListHeaderFooter0(@NonNull TabComponent header, @NonNull TabComponent footer) {
sendPacket(newHeaderFooter(header, footer));
}
@Override
@Nullable
public Skin getSkin() {
Collection<Property> properties = ((CraftPlayer)player.getPlayer()).getProfile().getProperties().get(TEXTURES_PROPERTY);
if (properties.isEmpty()) return null; // Offline mode
Property property = properties.iterator().next();
return new Skin(property.getValue(), property.getSignature());
}
@NonNull
@SneakyThrows
private PacketPlayOutPlayerListHeaderFooter newHeaderFooter(@NotNull TabComponent header, @NonNull TabComponent footer) {
PacketPlayOutPlayerListHeaderFooter packet = new PacketPlayOutPlayerListHeaderFooter(header.convert());
FOOTER.set(packet, footer.convert());
return packet;
}
@Override
@SneakyThrows
@NotNull
@SuppressWarnings("unchecked")
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof PacketPlayOutPlayerListHeaderFooter) {
PacketPlayOutPlayerListHeaderFooter tablist = (PacketPlayOutPlayerListHeaderFooter) packet;
if (header == null || footer == null) return packet;
IChatBaseComponent header = (IChatBaseComponent) HEADER.get(tablist);
IChatBaseComponent footer = (IChatBaseComponent) FOOTER.get(tablist);
if (header != this.header.convert() || footer != this.footer.convert()) {
return newHeaderFooter(this.header, this.footer);
}
}
if (!(packet instanceof PacketPlayOutPlayerInfo)) return packet;
PacketPlayOutPlayerInfo info = (PacketPlayOutPlayerInfo) packet;
EnumPlayerInfoAction action = (EnumPlayerInfoAction) ACTION.get(info);
List<Object> updatedList = new ArrayList<>();
boolean rewritePacket = false;
for (Object nmsData : (List<Object>) PLAYERS.get(info)) {
boolean rewriteEntry = false;
GameProfile profile = (GameProfile) PlayerInfoData_Profile.get(nmsData);
UUID id = profile.getId();
IChatBaseComponent displayName = (IChatBaseComponent) PlayerInfoData_DisplayName.get(nmsData);
int latency = PlayerInfoData_Latency.getInt(nmsData);
int gameMode = ((EnumGamemode)PlayerInfoData_GameMode.get(nmsData)).getId();
if (action == EnumPlayerInfoAction.UPDATE_DISPLAY_NAME || action == EnumPlayerInfoAction.ADD_PLAYER) {
TabComponent forcedDisplayName = getForcedDisplayNames().get(id);
if (forcedDisplayName != null && forcedDisplayName.convert() != displayName) {
displayName = forcedDisplayName.convert();
rewriteEntry = rewritePacket = true;
}
}
if (action == EnumPlayerInfoAction.UPDATE_GAME_MODE || action == EnumPlayerInfoAction.ADD_PLAYER) {
if (getBlockedSpectators().contains(id) && gameMode == 3) {
gameMode = 0;
rewriteEntry = rewritePacket = true;
}
}
if (action == EnumPlayerInfoAction.UPDATE_LATENCY || action == EnumPlayerInfoAction.ADD_PLAYER) {
if (getForcedLatency() != null) {
latency = getForcedLatency();
rewriteEntry = rewritePacket = true;
}
}
if (action == EnumPlayerInfoAction.ADD_PLAYER) {
TAB.getInstance().getFeatureManager().onEntryAdd(player, id, profile.getName());
}
updatedList.add(rewriteEntry ? newPlayerInfoData(
(PacketPlayOutPlayerInfo) packet,
profile,
latency,
EnumGamemode.getById(gameMode),
displayName
) : nmsData);
}
if (rewritePacket) {
PacketPlayOutPlayerInfo newPacket = new PacketPlayOutPlayerInfo(action, Collections.emptyList());
PLAYERS.set(newPacket, updatedList);
return newPacket;
}
return packet;
}
@SneakyThrows
private void sendPacket(@NonNull EnumPlayerInfoAction action, @NonNull UUID id, @NonNull String name,
@Nullable Skin skin, int latency, int gameMode, @Nullable TabComponent displayName) {
PacketPlayOutPlayerInfo packet = new PacketPlayOutPlayerInfo(action);
PLAYERS.set(packet, Collections.singletonList(newPlayerInfoData(
packet,
createProfile(id, name, skin),
latency,
EnumGamemode.getById(gameMode),
displayName == null ? null : displayName.convert())
));
sendPacket(packet);
}
@NotNull
@SneakyThrows
private Object newPlayerInfoData(@NonNull PacketPlayOutPlayerInfo packet, @NonNull GameProfile profile,
int latency, @NonNull EnumGamemode gameMode, @Nullable IChatBaseComponent displayName) {
return newPlayerInfoData.newInstance(packet, profile, latency, gameMode, displayName);
}
/**
* Creates GameProfile from given parameters.
*
* @param id
* Profile ID
* @param name
* Profile name
* @param skin
* Player skin
* @return GameProfile from given parameters
*/
@NotNull
private GameProfile createProfile(@NonNull UUID id, @NonNull String name, @Nullable Skin skin) {
GameProfile profile = new GameProfile(id, name);
if (skin != null) {
profile.getProperties().put(TabList.TEXTURES_PROPERTY,
new Property(TabList.TEXTURES_PROPERTY, skin.getValue(), skin.getSignature()));
}
return profile;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().playerConnection.sendPacket(packet);
}
}
@@ -0,0 +1,43 @@
package me.neznamy.tab.platforms.bukkit.v1_10_R1;
import com.mojang.authlib.GameProfile;
import lombok.SneakyThrows;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo;
import net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo.EnumPlayerInfoAction;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Arrays;
import java.util.List;
/**
* Implementation of TabListEntryTracker.
*/
public class NMSTabListEntryTracker extends TabListEntryTracker {
private static final Field ACTION = ReflectionUtils.getOnlyField(PacketPlayOutPlayerInfo.class, EnumPlayerInfoAction.class);
private static final Field PLAYERS = ReflectionUtils.getOnlyField(PacketPlayOutPlayerInfo.class, List.class);
private static final Class<?> PlayerInfoData = Arrays.stream(PacketPlayOutPlayerInfo.class.getDeclaredClasses()).filter(c -> !c.isEnum() && c.getConstructors().length > 0).findFirst().get();
private static final Field PlayerInfoData_Profile = ReflectionUtils.getOnlyField(PlayerInfoData, GameProfile.class);
@Override
@SneakyThrows
@SuppressWarnings("unchecked")
public void onPacketSend(@NotNull Object packet) {
if (packet instanceof PacketPlayOutPlayerInfo) {
PacketPlayOutPlayerInfo info = (PacketPlayOutPlayerInfo) packet;
EnumPlayerInfoAction action = (EnumPlayerInfoAction) ACTION.get(info);
for (Object nmsData : (List<Object>) PLAYERS.get(info)) {
GameProfile profile = (GameProfile) PlayerInfoData_Profile.get(nmsData);
if (action == EnumPlayerInfoAction.ADD_PLAYER) {
tablistEntries.add(profile.getId());
}
if (action == EnumPlayerInfoAction.REMOVE_PLAYER) {
tablistEntries.remove(profile.getId());
}
}
}
}
}
+4
View File
@@ -0,0 +1,4 @@
dependencies {
implementation(projects.bukkit)
compileOnly("org.bukkit:craftbukkit:1.11.2-R0.1-SNAPSHOT")
}
@@ -0,0 +1,62 @@
package me.neznamy.tab.platforms.bukkit.v1_11_R1;
import me.neznamy.tab.shared.chat.TabStyle;
import me.neznamy.tab.shared.chat.component.object.TabAtlasSprite;
import me.neznamy.tab.shared.chat.component.object.TabObjectComponent;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.shared.chat.component.object.TabPlayerSprite;
import net.minecraft.server.v1_11_R1.*;
import org.jetbrains.annotations.NotNull;
/**
* Component converter using direct NMS code.
*/
public class NMSComponentConverter extends ComponentConverter<IChatBaseComponent> {
@Override
@NotNull
public IChatBaseComponent newTextComponent(@NotNull String text) {
return new ChatComponentText(text);
}
@Override
@NotNull
public IChatBaseComponent newTranslatableComponent(@NotNull String key) {
return new ChatMessage(key);
}
@Override
@NotNull
public IChatBaseComponent newKeybindComponent(@NotNull String keybind) {
return new ChatComponentText("<Keybind components were added in 1.12>");
}
@Override
@NotNull
public IChatBaseComponent newObjectComponent(@NotNull TabAtlasSprite sprite) {
return new ChatComponentText(TabObjectComponent.ERROR_MESSAGE);
}
@Override
@NotNull
public IChatBaseComponent newObjectComponent(@NotNull TabPlayerSprite sprite) {
return new ChatComponentText(TabObjectComponent.ERROR_MESSAGE);
}
@Override
public void applyStyle(@NotNull IChatBaseComponent nmsComponent, @NotNull TabStyle modifier) {
nmsComponent.setChatModifier(new ChatModifier()
.setColor(modifier.getColor() == null ? null : EnumChatFormat.valueOf(modifier.getColor().getLegacyColor().name()))
.setBold(modifier.getBold())
.setItalic(modifier.getItalic())
.setUnderline(modifier.getUnderlined())
.setStrikethrough(modifier.getStrikethrough())
.setRandom(modifier.getObfuscated())
);
}
@Override
public void addSibling(@NotNull IChatBaseComponent parent, @NotNull IChatBaseComponent child) {
parent.addSibling(child);
}
}
@@ -0,0 +1,52 @@
package me.neznamy.tab.platforms.bukkit.v1_11_R1;
import io.netty.channel.Channel;
import lombok.Getter;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.platforms.bukkit.provider.ComponentConverter;
import me.neznamy.tab.platforms.bukkit.provider.ImplementationProvider;
import me.neznamy.tab.shared.platform.Scoreboard;
import me.neznamy.tab.shared.platform.TabList;
import me.neznamy.tab.shared.platform.TabListEntryTracker;
import org.bukkit.craftbukkit.v1_11_R1.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
/**
* Implementation provider using direct NMS code for 1.11.x.
*/
@Getter
public class NMSImplementationProvider implements ImplementationProvider {
@NotNull
private final ComponentConverter<?> componentConverter = new NMSComponentConverter();
@Override
@NotNull
public Scoreboard newScoreboard(@NotNull BukkitTabPlayer player) {
return new NMSPacketScoreboard(player);
}
@Override
@NotNull
public TabList newTabList(@NotNull BukkitTabPlayer player) {
return new NMSPacketTabList(player);
}
@Override
@NotNull
public Channel getChannel(@NotNull Player player) {
return ((CraftPlayer)player).getHandle().playerConnection.networkManager.channel;
}
@Override
@NotNull
public TabListEntryTracker newTabListEntryTracker() {
return new NMSTabListEntryTracker();
}
@Override
public int getPing(@NotNull BukkitTabPlayer player) {
return ((CraftPlayer)player.getPlayer()).getHandle().ping;
}
}
@@ -0,0 +1,164 @@
package me.neznamy.tab.platforms.bukkit.v1_11_R1;
import lombok.NonNull;
import lombok.SneakyThrows;
import me.neznamy.tab.platforms.bukkit.BukkitTabPlayer;
import me.neznamy.tab.shared.Limitations;
import me.neznamy.tab.shared.TAB;
import me.neznamy.tab.shared.platform.decorators.SafeScoreboard;
import me.neznamy.tab.shared.util.ReflectionUtils;
import net.minecraft.server.v1_11_R1.*;
import org.bukkit.craftbukkit.v1_11_R1.entity.CraftPlayer;
import org.jetbrains.annotations.NotNull;
import java.lang.reflect.Field;
import java.util.Collection;
import java.util.Collections;
/**
* Scoreboard implementation using direct NMS code.
*/
public class NMSPacketScoreboard extends SafeScoreboard<BukkitTabPlayer> {
private static final ScoreboardTeamBase.EnumNameTagVisibility[] visibilities = ScoreboardTeamBase.EnumNameTagVisibility.values();
private static final ScoreboardTeamBase.EnumTeamPush[] collisions = ScoreboardTeamBase.EnumTeamPush.values();
private static final Scoreboard dummyScoreboard = new Scoreboard();
private static final IScoreboardCriteria INTEGER = new ScoreboardBaseCriteria("dummy");
private static final IScoreboardCriteria HEARTS = new ScoreboardHealthCriteria("health");
private static final Field TeamPacket_NAME = ReflectionUtils.getFields(PacketPlayOutScoreboardTeam.class, String.class).get(0);
private static final Field TeamPacket_ACTION = ReflectionUtils.getInstanceFields(PacketPlayOutScoreboardTeam.class, int.class).get(1);
private static final Field TeamPacket_PLAYERS = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardTeam.class, Collection.class);
private static final Field Objective_OBJECTIVE_NAME = ReflectionUtils.getFields(PacketPlayOutScoreboardObjective.class, String.class).get(0);
private static final Field Objective_METHOD = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardObjective.class, int.class);
private static final Field DisplayObjective_OBJECTIVE_NAME = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardDisplayObjective.class, String.class);
private static final Field DisplayObjective_POSITION = ReflectionUtils.getOnlyField(PacketPlayOutScoreboardDisplayObjective.class, int.class);
/**
* Constructs new instance with given player.
*
* @param player
* Player this scoreboard will belong to
*/
public NMSPacketScoreboard(@NotNull BukkitTabPlayer player) {
super(player);
}
@Override
public void registerObjective(@NonNull Objective objective) {
IScoreboardCriteria healthDisplay = objective.getHealthDisplay() == HealthDisplay.INTEGER ? INTEGER : HEARTS;
ScoreboardObjective obj = new ScoreboardObjective(dummyScoreboard, objective.getName(), healthDisplay);
obj.setDisplayName(maybeCut(objective.getTitle().toLegacyText(), Limitations.SCOREBOARD_TITLE_PRE_1_13));
objective.setPlatformObjective(obj);
sendPacket(new PacketPlayOutScoreboardObjective(obj, ObjectiveAction.REGISTER));
}
@Override
public void setDisplaySlot(@NonNull Objective objective) {
sendPacket(new PacketPlayOutScoreboardDisplayObjective(objective.getDisplaySlot().ordinal(), (ScoreboardObjective) objective.getPlatformObjective()));
}
@Override
public void unregisterObjective(@NonNull Objective objective) {
sendPacket(new PacketPlayOutScoreboardObjective((ScoreboardObjective) objective.getPlatformObjective(), ObjectiveAction.UNREGISTER));
}
@Override
public void updateObjective(@NonNull Objective objective) {
IScoreboardCriteria healthDisplay = objective.getHealthDisplay() == HealthDisplay.INTEGER ? INTEGER : HEARTS;
ScoreboardObjective obj = new ScoreboardObjective(dummyScoreboard, objective.getName(), healthDisplay);
obj.setDisplayName(maybeCut(objective.getTitle().toLegacyText(), Limitations.SCOREBOARD_TITLE_PRE_1_13));
sendPacket(new PacketPlayOutScoreboardObjective(obj, ObjectiveAction.UPDATE));
}
@Override
public void setScore(@NonNull Score score) {
ScoreboardScore s = new ScoreboardScore(dummyScoreboard, (ScoreboardObjective) score.getObjective().getPlatformObjective(), score.getHolder());
s.setScore(score.getValue());
sendPacket(new PacketPlayOutScoreboardScore(s));
}
@Override
public void removeScore(@NonNull Score score) {
sendPacket(new PacketPlayOutScoreboardScore(score.getHolder()));
}
@Override
@NotNull
public Object createTeam(@NonNull String name) {
return new ScoreboardTeam(dummyScoreboard, name);
}
@Override
public void registerTeam(@NonNull Team team) {
updateTeamProperties(team);
ScoreboardTeam t = (ScoreboardTeam) team.getPlatformTeam();
t.getPlayerNameSet().addAll(team.getPlayers());
sendPacket(new PacketPlayOutScoreboardTeam(t, TeamAction.CREATE));
}
@Override
public void unregisterTeam(@NonNull Team team) {
sendPacket(new PacketPlayOutScoreboardTeam((ScoreboardTeam) team.getPlatformTeam(), TeamAction.REMOVE));
}
@Override
public void updateTeam(@NonNull Team team) {
updateTeamProperties(team);
sendPacket(new PacketPlayOutScoreboardTeam((ScoreboardTeam) team.getPlatformTeam(), TeamAction.UPDATE));
}
private void updateTeamProperties(@NonNull Team team) {
ScoreboardTeam t = (ScoreboardTeam) team.getPlatformTeam();
t.setAllowFriendlyFire((team.getOptions() & 0x01) != 0);
t.setCanSeeFriendlyInvisibles((team.getOptions() & 0x02) != 0);
t.setNameTagVisibility(visibilities[team.getVisibility().ordinal()]);
t.setCollisionRule(collisions[team.getCollision().ordinal()]);
t.setPrefix(maybeCut(team.getPrefix().toLegacyText(), Limitations.TEAM_PREFIX_SUFFIX_PRE_1_13));
t.setSuffix(maybeCut(team.getSuffix().toLegacyText(), Limitations.TEAM_PREFIX_SUFFIX_PRE_1_13));
}
@Override
@SneakyThrows
@SuppressWarnings("unchecked")
@NotNull
public Object onPacketSend(@NonNull Object packet) {
if (packet instanceof PacketPlayOutScoreboardDisplayObjective) {
TAB.getInstance().getFeatureManager().onDisplayObjective(player, DisplayObjective_POSITION.getInt(packet),
(String) DisplayObjective_OBJECTIVE_NAME.get(packet));
}
if (packet instanceof PacketPlayOutScoreboardObjective) {
TAB.getInstance().getFeatureManager().onObjective(player,
Objective_METHOD.getInt(packet), (String) Objective_OBJECTIVE_NAME.get(packet));
}
if (packet instanceof PacketPlayOutScoreboardTeam) {
int action = TeamPacket_ACTION.getInt(packet);
if (action != TeamAction.UPDATE) {
Collection<String> players = (Collection<String>) TeamPacket_PLAYERS.get(packet);
if (players == null) players = Collections.emptyList();
TeamPacket_PLAYERS.set(packet, onTeamPacket(action, (String) TeamPacket_NAME.get(packet), players));
}
}
return packet;
}
/**
* Sends the packet to the player.
*
* @param packet
* Packet to send
*/
private void sendPacket(@NotNull Packet<?> packet) {
((CraftPlayer)player.getPlayer()).getHandle().playerConnection.sendPacket(packet);
}
@NotNull
private String maybeCut(@NonNull String string, int length) {
if (player.getVersion().getMinorVersion() < 13 || TAB.getInstance().getConfiguration().getConfig().isPacketEventsCompensation()) {
return cutTo(string, length);
}
return string;
}
}
Loaded 100 of 840 files, more files were not shown because too many files have changed in this diff. Show more