#help-development

1 messages ยท Page 490 of 1

topaz atlas
#

the one at the top with the already existing resources

#

Now I just need to fix the errors for the maven dependencies

#

did you take a look at what I entered?

#

i sent you the link from where I copied it from

wet breach
#

Alright show us your pom

#

?paste

undone axleBOT
wet breach
#

Ok

topaz atlas
#

Right

#

so

wet breach
#

Take a look at that pom and you will see how it needs to be structured

#

And then it should be easy to know where to put the plugin block section at

#

So you need certain things in the pom. Should notice in mine at the top it has the modelversion

#

You always need that

#

Then it has a dependency section, and that is how you specify all your dependencies. And then it has a respository section. Any depedency that is not in maven central you need to specify the repo where maven can find it

#

And then there is the build tag section where all your plugin blocks go and basically dictates how maven should do some things

#

Hopefully its all making sense now lol

topaz atlas
#

will that work

wet breach
#

Plugin block sections have to be inside the build tag section

#

In my pom you should see i specify multiple plugins inside the build tag

topaz atlas
# wet breach Plugin block sections have to be inside the build tag section

Like this?


        <!--Spigot API-->
        <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.14.4-R0.1-SNAPSHOT</version>
            <exclusions>
                <exclusion>
                    <groupId>net.md-5</groupId>
                    <artifactId>bungeecord-chat</artifactId>
                </exclusion>
            </exclusions>
            <scope>provided</scope>
        </dependency>
#

thats a block right?

wet breach
#

Yep. Might want to fix that version tag at the end on the first dependency

#

Unless its just discord messing with it

topaz atlas
#

org.spigotmc:minecraft-server:1.18-R0.1-SNAPSHOT:txt:maps-mojang

#

1.18-R0.1-SNAPSHOT

#

in version

wet breach
#

So how you read that

topaz atlas
wet breach
#

Is like so. The group is org.spigotmc artifact minecraft-server version 1.18-R0.1-snapshot classifier maps-mojang

topaz atlas
#
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.18-R0.1-SNAPSHOT</version>
            <exclusions>
                <exclusion>
                    <groupId>net.md-5</groupId>
                    <artifactId>bungeecord-chat</artifactId>
                </exclusion>
            </exclusions>
            <scope>provided</scope>
  </dependency>
#

Is this correct?

wet breach
#

Yeah

#

Alright time for me to drive home now. Be back in like an hour uwu

topaz atlas
#

I just need to change all the group ids

#

and artifact ids

#

to match my project?

wet breach
#

No

topaz atlas
#
        <groupId>pw.hwk</groupId>
        <artifactId>servertutorial-parent</artifactId>
        <version>dev-SNAPSHOT</version>
        <relativePath>../pom.xml</relativePath>
    </parent>```
wet breach
#

Group ids and artifacts are specific to the dependency.

topaz atlas
#

Can I delete the parent project?

#

its causing a error

#

Last question

eternal oxide
#

multimodule?

topaz atlas
wet breach
#

Yeah delete the parent stuff you dont need it unless you want to make a multi module project

topaz atlas
wet breach
#

Which is probably a bit more advanced at the moment for you

eternal oxide
#

ignore it, you are starting with Maven you shoudl not be even looking at multimodule entries

#

?maven is all you need

undone axleBOT
eternal oxide
#

with a basic pom

topaz atlas
#

Edgar how do I fix my errors?

#

Should I send the whole thing

eternal oxide
#

why do you even have the deploy plugin?

topaz atlas
eternal oxide
#

ah

topaz atlas
#

and made slight adjusmtnets

wet breach
#

Yeah you werent suppose to copy it

topaz atlas
wet breach
#

Deploy plugin is how you can have maven move your jar to a remote location

#

Just fyi

topaz atlas
#

oh ok

eternal oxide
wet breach
#

That might be better to look at lol

eternal oxide
#

actually thats old to now

wet breach
#

Anyways going to drive home now

eternal oxide
#

still has source/target in properties

topaz atlas
topaz atlas
topaz atlas
eternal oxide
#

you can;t just copy the pom, you have to customize to fit your plugin

#

groupId, ArtifactId, version, description

topaz atlas
eternal oxide
#

?

#

You've posted nothign for me to look at

topaz atlas
eternal oxide
#

no you posted a screenshot with some random errors and said you'd changed some bits

topaz atlas
#

Ohh

#

I see the misunderstanding, anyways

#

I still get the errors

eternal oxide
#

?paste your pom

undone axleBOT
late sonnet
#

@/md5

eternal oxide
#

you have changed nothing

#

all you did is copy my pom

topaz atlas
#

Ok, ill make a new one

vocal cloud
#

The nice thing about the mc plugin for intellij is it saves the need to fix pom's. I hate reading pom files

topaz atlas
# eternal oxide ?paste your pom
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
 
  <groupId>me.spiderunderurbed</groupId>
  <artifactId>onutillities</artifactId>
  <version>1.0</version>
  
  <dependencies>
          <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.18-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
        
  </dependencies>
</project>```
#

My pom

topaz atlas
eternal oxide
#

right click your pom and select update project

topaz atlas
#

lmao

#

i just did that

topaz atlas
#

I didnt send a link

eternal oxide
#

no you need a repository as you don;t have buildtools

#

?maven

undone axleBOT
topaz atlas
topaz atlas
#

maybe it was included properly when I had a previous pom file, and carried over

#

idk

topaz atlas
#

to start working on my project

#

looking at the website

#

I assume i do

eternal oxide
#

no]

topaz atlas
# eternal oxide no]

I just need to know how do I set my Main.java file and ill be on my way, for a pom file, I been looking at this website and i still dunno how

quaint mantle
#

Hi. is there a way to create an NPC without using NMS? I'm using 1.19.4 API

young knoll
#

Citizens api

sullen marlin
young knoll
#

Otherwise, no

quaint mantle
young knoll
#

Then you need NMS

topaz atlas
#

I assume

sullen marlin
#

What are you trying to do

#

Are you making a plugin or a program

topaz atlas
#

mc plugin

orchid gazelle
#

Is it normal that armorstand teleports are laggy as hell?

sullen marlin
#

Just make a class and put the name in plugin.yml

#

Classes go in src/main/java and plugin.yml in src/main/resources

#

Any tutorial should cover this

topaz atlas
#

Im new to maven

#

Ok

#

Thanks

topaz atlas
#

last question to you

#

OH WAIT

quiet ice
#

Well every *.java file goes into src/main/java

topaz atlas
#

you awnsered it

#

thanks

topaz atlas
topaz atlas
quiet ice
#

Everything else (I.e. *.yml files) goes into src/main/resources

quiet ice
#

I am not sure whether you need to, but it is the best if you do

topaz atlas
quiet ice
#

Make sure nothing goes haywire

#

The exact meaning of packages is not that interesting to you at the moment

wet breach
wet breach
quiet ice
#

Just don't give packages generic names (such as "org.example.pluginname" or "pluginname" - instead use something like "com.gmail.username.pluginname")

wet breach
#

you can navigate to the project directory and take a look to see for yourself ๐Ÿ™‚

topaz atlas
#

Caused by: java.lang.IllegalArgumentException: Directory 'plugins/oNUtillities.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!

