#dev-general

1 messages ยท Page 551 of 1

prisma wave
#

well i guess java is already pretty fast so most of the time it's not necessary

#

but i imagine a lot of the graphics and sound libraries interact with lower level stuff

#

lwjgl for example which minecraft uses, is pretty much just a direct translation of a c(++) api (opengl)

timber oak
#

What is lwjgl for?

prisma wave
#

games

#

any 3d graphics ig

#

but mostly games

#

afaik the library provides a bit more than just opengl but that's kinda the gist of it

timber oak
#

Interesting

#

What makes C++ so fast though?

#

It is the fastest language I assume?

prisma wave
#

a combination of things

#

i mean

#

the "fastest" would be assembly or machine code, but that's kinda misleading

#

C and C++ are usually so fast because they compile directly to a native binary without anything extra such as a garbage collector

#

and also i think the compilers are pretty good at optimising

timber oak
#

C as in C# or what?

prisma wave
#

no

timber oak
#

Or is C something different?

prisma wave
#

just C

#

yeah

timber oak
#

Oh

prisma wave
#

C is the precursor to C++

timber oak
#

C# isn't very fast right?

distant sun
#

C - the original shit

prisma wave
#

C# is comparable to java

timber oak
#

Ye

prisma wave
#

so not slow, but not as fast as something properly native

timber oak
#

Very similar syntax also

prisma wave
#

yep

#

Microsoft Java

timber oak
#

lol ye

lunar cypress
#

Comparing speed like that on the surface level isn't that simple

old wyvern
#

๐ŸŒž

ocean quartz
#

Did it work Yugi?

prisma wave
#

more like microsoft ocaml

#

but yes

lunar cypress
#

Most JVMs for example have a just in time compiler and perform dynamic optimisations at runtime which are in many cases better than what can be done at compile time by C or C++

prisma wave
#

that's also true

old wyvern
#

I didnt test it yet matt, my classes just ended

ocean quartz
#

Ah okok ;p

old wyvern
#

I know this other language that can do more optimizations at compile time ๐Ÿ˜Š

prisma wave
#

๐Ÿ˜Œ ๐Ÿ˜Œ ๐Ÿ˜Œ ๐Ÿ˜Œ

#

did you know that ghc has flags for how many optimisations it can do

old wyvern
#

๐Ÿ˜ฎ

prisma wave
#

like you can make it do literally every possible optimisation

#

at the cost of build time ofc

old wyvern
#

I heard some of them break iorefs and such

#

like it sometimes inlines it harshly

prisma wave
#

yeah probably

normal talon
distant sun
potent nest
#

axolotls bad

steel heart
#

๐Ÿ˜”

#

Oh it got removed rip

hot hull
static zealot
hot hull
#

bruh what

static zealot
steel heart
#

Wait wtf

static zealot
steel heart
#

Thought that was a datapack

static zealot
#

it probably is xD

#

never tested lmao

steel heart
onyx loom
#

hey @ocean quartz how come triumph config doesnt have sources jar โ˜น๏ธ

steel heart
#

Matt monopoly epic fail

prisma wave
#

^

onyx loom
#

disgusting, unacceptable behaviour

distant sun
steel heart
#

No u

distant sun
#

is possible to put Something<T> into a collection that accept Something<?>?

potent nest
#

that should work fine

distant sun
potent nest
#

welp that's something different

distant sun
#

๐Ÿ˜ฆ

steel heart
#

Function<? super T, ? extends R> PES_Blush

distant sun
#
@FunctionalInterface
public interface ActionFunction<T> {

    Action<T> run(ActionMeta<T> meta);

}```
Easy
#

lol is the first time I see these tags

steel heart
#

Oh yeah same, what are those for :0

distant sun
steel heart
#

Ah

distant sun
distant sun
#

Is there any way to access the class of a generic (eg <T> void doStuff(ObjectHere<T> obj) without a Class<T> argument?

potent nest
#

not really

distant sun
#

So unfortunate. What about a method on an abstract class Class<T> getType(), that doesnt have to be overrided on each implementation? Or is this a similar scenario as above?

obtuse gale
#

Well you need to have a Class<T> to return in the first place

distant sun
#

Yes, I know, but I cant use T.getClass() =/

obtuse gale
#

That's why you still need a Class<T> object to return in the first place

#

It needs to be provided somehow

distant sun
#

Ah, I see what you mean. So is possible only on implementations since you have an actual object type rather a generic?

old wyvern
#

In the case its an abstract class, you kinda can

#

As long as the users make a strict implementation

obtuse gale
#

eh....

old wyvern
#

for eg

obtuse gale
#

is it the hacky thing TypeToken uses?

old wyvern
#

yea

#
abstract class Test<T> {
....
}
class B extends Test<Integer> {
....
}
#

With this you can

#
abstract class Test<T> {
....
}
class B<T> extends Test<T> {
....
}

With this you cant

distant sun
#

Yeah I use the first format

old wyvern
#

d; Class#getGenericSuperType

ruby craterBOT
#
public Type getGenericSuperclass()
throws MalformedParameterizedTypeException, TypeNotPresentException, GenericSignatureFormatError```
Description:

Returns the Type representing the direct superclass of the entity (class, interface, primitive type or void) represented by this Class.

If the superclass is a parameterized type, the Type object returned must accurately reflect the actual type parameters used in the source code. The parameterized type representing the superclass is created if it had not been created before. See the declaration of ParameterizedType for the semantics of the creation process for parameterized types. If this Class represents either the Object class, an interface, a primitive type, or void, then null is returned. If this object represents an array class then the Class object representing the Object class is returned.

Since:

1.5

Throws:

MalformedParameterizedTypeException - if the generic superclass refers to a parameterized type that cannot be instantiated for any reason
TypeNotPresentException - if the generic superclass refers to a non-existent type declaration
GenericSignatureFormatError - if the generic class signature does not conform to the format specified in The Javaโ„ข Virtual Machine Specification

