#placeholder-api

150650 messages · Page 116 of 151

mint fable
#

you sent only part earlier

tender vaporBOT
indigo geyser
#

I did add the repository

#

Oh

#

I think it fixed

austere hawk
#

Some way to get the player's timezone

nocturne igloo
#

He was banned for pinging someone. He cant reply lol

nocturne igloo
#

Apparently he sent logs and got banned for that

junior musk
#

then he was probably using leaked plugins

nocturne igloo
#

Leaked plugins meaning what

junior musk
#

a paid plugin that you download illegaly for free

silk mirage
#

Hello there,
Is there a placeholder api version for 1.7.10?

nocturne igloo
#

Im being told it was bought

junior musk
#

send the logs again then

nocturne igloo
#

Give me a second

junior musk
#

This page is no longer available. It has either expired, been removed by its creator, or removed by one of the Pastebin staff.

nocturne igloo
#

odd

#

Should work

junior musk
#

Ctrl+F "leak"

nocturne igloo
#

oh goodness

silk mirage
#

It is indeed a leaked plugin..

junior musk
#

yeah

nocturne igloo
#

Im just a middle man in this lol

junior musk
nocturne igloo
#

He says he inherited the server

silk mirage
nocturne igloo
#

if he resolves the piracy issue would unbanning him be an option?

junior musk
#

🤷you should see that with the staff

waxen shell
#

Does anyone have any idea of how i could do this?, Change output or something like that?

nocturne igloo
#

well apparently you cant ping in here

nocturne igloo
junior musk
#

assuming you made %afk% return nothing when the player is not afk:

conditions:
  nickcolor:
    conditions:
      - "%afk%="
    yes: "%essentials_nickname%"
    no: "%essentials_nickname_stripped%"

and in groups.yml

_DEFAULT_:
  tabprefix: "%afk%"
  customtabname: "%condition:nickcolor%"
sharp jay
#

Whyyyy you usin leaked PlUGINS

nocturne igloo
#

May i ask why?

sharp jay
#

Leaked plugins are not allowed

nocturne igloo
#

Hes aware of that fact. However, it wasnt him who had used the leaked plugin.

#

He has since resolved that issue.

sharp jay
#

How would we know that?

nocturne igloo
#

Could send you another log. For proof

austere hawk
sharp jay
#

with a custom plugin or something

sharp jay
nocturne igloo
#

Alrighty then

#

Is there a link you could provide?

sharp jay
austere hawk
sharp jay
#

see*

#

sec

#

lol

#

ig it does work

#

type /papi ecloud download localtime

nocturne igloo
#

He says he cant make a post

austere hawk
sharp jay
austere hawk
#

In the console I get that I can't take the timezone and use the server's

austere hawk
sharp jay
sharp jay
#

I need to know what your trying to make

#

exactly

austere hawk
#

Open Minecraft

#

And when I do it in the console it appears

sharp jay
#

it needs to be ran as a player

austere hawk
#

Something about the fact that I use the default timezone (the one from the server)

sharp jay
#

its per player

#

Are you trying to see others player timezone?

#

You can use the parseother expansion

austere hawk
austere hawk
#

I put it on the scoreboard anyway and it gives me the server time

sharp jay
#

You discussed this last time with cj

#

remember?

austere hawk
#

%parseother_{player_name}_{localtime_time}%?

sharp jay
#

Localtime doesnt work

austere hawk
sharp jay
austere hawk
#

Could you tell me?

primal wren
austere hawk
sharp jay
sharp jay
primal wren
#

i am not eftn

#

i joined to see if i needed some help

#

i was about to ask a question

#

then figured out my own priblem

#

problem* sorry

austere hawk
#

And what is the difference of this the key test and normal

sharp jay
#

@primal wren have your friend rejoin they were both unbanned the first one needs to appeal

primal wren
#

?

austere hawk
primal wren
#

who friend

#

my friend?

sharp jay
#

Eftn and Jonathan

primal wren
#

eftn i do not know

#

jonathan is do not know

sharp jay
#

and Eftn?

primal wren
#

no i just see that they left quickly

#

or banned

#

whatever it was

#

kicked i dont know

sharp jay
#

mk

austere hawk
sharp jay
#

If you want something custom id recommend using our service channels to try to hire somone to make one

austere hawk
#

Wow, you have to pay for your expansion to work, interesting

sharp jay
#

The one on github is free / ecloud but you need to get your own token because it seems like the one that was offered expired

#

If that doesnt resolve it it can be the host

austere hawk
#

I already consulted it and it is an expansion error

#

Pr that I have tried on several hosts

sharp jay
#

Im sorry I am out of solutions for this issue

austere hawk
sharp jay
#

its not required but an option

primal wren
sharp jay
primal wren
#

ok no problem man have a nice day 👌 👍

abstract hornet
#

Hi
I making the Minecraft public server but how to add coins like for baying whit online payment and how to add online shop

#

I need developer

primal wren
#

me try to find the destination of the appeal but i not find? wbesite broken??!

abstract hornet
#

Extermal say me to go this server and get support

sharp jay
primal wren
#

i thibk he asking you for money 💰

abstract hornet
#

I whant developer to make Minecraft server

waxen shell
abstract hornet
#

Can you help free

#

Some help

#

I almost make the server but I have a problem how to add online payment and get player coins in game

abstract hornet
#

Is vepsit

hot light
#

how do I make this plugin compatible in a network?

waxen shell
junior musk
#

it does, but it's only available to those who paid the plugin

#

and what you want to achieve is somewhat possible, you can enable layout and change the order from COLUMNS to ROWS, remove all fixed slots and add a player group that covers slot 1 to 80

The only downside is that all tablist slots will be shown to the player, even empty, which I believe is exactly what you don't want, so not possible

junior musk
#

there are some plugins like TAB that have a separate plugin to forward placeholders from the backend to the proxy, but without such, it's not possible either

sharp bloom
#

do u guys know if its possible with the changeoutput to use 2 options? for example > 10 < 50 cause i want to show smthing that is between 2 numbers and idk how :/

#

(contains isnt an option for what i wanna do ig)

junior musk
#

do you use TAB ?

sharp bloom
#

nop i wanna do smthing in deluxemenus with it

#

but ye i do

junior musk
#

TAB's config:

conditions:
  yourCondition:
    conditions:
      - "%placeholder%>10"
      - "%placeholder%<50"
    yes: "yay"
    no: "rip"

placeholders:
  register-tab-expansion: true

then use this placeholder in DM
%tab_placeholder_condition:yourCondition%

sharp bloom
#

hm eh i ll give a try to combine progress expansion with changeoutput instead :/

#

since i wanna make a progress bar myself

junior musk
#

okay 🤷

sharp bloom
#

i managed to do what i wanted with progress changeoutput and utils :d

vestal cedar
#

how do i reset the papi statistics or any api in general?

lean temple
#

hello

#

how I could get access to papi

#

I want to upload my own placeholder

sharp bloom
#

isnt there an option in changeoutput for string doesnt equal? wat