#
name: oNUtillities
version: 1.0
api-version: 1.17```
#

^ my yml

quaint mantle
#

why setPlayerListHeaderFooter() is deprecated?

wet breach
#

yes as I am home now ๐Ÿ™‚

topaz atlas
#

but i dont get this

wet breach
#

is the plugin.yml inside your jar?

topaz atlas
wet breach
#

you checked?

topaz atlas
#

the resources file should take whatever is in it to the root

topaz atlas
wet breach
#

so, open up the jar and see if the yml file is actually inside there. Odds are it probably isn't

topaz atlas
wet breach
#

just rename it to a zip extension

#

jars are just glorified archives

topaz atlas
#

Ok

topaz atlas
wet breach
#

what disappeared ?

topaz atlas
#

not the file

#

the yml file aint there

wet breach
#

well, now we know why the error is being thrown

#

and now know maven isn't doing what it should for some reason

#

lets see what your pom looks like now

topaz atlas
#
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
 
  <groupId>me.spiderunderurbed</groupId>
  <artifactId>onutillities</artifactId>
  <version>1.0</version>
  
  <dependencies>
          <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.18-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
        
  </dependencies>
</project>```
wet breach
#

that is it?

topaz atlas
#

yes

wet breach
#

you need a build tag

topaz atlas
wet breach
#
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
 
  <groupId>me.spiderunderurbed</groupId>
  <artifactId>onutillities</artifactId>
  <version>1.0</version>
  
  <dependencies>
          <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.18-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
        
  </dependencies>
    <build>
        
        <finalName>onutillities</finalName>
        <defaultGoal>package install</defaultGoal>
        <!-- BUILD PLUGINS -->

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.11.0</version>
                <configuration>
                    <source>17</source>
                    <target>17</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>com.google.code.maven-replacer-plugin</groupId>
                <artifactId>replacer</artifactId>
                <version>1.5.3</version>
                <executions>
                    <execution>
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>replace</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <file>target/classes/plugin.yml</file>
                    <replacements>
                        <replacement>
                            <token>maven-version-number</token>
                            <value>${project.version}</value>
                        </replacement>
                    </replacements>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>
wet breach
# topaz atlas Umm how do I go about making one

I added the replacer plugin, which is going to make it easier for you to update the version number in plugin.yml. so update the plugin.yml file and in the version spot, put maven-version-number

eternal oxide
#
    <build>
        <defaultGoal>clean package</defaultGoal>
        <sourceDirectory>src</sourceDirectory>
        <resources>
            <!-- Include all resources -->
            <resource>
                <directory>resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>*.yml</include>
                </includes>
            </resource>
        </resources>
    </build>```
remote swallow
#

couldnt you use resource filtering and remove the replacer plugin

wet breach
wet breach
#

the replacer plugin has always been reliable for me

eternal oxide
#

filtering does the job, you just have to not parse nbt/zip files

wet breach
#

by that statement seems still better to continue using replacer plugin and not have to worry about such technicalities

eternal oxide
#

I'd test replacer if I were you

#

I know filtering corrupts the BOM on compressed files

wet breach
#

replacer plugin doesn't filter

#

it looks for a token in files in a specified directory or in a specified file if just a single file is listed

topaz atlas
#

@eternal oxide @wet breach
Turns out, the yml file is kept in a folder called resources, not the root

#

so it isnt detecting

#

now that I added the build tag\

wet breach
#

and if it finds the token, it replaces it with the key you specify, in this case in the above I have it set to use the project.version of the pom

wet breach
topaz atlas
#

can you just send me or tell me what block i need

wet breach
#

have you tried compiling after updating the pom?

#

make sure you do a clean build

topaz atlas
#

you seen my pom

#

i just have the build tag and dependencies

wet breach
#

then add this inside the build tag

        <resources>
            <!-- Include all resources -->
            <resource>
                <directory>resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>*.yml</include>
                </includes>
            </resource>
        </resources>
#

eclipse is weird sometimes when it comes to maven

#

normally you don't have to specify this

#

but, its fine we can beat maven with a stick if need be

topaz atlas
#
        <defaultGoal>clean package</defaultGoal>
        <sourceDirectory>src</sourceDirectory>
        <resources>
            <!-- Include all resources -->
            <resource>
                <directory>resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>*.yml</include>
                </includes>
            </resource>
        </resources>
    </build>```
#

@wet breach I already had it

#

it still stays in the resources folder

wet breach
#

delete everything inside the target directory

#

and then build again

topaz atlas
wet breach
#

then, build the project. Make sure you are telling eclipse to build with maven

#

and not that the IDE should be trying to build it

topaz atlas
#

thats my steps

wet breach
#

yeah don't export

remote swallow
#

thats not building with maven

wet breach
#

that isn't using maven

topaz atlas
#

Umm, ima search how to build

wet breach
#

do you have a green arrow icon in your IDE?

#

like it looks like a play button

#

if you do, just click that

eternal oxide
#

Right click pom, run as -> Run Configurations. Then create a new task under maven build for your project

topaz atlas
# eternal oxide Right click pom, run as -> Run Configurations. Then create a new task under mave...
[ERROR] Source option 5 is no longer supported. Use 7 or later.
[ERROR] Target option 5 is no longer supported. Use 7 or later.
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException```
eternal oxide
#

why the heck are you set to 5?

#

?paste your pom

undone axleBOT
topaz atlas
eternal oxide
#

thats is not your pom

wet breach
#

o.O

remote swallow
#

did you remove the build block again?

wet breach
#

did you not save your pom?

#

after editing?

eternal oxide
#

are you trolling us?

wet breach
#

I think they didn't save the file XD

topaz atlas
#

Umm

#

one sec

eternal oxide
#

that is also NOT the pom which is giving that error

eternal oxide
#

still not the pom that gave that error

kind hatch
#

Wtf is that formatting?

eternal oxide
#

some spaces some tabs

#

best of both worlds ๐Ÿ™‚

topaz atlas
wet breach
#

well, the odd thing is. What happened to your pom that we spent some time helping you create?

topaz atlas
# wet breach well, the odd thing is. What happened to your pom that we spent some time helpin...

Wdym? this is it:

  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
 
  <groupId>me.spiderunderurbed</groupId>
  <artifactId>onutillities</artifactId>
  <version>1.0</version>
  
  <dependencies>
          <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.18-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
        
  </dependencies>
  
<build>
        <defaultGoal>clean package</defaultGoal>
        <sourceDirectory>src</sourceDirectory>
        <resources>
            <!-- Include all resources -->
            <resource>
                <directory>resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>*.yml</include>
                </includes>
            </resource>
        </resources>
    </build>
</project>```
wet breach
#

its missing the compiler plugin

topaz atlas
eternal oxide
#

doesn;t need it on Eclipse, but it doesn;t hurt

wet breach
eternal oxide
#

ah

topaz atlas
#

"use 7 or later"

#

I'll look through your pom for the compiler plugin

wet breach
#

I find it weird that eclipse defaults to java 5 though and not 6

rigid otter
#

Hello, how to work with MaterialData in v1.12.2?
For example if I want to set a block to Spruce Wood (Spruce Log), have I missed something with the code below?

