#help-archived

1 messages · Page 71 of 1

wanton delta
#

plz

devout mirage
#

sure

keen compass
#

ignore the packet if its incorrect @frigid ember

frigid ember
#

Internal Exception: io.netty.handler.codec.DecoderException: The received string length is longer than maximum allowed (22 > 16)

wanton delta
#

i think you need to accept that your way of doing things is gonna bring you bad fortunes down the line

devout mirage
#

ill just have the friends list only openable every 5 seconds

fair abyss
#

i think he isnt the developer of that plugin

wanton delta
#

best to learn redis and cache

frigid ember
#

and how I do it

devout mirage
#

caching is stupid

wanton delta
#

oh my god its literally not

devout mirage
#

for me it is

wanton delta
#

idk if ur troling at this point lmao

fair abyss
#

@frigid ember is it your plugin?

devout mirage
#

i need to get the players online status

keen compass
#

@devout mirage there is literally methods that exist for caching to update your cache if said item expired already

devout mirage
#

if i fucking cacheit wont be the valid status

dusty topaz
#

then use redis

wanton delta
#

so you use redis to keep track of the players

dusty topaz
#

send a message when a player comes online

#

and goes offline

devout mirage
#

in the friend gui it shows if a player is online or offline

dusty topaz
#

update status

frigid ember
#

what thing? @fair abyss

wanton delta
#

when a player comes online

#

send message

#

transfers server? send message

#

player logs off? send message

fair abyss
#

@frigid ember did you code the plugin which gaves that error?

devout mirage
#

if i cache a players friend it will sometimes show a friend online/offline when they arent

dusty topaz
#

if you use redis

#

it wont

#

!

keen compass
#

the only time the status needs to be changed is if a player connects or disconnects

#

any other time is not relevant

frigid ember
#

No

fair abyss
#

send full log so we can understand which plugin causes @frigid ember

devout mirage
#

im talking about loading a fucking players friends list in a fucking gui

dusty topaz
#

yes

wanton delta
#

we know

devout mirage
#

the friends list shows their friends online status

dusty topaz
#

i am talking to a brick wall

#

it seems

wanton delta
#

yea we know

devout mirage
#

so what the hell is you talking about with these silly messages

dusty topaz
#

idk, just giving helpful advice

#

no point asking us for help if u know it all tho

wanton delta
#

send a message when a player comes online. add that player to some hashmap or arraylist or some shit

devout mirage
#

its a bungee network

wanton delta
#

yea

keen compass
#

why does the online status need to be changed in between when someone connects or disconnects? Cache the status until someone connects or disconnects, update the cache accordingly

wanton delta
#

thats how redis works

devout mirage
#

omg

#

im done

dusty topaz
#

ok cool

wanton delta
#

we know lmfao

devout mirage
#

yall may know programming

#

but your dumb as rocks

dusty topaz
#

you're*

keen compass
#

we obviously know it better then you

wanton delta
#

i think youre trying to dig yourself a grave

dusty topaz
#

speak for yourself frost

#

idk how to program

devout mirage
#

no you guys know the craft but dont have the skill

wanton delta
#

you will come crying later and ask us why your dbs are so slow 😳

fair abyss
#

we know how to talk with people
know how to ask and receive help
its enough.

dusty topaz
#

i might type a msg to explain it

keen compass
#

Go update HoloAPI then if you think you are better 😉

wanton delta
#

seems strange considering ive done this before 🤔

devout mirage
#

this is why i dont bother

#

yall wanna blast me for how i code

keen compass
#

only because you asked

devout mirage
#

want me to type 5 lines when i can type 1

#

because of "conventions"

frigid ember
#

org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:86)
10.05 22:35:55 [Multicraft] Skipped 6 lines due to rate limit (30/s)
10.05 22:35:55 [Server] INFO CONSOLE issued server command: /list
10.05 22:36:02 [Server] INFO UUID of player zTheMatCraft is d5e65c5d-f3a7-37fb-9462-a80776b46674
10.05 22:36:02 [Server] INFO is leader = false
10.05 22:36:02 [Connect] User zTheMatCraft, IP 190.218.107.39
10.05 22:36:02 [Multicraft] zTheMatCraft ran command Message of the Day
10.05 22:36:03 [Disconnect] User zTheMatCraft has disconnected, reason: Internal Exception: java.io.IOException: Error while write(...): Broken pipe

wanton delta
#

no...?

dusty topaz
#

With redis, you can send messages across "channels". You can have services listening for messages on these "channels". So when someone connects or disconnects to your server, send a message on a channel. Listen for the message on every server, and update the cached friends list.

wanton delta
#

this is not in the name of conventions

dusty topaz
#

there you go]

#

does that explain how it works

wanton delta
#

this is in the name of your databases crumbling when they are being queried so often

dusty topaz
#

to a manner where you can comprehend it

devout mirage
#

that wont work because i need to load multiple data of the fucking player!

keen compass
#

And redis can do that

dusty topaz
#

then send a json object over the channel

frigid ember
#

@fair abyss

devout mirage
#

i need their rank, statsallof that

dusty topaz
#

and seralise it

wanton delta
#

Use json

devout mirage
#

no thats gay

wanton delta
#

-_-

dusty topaz
#

🤔

wanton delta
#

if you refuse to anything we suggest

#

you shouldnt be here at all

devout mirage
#

so reddis is suppossed to hold a million players in cache?

dusty topaz
#

no

keen compass
#

what makes you believe the ways we suggest don't work if you never tried them?

wanton delta
#

redis doesnt cache things -_-

dusty topaz
#

but with the way you speak, you'll be lucky to get 10 players

#

so

#

wouldn't worry about it too much

wanton delta
#

You came here to make sure if your way would work

keen compass
#

redis can cache stuff @wanton delta

wanton delta
#

we are telling you no

#

oh.

#

but you insist that it will?

#

im confused

devout mirage
#

hypixel has over 18 million unique players. you guys are saying all players friends will be cached and so thats potentially caching 18 mill players. no way in hell reddis can handle tracking 18 mill

wanton delta
#

uh

#

redis doesnt work the way you describe

dusty topaz
#

redis is only used to communicate on player join and player leave

wanton delta
#

you shouldnt talk about something you dont know about

keen compass
#

Redis was literally created for being a middle ware caching mechanism so as to not have the need to implement caching in your applications

frigid ember
#

I create a file and this says [{"name":"zTheMatCraft","uuid":"d5e65c5d-f3a7-37fb-9462-a80776b46674","expiresOn":"2020-06-10 22:36:02 -0400"}]

keen compass
#

But the nice thing with Redis however, is that it can grab data for you to cache though

#

as well as putting stuff in there yourself

devout mirage
#

i dont want to use reddis

#

im doing this bungee

wanton delta
#

🤦‍♂️

devout mirage
#

so tell me the best way to do it with bungee

wanton delta
#

redis

keen compass
#

Redis is powerful if you know how to leverage it

devout mirage
#

no

#

bungee only

dusty topaz
#

bungee messaging channel !