Returns:

the direct superclass of the class represented by this object

old wyvern
#

You'll then need to check if its a parameterized type

#

d; ParameterizedType

ruby craterBOT
#
@@Deprecated(since="9", forRemoval=true)
public interface ParameterizedType
extends Type```
ParameterizedType has 5 methods, 1 extensions, and  1 super interfaces.
Description:

Represents an invocation of a generic class or interface. For example, given the generic interface List<E>, possible invocations include: List<String> A generic inner class Outer<T>.Inner<S> might be invoked as: Outer<Number>.Inner<String>

Deprecation Message:

The declarations in this package have been superseded by those in the package jdk.javadoc.doclet. For more information, see the Migration Guide in the documentation for that package.

Since:

1.5

obtuse gale
#

@@

#

lol

distant sun
#

Double deprecation

#

Ah yeah

#

I guess I will just live with overriding the method

old wyvern
#

You could also abuse a typetoken probably

old wyvern
onyx loom
#

ye it is i think

#

i remember seeing 2 @NotNulls before

#

and 2 @Nullables

obtuse gale
#

that's a javadocs thing in general too lol

onyx loom
#

o

obtuse gale
#

Hey Yugi, would you say it's safe to assume that any "consumer" functions (that take something but return nothing ("void")) are expected to have side effects?

steel heart
#

Sounds logical to me but me ainโ€™t no lambda monad guy

prisma wave
#

im fairly sure that any non-empty consumer function must have side effects

#

or at least i cant think of any valid consumer implementation without side effects

obtuse gale
#

lol nerd

prisma wave
#

shut up

#

"hEy YuGi"

steel heart
#

So Haskell got no consumers?

prisma wave
#

well

steel heart
#

Welllll

prisma wave
#

you could have something like a -> () but the only valid implementation would just be \_ -> (), i.e it ignores the argument and returns ()

steel heart
#

So basically a runnable?

prisma wave
#

runnables are implied to have side effects too

steel heart
#

Oh ofc

#

Void

prisma wave
#

a -> () can't

#

a -> IO () could

cinder flare
#

i mean what's the point of having a consumer that does nothing

prisma wave
#

for instance putStrLn is String -> IO (), so i guess you could view that as a Consumer<String>

obtuse gale
cinder flare
#

a function that takes arguments, returns nothing, and has no side effects is objectively pointless right

prisma wave
#

pretty much

obtuse gale
#

yeah

prisma wave
#

the unit value is all about pointlessness

#

in a way

ocean quartz
prisma wave
#

๐Ÿ™‚

#

and you enjoy it

obtuse gale
#

kinky

prisma wave
#

oh yes

old wyvern
#

lol

#

@ocean quartz shall I merge that pr? the actions seem to be passing

cinder flare
ocean quartz
#

I'll test it real quick

steel heart
#

Yugi slimjar for maven when

tired vector
ocean quartz
old wyvern
steel heart
#

Ah

#

Some dev reached out to me about it lol so ye just got curious

tired vector
old wyvern
#

Do you wanna give it a shot?

steel heart
#

Uh what do u write it in?

#

I guess itโ€™s basically loose copy paste from the gradle one?

old wyvern
#

The features yea, there might be slight difference due to the difference in API that maven provides

ocean quartz
steel heart
#

Ah true but itโ€™s in Java? OwO

old wyvern
#

I dont see a reason why it wouldnt work

steel heart
#

Aight give me a couple of days, what do you prefer?

old wyvern
#

I dont mind, use what feels right to you

steel heart
#

Java it is ASowyea

old wyvern
#

๐Ÿ’ฏ ๐Ÿ’ฏ

prisma wave
old wyvern
#

๐Ÿ˜ฎ

steel heart
#

Okay so like yes good mmm

frigid badge
#

lmao

old wyvern
#

Are you... insulting... rich hickey??!

prisma wave
#

clearly!

#

unforgivable!

cinder flare
old wyvern
#

!!!

cinder flare
#

maybe ill change my ways once i do some elisp lol

old wyvern
#

ellipse

prisma wave
#

ive not actually had to write much

#

i think it's only really needed for the super personal customisations

old wyvern
#

I wanna make a lisp for the fun of it

prisma wave
#

lisps are sick

#

have you used parsec?

cinder flare
old wyvern
#

Nope

prisma wave
#

yes or that lol

#

it's so cool

old wyvern
#

its the haskell lib right?

prisma wave
#

yeah

old wyvern
#

Ill check it out

cinder flare
#

i saw a cool video series on making your own doom emacs from scratch basically

#

like writing all the elisp, it looked very cool

prisma wave
#
parseList :: Parser Element
parseList = do
  _ <- char '('
  x <- ListElement <$> sepBy parseExpr spaces
  _ <- char ')'
  return x
#

i think i've seen that too lol

old wyvern
#

Fuck it, lets rewrite linux

prisma wave
#

๐Ÿ˜Œ

#

and you can combine parsers with <|>

#
parseExpr :: Parser Element
parseExpr =
  parseString
    <|> parseAtom
    <|> parseNumber
    <|> parseList
    <|> parseVec
    <|> parseQuoted
#

it's so cool

old wyvern
#

Yea haskell actually works perfectly for this usecase tbh

prisma wave
#

definitely

#
parseNumber = do
  nums <- many1 (digit <|> char '.')
  if '.' `elem` nums
    then return $ FloatElement $ read nums
    else return $ IntElement $ read nums
#

such a cool library

old wyvern
#

like its almost backus naur

#

so very close

#

except with extra stuff ofc

prisma wave
#

almost

#

yeah

cinder flare
prisma wave
#

yeah lmao

#

whatever works

#

couldnt think of a better way of doing it

old wyvern
#

xD

steel heart
prisma wave
#

is this valid yaml?

old wyvern
#

looks like it

#

actually no

prisma wave
#

aw man according to a parser it's not

old wyvern
#

the key needs to be a string I think

prisma wave
#

๐Ÿ˜ฆ

#

yeah

#

rip

#

that was gonna be so cool

old wyvern
#

You can use json

cinder flare
#

yeah was gonna say

#

don't think an array can be a key

prisma wave
#

but json is ugly

#

not user friendly

cinder flare
#

TOML

old wyvern
#

Its just a few extra braces

cinder flare
#

a few lmao

prisma wave
#

and quotes everywhere

old wyvern
#

๐Ÿคท

#

Maybe you need...

#

KORM

prisma wave
#

๐Ÿ˜ญ

old wyvern
#

Looks like that could work

cinder flare
#

just write a custom lisp interepretation

prisma wave
#

i mean if it was me i'd do ```clj
{[1 2 3] {:type RED_STAINED_GLASS_PANE }}

