plan-player-analytics / Plan

Player Analytics plugin for Minecraft Server platforms - View player activity of your server with ease. :calendar:
https://www.spigotmc.org/resources/plan-player-analytics.32536/
GNU Lesser General Public License v3.0
858 stars 170 forks source link

Placeholders do not parse on Paper 1.21 #3678

Closed SlimeDog closed 3 months ago

SlimeDog commented 3 months ago

Describe the issue

None of the listed placeholders I tried parsed on Paper 1.21. I didn't try them all, but quite a few; none parsed.

Plugin versions

> version
[11:24:49 INFO]: This server is running Paper version 1.21-37-master@dd49fba (2024-06-24T02:08:49Z) (Implementing API version 1.21-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21-36-dd31654 (MC: 1.21)
> version Plan
[11:24:53 INFO]: Plan version 5.6 build 2883
[11:24:53 INFO]: Author: AuroraLS3
AuroraLS3 commented 3 months ago

Did you add the extra stuff e.g %plan_{listed_placeholder}% or did you use /papi parse two times?

/papi parse runs on server thread and Plan can't replace first time on server thread due to potential of crashing the server with a database wait. Same thing occurs on all things where server thread is used.

You can add the placeholder to Plan config for it to be loaded when player joins so it's "preloaded" when the placeholder replacement actually happens

SlimeDog commented 3 months ago

/papi parse runs on server thread and Plan can't replace first time on server thread due to potential of crashing the server with a database wait. Same thing occurs on all things where server thread is used.

That is the issue. I see the explanation in the wiki. Does the configuration entry need the percent-signs

Plugins:
    PlaceholderAPI:
        Enabled: true
        Load_these_placeholders_on_join: 
          %plan_player_death_count%

or without

Plugins:
    PlaceholderAPI:
        Enabled: true
        Load_these_placeholders_on_join: 
          plan_player_death_count
SlimeDog commented 3 months ago

Actually, the placeholder of interest could change after join, so maybe Tracked_player_placeholders is the better option?

AuroraLS3 commented 3 months ago

With, and also needs to be a list so starting with -

The tracked placeholders setting puts the data on the plugins tab of players

SlimeDog commented 3 months ago

Thanks.