keen compass
#

redis can be used across servers regardless of locations

devout mirage
#

stfu about reddis

dusty topaz
devout mirage
#

what good is that

wanton delta
#

stop saying reddis lmfao

dusty topaz
#

it sends messages ... across bungee...

#

without redis...

devout mirage
#

i already know about messaging channel

wanton delta
#

sakljgbak

#

then why dont you use it

devout mirage
#

i use it fr private messaging ONLY

#

because im not going to slow it down my sending dumb messages when i can just get stuff from mysql

wanton delta
#

i dont think you know how things work

devout mirage
#

i know how it works

dusty topaz
#

then why doesn't it work

frigid ember
#

mss

keen compass
#

plugin message channel uses an already existing connection of a player

devout mirage
#

im just concerned about players on my servers loading their friends likst of 50-100 players

#

want to make sure mysql can handle that

keen compass
#

100 players is nothing

dusty topaz
#

and rightly so... if only there was a way to track players easily without being resource intensive ...

devout mirage
#

then im good

keen compass
#

however, though think of it this way though

wanton delta
#

you can fetch/save the player lists no problem

#

but when it comes to checking if theyre online

keen compass
#

if you don't cache, and you have 100 players with 100 friends

wanton delta
#

you need to use a system like redis

keen compass
#

that is 10,000 queries

devout mirage
#

no i dont

keen compass
#

for no reason at all

devout mirage
#

i dont track players in bungee

dusty topaz
#

they can do a mass server crash

devout mirage
#

everything is done with mysql

dusty topaz
#

everyone just keep doing /friends

#

on the server

#

and watch it burn

devout mirage
#

why would it

wanton delta
#

so youre saving/deleting players when they come online and offline?

devout mirage
#

its only 100 queries each/friend

dusty topaz
#

if 100 people on with each other added as friends

keen compass
#

times however many players

dusty topaz
#

let me guess, you do SQL queries on main thread also

devout mirage
#

when someone loads their 100 player friends list all of their friends data are downloaded from mysql

keen compass
#

and then we have 100 players doing the same

frigid ember
#

10.05 22:43:51 [Server] INFO Skipping plugin SkyWars with author [CookLoco] and hardcoded author Wietje
10.05 22:43:51 [Server] INFO Starting UUID caching
10.05 22:43:51 [Server] INFO Starting player data caching for: world
10.05 22:43:51 [Server] INFO Fast mode UUID caching enabled!

devout mirage
#

each server has a max of 20 players

wanton delta
#

you should get all that info on startup

#

so its cached and ready to go

#

and save every 10 minutes or so in case of crash

keen compass
#

especially if its only 20 players

#

so wasteful to not cache, and sub-optimal

devout mirage
#

20 players loading their friends list of 100 players max every second is going to crash mysql you are saying???

wanton delta
#

why did you ask us this question

keen compass
#

fyi, hypixel caches data and if they didn't everything would crash and burn

#

XD

dusty topaz
#

as does mineplex

#

as does cubecraft

wanton delta
#

and im 1000% sure they use redis lmao

keen compass
#

wouldn't surprise me, I mean its literally designed for that

devout mirage
#

answer the fucking question

wanton delta
#

youre not being very nice to the people trying to help you

devout mirage
#

cause yall being difficult to anser yes or no

dusty topaz
#

Hypixel: 'Redis and MongoDB experience is a plus'

keen compass
#

if you are not a DBA and have 0 experience with MySQL server configs, odds are yes your mysql server will come to crawl

dusty topaz
#

hypixel use redis, they must be idiots (/s)

devout mirage
#

what if i use hikaricp with my mysql?

#

then will 20 players loading their friends list of 100 players max every second is going to crash mysql you are saying???

wanton delta
#

wtf

dusty topaz
#

i'mma head to sleep

wanton delta
#

are you going to ask us the same question for every mysql variation out there

devout mirage
#

if i have hikaricp

dusty topaz
#

hikari is just a connection pool

devout mirage
#

doesnt that make things more scalable???

dusty topaz
#

it's still mysql

keen compass
#

I am not entirely sure why you keep asking questions

devout mirage
#

yeah so it would be less likely to crash right?

dusty topaz
#

no

wanton delta
#

no

keen compass
#

You obviously don't care about the responses

devout mirage
#

yes it would

wanton delta
#

you dont know how sql works

#

you are ignoring our responses

devout mirage
#

you dont know what youre talking about

wanton delta
#

you are not here to get help

keen compass
#

@devout mirage and your experience is what exactly?

devout mirage
#

ok so say 20 players requesting their friends list of 100 players every 10 seconds. thats going to crash mysql???

fair abyss
#

"6 year html programming" @keen compass

keen compass
#

lmao XD

wanton delta
#

alligator

#

we've answered that

devout mirage
#

you answered ever second not every 10 seconds

wanton delta
#

youre being

#

rediculous lmfao

#

are you gonna ask 30 seconds next?

devout mirage
#

ill put a limit on them bitch asses

wanton delta
#

then 1 minute?

sweet hemlock
#

I'm just here being

#

🤦

wanton delta
#

then 5 minutes?

keen compass
#

remember everyone, we don't know what we are talking about

wanton delta
#

what about 10 minutes?

keen compass
#

but yet he keeps asking questions

wanton delta
#

30 minutes perhaps?

#

rt chuu

devout mirage
#

i hear about people running thousands of quereis every second. dont expect me to believe 20 players loading 100 of their friends player profiles from mysql every 5 seconds is going to crash mysql especially when im using asnycconnection pooling. GTFO!

wanton delta
#

ok

#

then do it

sweet hemlock
#

there's thins thing called caching

#

but if you wanna do that

wanton delta
#

you obviously arent gonna

sweet hemlock
#

then be it

wanton delta
#

follow our advice

full wasp
#

Using mysql for that is to slow

wanton delta
#

you should go away

keen compass
#

@devout mirage have to tailor the mysql server to handle high loads, its not configured out of the box to be super optimized

wanton delta
#

and just do it your way

paper compass
#

Can cancelling blockbreakevent cause lag especially when I’m just setting the block to air and giving the player the item.

devout mirage
#

@full wasp whats faster?

wanton delta
#

@paper compass it shouldnt

paper compass
#

Kk just wondering

sweet hemlock
#

That's microseconds of calculation, it shouldn't lag

paper compass
#

Ty

wanton delta
#

i see it done many times

keen compass
#

@full wasp if you are going to suggest caching, don't obviously we are all wrong in that regards and have no clue about it.

wanton delta
#

yea we have no the fuck clue about what we're talking about

devout mirage
#

ill listen to brono not you dumb asses

keen compass
#

going to laugh if Brono recommends caching

#

XD

full wasp
#

Yes lol

#

Ok, you can use mysql

wanton delta
#

it was just revealed that brono also doesnt know what hes talking about

#

(/s)

full wasp
#

but u have to use other methods to be more fast

devout mirage
#

stfu and let brono speak

keen compass
#

lmfao

devout mirage
#

what other methods

paper compass
#

