#help-development

1 messages · Page 780 of 1

rotund ravine
#

My statement still stands

tender shard
#

or for multi module maven, see blog post above

wet breach
#

They contain different versions of thr same classes. Mc when you map it doesnt name most of the classes differently. Instead of having multiple classes all slightly named something different or one class with a million imports you can instead create a single manager class and reference the class needed for the version dynamically if the project is setup with modules. You could take this a step further and compile for a specificc version instead and get the appropriate class that is needed.

storm crystal
rotund ravine
#

My statement still stands

storm crystal
#

What is it actually used for

tender shard
#

things that the API doesn't offer, e.g. spawning NPCs without third party libraries

#

direct NBT access

#

like serializing entities and stuff

#

sending certain packets to players without protocollib

#

reading the server's TPS

#

stuff like that

storm crystal
#

Not that I know what any of those mean xd

tender shard
#

then you don't need it

rotund ravine
#

Just ignore it for now

storm crystal
#

But Id assume I dont need it as for now

quaint mantle
#

thats it

rotund ravine
#

I’d love to touch mojang

wet breach
#

Nms is where you access the server jar code instead of the api. You can call some things directly or manipulate code with reflection. You only do this because you need something that the api doesnt provide but the server code does. Spigot tries to keep things as vanilla as possible and doesnt touch everything either

tender shard
#

mojang is underaged

rotund ravine
tender shard
#

but they reached age of consent in may this year

#

so you're fine

rotund ravine
#

Good

storm crystal
#

💀

tender shard
#

one is enough for now

storm crystal
#

Thats out of relevance

tender shard
#

AoC is 14 in germany anyway, which is a bit... questionable

rotund ravine
#

We’re talking about a company

#

Not a child

tender shard
#

it's notch's child

#

then microsoft adopted it

rotund ravine
#

Though i’ll probably need to touch a lot of children as a nurse. Professionally of course

tender shard
#

ah so you touch children for money

rotund ravine
#

Easy money

tender shard
#

hehe

rotund ravine
#

Their parents offer them to me

storm crystal
#

Could we move away from topic of aoc and touching children/whatever altogether 💀

rotund ravine
#

Hmm

tender shard
#

my bf is a nurse too but he only touches mentally ill people at work. is that a better topic?

#

ok back to NMS

#

you don't need it

rotund ravine
#

Ohh, I got my mental illness clinical coming up

#

This monday to next year

storm crystal
#

Maybe if it was a different channel

rotund ravine
#

We finished ur topic

#

Let us have our fun

tender shard
#

many people went to psychiatry after looking at mojang's code

#

so this is quite on-topic

storm crystal
rotund ravine
#

Bruh looking at people asking questions on spigot forums and here is the same

#

Mental IQ getting lowered 🥲

#

Ask a question instead of bashing kiddo. We’ll answer questions

tender shard
#

yeah where's your question

storm crystal
#

What parts of spigot is lambda used in

tender shard
#

e.g. World#spawn

rotund ravine
#

Anywhere it makes sense

storm crystal
tender shard
#

or all the scheduler methods

#

that take a consumer<bukkittask>

rotund ravine
#

That’s like asking where is integer addition used

storm crystal
#

Whats consumer

tender shard
#

a consumer is a functional interface that takes in one parameter and returns nothing

#

it's like a Function<T,Void>

storm crystal
#

Cant you just make void

rotund ravine
#

Mfnalex with his java academy

tender shard
#

When you want to spawn a custom entity, e.g. with a custom name or certain items equipped, you must use the method World#spawn(Location, Class, Consumer) unless you give a shit about compatibility with other plugins. I’ll explain why. The shitty way Usually, you can easily spawn entities like this: That is fine, as...

#

here's an example of a consumer<entity>

