#help-development

1 messages · Page 1539 of 1

hardy swan
#

to 1.16

wraith rapids
#

that isn't related to the api link or version

#

that pertains to the api-version field in your plugin.yml

#

which should be 1.16, not 1.16.1

soft dragon
#

im using]

#

1.16.5-R0.1-SNAPSHOT

#

huh

#

?

hardy swan
#

in plugin.yml* yes

#

api-version: 1.16

wraith rapids
#

1.16

#

it does not accept patch versions

soft dragon
#

thanks!

wraith rapids
#

only major.minor

soft dragon
#

... Thanks

#

if i didnt know that, i will spend 1 year from my life finding SOLUTION.

noble spire
#

I'm very confused, I've got a discord bot to work, and it runs fine just running it alone, but when I run it through spigot it gives me this error when I try to connect, anyone know if spigot blocks something or overrides it?

java.lang.NoSuchMethodError: 'boolean io.netty.handler.ssl.SslProvider.isAlpnSupported(io.netty.handler.ssl.SslProvider)'
soft dragon
#

DISCORD BOT

#

trough spigot lol?

noble spire
#

I just have a separate class which initialises my discord bot class

#

in the onEnable() method

mortal hare
#

i think i found vulnerability but not sure

wraith rapids
#

spigot or some other plugin on the server is probably shading in or including the classes that you depend on but with a different version

mortal hare
#

if notchian server uses counter to 100 for window ids

noble spire
#

yeah, does spigot use a different version of

mortal hare
#

to display items

#

on the client

#

and resets every 100th chest opened

#

wouldnt this broke if at the same time 101 players opened a chest

#

since 1 is occupied by the first player

#

101 player would see the 1st player's chest contents

#

am i right?

#

0 never happens

#

since 0 window id is for player's inventory

quiet ice
#

That would only happen if the notichan server has a windowId -> Object datatype

mortal hare
#

open window packet uses ints

quiet ice
#

Which, the server might not have and in this case it might just be some validation redundancy layer for either the client or player

mortal hare
#

and primitive integer as window id

#

but counter resets every 101th iteration

#

while packet getting sent

quiet ice
#

Yes, but it is not a lookup table

mortal hare
#

97,
98,
99,
100,
1,
2,
and so on.

#

according to the packets windowid doesn't not pass the 100 mark

quiet ice
#

the packet windowId is not really interesting for vulnerabilities in a standard environment unless that Id is reused for one purpose or another outside of the protocol

noble spire
#

is there a way to import it using an alias?

#

(in maven)

quiet ice
#

It could also be a remnant to an older system that is no longer used in the old form

mortal hare
#

so you're saying that windowid is really useless just like i was thinking

noble spire
#

or, in a java import to specify which version

quiet ice
#

it has to be

mortal hare
#

since there's only one window

#

that is rendered

quiet ice
#

No

mortal hare
#

i mean container

quiet ice
#

I would need to look up to be sure, otherwise I am talking bullshit

#

@noble spire I have no idea what your specific issue is, but perhaps you can remove all contender versions via excludes

mortal hare
#

first i thought window ids are used for linear array storage for container objects inside server, but it seems it isn't

wraith rapids
#

if there are only 100 possible values, then that is certainly not the case

mortal hare
#

i think this is just a legacy leftover.

wraith rapids
#

granted, there are some unsafe things like that, like entity ids only being 32 bits

#

but they are still feasibly safe

#

something like 100 just wouldn't fly

noble spire
wraith rapids
#

exclude the old version from the dependency that imports it

noble spire
#

how?

wraith rapids
#

i'm sure you can find a tutorial or a guide online

noble spire
#

okay, is it maven or java?

wraith rapids
#

i don't remember the jargon off the top of my head

quiet ice
#

Then you need something like


        <!-- World protection plugins to integrate with -->
        <dependency>
            <groupId>com.github.TownyAdvanced</groupId>
            <artifactId>Towny</artifactId>
            <version>0.97.0.4</version>
            <scope>provided</scope>
            <exclusions>
                <exclusion>
                    <!-- We don't want to harm our dependency tree with transistive dependencies-->
                    <groupId>*</groupId>
                    <artifactId>*</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
wraith rapids
#

maven

#

once again the TRANSitive dependencies are excluded from the project

#

just like in real life

quiet ice
#

I do not want to download RockDB everytime I build my project, okay

wraith rapids
#

an avid trans excluder, a discriminator

quaint mantle
quiet ice
#

I do not disciminate, I exclude everything equally!

#

Apache Text (which might have been merged into/split from Apache Commons - I suggest whatever is newer) offers something like that iirc

maiden heath
#

So I've been working on making a plugin for 1.17, and I've been copying most of the code from another plugin. I've got this line that no longer works in 1.17:

SECTIONPOSITIONCLASS = Class.forName("net.minecraft.server." + SERVER_VERSION + ".SectionPosition");

Any idea what I should replace it with?

mortal hare
# quaint mantle Is there any more efficient way of doing this https://paste.md-5.net/hifabineyi....

First thing that caught my eye is for each loop. Its a bit slower than simple for loop with primitive int since it uses Iterator in the backend, second since you check what string contains multiple times the same, you can cache the booleans instead of rechecking everytime like:

boolean emailStatus = message.contains("%emailStatus%");
boolean discordStatus = message.contains("%discordStatus%");

^ since those are essentially for loop functions which are iterative. And its for the better if you cache those for later use
also i don't seem to know why are you using arraylist for this particular situation, you can just use simple constant static array for this situation, since when static is used the object or the primitive is only initalised once.

private static const String[] contents = new String[] {
  " &f&m---------------] Auth [---------------",
  "",
  "   &cDiscord: &f%discordStatus% Message2",
  "   &cEmail: &f%emailStatus% Message2",
  "",
  " &f&m--------------------------------------"
}
#

also you can just do a repeating task every 5-10 minutes

#

to check the status

#

instead of checking it every time

quaint mantle
#

its a command

mortal hare
#

ik, but you can get the results via method which just return fields

#

but compute the result

#

in the task

quaint mantle
#

okay

#

ty

mortal hare
#

np

mortal hare
#

it changes everyttime when update of minecraft rolls out

maiden heath
#

I don't even know what that is lol

#

What should I do instead?

mortal hare
#

don't use this snippet of code

#

if you don't know what its doing

lucid jacinth
#