Block block = world.getBlockAt(...);
block.setType(Material.LOG);
block.getState().setData(new Tree(TreeSpecies.REDWOOD));
eternal oxide
#

it wouldn;t

wet breach
#

of course it has to be different from all the rest

#

well, java 5 isn't maven default either

eternal oxide
#

it would default ot whatever java is installed

#

which is why I'm startign to belive he's trolling

remote swallow
#
<build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.11.0</version>
                <configuration>
                    <source>17</source>
                    <target>17</target>
                </configuration>
            </plugin>
        </plugins>
        <defaultGoal>clean package</defaultGoal>
        <sourceDirectory>src</sourceDirectory>
        <resources>
            <!-- Include all resources -->
            <resource>
                <directory>resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>*.yml</include>
                </includes>
            </resource>
        </resources>
    </build>
wet breach
#

that is an even more scarier explanation XD

eternal oxide
#

his error clearly stated target/source

topaz atlas
wet breach
#

move the plugins portion below resources

#

I am sure it probably doesn't make a difference, but convention wise it looks better

eternal oxide
#

?maven and you need the repository. So it won;t error on a new PC

undone axleBOT
topaz atlas
#

YES

#

so ima export it and look at it

eternal oxide
#

no, you no longer export

wet breach
#

it should be in your target directory now

eternal oxide
#

find it in the target folder

topaz atlas
#

I imagine i find it in created files

remote swallow
#

it should be in the target/ not target/maven-status

wet breach
#

do you not know how to open a file on a pc?

#

just go to the project folder

#

in there there is a directory called target and in there should be a jar

topaz atlas
#

Found it

wet breach
#

now if you open that jar up, it should all be correct now

#

that is the jar you should put in the plugins folder for mc

topaz atlas
#

lmao