@devout mirage just cache the player data until the server shuts down and save it at constant intervals

wanton delta
#

ohsry

full wasp
#

for example in my network y use a cache in bungee

keen compass
#

wonder how many more are going to say the same thing about caching

paper compass
#

Idk what they’re talking about

#

Lmdao

devout mirage
#

the player data is cached in mysql

full wasp
#

Wen player join load stats from mysql in a bungee cache

keen compass
#

mysql doesn't cache unless you setup the queries to be cached, but even then it is only cached for so long

paper compass
#

Hah cache

wanton delta
#

"do i have to cache this?"
"yes"
"but i dont want to"
"well then you can suffer the consequences"
"but i dont want to?!??!"

devout mirage
#

ok then what @full wasp

paper compass
#

Lmfao martoph

full wasp
#

Well.. how to explain that, i put all data in a simple hashmap

devout mirage
#

in bungee itself?

full wasp
#

and use that on al network

paper compass
#

Is that what this conversation is? @wanton delta

wanton delta
#

yea

keen compass
#

yes

wanton delta
#

essentially

paper compass
#

Jesus

sweet hemlock
#

pretty much

wanton delta
#

he wants to load a friends syste

devout mirage
#

stfu dumb asses let the man speak

keen compass
#

@paper compass oh also we have no clue what we are talking about either

#

We are all dumb, and don't have skills in programming

#

we just only know the craft

wanton delta
#

not the skill

#

but if i recall correctly we've all done something similar before

#

so apparently we're the ones doing it wrong

devout mirage
#

@full wasp how do you access thestuff you have cached in bungee?

paper compass
#

If you are going to say “I don’t want to” after asking “do I cache” then don’t ask the question right?

keen compass
#

Basically that is the gist of it

wanton delta
#

he was expecting an answer

full wasp
#

We have own plugin for the stats management

paper compass
#

Jesus lmao

wanton delta
#

when he didnt get that answer

#

shit hit the fan

devout mirage
#

how does yourplugin get whats cached in bungee?

sweet hemlock
#

"cache it in a hashmap"
"okay how do you access that"

....

paper compass
#

Sockets or plugin messaging

#

Idk

devout mirage
#

stfu dumb ass

wanton delta
#

((((aka redis))))

#

(but idk what im saying)

paper compass
#

LMfAO

full wasp
#

I say bungee chache beacause the info save on the bungee and use that using the player

devout mirage
#

imma just block yall so i dont see your incompetent messages

wanton delta
#

do it

paper compass
#

“Dumbass”

#

HAHA

keen compass
#

And Brono just basically said what we already recommended

wanton delta
#

mhm

keen compass
#

we basically stated all the different ways to cache the stuff

paper compass
#

True

full wasp
#

Yes

#

but only mysql

#

no

#

personal experience jaja

devout mirage
#

@full wasp talk to me only

paper compass
#

LOl

wanton delta
#

WHAT

devout mirage
#

so how do you get whats cached in bungee?

paper compass
#

“Talk to me only”

wanton delta
#

DID I JUST

#

WITNESS

paper compass
#

Ahahahaha

#

This kid though

wanton delta
#

ope that had a bad word in it

sweet hemlock
#

Where's a staff in the midst of this =.=

paper compass
#

Huh what did he say?

keen compass
#

I think we need @subtle blade 's input on it as well I am sure he will say the same thing XD

sweet hemlock
#

nah he pinged so many people

wanton delta
#

oh

full wasp
#

@devout mirage in the own plugin we load the data from de mysql, that data cahed in a HasMap

wanton delta
#

hes trying to access data from the bungee itself

paper compass
#

I love how he demanded brono to only talk to him

wanton delta
#

but you cant do that without a socket or messaging of some sort

devout mirage
#

where is the hash map saved? in the server the data was loaded or in bungee?

full wasp
#

Yes...

devout mirage
#

in the server the data was loaded or in bungee?

upper hearth
#

The HashMap is stored in RAM. If you don't understand these concepts why are you even working with Spigot

devout mirage
#

fuck you mean yes lol

#

on the fucking server or in bungee

#

which one

keen compass
#

probably both

upper hearth
#

Which ever server the plugin is on?

full wasp
#

Where bungee plugins load men ?

devout mirage
#

so on the server then?

paper compass
#

“Shut up dumbass” @keen compass

#

Lmao

upper hearth
#

Wdym on the server lmao where else would it be saved?

devout mirage
#

in bungee

#

thats what he said before

#

so im tryna figure out how he saves and loads whatever shit is in bungee

upper hearth
#

If you're making a Spigot plugin, the HashMap is saved on the spigot server. If you're making a Bungee plugin, it's saved on the Bungee server

keen compass
#

Plugin message channel

#

it was stated already

paper compass
#

What kind of player data is he saving and loading

wanton delta
#

dessie we tryna tell him u cant just load stuff from the bungee server itself without a socket or messaging

devout mirage
#

i have a bungee network

wanton delta
#

and he refuses to use either method

devout mirage
#

and players load their friends list from mysql

paper compass
#

Ok you may want to put the commands in the bungee cord plugin then

upper hearth
#

If you refuse to use either method then stop asking us and go figure out your own way to do it

devout mirage
#

stfu @upper hearth

wanton delta
#

LOL

devout mirage
#

get blocked too

paper compass
#

LMFAO

upper hearth
#

Mhm

sweet hemlock
#

lmao

#

what is you blocking us gonna do for you lol

devout mirage
#

block their messages @sweet hemlock

wanton delta
#

idk hes blocking all the dumb stupid ppl

paper compass
#

And what’s the problem he’s having

sweet hemlock
#

nice, then block me

devout mirage
#

so i dont have to see their stupidity

paper compass
#

LOl

upper hearth
#

Our stupidity? Alr mate lol

wanton delta
#

@paper compass he wants to load a friends list on bungee

keen compass
#

validate their claim we are all dumb, despite brono stating one of the very methods we stated to do.

sweet hemlock
#

you don't deserve my knowledge as well then

paper compass
#

Ah

wanton delta
#

and he wants to send the info to the servers

devout mirage
#

deserve your knowledge?

#

you mean the knowledge you want to provide that just makes things overly complicated when they could be simplistic???

paper compass
#

Yes, I gotta be honest, you’re the only dumbass talking here.

devout mirage
#

will do!

wanton delta
#

this is a fairly simple thing

#

i would argue youre making it overcomplicated

sweet hemlock
devout mirage
#

blocked

paper compass
#

LOL

#

Guys can you send lists through bungee sockets?

keen compass
#

I mean, go ahead and listen to Brono, but not entirely sure how what brono is saying is any different then what literally 6 other people have stated

final verge
#

oh something fun to read

wanton delta
#

@paper compass json makes it very easy to do so

paper compass
#

Ahh

wanton delta
#

or gson rather

paper compass
#

I’ve never used json

#

What’s the difference between json and gson

keen compass
#

googles gson is actually quite nice for caching methods, since they are built it

#

gson is googles implementation of Json

#

but has more utilities built in especially for caching