is there a method to get a Player object from their username as a String?

mortal hare
#

you mean serialized player object?

maiden heath
#

Only if they're online

mortal hare
#

or just Bukkit.getServer().getPlayer()

lucid jacinth
#

yup thatll prob work tysm

wraith rapids
#

Bukkit.getPlayer

#

static Bukkit methods defer to the server instance methods anyway

noble spire
earnest sonnet
#

I'm curious, but have you ever been in a situation that you had to force a thread to sleep ?

wraith rapids
#

bukkit is no longer publicly updated

#

hasn't been for a few versions

#

you don't import bukkit

#

you import spigot

#

which includes bukkit

noble spire
#

?paste

undone axleBOT
noble spire
#

(that's my pom.xml)

#

yet it still gives me the error

#

am I importing spigot correctly?

wraith rapids
#

looks fine

noble spire
#

hmm

#

very weird

#

java: package org.bukkit does not exist

wraith rapids
#

restart and clear caches and all that shit

mortal hare
#

wait

#

org.bukkit as a jar

#

shouldn't it be craftbukkit

#

oh nvm

#

that's just the API

#

without NMS

#

just like Spigot-API

quiet ice
#

org.bukkit.craftbukkit is nms

earnest sonnet
wraith rapids
#

you can't really force another thread to sleep

reef turret
#

Can some1 link paper disc?

quiet ice
#

no?

wraith rapids
#

thread pools consist of individual threads that choose to sleep whenever they don't have anything to execute

#

sleeping a thread externally is a thing you can do on some older versions of java but has been deprecated for like over a decade

tired nacelle
#

I'm still getting Caused by: java.lang.IllegalArgumentException: Plugin already initialized! when running a command. what i can do?

quiet ice
wraith rapids
#

don't instantiate your main class twice

mortal hare
quiet ice
wraith rapids
#

while loops with sleep or blocking instructions in them, yeah

#

point is the thread sleeps of its own accord

#

another thread isn't forcing it to sleep

tired nacelle
#

just to get the main class

quiet ice
#

no

#

theres so much wrong there

wraith rapids
#

yeah, no, don't do that

quiet ice
#

replace all instances of main with this

#

then remove the main = new Main()

wraith rapids
#

you can not call the constructor of your main class

#

ever

#

never

mortal hare
#

threads are like separate programs on OS but in more smaller package and better resource usage sometimes, it depends.

tired nacelle
#

so something like this?

quiet ice
#

correct

#

(You can also omit the this. for method and field calls)

vocal solstice
#

Hi, I'm having a problem with Spigot. Anyone can help me?

earnest sonnet
#

?ask

undone axleBOT
#

If you have a question, please just ask it. Don't look for staff or topic experts. Don't ask to ask or ask if people are awake or available. Just ask the question to the channel straight out, and wait patiently for a reply.

earnest sonnet
#

though not sure if that's the best place

quiet ice
earnest sonnet
#

look, you scared him

tired nacelle
#

also Caused by: java.lang.IllegalStateException: Initial initialization is caused by new Main(); call?

quaint mantle
#

yes

tired nacelle
#

ok.

quiet ice
tired nacelle
#

bruh this.multiplayer is null

quiet ice
#

did you ever initialise multiplayer?

tired nacelle
#

i just made the variable public Main multiplayer;

wraith rapids
#

learn java

burnt current
#

Hey quick question: does anyone happen to know how to set an Nbt tag on an itemstack in the versions from 1.16 onwards, and also query it later on? Thanks in advance

wraith rapids
#

use the pdc

eternal oxide
#

don't use NBT tags, use PDC

#

?pdc

earnest sonnet
burnt current
#

I got the recommendation to use NbtTags instead of querying the name of an inventory, so I was interested in this in general, but thanks for the tip.

quiet ice
#

Example:

[22:21:53 WARN]: java.lang.NullPointerException: Cannot invoke "net.milkbowl.vault.economy.Economy.getBalance(org.bukkit.OfflinePlayer)" because "this.econ" is null
[22:21:53 WARN]: at com.plotsquared.bukkit.util.BukkitEconHandler.getBalance(BukkitEconHandler.java:110)
[22:21:53 WARN]: at com.plotsquared.core.util.EconHandler.getMoney(EconHandler.java:58)
[22:21:53 WARN]: at com.plotsquared.bukkit.util.BukkitEconHandler.getMoney(BukkitEconHandler.java:71)
[22:21:53 WARN]: at com.plotsquared.core.command.Merge.onCommand(Merge.java:197)
[22:21:53 WARN]: at com.plotsquared.core.command.SubCommand.execute(SubCommand.java:57)

some people will think that vault has to be at fault here

hardy swan
#

ok so I went to test and print the packets out, ABORT_DESTROY_BLOCK packet is generated even when player punches the block. But BlockDamageEvent isn't always cancelled even when I used #setCancelled(boolean) on detecting ABORT_DESTROY_BLOCK packets.

earnest sonnet
#

uuuuuh, just go the the first line and check it out? and if I didn't guess wrong it's cause someone forgot to initialize the econ ?

#

oh wait, is that from the guy who had this problem earlier ?

hardy swan
earnest sonnet
eternal oxide
#

they did

#

They never set eco

quiet ice
#

I saw, but in this case it is a bit different

earnest sonnet
quiet ice
#

I assume it has something to do with bukkit having inconsistent load order, but we can only speculate

hardy swan
hollow river
#

hey quick question because i cant find much on google about it, how would i set a turtle egg "block?"'s amount of eggs?

dusk flicker
#

If I didn't know how to read stacktraces my life would be done

#

I get too many

hollow river
#

((TurtleEgg) location.getBlock().getBlockData()).setEggs(eggCount);
is what i've tried

sage swift
#

then you have to set the block data again

hollow river
wraith rapids
#

Block::setBlockData

hollow river
#

ohh okay so ill try getting the blockdata, setting the egg amount and then updating the blockdata

sage swift
#

mhm

hollow river
#

i can test it in a bit,
TurtleEgg egg = (TurtleEgg) location.getBlock().getBlockData();
egg.setEggs(eggCount);
location.getBlock().setBlockData(egg);
is what i have now and should probably work, thanks!

soft dragon
#

Can you help me with this: org.bukkit.plugin.InvalidPluginException: Unsupported API version 1.16.1... Im using 1.16.5 APIs and LIBs but its still saying that the API is for 1.16.1

eternal oxide
#

1.16

soft dragon
#

?

eternal oxide
#

api version 1.16

soft dragon
#

im using it

#

in config

#

plugin.yml

dusk flicker
#

Put it to 1.16

eternal night
#

api version does not contain subversion xD

#

is what elgar was saying

earnest sonnet
#

yeep

dusk flicker
#

Not 1.16.something

earnest sonnet
#

Also, I'm quite curious why pick 1.16.1 when you're using 1.16.5 ?

wraith rapids
#

i already explained this to you

#

1.16, not 1.16.1

#

the api-version does not accept patch versions

soft dragon
#

I KNOW

#

i type 1.16

sage swift
#

then you havent recompiled

dusk flicker
#

You know that's a better way of answering that NNY

soft dragon
hardy swan
vital ridge
#

If i create a maven project, config.yml goes into the resources folder right?

eternal night
#

Yes

earnest sonnet
#

yes, but It's a good practice to include it in your pov too

#

pom*

vital ridge
#

My plugin wont enable cuz config.yml cant be found

#

even though it is in my resources folder

eternal oxide
#

Then you are building using Artifacts and not maven

vital ridge
#
[22:30:18 ERROR]: Error occurred while enabling CubicXpChat v1.0-SNAPSHOT (Is it up to date?)
java.lang.IllegalArgumentException: The embedded resource 'config.yml' cannot be found in plugins\CubicXpChat-1.0-SNAPSHOT.jar
        at org.bukkit.plugin.java.JavaPlugin.saveResource(JavaPlugin.java:192) ~[patched_1.16.5.jar:git-Paper-638]
        at org.bukkit.plugin.java.JavaPlugin.saveDefaultConfig(JavaPlugin.java:179) ~[patched_1.16.5.jar:git-Paper-638]
        at com.nux.cubicxp.Config.<init>(Config.java:12) ~[?:?]
        at com.nux.cubicxp.CubicXpChat.onEnable(CubicXpChat.java:13) ~[?:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[patched_1.16.5.jar:git-Paper-638]
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:380) ~[patched_1.16.5.jar:git-Paper-638]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:483) ~[patched_1.16.5.jar:git-Paper-638]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugin(CraftServer.java:501) ~[patched_1.16.5.jar:git-Paper-638]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugins(CraftServer.java:415) ~[patched_1.16.5.jar:git-Paper-638]
        at net.minecraft.server.v1_16_R3.MinecraftServer.loadWorld(MinecraftServer.java:591) ~[patched_1.16.5.jar:git-Paper-638]
        at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:281) ~[patched_1.16.5.jar:git-Paper-638]
        at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:1065) ~[patched_1.16.5.jar:git-Paper-638]
        at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$a$0(MinecraftServer.java:289) ~[patched_1.16.5.jar:git-Paper-638]
        at java.lang.Thread.run(Thread.java:831) [?:?]
