#help-development

1 messages · Page 1410 of 1

glossy scroll
#

Lol

#

1.8 great packet rewrite

quiet ice
#

Why not 1.17?

glossy scroll
#

1.17 isnt gonna be a very game changing update

quiet ice
#

1.7 was the packet rewrite afaik

glossy scroll
#

1.8 was im p sure

wraith rapids
#

because they will be too busy stewing in their shit over the world height being changeable per world now

glossy scroll
#

1.18 should just be a new era

#

No more backwards compat in 1.18

quiet ice
#

1.17 does change a good portion of internal stuff

glossy scroll
#

I suppose

wraith rapids
#

it's horrifying

glossy scroll
#

To prepare

#

Final packet fields 💀

quiet ice
#

1.17 would allow for a bigger world already

wraith rapids
#

and what's more horrifying is that they are going full steam towards being fully data driven and dynamic

glossy scroll
#

yes

wraith rapids
#

and bukkit can't even get rid of the fucking biome enum

glossy scroll
#

LOL

#

Choco’s pr takes care of all that

#

I hope its accepted at some point

wraith rapids
#

never gonna be merged

glossy scroll
#

yea 😔

wraith rapids
#

md69 is just gonna sit on his mouldy ass until it grows roots and spigot dies

glossy scroll
#

ok sir

quiet ice
#

I advocate for that PR, even if it is a pain to rewrite my plugin to it

glossy scroll
#

I was able to implement custom dimenstikns tho

#

With help of md

wraith rapids
#

you can get them to work on bukkit

#

but they're not supported in any fashion

#

same with biomes

glossy scroll
#

No thats what i mean

#

Previous custom worlds wouldnt generate with datapacks

#

I added that support (with some md help)

#

“”Support””

wraith rapids
#

you've been able to hack those into loading and generating for quite a long time

#

there was a slimefun server like a year or two back that had a custom nether dimension from a datapack

#

of course it still explodes daily even to date because no plugin can handle the custom biomes there, as the getBiome return type is an enum

young knoll
#

Is there a resource to convert wiki.vg names to protocollib names

vast quest
#

how can I check if the damager is a player in EntityDamageByEntity event

young knoll
#

event.getDamager.getType

rare rain
#

Also event.getDamager() instanceof Player

quaint mantle
#

^ better

young knoll
#

I imagine instanceof is ever so slightly slower

rare rain
#

But better practice in the long run imo, especially considering most people asking such a question are just beginning programming

#

And forces them to have some sort of early contact with OOP principles

young knoll
mortal hare
#

at least for blocks

quiet ice
#

instanceof is in the realms of nanoseconds

#

getType likely also, but instanceof is usually faster than a field access from what I know; the difference decreases (and eventually goes negative) up if you chain instanceof though

wraith rapids
#

instanceof needs a field access as well of course

#

or, well, not a field access, but a memory read anyway

#

i suppose getting the type would be two at a minimum

mortal hare
#

it chains instanceof

#

iirc

quiet ice
#

that is very concerning

#

At the very best they should cache that

mortal hare
#

or maybe im incorrect

#

it think they do this for inventory types

#

lemme check

#

i've saw some chaining for sure

#

yep

#

inventory.getType() does this

obtuse basin
#

Is there a way to check if a Configurationsection exists?

mortal hare
#

in this case wouldnt it be easier to get the class name and do a switch?

#

O(1+n) or at best case O(2)

wraith rapids
#

getting the class name is pretty expensive iirc

mortal hare
#

chaining would be O(n) everytime right now

wraith rapids
#

but, entity::gettype definitely doesn't do that

#

the entity type is a final field on the entity instance

#

inventories are just fucking cancer

mortal hare
#

ik

#

why wouldnt they store the inventoryType everytime

#

the inventory is created

#

like you use InventoryType enum still inside the args whenever you create it

#

why not store it in a field

#

instead of chaining shit like that

wraith rapids
#

muh 32 bits

mortal hare
#

Ram is cheaper than CPU's

#

also its size is 4 integers

wraith rapids
#

references are 4 bytes though, usually anyway

#

you're not allocating a new instance of the enum or type or shit, you're just referring to the existing instance

mortal hare
#

the more i see the NMS the more i hate it

wraith rapids
#

the stream parts are the best

sage swift
#

can someone explain PermissionAttachment

minor garnet
#