austere hawk
#

Yes, I don't like that you pay for something "custom" supposedly to fix the error, what if the error is fixed jaja

vivid sparrow
#

what

vestal cedar
#

how do i reset placeholder api statistics?

lofty valve
vestal cedar
lofty valve
#

Main world?

vestal cedar
#

i also deleted rhat

waxen shell
# junior musk and what you want to achieve is somewhat possible, you can enable layout and cha...

Oh, you are so kind for trying to help,

Ohh, i see why you said "who paid", i searched for it and it can't be purchased now, how sad, i would buy it only for the support lol

Yes, i have it configured as ROWS, but, players still don't appear on the side of the other... hmmm, i wonder why,
do i need to add a vertical max count amount or something?, so that players do appear one on the side of the other?,

And, sorry, i didn't get that "remove all fixed slots", do i have fixed slots?, sorry xd

And, hmmm, i get what you say, make it so it is always max width, right?... hmmm, i could see how that looks, only... i don't know how to do it, i'll try now

Thanks!

junior musk
#
  layouts:
    default:
      fixed-slots: []
      groups:
        players:
          slots:
          - 1-80
waxen shell
junior musk
#

Ctrl+F layout in your TAB config

#

you should see the layouts section underneath

junior musk
#

set it to true, reload TAB and it will generate the rest of the config

waxen shell
#

uh, uh, ok!, sorry

junior musk
#

dw

waxen shell
#

Ohhh, it is perfect now!, now everything aligns!!

#

Now, the last thing is... and sorry to keep asking things, how do i make so that hmmmm, players can appear one on the side of the other?, not only vertically?, i already have ROWS enabled but i doesn't seem to work

junior musk
#

on the side of the other?

#

like the first or second one?

waxen shell
#

Yes

#

mine only appear vertically

junior musk
#

first or second?

waxen shell
#

any, i wanted rows, so i set the setting to rows but it doesn't seem to be working

junior musk
#

send your config

waxen shell
#

my players just stack on top of the other in tab

junior musk
#

?paste

tender vaporBOT
waxen shell
#

I need to create an account?

#

(i left the default layout because it made everything line up)

junior musk
#

direction is set to COLUMNS and you don't have any layouts

waxen shell
junior musk
#

no

#

just set direction to ROWS

junior musk
#

right under empty-slots-ping-value

waxen shell
#

OMG o_O

#

Now the info is all on top of those spaces

#

it got really bugged

junior musk
#

not bugged, it's normal

junior musk
#

and no, there's no other way to have players display in rows instead of columns

#

it's unfortunately a limitation imposed by the game

waxen shell
junior musk
#

change your GUI scale

#

Pause Menu->Video Settings - > GUI Scale

waxen shell
#

but players would have to do that too, i guess it is better even if the vertical space gets full really quick

#

this is even bigger xd

#

thank you so much either way

junior musk
#

there's no other way

#

and once your server reaches 20 players, it'll do pretty much the same thing

waxen shell
#

Where could i send you a screenshot?

junior musk
#

then when you get to 21 it'll split into two, until you reach 40,and then it'll split again at 41, and 61,ans then you get to 80

#

?imgur

tender vaporBOT
junior musk
#

yes

#

and is client sided

waxen shell
#

I didn't know that "20" thingy, hmm, so i'll have to wait and see, thanks

#

If i artificially set deathcount stat to the same on the two of my test accounts everything lines up, so it is that (even when changing nicks, yeah)

#

is that possible?

junior musk
#

not really

#

well

#

somewhat

#

it would work but only up to 999

#

which placeholder do you use for the hearts?

waxen shell
#

I imagined like a placeholder that places an space if there is no info there, found this: https://github.com/ItsDoot/papi-pad not exactly what i was looking for, only adds spaces if there is no info

junior musk
#

oh my bad, I need the other placeholders

#

the one that returns the number

#
placeholder-output-replacements:
  "%the placeholder here%":
    "100-999": "%value%"
    else: " %value%"
#

add that under the placeholder-output-replacements section in your config (while using the actual placeholder)

waxen shell
#

Oh, that's great, either way, i wanted to leave a limit in 999

junior musk
#

perfect

waxen shell
#

Uuuhhh, you were right!, only that the 1 character width is a little different than the space, but i believe that's the best we can do, you're great at this!, thanks!!!

junior musk
#

try to add &l in front of the space and &r after

#

&l adds 1 pixel

#

even for spaces xD

waxen shell
#

lool, tyy xDD

waxen shell
# junior musk even for spaces xD

I have a super, super weird bug, do you know why it might be happening?, my tab miss-aligns only when the player nick has a "d" on it, yes... wth?

#

When player nick has a "d" it adds an space at the end, so Ping has a space, i'm gonna leave a screenshot

junior musk
#

did you get an error file in your TAB folder?

waxen shell
#

No, just the usual files;
animations.yml, config.yml, groups.yml, messages.yml, skincache.yml, users.yml

junior musk
#

I don't know what the issue is then

waxen shell
#

Deam, every time something super duper strange happens with any plugin, i'm surprised lol

What would you recommend to do?

junior musk
#

🤷

#

cry 😭

#

idk what to do

#

I just want to sleep

#

it's 3:35am xD

#

sorry

waxen shell
#

oH, OHH

#

you helped me a lott!, have a nice evening

#

I think i'll delete all my config and try to do everything from scratch and try to se if the bug appears

vestal cedar
#

how do i reset placeholder api bruh pls some one help statistics.

mint fable
#

delete your stats folder in the world folder

abstract hornet
#

Which is the best lobby for server

#

And how to upload lobby to server world

#

@sharp jay

tender vaporBOT
sharp jay
#

?help

tender vaporBOT
austere hawk
#

how do I do that with the Lifemc plugin that the lives are displayed on scoreboard

wide forge
#

What's the placeholder to see online players?

junior musk
#

do you want the player count or the player list?

wide forge
#

player count

junior musk
#

%server_online%

wide forge
#

thanks

junior musk
#

don't forget to download the Server expansion

#

/papi ecloud download Server
/papi reload

wide forge
#

already did, thanks ^^

red pine
#

whats the placeholder for blocks placed ?

#

is it %statistic_use_item% ?

junior musk
#

o_O

red pine
#

hmm

junior musk
#

I was almost certain there was one

#

I see EZBlocks but that's outdated

#

no idea if it'll work

austere hawk
#

yo is there a placeholder that gets the color of like a vault/luckperms group

#

swear there was but it was removed or something

waxen shell
#

Does anyone know how to disable this kill message?, or how to be able to translate it?,
https://imgur.com/a/epyx5Mp
It is from the default minecraft:kill command

#

I haven't found a plugin that is able to translate that one, but i want

tardy glade
#

Hi!, I'd like to create an ecloud account

onyx isle
#

hey can anyone help me i bought a pc recently and its rebootign like every20 mins whem i plac cod

still goblet
#

Hi! The towny placeholders doesn't seems to be working. Can anyone help me?

tender vaporBOT
still goblet
mint fable
#