eternal oxide
#
<directory>src/main/resources</directory>```
topaz atlas
#

I'll add that then rebuild

eternal oxide
#

replace the current one which says resources

remote swallow
#

add that in the resources part

wet breach
#

well, glad we have finally gotten to some progress

topaz atlas
eternal oxide
#

?paste your current pom

undone axleBOT
topaz atlas
eternal oxide
#

delete line 32

wet breach
#

love the odd formatting on the end portion

topaz atlas
#

no jar still

remote swallow
#

do you build with package or clean package

eternal oxide
#

errors?

#

if he set it correctly it should be clean package

topaz atlas
#

^the log

eternal oxide
#

Building jar: C:\Users\DuttR\eclipse-workspace\onutillities\target\onutillities-1.0.jar

#

but it says it copied 0 resources

topaz atlas
eternal oxide
#

is there a jar at that location?

topaz atlas
#

There is no jar at:

C:\Users\<Censored>\eclipse-workspace\onutillities'

eternal oxide
#

I didn;t say there

#

I told you EXACTLY where to look

#

C:\Users\DuttR\eclipse-workspace\onutillities\target\onutillities-1.0.jar

topaz atlas
#

Wait i reloaded

#

the jar just appeared

#

ima try the zip method

wet breach
#

makes sense since clean, deletes the target directory

eternal oxide
#

I guess he's only looking in his IDE

wet breach
#

and if you were viewing the directory when this happened, windows desyncs

topaz atlas
#

YES

#

it works, plugin.yml is in the root

eternal oxide
#

nah windows would be fine. If you are viewign a folder maven will not delete it, only its contents

topaz atlas
#

ima try it in the server

wet breach
#

on some other systems, windows will close out the view

eternal oxide
#

I am using win7 so my system is probably more stable than yours ๐Ÿ˜›

remote swallow
#

how do you run anything

eternal oxide
#

I've yet to find anythign which can't run

remote swallow
#

also why 7 not 8 or something

wet breach
#

well any games that need directx 12 wont run on windows 7

hushed spindle
#

windows 8 fuckin blows

eternal oxide
#

everything post 7 only gets worse

#

I don't have any DX12 games

hushed spindle
#

windows 8 was such a flop microsoft quickly ditched it after having released it

eternal oxide
#

they all support 11 anyways

wet breach
#

otherwise there wouldn't be windows 8.1

eternal oxide
#

If they stopped trying to make my PC look like a tablet/phone I'd consider upgrading.

wet breach
#

windows 10 isn't all that bad if you get the pro version

eternal oxide
#

great selling point, not too bad if you get pro ๐Ÿ™‚

wet breach
#

well I mean, xp was the same way

#

windows 7 is a bit worse on that end

#

because it has like 6 different versions

eternal oxide
#

yeah I used pro on xp

topaz atlas
#

Everything works

#

thanks guys

eternal oxide
#

Ultimate on win7

wet breach
#

I have windows 7 Ultimate

eternal oxide
#

best OS ever, other than DOS

wet breach
#

but it sounds like you use the best versions anyways, so it shouldn't be a surprise that windows 10 pro is the best to use

#

but I use windows 10 pro ๐Ÿ˜›

#

haven no need for my windows 7 no more

eternal oxide
#

if I could make it look like win7, behave like 7 and have no telemetry I'd consider using 10.

wet breach
#

you can completely disable telemetry in windows 10 pro

eternal oxide
#

mostly

wet breach
#

all of it

eternal oxide
#

they are inserting "ads" in the start menu now

#

although they are not calling them ads

wet breach
#

you can even do the same with windows 10 home if you make a single windows 10 pro system the domain controller ๐Ÿ™‚

wet breach
hushed spindle
#

i'm getting this error whenever a specific config is loaded, which i think shows that somewhere a material entry doesn't exist right? how would i go about finding that

eternal oxide
#

looks like you have a Static ItemStack

hushed spindle
#

i don't no

eternal oxide
#

can't do that are init time

wet breach
#

well the cut the end of the error off

#

so I can't determine

hushed spindle
#

its not as helpful as you might imagine

eternal oxide
#

you'd be suprised

#

Do you have an API version in yoru plugin.yml?

hushed spindle
#

it just happens when i call .get() on a Config

eternal oxide
#

it's trying to deserialize an ItemStack

hushed spindle
#

yeah i do

wet breach
eternal oxide
#

what version?

hushed spindle
#

1.14

eternal oxide
#

then you can only use 1.14 Materials

hushed spindle
#

oh is that how that works

#

so you should really be using the latest api version there then

eternal oxide
#

its an up to.

#

for Materials

hushed spindle
#

sad

#

thank you though

eternal oxide
#

will run on systems as far back as...

fluid river
#

ayo free java lessons check

#

pi pi pu pu

eternal oxide
#

You should have been here an hour ago NukerFall

wet breach
#

well, it makes sense that there would be free java lessons in places given java is free

fluid river
wet breach
#

would have gotten a maven lesson

hushed spindle
#

that explains why an item editor plugin i made doesnt work with newer materials lmao

#

goofy ahh

eternal oxide
#

We could have dumped a headache on you.

rapid dome
#

how works Holographic Displays

#

?

wet breach
#

well didn't help the person kept deleting their pom or not saving it

eternal oxide
rapid dome
#

like, it create an armor stand?

wet breach
#

yes

rapid dome
rapid dome
hushed spindle
#

so if i use api version 1.19 if i go on lower versions it nags about that, if i use a lower api version i cant use the materials, and without api version it nags about a lack of legacy constants

#

so tf do you do

eternal oxide
#

if you have api version 1.14 but the server is a 1.16 you shoudl have access to 1.16 materials.

#

you just can't load items created on 1.16 into a 1.14 server

#

so if you are supporting 1.14 servers you are limited to 1.14 materials

hushed spindle
#

right that makes sense, im not doing that though

eternal oxide
#

the error seems to disagree

#

?paste teh config section you are reading

undone axleBOT
hushed spindle
#

uhh, sec

#

i should clarify though even though it said 1.14 im supporting 1.16.5+ only, i just hadnt changed that api version in a while

wet breach
hushed spindle
#

if i understand it right though if i were to use something like mangrove logs in one of these configs and i test on 1.16.5, it'll throw that error

#

it'll consider the material null basically

eternal oxide
#

every itemstack looks to be QUARTZ

hushed spindle
#

i think im understanding why people choose to serialize itemstacks in their own way, so this doesnt happen

wet breach
#

in all the places where you have the block set to deepslate variants, this will only work for 1.17+ as that does not exist in 1.16

hushed spindle
#

i understand and in my code i made it so that if the material is unrecognized the entry is skipped

#

i thought that would be plenty

#

i didnt think calling the config itself would throw errors if itemstacks with such materials were used

wet breach
#

well its serialized

#

deserializing requires the reading of everything to get it back to what it was

#

can't nitpick serialized stuff, otherwise it really isn't serialized then

hushed spindle
#

thats fair

eternal oxide
#

when the config is loaded all deserialization happens

#

so first touch on the config causes deserialization

hushed spindle
#

would be nice if it specified which materials are considered unrecognized then

#

would make it quicker to patch

wet breach
#

this is generally why people use multi-modules

#

or just version specific jars

#

but, I think what you should add to your config

#

is the mc version it was created in

#

this way, you could just use that to know what needs to be looked out for. And yes, the reason for custom serialization is because the serialization you are looking it, is human readable serialization

#

and not really a true serializing where it would indeed be compact

hushed spindle
#

i use guis to populate the configs so i didnt consider human readability as high of a priority

wet breach
#

then, use a better serialization method

hushed spindle
#

yeah i gotta make one lol

wet breach
#

well there is plenty that exist already

#

and I was stating the serialization method you are using is human readable format

#

not the other way around, so if you don't need human readability, switch to a different serialization format that is more ideal ๐Ÿ˜›

#

it may just solve your problem too

hushed spindle
#

the plugin is already being used by 200ish servers so far so its a little difficult for me to simply use different serialization, though i could do the lazy thing and just ditch 1.16 support

#

in any case, i got work cut out for me ๐Ÿ˜”

wet breach
hushed spindle
#

its not ive done it before

#

i just got hit by a wave of bugreports lol

wet breach
#

in your new format just add an identifier. Instead of using yaml api to load the config initially just use the java file api to parse the file to read the lines at the top. If you don't see your identifier you know its the old format

quaint mantle
#

99% of my commands return the usage any idea why?

#

i have 1 command that woeks

#

works

#

and the others dont

#

even tho i made sure they look the same in every way

young knoll
#

Return true for no usage

quaint mantle
#

oh yh i forgot about that

#

help me

paper lichen
#

Whatโ€™s your problem?

quaint mantle
#

not working

#

scoreboard

#

on join

#

scoreboard not working

#

why does this work.

rotund ravine
#

?notworking

undone axleBOT
#

"Does not working" is a useless statement. Please describe what exactly is not working, what you expect it to do, and what actually happens. If you get any console errors, also ?paste the entire stacktrace.

quaint mantle
#

bbut this doesnt

#

isnt it exactly the same

quaint mantle
#

its two different versions but it should work on 1.8.8 too

#

1.16.5

rotund ravine
quaint mantle
#

on player join scoreboard must be on

#

should be turned on

#

but they isn't

rotund ravine
#

@quaint mantle Did you register the event?

quaint mantle
#

yes

rotund ravine
#

Show

quaint mantle
#

getServer().getPluginManager().registerEvents(new onJoin(), this);

rotund ravine
#

Do e.getPlayer

#

Donโ€™t cast the event to player

quaint mantle
#

?

rotund ravine
#

Yes

#

Exactly what i said.

quaint mantle
#

event.getPlayer.setScoreboard?

paper lichen
#

At Player p = (Player) e.getPlayer()

rotund ravine
#

Nope, the above^

quaint mantle
rotund ravine
#

Your stacktrace should have told you.

quaint mantle
#

it works

#

thanks

quaint mantle
rotund ravine
quaint mantle
#

yh but what is wrong now

remote swallow
#

@worldly ingot i have a new pr for you, annote everything in bukkit and spigot with an @Since

rotund ravine
quaint mantle
#

no

rotund ravine
#

You did

remote swallow
young knoll
#

That would imply that spigot supports older versions

remote swallow
#

the api does

young knoll
#

No it doesn't

remote swallow
#

how else am igonna know that XYZ method was added way back in 1.14

rotund ravine
quaint mantle
#

yes

#

its 2 different plugins but config util looks exactly the same

#

same folder too

#

package*

cinder abyss
#

Hello, is this correct ?java Bukkit.getScheduler().runTaskAsynchronously(this, (Runnable) new BukkitRunnable() { @Override public void run() { GenOre(event, -60, 20, Instrument.BANJO, 0, Note.Tone.G); } });

#

I don't know how to make a BukkitRunnable running asynchronously

wise pumice
#

How i can check if player is on ground? I know method player#isOnGround but is deprecated. There's other way to check this?

#

I'm creating a double jump plugin and I want when the player is on the ground to reset their jump series

paper lichen
#

idk why not

wise pumice
#

Okay, thank u.

tender shard
paper lichen
tender shard
#

I am not casting anything to player. I just said that casting something that already is player, to player again, makes no sense

eternal oxide
#

It looks like an apple, smells like an apple and tastes like an apple, but we better DNA test it to be sure.

paper lichen
wet breach
tender shard
paper lichen
river oracle
#

What're you doing

tender shard
#

First, both e and p are bad variable names
Second, you can save the player as field/var even without casting it
Third, a player will never be a string

river oracle
wet breach
#

so, that being said there is no reason to cast getPlayer to Player and you should remove it to keep with conventions. the compiler automatically removes it since it is the same type

paper lichen
river oracle
#

Bro can't be real

eternal oxide
#

I got a new dog today but the wifes not happy (Dog) event.getSheep();

river oracle
#

Lmao

wet breach
river oracle
#

Genius

wet breach
#

got to be safe

tender shard
tender shard
#

how? string is a final class

river oracle
#

public class String extends String implements Player

tender shard
#

you cannot extend string

river oracle
#

Starting in Java 21 String will implement player class

#

Stay mad losers

tender shard
#

why would that not work?

#

if you want "player" to be Player@a825162... then sure, that will work

#

the use cases are limited, at best, though lol

quaint mantle
#

I thought it call getName()

wet breach
#

toString() turns an object into string representation. Doesn't mean it will automatically convert the data the object was holding into a string or display it

#

anything that is an extension of Object has toString()

tender shard
#

he meant that you missed the ()

wet breach
#

oh right

#

guess I should go back and fix that

eternal oxide
#

can't have code that doesn't compile

tender shard
#

unless you're using eclipse compiler lol

wet breach
#

well not like discord is a decent IDE

eternal oxide
#

lol

quaint mantle
#

source code cannot be executed.

wet breach
#

nah we just imagine the code we create running to know if it works or not

wet breach
frail gale
#

CTRL + ALT + E my IntelliJ Build shortcut

tender shard
#

probably just cast it to long, then hope for the best

eternal oxide
#

mines F4

frail gale
#

in case you're in Windows

quaint mantle
river oracle
#

You're not an interpreted language

tender shard
#

then oracle would sue you

wet breach
#

split at the @ and you have the hashcode in hexadecimal format

wet breach
#

Java 11+ allows you to execute java source code without compiling

#

it doesn't depend. Java requires a JVM for it to execute

#

therefore it is an interpreted language

quaint mantle
#

Bruh

wet breach
#

anyways

tender shard
#

this is what oracle claims about java:

#

the JLS sounds like a lawyer wrote it

The null type has one value, the null reference, represented by the null literal null. A null literal is always of the null type (ยง4.1).

wet breach
#

for those that want to read the JLS

#

you may find some interesting things in there

#

like learning what word tearing is

river oracle
#

Are those requirements for a jdk

wet breach
#

yes

#

JLS = Java language Specification

river oracle
#

I forget sometimes a language is separate from a jdk

tender shard
#
class Test {
    class A {
        A(Test Test.this) {}
          // OK: the receiver parameter represents the instance
          // of Test which immediately encloses the instance
          // of A being constructed.

        void m(A this) {}
          // OK: the receiver parameter represents the instance 
          // of A for which A.m() is invoked.

        class B {
            B(Test.A A.this) {}
              // OK: the receiver parameter represents the instance 
              // of A which immediately encloses the instance of B 
              // being constructed.

            void m(Test.A.B this) {}
              // OK: the receiver parameter represents the instance 
              // of B for which B.m() is invoked.
        }
    }
}

fancy

tawny remnant
tender shard
#

there is no list at "backpacks." + key

#

also you should use getList instead of get

wise pumice
#

I want to spawn particle.
When i try to spawn REDSTONE particle works fine, but when i try to spawn NOTE particle error:

data should be class java.lang.Void got class org.bukkit.Particle$DustOptions

I spawn particles using:

            player.spawnParticle(
                    particle.getType(),
                    player.getLocation(),
                    count, offsetX, offsetY, offsetZ, extra,
                    new Particle.DustOptions(getColorFromName(particle.getColor()), particle.getSize())
            );

How i can check if particle needs DustOptions?

cinder abyss
wise pumice
tender shard
#

either check the javadocs, i added all the data types there once, or check whether Particle.YOUR_PARTICLE_TYPE.getDataClass() returns sth

cinder abyss
tender shard
#

if it doesn't mention anything here, that particle just doesn't have any additional data

cinder abyss
#

Hello, with what can I replace this who is deprecated ?java ChunkData chunk = createChunkData(world);

tender shard
#

where is that method supposed to come from?

cinder abyss
tender shard
#

you are not supposed to create your own ChunkData object, but instead just use the one passed into as parameter

#

e.g. generateCaves(...) has ChunkData as last parameter, and all other methods where you'd need it, have it too

wise pumice
tender shard
#

then check if it returns Void

#

if getDataType() == Void.class, there is no additional data

wise pumice
#

Thank u.

grizzled oasis
#

Question regarding PlotSquared if someone have ever used their api how can i pass the Location Bukkit to the PlotSquared Location format

quiet ice
tender shard
static ingot
#

so why do a bunch of classes in Spigot have #spigot() methods and interfaces? i guess once upon a time it was a hard separation of Bukkit and Spigot API, but why don't they just include the methods directly nowadays? deprecate the old interface methods in favor of ones that actually belong to the relevant classes?

tender shard
#

yeah it's pretty pointless imho

static ingot
#

i mean it seems like a strange practice in any case, yeah, lol

quiet ice
#

It probably is like that because it always used to be like that

static ingot
#

a lot of things are still like they are because that's just how it was made, lol. like we never made a big conversion from legacy text to components

quiet ice
#

though it's in progress apparently

static ingot
#

pog

quiet ice
#

Choco has a PR to add it everywhere where it is missing IIRC

#

But sadly I fear that it will end in the same part of the dumping bin as the Material API rewrite

livid dove
#

You will find 90% of the issues and dumb stuff Is still there as noonee cba to fix em

#

Player and offline player are an infuriating example of it imo

#

Player: works for online players...

Offline player: Works for both

#

God forbid we change the names to OnlinePlayer and Player ๐Ÿ˜…

grizzled oasis
#

cannot access com.plotsquared.core.location.Location someone knows why im using mvn install

quiet ice
#

Well doing that would cause ultimate chaos

onyx fjord
#

what is the BlockData for all crops?

quiet ice
fluid finch
#

I need to stop the player from putting certain items into the offhand slot, but If I just cancel the event it lets the player put the items into the slot, but not take em out

quiet ice
#

Then you cancel the wrong items

#

*event

fluid finch
#

i have this under an inventoryclickevent

if (e.getSlot()==40)
                        {
                            e.setCancelled(true);
                        }
#

fuc

opal juniper
quiet ice
#

I am pretty sure that PR is "done" by now

fluid finch
quiet ice
#

?jd-s there are plenty of inventory events

undone axleBOT
quiet ice
#

I'd also cancel the InventoryDragEvent

fluid finch
#

there's only one of each item tho?

quiet ice
#

minecraft can be funky sometimes

fluid finch
#

also I have gone thorugh them and I'm fairly certain inventoryclick is the correct one

quiet ice
#

Yeah ordinarily it is but apparently not

#

Unless you have something that is causing your lines to be irrelevant

fluid finch
#

it ain't the others tho

#

doeds it maybe get the item on the cursor maybe?

#

as it's not technically placed in the slot?

quiet ice
#

Hence inventoryDragEvent is the only plausible one

fluid finch
#

imma check

quiet ice
#

You'd need it regardless anyways just in case they drag it into the offhand slot

fluid finch
#

I'm fairly certain it's impossible

#

I'm gonna do some checking later but I don't think it'll be an issue

quiet ice
#

I'm sure you can drag it into "normal" slots and then into the offhand slot

fluid finch
#

oncursor was correct

kind hatch
#

The InventoryClickEvent can be tricked into thinking it's actually the InventoryDragEvent if someone is rapidly clicking in the GUI.

fluid finch
#

looks like you were correct

young knoll
#

A lot of PRs are "done" but I assume MD does a lot of testing with them to look for edge cases

#

Plus yknow, he does have an actual job to do

wise mesa
#

Literally impossible

static ingot
#

Do attribute modifiers need unique names? kinda annoying if so

wise mesa
#

Just use a random uuid

crude cobalt
#

Hello everybody! Is it possible to intercept the packet of changing the player's health interface to the health of an entity (for example, when the player prays to a horse) and cancel it, so that the player has his health interface?

cinder abyss
crude cobalt
#

Thanks, Iโ€™ll try

gilded bloom
#

Hello, I have a problem with sending the ENTITY_METADATA packet. I would like to send this packet to set the swimming animation for a particular player so that it looks like crawling. I have seen that this can be achieved by sending such a packet, but unfortunately I don't know how to send it correctly. Currently, nothing is happening. I would be so gratefull if someone could help.

THERE IS NO ERROR IN THE CONSOLE BTW
CODE:

ProtocolManager manager = ProtocolLibrary.getProtocolManager();
PacketContainer packet = manager.createPacket(PacketType.Play.Server.ENTITY_METADATA);
packet.getModifier().writeDefaults();
List<WrappedWatchableObject> wwo_list = new ArrayList<>();
wwo_list.add(new WrappedWatchableObject(1, 0x10));
packet.getIntegers().write(0, (int) p.getEntityId());
packet.getWatchableCollectionModifier().write(0, wwo_list);
for(Player target : Bukkit.getOnlinePlayers())
{
    manager.sendServerPacket(target, packet);
}
quiet ice
#

you may need to transform any future packets too

gilded bloom
#

wdym?

quiet ice
# gilded bloom wdym?

basically any future entity metadata packets could change the metadata and revert your changes

tribal quarry
vivid skiff
#

Where can i find a good ArmorWearEvent?

lunar forge
#
java.lang.RuntimeException: File 'plugins/WaterTranslator-1.0.0.jar' failed to load!
        at io.papermc.paper.plugin.provider.source.FileProviderSource.registerProviders(FileProviderSource.java:59) ~[paper-1.19.4.jar:git-Paper-507]
        at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.lambda$registerProviders$2(DirectoryProviderSource.java:32) ~[paper-1.19.4.jar:git-Paper-507]
        at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183) ~[?:?]
        at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:179) ~[?:?]
        at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197) ~[?:?]
        at java.util.Iterator.forEachRemaining(Iterator.java:133) ~[?:?]
        at java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1845) ~[?:?]
        at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) ~[?:?]
        at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499) ~[?:?]
        at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150) ~[?:?]
        at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173) ~[?:?]
        at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[?:?]
        at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596) ~[?:?]
        at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.registerProviders(DirectoryProviderSource.java:30) ~[paper-1.19.4.jar:git-Paper-507]```