if (Integer.valueOf(args[2]) == null i cant check if is null ? i getting null exception aways

eternal oxide
#

check args length

wraith rapids
#

you're probably not getting a "null exception"

#

you're probably getting either ArrayIndexOutOfBounds, or NumberFormatException

eternal oxide
#

it will be index out of bounds or a number exception

wraith rapids
#

please read your errors past the first fucking line

mortal hare
#

then try to get value of integer from that argument

minor garnet
#

is not null

mortal hare
#

if you haven't specified args[2] it would always throw nullpointerexception

minor garnet
#

becausee :

mortal hare
#

in this case

minor garnet
#

int chance = ( args.length < 3) ? 100 : Integer.valueOf(args[2]);

#

i already this check

wraith rapids
#

again, re-read your exception

#

are you sure it's a NullPointerException

mortal hare
#

can you show us the stacktrace

#

from the console

hybrid spoke
#

do you want to test if its an integer?

#

do you try to get the integer out of this string?

wraith rapids
#

he wants to send us the fucking exception

minor garnet
#

its because i need check if player execute command /loot create name otherthingelseanumber

sage swift
#

sudo vinny7 c:no i dont

vast quest
mortal hare
minor garnet
minor garnet
#

i already getting this

vast quest
#

but the File Is tehre

hybrid spoke
mortal hare
vast quest
#

wut

#

wdym

mortal hare
# minor garnet

you literally inputted "asd" and you're trying to parse integer from it

#

use try catch block

#

if it throws NumberFormatException

#

it means the integer is not parsable to int

minor garnet
#

yes but in my opinion is send me null, then if is null understand ?

#

but okay

vast quest
#

dovidas

#

how can I fix that

minor garnet
#

i ill try it

eternal oxide
mortal hare
#

show us the stacktrace

hybrid spoke
#

it trys to parse the string to an integer. if it can't do that -> error. you have to catch the error.

mortal hare
#

when you input normal number

young knoll
#

I don't seem to have any issues with the player flying into space, but I forgot jump boost reduces fall damage

vast quest
#

Ok imma just wait till u guys are done with him

sage swift
#

They're called "exceptions" for a reason. In a perfect world, you never get an exception. Say my boss asks me to work on an assignment. He'll expect me to say "yes, sir!" but I might reply with "I have a lot on my plate right now, I can't accept a new assignment without letting existing work fall through." He is prepared for both of those. He isn't prepared for me to punch him in the face. I lose my job and he calls security. Now imagine if he called security for me simply saying I have too much work - that's the third method: calling the cops for something that should just be expected.

wraith rapids
#

Caused by: java.lang.NumberFormatException: For input string: "asd"

#

read

#

your

#

exceptions

#

past the first line

glossy scroll
#

(85% sure)

young knoll
#

Ah

#

I could add fall damage back with the damage event I guess

glossy scroll
#

I do onow that the server calcukated jump boost velocity correctly

#

Its an int value, not byte value (server side)

young knoll
#

But then I have to calculate all the fall damage reduction by hand

mortal hare
#

just fix the kb system

#

instead of patching it

#

externally

#

its a bug.

hybrid spoke
wraith rapids
#

that is a stepping stone to what he wants to do yes

mortal hare
#

he stated that he doesn't get parsed number even if he inputs it

young knoll
#

Note to self > burn in daylight + instant death challenges don't go well together if you don't have a spawnpoint inside

wraith rapids
#

in reality he just wants to let a player specify a number

mortal hare
#

because it throws "null pointer exception"

wraith rapids
#

he should stop being a sub 70 iq vegetable

hybrid spoke
vast quest
#

I tried to make a reload command but it gave this error https://paste.md-5.net/fiyasenuwu.md

It says that the file is not there but the file IS there as you can see below. I think I may have done smth really dumb this is the code

    public FileConfiguration getCustomConfig() {
        return this.customConfig1;
    }```
```java
    private void createCustomConfig() {
        customConfigFile1 = new File(getDataFolder(), "config.yml");
        if (!customConfigFile1.exists()) {
            customConfigFile1.getParentFile().mkdirs();
            saveResource("config.yml", false);
        customConfig1 = new YamlConfiguration();
        try {
            customConfig1.load(customConfigFile1);
        } catch (IOException | InvalidConfigurationException e) {
            e.printStackTrace();
        }

ParticleManager.getInstance().getCustomConfig().load("config.yml");
And the file is there in the plugins/ParticleManager/ location the config.yml is there

young knoll
#

I love that thread

#

"If best practices don't matter to you, or you want to troll the guy who does your code reviews, try this on for size:"

sullen dome
#

restart your server?

#

ah nvm that file im dumb

#

Commands.java:28
which line is that?

vast quest
#

Its the 3rd code I sent

#

that gives the error

#

Idk if I understood you right

eternal oxide
#
Pattern numbersOnly = Pattern.compile("^[0-9]+$");
public boolean isNumber(String arg) {
    if (arg == null || arg.length() == 0) return false;
    return numbersOnly.matcher(arg).find();
}```
sullen dome
#

what means load()? is that one of your methods or from YamlConfiguration or smt

wraith rapids
#

but what if I want to match decimals too

#

and scientific notation

eternal oxide
#

tuff 🙂

sullen dome
#

im dumb at reading, it's from FileConfiguration

wraith rapids
#

and also base2 and base8 and base16

vast quest
wraith rapids
#

like, have you seen that regex that you're "recommended to use to check strings" that's listed in the javadocs

#

shit probably weighs more than trying to parse it throwing the fucking exception

young knoll
#

Aren't compiled patterns reasonably fast

eternal oxide
#

faster than a regex

sullen dome
#

so, it's searching for a file... idk where it searches...

wraith rapids
#
final String Digits     = "(\\p{Digit}+)";
  final String HexDigits  = "(\\p{XDigit}+)";
  // an exponent is 'e' or 'E' followed by an optionally
  // signed decimal integer.
  final String Exp        = "[eE][+-]?"+Digits;
  final String fpRegex    =
      ("[\\x00-\\x20]*"+  // Optional leading "whitespace"
       "[+-]?(" + // Optional sign character
       "NaN|" +           // "NaN" string
       "Infinity|" +      // "Infinity" string

       // A decimal floating-point string representing a finite positive
       // number without a leading sign has at most five basic pieces:
       // Digits . Digits ExponentPart FloatTypeSuffix
       //
       // Since this method allows integer-only strings as input
       // in addition to strings of floating-point literals, the
       // two sub-patterns below are simplifications of the grammar
       // productions from section 3.10.2 of
       // The Java™ Language Specification.

       // Digits ._opt Digits_opt ExponentPart_opt FloatTypeSuffix_opt
       "((("+Digits+"(\\.)?("+Digits+"?)("+Exp+")?)|"+

       // . Digits ExponentPart_opt FloatTypeSuffix_opt
       "(\\.("+Digits+")("+Exp+")?)|"+

       // Hexadecimal strings
       "((" +
        // 0[xX] HexDigits ._opt BinaryExponent FloatTypeSuffix_opt
        "(0[xX]" + HexDigits + "(\\.)?)|" +

        // 0[xX] HexDigits_opt . HexDigits BinaryExponent FloatTypeSuffix_opt
        "(0[xX]" + HexDigits + "?(\\.)" + HexDigits + ")" +

        ")[pP][+-]?" + Digits + "))" +
       "[fFdD]?))" +
       "[\\x00-\\x20]*");// Optional trailing "whitespace"

  if (Pattern.matches(fpRegex, myString))
      Double.valueOf(myString); // Will not throw NumberFormatException
  else {
      // Perform suitable alternative action
  }
sullen dome
#

GOD

#

please

#

?paste

queen dragonBOT
wraith rapids
#

no

sullen dome
#

yes

wraith rapids
#

up your ass

eternal oxide
#

a little overkill

wraith rapids
#

the point is that it's big

#

it doesn't work if I don't paste it in your face

sullen dome
#

so what should i take from that now?

#

that your file is big? lmao

wraith rapids
#

that the javadocs are dumb

sullen dome
marble verge
#

getTitle seems to be deprecated, what can i use instead?

young knoll
#

getView.getTitle

wraith rapids
#

getTitle on inventory view

marble verge
#

thanks

wraith rapids
#

also, if that question wasn't one that people ask 100 times a day, we would have no idea what you're talking about

sullen dome
#

yeah, why do people even ask about that... isn't that change since like 1.8?

wraith rapids
#

because 1.8 people can't read the docs

sullen dome
#

true true

wraith rapids
#

and sometimes have to do stuff on other versions than 1.8

#

which makes their small and smooth brains overheat

sullen dome
#

are you okay? you sound pretty angry tho

wraith rapids
#

i am fueled by my fucking incandescent hatred

eternal oxide
#

NNYa has a permanent vein bulging on his 5head.

sullen dome
#

that's interesting

mortal hare
sullen dome
#

how can i turn off my fucking ps5 controller ahhh

#

when connected with pc

wraith rapids
#

oh fuck off

#

can't even send copypastas

eternal oxide
#

bot attack

sullen dome
#

same error?

vast quest
#

wait imma copy it

#

omg

#

o

#

wait

#

wut

sullen dome
#

or try to use YamlConfiguration#loadConfiguration(File);

#

that should work definitely

mortal hare
#

or code your own loader

sullen dome
#

or code your own loader xd

vast quest
#

ok this is wizard magic

mortal hare
#

or write in assembly

#

to make it more OPTIMISED

wraith rapids
#

or depend on a configuration library that isn't garbage

sullen dome
#

let me guess, it works, and you dont know why?

vast quest
sullen dome
#

yeah, what i said

#

i love when such things happen

vast quest
#

wizard magicc!

sullen dome
#

like... a decade ago...
my getDataFolder() always returned null, and even mods didnt knew why lol

vast quest
#

aaaaaaaaaaaaaaaaaaaaaaa

sullen dome
#

bbbbbbbbbbbbbb

vast quest
#

intellij update

sullen dome
#

oh true

vast quest
#

im too lazy to update aaaaa

sullen dome
#

if i update now, i will get 1000 errors again, i guess?

wraith rapids
#

i haven't updated intellij in years

sullen dome
#

like everytime

wraith rapids
#

in my experience the people developing the ide only make it worse with every update

vast quest
#

Im just going for it

#

ok no I felt like that was going to break my wizard magicc

sullen dome
#

there's one update in intellij i really enjoyed

wraith rapids
#

what did it do

vast quest
#

nothing!

sullen dome
vast quest
#

there is 1 update that I really enjoyed

#

it did absolutely nothing

wraith rapids
#

would be nice if the ide wasn't so fucking heavy I could run even a single instance without lagging to shit

sullen dome
#

yeah

#

yk whats funny

vast quest
#

lol

sullen dome
#

god bless my cpu

wraith rapids
#

ij is so bloated and full of useless eyecandy

vast quest
#

my explorer lags more than intellij

wraith rapids
#

some day I will write myself a simple and bare bones ide

#

or just switch to fucking notepad and javac

sullen dome
#

it's more than enough

eternal night
#

Isn't there an intellij light client for people that work on toasters ?

sullen dome
#

idk

#

maybe eclipse? lmao

wraith rapids
#

you can turn a lot of the gizmos off but then it's just about as useless as eclipse

vast quest
#

tbh I dont like my pc... its not "good" but im glad its not a toaster

sullen dome
#

what stuff is inside?

eternal night
#

just vim and language server kekw

wraith rapids
#

my processor is like 600mhz

sullen dome
#

well, i had a 2x2ghz cpu before, with a geforce gt1030, imagine that

vast quest
#

OH

#

I FOUND WHAT I DID

sullen dome
#

what was it? lol

wraith rapids
#

it goes up to 1.5ghz but because of shitty passive cooling it always throttles down to 600mhz

vast quest
#

ParticleManager.getInstance().getCustomConfig().load("plugins/ParticleManager/config.yml");

sullen dome
#

like my gpu has a huge problem

#

it's made that the fans only turn at 55+ degrees

#

problem?

vast quest
#

wtf?

sullen dome
#

it always is between 53 and 56 degrees

vast quest
#

im pretty sure fans are suppose to... not even let it go that high

wraith rapids
#

50'ish is fine

#

not good but fine

fresh heath
#

What's the problem in here

            Map<String, Integer> PlayerHits = new HashMap<String, Integer>();
            PlayerHits.put("howmanyhtis", 0);

            int howmanyhits = PlayerHits.get("howmanyhits");
            howmanyhits = howmanyhits + 1;
sullen dome
#

well, when playing horizon zero dawn, or stuff like that, its on like 70-80

#

the fans of the msi-version are trash yeah

vast quest
#

there is a difference between functional and barely working

#

my pc is in thew middle

wraith rapids
#

rivex

sullen dome
#

msi radeon rx580 armor oc, before someone asks

#

thats me

wraith rapids
#

tell this potato fuck how to get his map working

#

he's been at it for 2 days now

sullen dome
#

which map

#

oh is ee

#

i see

wraith rapids
#

he wants to store the # of times a player punches

sullen dome
wraith rapids
#

that he doesn't know anything about anything

fresh heath
#

yes

vast quest
#

question should I change my particle system to packets instead of spawn particle

wraith rapids
#

never written a single line of java and unable to comprehend even the simplest of tutorials

#

spawnParticle just shit out packets anyway

sullen dome
#

i mean, what is the problem? error?

wraith rapids
#

they're basically the same

fresh heath
#

no error doesnt work

vast quest
#

o well

sage swift
#

it's because the map is capitalized

sullen dome
#

what exactly doesnt work

sage swift
#

duh

wraith rapids
#

lol

vast quest
sullen dome
#

tf

vast quest
#

dont ask

sullen dome
#

doesnt matter if it's capital or not. in functionality

sage swift
#

it must be because he's using java 16 then

#

needs to*

#

since it's for 1.16

sullen dome
#

i mean doesnt work isn't that specific

sage swift
#

well it's pretty obvious to see why it doesnt work

wraith rapids
#

it's like trying to help a toddler build a house

sullen dome
#

well yeah it is

#

tho

#
howmanyhits = howmanyhits + 1;```
that's not how it works
vast quest
#

isnt it howmanyhits++

sullen dome
#
map.set(key, map.get(key) + 1);```
sage swift
#

that will solve all the issues yes

sullen dome
#

(pseudocode btw)

#

btw, in idle...

fresh heath
#

pseudo code is like the code that the idea is correct but it isnt correct

sullen dome
#

tf, you want to correct me? lmao

wraith rapids
#

how dare he

#

lynch him

sullen dome
#

my name is pink

wraith rapids
#

that's pretty gay

sage swift
#

and youre white

cold field
#

guys, does anyone know how to properly use commodor file format?

vague kayak
#

Do you have an idea of ​​the event when a block of cobble and generate from lava and water?

vast quest
sage swift
#

BlockFromToEvent

#

also its not fun

#

trust me

#

it's the worst

cold field
#

😦

sullen dome
#

tf what is that name

vast quest
#

wait

wraith rapids
#

block from to event iirc

vast quest
#

if we cancel blockupdateevent

sullen dome
#

Does BlockFromToEvent really exist? lmao

vast quest
#

wouldnt that mean

#

o-o

cold field
#

no one?

sullen dome
#

ICH BRAUCH WASSER

sullen dome
cold field
#

😦

wraith rapids
#

hoh

#

what does this do

sage swift
#

ore gen

#

classic stuff

wraith rapids
#

no readme

young knoll
#

Why not listen to the cobble forming

wraith rapids
#

does it have a resource page

dense tartan
sage swift
#

i think the reason i didnt go with that is because i couldnt set the block during the event

young knoll
#

you can cancel the event and set the block manually

sage swift
#

dont remember

young knoll
#

Or just override the old block one tick later

wraith rapids
#

cancelling the event fucks plugin compatibility though

young knoll
#

But yes it would be nice if it had a setNewState

vital ridge
#

Hey, I made a plugin so enchants multiply with a specific number. Basically when I have 2 sharpness 20 swords and i combine em in anvil, the new sword will successfully be sharp 40. But if i have both sharp 20 swords, but they both or one of them has more than 1 enchantment, the numbers stay the same and dont go up as they should.
Heres my code
https://pastebin.com/Ld8Nz4Yb

sage swift
#

40?

wraith rapids
#

hardcore

young knoll
#

Someone PR a setNewState for that event, i'm lazy

fresh heath
#

I have no idea what .set() does I dont even have that option

sage swift
#

cant set in a map

wraith rapids
#

he means put

#

replace set with put

fresh heath
#

it actually seems to work

sage swift
wraith rapids
#

potato

#

do you know why it didn't work before

quaint mantle
#

@wraith rapids man my plugin doesn't appear on the server

young knoll
#

Check console

#

It probably failed to load

quaint mantle
#

i did

wraith rapids
#

can't help without any info

#

probably won't help anyway

fresh heath
quaint mantle
#
[21:42:08 ERROR]: Could not load 'plugins\Soldier.jar' in folder 'plugins'
org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml
    at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:160) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:144) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at org.bukkit.craftbukkit.v1_16_R3.CraftServer.loadPlugins(CraftServer.java:382) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:224) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:928) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:273) ~[spigot-1.16.5.jar:3054-Spigot-4225eac-f3ed1ac]
    at java.lang.Thread.run(Unknown Source) [?:1.8.0_291]
Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml
    ... 7 more
wraith rapids
#

have you tried reading it

sage swift
#

needs plugin.yml

quaint mantle
#

but look

sage swift
#

is it in src/main/resources

quaint mantle
young knoll
#

yaml parser

quaint mantle
young knoll
#

Also make sure it's in the exported jar

sage swift
#

that last line will cause problems

quaint mantle
#

why

sage swift
#

'

young knoll
#

Ah yeah

#

'don''t'

sage swift
#

or "don't"

young knoll
#

Fair

wraith rapids
#

big brain

sage swift
#

or just dont yeah

wraith rapids
#

do not

young knoll
#

Do'nt

quaint mantle
#

I want to paste a schematic via code, while I have worldedit installed right now, I don't intend to keep it like that, Can I paste schematics async without having worldedit/fawe installed?

sage swift
#

you said that

wraith rapids
#

you cannot paste things async, period

young knoll
#

FAWE will try

wraith rapids
#

not with worldedit nor otherwise

quaint mantle
#

just slowly pasting it in then, like only a few dozen blocks at a time?

sage swift
quaint mantle
#

@sage swift

Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml
wraith rapids
#

yes, just call setBlock a million times over

young knoll
#

You can place quite a few blocks per tick if you use NMS

quaint mantle
#

yeah but that doesnt support schematcs, right

sage swift
#

nope

quaint mantle
#

so what do i go with here

wraith rapids
#

bukkit doesn't support schematics

#

you'll need some library that does

sage swift
#

you definitely cant support schematics without worldedit, lol

young knoll
#

Sure you can

#

But you shouldn't bother

quaint mantle
#

@wraith rapids help pls

paper viper
#

lol

young knoll
#

The file isn't in your built jar

#

What are you building with

quaint mantle
#

Idk

young knoll
#

Since it's in src/main/resources I hope Maven/Gradle

quaint mantle
#

yes

#

Maven

wraith rapids
#

he did follow a maven tutorial

#

but he may have given up on it

quaint mantle
#

no

wraith rapids
#

probably using ant now

paper viper
#

lol

quaint mantle
#

n0

young knoll
#

How to you build it

#

Walk us through

quaint mantle
#

ok listen

#

i do this

paper viper
#

yes

quaint mantle
young knoll
#

Wrong

quaint mantle
#

what

#

why

wraith rapids
#

so you did give up, but only halfway

young knoll
#

run as -> maven install

quaint mantle
#

but maven install doesn't do anything

young knoll
#

iirc

#

It does

#

The jar is in the output folder

paper viper
#

no

young knoll
#

Forget where that is with maven

paper viper
#

mvn clean package

quaint mantle
paper viper
#

that is to clean the source folder

#

and package is to compile

young knoll
#

I used install /shrug

paper viper
#

it compiles to the target folder

wraith rapids
#

real men deploy directly to prod

paper viper
#

lol

quaint mantle
#

where does it go?

wraith rapids
#

we just told you

young knoll
#

I wish the quote button still existed

sullen dome
#

yeah, the new answer function is trash

#

with the auto-ping

quaint mantle
young knoll
#

It would be fine if it was persistent

sullen dome
#

lightmode god

#

kill me

paper viper
#

lmao

quaint mantle
#

why

paper viper
#

??

#

how are we going to know?

#

no code... no pom...

#

no error...

sullen dome
#

Source Option 5 is no longer supported

quaint mantle
#

okay wait

sullen dome
#

Use 7 or later

young knoll
#

I mean it does say

#

Why are you trying to build with Java 5

paper viper
#

^

sullen dome
#

change the compiler version in the pom

paper viper
#

lol

quaint mantle
#

What is Java 5

wraith rapids
#

why can you not read anything

paper viper
#

lmao

quaint mantle
#

@paper viper return

sullen dome
#

oh god

#

where am i

wraith rapids
#

literally every issue you have had until now is you not reading things told to you

#

you either skip reading them entirely

young knoll
wraith rapids
#

or you read them, don't understand, and then forget about them

quaint mantle
#

but you didn't tell me what Java 5 is

paper viper
#

smh

#

its a java major version

wraith rapids
#

how is it physically possible for someone to be so complacent and slothful

paper viper
#

java has its own versions

sullen dome
#

A VERSION?!?

wraith rapids
#

"do everything for me"

#

"i don't want to use my brain"

quaint mantle
#

but you DIDNT TEL me what JAVA 5 is

paper viper
#

I just did

wraith rapids
#

did you try searching google with java 5?

paper viper
#

And that too

wraith rapids
#

did you try doing anything yourself?

sullen dome
#

if you have java 8 installed (really hope so)
go to your pom.xml, change the version from 5 to 8, that's it

quaint mantle
#

im stupid

paper viper
#

I just said that Java 5 was just one of the major versions in Java

wraith rapids
#

you're not stupid

#

you just don't want to put in the effort

young knoll
#

Java 5 is a version of Java released in 2004

wraith rapids
#

you're worse than stupid

#

you're lazy

quaint mantle
#

i updated java just today

#

@wraith rapids shut up

paper viper
#

...

young knoll
#

People born in 2004 are 17 this year

paper viper
#

That is older than me

#

🥶

wraith rapids
#

noob at life

quaint mantle
#

I updated Java just today

sullen dome
#

not always. i was born in 2001 and i am 19 so...

#

maybe they're 16

young knoll
#

People born in 2004 are 17 this year

paper viper
quaint mantle
#

what is it

sullen dome
#

lol nvm my bad

quaint mantle
#

that skeleton guy says im not doing anything

wraith rapids
#

what

#

skeleton

paper viper
#

lmfao

wraith rapids
#

i don't even

sullen dome
#

Lol

paper viper
#

THis is hilarious

sage swift
#

hitler

quaint mantle
#

gecko you're good will you tell me what to do

wraith rapids
#

maybe gecko will take you to the 1.8 support server

quaint mantle
#

shut up

#

gecko pls help

paper viper
#

gecko aint gonna help you

#

lmao

#

ur acting 12

quaint mantle
#

I AM NOT

wraith rapids
#

anyway

quaint mantle
#

wtf

wraith rapids
#

you have a later version of java installed, yes

#

you've updated, yes

sullen dome
#

i suggest you guys reading #general and his messages today

vast quest
#

uhhhhhhhhhhhhhhh

quaint mantle
#

i updated java just today

wraith rapids
#

yes, you did

#

but you're still using an older version to compile

sullen dome
#

i dont think he acts like 12

quaint mantle
wraith rapids
#

i am literally the only one helping you

sullen dome
#

to quote myself, i dont like you either

wraith rapids
#

now, you need to go into your pom

quaint mantle
sullen dome
#

but yeah, that's humanity

wraith rapids
#

and specify source version as 7 or 8

sullen dome
#

we dont have to like everyone

#

but respect

quaint mantle
sullen dome
#

and that's what you probably never learned, so don't expect to get respect

quaint mantle
#

piece of shit

wraith rapids
#

i don't need to respect you

#

you're not worth respecting

sullen dome
#

who me or him

vast quest
#

heyo chill

quaint mantle
#

im doing whatever i can

wraith rapids
#
    <properties>
        <maven.compiler.source>1.8</maven.compiler.source>
        <maven.compiler.target>1.8</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>
#

add these properties to your pom

#

you are capable of copy pasting text, yes?

quaint mantle
#

yes

sullen dome
#

guys, you can't talk normally to him... really

wraith rapids
#

or shall I mail myself to you with fedex and do it for you

sage swift
quaint mantle
sullen dome
#

holy

#

i told you to show respect

#

see what i mean?

quaint mantle
#

you arent showing respect

#

FUCK YOU

sullen dome
#

show respect to me, and i will show respect to you, it's that easy

quaint mantle
#

you are trash

#

liar

#

fucking liar

wraith rapids
#

you're the baby sucking on my man-teats of programming knowledge

quaint mantle
#

you are talking shit

wraith rapids
#

you shall beg and bend your knee at my feet

vast quest
#

Respect should be both sided. If one side does not show respect there is no point in showing respect on that person

sage swift
#

return;

quaint mantle
#

please keep it clean! It's for coding help 😦

#

@quaint mantle someone is being disruptive

wraith rapids
#

i'm a pretty clean guy

vast quest
quaint mantle
#

I came for coding help and this guy started shit

sage swift
#

oh yeah show me your tongue

wraith rapids
#

i just ate some cookies

quaint mantle
paper viper
wraith rapids
#

i bet you wish you had cookies

sage swift
#

the only cookie i have is my third-party identifier B)

vast quest
wraith rapids
#

the cookie monster eats my browser cookies

quaint mantle
#

please do it in #general then

wraith rapids
#

you almost did it right

#

you need to paste it between <project> and </project>

#

since it's part of your project

sullen dome
#

i dont like going in it like this, but didn't your mother told you to respect people?
You show no sort of respect. if you want i can show everyone here what you wrote all the day today.
I say it a last time. Have Respect in here, this is not your bubble of friends, where you can do whatever you want.
Be respectful to people, and they'll be respectful to you, of course.

Thats the last thing i tell you

wraith rapids
#

can you handle doing that

wraith rapids
#

protip: you can press ctrl-z to undo an action

#

unlike in real life, where you will forever be held responsible for calling me a fucking skeleton

quaint mantle
#

you look like a skeleton

sage swift
#

santa hitler boner

sage swift
#

ok now can someone explain what the heck PermissionAttachment is/does

wraith rapids
#

i have no clue

sullen dome
#

i guess it's there to add perms

wraith rapids
#

i've never fucked with permissions beyond registering some in a plugin

sullen dome
#

well, i always used my own permission system, so idk

sage swift
#

luckperms-hacked.jar

young knoll
#

I just use vault

wraith rapids
#

and realizing that discordsrv bricks the garbage collector because it checks the perms of like 50000 users in a single task

sullen dome
#

not really

wraith rapids
#

which invokes a billion regex matchers

sage swift
#

task?

#

sus?

sullen dome
#

just like a file with Strings (permissions) bound to uuid's, and if's to that. that simple

sage swift
wraith rapids
#

the background role sync task

sage swift
#

amogu

sullen dome
#

that i use for my own plugins

#

as API

wraith rapids
#

seems uh

#

a bit redundant

#

what with bukkit already having permissions

sullen dome
#

because PermissionsEx is still unsupported, and i dont like vault/luckperms

sage swift
#

well i dont like you

sharp bough
#

return (Main.get().getConfig().get("activeBeds." + player.getUniqueId())) != null;
will that return true when its not null and false when its null ?

sullen dome
sage swift
#

what is it set to

#

or is it a list

#

because if its a list you should check #contains, not != null

sharp bough
#

it just
activeBeds:
playerId:
beds:
'1': 1
'2': 3
where player id is the player.getuniqueID

sullen dome
sage swift
#

use getConfigurationSection

young knoll
#

I mean you can simply add them with the vault api

sullen dome
#

nvm

#

yeah, it will

vast quest
#

is it just me or sometimes spigot does not update the file when posting a resource update

sullen dome
#

yeah, but iirc you can't manage perms without permission api's

#

except #hasPermission

young knoll
#

Yeah but that's why you have a permission API

sullen dome
#

i dont like depending on stuff

sage swift
#

and yet PermissionAttachment is beyond me

sullen dome
#

except spigot

young knoll
#

You only need to depend on vault

deep wave
#

literally any competent perm plugin replaces bukkits permission stuff with its own impl of stuff

sullen dome
#

yeah, so you have to have vault installed on the server. and i don't like that, just dont ask why

deep wave
#

vault works if you need to access things like groups, but, vaults pretty dated

sullen dome
#

i liked the api of PEX tho

young knoll
#

Still works with modern permission plugins

#

And saves you working with 7 different plugin APIs

sullen dome
#

thats why i use my own Permission-System 5Head

i mean, it's simple, but working

#

spigotmc has a support-desk? holy

#

that's nice

sharp bough
#

is there a way to affect all the values of a section in the config at the same time?

    playerId:
        beds:
            '1': 7
            '2': 2
    playerId1:
        beds:
            '1': 10
            '4': 16
    playerId2:
        beds:
            '6': 4
            '1': 8```
i want to set everything under beds to the num--
#

maybe * ?

#

i cant remember

sage swift
#

for (String key : config.getConfigurationSection("activeBeds").getKeys(false)) {

sour sand
#

is there a way to detect for an item in a players inventory

sage swift
#

if (player.getInventory().containsAtLeast(item, 1)) {

main dew
#

Who know luckperms API I have problem

sage swift
#

they have a discord, but sure, go ahead

sharp bough
#

its on the plugin.yml as well

#

Solved the problem by making a new project and just basically copying the code and pasting.

#

do i have to do that

sullen dome
#

first of all: the Objects.requireNonNull() is doing Nothing, like you can see. you can probably remove it.

2nd: i guess testCommand() is not a class?

#

if it is, why tf do you call a class in lowercase

sharp bough
#

testCommand is the only class i have in lowercase to avoid problems,

sullen dome
#

what kind of problems?

sharp bough
#

its just a test class i use to test things inside my proyect

#

a small command executor

#

that runs a part of my code

vernal basalt
#

if i do Bukkit.getOfflinePlayer() and the player is online what happens

sharp bough
#

to see the output without running all the events and classes

sullen dome
#

show us your yml

#

plugin.yml

quaint mantle
#

yo it says the class YalmConfiguration doesn't exist on spigot 1.8.8?? anyone knows why

sharp bough
#
version: ${project.version}
main: me.paradis.main.Main
api-version: 1.16
authors: [ Paradis ]
description: a bed plugin for Toxic
commands:
  beds:
    description: "adds a default respawn location to send the players when they close the GUI"
    usage: /beds [add/remove/player]
  test:
    description: "test"
    usage: /test```
sullen dome
#

with ````this please

sharp bough
#

oh

quaint mantle
#

yo it says the class YalmConfiguration doesn't exist on spigot 1.8.8?? anyone knows why

sullen dome
#

looks right

glass sparrow
#

lmao

sullen dome
#

1.8 isn't supported here

quaint mantle
#

is there another type

#

ok

#

so I won't be able to use custom config files? x/

#

on 1.8.8

sharp bough
#

1.8? i used to play that minecraft version like 9 years ago

sullen dome
quaint mantle
#

1.8.9 and 1.12.2

#

best versions ngl

sullen dome
#

why tho?

quaint mantle
#

ok so you won't help me ? -.-

sullen dome
#

i personally don't, because i don't code with 1.8 since years

quaint mantle
#

so you have no idea why it wouldn't work?

glass sparrow
sullen dome
#

what exactly is the issue?

quaint mantle
#

I'll check that

sullen dome
#

so lucas, you get a NoClassDefFoundException

i usually get that when reloading, or exporting into plugins-folder while server is running.

maybe try a clean restart, or exporting it with server closed?

#

or even Try Call the Class in ThisLetterCase? (idk how that case is called lol)

#

@sharp bough

sharp bough
#

i already fixed it

#

i just renamed the command

sullen dome
#

oh okay nvm, what was it

sharp bough
#

and remade the class

#

i have no idea what the error was

sullen dome
#

yeah, never call a class lowercase

sharp bough
#

lol

sullen dome
#

maybe it got confused and thought it was a method, because... lowercase, idk

sharp bough
#

hah just joking

sullen dome
#

please don't do that

quaint mantle
#

ok the clas YalmConfiguration is suppose to exist in 1.8.8 but I can't find it

sullen dome
#

go

#

d

quaint mantle
#

it says it doesnt exists

sullen dome
#

i hope so lol

#

lemme see

sharp bough
#

wich one is it

wraith rapids
#

smoothbrain

sullen dome
#

tf

quaint mantle
#

mister lucas

#

what are you even saying

sullen dome
#

mister? lol what did i missed

quaint mantle
#

yes

#

I typed it correctly

#

several times

#

didn't work

#

it's like the class doesn't even exists

sullen dome
#

it does

quaint mantle
#

are you using spigot 1.8.8

#

little boi

sullen dome
#

look at the right side

quaint mantle
#

dawg

#

what

#

in the world

sullen dome
#

i ditn't enabled dualwindow reasonless

random epoch
wraith rapids
#

real men use red

paper viper
#

red is gross

wraith rapids
#

you're gross

sullen dome
#

girls

random epoch
eternal night
#

Think you misspelled "darkest dark" as "red" there buddy

wraith rapids
#

red on black

#

anything else is heresy

sullen dome
#

from the spigot package ofc

quaint mantle
sullen dome
#

ok, so the file does obvly exist

#

if not, you would probably get thousands of errors tho

quaint mantle
#

it does

#

exist

#

but I can't access

#

it for some reason

wraith rapids
#

rebooterino

sullen dome
#

what means cant access

quaint mantle
eternal night
#

Yalm xD

#

lol

quaint mantle
#

lolipop

sullen dome
#

there's your issue

wraith rapids
#

have you tried importing it

eternal night
#

pretty sure it is spelled YAML

#

not Yalm

sullen dome
#

you wrote YalmConfiguration

quaint mantle
#

oh

#

fucking

#

hell

eternal night
#

kekw

sullen dome
#

it's YAML

quaint mantle
#

fucking

#

hell

sullen dome
#

xd

quaint mantle
#

I am so sorry for all the trouble

sullen dome
#

happens to everyone tho

quaint mantle
#

thank you so much

#

:ashamed:

sullen dome
#

sure

quaint mantle
#

but like

#

why did it import xD

#

YALM

#

xdd

sullen dome
#

i dont think YALM exists in any world

quaint mantle
#

HAHAHHA IK

#

then idk why it imported

sullen dome
#

No clue

quaint mantle
#

cuz i didnt write that line

sullen dome
#

but yeah, like a year ago i forgot semicolons, and opened forum threads... so i feel you xd

wraith rapids
#

the IDE is able to fix up some simple typos in class names

quaint mantle
#

ommgg lmaoo

sharp bough
#

what does the * do in config.get() ?

sullen dome
#

wdym

wraith rapids
#

probably nothing

sharp bough
#

i saw it once a guy using config.get("example.*")

sullen dome
#

i guess a typo

#

nvm

wraith rapids
#

that doesn't look like it should do anything useful

glass sparrow
#

gets all keys

sullen dome
#

probably like config.get(key.<vlaue>)

#

see, even i mistype stuff

#

vlaue

wraith rapids
#

to get all keys, you should getConfigSection and getKeys

glass sparrow
#

yeah thats what i do but you dont have to

sullen dome
#

or is the * returning a list or smt

wraith rapids
#

that's my guess

sullen dome
#

bit like @a in mc

wraith rapids
#

never seen anyone do that or even mention that

sullen dome
#

same

pale hazel
#

Does the PlayerInventory class have the methods where i can place an item in a specific slot.

#

of the inventory

sullen dome
#

PlayerInventory#setItem(slot);

pale hazel
#

Thanks bro!

sullen dome
#
FileConfiguration config = YamlConfiguration.loadConfiguration(file);
config.set(uuid.toString(), permission);
config.save(file);

does this actually save the Config?

(Testing it would take much time, so please don't tryItandSee' me)

eternal night
#

tbh try it and see

sullen dome
#

god you got it dude

eternal night
#

but yes

#

this should write the entire config to file

#

including the updated uuid key permission value set

south onyx
#
@EventHandler
    public void onInteract(PlayerInteractEvent e) {
        if (e.getItem() == null || tracker == null) {return;}
        if (!e.getItem().equals(tracker) || !stalkers.contains(e.getPlayer().getUniqueId())) {return;}
        Player stalker = e.getPlayer();
        if (runner != null) {
            Player blockrunner = Bukkit.getPlayer(runner);
            CompassMeta compassMeta = (CompassMeta) tracker.getItemMeta();
            if (compassMeta != null && blockrunner.getWorld() == stalker.getWorld()) {
                compassMeta.setLodestoneTracked(false);
                compassMeta.setLodestone(blockrunner.getLocation());
            } else {
                stalker.sendMessage(ChatColor.LIGHT_PURPLE + "You cannot track the runner because he isn't in the same world as you!");
            }
            tracker.setItemMeta(compassMeta);
        } else {
            stalker.sendMessage(ChatColor.DARK_AQUA + "There is no runner to track!");
        }
        
    }
sullen dome
#

it's an api, so i would have to implement it in a plugin first lol.

question was only like, if config.save(file); does act the same like saveConfig();

south onyx
#

when there is a stalker and the runner is null it prints there is no runner to track

#

so that works

#

but when there is a stalker and a runner, it doesnt track the runner

eternal night
#

Well saveConfig internally just calls save(File) on the FileConfiguration that represents the config.yaml file

sullen dome
#

oh nvm

#

then my bad haha

eternal night
south onyx
#

its a compass itemstack

eternal night
#

but you never give that stack to the player o.O

south onyx
#

i do

eternal night
#

the itemstack and item meta are not consistent through spigot

south onyx
#

there is a command

eternal night
#

no

sullen dome
#

no

eternal night
#

after giving them that item stack

sullen dome
#

you have to re-apply it

south onyx
#

huh

sullen dome
#

that's why people use ItemBuilder's

eternal night
#

it no longer "syncs" with the item stack you passed in

sullen dome
#

you are modifying the meta

#

but you're not re-applying the meta to the stack

south onyx
#

tracker.setItemMeta(compassMeta);

sullen dome
#

^

eternal night
#

yes, that is your single item stack defined somewhere

sullen dome
#

right at the end

south onyx
#

i did that

eternal night
#

but it only matters when you add the item to a players inventory

#

all modifications after that do not modify the item in the inventory

south onyx
#
if (Bukkit.getOnlinePlayers().toString().contains(args[i])) {
                                    stalkers.add(Bukkit.getPlayer(args[i]).getUniqueId());
                                    Main.main().tracker = new ItemStack(Material.COMPASS);
                                    Bukkit.getPlayer(args[i]).getInventory().addItem(Main.main().tracker);
                                } else {
                                    invalidPlayers.add(ChatColor.RED + args[i]);
                                }
#

i add the item to the players inventory using a command

sullen dome
#

yeah

eternal night
#

read

south onyx
#

once i do the command i trigger the event

eternal night
#

what we are saying

sullen dome
#

you have to re-apply the meta to the stack, then the stack to the player

south onyx
#

oh

sullen dome
#

because the player-existing stack is still the old one

south onyx
#

so after i put the item meta

#

i have to give them the item again?

wraith rapids
#

almost all get operations in bukkit clone the thing you get

sullen dome
#

you re-apply the stack to the player, yeah

south onyx
#

ok

wraith rapids
#

meaning that modifying the thing you get doesn't change the original thing

south onyx
#

why tho

wraith rapids
#

that's just how it works

eternal night
#

how would that work over a server restart in your case lol

wraith rapids
#

there is a reason for it but it's kind of complicated

#

and somewhat dumb

wispy monolith
#

Hi

eternal night
#

spigot just magically tracking all items that were created from your tracker variable ?

wraith rapids
#

if you get an item from an inventory, you're actually getting a copy of it instead of the actual item

eternal night
#

lol

wraith rapids
#

if you get meta from an item, you're actually getting a copy of it rather than the actual meta

south onyx
#

oh ok

sullen dome
#

that's pretty much the same like this:

   s = "i'm a String!"

that's not updating it in the map

south onyx
#

oooooh

#

ok

#

thx

wispy monolith
#

after I used maven and tried to compile the plugin everytime it says in the console couldn't find main class: <class path in plugin.yml>

wraith rapids
#

your plugin.yml is in the wrong directory

wispy monolith
#

it's in resources

sullen dome
#

then it's right

wraith rapids
#

put it in the jar manually with winrar or something, i don't know

sullen dome
#

do you use intellij? if yes, use the MCDev-Plugin

#

maybe you screwed something up

eternal night
#

but the plugin.yml needs to exist in order for it to complain about not finding the main class 🤔

eternal night
#

yeah, that isn't your issue

#

lol

#

have you opened your jar file and investigated ?

#

content wise

wraith rapids
#

wait what are we talking about

sullen dome
wraith rapids
#

oh right you're the guy who has the main package name issue

#

i told him to look and send a screenshot and unless I'm blind the class path and the value in plugin.yml are both correct

#

i don't know why it doesn't find it

mortal hare
#

why minecraft realms is a thing

#

lol

sullen dome
#

probably for the same reason, my #getDataFolder() returned null like a year ago

wraith rapids
#

to scam kids out of their parents' money

sullen dome
#

nobody knows EyeShakeNew

mortal hare
#

its like saying we're hosting the servers, but its way worse than hosting

wraith rapids
#

it's the hands-free solution

#

you don't need to do anything

sullen dome
#

well, because they still think that people buy realms

wraith rapids
#

because you can't fucking do anything

sullen dome
#

because they're dumb

wraith rapids
#

people do buy realms

mortal hare
#

on bedrock that's understandable because you cant always host a server on a the specific platofrm

sullen dome
#

who tf buys realms lmao

mortal hare
#

but on pc

#

wtf

wraith rapids
#

the absolute number of 12 year old pimplish fucks that play on realms is insane

sullen dome
#

i think realms is like the inbuild twitch streaming-feature
almost nobody ever used it

south onyx
#

what even is the point of realms

wraith rapids
#

lots of kids do

sullen dome
#

servers

mortal hare
#

to have a LAN party

#

but for monthly fee

south onyx
#

cant u just do that with a server

sullen dome
#

without hanging around with dumb hosters like Bisect etc

south onyx
#

like a free server

sullen dome
#

idk what the pricings of realms are tho

south onyx
#

i think its like 10 bucks a month

wispy monolith
#

My code is is in src/main/java/<my package>/<the class>

wraith rapids
#

like if you look it up on reddit or some other tard infested site, you will find massive boards and communities full of normies who play exclusively on realms

mortal hare
#

$7.99 USD per month.

wraith rapids
#

and think it's the shit

sullen dome
mortal hare
#

i can find a VPS

#

for that price

wraith rapids
#

iirc they rent from like amazon aws or something

sullen dome
south onyx
wraith rapids
#

so the performance isn't very good

south onyx
#

never tried it

sullen dome
#

but why do hosters like Bisect exists?

mortal hare
#

``Realms is build upon the Amazon EC2 cloud, it'll be one of these standard instances:

``

sullen dome
#

or zap

#

or nitrado

wraith rapids
#

it's literally just a scam

#

scamming retards is fine

sullen dome
#

because people don't want to hang around with that stuff

wraith rapids
#

that's natural selection

#

but scamming kids goes beyond the line for me

#

that's capitalism

sullen dome
#

rockstar games in a nutshell