paper compass
#

Oh it just serialises data into a string basically

#

Then sends it then deserialises it

#

When recurved

keen compass
#

Like setting expire stuff and if its expired to auto get the object again from t he source

paper compass
#

Recieved

sweet hemlock
#

Yup

paper compass
#

Epic

wanton delta
#

yea with gson

keen compass
#

But in this case, the cache doesn't need to expire unless someone DC's though

wanton delta
#

u can literally just

#

make an object a string

#

and make that string into an objct

paper compass
#

I love how that kid was like “but you’re making it complicated” lmao

sweet hemlock
#

They're obviously a troll

paper compass
#

“When it can be simpler” but if you know it can be simpler? You must know how to do it????

keen compass
#

best part is gson is shaded into spigot already so no need to add external dependencies

paper compass
#

Oh wow that’s useful

keen compass
#

yeah gson is part of guava so even vanilla mc has it too

sweet hemlock
#

Wasn't there a JSON library whose support got dropped a while ago?

keen compass
#

simple json?

#

well that is still shaded into spigot if I recall

#

but that is the only other json lib in spigot other then gson

sweet hemlock
#

hmmm, I thought it was gson that got dropped, but I guess I'm remembering it wrong then

#

I see

paper compass
#

Guys he’s not even in the server anymore LMaO

pastel basin
#

last release of json simple was in 2012 if I remember

keen compass
#

yeah, version 1.1.1

#

at this point it is only there for backwards compat if I recall

pastel basin
#

a guy recoded it and is updating it to this day

sweet hemlock
#

ahh

#

speaking of recode, I should go back to doing that

paper compass
#

I wonder what happened to alligator

keen compass
#

they left

upper hearth
#

Shame

paper compass
#

Kk

keen compass
#

wouldn't surprise me if they were silently kicked though 👀

paper compass
#

@devout mirage

#

Wait he’s still here

sweet hemlock
#

he's still here, just changed name

keen compass
#

lol

sweet hemlock
#

god forbid what if it was someone running some kind of neural network script 👀

paper compass
#

Omg

upper hearth
#

It was Choco all along

keen compass
#

that would be a plot twist

paper compass
#

I guess choco is a dumbass then?

sweet hemlock
#

w>

paper compass
#

Lmao

#

What if I was him

#

But nah I’m on my phone

keen compass
#

I am just going to save the part where the person claims everyone is dumb all the while asking for help

paper compass
#

Lol

keen compass
#

remember, we have no skills in programming

#

😉

paper compass
#

Kk

#

Hey guys how me get friends from MySQL in bungeecord to spigot yes

keen compass
#

I can say, it made my night

paper compass
#

I love how he told Bruno to only talk to him

keen compass
#

lol

paper compass
#

And told @sweet hemlock to block us

keen compass
#

love how brono recommended the very way we stated

#

and accepted brono's responses but no one elses

paper compass
#

Lol

sweet hemlock
#

some people can be dense like that 🤷

vital copper
#

aww it seems like I missed the fun

sweet hemlock
#

and I'm just here, trying to figure out the best way to make a bootstrap button the same height as rest of the inline text

frigid ember
#

do custom NBT tags save or do they have seperately saved?

devout mirage
#

no

dense rampart
#

how do you delete a page on the wiki? can only staff do that?

keen compass
#

@frigid ember yes metadata should persist unless you mean raw NBT

#

in which case no

frigid heath
#

how do i cast an ItemStack to Damageable?

pastel basin
#

@frigid heath

Damageable damageable = (Damageable) itemStack.getItemMeta();
devout mirage
#

how many requests from mysql can a db handle every second un optimized?

#

@pastel basin

pastel basin
#

I don't know

#

don't ping random people

#

just leave your question there and someone else will answer you

sweet hemlock
#

depends on the database server configuration, like CPU speed and amount of RAM

frigid heath
#

thanks

frigid heath
#

how can i damage an item and delete it if it goes below 0?
currently im using this but testing shows it does nothing, no errors.