What is this?
lunar forge
#

ohh

#
java.lang.SecurityException: Invalid signature file digest for Manifest main attributes
        at sun.security.util.SignatureFileVerifier.processImpl(SignatureFileVerifier.java:340) ~[?:?]
        at sun.security.util.SignatureFileVerifier.process(SignatureFileVerifier.java:282) ~[?:?]
        at java.util.jar.JarVerifier.processEntry(JarVerifier.java:327) ~[?:?]
        at java.util.jar.JarVerifier.update(JarVerifier.java:239) ~[?:?]
        at java.util.jar.JarFile.initializeVerifier(JarFile.java:762) ~[?:?]
        at java.util.jar.JarFile.getInputStream(JarFile.java:845) ~[?:?]
        at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:173) ~[spigot-api-1.19.4-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:144) ~[spigot-api-1.19.4-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.v1_19_R3.CraftServer.loadPlugins(CraftServer.java:423) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f]
        at net.minecraft.server.dedicated.DedicatedServer.e(DedicatedServer.java:219) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f]
        at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:975) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f]
        at net.minecraft.server.MinecraftServer.lambda$0(MinecraftServer.java:304) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]
[21:35:53] [Server thread/ERROR]: This crash report has been saved to: /home/container/./crash-reports/crash-2023-04-27_21.35.53-server.txt``` when using spigot
#

If I don't have WaterTranslator installed, I don't get this error

#

a plugin

#

Player#hidePlayer

cinder abyss
#

Hello, I don't know why my custom populator is not working, I'm using Spigot 1.19.4 :
https://pastecord.com/pyqetuxari

I register it using this :

@EventHandler
    public void onWorldLoad(WorldInitEvent event) {
        getLogger().info("Gen");
        event.getWorld().getPopulators().add(new CustomOreGen(this, -60, 20));
    }```