what placeholder are you trying @still goblet ?

mint fable
tardy glade
mint fable
#

Can you provide a source and explanation?

#

on github*

tardy glade
#

everything is explained in readme

mint fable
#

looks good to me, I've let cube know

#

only other thing that could replicate it is string_replaceCharacters, which is a lot more complicated to use

tardy glade
#

ive made it mainly because that font thingy is a new trend

#

its being asked for on spigotmc discord daily

mint fable
#

icic

still goblet
tender vaporBOT
mint fable
#

Did you download an expansion?

still goblet
#

Of course

mint fable
#

you shouldn't need to anymore

#

it's included with the plugin

still goblet
mint fable
#

that's why the expansion is not verified anymore

still goblet
#

So this doesn't work?

mint fable
#

it's for older towny versions

still goblet
#

Ah okay

#

So delete it and /papi reload?

mint fable
#

yep

still goblet
#

Thanks man!

mint fable
#

no problemo

thorn bay
#

hello all, i have a problem with a pleceholder of a plugin called playerlist, i can't use it in my codes and i need it. I did shorter code to make sure the placeholder was the problem. I contacted the discord server of those who made the plugin but they sent me here for help. I hope you can understand what the problem is.

thorn bay
mint fable
#

/papi parse me %playerlist_staff_amount% @thorn bay

thorn bay
#

in game the placeholder works

mint fable
#

ah, then i'm not sure sorry I don't use skript

thorn bay
#

ok no problem if i knew someone who can help me i would really need it

mint fable
#

also just fyi, since the placeholder works in-game, it is a problem with your skript/skript itself

thorn bay
#

yes, the type of the plugin also told me but in the log it tells me this:

#

[19:13:54 INFO]: [Skript] You're currently running the latest stable version of Skript.

#

however I agree that the problem could be that but I don't find other versions for the script to install, could you send me some links to install it?

mint fable
#

I don't know anything about skript

mint fable
primal blade
#

yo im having a problem with placeholderAPI... i have imported it in my pom, have checked it in my Main and i have it on my server with the needed downloads installed.... still: PlaceholderAPI.setPlaceholders(null, "§7Players: %bungee_<lasertag-1>%/100") is not working 😦 anybody have an Idea? Its my first TIme using PlayeholderAPI. Greets!

fluid bough
#

hello when I tried to install an extension it doesn't register it, I restarted the plugin with /papi reload and restarted the server

#

no errors in console

balmy marten
balmy marten
fluid bough
balmy marten
tender vaporBOT
zealous ledge
#

Can you check total players on a velocity proxy?

#

nvm

mint fable
#

@tardy glade From what i see in the jar you uploaded, the bold wouldn't work

#

unless my decompiler is just failing

#

just an fyi, I can test it myself in a bit

#

probably some weirdness with my decompiler

tardy glade
#

it was tested with many different cases

mint fable
#

ok my decompiler just be buggin then

#

yepp, just tested to confirm

#

stupid decompiler, never perfect

tardy glade
#

which one did you use

mint fable
#

jd gui

tardy glade
#

yeah its pretty ancient

mint fable
#

any recommendations?

tardy glade
#

CFR is really good

#

recaf has it

mint fable
#

gah, seems to complicated lmao

#

I ran the jar and it opened nothing lol

#

oh ya, recaf booted up nice

#

thanks 👍

marsh prawn
#

Hey guys, is there a way someone can help me out? I am looking to make it so a users cpdata is updated and added overtime upon command execution.

" CatchCommands:
- 'cpdata add %player_name% bronzecatch 1'"

For example from seen above, a user catches a fish, and the "bronzecatch" value gets +1 everytime.

what I have in place now, works, but I can not figure out how to get the value to increase progressively. I did install the "math" papi extension but I do not seem to know how to use it.

Any feedback would be super much appreciated!

fluid bough
marsh prawn
#

oh, sorry. Its Command Panels. It allows you to create placeholders of your choosing, that I am trying to increase upon command execution

mint fable
#

so %cp-data-bronzecatch% would return the value?

marsh prawn
#

correct

mint fable
#

What do you mean by increase progressively?

marsh prawn
#

Upon the user catching a special fish, I can make it execute a command. This is fine and working.

What I am struggling with, is I want the placeholder to increase by number.

So, after the user catches 2 fish, the value of the placeholder becomes 2

mint fable
#

how can you tell if the user catches 1 fish or 2

marsh prawn
#

that is handed by another plugin, it will execute a command on catch

mint fable
#

the command doesn't run once for each fish I presume

#

oh

#

then it should just run the add command twice, no?

marsh prawn
#

the command can execute everytime a fish is cauht

#

Oh, I think so. I can make it run multiple commands, is that what I am looking for?

mint fable
#

no i meant like

#

you have the plugin that runs a command on catch

marsh prawn
#

yes yes

mint fable
#

that command is cpdata add %player_name% bronzecatch 1

#

which, should mean, if the player catches 2 fish, the command will be run twice

#

and you shouldn't have to do anything with math at all

marsh prawn
#

What about 3 and 4 and so on?

#

I must not be understanding 😦

mint fable
#

hmm

mint fable
#

and you said it would be handled by the plugin executing a command on catch

marsh prawn
mint fable
#

Yes, I am aware

#

Does it run the command per fish?

marsh prawn
#

Yes, each time the user catches one

mint fable
#

but if they catch 2 in one go, it runs it once?

#

is that correct?

marsh prawn
#

Correct, I am not worried about the touchyness of that

mint fable
#

So do you have a way to get the amount of fish the user caught or no

#

is there a variable for it?

marsh prawn
#

For everytime the user uses a fishingrod, and makes a catch, this placeholder value is increased by 1

fluid bough
#

hello when I tried to install an extension it doesn't register it, I restarted the plugin with /papi reload and restarted the server
no errors in console

marsh prawn
#

reguardless if they caught 1 or 2 fish per catch, I am not worried about that part

mint fable
#

what?

#

that's exactly what you're worried about

#

you said earlier

marsh prawn
#

I cant get the value to increase though

mint fable
#

you literally are worried about that part

#

if they catch 2, you want to increase it by 2

#

if they catch 1, increase it by 1

#

so in your plugin that is running the command after a catch, is there a variable provided for how many fish the user caught?

marsh prawn
#

maybe I should re-phrease my question

mint fable
#

If there is not, then it won't be possible

marsh prawn
#

Can I use papi math, to increase the value of a previous placeholder

mint fable
#

Yes

#

but you're already increasing the value by doing cpdata add

marsh prawn
#

i think this is fault on cpdata, that command doesnt actually "add"

#

so thats a lie

mint fable
#

okay....

marsh prawn
#

But can I use a different command, to increase the cpdata placeholder by 1 each time a command is executed?

mint fable
#

now it makes sense

marsh prawn
#

🫰

mint fable
#

I was going to send the placeholder earlier, but noticed the command was add and immediately ruled out the need for math

marsh prawn
#

yea sorry about that

#

I wish add actually meant add....