((Damageable) event.getPlayer().getInventory().getItemInMainHand().getItemMeta()).setDamage(((Damageable) event.getPlayer().getInventory().getItemInMainHand().getItemMeta()).getDamage() + 1);
if (((Damageable) event.getPlayer().getInventory().getItemInMainHand().getItemMeta()).getDamage() > event.getPlayer().getInventory().getItemInMainHand().getType().getMaxDurability()) {    event.getPlayer().getInventory().getItemInMainHand().setType(Material.AIR);
}```
#

that looks terrible

#

lemme pastebin it

devout mirage
#

fix or repair daily @wraith thicket

wraith thicket
#

First of all, Qther, I wouldn't nest all those methods like that.

#

You'd need to make sure that the item in question has meta (the method is nullable)

#

You'd need to make sure the meta is an instance of Damageable

frigid heath
#

both are checked

#

just elsewhere

wraith thicket
#

But still, you're creating the new instance of the item meta twice for no good reason

#

Every time you call ItemStack#getItemMeta you're creating a new instance

frigid heath
#

fair

wraith thicket
#

When you want to delete the item, you'll most likely want to set it to null. You can check the maximum durability with Material#getMaxDurability

#

I think you want to call PlayerInventory#setItemInMainHand instead of setting the stack's type

frigid heath
#

so if i change them to be the same instance and do that it should work in theory?

wraith thicket
#

In fact, you're creating it 3 times. Use #getItemMeta once, increment, #setItemMeta and then check the max durability. And if it's over that, you can set the item in main hand to null

#

It'll also make your code more readable. Remember, your code is generally read more times than its written.

wanton vine
#

Anybody know why my server is crashing?

#

---- Minecraft Crash Report ----
// Don't be sad. I'll do better next time, I promise!

Time: 5/11/20 5:59 AM
Description: Exception in server tick loop

java.lang.IllegalArgumentException: ChunkNibbleArrays should be 2048 bytes not: 0
at net.minecraft.server.v1_12_R1.NibbleArray.<init>(NibbleArray.java:14)
at net.minecraft.server.v1_12_R1.ChunkRegionLoader.a(ChunkRegionLoader.java:402)
at net.minecraft.server.v1_12_R1.ChunkRegionLoader.a(ChunkRegionLoader.java:94)
at net.minecraft.server.v1_12_R1.ChunkRegionLoader.loadChunk(ChunkRegionLoader.java:72)
at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOProvider.callStage1(ChunkIOProvider.java:21)
at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOProvider.callStage1(ChunkIOProvider.java:1)
at org.bukkit.craftbukkit.v1_12_R1.util.AsynchronousExecutor.skipQueue(AsynchronousExecutor.java:336)
at org.bukkit.craftbukkit.v1_12_R1.util.AsynchronousExecutor.getSkipQueue(AsynchronousExecutor.java:295)
at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOExecutor.syncChunkLoad(ChunkIOExecutor.java:16)
at net.minecraft.server.v1_12_R1.ChunkProviderServer.getChunkAt(ChunkProviderServer.java:137)
at net.minecraft.server.v1_12_R1.ChunkProviderServer.getChunkAt(ChunkProviderServer.java:120)
at net.minecraft.server.v1_12_R1.ChunkProviderServer.getChunkAt(ChunkProviderServer.java:116)
at net.minecraft.server.v1_12_R1.MinecraftServer.l(MinecraftServer.java:374)
at net.minecraft.server.v1_12_R1.MinecraftServer.a(MinecraftServer.java:338)
at net.minecraft.server.v1_12_R1.DedicatedServer.init(DedicatedServer.java:272)
at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:545)
at java.lang.Thread.run(Thread.java:748)

chrome heron
#

how to disable mob spawning from spawner?

mossy wraith
#

@naive goblet If I set in event world worldspawnpoint than they'll not spawn in main lobby.

keen compass
#

@sweet hemlock pretty sure that is the person we already dealt with XD

sweet hemlock
#

👀

keen compass
#

if they keep bugging you or asking questions, I can only say good luck on your endeavor that like 7-8 other people couldn't do 😛

sweet hemlock
#

@keen compass I'm not sure who you're referring to >w>

#

but I'll just try to help when I'm able, or if they're too dense then ¯_(ツ)_/¯

keen compass
#

guess you missed on that then

#

lol

naive goblet
#

@mossy wraith Yeah there is probably another plugin overriding it?

obtuse rose
#

Anyone here familair with docker?
I've been trying to start docker container via ProcessBuilder (and attach stdio to it)

#

but stdio doesn't seem to work at all

mossy wraith
#

@mossy wraith Yeah there is probably another plugin overriding it?
@naive goblet Maybe... Can it be essentials?

chrome heron
#

how to disable tweakeroo on spigot server?

icy timber
#

eyo guys
I might be kinda stuck in an interesting situation here

#

Checking if Projectile has the channeling enchantment
I'm listening to ProjectileHitEvent.
Once the projectile hits the target with a channeling enchantment, I want to do something for the player.
Issue is, you cannot check if the entity contains an enchantment.
ProjectileLaunchEvent is called "After" the player has thrown the trident.
PlayerInteractEvent is called when the player draws the trident, but not when he releases it.
So there is literally no way of getting the trident when it is an ItemStack.

#

literally made a thread about this on spigot, copied and paste :P

naive goblet
#

@mossy wraith remove ess spawn?

mossy wraith
#

?

naive goblet
#

EssentialsSpawn

tranquil rampart
#

@frigid ember server.properietis

#

You need to change it there

#

Someone uses NameTagEdit?

pastel basin
#

@icy timber I would listen for projectilelaunchevent do the checks, and add the player to a hashset, then listen for ProjectileHitEvent and check if the hashset has the shooter then do the things to the entity hit by the projectile

icy timber
#

hmm

#

interesting idea

#

ill try it out

pastel basin
#

you can do it even better by adding metadata "hasChanneling" to the projectile on launch event and check on hit event if the projectile has this metadata, if so, then do things to the shooter

#

actually this would even prevent bugs because the other method could keep players in the hashset even if the projectile didn't hit anything

icy timber
#

The thing is, the Launch event fires only after the player has thrown the trident already. So we cannot figure out if the trident contains channeling then in the first place since it is no longer an ItemStack, but an entity.

pastel basin
#

are you sure? can't you get the item in the player's hand? All bukkit events are called before it happens. But if say you can't get it through launch event, just check on player interact event if the item is a trident

icy timber
#

I honestly haven't tried it.
If it works as you are saying, my problem is solved by just getting the item in the player's hand then.

pastel basin
#

@icy timber also if you use paper there is PlayerLaunchProjectileEvent which stores ItemStack and a projectile that you can use to check and add the persistentmetadata

naive goblet
#

That exist in normal Spigot?

pastel basin
#

nop

#

that's why nms would be better

icy timber
#

does paper have a maven dependency ?

pastel basin
#

probably, go in their site, if they don't just download and add it

formal nimbus
#

Hey guys

#

I have this crate gambling system

#

and everytime somebody 'opens' a gambling crate, a new inventory is created

#

this works fine, and is multiplayer friendly

#

I'm just wondering about the efficiency

#

because if a new inventory is created every time somebody opens a crate, the contents of that inventory are still being stored somewhere right, and never being used?

#

so if a server was using this and more and more inventories just kept being created as the server went on

#

would that not cause issues?

#

Also, is it inefficient to create a new inventory everytime, as you have to go through the process of creating a new inventory every time

#

it would probs be better to have a gambling inventory for each player?

#

using a hash map or something

sharp mauve
#

Every time you right click... you get both left and right click events

blissful verge
#

How can I create stuff like etokens which are currently on basically all prison servers?

sturdy oar
#

the hell are etokens

#

you should not assume everyone has played prison servers

wraith thicket
#

@sharp mauve the PlayerInteractEvent gets called once for either hand. This is also clearly mentioned in the javadocs

fluid lotus
#

I can't contact to Unban-support ?
I want to know why i got ban.

sturdy oar
#

you got banned from spigot test server?

sharp mauve
#

Thanks!

fluid lotus
#

i download many times with many plugin and got ban for leaking
that's they told me

#

i use my plugins to test in my test server.

wraith thicket
#

Who's "they"?
What medium did you get banned on?

fluid lotus
#

"You have been banned for the following reason: Leaking Plugins. To appeal, please email unban-support@spigotmc.org with details of why you were banned, why you should be unbanned, and how you will prevent it from happening again. Please note that creating a new account is against the rules and will only extend your ban."

safe gate
#

where is the plugin it self "spigot"?

wraith thicket
#

Well there you go. You need to send an email to that address.

sturdy oar
#

where is the plugin it self "spigot"?
@safe gate what does that even mean

wraith thicket
#

No idea

sturdy oar
#

oh you want the spigot jar server?

safe gate
#

like so i can add plugins tho theserver

sturdy oar
#

wutttt

#

resources

safe gate
#

lol

#

yeah

sturdy oar
#

everything is here I guess

safe gate
#

ok

wraith thicket
#

For the server jar itself you need to download and run BuildTools

sturdy oar
#

nah I don't think he meant that

wraith thicket
#

I don't think you can be sure of that :)

safe gate
#

do i just add the resourses?

pastel basin
#

?????

sturdy oar
#

they are plugins, and they shall stay in the /plugins folder of your server

heady geode
#

would Player#getActivatePotionEffects() cause thread safety issues? 🤔

fluid lotus
#

Well there you go. You need to send an email to that address.
@wraith thicket i sent it for almost 2 weeks
Nothing was returned.

safe gate
#

ok thanks

pastel basin
#

run spigot, download plugins on that link, put the plugins on plugins folder

#

@heady geode why would it?

#

it is a getter, it returns a field

heady geode
#

right, I'm just paranoid probably

#

xD

pastel basin
#

lol

heady geode
#

tnx for yah help

pastel basin
#

np

formal nimbus
#

Hey, I asked this question about an hour ago but it was buried before I got a response

#

I have a crate gambling system where every time you right click a crate, a new inventory is created

#

like so:

#

that inventory is then opened for the player, and items from the crate they opened will scroll across it

#

However, I'm wondering if this is bad for performance as every time a crate is opened, a new inventory has to be created and stored somewhere, never to be used again

#

is there a way I can destroy the inventory? Or should I just use a hashmap and give everyone a private gambling inventory?

lofty otter
#

im pretty sure java garbage collection will take care of that

formal nimbus
#

o, sweet

#

r u sure though?

#

because it rpobably doesn't regard it as garbage

lofty otter
#

if you dont have any references to an object, it gets deleted

wraith thicket
#

@pastel basin a getter isn't magically thread safe

formal nimbus
#

hmm

pastel basin
#

@wraith thicket true, I looked into the source and this method actually does something

formal nimbus
#

ok. So I probably don't need to worry about that. But it still might be better to just open a player's gambling inventory rather than making a new one every time?

#

that still must be better for performance

pastel basin
#

but if it just returned a private field why would you need to be thread safe

lofty otter
#

yes

formal nimbus
#

is that a yes to me Cableguy?

#

kk

#

welp I'll change it and utilise hash maps

lofty otter
#

i just got a warning for spamming lmfao

wraith thicket
#

Most all getter method do something, at the very least because the API is backed by NMS

lofty otter
#

for saying "yes" twice

formal nimbus
#

lol, I do too the other day. It's dumb

#

*did, though not for saying yes twice

lofty otter
#

reading a variable is always thread safe, as long as its not being changed

wraith thicket
#

And even just returning a private field is not necessarily thread safe. For instance, you could catch a double when only one of its bytes has been written to, thus you'd effectively get garbage

#

As long as it's not being changes.... That's the whole point. You don't know when it's being changed

#

If it was never changed, you wouldn't need to read it, would you?

lofty otter
#

it may be set once and then never changed

pastel basin
#

no if the player instance was the one being changed

lofty otter
#

oh wait are we talking about player instances here?

pastel basin
#

then you would need to make player thread safe

lofty otter
#

whats the context here...

pastel basin
#

yeah, the guy was asking if getActivePotionEffects is thread safe

wraith thicket
#

It doesn't really matter what we're talking about. In general, unless something was explicitly made thread safe, it is not thread safe.

#

You can access true constants (static and final), of course, but that's not really the majority of use cases

pastel basin
#

^ @heady geode

wraith thicket
#

And just because you may be able to use something in an asynchronous thread during testing (usually on your home server with one or two accounts) doesn't mean you won't run into issues in production

frigid heath
#

is it possible to make grindstone not give xp?

#

couldnt find a packet for it

frigid ember
#

Last: d9f6dd5b-c86c-3c19-83d4-41dc12249920 vs Cur: d9f6dd5b-c86c-3c19-83d4-41dc12249920, same? false can someone tell me how these UUIDs are not the same?

#

Using them as strings to compare them or parsing them as UUIDs both say they're not the same..

#

there is not.. one.. character different

#
(cur == lastUsed)```
lofty otter
#