spare hazel
#
@EventHandler(ignoreCancelled = true)
    public void onBlockDropItem(BlockDropItemEvent e){
        if(HypixelSkillCore.getInstance().getPlayer(e.getPlayer().getUniqueId()).getLastBlockBroken() == Material.LIGHT_BLUE_WOOL){
            doStuff(e);
        }
    }```
this must surely work
storm crystal
#

Self advertisement damn

tender shard
#

https://blog.jeff-media.com/understanding-lambdas-and-method-references/ and here's an explanation on what lambdas actually are

Lambdas and Method references can be used to make your code way shorter, and (sometimes) more readable by getting rid of anonymous classes. What are Anonymous Classes? Anonymous classes are like local classes without a name. Imagine you have the following code: We hereby declare and instantiate a class implementing java.lang.Runnable that just p...

rotund ravine
#

Alex

tender shard
#

Jan

rotund ravine
#

Set up some adsense so you got an actual reason to selfadvertise

spare hazel
#

IT WORKSSS LETS GOOOOOOOOOOOOOOOOOOOOO

storm crystal
#

Cant I just normally spawn entity at location

tender shard
storm crystal
#

Like why would I need something that returns void

tender shard
rotund ravine
#

Don’t bother with lambdas if u don’t know where to use them

#

?learnjava

undone axleBOT
tender shard
rotund ravine
#

How many times have this been posted to you?

tender shard
#

so you can return null and declare it as Future<Void>

rotund ravine
#

Future<Unit>

#

Jkjk

storm crystal
#

But why does it need something to return

tender shard
#

because it's a generic interface

#

it is universally usable to be able to return anything

rotund ravine
#

I wanna see how patient alex is, can u tag me when u give up?

tender shard
#

dw I have to pick up my bf from work in a few minutes

#

then I'm gone anyway

rotund ravine
#

Ahh

storm crystal
#

So consumer just returns void?

hybrid spoke
#

wait, yes

tender shard
hybrid spoke
#

just like every void method

spare hazel
#

how can i get an item's nbt data

tender shard
storm crystal
#

What happens if I do World().spawn(location, class, something that returns not void)?

rotund ravine
#

No compilo

hybrid spoke
#

is he trolling or actually trying to figure out

spare hazel
rotund ravine
#

Well i branded him as a troll ages aho

tender shard
spare hazel
rotund ravine
#

Huh

tender shard
#

no but there's sth in BukkitUnsafe or however it's called

storm crystal
tender shard
#

yes, PDC would be the way to go

storm crystal
#

For it

tender shard
#

ok bb gotta pick up my stupid bf now

spare hazel
#

alr but i HATE creating new NameSpacedKeys

rotund ravine
#

Bye

#

That’s a weird thing to hate

storm crystal
rotund ravine
#

Yep

storm crystal
storm crystal
#

You can just call it and input what value of said key you want

storm crystal
spare hazel
storm crystal
#

💀

hybrid spoke
rotund ravine
#

It would work fine as a constant or enum. Since it’s a thing that doesn’t need a new object

remote swallow
rotund ravine
#

The mentally ill guy

remote swallow
#

Yeah which

tender shard
#

the one who only works at the clinic

hybrid spoke
#

i have a feeling that alex's life is like a rtl episode

tender shard
#

not the one I met as patient in the clinic

remote swallow
#

Leon or the other one

tender shard
#

get your facts straight

#

leon

storm crystal
tender shard
#

leon is working at the clinic

remote swallow
#

Sus

tender shard
#

felix was a patient at the clinic and got thrown out with me

rotund ravine
#

It’s a sad life some trolls have

#

Poor Felix Ries

tender shard
#

I should write a book about my life, I'm sure my parents wouldn't want to read it

storm crystal
remote swallow
#

Sex, found out ur gay, sex, sex

rotund ravine
#

Should i get drunk and write some shit plugin tonigjt

quaint mantle
# storm crystal What happens if I do World().spawn(location, class, something that returns not v...

@storm crystal Simply works like this

interface Consumer<T> {
  void consume(T input);
}
// Other
interface NeedValue<T> {
  T get();
}

Class that want the consumer

public class MyClass {
  public void lol(Consumer<String> e) { e.consume("e") }
  public void print(NeedValue<String> e) { System.out.println(e.get()) }
}
public class Main {
  public static void main(String[] args) {
    // You do:
    new MyClass().lol( (input) -> { /* Do something */ } );
    new MyClass().print( (e) -> { return "Yes!!" } );
  }
}
hybrid spoke
rotund ravine
#

NeedAValue lol

storm crystal
rotund ravine
#

Provider desu

hybrid spoke
rotund ravine
storm crystal
#

Not a single idea how to understand interface and ->

rotund ravine
#

Don’t fry

#

Try

#

Take a programming / java course

hybrid spoke
storm crystal
#

I mean I can just not use it for now

rotund ravine
storm crystal
#

Yeah I think I can just spawn mobs and then give them custom stuff I dont really care about plugin compatibility

#

Since I have just one plugin

rotund ravine
#

Eh

#

What does that have to do with anything

storm crystal
#

That I can ditch forementioned stuff for now

hybrid spoke
#

ive had an idea of making custom space ballons

#

planets with their moons and shit

storm crystal
#

Kinda stinks to learn something I wouldnt find use of

hybrid spoke
#

or a blackhole ballon which, if too long taken out, explodes into a supernova

rotund ravine
#

It’ll need to be a 1 day thing hmm

hybrid spoke
#

hm

rotund ravine
storm crystal
#

Is it possible to make stuff like dungeon generator with preset rooms?

chrome beacon
#

Yes

storm crystal
#

Like in TBoI

hybrid spoke
#

why wouldnt it

#

is it me or is discord dying

storm crystal
#

Idk what capable are plugins of

hybrid spoke
#

with a lot of creativity everything is possible

rotund ravine
storm crystal
#

Im pretty limited in this sense xd

hybrid spoke
#

or both combined

#

a tower defense where you can gamble your gained coins

#

that would be cool

rotund ravine
#

Seems like more than a days work if it needs to look good lol

hybrid spoke
#

then get a few shots more

spare hazel
#

how to create a custom enchant book? like efficiency 6

rotund ravine
#

Look for unsafe

#

On the javadoc

quaint mantle
spare hazel
#

how to create a normal enchant book?

#

?jd

undone axleBOT
hybrid spoke
hybrid spoke
quaint mantle
#

99.99% uptime lmao

spare hazel
storm crystal
#

if I have class that manages PDCs (two methods for setting them or retrieving their value) should I keep them non static?

hybrid spoke
#

sounds like a util class so no, make them static

storm crystal
#

Should I declare namespacedkey outside of them and assign value in methods?

#

Or do I just keep declaring inside methods

quaint mantle
# spare hazel like mending I
ItemStack book = new ItemStack(Material.ENCHANTED_BOOK, 1);
EnchantmentStorageMeta meta = (EnchantmentStorageMeta)book.getItemMeta();
/* Stuff */
storm crystal
#

Whats up with those (Player) and such

#

How is it named and what does it do

rotund ravine
#

Casting

#

It casts

storm crystal
#

Casts what

quaint mantle
#

object?

storm crystal
#

Okay but what does casting mean

eternal oxide
#

Player extends HumanEntity, so you can cast a HumanEntity to Player

rotund ravine
#

If it's a player that is

eternal oxide
#

yep

quaint mantle
# storm crystal Okay but what does casting mean

Here we go:

class MyParentClass { public void hello() {
  System.out.println("Hi!");
} }
class MyChildClass extends MyParentClass {
  @Override
  public void hello() {
    System.out.println("Yooo!");
  }
}
public class Main {
  public static void main(String[] args) {
  MyChildClass child = new MyChildClass();
  child.hello(); // output Yooo!
  MyParentClass parent = (MyParentClass) child;
  parent.hello(); // output Hi!
  }
}
rotund ravine
#

I was lazy, so here is ChatGPTs try on answering your questions @storm crystal

In Java, casting and inheritance are two fundamental concepts related to object-oriented programming that allow you to work with classes and objects in a flexible and polymorphic manner. Let's discuss each concept separately:

  1. Casting:
    Casting in Java is the process of explicitly converting an object or a value from one data type to another. It is often used when working with inheritance and polymorphism to access the methods and fields of a subclass or a more specific type from a reference of a superclass or a more general type. There are two types of casting in Java:

    a. Upcasting (Implicit Casting):
    Upcasting is when you cast an object from a subclass to a superclass. It is done implicitly by the Java compiler and does not require any explicit casting. For example:

    // Superclass
    class Animal {
        void eat() {
            System.out.println("Animal is eating.");
        }
    }
    
    // Subclass
    class Dog extends Animal {
        void bark() {
            System.out.println("Dog is barking.");
        }
    }
    
    public class Main {
        public static void main(String[] args) {
            Animal animal = new Dog(); // Upcasting
            animal.eat(); // Accessing the superclass method
        }
    }
    

    In this example, we cast a Dog object to an Animal reference, and we can call the eat method on it.

    b. Downcasting (Explicit Casting):
    Downcasting is when you cast an object from a superclass to a subclass. It is not done implicitly by the Java compiler and requires explicit casting. It is used when you want to access the methods or fields specific to the subclass. If the object is not an instance of the subclass, it may result in a ClassCastException. For example:

    public class Main {
        public static void main(String[] args) {
            Animal animal = new Dog();
            Dog dog = (Dog) animal; // Downcasting
            dog.bark(); // Accessing the subclass method
        }
    }
    

    In this example, we first upcast a Dog object to an Animal reference, and then we downcast it back to a Dog reference to access the bark method.

  2. Inheritance:
    Inheritance is a fundamental concept in object-oriented programming that allows you to create a new class (subclass or derived class) based on an existing class (superclass or base class). The subclass inherits the attributes (fields) and behaviors (methods) of the superclass, allowing for code reuse and creating an "is-a" relationship. In Java, you use the extends keyword to indicate that a class is inheriting from another class.

    For example:

    // Superclass
    class Vehicle {
        void start() {
            System.out.println("Vehicle is starting.");
        }
    }
    
    // Subclass
    class Car extends Vehicle {
        void accelerate() {
            System.out.println("Car is accelerating.");
        }
    }
    

    In this example, the Car class inherits the start method from the Vehicle class. This is an example of single inheritance in Java, as a subclass can only inherit from one superclass.

In summary, casting in Java allows you to work with objects of different types, especially in cases of inheritance, and inheritance is a mechanism that promotes code reuse by creating a hierarchical relationship between classes.

storm crystal
quaint mantle
#

😭

storm crystal
#

Cuz it doesnt sound so abstract

#

I just see right away how I can utilize it

storm crystal
#

Provides either vague or not completely true answers

rotund ravine
#

Well we're not your chatgpt or googling substitute

quaint mantle
rotund ravine
#

Player extends HumanEntity

storm crystal
#

He once disrespected 2nd law of thermodynamics when I asked him question

#

So I dont trust him no more

quaint mantle
#

oh

storm crystal
rotund ravine
#

Bruh

storm crystal
#

Kinds breaks the point of it

rotund ravine
#

?google

undone axleBOT
rotund ravine
#

?learnjava

undone axleBOT
rotund ravine
#

What do you think these are for

storm crystal
#

Well you overuse it all the time so anger management measure?

chrome beacon
#

We don't over use it

#

we use it when we feel like it's necessary

storm crystal
#

I went for entire w3schools course and there was no casting

#

So I assumed its rather spigot thing

chrome beacon
#

It's not

pastel axle
#

w3schools is terrible and you should never use it for serious work

storm crystal
#

I was told to "go learn fundamentals"

#

So I did

rotund ravine
#
chrome beacon
slender elbow
#

what a surprising turn of events

chrome beacon
#

It uses primitives as examples

storm crystal
quaint mantle
storm crystal
#

How am I supposed to know it can work on a custom data type

chrome beacon
#

You should look at different tutorials

#

Not all of them cover everything

#

If you want something that does cover all the basics in detail you can read Introduction to Java Programming and Data Structures by Y. Daniel Liang

storm crystal
#

Any course equivalent of that

chrome beacon
#

🤷‍♂️ I never took a specific course to learn Java

slender elbow
#

apparently jetbrains academy is pretty good

chrome beacon
#

Your best option is probably to go take a few different ones

storm crystal
chrome beacon
#

Well it's 1700 pages of pure knowledge

#

It will cover everything you need to know and a bit more

storm crystal
#

That isnt helping for sure

#

Sole reading would take like 3 weeks if not more

chrome beacon
#

Well yeah

#

You don't learn a new programming language in a day

storm crystal
#

Id burn out on 1/5th of way

chrome beacon
#

and you especially don't learn programming in a day

#

It comes with a bunch of exercises to keep you occupied and interested

storm crystal
#

I mean at worst Id be missing out on a few fundamental things at this point so might as well take a random course and skip what I know

storm crystal
slender elbow
#

for which you need to know some basics; plugin making isn't exactly day-1-beginner friendly

storm crystal
#

Well I did it and so far im doing okay

storm crystal
# rotund ravine lol

Blame school and being forced to read ~30 books about literature I totally dont give a shit about to pass one exam

hushed spindle
#

gonna ask it again just in case, but does anyone have a method to check if a player is standing on a block? Player#isOnGround() is deprecated and doesn't link to a replacement, checking the block under the player doesnt account for sneaking on the edge of a block and might also not work if the block isn't a full block.

#

i was thinking of doing 4 tiny raytraces off of the corners of the player's bounding box, downwards, to see if they collide with anything but that seems like a pretty absurd way to do it

smoky anchor
chrome beacon
hushed spindle
#

then another one through the middle idk lol

tender shard
#

lmao a friend just messaged me

Then like this: We now have a fairly comprehensive commercial software called CIMPLIFY. Written in C#, UI with Windows Forms and database in SQL (if that makes sense). I can rate the work of my three programmers under me as zero because I have no idea about programming myself. If I were to sit down now, book courses and learn programming for 10 hours a week, when would I be able to estimate whether a new module would cost 30 or 300 hours of programming?

chrome beacon
#

Only one ray cast required uwu

hushed spindle
chrome beacon
#

It's deprecated because the client controls the value

#

If that's fine then you can use it

hushed spindle
#

in my case it would allow people spoofing that value to mine at normal speeds while in mid air which can be jank

#

ill try that raycast solution thanks man

rotund ravine
#

I mean

#

Just get highestblock, is solid, is play within a reasonable height above it

storm crystal
tender shard
rotund ravine
#

Great

tender shard
#

i especially find it funny that he thinks he could know it better with learning coding 10hours a week than someone who does coding for a living

rotund ravine
#

Tell him to outsource to you

quaint mantle
rotund ravine
#

20$ an hour and you’ll grade one project every 2 hours.

hushed spindle
#

just hire some fellas from india

rotund ravine
#

Yepyep

tender shard
#

I wouldn't touch windows forms for 300€ an hour

sullen wharf
#

it sucks

tender shard
#

accurate

sullen wharf
#

WPF is solid tho

rotund ravine
#

First gif that pops up

quaint mantle
#

I thought people use c# because of how easy to create fancy UI(s) on windows.

rotund ravine
#

C# is ugly

hushed spindle
#

its easy sure but its also kinda terrible

#

cant really call it fancy

storm crystal
#

Is there any programming language other than java used for plugins?

quaint mantle
#

Anything on top of jvm

quaint mantle
rotund ravine
#

Is a favourite

#

Though there is a ton of funny implems for things like python or other language to run plugins

#

I wonder if i should write some plugins in clojure for fun

quaint mantle
#

Dont use other languages exept java if you making plugin api

rotund ravine
#

I can have java code for the endpoint no worries

slender elbow
#

CLOJURE!!!

rotund ravine
#

It’s ugly as hell

slender elbow
#

wtf no

rotund ravine
#

Wtf yes

#

You remind me of an ol’ paper pal ahaha

storm crystal
#

Whats the difference in dependency and api terms cuz i get them confused

rotund ravine
#

Well

#

How do you get them confused? Most dependencies have an API you interact with

#

Not all though

quaint mantle
#

api is source code.
dependency is object.

#

thats it

hazy parrot
#

Not really

storm crystal
#

You make dependency out of api?

rotund ravine
#

I thought he meant spigot dependencies

#

Which type of dependency are we talking about

storm crystal
#

Dependency in general

quaint mantle
#

object

worldly ingot
#

The term just means your code is dependent on something

#

It's a required thing

hushed spindle
#

im probably being dyslexic here but i dont understand how to use this method, BoundingBox#rayTrace() that is. like what does start represent

rotund ravine
#

Math 🥲

hushed spindle
#

math is interesting as shit but why does it have to be so confusing

rotund ravine
#

I quit math 1,5 years ago

tender shard
hushed spindle
#

yeah but like of what

chrome beacon
worldly ingot
#

Think of it not like the bounding box is ray tracing, but rather the bounding box is a collidable object

#

Consider it something like a World#rayTraceBoundingBox()

storm crystal
#

Math is confusing cuz people dont know how to teach it properly

hushed spindle
#

so the entire bounding box becomes the raytrace am i getting that correct

worldly ingot
#

No no

#

You're casting a ray from the given start position in the given direction and seeing if it ever collides with that bounding box

tender shard
# tender shard true

same applies to everything. If you cannot explain something in 3 easy sentences, you haven't understood it yourself

rotund ravine
#

3 sentences, you mean 1 sentence and a citing

hushed spindle
#

hm

storm crystal
#

Can I make methods that manage config static?

tender shard
#

iirc there's a book that's like 300 pages long but it's only one sentence

tender shard
storm crystal
#

To not make instances

hushed spindle
#

why avoid making instances

tender shard
#

what's the advantage

storm crystal
#

Less code

tender shard
#

good luck

rotund ravine
#

You still need to make the first instance what

#

There’s zero profit

storm crystal
tender shard
#

they don't

storm crystal
tender shard
#

both can use the same instance

rotund ravine
#

?di

undone axleBOT
storm crystal
#

And then use static methods

#

Do i not understand something

tender shard
#

why would you create an instance in the first place if you want to make the methods static o0

hushed spindle
#

if you're wanting to make a single instance of a class like a manager or whatever you can make it singleton ig

storm crystal
#

He told me to do it

rotund ravine
#

What

#

Yes

tender shard
#

?learnjava

undone axleBOT
tender shard
#

someone needs to fix those links

storm crystal
ancient plank
rotund ravine
#

@ivory sleet fix

storm crystal
#

Cant I just import static methods and use them

ivory sleet
#

Can’t we let the new oranges do that?

#

@young knoll

quaint mantle
# storm crystal Less code

If you always be one config for all plugin then yes. If you have sperate configs you should not use static method/fields at all.

hybrid spoke
storm crystal
tender shard
storm crystal
#

As in use parameter for it

tender shard
#
- asd
- asd
  • asd
  • asd
    instead of
#
  - asd
  - asd
#
  • asd
    • asd
rotund ravine
#

Add some more too

ancient plank
#

They look normal on my phone, except for the first one ty for telling me I'll do nothing about it for the next hour

rotund ravine
#

Someone in here decided they were all useless for some reason

tender shard
rotund ravine
storm crystal
#

So when do I want to make method static and when make instance in main class and pass it further

rotund ravine
#

Never use static 💪🏻

storm crystal
#

Why?

hybrid spoke
#

only use static 🦾

rotund ravine
#

OOP

quaint mantle
storm crystal
#

So why is static a thing

rotund ravine
#

We want no static

quaint mantle
#

cause i didn't think injecting it everywhere

tender shard
rotund ravine
#

Static is the bane of us all

quaint mantle
#

would be worth it

rotund ravine
#

Static needs to die

#

Go bury it

tender shard
# storm crystal So why is static a thing

Many people are going crazy whenever they see the static keywoard inside some source code. That’s ridiculous, because it alleges the people who developed Java were totally stupid. It is true that the static keyword gets abused by many people, but there’s a difference between static abuse and proper use of the keywoard. What does...

rotund ravine
#

Banned death threats

tender shard
#

static = member of class
non-static = member of instance

hybrid spoke
#

i love deadly static electricity

rotund ravine
#

Static = death jkjk

hushed spindle
#

you need to minecraft game over

rotund ravine
#

Jokes on you i use kotlin

storm crystal
#

How do I tell if i need instance

rotund ravine
#

Go befriend a creeper

tender shard
quaint mantle
#

Java should add keyword "singleton" before "class"

hybrid spoke
tender shard
#

dw, he will eventually

rotund ravine
#

@hybrid spoke Eat glass

tender shard
rotund ravine
#

Step on a lego

hushed spindle
#

maybe you should try to stop being singleton

storm crystal
hybrid spoke
tender shard
rotund ravine
#

Companion objects is where it is at 💪🏻

tender shard
#

?learnjava!

undone axleBOT
quaint mantle
rotund ravine
#

Sugar

#

Not sulfaf

hybrid spoke
#

even worse

tender shard
#

sulfur glass

storm crystal
#

Wait wasnt a field a variable

storm crystal
#

Why is it even named like that

hybrid spoke
#

love how fast the conversation turned into hatespeech

rotund ravine
#

companion object {}

tender shard
opal carbon
#

ngl maybe its just me but kotlin coroutines are more confusing than completablefutures

storm crystal
#

Field term is confusing as fuck

echo basalt
#

merge it with #general

rotund ravine
#

Coroutines are not completable futures

sullen wharf
tender shard
#
class MyClass {
  String thisIsAField;

  public void doSth() {
    String thisIsALocalVariable = null;
  }
}
sullen wharf
#

that shit's a whole ant nest

storm crystal
#

Its too similar to fields in physics

opal carbon
hybrid spoke
#

go to paper

#

you're welcome

storm crystal
rotund ravine
#

A field is owned

opal carbon
rotund ravine
#

VirtualThreads are almost here

tender shard
storm crystal
#

What makes one a field and one not

rotund ravine
#

Ownershio

hybrid spoke
#

promise thisWillBeTrue = mybool == true;

tender shard
rotund ravine
#

promise glass

tender shard
#

the place where it's declared

hybrid spoke
#

no it will be true, i promise

storm crystal
#

And what is a field that variable isnt

rotund ravine
tender shard
undone axleBOT
rotund ravine
#

Ownership

hybrid spoke
#

its the keyword, not me

#

it promises

opal carbon
#

imo kotlin is rust but worse

tender shard
#

whut

storm crystal
#

By class or what

rotund ravine
#

Rust is great wtf

#

Rust and kotlin are leet language

opal carbon
#

exactly

#

rust is good

tender shard
#

pls just read the JLS

opal carbon
#

kotlin tries to be it but sucks

hazy parrot
#

Kotlin literally doesn't have any features rust is famous for xd

opal carbon
rotund ravine
#

Kotlin isn’t shitty lol

#

Smh

#

Have you seen skript

hazy parrot
rotund ravine
#

Jkjk

#

Zacken

storm crystal
opal carbon
tender shard
#

kotlin isn't shit

tender shard
#

the full one

storm crystal
hushed spindle
# chrome beacon player location to vector

sorry to bother again but im really not understanding this method, it checks if the given start vector intersects the bounding box right? how can that be used to determine if the player is standing on something?

tender shard
rotund ravine
#

I fixed it

hybrid spoke
storm crystal
tender shard
chrome beacon
rotund ravine
#

Fist fight us two

chrome beacon
#

then get the result if you hit anything

storm crystal
#

Why reading entire thing would do anything about one section

hushed spindle
#

so the direction is a downwards vector yes?

chrome beacon
#

yes

hushed spindle
#

ive done that and it always returns a null raytraceresult

rotund ravine
#

Come to denmark i can’t leave due to uni

#

Fyn aarup

hybrid spoke
#

remember guys, dont troll convo while someone needs help

rotund ravine
#

Mfnalex will be referee

tender shard
#

the part where he lives in, obviously

chrome beacon
tender shard
hushed spindle
storm crystal
hushed spindle
#

im probably being rather silly and dumb but i cant tell whats going wrong

hybrid spoke
rotund ravine
#

Sry Athlaeos

hybrid spoke
hushed spindle
#

i dont remember man

#

it came from eclipse thats all i know

rotund ravine
#

Shit zacken

hushed spindle
#

i likes it

ancient plank
#

?learnjava @tender shard

undone axleBOT
tender shard
#

great

#

fixed

rotund ravine
#

It’s fixed

hushed spindle
#

now we can stop panicking

tender shard
#

finally I can learn java

opal carbon
#

thanks catgirl

rotund ravine
#

Remove the discord

hybrid spoke
#

remove zacken

tender shard
#

remove stains with vanish oxy action

ancient plank
opal carbon
#

go to papermc if you want civilized behaviour

eternal oxide
#

lol

tender shard
#

lol

opal carbon
#

well mostly

smoky anchor
# hushed spindle

@chrome beacon if this is what you suggested, it will fail on edges of blocks
You'd have to "raytrace" the whole player bounding box instead of a ray

nvm, this traces the bounding box, doesn't it

Also, use normalized vector instead of -0.1 on y

hybrid spoke
rotund ravine
eternal oxide
#

paper is toxic

opal carbon
rotund ravine
#

I am banned from there

hybrid spoke
#

+1

tender shard
#

you too?

scenic onyx
#

?paste

undone axleBOT
rotund ravine
#

They felt i was transphobic

opal carbon
#

see thats the spigotmc spirit

tender shard
#

I got banned for a soundcloud link

opal carbon
#

you go champ

rotund ravine
#

Nice

chrome beacon
hybrid spoke
#

i got banned for helping people with log4shell

smoky anchor
rotund ravine
#

Purpur and here is the only place i engage in mc community

scenic onyx
opal carbon
#

you dont

tender shard
#

volt?

#

what the hell is volt

hybrid spoke
#

what does stack do

tender shard
#

tell us how it went

tender shard
scenic onyx
tender shard
#

well then you take the current selection, loop that amount of times, and paste it into the looking direction with an offset of selectionWidth*iteration where the width is the width into the direction you are copy/pasting to

opal carbon
#

apparently ive somehow managed to send 372 messages in paper without being banned???

#

feels like a glitch in the matrix

tender shard
#

I managed to send over 220k here and only got banend once here

opal carbon
tender shard
#

by mistake

rough drift
#

endLocation.sutract(origin).toVector(); gives me the direction vector, though if I set a player's direction to this it seems to make them always face up?

rotund ravine
#

Search for my messages

opal carbon
#

nobody gives a shit here

opal carbon
hybrid spoke
#

banned me for nothing

scenic onyx
opal carbon
rotund ravine
#

Wrong emoji

tender shard
opal carbon
rotund ravine
#

@quaint mantle from:jantuck

#

I wanna know what my last ones were

hybrid spoke
#

Lol Lol Lol Lol

rotund ravine
#

So transphobic

worldly ingot
#

I mean I don't really think there's any reason to be trolling in the Paper Discord. Seems rather unprofessional and ultimately makes us look worse

#

Doesn't really matter

rotund ravine
#

Spigot is living

opal carbon
#

lets see if i get banned

#

ya never know with paper mc

rotund ravine
#

Smh

shadow night
hushed spindle
#

i aint hear no bell

eternal oxide
#

wrong locations

worldly ingot
#

The direction is always relative to those two points so if the origin is below endLocation, the difference will be upwards

#

If you want to ignore the y value, set the resulting vector's y axis to 0

rough drift
#

the difference is 1 block on the y

worldly ingot
#

The direction will be normalized for you so no need to worry about that

storm crystal
#

so can I just make it static and import separate methods that Id need?

eternal night
#

🙃

young knoll
#

Yo 30% stake is a fair amount

#

Assuming the server gets more than 3 sales

rough drift
#

0.30c

rotund ravine
#

Don’t take stake

rough drift
#

LOL

rotund ravine
#

Go ask somewhere else lol

#

Ahaha

eternal night
storm crystal
eternal night
#

pass the FileManager instance to the constructors of classes that need it instead

storm crystal
#

but at this point why not make it static

#

what would be a difference?

rotund ravine
#

We’ve tried to say it lynx. Good luck

eternal night
#

static state just becomes ugly quickly

#

ah

#

then I won't waste my time on this 😅

storm crystal
hybrid spoke
#

you just got cockblocked

glad prawn
#

why static, quick access? 🤓

storm crystal
#

?

hybrid spoke
#

cries inside

eternal night
#

Static state just means you "guess" your state is initialised

#

You hope that when you call FileManager.something, your onEnable properly called whateveer init function you have

#

hence, instead, you pass around an instance. The fact that the instance exist should usually promise that it is ready for usage

storm crystal
#

but wouldnt doing it constructor method also make me hope that it makes it correctly?

eternal night
#

Well no because that constructor has to run

#

otherwise you cannot have an instance of FileManager

storm crystal
#

cant I just initialize it on enable and it would be practically the same thing?

eternal night
#

Yea

#

hence why I said, it might be fine for a config accessor but like

#

its more about a general design choice

#

learning to keep things not-static and how to properly use OOP is a fundamental you need to be comfortable in

#

so while you might get away with static here, you certainly won't in other cases

#

so why use something that has really, not advantage here outside of not passing it to the like, 5 classes sthat need the instance in a constructor

storm crystal
#

idk someone else earlier told me that I can use static

#

so I tried to do it properly

eternal night
#

Yea like you can use static certainly but in general it is not something you strive for in object oriented development in java

storm crystal
#

fine

ancient plank
eternal night
#

Thank you I love cookies 🥰

vital vortex
#

if i have spigot 1.16.5 and update the java version to java 18 what happends?

rotund ravine
#

Maybe it works

#

Maybe it doesn't

eternal night
#

spigot will probably not let you run it

rotund ravine
#

I can't recall if spigot 1.16.5 recognizes it

eternal night
#

Doubt it ? 😅

#

but yea, try and see

vital vortex
#

i mean if it dosent works what have i to do?

rotund ravine
#

Update spigot

young knoll
#

I think 1.16.5 only accepts up to 16

#

Maube 17

eternal night
#

probably yea NODDERS

young knoll
#

Downstream has a flag to bypass that don't they

eternal night
#

Yea

young knoll
#

Wonder if MD would accept that as a PR

eternal night
#

Well I think we just yanked the entire check these days

vital vortex
#

how can i make it 100% works? Because i need plugins like exellent creates on my 1.16.5 spigot

eternal night
#

idk what the reason was for it

#

generally people running versions that might not be supported

#

like ASM needs updating for new versions

young knoll
#

Yeah that's basically it

ancient plank
#

Huh I thought the flag was a spigot thing tbh

young knoll
#

--IReallyKnowWhatImDoingISwear2

storm crystal
#

should I keep EventHandlers and other un-annotated methods that I use in other classes together?

young knoll
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.

storm crystal
#

like I register events via main class and pass it's instance to other classes and use it's methods

rotund ravine
#

The Listener should not have that many methods.

vital vortex
#

how can i make it 100% works? Because i need plugins like exellent creates on my 1.16.5 spigot

#

and other payed plugins

rotund ravine
#

@vital vortex Don't repeat yourself.

young knoll
#

Well

#

Bypass it through whatever means

#

And then test it

#

Keep a backup of course

vital vortex
storm crystal
vital vortex
#

i'm scared

rotund ravine
#

Move that method up to somewhere else

vital vortex
#

Found server.jar

===============================

Default Java

===============================

openjdk version "18.0.2" 2022-07-19

OpenJDK Runtime Environment (build 18.0.2+9-61)

OpenJDK 64-Bit Server VM (build 18.0.2+9-61, mixed mode, sharing)

Unsupported Java detected (62.0). Only up to Java 16 is supported.

rotund ravine
vital vortex
#

it dosent works

storm crystal
vital vortex
#

ok

storm crystal
#

if I keep it

vital vortex
#

i was thinking like the server were spamming errors and all willl be crashed

rotund ravine
#

@storm crystal I tell you to go do a java course agian

#

Oh no

ivory sleet
vital vortex
#

if i update the spigot version from 1.16.5 to 1.18 will i lose all the files?

storm crystal
rotund ravine
#

I didn't tell you to move th event handler

#

I told you to move the helper method in there if you want to use it elsewher

#

e

storm crystal
rotund ravine
#

I see

vital vortex
#

the spigot 🔛 🔝

#

❤️ spigot ❤️

rotund ravine
#

Placing anything large is extensive

young knoll
#

40 blocks isn't that much

#

Probably more on the chunk loading

#

Take a spark report and check

vital vortex
#

did something like viaspigot exsist?

young knoll
#

?

hybrid spoke
#

viaversion 🤔

vital vortex
# young knoll ?

like if i have java 17 and want a plugin for java 18 i can with viaspiogot

young knoll
#

Nope

echo basalt
#

dragonproxy hm

young knoll
#

If you are a little bit technical you can easily edit out the java check from spigot

young knoll
#

Build spigot with buildtools, remove the check in Craftbukkit, and then rebuild it

vital vortex
#

i dont understand

#

i need exellentcrates plugin

#

but it cant be loaded

#

[15:15:00 ERROR]: Could not load 'plugins/ExcellentCrates-5.0.0 (3).jar' in folder 'plugins'

#

[15:15:00 ERROR]: Could not load 'plugins/NexEngine.jar' in folder 'plugins'

young knoll
#

There will be more than that

#

?paste

undone axleBOT
young knoll
vital vortex
vital vortex
rotund ravine
#

We don't want ur files

vital vortex
#

and i have to upload it as a .txt

eternal night
#

?paste

undone axleBOT
rotund ravine
#

It's a plugin issue

vital vortex
storm crystal
#

Do hypixel's variations of basic enchants like sharpness work the same way as in vanilla or did they make custom variants as well?

rotund ravine
#

Look at the link i posted lol'

eternal night
#

I doubt hypixel relys on any vanilla logic for their enchantments

#

would be rather bleh to implement a shit load of custom enchantments and then have a couple of outliers for enchants that exist in vanilla

storm crystal
#

They dont really rely on any vanilla logic right?

eternal night
#

¯_(ツ)_/¯

#

I presume they optimized a lot, so I guess not much

storm crystal
#

Like even custom crafting table

rotund ravine
#

I think everything is custom or almost so over there

storm crystal
#

Didnt you block me

glad prawn
#

unblock

rotund ravine
#

Unblock what

hybrid spoke
rotund ravine
storm crystal
#

?learnjava!

undone axleBOT
glad prawn
#

this also needs fixing @ivory sleet

rotund ravine
#

@ancient plank

ivory sleet
#

@lost matrix

#

^

rotund ravine
#

@young knoll

young knoll
#

On it

remote swallow
#

ping choco

storm crystal
#

@remote swallow

remote swallow
#

@worldly ingot

young knoll
#

?learnjava!

undone axleBOT
remote swallow
#

Wow you actually fixed it

young knoll
#

Idk if it's possible to keep the gif but remove the link

#

But yeah

hasty prawn
#

:O new helpors

remote swallow
#

How does that take 2min but plugin stuff takes 2 days

young knoll
#

I mean it's literally one command

#

Do we still have some of the old versions commands

#

?1.17

undone axleBOT
young knoll
#

yep

remote swallow
#

Update bootstrap

young knoll
#

?bootstrap

undone axleBOT
#

Bootstrap Jar
The main spigot-1.18.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-1.18-R0.1-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.

Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163

young knoll
#

What about it

remote swallow
#

The main spigot-1.18

river oracle
#

that's when it became bootstrap

young knoll
#

I can change it to be more generic

remote swallow
#

People are dumb miles

young knoll
#

Bootstrap Jar
Since 1.18 the main spigot.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-<version>-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.

Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163

#

somethin like that

remote swallow
#

Perfect

ancient plank
#

%s

young knoll
#

hm?

remote swallow
#

Adele ur pfp is still catgirl

hushed spindle
#

its not a phase

#

dad

ancient plank
#

the pfp change was not related to the uwu speak

remote swallow
#

But its true

hushed spindle
#

thats just how it is sometimes

#

the people you love and care about turn into furries

#

you have joe biden to thank for that

rotund ravine
#

@ancient plank @hushed spindle Seems to love and care about you

slender elbow
#

The New Society™️

hushed spindle
#

fuck no

slender elbow
#

the us 💀

rotund ravine
#

I considered moving to the Us after my education

#

But it pays less than norway

#

and norway is easier

hushed spindle
#

you should move to norway its much better than america

rotund ravine
#

I am in denmarkj

#

haha

hushed spindle
#

im sorry for your loss

rotund ravine
#

Ikr

hushed spindle
#

and im sorry you're not sweden

rotund ravine
#

Sweden is worse than norway in payment to nu rses

old cloud
#

best payment is printing

hushed spindle
#

also finland is basically the superior scandinavian country just saying

#

funny little language for funny little people

rotund ravine
#

How much do you pay your nurses? @hushed spindle

hushed spindle
#

lemme check

#

bout 3900 euros monthly

ancient plank
hushed spindle
#

but it ranges quite heavily from 1800 to 6200

#

also not from scandinavia im from the netherlands lmao

rotund ravine
storm crystal
#

Sweden is defo more dangerous to live in

hybrid spoke
#

isnt sweden very nice

#

want to move there in a few years

storm crystal
#

No

opal carbon
hybrid spoke
#

beautiful landscape, beautiful women. what else do you need

scenic onyx
#

?paste

undone axleBOT
hushed spindle
#

depends on what you compare it to

scenic onyx
#

I want duplicate the //stack of WordEdit. Beacuse the "void distance" dont go?

hybrid spoke
#

and what are the downsides of sweden?

hushed spindle
#

sweden by global standards is still rather nice

hybrid spoke
#

i live in germany so shouldnt be any different

rotund ravine
hybrid spoke
#

okay so plan b, cayman islands

rotund ravine
#

I think their healthcare is more like ours than yours tho @hybrid spoke

hushed spindle
#

move to the netherlands we got lots of bikes and racism

hybrid spoke
rotund ravine
#

Denmark

#

So more government less work oriented

hybrid spoke
#

i mean germany has one of the best healthcare

#

only positive of germany

hushed spindle
#

why did germany have to get rid of nuclear

#

like damn

hybrid spoke
#

germany dropped everything so noone is scared of us lol

#

and we are scared to build back up

hushed spindle
#

i think the school system is fucked in general

#

like globally

hybrid spoke
#

no not really

#

i mean the school system in general is fucked

#

but you can get into good schools by doing good

#

actually your elementary teachers recommend you if you are above average

scenic onyx
remote swallow
wet breach
ancient plank
remote swallow
#

kek

hushed spindle
#

i think i do a whole lot of not having a particular opinion about them

wet breach
#

but you said we have biden to thank for furries

hushed spindle
#

yes

river oracle
#

I think that was a joke

hushed spindle
#

joe biden put chemical in the water supply that turn children into furries

#

well known fact

wet breach
#

doesn't sound much like liking there, so it means you don't like them

hushed spindle
#

hey maybe you want people turning into furries

#

could be a good thing depending on who you ask

wet breach
hushed spindle
#

im just stating a well known fact that joe biden is the creator of many furries

river oracle
#

he chipped us all with the vaccine so he could track how many furries he created

hushed spindle
#

yeah exactly

opal carbon
#

i love vaccine

hushed spindle
#

i didnt feel like becoming a furry so i drank a magnetic lead potion that removed the furry chips

wet breach
hushed spindle
#

the lead makesm y brain tiklcle

river oracle
#

that's where the vaccine chip comes in

wet breach
hushed spindle
#

thats why they banned leaded gasoline

#

it made people immune to being furries

#

thats why furries literally dont exist during that time period

rotund ravine
#

I mean the uptick happened after the exposure

wet breach
hushed spindle
#

its fact look it up

river oracle
#

legit

#

its in the government databases

hushed spindle
#

what do you think that whole mkultra thing was about

#

not just mind control but furry femboy research

kind hatch
opal carbon
#

:3

river oracle
hushed spindle
#

its public look it up

kind hatch
#

I made the chips.

#

I'm secretly joe biden

river oracle
hushed spindle
#

actually the government has all the dnas that exist because somehow a whole lot of dna from men is flushed down the drain

ancient plank
#

I don't know how many people actually leave house without their phone

hushed spindle
#

strange how that happens

ancient plank
#

in 2023

rotund ravine
#

@sterile token come with some weird ideas

hushed spindle
#

i forgot to bring my phone one time and it very quickly made all the furry related thoughts go away

#

but then i got home again and they came back

opal carbon
#

i think uve been furrified

kind hatch
#

I think you just want to be furry at home.

hushed spindle
#

i still have my lead potions

#

to protect me

opal carbon
hushed spindle
#

ok fair

#

but i propose you this

#

free thought is an illusion its all controlled by the shadow government

#

i want nothing its all them

kind hatch
#

SHADOW WIZARD MONEY GANG

hushed spindle
#

we love casting spells

fallow violet
#

Hey guys, i got a questiooonnn sooo

If i have a cauldron and i want to set its level i use the new Levelled thingy but how can i set the material to lava or water? Im too dumb sorryyyyy

hushed spindle
#

set the block type to LAVA_CAULDRON or WATER_CAULDRON

fallow violet
#

wait thats a thing

#

nicee

#

thasnks

hushed spindle
#

yeah also regular cauldrons arent levelled any more so be sure to keep that into account

young knoll
#

I don't think lava or snow ones area either

#

Wait no lava is

#

Snow isn't

hushed spindle
#

i need to drink more lead the thoughts are coming back bye

fallow violet
#

wait lava is levelled? i mean how can u remove a level

young knoll
#

I thought it was

fallow violet
#

i dont know a survival way to remove a level ig...

hushed spindle
#

i dont think lava cauldrond are levelled no

young knoll
#

Nope

#

Water and snow are levelled

#

Lava is not

fallow violet
#

ooh yes

#

Another question right away, how can i get the item slot of a dispenser inventory in the blockdispenseevent when i just got the item and the dispenser but no slot or something

hushed spindle
#

i suppose you could compare dispenser contents before and after

#

or try indexof of the fired item on the dispenser inventory

zenith gate
#

Yeah I could, but changing numbers is a lot easier than that 😂

zenith gate
#

what would be a good delay for spawning mobs 1 per tick?

rotund ravine
#

?scheduler

#

Oh

#

Sure

#

1 tick seems fine

dry hazel
#

?scheduling

undone axleBOT
zenith gate
#

I know how to create a scheduler... just don't know what math to go with

dry hazel
#

you want to spawn 1 mob per tick, right?

zenith gate
#

That's the number im going with yep.

dry hazel
#

repeating task with a one tick interval

fluid river
#
Bukkit.getScheduler().runTaskTimer(pluginInstance, () -> {
    Location locationInstance = calculateEntitySpawnLocation();
    worldInstance.spawnEntity(locationInstance, EntityType.ZOMBIE);
}, 0L, 1L);```

also there should be clause which stops scheduler
storm crystal
#

Wouldnt that lag the shit out of server

fluid river
#

who knows

#

i mean after certain time yeah

#

but spawning 1 entity each tick is not that much trouble

vital vortex
young knoll
#

Probably the wrong version of ExcellentCrates

vital vortex
young knoll
#

You just did 4 minutes ago

vital vortex
young knoll
vital vortex
#

how can i record screen so i can let u see that?