mint fable
#

%math_0:_{cp-data-bronzecatch}+1%

fluid bough
#

hello when I tried to install an extension it doesn't register it, I restarted the plugin with /papi reload and restarted the server
no errors in console

marsh prawn
#

Oh my gosh thank you so much, I could not find a use-case example anywhere online

marsh prawn
#

thanks CJ, I looked at this page but I still didnt know exactly how it looked

#

Your example is all I needed!!! ❤️

mint fable
#

no problemo

#

?startuplog

tender vaporBOT
mint fable
#

@fluid bough can you send your log over this

fluid bough
abstract hornet
#

How to add lobby in world in server

austere hawk
#

Is there a placeholder that checks the amount of blocks placed by the player.

vale cave
#

I type in player_colored_ping and at the end it gives me some obscure symbol.

#

What could be the problem? I can't send a screenshot to this chat for some reason.

vale cave
#

please help me

tame willow
#

Is there any placeholder to format numbers like 10700 to 10.7k

thorn siren
#

It seems that PAPI does not work entirely on 1.20.1. I have PAPI, ProtocolLib, and 2 plugins that I use (venturechat and TAB), but both VC and TAB don't register any placeholders as being functional, all the way to the point of VC just refusing to send chat messages at all, and TAB has %afk% tacked to the end of everyone's names in the list, where PAPI would put ' ' or '[afk]' depending on if the user is or isnt afk. Can anyone else confirm this, or is it just me? PAPI version 2.11.3, ProtocolLib version 5.1.1 (latest dev build 665), Venturechat version 3.6.0, and TAB version 4.0.3

errant iron
#

Make sure you have the correct expansions downloaded and that you are using the correct placeholders!

#

So if you're using Essentials, you'd need to download the Essentials expansion and then use iirc %essentials_afk%

thorn siren
#

I'll double check that! It was getting very annoying 😛

errant iron
#

You can always check if a placeholder is working without using any extra plugins by running /papi parse me %placeholder%

thorn siren
#

ok thank you much!

marsh prawn
#

Hey guys, I cant seem to parse CommandPanels Data Values with Papi, can someone help me?

#

/cpdata get ClassicRockDude fishquest | This returns a valid number
/papi parse ClassicRockDude %commandpanels_fishquest% | Just gives a blank line in chat

#

I got it nevermind 🙂

real stratus
#

Hey does anyone know how to get the UltimateClaims plugins placeholders to work on a tab

#

i have added

%ultimateclaims_totalpower%
%ultimateclaims_claims%

austere hawk
#

hello?

marsh prawn
#

Hey guys, what console command would I use, to increase a math placeholder?

junior musk
#

there is no command to increase a math placeholder

marsh prawn
#

So, what is this - 'cpdata add %math0:{cp-data-bronzecatch}+1%'

#

I need to increase another plugins placeholder value, with a console command

#

Is that possible?

junior musk
#

it's adding a value to a plugin that has a cpdata command

marsh prawn
#

correct, what would be the "console" command to execute, to set the players bronzecatch plus 1 each time

junior musk
#

I have no idea

#

doesn't the above command do that already?

marsh prawn
#

i dont know, it doesnt seem to be a valid command in-game

junior musk
#

where did you find it?

marsh prawn
#

I kinda made it up, but I was given the "%math_0:_{cp-data-bronzecatch}+1%" by another support member

#

So, I assume that is the "math" section, but how do I apply it in a command?

austere hawk
#

@junior musk Sorry to inturrupt you but, You know how to fix my problem?

junior musk
#

read

#

I answered you in the channel you asked for help

#

no need to ping me if you don't even read what I say

austere hawk
#

I already installed the plugin but its only for 1.13

junior musk
marsh prawn
#

I seem to understand the point then 😦 I dont get it

#

Let me try from the top;

How may I adjust a placeholder through math-data via a console command?

Example, the player catches a fish, and the console executes a command.
Using another plugin, that allows you to create placeholders, the command would increase that value +1?

I was given this operation from a previous helper, but unsure how to apply that via a command.
%math0:{cp-data-bronzecatch}+1%'

Where, {cp-data-bronzecatch} is the "other plugins placeholder data"
Any help would be major appreciated!

The end result I am going for, data of a players placeholder, will increase by 1, each time a fish is caught. Like a scoreboard or some sort, what would such a command look like?

sonic cape
#

I have a really frustrating problem someone explain to me why this ```java

if (Bukkit.getPluginManager().isPluginEnabled("PlaceholderAPI")) {
getLogger().info("PlaceholderAPI found, registering!");
new SpawnerLevelsPlaceholderExpansion(this).register();
} else {
getLogger().info("PlaceholderAPI now found, skipping!");
}``` won't register my Listener class?

junior musk
sonic cape
#
package si.jezen.spawnerlevels;

import me.clip.placeholderapi.expansion.PlaceholderExpansion;
import org.bukkit.entity.Player;

public class SpawnerLevelsPlaceholderExpansion extends PlaceholderExpansion {

    private SpawnerLevels plugin;

    public SpawnerLevelsPlaceholderExpansion(SpawnerLevels plugin) {
        this.plugin = plugin;
    }

    @Override
    public String getAuthor() {
        return plugin.getDescription().getAuthors().get(0);
    }

    @Override
    public String getIdentifier() {
        return "spawnerlevels";
    }

    @Override
    public String getVersion() {
        return plugin.getDescription().getVersion();
    }

    public boolean persist() {
        return true;
    }