[22:30:18 INFO]: [CubicXpChat] Disabling CubicXpChat v1.0-SNAPSHOT
quiet ice
#

it needs to be in src/main/resources

vital ridge
#

it is there

eternal oxide
#

You need to use the window on the right thats labeled Maven, not the build artifacts on the left

vital ridge
#

Im clicking on the right window, selecitng lifecycles and doubleclicking package

soft dragon
#

Me so dumb

eternal oxide
#

now get your compiled jar from the target folder

soft dragon
#

I really use ARTIFACTS xd

#

and

#

how to compile it using maven

vital ridge
#

Iam getting it

#

still the same error

#

Im starting to doubt its smthing else

#

it could be my code

eternal night
#

Open your jar and look inside XD

eternal oxide
#

Then you are either not placing it in the correct folder to start, you are not using the correct jar that was compiled or not uploading it correctly to your server.

eternal night
#

Your favourite archive tool should work fine

eternal oxide
#

I'm betting you are getting the jar from teh wrong folder

vital ridge
earnest sonnet
#

Are you getting your jar from the target folder ?

vital ridge
#

yep

#
Building jar: C:\Users\Kasutaja\Desktop\projects\CubicXpChat\target\CubicXpChat-1.0-SNAPSHOT.jar
#

this is the folder its getting built in

earnest sonnet
#

try to use <includes> in your pom

eternal oxide
#

?paste your pom

undone axleBOT
vital ridge
eternal night
#

Did you validate the file is in your jar ?

earnest sonnet
#

run clean and package it again

vital ridge
#

What was the command for cleaning again?

earnest sonnet
#

and like someone said above, decompile your plugin to see what's inside

eternal oxide
#

don;t use commands

#

use lifecycles

eternal night
#

Huh ? What's wrong with mvn clean

vital ridge
#

I decompiled it

#

the maven and the pom

#

is inside

#

everything is inside

eternal oxide
#

depending on IDE may use a different maven

eternal night
#

The pom is inside ???

dusk flicker
#

I always run commands for maven

vital ridge
#

yea?

#

not inside where the classes and sht like that is

#

its in its own specific folder

eternal oxide
#

can you show us teh structure of yoru jar

vital ridge
#

Structure of my jar?

#

shit wait

#

i cant see

#

config.yml

eternal oxide
#

you never included config

lusty cipher
#

Does CraftBukkit not ship with bungeecord text API?

wraith rapids
#

no

grand coral
eternal oxide
#

do you get the yeahh message?

grand coral
#

No

eternal oxide
#

then debug and see how far into your code it is getting

vital ridge
# eternal oxide you never included config

included it, got my plugin working now, but theres another problem, i specified my host as 'localhost' in config, but error tells me:

Caused by: java.net.UnknownHostException: No such host is known (null)
lusty cipher
#

Can I (using the Bukkit/Spigot API) determine if the server is running CraftBukkit (and not Spigot etc.)?

vital ridge
#

Im creating MySQL database.

eternal oxide
undone axleBOT
vital ridge
eternal oxide
#

look at the path you are fetching

vital ridge
#

ahh fuck, i shouldve just wrote host right?

eternal oxide
#

mysql.host

vital ridge
#

Yeah

#

Ill fix it

#

1 sec

lusty cipher
#

or can I let my plugin be Spigot API only and let CraftBukkit disable it as it wouldn't work?

dusk flicker
#

Don't even worry about CB

#

If someone runs it they are dunb

#

Dumb*

lusty cipher
#

well I just had someone open an issue on gh and they were using CraftBukkit