#

but thats also not very user friendly

old wyvern
#

Why not have haskell configuration like xmonad? ๐Ÿ˜Œ

prisma wave
#

tempting

cinder flare
#

how about ```haskell
do => monad monad
1 2 3 <==> RED_STAINED_GLASS_PANE
monad monad

prisma wave
#

๐Ÿฅด

cinder flare
#

as you can see, we've progressed as a species

prisma wave
cinder flare
#

we now use monad monad instead of brackets

old wyvern
cinder flare
#

so wait did sx like die or something

prisma wave
#

in theory

cinder flare
#

i know he left the community

old wyvern
#

He left everything

cinder flare
#

but did he leave developing entirely?

old wyvern
#

Probably not

prisma wave
#

doubt it

old wyvern
#

I assume alt account

cinder flare
#

ahhh

prisma wave
#

last i checked he was working for some big server

cinder flare
#

maybe he renamed himself to::: Brister Mitten! ๐Ÿ˜ฎ

prisma wave
#

probably telling them about how good kotlin is

#

๐Ÿ˜ฎ

old wyvern
#

And then one day all of a sudden he left that

#

he was working on a youtubers server

prisma wave
#

oh yeah he got banned and clip left on the same day

#

they had some massive argument

old wyvern
#

Yea about the api changes sx did

prisma wave
#

yeah lmao

old wyvern
#

He instantly broke like hundreds of expansions

prisma wave
#

he broke a bunch of shit in a minor update

#

๐Ÿ˜‚

cinder flare
#

damn we lost two bois on the same day

#

that is very sad

old wyvern
#

Well

prisma wave
#

yeah i mean clip joined back

old wyvern
#

clip rejoined after a day

prisma wave
#

but it's not like he's active

old wyvern
#

yea

cinder flare
#

did he really tho

#

yea

#

man what would a haskell syntax be for like a deluxemenus clone

#

isn't that what you're making?

old wyvern
#

What?

prisma wave
#

i wish

#

i just want customisable guis for a commission

prisma wave
#

trying to think of a nice way of doing it

cinder flare
#

ah

#

we should make a DM fork that uses haskell notation

prisma wave
#

i'd love to

#

but work comes first

old wyvern
#
gui = [
   [stick, glass, glass],
   [stick, glass, glass],
   [stick, glass, glass],
]
cinder flare
#

damn imagine getting paid to do stuff

#

i could never

prisma wave
#

i pretty much have to

#

i have no money left and ive booked a trip to london next week

#

sooo

#

pretty much praying that this dude isnt gonna scam me

cinder flare
#

well yeah my point was more that nobody would hire me

prisma wave
#

oh lmao

cinder flare
#

not really that I don't want to lmao

prisma wave
#

they probably would

#

as long as u can make something that works

cinder flare
#

awww

#

i've made a few things that work i think

prisma wave
#

thats enough for most people

cinder flare
#

i mean look at my jithub!

old wyvern
#

ez money

cinder flare
#

yeah I saw that lol

old wyvern
#

lol

obtuse gale
#

and there's people in #off-topic saying they have DMs off

#

lol

prisma wave
#

lmao

cinder flare
#

ayyy

old wyvern
#

lol

#

Ping spam them

obtuse gale
#

they already did ๐Ÿ˜‚

old wyvern
#

lmao

cinder flare
#

did you see the guy whose range of payment was $0 to $25

#

ah he changed it to $1 lmao

obtuse gale
#

but yeah most people just want something that works so don't bother in quality (:

#

jk

distant sun
obtuse gale
#

I mean

cinder flare
#

capture capture gang

obtuse gale
#

yeah

#

you're getting it as <?, ?>

distant sun
#

yeah ik

cinder flare
#

also I have literally no clue what that function does

distant sun
#

it is a supplier that returns a new instance of a Node<>

obtuse gale
#

it parses a node

#

what's nodes?

distant sun
#

private final Table<String, Class<?>, Node.Supplier<?, ?>> nodes = HashBasedTable.create();

#

hm, I might rename them to Component

#

Node is kinda meh

cinder flare
#

man you are speaking another language man

#

so much so that I said man twice in that short sentence

obtuse gale
#

sheesh

distant sun
#

Im opened to suggestions, im not too experienced with generics

cinder flare
#

all these question marks, whatever a HashBasedTable is

#

suppliers and stuff, crazy

obtuse gale
cinder flare
#

lmao

half harness
#

@SuppressWarning("all")
๐Ÿ˜Œ

distant sun
#

:))

distant sun
obtuse gale
#

lmao

half harness
#

-_-

cinder flare
distant sun
#

d;guava Table

ruby craterBOT
#
public interface Table```
Table has 21 methods, 5 implementing classes, and  1 sub interfaces.
Description:

A collection that associates an ordered pair of keys, called a row key and a column key, with a single value. A table may be sparse, with only a small fraction of row key / column key pairs possessing a corresponding value.

The mappings corresponding to a given row key may be viewed as a Map whose keys are the columns. The reverse is also available, associating a column with a row key / value map. Note that, in some implementations, data access by column key may have fewer supported operations or worse performance than data access by row key.