    @Override
    public String onPlaceholderRequest(Player player, String identifier) {
        plugin.getLogger().warning("HELLO " + identifier);

        if (player == null) {
            return "";
        }

        // %spawnerlevels_current_level%
        if (identifier.equals("current_level")) {
            PlayerData playerData = plugin.getPlayerData(player.getUniqueId());
            return String.valueOf(playerData.getLevel());
        }

        // %spawnerlevels_next_level%
        if (identifier.equals("next_level")) {
            PlayerData playerData = plugin.getPlayerData(player.getUniqueId());
            return String.valueOf(playerData.getLevel() + 1);
        }

        // %spawnerlevels_current_kills%
        if (identifier.equals("current_kills")) {
            PlayerData playerData = plugin.getPlayerData(player.getUniqueId());
            return String.valueOf(playerData.getCurrentKills());
        }

        return null;
    }
}```

this is my listener
sonic cape
#

nothing

#

§6Fetching version information...
[23:30:24 INFO]: [PlaceholderAPI] Placeholder expansion registration initializing...
[23:30:24 INFO]: 0 placeholder hook(s) registered!

junior musk
#

send the entire logs

#

?paste

sonic cape
#

its been driving me nuts

tender vaporBOT
sonic cape
junior musk
#

did you add PlaceholderAPI in your plugin.yml's softdepends?

sonic cape
#

oh im idiot but why Bukkit.getPluginManager().isPluginEnabled("PlaceholderAPI") is this false

sonic cape
#

i thought that was optional

#

well i added it but still [PlaceholderAPI] Placeholder expansion registration initializing...
[23:34:58 INFO]: §6Fetching version information...
[23:34:58 INFO]: 0 placeholder hook(s) registered!

junior musk
#

it's optional if you don't have any plugins you rely on, but since you rely on PlaceholderAPI, it's required

#

send the entire logs again

sonic cape
#

Nevermind, thank you for help it works that log message just makes no sense

marsh prawn
waxen shell
#

What Placeholder would you guys recommend to use in combination with Chatty to display roles when hovering over player names in chat?,

For example:

Best Base 2023
Most Mobs Kills

Etc, i thought of %luckperms_groups% but it looks bad without any possibility of formatting and it always displaying the "default" group, if i could remove that it would be fine

#

Or, is there any placeholder that i could just set text to every player differently?

knotty relic
#

Im trying to make it so i have enchantments placeholder. i have fortune on a pickaxe but the placeholder doesnt change dm me for the image

junior musk
junior musk
#

also, for images, check this:

#

?imgur

tender vaporBOT
knotty relic
#

herehttps://imgur.com/a/YgGutSj

junior musk
#

can have colors

knotty relic
#

so i added fortune placeholder and i have fortune on the pickaxe but it doesnt change

junior musk
knotty relic
#

alright

knotty relic
marsh prawn
junior musk
marsh prawn
#

it does

junior musk
marsh prawn
#

oh sorry lol

junior musk
marsh prawn
#

But what is the format? what would it look like, i know x_x haha

junior musk
#

you already have the placeholder

#

you just need to use it in the command at the position where you would normally set a value

knotty relic
junior musk
#

if the command is /setsomedata set <mydata> <value>, you'd use /setsomedata set <mydata> %math placeholder you sent earlier%

junior musk
#

?paste

tender vaporBOT
junior musk
#

send the error

junior musk
#

send the placeholder you're currently using

knotty relic
#

%enchantment_<fortune>_level%

junior musk
#

try without <>

junior musk
#

then it's working?

knotty relic
junior musk
#

send your menu file

knotty relic
#

wdym

junior musk
#

wdym wdym

#

your menu file

#

the DeluxeMenus menu file

knotty relic
#

im not putting it on a menu im putting it on a pickaxe lore

junior musk
#

uh

#

and how are you adding it to the lore?

knotty relic
#

/give commands

junior musk
#

then it won't work

knotty relic
#

how do i do it then?

junior musk
#

PAPI doesn't parse placeholders in items

knotty relic
#

so it wont work on the pickaxe lore?

junior musk
#

you'll need another plugin that can do that

#

it won't work on items at all

knotty relic
junior musk
#

not really

lethal breach
#

Hi, I need some help with this line of code:

PlaceholderAPI.setPlaceholders((Player) sender, consoleCommand);

How can I use this if the sender is console?

#

the code works if a player is running the command

junior musk
#

use null in the player argument, some placeholders will suport it, some won't

#

for example, %server_online% can be parsed when no player is associated, but %player_name% will require one

junior musk
#

the KillStats expansion requires its associated plugin, did you download it as well?

junior musk
#

considering it hasn't been updated since 2014, idk if this is really something you'd want to use

#

use the Statistic expansion

#

%statistic_deaths%
%statistic_player_kills%

#

delete the playerdata files in your server's main world folder (while the server is turned off)

#

?

#

what do you mean by "player spend time"

#

ah

#

that's also in the statistic expansion

#

%statistic_time_played%

solar swift
#

my placeholders from vault has been broken

junior musk
#

send /papi dump

proper wren
#

i need help, i'm registering an hook but when i integrate it with TAB plugin i need to restart the server each time a new player joins because it shows the placeholder instead of the value retrieved from database

pliant ember
#

is there an api that counts when there will be night?

open pivot
#

Who has faced this? At some point, placeholder CheckItem stopped working. There are errors in the console:

[13:23:21 INFO]: Placeholder got blocked due to security concerns (%checkitem%)

Server 1.19.3
PAPI 2.11.3

iron moth
#

Hello, I'm trying to get playerlist to work but when I do /papi parse <user> %playerlist_online,world,yes,amount,pvp% it's not working. I've installed the extension still nothing

mint fable
#

Not sure if disabling them will “unblock” the placeholder though since I don’t know what’s doing it

open pivot
junior musk
#

I think it may have been CMI

#

let me check

#

yup

open pivot
solar swift
#

02:46 WARN]: [PlaceholderAPI] Cannot load expansion vault due to an unknown issue.
[19:02:46 WARN]: [PlaceholderAPI] Failed to load expansion bungee. Identifier is already in use.
[19:02:46 WARN]: [PlaceholderAPI] Cannot load expansion bungee due to an unknown issue.

junior musk
#

you have 2 bungee expansion jars

#

PAPI-Expansion-Bungee.jar
Expansion-bungee.jar

solar swift
#

which is correct?

#

and why vault not working ;((

junior musk
#

delete both and redownload

#

as for Vault, do you have an economy plugin?

#

the expansion won't load if none is found

solar swift
#

lighteconomy

junior musk
#

check /vault-info

junior musk
solar swift
#

omy got meaby forgot to upload newest version xD

junior musk
#

gg

#

xD

solar swift
#

yea it should be correct

#

because was config update

#

and trying update and forgot

#

nice nice 👍

#

eh

#

anyway

#

why bungee expansion doesn't support vanish?

junior musk
#

?

solar swift
#

when im on vanish and have bungee online there is still shows as online

#

me on vanish + 2 players = 3

#

and 3 shows

junior musk
#

the expansion only takes the data Bungee sends back, which is the amount of players connected to the Bungee, and Bungee doesn't have a vanish system

#

though since you're using PremiumVanish, you could use its placeholders

solar swift
#

can i use from networkmanager ?

junior musk
#

it allows you to use the plugin on both the backends and the proxy to forward data, and it has placeholders to get playercount on the proxy while accounting for vanished players

junior musk
#

but aren't you using PremiumVanish?

solar swift
#

using

#

wait i will check placeholders

junior musk
#

then why would you use NetworkManager?

solar swift
#

becuase have this too and using small amount of his features 😂

#

nevermind

#

oh yes now understand

#

vanish placeholders will support vanished layers

#

iq 1000

tropic epoch
#

There's probably some really simple solution to this which I haven't realised but I've been trying to get these to work all day and I'm very close

#

however, papi doesn't use the color codes in my luckperms prefix

junior musk
#

since 2.11.2 or .3, PAPI doesn't parse colors anymore

#

the plugin where you're using the placeholder now has to parse them

#

or you can use another placeholder to parse them for you

tropic epoch
#

so how do i do that

#

i don't understand

#

wait

junior musk
#

I made one in my Utils expansion, %utils_colors_<placeholder>%

tropic epoch
#

i might know a way

junior musk
#

if your placeholder is %essentials_nickname%, you would use %utils_colors_essentials_nickname%

tropic epoch
#

I figured it out

#

thank you for the help :)

mint fable
#

thanks for opening that up and informing them 👍

junior musk
#

oh btw I think I have an idea to fix it in the meantime

mint fable
#

also it's been since june

#

wow

junior musk
#

just use %utils_parse_<placeholder>%

#

xD

mint fable
#

surprising

#

lmao

#

Ya, interesting that they give no detail to the user about it though

#

lol they blocked it after I made the update to fix it

#

it must've been that one guy that was REALLY complaining about it

junior musk
#

bruh

mint fable
#

now, in fairness, it doesn't update previously-existing configs

#

but 🤷‍♂️

#

Thanks again for mmaking the discussion for it

austere hawk
#

hi

#

anyone here?

lucid lance
#

is it possible to parse a placeholder inside your plugin?

#

like from another plugin

#

say i wanted to do something like player.sendMessage("%player_time%");

junior musk
#

yeah

#

check the wiki

mighty frost
#

which placeholder is responsible for counting the picked up items

austere hawk
#

bro

#

someone help me

austere hawk
#

i have the required papi extensions

#

😥

mint fable
#

?startuplog

tender vaporBOT
mint fable
#

send the whole log

#

I don't know if there is such a placeholder @mighty frost but you can try %statistic_pickup%

#

or you would need another plugin that adds it

quartz violet
#

&8[%progress_bar_{redisbungee_Skyblock}_c:&a█_p:&e█_r:&7█_l:10_m:40_fullbar:&aCompleto%&8]

when using the placeholder, returns the variable, but not the colors. It looks like this:

&a█&a█&a█&e█&7█&7█&7█&7█&7█&7█

mint fable
#

papi does not color things

#

you would need to rely on whatever plugin you're using it in

quartz violet
tender vaporBOT
quartz violet
#

sorry

mint fable
#

placeholderapi does not do anything with coloring

#

so you won't see a color unless the plugin where you are using it colors it

austere hawk
#

Any placeholder so that the text returned by a placeholder is lowercase, uppercase, or just the first uppercase letter?

#

If the value of a placeholder is "example" return it as "Example" "example" "EXAMPLE"

mint fable
#

@austere hawk looks like %str_capitalize_<text>% should work

austere hawk
mint fable
#

turn example into Example

#

there is also lowercase and uppercase

#

for EXAMPLE

austere hawk
#

No, but I want to choose whether to return it in upper or lower case

#

That does not depend on the text

mint fable
#

I am confused

#

let me see

#

%str_lowercase_EXample% would return example

#

is that something you need?

austere hawk
#

Something

mint fable
#

%str_uppercase_exAmplE% would return EXAMPLE

austere hawk
#

yes

mint fable
#

%str_capitalize_examPle% would return Example

austere hawk
#

Work %str_lowercase_example%?

mint fable
#

it would say example

austere hawk
#

yes

mint fable
austere hawk
#
  • %str_lowercase_EXaMple% - Returns the text in lowercase (example)
  • %str_uppercase_EXaMple% - Returns the text in uppercase (EXAMPLE)
  • %str_capitalize_EXaMple% - Returns the text with only the first letter in uppercase and the rest in lowercase (Example)
mint fable
#

yes

#

should do

#

if not, let me know

#

you can test with /papi parse me %placeholder%

#

capitalize might not do that exact thing

#

but you can do it with combining placeholders

austere hawk
#

And can I use %str_uppercase_{placeholder}%?

mint fable
#

makes it a little trickier

austere hawk
mint fable
#

you might have to try %str_capitalize_{str_lowercase_{placeholder}}%

#

according to the wiki, that should probably work

austere hawk
#

if we are right

mint fable
#

well if not I have another way

#

so it's all good

edgy burrow
#

Whats the use case?

austere hawk
#

Capitalize the first letter, if the first character is not a lowercase letter, return it as it is.

mint fable
#

yes i've seen that

austere hawk
mint fable
#

test it

#

let me know

austere hawk
#

ok, i'll try

tender vaporBOT
austere hawk
#

Because if the text is heLLO returns HeLLO

rare gazelle
#

hi i search a placeholder for the vp plugin who have ?

noble vector
#

hello. is there any way how to make papi translate hex colors itself I've just downloaded a plugin which supports papi and want to display name using hex colors with luckperms but this plugin does nothing with hex colors so i want papi to do it

jovial tusk
#

how can i make a placeholder round to the nearest whole number?

junior musk
#

use the Math expansion

jovial tusk
noble vector
#

guys please where can I find hex translate expansion

mint fable
#

%math_0:_<expression>% for 0 decimals

west heron
#

Currently cant get vault placeholders nor essentials top balance placeholders too work.
I have updated the config to allow for it, installed both vault and essentials and reloaded.
It still outputs blank, any idea?
Am I missing something, doing something wrong?

junior musk
#

which placeholders are you using?

west heron
#

%essentials_baltop_player_1%
%vault_eco_top_player_2%

Tried using both just for test purposes

junior musk
#

Vault's baltop placeholders were removed

#

and for the essentials one, I remember them not working properly with offline playeres

#

or only when you run /baltop before hand

west heron
#

Ah that is going to be a pain for me.
Not sure I can work around that.
Might need to find an older version of the vault expansion then.

junior musk
#

imo the best option would be to go with a plugin like ajLeaderboards and use the %vault_eco_balance% placeholder

west heron
#

I'm not setting a on screen leaderboard, therefore that doesn't really help me unfortunately.

junior musk
#

it does provide placeholders though

west heron
#

Oh, hmm, okay that might be worth a look then thankyou.

austere nymph
#

WARN [PlaceholderAPI] [math] Invalid Placeholder detected!
WARN [PlaceholderAPI] [math] Placeholder: %math_2:_{luckperms_meta_ShopBlock2Price}*32%
WARN [PlaceholderAPI] [math] Cause: '*32' is not a valid Math expression.

Runnning math 2.0.2 and PlaceholderAPI 2.11.3 Just updated and started seeing these warning spam our console. What's weird is its working in game as we expect, like its doing the math right but was curious if anyone knows how to fix?

#

oof it removed the **32' is not a valid Math expression. Theirs only one asterick btw.

junior musk
#

what does %luckperms_meta_ShopBlock2Price%?

#

is it an empty string?

austere nymph
#

no sir, just ran
/papi parse me %luckperms_meta_ShopBlock2Price%
and returned
1.84

junior musk
#

can you try the math placeholder in papi parse?

austere nymph
#

and it is succesfully multuplying it by 32 and returning a result.. I just noticed(prob durig some other testing) I turned on debug=trrue in my server.properties.. maybe Im just seeing a non error that always been there?
Yep one sec

junior musk
#

where are you using the placeholder?

#

and when does the warn appear?

austere nymph
#

Using it in a DeluxeMenu and it seems to appear anytime I even open the menu.

#

running math...one min

junior musk
#

can you send that menu?

austere nymph
#

You may have found it.. it may be a non error.. I just disabled debug and about to reboot.
/papi parse me %math2:{luckperms_meta_ShopBlock2Price}*32% returned %math2:{luckperms_meta_ShopBlock2Price}**32%

Yep, I'll send it, dm?

junior musk
#

?paste

tender vaporBOT
junior musk
#

and Discord yeeted the _

#

copy paste it from your console directly, or from your menu

austere nymph
junior musk
#

could it be because of the open_commands ?

austere nymph
#

those specific placeholders aren't coming up in the log it's everywhere I'm using math. Ohh.. I bet your right. So user opens the menu and at the time those may be null, and it's reporting back the possibility that the math calculations are wrong... but then the commadns run and user has the placeholder for the block prices and qty. I may be able to ignore it. Turning off debug to see if the messages stop. I don't see yet where it's hurting the daily shop or where users aren't gettign the correct amounts calculated

#

Okay, I disabled debug in server.properties and the message stopped and th emenu still works.

#

ty for your time. I fyou think of any issues with leaving it like that I'm open to look into them.

austere hawk
austere hawk
#

They are [lang]<key>[/lang]

#

Interesting to use /papi parse me %str_uppercase_{[lang]rank[/lang]}% and /papi parse me %str_uppercase_[lang]rank[/lang]% and return the placeholder as text

#

The creator of newt says that he made the placeholders with that format why can't you use the arguments

mint fable
#

so if [lang]rank[/lang] is an internal placeholder in another plugin, papi can't parse it

unreal ravine
#

does placeholderapi also work for arclight?

austere hawk
tender vaporBOT
tender vaporBOT
austere hawk
#

If it works /papi parse me [lang]ranks[/lang]

#

If it gives me the value of the placeholder, but if I use it with str it doesn't

mint fable
mint fable
austere hawk
mint fable
#

can you send an image maybe

#

?imgur

tender vaporBOT
austere hawk
mint fable
#

please send a picture

austere hawk
#

I can not now

#

But it wouldn't make sense why it just returns me the placeholder in mayisc

mint fable
#

can you please tell me exactly what it says

austere hawk
mint fable
#

1 moment

austere hawk
#

{[lang]rank[/lang]}and{[lang]rank[/lang]}

#

That but all in capital letters

mint fable
#

so

#

what you want to do will not work

austere hawk
#

The bot removes the message by capitalization

mint fable
#

because of the way the translation plugin works

#

it translates the message after it's been parsed

#

so the placeholder, uppercases ALL the characters, and the plugin no longer translates it

#

So you will not be able to uppercase, capitalize, or lowercase any of the translations

austere hawk
#

But if it works on /papi parse me

mint fable
#

yes, because the message is translated after it is sent

#

when you type /papi parse me [lang]rank[/lang] what sends in chat is [lang]rank[/lang]

#

that is then replaced by the translator plugin

#

into what you are supposed to see

austere hawk
#

Or I want the Uppercase to be applied to the value of the placeholder

mint fable
#

you can't

mint fable
#

yes

#

I am telling you

austere hawk
#

you don't understand i think

mint fable
#

I am trying to explain it

austere hawk
#

oh my god you don't seem to be paying attention

mint fable
#

please be patient

#

I understand what happens

#

the placeholder works

#

and shows you the correct word

#

in your language

#

I understand that

#

What I am telling you is that when you type /papi parse me [lang]rank[/lang]

austere hawk
#

If I do /papi parse I get [lang]rank[/lang] it returns the correct value

mint fable
#

in the BACK END of the server

#

what PLACEHOLDERAPI sends to YOU is [lang]rank[/lang]

austere hawk
#

Rank returns me in English and Spanish Rango

mint fable
#

this is then INTERCEPTED and TRANSLATED by the plugin

#

that is why you see the correct value

#

and the reason you do not see the correct value when using %str_uppercase_[lang]rank[/lang]% is because

#

placeholderapi sends the message to you saying [LANG]RANK[/LANG]

#

which will NOT be intercepted and parsed by your translator plugin

#

because it's out of format

#

if you were able to have triton translate before it reached the internals of papi, things might be different

#

but I don't know if that would be possible in many/any scenarios

#

wait!

#

triton provides placeholderapi placeholders

#

so you can use it

#

%str_uppercase_{triton_rank}% should work

austere hawk
#

The creator told me that the placeholder %% doesn't work

mint fable
#

%triton_rank% doesn't work?

#

why would it be on their wiki then thonking

#

says since v1.1.0

#

/papi parse me %triton_rank% what does that say?

austere hawk
mint fable
#

looks like it's built-in, no expansion needed

austere hawk
#

the creator lied to me then

#

work

mint fable
#

and what about /papi parse me %str_uppercase_{triton_rank}%

austere hawk
#

Work

austere hawk
#

Still the problem with localtime?

#

Does anyone know another way?

#

Since the only way to fix localtime temporarily is with the key test that I have to acquire

noble vector
#

@junior musk hey i've just used ur color_utils expansion, is it possible for me to add hex support? i tried to edit ur source but it resets color to previous anyway 💀

junior musk
#

RGB colors depend on which plugin you use the placeholder in

#

I don't think I can parse them myself

noble vector
#

ohh okay thank you

#

is it possible to insert one variable into another like: %rgb_%luckpermsrank%% ?

junior musk
#

with Utils

#

xD

#

%utils_colors_{rgb_{luckperms_rank}}%

noble vector
#

actually i did the same but doesnt work for some reason...

junior musk
#

send me what you used and what it returns

noble vector
#

i used the same as in your message and it returns the same string in output '%utils_colors_{rgb_{luckperms_rank}}%' without any changes

junior musk
#

did you download Utils?

noble vector
#

sure

junior musk
#

oh my bad try color instead of colors

noble vector
#

oh everything translates now except rgb part i think it could be a problem of that extension?

junior musk
#

I don't think so

#

it's just that it depends where the placeholders are used

#

RGB is not supported everywhere

#

and not all plugins support it

junior musk
#

idk

noble vector
#

oh ok thanks anyway

junior musk
#

that rgb expansion doesn't seem to translate RGB colors

#

only allow you to add gradients

#

idk if it translates those colors tho

noble vector
#

oh wait

#

i can just add rgb to your extension

junior musk
#

wat

#

well idk, have fun xD

noble vector
#

i mean to add method hex and in translate colors method insert hex(message) so it will do it for itself

junior musk
#

ah, well gl

austere hawk
#

any ideea of how to fix console spamming this?

java.lang.IllegalStateException: java.io.EOFException
        at com.google.common.io.ByteStreams$ByteArrayDataInputStream.readUTF(ByteStreams.java:472) ~[guava-31.1-jre.jar:?]
        at com.extendedclip.papi.bungeeexpansion.BungeeExpansion.onPluginMessageReceived(BungeeExpansion.java:123) ~[?:?]
        at org.bukkit.plugin.messaging.StandardMessenger.dispatchIncomingMessage(StandardMessenger.java:455) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?]
        at net.minecraft.server.network.ServerGamePacketListenerImpl.handleCustomPayload(ServerGamePacketListenerImpl.java:3741) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundCustomPayloadPacket.handle(ServerboundCustomPayloadPacket.java:37) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundCustomPayloadPacket.handle(ServerboundCustomPayloadPacket.java:15) ~[?:?]
        at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:51) ~[?:?]
        at net.minecraft.server.TickTask.run(TickTask.java:18) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:153) ~[?:?]
        at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24) ~[?:?]
        at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1366) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:197) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:126) ~[?:?]
        at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1343) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1336) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:136) ~[?:?]
        at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1314) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1202) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323) ~[purpur-1.20.1.jar:git-Purpur-2035]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]
Caused by: java.io.EOFException
        at java.io.DataInputStream.readUnsignedShort(DataInputStream.java:346) ~[?:?]
        at java.io.DataInputStream.readUTF(DataInputStream.java:595) ~[?:?]
        at java.io.DataInputStream.readUTF(DataInputStream.java:570) ~[?:?]
        at com.google.common.io.ByteStreams$ByteArrayDataInputStream.readUTF(ByteStreams.java:470) ~[guava-31.1-jre.jar:?]
        ... 19 more```