dont use reference equality

#

use .equals

#

perfect example of this

#

same data, different instance

pastel basin
#

line 3 hyphen instead of space
line 51 to the end of file wrong space indent

paper compass
#

how do I get the title of the inventory?

#

in 1.15.2

regal cloak
#

ive been searching for almost an hour but still cant find the 1.14.4 spigot api download link anywhere, and i need it for the spigot wiki blank plugin tutorial

bleak dagger
#

what did say instead of space ?

#

what I must to change ?

wraith thicket
#

@regal cloak your can a) use maven and set the dependency with the repo b) download and run BuildTools.jar from SpigotMC.org

regal cloak
#

ill try the build tools cause the blank plugin tutorial said not to use maven

hoary parcel
#

Then the tutorial is dum

regal cloak
#

can someone just give me a link to the build tools as i cant find them

bleak dagger
#

anyone can help me plz ?

regal cloak
#

i managed to download the build tools, but when i ran it, it did nothing

#

grr seeing as build tools aint working, what tutorial for intellij says to use maven

wraith thicket
#

BuildTools work just fine

regal cloak
#

not for me

wraith thicket
regal cloak
#

ok brb

keen compass
#

?bt

worldly heathBOT
sturdy oar
#

is it evil to declare classes inside methods?

wraith thicket
#

It's not like the link you downloaded buildtools from already had the link to the wiki

sturdy oar
#

like I have this static method that has a class inside itself, because the class doesn't get used anywhere else

#

is it proper usage?

keen compass
#

@sturdy oar no, but it really depends what it is for. Can make doing certain things more difficult doing that. If its like for something simple for whatever reason go for it, not really a need for a sperate file for that.

regal cloak
#

i have tried the method before and remember it does not work, so im just gonna give up on build tools, what even is build tools? nothing has mentioned it ever befor

keen compass
#

but, like if its a large class inside another large class, probably wouldn't recommend it unless you have some weird reason for it lol

#

@regal cloak does it not work because you get some kind of error? o.O

regal cloak
#

no it litteraly does nothing

wraith thicket
#

The first section in the wiki describes what it is...

regal cloak
#

i read it and it sounds like it is creating a server which i dont want but im just making sure

keen compass
#

you need the source files which is what buildtools gives

#

ironically to obtain the spigot.jar is the same method as well

regal cloak
#

whats spigot.jar?

wraith thicket
#

The thing that runs the server

regal cloak
#

but i dont want a server

keen compass
#

you want the source right?

#

or is it the api you are after?

regal cloak
#

i dont know, it never said to download it

#

i just want a 1.14.4 api

wraith thicket
#

You want to depend on spigot in order to make a plugin?

regal cloak
#

i dont know, i just want to make a plugin but the tutorials link to the api is broken

wraith thicket
#

If you want to make a plugin, then you need the jar/source

regal cloak
#

yes it said

wraith thicket
#

Or, again, use maven

keen compass
#

api resides there

regal cloak
#

ok brb

keen compass
#

whether you want to manually download it or use maven, that is one of the few links to use

#

only the api is there, if you need anything more you need buildtools for it

regal cloak
keen compass
#

travel to org then to spigotmc

#

from there it should be easy to find spigot-api jars

regal cloak
#

its not though

keen compass
#

just told you the two directories

regal cloak
#

what about the 3rd though

frigid heath
#

are you even trying to look for it yourself

regal cloak
#

i did and i found it

#

which file though

keen compass
#

the latest one by date

regal cloak
#

ok brb

keen compass
#

use the one that has -92 at the end of it

regal cloak
#

the 3 newest ones have the same time

#

oh thanks

#

none of them have -92 on the end

wraith thicket
#

Let's be honest, if you want to make a plugin, you'll eventually need the server jar anyway, unless you want to test your plugin in a production environment (which is a terrible idea)

frigid heath
#

ah shit he's onto me :p

keen compass
#

I am not going to hold your hand every step of the way. Make a judgement call in what -92 means 😉

#

if you can't figure that out probably shouldn't be doing this

regal cloak
#