wraith rapids
#

spigot is a minority

#

craftbukkit is a super über minority

#

literally nobody runs craftbukkit servers anymore

#

build against spigot and you're good for pretty much the entire bukkit ecosystem

lusty cipher
#

not exactly nobody

#

but yeah

wraith rapids
#

there's always one or two

#

but it's like less than a percent or something

#

practically nobody

#

people using paper and its derivatives might have some criticisms if you don't use paper or paperlib but for most plugins that shouldn't be very significant

indigo iron
#

So basically when someone interacts with any type of armor in their inventory it is suppose to put them on cool-down and when that cool-down is active they can not interact with the item. for example i equip a chest-plate it will put me on a 3 second cool-down meaning i cannot dis-equip the chest-plate until that 3 second cool-down is over. Here my code for it but doesn't work.
https://hastebin.com/sinoxawuyi.typescript

lusty cipher
#

I build everything against spigot-api but exclusively use paper and purpur on my servers

vital ridge
#

@eternal oxide this problem got fixed but now Im getting this error:

[22:54:22 WARN]: com.mysql.cj.jdbc.exceptions.CommunicationsException: The driver was unable to create a connection due to an inability to establish the client portion of a socket.
[22:54:22 WARN]:
[22:54:22 WARN]: This is usually caused by a limit on the number of sockets imposed by the operating system. This limit is usually configurable.

What could it be? Its pointig to my openConnection method which does this:

public void openConnection() throws SQLException {

        if (getConnection() != null && !getConnection().isClosed()) {
            return;
        }

        connection = DriverManager.getConnection("jdbc:mysql://" +
                this.host + ":" +
                this.port + "/" +
                this.database,
                this.username,
                this.password);
wraith rapids
#

if it's a private plugin, you may want to consider using paper or purpur api

#

as with them you can write generally more performant code and there are a lot of handy shortcuts that on base spigot can be a headache to pull

lusty cipher
#

yeah my private one goes against paper

mortal hare
#

or even better

#

Airplane or Purpur

wraith rapids
#

airplane afaik is nothing but placebo

mortal hare
#

I use purpur

lusty cipher
#

yatopia

wraith rapids
#

i looked through the server patches a while ago and I found nothing that wasn't a micro optimization

lusty cipher
#

and airplane uses that replacement for timings which they want money for, no?

wraith rapids
#

i don't remember if it's a full on replacement but yeah they have some sort of a live profiler tool that requires a patreon subscription

#

somewhat understandable I suppose but still kind of shady

digital plinth
#

whats the difference

#

potato

#

potatoES

#

plural?

dusty herald
#

Potatoes are Ageable

eternal oxide
vital ridge
#

No Im not closing it in my code

#

But the tutorial i followed said that its a bad thing to do

#

to close connection

wraith rapids
#

potatoes is the block

#

potato is the item

vital ridge
#

in onDisable

digital plinth
#

ohh okay

digital plinth
eternal oxide
wraith rapids
#

used to be potato and potato_item or something

vital ridge
#

Also:

Caused by: java.net.BindException: Cannot assign requested address: connect
eternal oxide
vital ridge
eternal oxide
#

Caused by: java.net.BindException: Cannot assign requested address: connect

#

connect?

vital ridge
#

I have no idea

#

what does this error mean

solemn relic
#

Hey

eternal oxide
#

what port should it be using?

vital ridge
#

3306

#

its the port in my XAMPP

solemn relic
#

How would i go about keeping sugarcane growing in unloaded chunks

#

?

#

Sorry if im interrupting

wraith rapids
#

you wouldn't

#

if the chunk is unloaded, the sugar cane does not exist

#

and if it doesn't exist, it cannot grow

solemn relic
#

Yeah ofcourse

#

But

#

I tried this

#

Gonna get the code 1 sec

wraith rapids
#

one thing you could do is scan the chunk on load for sugarcane, read a stored last-loaded timestamp and compare to current system time, and then simulate growth for each cane

#

that will however be quite expensive performance wise

eternal oxide
solemn relic
#

IntelliJ crashed 🤦‍♂️

#

Gotta restart it 1 sec

vital ridge
#

Oh shit yea think

#

1 sec

digital plinth
#

is it Material.AIR when the player is holding nothin

burnt current
#

Hey I have a problem. It's about persistent data. I just tried to store a string in a custom header and wrote the following code:

ItemStack item = customSkull("http://textures.minecraft.net/texture/851a72cf4962e5d00ef30294e5db8847ce67565154d7ad436099ff3e9dd29a1c");
                                ItemMeta itemMeta = item.getItemMeta();
                                PersistentDataContainer data = itemMeta.getPersistentDataContainer();
                                data.set(new NamespacedKey(Main.getPlugin(), "key"), PersistentDataType.STRING);

However, data.set(new NamespacedKey(Main.getPlugin(), "key"), PersistentDataType.STRING); is highlighted in red and gives the following error:

#

Can anyone help me with this by any chance? Thank you in advance

wraith rapids
#

it needs 3 parameters

#

set(key, type, value)

#

you have set(key, type)

#

since PersistentDataType.STRING is a PersistentDataType<String>, the value would in this case be a String

vital ridge
#

Nvm I dont, I deleted the other stuff

#

Im still getting the error

solemn relic
#
    @EventHandler
    public void onPlace(BlockPlaceEvent e) {

        if (e.getBlockPlaced().getType().equals(Material.SUGAR_CANE)) return;
        if (Core.getInstance().caneChunks.contains(e.getBlockPlaced().getChunk())) return;

        Core.getInstance().caneChunks.add(e.getBlockPlaced().getChunk());

    }

    @EventHandler
    public void onUnload(ChunkUnloadEvent e) {

        if (Core.getInstance().caneChunks.contains(e.getChunk())) {

            e.setCancelled(true);
            e.getChunk().load(true);

        }

    }
wraith rapids
#

yeah no you don't want to do it like that

#

that will cause the chunk to be repeatedly loaded and unloaded

#

and you can't cancel a chunk unload event anyhow, I don't think

#

add a plugin ticket to the chunk to force it to stay loaded

burnt current
solemn relic
wraith rapids
#

however be aware that that will keep the chunk loaded at the maximum load level; entity ticking and everything

#

it's somewhere under World

#

check the javadocs

gaunt hatch
#

Could this be a spigot issue?

In code i save the world, but when i stop the server and re-load the world the only block data saved was the chunk where the player was, any other chunk did not save even though there where changes.

solemn relic
#

Alright thanks

#

Does it exist in Spigot 1.8?

wraith rapids
#

probably not

#

data.set(new NamespacedKey(Main.getPlugin(), "key"), PersistentDataType.STRING, "my string");

eternal night
#

PDC was 1.14

wraith rapids
#

this is plugin tickets

eternal night
#

Oh

wraith rapids
#

pdc is for the other guy

eternal night
#

So many people

solemn relic
wraith rapids
#

thankfully my long experience as a faggot moderator has rendered me capable of partaking in 200 conversations at once

solemn relic
#

This is why i usually post my questions on the forums

wraith rapids
#

without the aid of modern doodads like replies or any of that shit

eternal night
#

Ah forums are trash, the real people are vibing here

vital ridge
earnest sonnet
vital ridge
#

and I do not have a password

wraith rapids
#

the forums are an eternal record of your incompetence

vital ridge
#

if i log in to the database

wraith rapids
#

here, your nooby failures will be forgotten in a day

#

unless you're exceptionally mentally deficient like a certain floofsy in which case it might take a week

earnest sonnet
#

In the arctic or whatever that place was

eternal oxide
vital ridge
#

the name is root

#

password should be empty

eternal oxide
#

your error says you used no user

vital ridge
#

Yep no errors now, successfully connected to the database, i forgot to define my username variable.

#

Thanks bro, rly appereciate it.

pseudo raptor
#

I'm making a ban plugin. It's not a coding error, it's a question. When the player tries to join the server, he is kicked (because he was banned), but the console shows a message. Is it possible to remove this message?

digital plinth
#

is the duration in ticks

#

or in seconds

pseudo raptor
#

ticks i believe

digital plinth
#

okay

digital plinth
#

should be able to remove it using a plugin

#

or configuring the paper/spigot/bukkit.yml i think?

pseudo raptor
#

aaah, ok

#

i gonna try

digital plinth
#

uhh

#

why is there no docs on turning byte to a string

#

theres only byte[] to string

#

can you not convert byte to string?

#

does it work if i convert it to char

#

i just want to print out the byte

#

wait i can use sout

young knoll
#

You should be able to use a byte directly concatenated with a string

eternal night
#

There is a string constructor that takes bytes

young knoll
#

Or you can do String.valueOf

digital plinth
digital plinth
eternal oxide
#

new String(bytes, StandardCharsets.UTF_8)

digital plinth
#

wait what

young knoll
#

Single byte

digital plinth
#

why is light level 0

young knoll
#

Not an array

digital plinth
#

im trying to check the light lvl

#

through a plugin

#

and its telling e its ZERO

eternal oxide
#

then why do you want to convert to a string? Its a value

digital plinth
#

broadcastmsg

eternal night
#

A single byte isn't even a string. Nor a char

wraith rapids
#

there is no way to convert a byte to a string because there is no sense in turning a byte to a string

eternal oxide
#

Its still a Number not a string

wraith rapids
#

a single byte isn't even enough to represent a single character in a string

eternal night
#

Single byte just sad

digital plinth
#

rip byte

young knoll
#

Yeah you can just concatenate it with a string

earnest sonnet
#

byte or bit ?

#

cause you're confusing me

young knoll
#

Byte

#

No one said bit

earnest sonnet
#

yea, IDK I read one of the bytes as bit 🤣 my bad

digital plinth
#

this is weird

#

the blocks have 0 lightlvl

#

and its day time

eternal oxide
#

why do you not just read the light level from teh block? If you are getting a byte it sounds like you are using nsm or protocol somehow

young knoll
#

No

#

That’s what it returns

#

byte light = player.getLocation().getBlock().getLightLevel();

digital plinth
#

.getLightlvl returns byte

eternal oxide
#

oh it does

wraith rapids
#

fairly silly if you ask me

digital plinth
wraith rapids
#

byte doesn't even represent the actual range anyway

#

so might as well use something sensible like an int

digital plinth
eternal oxide
#

In that case I bet you are testing actual blocks and not AIR blocks.

young knoll
#

They are if you look at the code

wraith rapids
#

solid blocks have a light level of 0

digital plinth
#

i need to get the air blcoks?

wraith rapids
#

because they are solid and don't let light go through

#

only blocks that light can travel through have a light level

digital plinth
#

the hwat about lightlvlfromSKy

wraith rapids
#

also the same

young knoll
#

Use getClickedFace(?) and then getOpposite to get the block next to it

digital plinth
#

hmm okay

wraith rapids
#

only blocks that light can go through can have a light level

wraith rapids
#

skylight or blocklight, doesn't matter

#

light is light

#

it light doesn't go through, it can't have a light level

digital plinth
#

so what if the blocks emit light

#

then the .getBlockLight should not be 0

wraith rapids
#

myes

digital plinth
#

lemme try it

wraith rapids
#

though I don't think there are any actually solid solid blocks in the game that emit light

digital plinth
#

glowstone

wraith rapids
#

not solid

digital plinth
#

redstone

wraith rapids
#

also not solid

digital plinth
#

really?

#

uhh

#

redstone lamp

wraith rapids
#

that might be one, i'm not sure

#

glowstone is weird, it's a full block but it's not solid in some sense

#

same with jack o lanterns

#

not sure about the new sea lanterns

digital plinth
wraith rapids
#

mmm i guess a lit furnace is properly solid

digital plinth
#

slabs

young knoll
#

Wiki says redstone lamps are partially transparent when lit

digital plinth
#

useful for redstone

wraith rapids
#

i guess at some point the lighting engine or something required light emitting blocks to act non-solid in some sense

#

probably not the case anymore

digital plinth
#

.getCLickedBlock.getface

#

probably?

compact haven
wraith rapids
#

a byte can represent up to 255

compact haven
#

oh wait

#

I thought that was a short, no?

wraith rapids
#

short is 6555 something

#

16 is like 4 bits

#

byte is 8

compact haven
#

I was wrong :)

turbid wind
#

I'm using PrepareAnvilEvent to get my custom enchantments to work in an anvil, but I can neither obtain the item in the result slot nor get unenchanted items to have enchantments applied to them

wraith rapids
#

i hate that byte is signed

young knoll
#

Everything in java is signed iirc

wraith rapids
#

everything except char

#