The methods returning collections or maps always return views of the underlying table. Updating the table can change the contents of those collections, and updating the collections will change the table.

All methods that modify the table are optional, and the views returned by the...

This description has been shortened as it was too long.

Since:

7.0

obtuse gale
#

Row and Column

#

smort

distant sun
#

ikr

cinder flare
#

damn why don't we make GUIs using these bad boys

obtuse gale
#

๐Ÿคจ

distant sun
#

lol star

cinder flare
#

what

#

oh well i guess you only need indices for a gui

#

nvmd

obtuse gale
#

already did

ocean quartz
obtuse gale
#

japan

prisma wave
#

i have just found about about "spicetify"

#

this makes me extremely happy

forest pecan
#

Welcome to the korm fields

#

Also isnโ€™t that Kotlin object relation mapping or something

#

And Sxtanna made it right lol

cinder flare
#

ye

#

it was linked above lol

forest pecan
#

Oh lol

prisma wave
#

yes

#

sxtanna json

#

but look at this!!

#

i can finally have pretty r/unixporn stuff with spotify

forest pecan
#

Hot

prisma wave
#

very hot

cinder flare
#

inb4 spotify bans spicify like discord banned betterdiscord lol

prisma wave
#

then i will stop using spotify

cinder flare
#

i really wish there was a good desktop apple music player

#

or that they had an api third party programs could implement ๐Ÿฅฒ

prisma wave
#

ha

#

you expect too much from apple

forest pecan
#

โ€œiTunesโ€

#

Thatโ€™s what Masked said he listens to

cinder flare
#

well on macos they have the Music app

forest pecan
#

๐Ÿ˜ซ

cinder flare
#

which is actually not too shabby

forest pecan
#

Is there a SoundCloud app

cinder flare
#

uyh

#

probably not

#

who knows, maybe I just start downloading my music

#

probably won't take up that much space anyways

#

i have 4.3GB of music on my phone and that's like, every song I listen to

old wyvern
cinder flare
#

if BM is a man of integrity, that's xmonad and xmobar

#

and honestly a damn good use of screen space

prisma wave
#

sorry star

cinder flare
#

damb

#

maybe I can convert you after I get my setup

prisma wave
#

maybe

#

im not a big customisability freak tbh

#

i prefer things that work out of the box

#

well

#

i know xmonad does too

#

but that's specifically designed to be 100% super customisable

cinder flare
#

i mean that's why you just steal someone's config

prisma wave
#

true

cinder flare
#

then you tweak just a little

#

and it's perfect

prisma wave
#

ยฏ_(ใƒ„)_/ยฏ

#

might as well use i3 at that point though

cinder flare
#

and you're not locked into a shitty status bar ๐Ÿฅฒ

#

i mean but the principle

prisma wave
#

true

cinder flare
#

as a haskell enthusiast

#

they might revoke your haskell membership for using i3 if you're not careful eyesintense

prisma wave
#

im sure they'd understand

#

yknow

#

sure haskell is nice

#

but

#

i3 does everything i need it to and i cba to move over

old wyvern
#

ah

cinder flare
#

hmm dats true

#

though I hear xmonad has really good multi screen support

#

since you can tell stuff to move by monitor instead of by workspace and other things

#

and, having 3 monitors myself, that is of utmost importance to me lol

prisma wave
#

neat

obtuse gale
#

ah yes, the pinnacle of software engineering

steel heart
half harness
cinder flare
#

i have retreated back to the safety of Arch

#

Gentoo requires too much forethought and planning and I change my mind like every hour, which is faster than Gentoo can recompile all my stuff

#

also I hate boot managers with a passion

#

Back to Arch ๐Ÿ˜Œ

obtuse gale
#

Too much lighting

cinder flare
#

what, my keyboard?

#

it's not that annoying in person

#

just looks really bright in the pics cause there's not a lot of lighting in my room

#

string lights and all

obtuse gale
#

Almost had a heart attack

cinder flare
#

nah you good

obtuse gale
#

๐Ÿ˜Ž

cinder flare
#

hey bm

#

guess who has xmonad installed right now

static zealot
#

yugi?

cinder flare
#

doom emacs is being setup as we speak

static zealot
#

k

cinder flare
#

k sorry just thought bm would be happy for me ๐Ÿ˜ฆ

static zealot
#

well he's clearly not. he's too busy playing overwatch

#

with Sx

obtuse gale
#

Not if I stop him

#

@prisma wave

static zealot
#

@prisma wave

#

@pallid gale idk if you know this but BM still has the TRusted role xD

#

I just noticed

#

it

prisma wave
#

wat

static zealot
#

wait @cinder flare why don't you have the developer role again?

static zealot
obtuse gale
#

Because he ain't a developer

prisma wave
obtuse gale
#

sad Star noises

static zealot
#

xD

static zealot
cinder flare
#

i installed doom emacs okay

#

i think that's enough

pallid gale
static zealot
#

wait I said trusted?

cinder flare
#

yeah not sure what Blitz is on about

static zealot
#

fuck. I meant helpful

#

my bad

cinder flare
#

besides hurting my feelings

pallid gale
#

u can have both?

static zealot
#

oh

#

ok then

#

nvm

cinder flare
#

hey can I get mine back

#

i had it originally remember

pallid gale
#

gotta be helpful for that

#

kek

static zealot
#

when you gave me staff u took out the helpful. xD

cinder flare
#

i literally was ๐Ÿ˜ฆ

static zealot
#

=xp

compact perchBOT
static zealot
#

read the background card

#

ty

cinder flare
#

oh damn he's got a point

pallid gale
#

leaked our dms

#

so bad

static zealot
#

at least I'm helpful xd

cinder flare
#

can i auto-obtain the developer role due to my contributions to notable projects such as Barry and PAPI

static zealot
#

anyways since you took it for everyone just thought its like an upgrade helpful -> support -> trusted or something like that

cinder flare
#

damb

#

where's mr piglet

static zealot
#

well

#

you can just make the request