oh i get it

#

im dumb

#

this might take me a while

#

grr my eyes keep skipping one, i cant do it im gonna write a python program to do it for me

wraith thicket
#

Do what for you? Download a file?

keen compass
#

buildtools literally makes one for you

#

but ok

regal cloak
#

no, count -92 upwards

#

which is basicly 92 downwards

keen compass
#

java -jar buildtools.jar --1.14.4

regal cloak
#

like i said it dont work

keen compass
#

will literally install the api into maven repo for you

regal cloak
#

but im gonna continue to do -92

#

bye thanks

keen compass
#

I mean you could count, but why not use the browsers search function

#

to search the page

#

for something that has -92

regal cloak
#

it has that? wow thanks

wraith thicket
#

I mean, you just look at the page and it's there, to be honest...

keen compass
#

not like there is many of them, -92 is in its name, and it means it is the 92 build of that version

regal cloak
#

oh oops

#

ill check them then

#

i had no clue it meant that

fleet burrow
#

I have something like this.
Is there any way I could make the wall update it's faces to adapt to the new blocks?

regal cloak
#

im searching the web and aparrently google chrome does not have the search feature so im gonna do it manualy

keen compass
#

@fleet burrow yes

fleet burrow
#

Thank god

#

How would I go about it?

keen compass
#

?jd

worldly heathBOT
regal cloak
#

there are multiple with -92 in there name which one should i choose

fleet burrow
#

Is that for me?

wraith thicket
#

If you want an in game fix, then you can probably use the debug stick

keen compass
#

@fleet burrow ^

#

setFacing()

fleet burrow
#

Nope. stone walls are multiplefacing

#

And there is no method for resetting it's faces

fleet burrow
#

Yes.... I know..

#

lmao

keen compass
#

check which faces are enabled

#

then check if the specified faces have a block next to it

#

if not update it

fleet burrow
#

then check if the specified faces have a block next to it
@keen compass How would I do that?

wraith thicket
#

The -92.jar @regal cloak

regal cloak
#

there are multiple of those

frigid heath
#

@regal cloak chrome definitely has a search function

#

the keybind is CTRL+F

fleet burrow
#

nvm

#

getRelative

regal cloak
#

ok thanks but i now have found the -92

keen compass
#

BlockFace has directions

regal cloak
#

i just need to know which one

wraith thicket
#

There's only one that ends with -92.jar

keen compass
#

which from that direction you can get a location

#

from which you can get the block

regal cloak
#

ill try all of the .jar ones

keen compass
#

if the block is air, its not attached to a block, but has the face enabled

#

getFaces(); gets all the faces that are enabled in a list

fleet burrow
#

yup

#

I got it 👌
Thanks!

regal cloak
#

ive decided there are too many to try them all so im really asking nicely if youl tell me which -92.jar i want

keen compass
#

sources, shaded and javadoc preferably. But if you need to choose only one, shaded jar

fleet burrow
#

was rather simple after all