I get this in my console :```bat
Preparing level "world"
[SimplesOres] Gen```And nothing after

**PLEASE HELP MEEE ๐Ÿฅบ **
quiet ice
#

You need to also generate new chunks with it

cinder abyss
quiet ice
#

unless with "not working" you mean the game crashes

#

or rather said freezes

quiet ice
#

Use jstack

cinder abyss
#

After a long time, the game doesn't respond (and the server crash)

cinder abyss
quiet ice
#

Oh right - does watchdog crash the server?

#

In that case you don't need to use jstack since watchdog already gives you the stacktraces

cinder abyss
quiet ice
#

but you don't get any crash report after waiting a minute or so?

cinder abyss
#

but else I haven't got any error or crash

#

there is just... nothing

quiet ice
#

Then we need jstack. You can execute jstack with the pid of the minecraft server. You can find the pid via jps

#

The jps and jstack binaries are found next to the java binary within your JDK install

cinder abyss
#

6972

#

and what do I need to do ?

quiet ice
#

Run jstack 6972 (on unix - under windows it might be different; it may also be the case that you need to use the full path to the jstack binary)

cinder abyss
#

okay

quiet ice
#

Running 2 - 3 times will get a good idea where it starts hanging

cinder abyss
quiet ice
#

Okay the server thread is parked - no good

cinder abyss
quiet ice
#

Ah yep I see now

cinder abyss
cinder abyss
quiet ice
#

You are causing a deadlock by obtaining a chunk that isn't loaded yet

cinder abyss
quiet ice
#

Don't use chunk.getBlock(x, y, z)

cinder abyss
quiet ice
#

Ah no - the Chunk chunk = world.getChunkAt(chunkX, chunkZ); is the critical piece of code. But the same result

#

If I had to guess you need to use LimitedRegion but let me look

young knoll
#

Use the LimitedRegion it gives you

cinder abyss
quiet ice
#

no this is patrick

young knoll
#

Check the javadocs

cinder abyss
quiet ice
cinder abyss
quiet ice
#

Both implement RegionAccessor

#

You just can't get chunks

icy beacon
#

does this server finally support fancy formatting

The official video for โ€œNever Gonna Give You Upโ€ by Rick Astley

โ€˜Hold Me In Your Armsโ€™ โ€“ deluxe blue vinyl, 2CD and digital deluxe out 12th May 2023 Pre-order here โ€“ https://rick-astley.lnk.to/HMIYA2023ID

โ€œNever Gonna Give You Upโ€ was a global smash on its release in July 1987, topping the charts in 25 countries including Rickโ€™s native UK and...

โ–ถ Play video
#

fuck me in the wide hole

cinder abyss
quiet ice
#

.-.

cinder abyss
#

oh so funny

young knoll
#

fix your logic

cinder abyss
#

๐Ÿคฃ I'm a kid

young knoll
#

if action != right click air && action != right click block return

icy beacon
#

I wish discord didn't add embeds automatically

cinder abyss
cinder abyss
#

Wish me good luck ๐Ÿซก I'll check a doc

tawny remnant
#

How can I create a DamageIndicator? When I tried getting the finalDamage off of EntityDamageByEntityEvent it only triggered when I was damaging a player not another entity. Got any tips?

young knoll
#

That event does trigger for all living entities