#

but there's a queue

cinder flare
#

yeah exactly

#

ill just go straight to the source

static zealot
#

and when I say a queue I mean like a black friday type of queue

#

xD

#

like the us walmart black friday queue

cinder flare
#

nah black friday is lame now

#

there's too many people and the prices aren't good at all

#

walmart ain't what it used to be smiling_face_with_3_tears

static zealot
#

well idk. it was never like that here. never actually had to sit in a queue for black friday. and never had people trample eachother

cinder flare
#

well you see

#

the average weight of an american is probably twice what it is for romanians

#

you guys can't even afford minecraft

#

how can you afford food, free time to trample people, and walmart delicacies

static zealot
#

yeah. the last one is even harder to afford bcz we don't have walmart

cinder flare
#

exactly

ivory hare
#

Hi

#

So , im developing a plugin

#

and i have a player that is mounted on an armour stand

#

however if they press shift they easily get off

#

how do i prevent that

static zealot
#

isn't there an entity dismount event or something like that you can cancel?

ivory hare
static zealot
#

d;spigot EntityDismountEvent

ruby craterBOT
#
public class EntityDismountEvent
extends EntityEvent
implements Cancellable```
EntityDismountEvent has 1 all implementations, 6 methods, 1 implementations, and  1 extensions.
Description:

Called when an entity stops riding another entity.

ivory hare
#

Oh

#

damn

#

thank you

ivory hare
#

I have this right now , how to i cancel the event

#

sorry im new to development

dense dew
#

@eventhandler
public void onsomeevent (entitydismountevent evrnt) {
//you can do if something
event.setcanceled(true) }

compact perchBOT
#
๐Ÿ“‹ Your paste: lemanuh
https://paste.helpch.at/obejotijay

A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.

static zealot
#

@timber oak it means its declared per class. not per instance. so yeah I guess what you said is kinda true

timber oak
#

Oh, deleted the message because I thought it was wrong after I wrote it lol

#

I now understand the disadvantages though

#

Oh wow it actually makes so much sense now lol

frail glade
errant geyser
#

Is there a reason for Java version numbers being 44 above their name? For example, Java 6 is 50, Java 16 is 60 and so on

steel heart
#

I believe there was a lot of versions early on like Java 1 or smtng

#

Or class versions

#

Whatever itโ€™s called

humble silo
#

?paste

compact perchBOT
#
FAQ Answer:

Paste Services
When asking for help with a config/menu/code issue please use our paste bin:
(we prefer it over pastebin.com)
โ€ข HelpChat Paste - How To Use

rich ridge
#

hi im searching for developers for my minecraft server dm me if you're intreseted

obtuse gale
jovial warren
#

hey, I know this may seem a bit generic, but would any of you have any idea why a task would run perfectly fine sync on startup, but just hang for ages and do nothing running on a ThreadPoolExecutor with (Runtime.getRuntime().availableProcessors() - 1).clamp(1, 8) threads?

#

I'm just looking for some possible reasons why that could even happen in the first place

#

can provide much more context if necessary

prisma wave
#

Needs more context I imagine

#

It's probably not the thread pool's fault, meaning it's probably the task doing something wrong

jovial warren
#

a.k.a me doing a PEBKAC

#

basically, what this system does is loads a bunch of resources from files and then applies them

#

the BACKGROUND_EXECUTOR is meant to do the loading part of that process, and then that second Runnable::run there is the syncExecutor, which is used to do the actual application

#

as you can see, it has to first create the loader that will actually do the loading, and then grab the load task with a CF, which is executed on the background executor, then the reload is done on the sync executor

#

omfg why

#

ofc the one line I looked at and went "eh, probably just a decompiler error" was actually the one that fixed it all

#

in SimpleReloadInstance's init function, we have a mutable future reference, and the code also takes an immutable reference to that inside of the forEach that it uses for the thenCombine, well, I was using the future reference instead of making that immutable reference, and adding the immutable reference seemed to fix everything

#

of fucking course it did

obtuse gale
#

Anyone done some rust with oxide?

timber oak
#

Kotlin vs Java for plugins?

#

Or am I misunderstanding kotlin

sly sonnet
#

i think its personal preference

#

there are plugins made in kotlin only

static zealot
#

or made in both

timber oak
#

But the libraries made in java only works for java right?

#

Or what

static zealot
#

no

cloud hedge
#

Can i get a developer to help me for a plugin im willing to make its really tough so please help me

old wyvern
cloud hedge
#

They wont anwser because they wont do free work

obtuse gale
#

asking in the wrong channel isn't very well seen here either

timber oak
obtuse gale
old wyvern
#

๐Ÿ˜ฎ that worked!!

#

๐Ÿ˜Œ

steel heart
timber oak
#

I keep forgetting, the java 16 requirement for 1.17+ is just on server side right? Or is it also client-sided?

distant sun
#

both

timber oak
#

But you can play 1.17 with just Java 8 installed?

#

So minecraft installs java 16 itself?

distant sun
#

yes it does install java 16

timber oak
#

Where is that installation located though?

#

The version that minecraft installs

distant sun
#

Idk

forest pecan
#

In the oracle thing you know in the program files

timber oak
#

Not there

#

This kinda confuses me

#

So java is installed within the minecraft jar?

steel heart
#

It installs an appropriate jdk if needed

forest pecan
#

OpenJDK superior

timber oak
obtuse gale
#

probably in the launcher dir or the default game dir

steel heart
#

Thought it was in user/jdk or user/.jdk PES_SadShrug

obtuse gale
#

not the one MC uses by default

#

it doesn't install it

#

it downloads one from their servers and saves it in the launcher dir I believe

steel heart
#

Ah okay

onyx loom
old wyvern
#

Nah

#

IJ's ones are installed separately along with IJ files

#

"Jetbrains Runtime"

forest pecan
#

Spring framework isnt that big right?

#

isnt it only like a couple megs

#

i always hear people joking around how large it is lol

humble silo
#

thats defintely not small

#

and do you mean just the core part or all of spring boot/the starters?

onyx loom
#

its definitely alot bigger than 3kb spigot plugins ๐Ÿ’€

cinder flare
#

i mean depends on how many parts you have

#

you can really load em up

humble silo
#

looks like the core is around 2mb

#

Didnt know how many they had

onyx loom
#

spring... good...?

old wyvern
#

Yes ๐Ÿ˜Œ

obtuse gale
#

โ€ฆasses

half harness
#

๐Ÿคฃ

old wyvern
#

reminds of this

obtuse gale
#

Lmfao

hot hull
#

I love when people post in offer services, and not link any sort of previous work

old wyvern
#

๐Ÿ˜Œ

distant sun
#

with .htaccess, how can I redirect only / to a new url? But other redirects like /discord won't be affected?

hot hull
#

Yes

boreal needle
#

somebody please send help

#

generics are driving me crazy

steel heart
#

Try pass the type ? super V to Condition maybe

prisma wave
#

๐Ÿฅด

steel heart
#

Assuming the test() takes U, V

distant sun
#

@frigid badge you are a genius sometimes

#

Idk when but I bet you are!

frigid badge
#

no for real don't use .htaccess, just edit your nginx config's

distant sun
#

Ok

prisma wave
#

should java records be used everywhere possible?

#

intellij often suggests converting things to records but i always got the idea they were supposed to be for DTOs and things

old wyvern
#

oh I swear I keep forgetting those exist

prisma wave
#
public class YamlObjectLoader implements ObjectLoader {
    private final Yaml yaml;

    @Inject
    public YamlObjectLoader(Yaml yaml) {
        this.yaml = yaml;
    }

    @Override
    public Map<Object, Object> load(Path source) throws IOException {
        return yaml.load(Files.readString(source));
    }
}

``` like this clearly isn't for data representation but it could be a record
old wyvern
#