which is an unsigned short

#

who even uses bytes in signed applications

#

so gay

young knoll
#

Mojang does

wraith rapids
#

ah yes

#

the people I look up to the most when it comes to programming

#

mojang

#

the people who decided finding structures by brute force loading and searching each individual chunk one by one was a good approach

digital plinth
#

so i launched a projectile

#

and now can i change the texture

wraith rapids
#

good job

digital plinth
#

of that entity

digital plinth
wraith rapids
#

i don't think so, no

young knoll
#

I linked you the docs for it a while ago

digital plinth
digital plinth
#

okay lemme check

wraith rapids
#

i don't think the resourcepack supports that but I could be wrong

young knoll
#

You can just set it to any vanilla material

#

Don’t know what happens with CustomModelData

digital plinth
#

well i have the use the Snowball class

#

and not an ibject of it

#

object

#

but now how do i use the .setItem on it

young knoll
#

What does launchprojectile return

digital plinth
#

ohhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh

#

🤣

#

is it possible for plugins to like be able to launch a trident when a player right clicks air using like a sword or an axe

#

or a grass block

#

🤷

young knoll
#

Sure

digital plinth
#

like also allow the like

#

charging

#

drawing the trident

#

the longer you draw

wraith rapids
#

that'll be more difficult but not strictly impossible

digital plinth
#

the father it flies

#

farther*

digital plinth
#

hmm maybe changing the item into a trident at the last moment?

#

how do you do it

#

no nms pls

wraith rapids
#

the issue is in determining the length of charging

digital plinth
wraith rapids
#

the client doesn't send proper packets for when the RMB is pushed down or released

#

it just repeatedly sends right click packets

digital plinth
#

rip

wraith rapids
#

so you need to grab the interact events and try to guess whether the player is spam clicking or holding the button down

digital plinth
#

the packet is sent per tick

#

the player needs to press it PRECISLY

#

on every tick

#

which should be impossible

wraith rapids
#

it's sent like two or three times a second

digital plinth
#

oh then not per tick

wraith rapids
#

or something

digital plinth
#

per 6 tick

wraith rapids
#

i don't remember the exact interval and it's subject to latency and shit anyway

digital plinth
#

nms again sign

wraith rapids
#

nms won't help

#

the protocol is the issue here

digital plinth
#

is it possible for me to make trident with a special liek Lore

#

change their texture

wraith rapids
#

with the custom model id property yes you can assign a specific texture to a specific item with a resourcepack

digital plinth
#

changing the texture of a trident with the default pack

#

like i want normal vanilla tridnets to have the default texture

#

and change Some tridents not all of them

wraith rapids
#

yes, assign a non-zero custom model id and create a resourcepack that binds a specific texture to that specific model id

digital plinth
#

soo i can make a trident have the texture of a sword for example using a plugin

#

i need resource packs?

wraith rapids
#

yes

digital plinth
#

till launching tridents

#

texture didnt change

#

weird

#

oh the texture change works on snowballs

#

but not tridents?

#

even weirder

hexed hatch
#

Tridents don’t support custom models in projectile form because there’s no support for custom entity models

#

The only reason snowballs work is because all they do is render an item

young knoll
#

Yeah I don’t know why the setItem method is on ThrowableProjectile

ivory sleet
#

Did they registry-fy that also?

hexed hatch
#

Yes

ivory sleet
#

Oof

hexed hatch
#

For a while, trident models weren’t working at all

#

I think that was in like 1.15

ivory sleet
#

Oh I missed something then lol

hexed hatch
#

But the entity has never been modelable

ivory sleet
#

Fair

hexed hatch
#

I think they broke the trident model completely in either 1.14 or 1.15, I remember seeing a lot of people complaining in the BlockBench server about it. I think they fixed it now so you can remodel the item like normal.

daring sierra
#

wrong channel mb

minor garnet
#

Is possible detect when player is holding a left click button ?

#

I know exist the method playerinteractevent and i check if action == left click but how i detect the player is holfing a button

young knoll
#

You can't

#

Not easily

sage swift
#

inn cumang paket

torn jewel
#

Were persistent data containers on items removed in spigot 1.17?

sage swift
#

nope

#

meta

torn jewel
#

i have checked

#

it aint there

sage swift
#

are you using nms ItemStack

torn jewel
#

nope

#

nomal ItemMeta

sage swift
young knoll
#

It's 100% still there

sage swift
#

maybe you accidentally put 1.7

torn jewel
#

<dependency>
<groupId>org.spigotmc</groupId>
<artifactId>spigot-api</artifactId>
<version>1.17-R0.1-SNAPSHOT</version>
<scope>provided</scope>
</dependency>

#

this is what i put in

eternal oxide
#

pdc is fine. Show the code you are getting the error with

#

?paste

undone axleBOT
torn jewel
#

wait

#

i just relised that i am stupid and imported bukkit api in a regular non maven dependacy by accident

vital ridge
#

My hashmap data gets lost for some reason, when sending a command im putting uuid and boolean in a hashmap, after running the command i have a sysout in asyncplayerchatevent which prints the hashmap, but there it prints absolutely nothing.

#

Anybody has any idea what could be the case?

sage swift
#

?paste your code

undone axleBOT
eternal oxide
vital ridge
#

You mean the hashmap is not static?

#

I cant make it static

eternal oxide
#

no

#

post your code

sage swift
#

🤔 if you cant make it static then it's probably in the wrong place

vital ridge
#

I meant every player needs to have its own boolean]

#

i have a plugin which listens for ur input

#

and does something with that input

eternal oxide
#

you havn;t shown us the Map

vital ridge
#

oh yeah

#

1 sec

#
public HashMap<UUID, Boolean> inputListener = new HashMap<UUID, Boolean>();
eternal oxide
#

how is utils instanced?

digital plinth
#

just new HashMap<>()

#

no UUID, Boolean

sage swift
#

doesn't matter

vital ridge
#

i cant for some reason

#

tho

#

thats why i used as that

digital plinth
#

🤷

vital ridge
#

Oh Elgar

#

Every class creates its own utils instance

sage swift
#

there you go

vital ridge
#

yeah ill fix that

#

But

#

So i should create utils instance in main?

sage swift
#

one class has a different map than another

#

you could make the map static, or have a single utils instance in the main plugin class

#

which, i hope you have not called Main

vital ridge
#

Didnt

#

lmao

eternal oxide
#