quaint mantle
quaint tapir
#

is there a cap on how high I can set a mobs health
I can set a spiders health to 200 but not 2000

cinder abyss
# quiet ice You probably can easily do <https://hub.spigotmc.org/javadocs/spigot/org/bukkit/...

I get this errors :bat Failed to schedule load callback for chunk [4, -6] java.util.concurrent.CompletionException: net.minecraft.ReportedException: Exception generating new chunk at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:315) ~[?:?] at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:320) ~[?:?] at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:1159) ~[?:?] at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:482) ~[?:?] at net.minecraft.server.level.ChunkTaskQueueSorter.b(SourceFile:62) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.h(SourceFile:91) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.a(SourceFile:146) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.run(SourceFile:102) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1395) ~[?:?] at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373) ~[?:?] at java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182) ~[?:?] at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655) ~[?:?] at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622) ~[?:?] at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165) ~[?:?] Caused by: net.minecraft.ReportedException: Exception generating new chunk at net.minecraft.server.level.PlayerChunkMap.lambda$31(PlayerChunkMap.java:740) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[datafixerupper-6.0.6.jar:?] at net.minecraft.server.level.PlayerChunkMap.lambda$30(PlayerChunkMap.java:721) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:1150) ~[?:?] ... 11 more Caused by: java.lang.IllegalArgumentException: Coordinates 10, 8, 6 are not in the region at com.google.common.base.Preconditions.checkArgument(Preconditions.java:453) ~[guava-31.1-jre.jar:?] at org.bukkit.craftbukkit.v1_19_R3.generator.CraftLimitedRegion.getType(CraftLimitedRegion.java:191) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at fr.paulem.simplesores.CustomOreGen.populate(CustomOreGen.java:34) ~[?:?] at net.minecraft.world.level.chunk.ChunkGenerator.applyBiomeDecoration(ChunkGenerator.java:461) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkGenerator.a(ChunkGenerator.java:444) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkStatus.lambda$11(ChunkStatus.java:149) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkStatus.a(ChunkStatus.java:276) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.server.level.PlayerChunkMap.lambda$31(PlayerChunkMap.java:723) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[datafixerupper-6.0.6.jar:?] at net.minecraft.server.level.PlayerChunkMap.lambda$30(PlayerChunkMap.java:721) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:1150) ~[?:?] ... 11 more

With this : https://pastecord.com/sevityzoza.java

quiet ice
#

You need to add the world pos ontop of the chunk coords

young knoll
#

Caused by: java.lang.IllegalArgumentException: Coordinates 10, 8, 6 are not in the region

#

They are't chunk relative coordinates

cinder abyss
young knoll
#

You need to use coordinates relative to the world spawn

cinder abyss
cinder abyss
#

so I need to get the spawn location ?

quiet ice
#

chunkX * 16 to x and chunkZ * 16 to z

cinder abyss
#

@quiet ice Perfect :bat Caused by: java.lang.IllegalArgumentException: Coordinates 33, 11, 0 are not in the region at com.google.common.base.Preconditions.checkArgument(Preconditions.java:453) ~[guava-31.1-jre.jar:?] at org.bukkit.craftbukkit.v1_19_R3.generator.CraftLimitedRegion.getType(CraftLimitedRegion.java:191) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at fr.paulem.simplesores.CustomOreGen.populate(CustomOreGen.java:34) ~[?:?] at net.minecraft.world.level.chunk.ChunkGenerator.applyBiomeDecoration(ChunkGenerator.java:461) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkGenerator.a(ChunkGenerator.java:444) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkStatus.lambda$11(ChunkStatus.java:149) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.world.level.chunk.ChunkStatus.a(ChunkStatus.java:276) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.server.level.PlayerChunkMap.lambda$31(PlayerChunkMap.java:723) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[datafixerupper-6.0.6.jar:?] at net.minecraft.server.level.PlayerChunkMap.lambda$30(PlayerChunkMap.java:721) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:1150) ~[?:?] at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:482) ~[?:?] at net.minecraft.server.level.ChunkTaskQueueSorter.b(SourceFile:62) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.h(SourceFile:91) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.a(SourceFile:146) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at net.minecraft.util.thread.ThreadedMailbox.run(SourceFile:102) ~[spigot-1.19.4-R0.1-SNAPSHOT.jar:3739-Spigot-d1bd3bd-63cad7f] at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1395) ~[?:?] at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373) ~[?:?] at java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182) ~[?:?] at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655) ~[?:?] at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622) ~[?:?] at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165) ~[?:?]

quiet ice
#

Also it's X = random.nextInt(16); not X = random.nextInt(16) + chunkX; (probably)

#

No - actually it's X = random.nextInt(16) + chunkX * 16; if you didn't add the chunkX * 16 somewhere else

cinder abyss
quiet ice
#

Yeah no - that won't work

cinder abyss
#

no errors...

#

incredible

#

this is a dream

#

there is no other explaination

#

this can't be real...

#

it's preparing the world...

#

it's slow but it's working ๐Ÿคฃ

#

@quiet ice thank you so much, and thanks to the others

#

finally, after 3 days, it's working

#

hello vein

tawny remnant
#

Is there a way to create a single line of String out of a ItemStack array?

chrome beacon
#

StringBuilder and a for loop

#

You forgot a part of the package name in the plugin.yml

regal scaffold
#

How can I create a Hashmap

#

That stores a UUID, Integer

But that I can do a progressive sum

#

As in, if the UUID exists, add whatever was there before to the new value. But default to 0 if it isn't there

#

Is this possible in 1-2 lines? Cause I know I can do if but I thought it would be nicer by having any non-existing values default to 0 so it doesn't crash

#

๐Ÿ‘ That's what it was!

#

Sick

hushed heath
#

so i was wondering how to make it so my command wont register

#

like it would be red

#

but still work

remote swallow
#

use the player command pre process event

sterile token
#

I have done some sort of wand claiming system. But i have some sort of bug (mainly self coding error) where all the blocks marked in red are not being protected (like if they werent part of the region). Its just protecting all the blocks between the red ones

river oracle
#

?paste

undone axleBOT
river oracle
#

your code for that

sterile token
#

right

#

1m bro i have to reopen IJ

sterile token
quiet ice
#

Just inflate the region by 1 block to each side : problem solved

sterile token
#

oh ok

#

So just add +1 to max and min region?

river oracle
sterile token
analog snow
#

Hey guys, I need your help. Could someone explain to me why this does not work?

sterile token
river oracle
sterile token
river oracle
#

oh If you aren't using bounding boxes I would

#

but otherwise just inflate by one as geol said

#

its probably the easiest way

sterile token
river oracle
#

oh okay

#

hm I guess inflating by one then

sterile token
#

Yeah that the issue right?

river oracle
#

uea

sterile token
#

So each vector property + 1 right

river oracle
#

just add +1 too a named constant

sterile token
#

๐Ÿคฆโ€โ™‚๏ธ

sterile token
river oracle
#

inflating just means + 1 to x and z

sterile token
#

Really thanks to both of you mates!

river oracle
#

I would make that a named constant though so you know what it does much later on incase things end up changing

analog snow
river oracle
#

like

public static final int INCLUDE_BORDER = 1;
sterile token
#