same bm, intellij is not recommending it

prisma wave
#

it does for me

old wyvern
#

uh maybe im doing something wrong

#

one sec

prisma wave
#

Records are classes that act as transparent carriers for immutable data
Doesn't really seem appropriate

old wyvern
#

I have sdk set to 16 and language level at experimental

prisma wave
#

huh

old wyvern
#

Unless this cant be one?

prisma wave
#

seems like it could

old wyvern
#

weird

quiet depot
#

ij is just fuken stupid with records

prisma wave
#

anyway im more asking if there's any reason to not use records wherever possible

old wyvern
#

I dont think so

quiet depot
#

no reason yet

prisma wave
#

the only semantic difference seems to be that it makes private things public

#

but who cares

old wyvern
#

wdym?

prisma wave
quiet depot
#

if they ever make records more efficient in the jvm then itโ€™ll probs be worth it

prisma wave
#

not private

quiet depot
#

but atm i think records r compiled just like a pojo

#

so like no difference

prisma wave
#

yeah they are

quiet depot
#

currently I'm choosing not to make classes like that records

#

because it just doesn't make any sense

prisma wave
#

A record is basically a โ€œdata class,โ€ a special kind of class that is intended to hold pure data in it
yeah it doesn't make a lot of sense

#

the example i sent clearly isn't just for holding data

old wyvern
#

I think it might be because im on a older version

#

uh

#

Where did they move the mark directory as menu to in the latest version?

#

oh nvm it fixed itself

cinder flare
quiet depot
#

how is it faster

cinder flare
#

It calls different bytecode I dunno

old wyvern
#

I dont think they're neccessarily faster

cinder flare
#

Maybe not true true

old wyvern
#

It just generates an implementation at runtime with method handles

quiet depot
#

also i will be on a little later to talk about that thing u wanted to talk about in v

#

vc

cinder flare
#

Oh uh

frigid badge
#

๐Ÿ˜ฎ

cinder flare
#

I'm at my parents house right now

#

No pc or anything

quiet depot
#

o

cinder flare
#

And also supposed to be asleep lol

quiet depot
#

well in that case lemmo just made an appearance and he knows more than i do about it

cinder flare
#

๐Ÿ˜ฎ

old wyvern
#

docker?

quiet depot
#

ecloud

old wyvern
#

oh lol

quiet depot
#

ecloud spring rewrite

old wyvern
#

Is that ever going to be a thing?

quiet depot
#

will come with papi 3

cinder flare
#

If I can ever get it to boot maybe lol

old wyvern
#

So in like 2 decades?

#

xD

#

๐Ÿฅฒ

quiet depot
cinder flare
#

What

#

It doesn't have a dockerfile

frigid badge
#

there's a docker-compose file

#

and there is a dockerfile

cinder flare
#

Oh well I'm blind then nvm

frigid badge
#

it's garbage though

quiet depot
#

lel

cinder flare
#

That would've been good information to put in the readme ๐Ÿ™‚

frigid badge
#

but in #ecloud there's a pinned message iirc

cinder flare
#

If only I were in that channel ๐Ÿ™ƒ

quiet depot
#

added

old wyvern
#

Updating ij fixed it!

cinder flare
#

Yay records!

quiet depot
#

that Integer tho

old wyvern
#

๐Ÿ˜Œ

#

Nullable sadly

#

๐Ÿ˜ฎ

#

even better

#

yea.... now ijs having a complete stroke

cinder flare
#

Arrow code: folder edition

old wyvern
#

ok deleting .idea fixed it

lunar cypress
#

deleting .idea

#

creating .emacs

#

that's how you fix your problems

old wyvern
#

๐Ÿ˜ฎ

prisma wave
#

^

old wyvern
#

Ok, ij is still messed up

#

Now it stops recognizing classes from the same project

prisma wave
#

ij bad

#

emacs good

old wyvern
#

Seriously tho

#

ij completely broke

#

This is a first

#

let me try clearing everything again

#

oh wait

#

ik whats wrong

#

jetbrains tools just opening an old version inbetween for some reason

