#placeholder-api
1 messages ยท Page 169 of 1
Now it's fixed it
oh ok
i have a rpoblem with placeholder api i need help pls
How do you mean that ?
read channel topic ๐
A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.
A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.
A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.
sry
@hidden pumice just update your server expansion
do /papi ecloud download server then /papi reload
For the math expression do you think its possible for it to pick a random number between the specified number?
Or is that not possible
not possible. but you can use the RNG expansion if you want that
Do you think its also possible for the expression to output a modifier with it?
a modifier?
Essentially I am doing a dnd roll with the expression
So when I do /roll 1d20 it'll pick up the 1 and 20 %rng_0,20% then say I want to add +4 it will add 4 to the total.
I mean you can use the math expansion for that. you generate a random number and add whatever you want to it
It has been a while since I updated, just did so and noticed some errors, so I updated the expansions. Now I have 2 sets of expansions in my folder and one of the player expansions is throwing an error. Can I safely delete one of the expansion files? Currently I have Expansion-player.jar and Expansion-Player.jar. Which would be the correct one to remove?
This is on v2.10.10
just remove both and use /papi ecloud download player then /papi reload to have the latest
fixed, thank you.
I assume animatedscoreboard supports PAPI, so make sure u have downloaded the statistic expansion
/papi reload```
I did it
Example %statistic_deaths% doesn't work
Just show 0
Server running on paper 1.16.5
Latest version of papi
Well do u have 0 deaths? if its returning a number then that indicates that it should be working fine
.-.
the statistic expansion just returns whatever statistics the server is holding
I tried to die but it still show 0
if u run /papi parse me %statistic deaths%, is it still 0?
Yes
that means your server is not recording the statistics correctly then
or you just haven't died yet
Hey what is the placeholder to display the total players within a network?
And I assume I can use this placeholder for my backend servers, this is for Velocity
@cold temple
I thought bungee_total was per server
Also didn't think it would work on velocity o.O
will try now thank you
hey! i want to do something like alias for my player_direction but its not working can u help me? There is the code
player:
ping_color:
medium: '&e'
high: '&c'
low: '&a'
player_direction:
w: 'โฌ'
can someone help me with this?
@sharp jay ur the only online sorry for pinging u
Please respect the rules, be patient and don't ping staff members!
there is 20 other people online
Not rn
yesterday was today but with a day off
Please respect the rules, be patient and don't ping staff members!
What is?
e
hey! i want to do something like alias for my player_direction but its not working can u help me? There is the code
player:
ping_color:
medium: '&e'
high: '&c'
low: '&a'
player_direction:
w: 'โฌ๏ธ'
do you understand what i want
if the papi parse is W then i want to be it โฌ๏ธ
like
west: โฌ๏ธ'
Dont Really understand it sorry
no Fxdvs. you can't just add options to the config as you please. unless you're making your own expansion
if you want outputs based on inputs you can do it with a bit of javascript
oh
An expansion that allows you to use javascript for processing
โข Wiki
โข Community Scripts
โข GitHub
โข eCloud
here's the links ^^
var player = BukkitPlayer;
var direction = '%player_direction%';
function direction_alias() {
if ( direction !== 'W' ) {
return "&fWest!"
}
}
direction_alias();
could it work?
oh
i have the !
yea
i know
var direction = '%player_direction%';
var color = '&3';
function direction_alias() {
switch(direction) {
case 'W':
return color + "โฌ"
break
case 'NW':
return color + "โฌ"
break
case 'N':
return color + "โฌ
"
break
case 'NE':
return color + "โฌ"
break
case 'E':
return color + "โฌ"
break
case 'SE':
return color + "โฌ"
break
case 'S':
return color + "โก"
break
case 'SW':
return color + "โฌ"
break
}
}
direction_alias();
this is my final codfe
Make sure you select UTF-8 encoding dor the file
yea
@trim frost here
Hello I have a strange problem with the placeholder of the Bentobox plugin, the players who have reached 1 million broken blocks can no longer open a deluxe menu and it returns this error:
I explained the problem to the developer and he referred me to you!
Thanks !
send the ss please
could someone with knowledge of papi/dmenu explain this error to me? idk what the issue is from
Who?
When making a javascript placeholder, how can I make it allow relational placeholders? As right now, it cant be read as a relational placeholder
It's hook by the plugin i can't download new
mysql expansion works
oof
hey! why placeholderapi consumes a lot, proofs
how can i send placeholder outputs like into database
and then show it
on like a web
or something
hey, I have no clue how to use the %randomnumber_number_scale%. anyone know? %randomnumber_number_min_max%? do I replace the min max or how does it work
tried replacing, but didnt work
run /papi parse me %randomnumber_number_1_5%
what does that say?
it returns the literal placeholder
I see what's wrong. the placeholder doesn't actually install even after papi reload
ah
hmm, what do I do? ๐ placeholder won't let me install it
so super strange. it works on one of my servers, but not the other ๐
nope I lied. it's on both so I'm back to square 0
why placeholderapi consumes a lot, proofs
https://prnt.sc/1nol5yz
is lightshot dont be scare
send your actual timings report
that screenshot is useless
1sec
chances are that the placeholders are lagging, not placeholder api itself
also, it's been more than 1 second ๐ฅฒ
Hi there, I'm trying to use the %server_countdown_<SimpleDateFormat>_<time>% placeholder and tried using the u letter from this page; https://docs.oracle.com/javase/8/docs/api/java/text/SimpleDateFormat.html but it basically just returns 0 however I try and provide it
Example of what I tried: %server_countdown_uu_3%
Does anyone know how to do this properly?
Have you tried any of the examples including u?
and I don't think uu is correct, it seems like it'd just be one u since it's a single number for the day of the week
%server_countdown_u_6% does not work either
This works fine tho: %server_time_ww-u%
I assume I'm typing the placeholder wrong or misunderstanding something but I can't figure out what to type instead
The example works but as soon as I simplify it down to just dd for example it'll just return 0
This doesn't work either; %server_countdown_yyyy.u_2021.6%, but if I change it to 2022 it works for some reason
Same goes for %server_countdown_HH_23%, and adding 2022 to it makes it work but, well, I don't want to countdown to 2022
like you point it to a specific day
i don't think you can do like weekly countdowns, i think you have to specify a day per countdown
I might be able to use the math-related variables in combination with the server_time one to calculate it
yeah, there's probably some way to get the current time and like, just add to it
but I'm pretty sure SimpleDateFormat is just a pretty way to express unix time, not a relative time
i see, thank you \๐
GemsEconomy have placeholders but not uses commas, is there a way to make them use comma with another expansion?
Can I do that with Formatter?
?
formatter
Formatter
who sent this...
I asked because I couldn't understand how this thing works
I encountered such an error message while the server was booting:
https://hastebin.com/asaxolemom.md
%formatter_number_format_{GEMS_ECONOMY_PLACEHOLDER}%
thank you
Placeholder api gives me an error https://pastebin.com/y5ESQzmY
do u have the essentials plugin installed?
ye
Please respect the rules, be patient and don't ping staff members!
looks to me like you're not on the 2.19 development builds of essentials. try installing those
can I have a way to check materials, to check if the item is a tool or like it contains the name "Sword", "Pickaxe" "Axe", all in one placeholder?
I know about this, but it doesn't work
I found this, %checkitem_matcontains:SWORD,matcontains:PICKAXE% but id like to return yes if it only has one of them
And there is a way to check if the player's inventory is full? With placeholders?
Why am I getting the error "/featherboard (Startup error! Are you sure you have installed MVdWPlaceholderAPI) ?
I have installed it
anyone know a way to know the placeholders a plugin internally hardcoded?
not an expansion from ecloud
@lime slate decompile? or open it with winrar
I was wondering if there was a way with a command or something like that
if not then no problem ๐
Nope
okay, thanks for the fast response anyways ๐
np!
usually they will provide it to u on wiki page of the plugin
@lime slate I've seen /papi info ExpansionName or /papi list ExpansionName (can't remember exact command) work for some plugins. But not all. Not even sure how you make it work with that. Also the wiki has listed a lot of placeholders. Over 2.5k. the papi wiki I mean. If it's not there then usually it's on the plugin's spigot page or documentation page
I don't think I understand this question
You can use the javascript expansion for that. The checkitem one only allows 1 material I think
already changed to another plugin alternative, but thanks for the recommendation ๐
papi info only displays stuff like version and author, papi list is an ecloud command so if it's not on ecloud it doesn't work
but I already changed to another plugin which I did find its placeholders so no need to worry
Alr. It is /papi info then. But only works for a few expansions from what I've seen
%player_has_empty_slot%
Ohhh i misread the question lmao
yeah i was gonna say lol, that's like a super simple question
I was so confused
oh ok, I have a question, I use the checkitem placeholder for deluxe menus so I tried doing this
expression: '%checkitem_matcontains:SWORD% == "yes" || %checkitem_matcontains:PICKAXE% == "yes"'
and doesn't work
slip it into 2 different condition
have you tried parsing the placeholders? to see what they return?
and no don't split them into 2 conditions
bcz then it will never work. it will require them to be both a sword and a pickaxe
I don't know how the %javascript_<your placeholder identifier>% works, so I tried learning but it always returning nothing
have you read the wiki? it explains it pretty well I believe.
=links javascript
An expansion that allows you to use javascript for processing
โข Wiki
โข Community Scripts
โข GitHub
โข eCloud
see first link ^^^
okok
Hello, i was wondering if anyone has had the same problem as me before? I have a 1.16.5 server and idk why but the statistic placeholders are not working
For example %statistic_kill_entity:PIG%
And so on, like %statistic_mine_block:stone%
They always show 0
Testing this out for you rn
ty
can you try reading the statistics from minecraft?
are those 0 as well?
bcz it might be that your server doesn't record them at all
^ thats a good one
yeah. seen this happen a lot in 1.17 lately but seen it in 1.16 before as well. never found out why or how to fix. you might have to ask in your server software discord
so paper or spigot or whatever you use
I see, that's weird, ty
let me check ur script real quick
i found the first script error u missing ; after return, the ; is supposed to be outside {} of return. if u have multiple command in return u also need to use the ; inside too
like after the }?
https://bin.bloom.host/haweqideze
https://bin.bloom.host/pipomiheme
Better? or wdym i don't really understand sowwy
no what i said isreturn need to put in {} of the if it follow
an example visualize my word
var isl = %Level_bskyblock_island_level%;
function colorlevel() {
if(isl<0){return "&c" + isl}
else{
if(isl<=1000){return "&7" + isl}
else{
if(isl<=2000){return "&f" + isl}
else{
if(isl<=4000){return "&a" + isl}
else{
if(isl<=8000){return "&e" + isl}
else{
if(isl<=16000){return "&b" + isl}
else{
if(isl<=32000){return "&d" + isl}
else{
if(isl<=64000){return "&5" + isl}
else{
if(isl<=128000){return "&6" + isl}
else{
return "&4" + isl
};
};
};
};
};
};
};
};
};
};
colorlevel();
let me try do it for u XD
never have i ever seen a console print so faaast
why there is space between if and the condition aka the ()
that space is what f u up XD
can u send a correct version? XD
sure XD
oh jeez
thats one big fat arrow ๐
๐ฌ
u have the same taste as Start XD
btw there is a ghost return
the ghost return will break your script
Start?
*Star
typo real hard
Star is also on support team 
i know
wdym? iirc spaces usually don't matter in JS
basically u trying to make ur script return a value it unable to evaluate aka no condition
conditions should not be necessary
so return "Talk to Reza!"; ?
yes
u want it to always possitive ?
yes
if they have the perm
but since if they get a higher perm the placeholder changes
why every1 hate arrow code ;-;
plus add some spaces
such as if (isl < 0) { return }
helps with readability
any idea what is wrong with these ?
u trying to return too many line like i said

there is a non condition return and a conditioned return
make it return 2 time
which is impossible for the placeholder
that why i said ghost return
but the higher permission should be prioritised? that's how someone explained it to me atleast
yes
why not?
it returning 2 line
?
what is returning 2 line
the script just checks a bunch of perms, if it's true then return whatevers in the if statement, if none are true then return "Talk to Reza!"
but it's throwing errors?
the return "Talk to Reza!"; have no condition make it always possitive and the placeholder will always try to print it, and the if statement above have no link to this 1, so it cuasing the placeholder trouble
yes but it's at the bottom
JS goes top to bottom
it won't just go to the bottom..?
yes it do but there no stop point
the return "Talk to Reza!";
what?
is the stop point ..

what line?
wut?
u just send the line to fix the issue then quicky remove it
the script WORKS but it's throwing errors occationaly
well fair but it's not necessary?
actually that what i want it XD
btw plz use switch
nono
wait wut is switch
.......
https://bin.bloom.host/veheyewiko.php makes the code cleaner 
but my issue persist XD
btw do you have more scripts than these?
[02:02:37 ERROR]: [PAPI] [Javascript-Expansion] An error occurred while executing the script 'quest':
Failed to evaluate requested script.
yes
https://bin.bloom.host/hemogegehi.php btw accidentally made a typo
hmmmmm
new javascript expansion run java 16
???
how does java 16 have to do with this
yes i know they released an update for java 16
can u try this: https://bin.bloom.host/ajenabodix.php @molten bison
wait no
dont
i doubt itll fix
but
ยฏ_(ใ)_/ยฏ
i get most issues with the quest one tbf
hmm
i think the switch thingi actually fixed this one

it's not throwing any errors for it yet
anyways here is ur perm check stuff https://paste.helpch.at/ekodixakup.js
what
i just fix the typo and the free condition return .-.
no
i know case is better but im doing something else rn so cant change it
it surely didn't like that one
thats basically the same thing but with a redundant ;, no spaces (decreases readability), and a redundant else statement
i think
the original give error
both do
?
can this check the condition ?
technically it isn't papi's fault, it's the javascript library
๐ฅฒ
has the second script errored yet?
i restarted the serverl ike 1 sec ago but not yet
yes u can
but i needed to restart it
they both seem to work
now
ty for help
and good night
yeah
and for the featherboardapi, i need to add as a dependency featherboard?
couldn't find a maven repo or smth
I need help with the %world_players_<world>%. I keep doing the command with my znpcs npc but nothing comes up. Am I doing something wrong or?
Please respect the rules, be patient and don't ping staff members!
nice help.
Is ecloud down? I can't update or download any new expansions
PlaceholderAPI eCloud is online and responding.
Should your host not allow connections to the PlaceholderAPI eCloud, you can manually download expansion from https://placeholderapi.com/ecloud and place them in your /plugins/PlaceholderAPI/expansions/ folder.
Can I have help with the world expansion please?
what u trying to do ?
So in my spawn I have an npc that takes you to another world
have you tried the placeholder in /papi parse me ?
please do.
/papi parse me %placeholder%
and you change placeholder with the one
that doesn't work
and see what it returns
So what place holder would I use to see the player count of that world?
Ye.
don't. use the server expansion
Oh
So in the <> do i put my world name?
yes
Oh
when you see <something> usually you have to replace the whole thing whit whatever you want.
My dev said he tried it but it did not work.
has he downloaded the server expansion? if not ask him to do /papi ecloud download server then /papi reload
yep
and also ask him to test the placeholder with /papi parse me %server_online_WORLDNAME%
btw. the world name is case sensitive. so if the world is named World, world won't work
Thanks
ugh. can you explain a bit? do you get any errors? does it just not work? does it work but not correctly?
it works correctly but it's throwing errors.
mind showing the errors?
A member of staff has requested I move your pastebin.com paste to our paste.helpch.at!
hmm. @thorn thunder you got a second to take a look?
is this the latest version of the expansion? I thought they changed to quick js not v8
ahhh the latest expansion doesn't enable on 1.16.5
oh? did you check the startup logs?
you don't have to
[14:39:33 ERROR]: [PlaceholderAPI] Failed to load expansion class JavascriptExpansion (Is a dependency missing?)
[14:39:33 ERROR]: [PlaceholderAPI]
java.lang.UnsupportedClassVersionError: org/openjdk/nashorn/api/scripting/NashornScriptEngineFactory has been compiled by a more recent version of the Java Runtime (class file version 59.0), this version of the Java Runtime only recognizes class file versions up to 55.0
it needs 15 then?
ughhhh
Oh yea, we had that issue I think, just need to recompile nashorn with java 8
yeah. 15. but idk what yugi means with the recompile against java 8 part?
@thorn thunder do u mean that the javascript expansion needs to be recompiled?
where can i find old expansion versions?
on ecloud page or u can specific a version to download
with the /papi ecloud download <expansion> <version>
and what is the latest version i can use with java 11?
idk try role back 1 version
[15:01:42 WARN]: [PAPI] [Javascript-Expansion] Failed to set ScriptEngine for javascript placeholder: playerlocation
[15:01:42 WARN]: [PAPI] [Javascript-Expansion] ScriptEngine type for javascript placeholder quest isn't initialized! Defaulting to global
what
is this supposed to mean
you can ignore. you can also disable by going in javascript_placeholders.yml and adding engine: nashorn after the line you declare the file in
for each of them
ignore it? the placeholder doesn't work xd
okok
No
Please respect the rules, be patient and don't ping staff members!
what does this mean https://pastebin.com/0fjzqUhm
it means one of your expansion classes is messed up
i would delete all of them and start downloading them fresh one by one
then you'll know which one is the problem, if any still are
This is making it so it doesn't load any of them placeholders https://pastebin.com/3ZkYmt44
But only sometimes. Why would this be?
I can restart the server 10 times but only 4 of those times will this error show
welll... as Star said. One of your expansion is broken. We don't know why or how it breaks but it does and when it breaks, it breaks the entire expansion loader so PAPI can't load the other expansions
I deleted all of them and have freshly redownloaded them
directly from papi cloud
stil does it
I'm doing that but the error doesn't always show
well
what you do
is get just 1 expansion
you do a bunch of /papi reload
see it doesn't happen like 0 out of 10 times
or something
then get the next one
try again 10 times
etc.
omg
It only shows up when restarting
I downloaded all of them and did /papi reload 15 times
doesn't show
well then you'll have to restart I guess.
so i have this JS placeholder which basically returns null if null or the string with a colon and a space in front. however, since players have full access to the message, if they put a quote, it breaks the placeholder with this error: [13:02:46 INFO]: gecko10000 issued server command: /afk " [13:02:46 ERROR]: [PAPI] [Javascript-Expansion] An error occurred while executing the script 'afk javax.script.ScriptException: <eval>:1:10 Missing close quote afk = """; ^ in <eval> at line number 1 at column number 10
how could i either filter out all these unusual characters or stop this from happening?
yo @errant iron I've not looked at PAPI code but you've worked with it. I see this being pretty common. is there any chance you can like make a debug message or something you can enable from config.yml telling you which expansion its trying to load or something like that?
yes. you can't just have """
you have to escape the middle one
javascript doesn't know what you're trying to do
how would i escape the contents of the placeholder is my question
afk = "%cmi_user_afk_msg%";
oh
when i do /afk " it breaks from user input
i don't even know what causes this error man
it's like a weird java thing that it can't read from the file or something
well you don't need to catch the error. just tell us what expansion it will load next
so we at least know where to look at
instead of having to go 1 by 1
can I see the entire code please?
i think it might be vault
afk = "%cmi_user_afk_msg%";
function formatAFK() {
return afk == "" ? "" : ": " + afk;
}
formatAFK();```
nvm
wait. so you can basically set your own afk message to whatever you want?
not vault
that's all it is and it normally works fine, but since the placeholder is replaced directly it causes issues
yes
hmm. I wonder if javascript has like an escape method or soemthing to escape entire strings. 1 moment
๐ thank you for looking into it
well... we're lucky I guess
there's a method
called escape()
xD
hmm
but I Don't think it does what we need
since the placeholder seems to be replaced directly i don't know if it's possible within the placeholder file itself
it would have to be part of the expansion, maybe? a setting in the javascript_placeholders.yml per script?
alright. so
afk = encodeURI(%cmi_user_afk_msg%);
function formatAFK() {
return afk == "" ? "" : ": " + afk;
}
decodeURI(formatAFK());``` something like this maybe?
without quotes around the placeholder?
is there any real benefit to updating expansions? I have the old ones that worked
well. I mean. Usually they add new stuff, they might fix bugs etc.
try this build
without quotes does not work
surrounding it with quotes works, but i assume it has the same issue since the placeholder is being literally replaced without being escaped
well that's what I'm asking you. to test it in the condition you were testing it before.
alright. then I recommend you go to: https://github.com/PlaceholderAPI/Javascript-Expansion/issues and open an issue. tell them that the placeholders are parsed first and if they contain quotes they will break the javascript. ask them what can be done and to do it. ๐
Caused by: java.lang.LinkageError: loader (instance of org/bukkit/plugin/java/PluginClassLoader): attempted duplicate class definition for name: "me/clip/placeholderapi/PlaceholderAPI"
I've restarted the server roughly 20 times now and the error hasn't returned. Seems like that dev version works
thank you
you have two PlaceholderAPI.jar's in your plugins folder
ugh. localtime_timezone_<timezone> is a placeholder
localtime_timezone_<format> is not
use %localtime_time_<format>% instead
Is it possible to set this placeholder to display the countdown for each Sunday in deluxe menus? %server_countdown_<SimpleDateFormat>_<time>%
use a javascript placeholder to run a timer for this placeholder
Hi, i want to use PlaceHolderAPI in my Plugin so other users use the replacements, how can i replace the replacements in my plugin with PlacerHolderAPI?
[06:51:06 ERROR]: [PlaceholderAPI] Cause: IllegalStateException zip file closed```
This error only occasionally happens
I've deleted and redownloaded the expansion 4 times
@ blitz I think I found the expansion causing the issue from yesterday
wrong java version
this is what it failed to load https://pastebin.com/mbtkmPpE
this is when it passed and loaded fine https://pastebin.com/NiJEttHR
im reading it manually
oh
cause barry have a error and solution function, but it not always work
ooo
i was expecting barry to detect ur error and show the solution
I switched to an older expansion version and after 6 or so restarts, it's been working fine
He's only trained on very frequent simple to fix errors
so I'm guessing there's an issue with the new version
Try uninstalling chatcontrol
We've had reports it goes rouge when working with papi js
I did that before and it doesn't solve it
I looked into it and it's an addon because java 16 doesn't ship with the needed... stuff
I use deluxechat as the primary source for chat and chatcontrol for everything else
a bit redundant but I'm still waiting on the new deluxechat to be released
[PlaceholderAPI] Cause: IllegalStateException zip file closed is that really the full error?
What did you change between them?
nothing
oh lol
a few seconds between restarts
?
only the time it took to close my local server and to restart it again
wait u use /reload ??????????
na
ok phew XD
Not sure why it's reporting in the [ForkJoinPool.commonPool-worker-7/ERROR]: for the broken one?
ii have no idea
almost like something is modify the jar
Does it fail more often then it works?
or is it random?
I'm gonna be a pain and request something
I can give you both java expasion verions
Mind dragging all ur plugins besides placeholderapi into a folder called _disabled and restarting
the older one that has yet to fail after 10+ restarts
and the one that randomly fails (new version)
is it the same js expansion version?
the old one?
as in the older one and randomly fails (new version)
Honestly not sure but it's from my 1.16.5 sevrer and i haven't updated the expansions in yrs
ah
the new one is from yesterday
Probs the non java16 ver
very likely
Anyhow mind doing that _disabled thing?
create a folder called that and drag all the plugin .jars besides papi in it
I could just delete everything
up to you
same effect?
folder just means you can bring back stuff slowly
Updated js expansion has one known issue
Nashorn in it is compiled with java 15
So it wont load on prior versions
Believe Ergenta is on Java 16?
Oh?
Checking, could be wrong
Any stacetrace or other info I could look at on what went wrong?
Java(TM) SE Runtime Environment (build 16.0.2+7-67)
Java HotSpot(TM) 64-Bit Server VM (build 16.0.2+7-67, mixed mode, sharing)``` this is what it's running on
[07:07:08] [ForkJoinPool.commonPool-worker-7/ERROR]: [PlaceholderAPI] Cause: IllegalStateException zip file closed is the only thing being reported which is odd
Hmm
Ergenta when you get a sec can we have a /papi dump aswell?
Uh
Keep as is for now
Are you sure the js expansion is having any issues
essentials failed to load
im on restart 5 now and the error doesn't show
I also deleted the old expansion and downloaded a new one
old as in from yesterday
good good
this is the entire folder
Not something we're going to download, just for our safety
how can i get cube ping ?
is there anything else you want me to test
If that's all working try adding back your plugins
and if that breaks it, take them all out again and slowly add them back until you find the source, good old trial and error
I tried that yesterdya but the issue is, it randomly does it
Keep trying to get it to fail by itself then I guess
report back any stack traces it produces should it do so
any real downsides to using an old expansion?
It shouldn't work on java 16
it does
can someone setup me up a placeholder for the %server_countdown_<SimpleDateFormat>_<ActualDateAndTimeBasedOnSDFSpecified>%
for the date
18/08/2021
and the time 12:00
i can do the simple date format is just the datetime thing
12 in the middle of the day?
Yes
hi my placeholderapi just shows what i type in config in chat
Default_Format: "{vault_prefix} {vault_suffix} {placeholderapi_guilds_name} {player} &9>&f{message}"
everything works but guilds just shows like that in chat
@ FunnyCube I think I figured out the cause
it was because of discordsrv
I'm guessing it's because it wasn't connected with a key yet so it was shutting down
the process of shutting down some how effected the loading of the expansions... but only some times.
Can someone help me when I use papi reload i keep getting this error java.lang.IllegalStateException: zip file closed
Kk ill test
Hi, I have been trying to add a kill and death count to the PlaceholderAPI in the form of the extension KillStats however the placeholder is not parsing (I tested it with /papi parse me %killstats_kills% and it returned %killstats_kills%)
Specifically I am trying to use the placeholders in the TAB plugin
The server is on 1.16.5
Could anyone help out?
Oh and before you ask the PlaceholderAPI plugin is fully up to date
@lilac oxide sorry for ping but it says you are support aha, do you have any idea why I am having this issue?
Please respect the rules, be patient and don't ping staff members!
Oh oops sorry
When I do /papi register Expansion-killstats.jar it returns this fail message: Failed to register expansion from Expansion-killstats.jar
I want to add my expansion to ecloud
Hello, Good Evening I would like to know how mvdw placeholders work I wanted to know how to use a mvdw placeholder on papi already downloaded the extension but did not understand the example of how using someone could help me?
dm me a username and email you'd like
oops srry
When using BaseComponent[] is it possible to parse the placeholders or not?
Hi guys , i use %statistic_player_kills% for a leaderboard and it also returns a value (0 cuz i didnt start server yet). But the preoblem is when i kill someone the value doesnt update at all ,always 0 , when i do papi parse for that placeholder too.
Could someone help me with that please
So I'm already using papi but I wanted to use a mvdw placeholder already installed the mvdw expansion, however I still don't understand how to use it.
Please respect the rules, be patient and don't ping staff members!
Hello, the current expansion - skript is outdated, and I have made a new expansion that works with the newer versions of PAPI.
I am unable to register an user, and was forwarded to this discord server.
hello. Ugh. there might be a problem with this. there's already an updated expansion of skript: https://github.com/Altruiis/skript-expansion
Iam using BaseComponent with hover event how can I make the placeholders parse now its still this https://gyazo.com/b78ad2a04ed30c554158123a33ac00bf
you will probably have to serialize to string, parse and deserialize or something
That will break the Hover event I think
well PAPI only supports strings afaik
I think 3.0 version will support Components but currently only string is supported
when is 3.0 comming
No ETA.
will it be weeks or months or no idea?
ok ty
like its not something that will come out soon
I guess ill have to code an API for my token plugin to link to my chat plugin
Anyone know if it's possible to make it so the Statistic expansion can pull data from offline players?
not possible. no.
d;spigot offlineplayer#getstatistic
int getStatistic()
throws IllegalArgumentException, IllegalArgumentException, IllegalArgumentException```
Gets the value of the given statistic for this player.
the value of the given statistic
IllegalArgumentException - if statistic is null
IllegalArgumentException - if entityType is null
IllegalArgumentException - if the given parameter is not valid for the statistic
statistic - Statistic to check
entityType - EntityType offset of the statistic
@turbid tide since 1.15
well. the statistic expansion doesn't support it.
Yes, I know
that's what I was talking about
I'm already using papi, but I wanted to use a mvdw placeholder already installed the mvdw expansion, but I still don't understand how to use it could someone help me?
btw what placeholder is it? (since papi might have it)
but the placeholder is %mvdw_<placeholder without {}>%
you'll also have to do /papi ecloud download MVdW
So I saw it on the site, but I didn't understand it very well I'm Brazilian and sometimes the translation from one language to another goes a bit wrong if it doesn't bother you could you give me an example using any placeholder?
Hi, what the precision means in %math_[precision]:[rounding]_<expression>% placeholder?
Number of decimals
Anyone know of a placeholder than can display a top 10 list of blocks placed, mobs killed, players killed, blocks broken and such?
Oh well, I did not know.
Anyways - that skript expansion version isn't on ecloud.
Either way I think at least one of the expansions should be on ecloud.
This is the link to mine: https://www.spigotmc.org/resources/papi-skript-variables-expansion.95416/
Please respect the rules, be patient and don't ping staff members!
hello . where do statistic papi expansion get data? cuz i use rankup plugin . and the statistic between rankup plugin and scoreboard are not the same eventhough i use the same placeholder.
From the world file.
Not sure if this is the right channel but is there a way I can be registered to upload an expansion? https://gyazo.com/6d1b1c1e3f622f14e6fbfa3e472e58cf
Please ping me for a reply
@balmy marten ^
dm me a username and email you'd like and i'll create it from here
Thanks
hello. so I Just took a look thru the ecloud. and there's 2 updated expansions up there.
SkriptLang was updated june 6 and Skippi was just uploaded today. I'm not sure if another one would be a good idea since it would just makes things more confusing. those 2 will work on latest PAPI version.
How do you use the Players expansion with discordsrv?
anyone has javascript for custom tps placeholder? i try to learn javascript but i dont understand it xD
why would you use a custom javascript for it?
i want it to show Good instead of numbers. example: 19-20tps= good, 17-18=playable, 15-18= call admin
var tps = parseInt("%server_tps_1%");
function convertToText() {
if (tps < 17) return "Call Admin!";
if (tps < 18) return "Playable";
return "Good";
}
convertToText();
something like this then
aye. thanks a lot . ill figure out how to put it on animatedscoreboard. thanks
probably want to use %server_tps_1% though
otherwise it would return tps from 1, 5 and 15m and wouldn't be able to be parsed as an int
oh right
Forgot about that
@civic bough updated the js bcz the placeholder I was using was not the correct one for getting the tps
btw
if you don't know how to set up a js placeholder
its pretty easy. here's the wiki link:
An expansion that allows you to use javascript for processing
โข Wiki
โข Community Scripts
โข GitHub
โข eCloud
aye. i will
yeap. thats where im looking at now xD . thanks
also dont you have to add convertToText() at the bottom?
Please respect the rules, be patient and don't ping staff members!
Hello i have a problem with placeholdersapi ๐ฆ
i register a placeholders %boat_1% and if y modify the text of %boat_1% is not refresh, if i reconnect it's refresh thank you ^^
can someone help
A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.
Do you have outgoing connections blocked in your firewall?
i am using a free server provider, ploudos
./papi parse me %javascript_custom_tps% i use this and nothing happened. the output is empty . no output
Please respect the rules, be patient and don't ping staff members!
opss. sorry .
idk if you saw but I had to edit the javascript again. I missed the function call. basically added the last line
oh the convert to text?
yeah. here. I added the last line basically. bcz I forgot it
alright. will try out . and its correct right ? the %javascript_custom_tps%
well. it really depends how you called it in javascript_placeholders.yml
did you call it:
custom_tps:
file: custom_tps.js``` or something like that?
yeap.
then yeah. that's a correct usage.
do i need to put engine too?
jeezz... it work now.. sorry i didnt realize the last line. thanks a bunch
yeah. its all good. I Forgot to ๐ after dkim noticed it
thanks. appreciate it a lot. and i should ask you earlier cuz i spend 3 hour to figure it out xD
xD yeah. sometimes asking is fine
Hello i have a problem with placeholdersapi ๐ฆ
i register a placeholders %boat_1% and if i modify the text of %boat_1% is not refresh, if i reconnect it's refresh thank you ^^
can I see your code please?
Paste Services
When asking for help with a config/menu/code issue please use our paste bin:
(we prefer it over pastebin.com)
โข HelpChat Paste - How To Use
use this paste bin ^^^
@turbid tide
A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.
A member of staff has requested I move your pastebin.com paste to our paste.helpch.at!
lol
ho what x)
|| why are you using DI and singleton at the same time on the same class ||
also you can just do plugin.getConfig()
when you have an instance of the plugin already?
and yes
you can just do plugin.getConifg as well
it is
are you using /papi parse me %boat_1% to test?
oh then this isn't a papi issue - but what hologram plugin do you use?
holographic display
^^^ its up to the hologram to refresh.
which addon plugin are you using to add placeholders?
are you using HolographicExtension? Or HolograhpicPlaceholders?
HolographicExtension
HolographicDisplay addon too
{fast}%boat_1% THIS IS A TEST
there's like 5 tags in total tho. they're explained on the spigot page
thank you !
How do I get my expansion verified
what expansion is it?
cc: @balmy marten
How do I format Time Played? I want to only show the amount of days and hours
@north crane statistic expansion
^^ %statistic_time_played:days%%statistic_time_played:hours%
Those 2 will give you the days and hours
I want to show the name of the Faction on the scoreboard but when I use the command /papi ecloud dowload Fations it is not available
Author and Identifier don't match what's on the ecloud, therefore can't be verified as it would conflict the update notify ingame.
Will VoteParty ever support MySQL so votes can count on multiple servers? (Im asking this because I want to buy the plugin if it does/will support)
Sorry for asking in the wrong channel but I couldnt find a channel for "pre-buy" questions
@trim mist
can I get the world time with placeholders without being formatted? like to be a long and not formatted in pm or am, I only know about these 2
%world_time_<world>%
%world_timein12_<world>%
https://paste.gg/p/anonymous/0955fe71d3ae4723b86ad18b5ed94638
Does anyone know why this javascript expansion (taken from the examples)
outputs a blank line?
From what I remember someone else recommended it and glare said that it probably won't. Unless someone decides to PR to it I guess.
I really need it so I hope he does it
long? what type of long?
like I Don't really understand what you need here
world_time_world should return it formatted as 24 hours instead of 12 AM/PM. if that's what you're looking for
I will use the Skript plugin placeholder but it doesnยดt download it
The plugin doesnยดt find the expansion
yes. currently there's like 4 expansions and they're all outdated or broken so they are not verified anymore. You will have to manually download one https://github.com/Altruiis/skript-expansion/releases/ and put it in your plugins/PlaceholderAPI/expansions folder then do /dm reload
that probably means you haven't actually declared the code in javascript_placeholders.yml
thx its worked
๐ yw
Most likely not unless someone PRs it.
Hi guys! Do I need to use Java 16 even for 1.16.5 server if I want to use JavaScript extension? I am getting this error: org/openjdk/nashorn/api/scripting/NashornScriptEngineFactory has been compiled by a more recent version of the Java Runtime (class file version 59.0), this version of the Java Runtime only recognizes class file versions up to 55.0
Yes
What about cloning repo and compiling with Java 11
I am almost 100% sure something will break if I update to Java 16 for 1.16.5 server ๐ ๐
why would it break?
Doubt it, though I think older java versions include Nashorn by default
yeah
Yea I know
you can just install old javascript expansion
So maybe use an older version of the extension if you really want to, but updating to 16 is going to happen sooner or later
Staying with years-old java versions is never a good idea
Yea... Better workaround for now
11 is still LTS dont forget ๐
I mean I would try updating and see what happens
LTS doesn't mean shit for people like you who can update a single server for free
LTS is for businesses who have tens of millions of lines and aren't so agile
I am not agile in servers too ๐ ๐ I like things that work and not keep updating every day ๐
I meant plugin updates
I don't see how that's related
But yea... I will update ๐
You own a single server, updating your JDK version is essentially free
I already have lobby on Java16 and 1.17 but it was pain
Worst case? You roll back to 11 in 5 minutes
yea yea... thanks ๐
It was a pain? Are you using plugins that haven't been updated for 1.17 yet? lol
o. did glare not finish the update yet? xD
Ah that's good! Most plugins for Paper servers are up-to-date now, it's really the like 6yo Bungee plugins that aren't seeing a lot of love
BB is open source now, so I'm impressed nothing has come up yet lol
yeah. glare has worked on it before and I know someone else as well
It did but 1.17 came with some pretty stinky chunk loading things
but idk if any of them finished updating
And I am not that big Java guy to fix it myself
U right... 99% of plugins are updated now...
yeah. and those which aren't probably won't be for a long time or at all.
btw 3.0.0 branch is pre Java 16?
ok
I would give a try compiling BB from Glare's repo if you get a chance, seems promising
bcz it was pretty painful to get it to work on java 16
I bought InteractiveBoards ๐
its merged into main now
btw
like the one from Sander I mean
it's 12 commits ahead of Sander ๐
but was it the one from github?
Yes
How I said... I bought InteractiveBoards week ago
1 sec. let me link
No time for that shit
Its good plugin btw... Seems much faster than BB
Also it have fully dynamic boards
yeah. bb turned out to be a mess internally xD
but if anyone cares, andre seems to have made some big changes as well: https://github.com/Andre601/BannerBoard-free/tree/feature/improve-bannerboard
Its still 2 months old
I was testing it week back
Every single one ๐
you were testing only glare's update. andre had a different branch