For example in 1.8x getLocation() method exists, but for newer api version does

analog snow
#

He is using 1.16.5 and I am on 1.8.8

sterile token
#

Thats the reason haha

analog snow
#

How can I do that in 1.8x then?

sterile token
#

If you are on 1.8 there is not getLocation() method

river oracle
#

upgrade versions

#

stop using 1.8.8

analog snow
#

not possible

river oracle
#

old pvp can be replicated new features can't

sterile token
# analog snow How can I do that in 1.8x then?

I now your feeling of people telling to upgrade version, i dont really agree with them. So if you need 1.8 help just ping me

You use the next code:

// saving it to config
Location current;
getConfig().set("myLocation", current);

// loading it from config:
Location locaiton = getConfig().get("myLocation", Location.class);
if (location == null) return; // Just in case the location is null
river oracle
#

besides hte pvp which can be replecated

analog snow
sterile token
wary topaz
#

anyone know a api or atleast a working documentation on how to make a message listener for spigot>bungee

#

show us the yml

#

you check the imgur link and ask that agani lol

#

lol

#

morice do you use messagelisteners?

#

no for likebungeecoord

#

PluginMessageListener

#

spigot>bungee

#

well idk anything else

#

could you help me out?

#

I use pterodactyl if that matters

#

yeah im trying to connect a player

#

to a different servwer

#

its outdated

#

it doesnt work

#

damn

#

stuck with bungeeguis and citizens dont even support it

#

ill make a request to update forms

#

do you have a spigot account bajka

#

you have to verify

#

./verify

#

image perms

#

lol

#

read the error

#

I dont know, you should test it ๐Ÿ˜‰

sterile token
# river oracle what is the reason to use such an old version

Hi bro, im again sorry. Could you give me a hand designing a opened menu tracking system? So every menu you open is tracked on a LinkedMap<Player, Menu> so then you can: get the current menu opened, the menu opened before the current one and also the next menu

#

Im not really sure how to track each menu let say

wary topaz
opal juniper
#

you need waterfall

wary topaz
#

what's that?

opal juniper
#

bungeecord for 1.8 - made by paper

wary topaz
#

is it alot of changes?

opal juniper
#

no

#

not by default at least

wary topaz
#

I cant find any 1.8 downloads for it

#

what @kind hatch you know something I dont?

sullen marlin
#

No you dont

#

Latest bungee supports 1.8 fine

wary topaz
#

oh really?

opal juniper
#

huh i have been misinformed.

wary topaz
#

the reason I'm going to 1.8 is because of the 1.19 plugin messaging missup

sullen marlin
opal juniper
#

just run folia instead of 1.8

wary topaz
#

bungeecoord aint registering the pluginmessage

weak meteor
#

event.getPlayer().performCommand("staff");

wary topaz
#

i tried a numerousof ways

sullen marlin
sullen marlin
undone axleBOT
#

Itโ€™s hard to answer a programming question without code
Oh no! You ran into a problem. But no worries, people are willing to help, but first they need to see your code. This is because otherwise, they would be providing help based on guesses instead of concrete knowledge. Whether it be a compile error, runtime error, or an unexpected output, I'm sure that if you were to provide code, you'd receive a quick solution.

sullen marlin
#

1.8 isnt gonna fix it

weak meteor
wary topaz
#

let me undo my delete rqw

sullen marlin
wary topaz
#
out.writeUTF("Connect");
out.writeUTF(args[0]);
player.sendPluginMessage(this, "bungeecord:main", out.toByteArray());```
weak meteor
sullen marlin
#

The channel is BungeeCord

wary topaz
#

I know for a fact that does not work

#

let me scroll up and get the message

sullen marlin
#

And I know for a fact it does

kind hatch
#

๐Ÿฟ

young knoll
#

Why did you decide โ€œhmm this isnโ€™t working in the latest versionโ€ฆ letโ€™s try one from 7 years agoโ€

wary topaz
#

ughh cant find the msg ill try again

kind hatch
#

Is the wiki outdated or should the string just be "BungeeCord"?

weak meteor
#

Now im using spigot, now can someone explain me this?

quaint mantle
#

is there a way to apply data to a flying enderpearl

sullen marlin
quaint mantle
#

projectile

weak meteor
#
player.getInventory().clear();
                    Object inv = config.get("inventory");
                    ItemStack[] inventory = (ItemStack[]) inv;
                    player.getInventory().setContents(inventory); // Line highlited
                    player.sendMessage(); 
quaint mantle
#

to be more generell

#

general

young knoll
#

Itโ€™s an entity

kind hatch
young knoll
#

So it has PDC

young knoll
#

Or metadata

quaint mantle
#

ill stick to pcd since i know how to use it more then metadata

weak meteor
#

damn

#

im never creating...

wary topaz
weak meteor
#

actually, what?

#

it is ok...

wary topaz
#

you should indent your if statements

weak meteor
#

indent?

wary topaz
#

like conjunction

#

idk how you read that

kind hatch
#

Those are two different things.

#

His code is already indented.

weak meteor
#

idk what u mean

wary topaz
#

im just stating my opinion

topaz atlas
#

Umm

#

I been looking online

#

and for tutorials

#

How do i finish it?

wary topaz
#

yikes

topaz atlas
#

I tried diffrent options too

wary topaz
#

light mode

#

and i dont use ecilpse so idk

topaz atlas
topaz atlas
remote swallow
#

@young knoll speak

topaz atlas
#

EpicEbic

wary topaz
#

he uses intellij

topaz atlas
#

Oof

young knoll
#

Who huh what

wary topaz
#

he needs help with eclipse

topaz atlas
wary topaz
#

and please go through how to turn on dark mode ๐Ÿ˜Ž

topaz atlas
# topaz atlas

How do I finish this? what option do I need? and yes, i tried finding the awnser myself

wary topaz
#

is ?eclipse a command

#

nope

kind hatch
#

?eclipse

remote swallow
young knoll
#

Oh

#

I have no idea I never do anything fancy when making a class

topaz atlas
#

And eclipes gives me that option

#
        // TODO Auto-generated method stub
        int i = 0;
        while (i < 10) {
          System.out.println((i*10) + "%");
          i++;
        }
        if (config.getBoolean("test")) {
            // do something
            System.out.println("Sucess!");
        }
        Bukkit.getPluginManager().registerEvent(new SignEvents(), plugin: this);
        //super.onEnable();
    }
    ```
young knoll
#

Just making a normal class all I need to add is a name

topaz atlas
#

I clicked SignEvents

#

and clicked "create class"

topaz atlas
young knoll
#

I think it may want a proper super class

native nexus
young knoll
#

Any class that extends Listener can be registered with that method

#

Sorry, implements

topaz atlas
young knoll
#

Make a new class

#

Call it whatever

#

Add implements listener to the class declaration

dusk flicker
#

I think this is a case for the good ol

#

?learnjava

undone axleBOT
dusk flicker
#

my lord that list looks horrible

wary topaz
#

its not his fault, eclipse sucks

#

and yes it does lol

native nexus
#

Learn java from your backyard neighbour

topaz atlas
#

anyways

fluid river
#

learn java from me

#

?freejavalessons

topaz atlas
#

seems they got the best eclipes