mild rose
#

With bungeeguard, it says unable to authenticate, even though I have a token in all of my servers.

lavish notch
mild rose
#

Yes

timber oak
#

How would you all set up a rankup system? A Rank class that is created for each player and stored in a hashmap?

#

And then a rank level in the constructor maybe?

#

To update it, or what would be best

static zealot
#

I'd usually just use LuckPerms and not bother at all fingerguns

rotund egret
#

Yeah, if you wanted to do like an "auto rank" system I'd use LPs API.

timber oak
#

it's not auto, just on a command

static zealot
#

then just use LP.

#

no need to make your own system unless you actually do it to learn I guess.

timber oak
#

Would the ranks be set up as groups or what?

hot hull
#

Yes

timber oak
#

How is luckperms performance-wise?

#

It's very good right?

hot hull
#

luckperms is cherry on the cake

timber oak
#

Good, thought so but just had to make sure

timber oak
#

What are the 5 general java rules called? I forgot

#

The ones like "only one goal for each class" or something like that

#

idk if that makes sense

compact perchBOT
timber oak
#

Thanks

#

Does luckperms take performance from the unused features as well as the features currently in use on the server? Or only the features that are currently being used

steel heart
#

wym

#

I mean luckperms uses what it has to like any other plugin

static zealot
steel heart
#

except blitz plugins mbey

static zealot
#

yeah. mine use everything at every point in time. even if it doesn't need to

steel heart
timber oak
#

But like, let's say I just want to set up one group and one permission, does it then also take performance to run all those extra features in the config and so on?

static zealot
#

performance is not something you'll really have to worry with LP

steel heart
#

if a feature is disabled in config then it simply wont be used

static zealot
#

unless you do some interesting stuff xD

steel heart
#

LP is at its finest scalable horizontally

#

but with that being said, even a normal minecraft server isn't made to keep up with too many concurrent players so hopefully that limits the expectations for luckperms as well as any other plugin

obtuse gale
#

There aren't really any "extra features" though

#

Rather, the LuckPerms config is all about how things are calculated (+ storage settings)

timber oak
#

Those calculations won't take a lot of performance I assume?

obtuse gale
#

The calculations will happen you like it or not, the config only tells LP how things are calculated

#

Not if they will happen or not

#

But most of LP runs asynchronously from the server thread anyway

timber oak
#

calculations for what though?

#

Not sure what would be calculated with permissions

#

and groups

obtuse gale
#

Tree traversal

#

Caching evaluated contexts (per world/server perms, primary group, prefixes etc)

#

Precalculating meta values too. LuckPerms is a top notch permissions calculator, there is a lot more that goes on behind the scenes than just "HashMap<String, Boolean>"

#

Wildcards, shorthand, group weights

static zealot
#

but it does it very well and not a lot you need to worry about. the thing you will have to worry about is your code

timber oak
#

Hmm aight

obtuse gale
#

Hell, even the commands run async

#

LP will be the last thing you'll have to worry about really

timber oak
#

Alright, ty

obtuse gale
#

Not to mention it is to my knowledge the only fully functional perms plugin to exist as of today lmfao

distant sun
#

tldr; em is a lp lover

timber oak
distant sun
#

Ik

timber oak
#

but yeah, still useful information

obtuse gale
#

UltraPermissions being the "main competitor" has broken Vault integration which is vital for many other plugins

#

Hilarious

obtuse gale
#

LP good

prisma wave
#

๐Ÿ˜ฎ

onyx loom
#

pex and groupmanager are functional ๐Ÿ™‚

obtuse gale
#

If we're in 2013 yes

#

Lmao

timber oak
#

How does Tuinity work differently?

#

Than paper

#

World generation right?

rotund egret
#

Emily is a moderator in LP discord, shilling out for them ๐Ÿ‘€

#

Despite that, it is the best though

steel heart
#

permissions.yml!

rotund egret
#

I don't even know what a yml is ๐Ÿ˜ฆ

steel heart
rotund egret
#

I think you're thinking of someone else

#

Turbo?

#

No wait you're right, how did I not know that wtf

#

@obtuse gale What is this

#

Initial Commit

steel heart
#

๐Ÿ˜Œ

obtuse gale
#

Lol

obtuse gale
static zealot
#

wait what?

#

group manager is based on luckperms?

#

or is this a "new" group manager?

onyx loom
#

hope this explains it

static zealot
#

yes

#

that's why I asked

#

I never knew group manager

#

was forked from luckperms

#

...

rotund egret
#

...

static zealot
#

or is that just the same plugin with the name changed?

#

and not the actual group manager

#

I'm gonna assume that is the case

onyx loom
#

omg

obtuse gale
#

Lol

old wyvern
#

lmao

static zealot
#

why is this a thing?

#

where the fuck is the applications folder located at? the one where I edit the desktop icons and stuff

#

I thought its in /usr/local but its not

distant sun
#

Fan Made Updates
smh my smh

static zealot
static zealot
prisma wave
#

i think generics might be my least favourite thing ever

#

omg

#

i have found my new favourite thing

#
public <T> Try<T> load(Class<T> type, Path source) {
        return Try.of(() -> loader.load(source))
                .flatMapTry(map -> mapper.map(map, type));
    }