either a single instance, or you make the map static so any instance uses the same map

sage swift
#

thats what i said!

vital ridge
#

Ill make the map static

sage swift
#

we are so in sync elgar

vital ridge
#

thats the only static method there

#

Actually

#

ill create one instance

#

actually ill change the map to static

eternal oxide
sage swift
#

ok mr towny man

#

lets do it

wraith rapids
#

the lizard and the palm tree

#

god knows what sort of hellspawn you'd procreate

sage swift
#

we are making our own optimized fork of 1.8 at this very moment!

eternal oxide
#

Time for a divorce

outer sorrel
young knoll
#

data.pastVictimBoxes.get(ticks + range)

#

ticks + range is outside the bounds of the list

vital ridge
#

Is there any easy methods to get color of a string?

sage swift
#

ChatColor.getLastColors

covert bluff
#

is there anwyay i can make it so that only a certain player can hear a sound i'll playy

#

or do i have to use nms or something with packets

quaint mantle
#

can you not just do player.playSound

covert bluff
#

no, it plays it at the location

#

i've tested it, other players can hear it

#

i want to make it so that only that client can hear it

quaint mantle
#

it just sends a packet to the handler of CraftPlayer

young knoll
#

Yes player.playsound is for them only iirc

quaint mantle
#

Code it runs makes 0 sense how it can be sent to multiple players

#

x,y,z would just be for volume adjusting across distance I assume

covert bluff
#

hmm

sage swift
#

?paste the code that's playing it for everyone

undone axleBOT
summer scroll
craggy crown
#

What do you recommend to learn how to create plugins?

eternal oxide
#

Do you know java?

jagged monolith
craggy crown
eternal oxide
jagged monolith
craggy crown
#

tanks you

quaint mantle
#

damn bro, how you gonna tank them?

craggy crown
#

it is bad? I did not know, I did not know it

quaint mantle
#

lmao

ivory sleet
#

He was just joking

quaint mantle
#

yeah ^

craggy crown
#

ah , okey

weary pagoda
#

we are world champions, come on Italy

digital plinth
#

😕

#

apparently my code is stopping the player from attacking mobs

#

i didn't setcancel any event

#

so y

gaunt hatch
#

Does anyone know where the code is for when the user does /save-all?

digital plinth
#

i did some experiments

compact haven
digital plinth
#

and i dont think the plugin code changed

#

but all of a sudden it stopped allowing me to attack

eternal oxide
#

you are either cancelling a damage or interact event or setting damage to zero

digital plinth
#

hmm

gaunt hatch
#

hmmm

digital plinth
#

what i did

#

is skipping out of the dmg event

#

like when a player dmg a entity

#

when they are at full health

#

i stops the code in the event from running

#

i used return for it hmm

eternal oxide
#

return will do nothing other than stop YOUR code running

digital plinth
digital plinth
#

still now i cant attack

eternal oxide
#

My previous statement still stands

digital plinth
eternal oxide
#

Those are the only things that will stop you attacking, other than spawn protection

digital plinth
#

spawn prot

#

might be that

eternal oxide
#

pretty sure you can still attack mobs in spawn protection though

digital plinth
#

yea

#

omg this is annoying

gaunt hatch
#

I sure wish the back end did go back to obfuscation ...

quaint mantle
#

does isSerializable exist?

digital plinth
#

like stackTrace the attack

#

i can break blocks and i can see the left click animation

#

but cant dmg mobs

jagged monolith
#

Listen to the EntityDamageEntityEvent and print debug messages

solemn relic
#

For some reason this stops working after a while... The event doesnt even seem to get called

    @EventHandler(priority = EventPriority.HIGHEST)
    public void onSpawn(ItemSpawnEvent e) {

        Item item = e.getEntity();

        Bukkit.getScheduler().runTaskAsynchronously(Core.getInstance(), () -> {
            for (Collector c : Core.getInstance().collectors) {

                if (e.getLocation().getChunk() == c.getChunk()) {

                    if (c.getFaction() == null) return;

                    if (!Core.getInstance().drops.contains(item.getItemStack().getType())) return;

                    c.depositDrop(item.getItemStack().getType(), item.getItemStack().getAmount());
                    item.remove();

                }
            }
        });

    }
digital plinth
#

throu the IDE?

jagged monolith
#

Just send messages to the console.

digital plinth
#

what?

#

that checks to see if theevent is called?

#

okie

#

wait hello?

#

i can attack entites again

jagged monolith
#
@EventHandler
public void entityDamageEntity(EntityDamageEntityEvent e) {
  Bukkit.getLogger().info("some random message");
}

That will print "some random message" to the console if the event is called.

digital plinth
#

okay now i can attack entites

#

but

#

for a while i could attack the iron golem in a village

#

what is this like

#

randomly stopping my attacks

#

nvm fixed

#

due to me under the affect of weakness

#

BRUH

#

btw is it possible to check if the mc day is a full moon

digital plinth
#

uhh why are my custom commands avaliable only to ops

#

i dont understand

#

the list is null

quaint mantle
digital plinth
#

can i make the commands avaliable for everyone

#

non-ops

digital plinth
digital plinth
quaint mantle
#

thats why its null

digital plinth
#

wait uhh

#

can a list have like a singke string

#

single

quaint mantle
#
key: [value]
key:
  - value
digital plinth
#

ik

#

the brackets are missing tho

#

i wrote it using code

#

and theres no bracket

quaint mantle
#

?

digital plinth
#

like i did .set() and theres no bracket in the yml

quaint mantle
#
FileConfiguration#set(String, Object)
#

if you put a string into the second parameter, what do you think it's gonna set it as?

#
FileConfiguration config;
String path;
String value;

// ... //

config.set(path, Collections.singletonList(value));
#

@digital plinth

digital plinth
#

the string so i changed it into a list :>

#

lol

quaint mantle
#

how do i listen for when a player gets money through vault

digital plinth
#

is that like a plugin on spigot's website

#

they should have an api for it

quaint mantle
#

there is

digital plinth
#

okay?

#

now you should be able to listen to it?

quaint mantle
#

nope

#

jfc

fickle geyser
#

what the heck is vault

sage swift
bitter oak
#

how do i set sleep ticks in 1.17

#

i see that theres getSleepTicks method but there is no setSleepTicks method

candid galleon
#

@quaint mantle doesn't look like it supports it, you probably have to check the implementer's project individually