multiFace.allowedFaces.forEach {
                val relative = block.getRelative(it)
                multiFace.setFace(it, relative.type != Material.AIR)
            }```
regal cloak
#

ok thanks soo much

#

now i can use it

keen compass
#

shaded jar contains everything you need, sources jar just lets your IDE see that shaded jar without having to decompile it if you needed to browse it, and if you have a sane IDE, the javadocs jar provides you information to methods

frigid heath
#

or you could just use maven

keen compass
#

@fleet burrow there you go 😉

fleet burrow
#

I don't even have a line 519

#

lmaooo

keen compass
#

maybe it is complaining about using val

fleet burrow
#

makes sense actually

#

wait nope

#

why would it 🤔

tiny dagger
#

is this correct mysql syntax? 🤔 "DATE_ADD(NOW(), INTERVAL 1 MONTH)"

keen compass
#

because var means it is mutable

#

and last I recalled enums are not

#

so wouldn't you need val instead?

fleet burrow
#

I am using val

frigid heath
#

aah it doesnt load

tiny dagger
#

well

#

i have to add a lot of stuff to try and see

#

i just thought someone used it before and knows

chrome lark
#

Just use the mysql client and run it

keen compass
#

well can always just use the Block @fleet burrow instead of val or var

chrome lark
#

Beyond that, look for examples of it, stuff like that you either know or you go scour google

ripe ledge
#

Does someone here knows a plugin the make custom join/leave messages for each rank?

keen compass
#

NOW() refers to the date of now just FYI and generally is just used on its own

fleet burrow
#

I added a print statement and it fixed it

#

probably just compiled incorrectly 🤷‍♂️

keen compass
#

ah

#

weird

frigid heath
#

does anyone know if there is an event for interacting with blocks

fleet burrow
#

PlayerInteractEvent?

keen compass
#

otherwise you need to pass in the date, either using MySQL's date stuff or your own as long as it is in the valid format of what MySQL expects of a date if you specified that row as a date.

fleet burrow
#

Check if the player interacted with a block

frigid heath
#

oh wow i thought that was just an abstract class that the other events extended from lol

#

should have checked

pastel sierra
#

Anyone knows how you can make the hover like text in hypixel bedwars game status?

tiny dagger
#

chat text?

#

that can be done using the text components

pastel sierra
#

Oh.. Can you direct me to the api docs page please?

#

(Of the component)

keen compass
#

?jd

worldly heathBOT
tiny dagger
keen compass
#

ah, the api is in Bungee

tiny dagger
#

it's an api on itself tbh

keen compass
#

probably should have it in the javadocs

tiny dagger
#

org.md5.textcomponents i think

keen compass
#

well I meant javadocs wise

tiny dagger
#

oh

keen compass
#

because it is from bungee, it isn't included in the javadocs

#

and bungee javadocs are not hosted either, oddly

#

maybe whenever he is on at some point I will see if he will include some of the bungee api stuff in the javadocs for spigot

#

would only make sense that they are available there =/

wraith thicket
#

The chat component wiki page links to the javadocs, though

tiny dagger
#

you don't really need to look much lol

#

it's pretty straight forward

ripe ledge
#

I know Java and I want to learn how to make plugins. Someone have a good playlist of videos tutorial or something like this?

keen compass
#

ah its a bit hidden @wraith thicket

#

didn't notice that, still it would be worth using maven though to include some of the relevant api stuff into the spigot javadocs

#

instead of having to find a different javadocs that isn't hosted in a similar place as the spigot one XD

regal cloak
#

im wondering now what server.jar is and where i can download it from as apparently i need it according to the tutorial

wraith thicket
#

Again...

#

BuildTools

regal cloak
#

come onnnn..... grrr ill try another device then

pastel sierra
#

java -jar BuildTools.jar

regal cloak
#

and where do i type that

pastel sierra
#

cmd

regal cloak
#

ok thanks

pastel sierra
#

first cd to the directory

#

then type that

wraith thicket
#

Did you even read the wiki when it was sent to you hours ago?

regal cloak
#

yes

#

im just really stupid

#

and it still wont work

#

like i said im trying another device

pastel sierra
#

Ummmm

#

Did you cd C://Directory

#

first

#

?

regal cloak
#

yep

pastel sierra
#

Like do cd Downloads

#

Do you have git installed?

regal cloak
#

it said not enough memory said i had 0 megabites, and i do have git installed

pastel sierra
#

type git version

regal cloak
#

ok

#

ah it appers my git has gone

#

ill redownload it

frigid heath
#

does anyone know how scoreboard works?

tranquil yoke
#

How do i sort players by money i mean player 1 have 100 money so he is up player 2 have 50 money so he is down i need to sort it like this i am using PlayerListPlus somebody can help me?

regal cloak
#

i just did the command line and it will only give me 1.15 server.jar, when i really need 1.14.4 server.jar does anyone have a manual download link to 1.14.4 server.jar as i need it

#

oh

#

done it thanks

#

now i can finaly have autofill sugestions yay

#

not making every variable i type red or any mincraft stuff red text

ashen stirrup
#

How do you get the centre of a block?
I've tried this but it doesn't seem to work.

    public static Location getCenter(Location loc) {
        return new Location(loc.getWorld(),
                getRelativeCoord(loc.getBlockX()),
                getRelativeCoord(loc.getBlockY()),
                getRelativeCoord(loc.getBlockZ()));
    }

    private static double getRelativeCoord(int i) {
        double d = i;
        d = d < 0 ? d - .5 : d + .5;
        return d;
    }
tiny dagger
#

getblockx + 0.5

regal cloak
#

it says i need server.jar and the build tools just gave me spigot-1.14.4.jar, is that the server.jar?

tiny dagger
#

just + 5

ashen stirrup
#

+5 or +0.5

tiny dagger
#
  • 0.5
ashen stirrup
#

To X and Z?

regal cloak
#

im in a rush for time can someone please quickly answer my question? sorry for being rude......

ashen stirrup
#

Works, cheers

#

Just rename spigot-1.14.4 to server

regal cloak
#

really, does it work? thanks

#

or can i keep it as the original name

ashen stirrup
#

That's what I do 🤷‍♂️

#

You can keep it as it's name

regal cloak
#

great thanks soo much

ashen stirrup
#

You have to edit the batch file

regal cloak
#

ive got 10 mins ill just add it quick youve saved me soo much headache

ashen stirrup
#
java -Xmx1024M -Xms1024M -jar spigot-1.14.4.jar nogui
pause
#

That should work, if not,

java -Xmx1024M -Xms1024M -jar server.jar nogui
pause

And change the spigot file to server

regal cloak
#

ive already added it as the original name, soo i hope i did it right as if not ill be sad when i wake up, oh well byyeeeee

formal nimbus
#

fellas

#

is it possible to change the name of an inventory once created?

ashen stirrup
#

Uhh probably

#

Try it

formal nimbus
#

that's the thing

#

I don't know how to do it

finite crescent
#

For what version?

formal nimbus
#

1.15

ashen stirrup
#

I don't think you can in 1.8

finite crescent
#

Yes with the PacketPlayOutOpenWindow packet

formal nimbus
#

How would I use this?

#

also just to clarify, I don't need to change the name of the inventory whilst it's open

ashen stirrup
#

How're you creating the inventory?

formal nimbus
#

there seems to be no option like inventory.setTitle("")

#

constructor

#

CrateGUI object

#

if the image would load...

#

but using Bukkit.creatInventory()

#

*create

ashen stirrup
#

I'd probably just use Bukkit.createInventory()

#

Again

formal nimbus
#

just make a new inventory?

finite crescent
#

It updates the name while the inventory is open

formal nimbus
#

right. How do I send a player a packet

#

I could have a method like CrateGUI.updateInventory()?

#

which would then send the packet with the update

#

this is my inventory object class

bleak osprey
#

hey,

some days ago, a player took my UUID and logged in to the game as me...
Iam using a Bungeecord, how could i prevent this?

bronze marten
#

lol

#

protect your spigot servers

#

allow only bungeecord ip addres to connect to spigot

placid hamlet
#

can anyone help me with this error?

bronze marten
#

Contact Songoda about it

#

that their reflection went wrong there

silk bane
#

that's probably because you're not running the latest version of spigot

formal nimbus
#

lmao

silk bane
#

you're welcome by the way

frigid heath
#

guys i need some serious english help what do you call the radius of a square

formal nimbus
#

tbf the same thing happened to me and I thought I had the latest version

#

a square doesn't have a radius...

frigid heath
#

like

#

distance from centre

formal nimbus
#

that changes...

frigid heath
#

to closest points outside

silk bane
#

do you want half the side length

frigid heath
#

yes

formal nimbus
#

yep that's the one

frigid heath
#

but in a nice word

formal nimbus
#

there isn't 1

frigid heath
#

oof

formal nimbus
#

well, there might be

silk bane
#

i'm not aware of one

#

@bright meadow yes, it's designed to be annoying

frigid heath
#

how the hell am i gonna display that in a scoreboard lmao

#

might go with 1/2 Side Width

#

or 1/2 Width +-

silk bane
#

@frigid heath you could try 'inradius'

#

which is the radius of the largest circle that fits inside a polygon

#

in the case of a square, the inradius is equal to half the side length

frigid heath
#

yep that works holy hell

silk bane
#

but naming a variable probably isn't worth this much effort lol

frigid heath
#

lol

red kernel
#

Anyone know how to solve this error? Please @ me when you answer ^^

frigid heath
#

@red kernel instead of § use \u00a7

red kernel
#

Alright

#

Thank you^^ I'll test it now :D

naive goblet
#

Pixlie is that ur plugin?

#

Well, idk why you would use § or even \u00a7. Use the static ChatColor.translateAlternateColorCodes() or the ChatColor enum.

red kernel
#

Yes it is

#

With the ChatColor.translateAlternateColorCodes() it says the same

hollow thorn
#

how would i make a flying carpet

frigid ember
#

make a fake player called carpet and then setflying(true)

#

wait nevermind

oak stump
#

@red kernel if you do this:


import org.bukkit.ChatColor;

public class Utils {
    
    public static String chat(String s) {
        return ChatColor.translateAlternateColorCodes('&', s);
    }

}```
naive goblet
#

class Utils {
  static String color(String str) {
    return ChatColor.translateAlternateColorCodes('&', str);
  }
  static void sendMessage(CommandSender sender, String... messages) {
    Arrays.asList(messages).map(Utils::color).forEach(sender::sendMessage);
  }
}
class OtherClass {
  //EventHandler
  Player player = e.getPlayer();
  Utils.sendMessage(player, "&cRed line", "&1Blue line");
}```
oak stump
#

then you can import "Utils.chat()" and use the & syntax hylighting

red kernel
#

Alright

#

Thank you ^^

naive goblet
#

Don't static import it. Use Utils.method() as Symbolizm said.

fleet burrow
#

I am cancelling the task, no?

naive goblet
#

No idea why you're using BukkitRunnable but if the ISE comes from #cancel(),

#

it's already been scheduled