junior musk
#

and please let me know if it fixed it, because everytime I send it, the person with the issue never comes back to let me know if it did or not NotLikeThis

austere hawk
#

okay, one second

austere hawk
junior musk
static mauve
#

Hi there, I have a mini issue where the placeholder isn't working 😅

This is the Utils class where I have registered the placeholders

public class Utils extends PlaceholderExpansion {

    @Override
    public String onRequest(final OfflinePlayer player, final @NotNull String identifier) {

        if (player.isOnline() && identifier.equals("current_dimension")) {

            // Return the balance as a string
            return AdventureWorld.getInstance().getCurrentDimension().getType().getDimensionWorldName();
        }

        if (player.isOnline() && identifier.equals("time_left")) {

            // Return the balance as a string
            return AdventureWorld.getInstance().getStringOfTimeLeftTillRotation();
        }

        return null; // Placeholder not found
    }

    @Override
    public @NotNull String getIdentifier() { return "ad"; }

And this is the class where I check for the plugin and register the above class

public class Hook {

    private Hook() {}

    /**
     * Checks if PlaceholderAPI is enabled and registers the custom placeholder expansion.
     */
    public static void placeHolderAPIChecker() {

        // Check if PlaceholderAPI plugin is enabled
        if (Bukkit.getPluginManager().isPluginEnabled("PlaceholderAPI")) {

            Log.info("PlaceHolderAPI plugin detected!");

            // Register the custom placeholder expansion
            new Utils().register();
        }
    }
}

Then I call the Hook class in the onEnable method.

In game I do %ad-time_left% and nope not working, any ideas?

It does register the identifier tho [Server thread/INFO]: [PlaceholderAPI] Successfully registered expansion: ad [1.0]

junior musk
#

try ad_time_left instead of ad-time-left

static mauve
#

Well

#

That worked lol, thought it will work with ad- and not ad_ lol, thanks 😄

#

Can't I make it ad-... ?

junior musk
#

nope

#

does it matter though?

#

end-user won't see it

#

only you when editing configs

static mauve
#

Oki no problem, thanks tho 😄

gleaming umbra
#

Any idea why %pinger_isonline_testplugins.com:25565% isn't working in a hologram?

urban marsh
#

Because you need the ip?

#

Not the domain

solar valley
#

How can I use Hex Colors using Papi?

#

I am trying to use hex rather than BungeeCord RGB color codes

solar valley
#

Please ping any response, thanks

reef harness
#

if a another plugin has a placeholder, how can i get its value in code?

#

Which method on the placeholderapi do you use to get the value of an existing placeholder

#

eg papi parse... but within a plugin

reef harness
#

interesting naming for sure

#

figured it would be "getPlaceholder" or something

reef harness
junior musk
# solar valley I am trying to use hex rather than BungeeCord RGB color codes

HEX is just the code that RGB colors use, and depending on which plugin you're trying to user RGB in, you have to use its appropriate format, if it supports it. For example, some plugin use &#RRGGBB, some use <#RRGGBB> while some simply use #RRGGBB, so you'd need to use that inside your PAPI placeholders (I'm guessing you want to use it in LP prefixes or smth similar, you'll have to use one of the above format in your prefix), but not all plugin support those colors, so you need to check their doc

junior musk
austere hawk
#

Yo i have a question, what is the online players placeholder? For only one server, no global

junior musk
#

%server_online%

austere hawk
#

thanks

limpid spear
#

does anyone know if there's a way to remove the seconds from %server_uptime%

junior musk
#

maybe with JS

limpid spear
#

I tried what you said in this message after searching through the helpchat discord but it didn't seem to work? just gave a wierd output

junior musk
#

it's not exactly the same thing

#

you just want to remove seconds right?

#

minutes and hours should still show ?

limpid spear
#

yes

#

please

junior musk
#
function uptime() {
  var uptime = "%server_uptime%"
  var times = uptime.split(" ")
  var seconds = times[times.length-1]
  if (times==seconds) return "0"
  return uptime.replace(" "+seconds,"")
}
uptime()
#

should work

limpid spear
#
javax.script.ScriptException: <eval>:4:20 Invalid return statement
if (times==seconds) return "0"
                    ^ in <eval> at line number 4 at column number 20```
junior musk
#

👀

#

oh right

#

updated my msg

#

forgot to make it a function NotLikeThis

limpid spear
#

Yooo! It works! Thank you so much! 🙌

tender vaporBOT
strange bough
#

I'm struggling to figure out how to show the online player count. I tried with the "Server" ecloud download and use server_online, but that just says "yes". It's not a bungee server, just standalone paper

junior musk
strange bough
#

?

junior musk
#

/papi parse me %server_online% returns "yes"?

#

are you sure you're not using player_online ?

strange bough
#

That's what I was told, I haven't been able to test myself

#

So %server_online% should work for what I'm trying to do?

junior musk
#

yeah

#

it's likely that the user had the wrong placeholder and used %player_online% (which returns whether the player is online or not) instead of %server_online% which returns the player count

strange bough
#

I'll double-check when I get home. I assume it works, so I'll just say thanks for the help now.
Thanks 🙂

sharp bloom
#

is there any placeholder that returns for how much time a player has been online? aka smthing like the /seen of essentials

junior musk
#

there's a placeholder for the time a player joined at, but idk about a placeholder for that

sharp bloom
#

ye i couldnt find anything like that either thats why i came to ask :/

junior musk
#

you could make a suggestion on the Player-Expansion repo

sharp bloom
#

that expansion hasnt been updated in ages evil_cat

junior musk
#

I know xD

#

I'll probably fork it tomorrow

sharp bloom
#

ok wait last update was june 16 of 2023

#

not bad

#

there might be a workaround with players localtime placeholder x last join placeholder 🤔

junior musk
#

I see JS

#

but I don't like JS

sharp bloom
#

but aint gonna bother to find it cshrug

junior musk
#

so I won't do JS sadness

sharp bloom
#

ye i hate js too pepe_exhausted

#

608 menus and only 2 use javascript