dusk flicker
#

PR one

bitter oak
#

yeah i tried that and there doesnt seem to be any value called sleepTicks

candid galleon
#

try debugging out the fields then

bitter oak
#

what do you mean by that?

candid galleon
#

if you have the NMS classes shouldn't be too difficult to trial and error it too

bitter oak
#

ook

quaint mantle
#

the wait method is the best to use. It makes everyone one on the server wait

candid galleon
#

I think you mean Thread.sleep

quaint mantle
#

that too

#

hello i was wondering how to get the location of a block and if there was a method to delete a block

candid galleon
#

?jd

candid galleon
#

look at the Block javadoc

quaint mantle
#

And then to delete the block you can do block.setType(Material.AIR);

#

@quaint mantle

bitter oak
#

okay so now i figured out i wasn't using the remapped mojang classifier but when i tried it out this happens

bitter oak
quaint mantle
#
<repository>
   <id>spigot-repo</id>
   <url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
</repository>
bitter oak
quaint mantle
quaint mantle
bitter oak
#

yea i added it

#

do i like

#

rebuild the spigot?

#

i tried doing it a couple of times, cleared my local maven repository, still doesnt work

quaint mantle
quaint mantle
bitter oak
#

i'm trying to set sleep ticks but there doesnt seem to be a method

quasi flint
#

Thread.sleep

#

Works perfectly without any lag for all players

sage swift
#

sleep ticks for a player?

earnest sonnet
#

uhmm

sage swift
#

there is no method in HumanEntity it seems, no

#

but it might be that the sleep ticks are just calculated from the player statistic

smoky finch
#

Which event should I look into if I want to

  • Get the player who threw a splash/lingering potion
  • The effects of the potion itself
  • All the entities that were affected by this potion.
sage swift
#

ProjectileLaunchEvent

quaint mantle
#

PotionSplashEvent

sage swift
#

and that

quaint mantle
#

ProjectileLaunch is a bit redundant

sage swift
#

oh yeah projectiles have shooter nvm

#

silly me

quaint mantle
#

ya

#

silly gecko

bitter oak
smoky finch
#

Oh thanks, that has everything I need.

quaint mantle
#

it do

sage swift
quaint mantle
#

sucks to suck

smoky finch
quaint mantle
#

eh that can get a bit messy pretty quickly

sage swift
#

you could probably cancel the event in monitor priority 🙊 and apply the effects to the chosen entities manually

digital plinth
#

is there an event where player LEFT click an entity

#

apparently with weakness you cant deal dmg to entites with your fist

#

i want the player to be able to deal half a heart even with weakness

#

i suppose I can calculate the distance between the player head the and entity in question and .damage(1,player)

#

but is there an easier way?

#

since i'll have to calculate the hitboxes and stuff

#

EntityDamageByEntity event is not called

#

which is bad

summer scroll
sage swift
#

nope, that's only called for right click

quaint mantle
#

the map is mutable

sage swift
#

your mom is mutable

quaint mantle
#

..

smoky finch
#

It's a Map???

#

It says a collection

quaint mantle
#

ah it's backed by a map

#

lmao

#

nvm then

smoky finch
#

Well, damn I can't do anything if the map is not accessible directly, Not touching reflection

sage swift
quaint mantle
#

yuck

smoky finch
#

Idk why they made it private, it doesn't break anything at all.

#

Perfect opportunity for performance and writing less redundant code

sage swift
quaint mantle
#

just use /data lol

sage swift
quaint mantle
#

/data is literally a command to handle NBT

sage swift
#

in an impossible-to-read format

quaint mantle
#

??

sage swift
#

i also dont know how to use any subcommands other than get

quaint mantle
#

if only things were documented in an official wiki

#

such as minecraft fandom

sage swift
#

how official

quaint mantle
sage swift
#

i just like not having to scroll through a block of text

young knoll
#

Meh

sage swift
#

so, like, a key?

#

and no, that's the point.

#

why?

#

seems like xy

#

nope that's the point of it

#

as to not conflict between plugins

quaint mantle
#

"can i have a cheeseburger without the burger"

sage swift
#

but you can do NamespacedKey.fromString if you like to disobey authority

smoky finch
quaint mantle
#

well yeah

#

because a namespaced key has to have a namespace

sage swift
#

NamespacedKey.fromString("forge:rf")

quaint mantle
#

?

sage swift
#

mohist time!!

quaint mantle
#

no

#

get out

sage swift
#

wym mohist is awesome it lets me get the best of both worlds!!

twilit nexus
#

would someone be able to help me with using the getPing function

clear fable
#

can someone help me with packets? I'm trying to send an EntityMetadata packet to turn a player invisible but I keep running into problems. I tried protocol lib and it literally did nothing. no errors, but no output either. can someone show me an example of how to do it? I found this https://www.spigotmc.org/threads/simulating-potion-effect-glowing-with-protocollib.218828/#post-2246160 (which is for glowing but similar enough) but it didnt do anything when i tried it

#

does it matter if I am sending packets on the player join event?

#

should I delay them?

summer scroll
clear fable
#

ok

#

finallyyyy

#

it worked

#

oml

burnt current
#

Hey! I tried using persistantdata in items to build a gui. So you should not be able to move the items then. I have written the following code snippets for this:
https://hastebin.com/akajuqisog.csharp

First I created a variable at the beginning of the class in front of all methods that contains the string I want to store in the item later.
Then I created the ItemStack and gave it a meta directly. Among other things, this also contains the PersistantData.
Then I created a query to check whether the item contains a certain string. If so, the InventoryClickEvent should be cancelled and a new inventory should open. However, the event is not cancelled and the new inventory is not opened. Does anyone know what I could have done wrong in this case? Thanks in advance

quasi flint
#

registered event?

eternal night
#

"GUI?" while saving "GUI"

#

also PDC's #get method will return null if the key does not exist

quaint mantle
#

Hi, so I have two AsyncPlayerChatEvent, but they both occur at the same time when the RecoverEmailSetup method occurs this code user.getSettingUpEmail().setPhase(SetupPhase.VERIFICATION); the RecoverEmailVerify method runs right after it, but I don't want that. How do I fix that?
Code: https://paste.md-5.net/boqemizasa.cs
Video:

eternal night
#

so null check the value please

#

you can specify an approximate order of event handlers using event priority

quaint mantle
#

how do i do that?