``` ๐Ÿ˜Œ
onyx loom
#

oh my god

prisma wave
#

this makes me so happy

onyx loom
#

heaven

prisma wave
#

they even somehow added pattern matching to java

#

it's extremely cursed

#

but my god

#
Match(_try).of(
    Case($Success($()), value -> ...),
    Case($Failure($()), x -> ...)
);
#

honestly impressive

onyx loom
#

what java version can this be used with?

frigid willow
#

[22:29:10 WARN]: [PlaceholderAPI] Loaded class net.ess3.api.IEssentials from Essentials v2.19.0-dev+221-1556b91 which is not a depend, softdepend or loadbefore of this plugin.
[22:29:10 INFO]: [Vault] Checking for Updates ...
[22:29:10 INFO]: [Essentials] Essentials found a compatible payment resolution method: Vault Compatibility Layer (v1.7.3-b131)!
[22:29:10 INFO]: [Jobs] Successfully linked with Vault.
[22:29:10 INFO]: [Citizens] Loaded 0 NPCs.
[22:29:10 WARN]: [PlaceholderAPI] Loaded class me.ryanhamshire.GriefPrevention.GriefPrevention from GriefPrevention v16.17.1-2b69191 which is not a depend, softdepend or loadbefore of this plugin.
[22:29:10 INFO]: [PlaceholderAPI] Successfully registered expansion: griefprevention
[22:29:10 INFO]: [PlaceholderAPI] Successfully registered expansion: essentials
[22:29:10 WARN]: [PlaceholderAPI] Loaded class net.luckperms.api.LuckPerms from LuckPerms v5.3.47 which is not a depend, softdepend or loadbefore of this plugin.
[22:29:10 INFO]: [PlaceholderAPI] Successfully registered expansion: luckperms
[22:29:10 WARN]: [PlaceholderAPI] Loaded class net.milkbowl.vault.economy.Economy from Vault v1.7.3-b131 which is not a depend, softdepend or loadbefore of this plugin.
[22:29:10 INFO]: [PlaceholderAPI] Successfully registered expansion: vault
[22:29:10 WARN]: [PlaceholderAPI] Loaded class com.bencodez.votingplugin.VotingPluginMain from VotingPlugin v6.5.2 which is not a depend, softdepend or loadbefore of this plugin.

#

Any ways How to fix this?

half harness
#

You can ignore those warnings

old wyvern
prisma wave
old wyvern
#

I think the record builder I found earlier are also extremely useful

onyx loom
#

who needs java 11? ๐ŸŒž

old wyvern
#

with that and records, hundreds of lines went

onyx loom
#

this is actually amazing

obtuse gale
#

And this other one too, give me a min

prisma wave
#

arrow?

onyx loom
#

bms favourite thing

forest pecan
#

Welp. I guess thatโ€™s another dependency I gotta install

#

Lol

prisma wave
old wyvern
#

elara doc when ๐Ÿ˜”

obtuse gale
#

Tomorrow night probs

prisma wave
#

higher kinded types in java??

obtuse gale
#

That one is delightful

prisma wave
#

oh boy

#

26 files just to load a single yml file

#

love it

obtuse gale
#

๐Ÿ˜‚

distant sun
#

Nice

cloud hedge
#

Hello im making a plugin and i dont know if i can add breeding and taming?

sly sonnet
#

not gonna answer bcuz u spammed all dev channels ๐Ÿ˜ 

static zealot
#

and dms

#

and non dev channels

obtuse gale
#

asking everywhere = getting help faster

#

Right?

#

asking everywhere = getting help faster, right?

static zealot
#

xD

cloud hedge
#

I need it

timber oak
#

Any reason not to use paper API on paper servers?

onyx loom
#

no? lol

timber oak
#

thought so lol, just had to make sure

forest pecan
#

Is there a way to like avoid the try/catch statement inside a lambda?

#
    Stream.of(libraryPath, dependencyPath, httpServerPath, vlcPath, imagePath, audioPath, videoPath)
        .forEach(
            p -> {
              try {
                Files.createDirectories(p);
              } catch (IOException e) {
                plugin
                    .getLogger()
                    .log(
                        Level.SEVERE,
                        "[MinecraftMediaLibrary]: A severe I/O exception occurred while trying to create library folders!");
                e.printStackTrace();
              }
            });
#

like that try and catch is ugly. But yes ig it is necessary to handle it, but id rather handle it somewhere else

half harness
#

๐Ÿฅฒ so many newlines

forest pecan
#

google format

#

seems like the only way is to create its own method

#

๐Ÿฅฒ

obtuse gale
forest pecan
#

๐Ÿฅถ

obtuse gale
#

Wow

#

What

#

Unfriended

obtuse gale
forest pecan
#

Ended up doing this

#
public interface ThrowingConsumer<T, E extends Throwable> {

  static <T, E extends Throwable> Consumer<T> unchecked(
      @NotNull final ThrowingConsumer<T, E> consumer,
      @NotNull final Logger logger,
      @NotNull final Level level,
      @NotNull final String message) {
    return (t) -> {
      try {
        consumer.accept(t);
      } catch (final Throwable e) {
        logger.log(level, message);
        e.printStackTrace();
      }
    };
  }

  void accept(final T t) throws E;
}

#

๐Ÿคก

obtuse gale
#

lmao

hot hull
#

May I ask what the fock is going on with request paid, have people become idiots again with their budgets or what

sweet cipher
#

Yeah they are offering way too much

civic cairn
steel heart
#

Oh wtf

unkempt tangle
#

Did ya folks ever heard of baritone?

#

A pathfinder bot for Minecraft

#

Where is senpai:c

hot hull
frigid willow
#

hello I have a question

#

about deluxemenu

steel heart
#

What r u trying to do buddy

static zealot
#

you can just use the ChangeOutput expansion

#

/papi ecloud download changeoutput /papi reload

#

ugh

#

%changeoutput_equals_{essentials_afk}_true_yes_no%

#

so this will parse essentials_afk

#

and if it is true

#

it will output yes

#

otherwise it will output no

#

yeah think that will probably work

#

I've just realised we're in the wrong channel

prisma wave
#

Bruh placeholders are pretty much Turing complete at this point

#

Crazy

#

Coming soon: placeholderapi written in nothing but placeholders

timber oak
#

Would it be difficult to host a Linux screen on google, like so you can use the console on google or whatever

cloud hedge
#

Im trying to convert my block item file to a optifine entity but it messes up the rotation is there a way i can do this without messing the rotation?

mild rose
#

I can't figure out why Bungeeguard isn't working

#

the tokens are the same on every server but it still says "Unable to authenticate"

ocean quartz