#dev-general

1 messages · Page 369 of 1

half harness
#

i thought it was like a big pen

#

lol

jovial warren
#

Never ever seen that in my life

oblique heath
#

oh is that the thing you see in like cartoons and stuff

half harness
#

until smoke came out

jovial warren
#

Yeah we don't have those over here

lunar cypress
#

you put water flavour and coal there and then smoke the vapor

oblique heath
#

weird

half harness
#

wot

jovial warren
#

Jesus

prisma wave
#

YES

half harness
#

lol

half harness
lunar cypress
#

I haven't seen it much elsewhere though that's true

prisma wave
#

Yea that's not german I don't think

obtuse gale
#

HAPPY BIRTHDAY

half harness
prisma wave
#

THANKS

lunar cypress
#

In Germany you have bars for these at every corner

half harness
#

oops

prisma wave
jovial warren
#

My parents just said they recognise it

#

They know it as a shisha

#

Or a bong

#

F

frail glade
#

Happy Birthday!

jovial warren
#

Afternoon Glare

lunar cypress
#

shisha fucks your lungs even more than regular cigarettes

forest pecan
#

Will you guys hate me if i do @NotNull final instead of final @NotNull

sweet cipher
jovial warren
#

IntelliJ

#

Lol

oblique heath
#

aw why

lunar cypress
#

he's right though

half harness
#

what did ivan say

oblique heath
#

i said "what is that IDE? notepad++++?"

sweet cipher
#

lol

lunar cypress
#

there's a difference between not accepting other opinions and saying right off the bat that you aren't interested in arguments about IDEs

sweet cipher
#

notepad--

oblique heath
#

what's he saying

#

fair enough 😥

lunar cypress
#

he's tired of people telling him to use another IDE because they provide no sufficient reason for him to switch

#

he's used to Netbeans and likes it

hot hull
#

show code

ocean quartz
#

And likely all these comments he's, getting will make it even less likely he'll ever switch
Annoying someone into changing isn't a good strategy

prisma wave
oblique heath
#

HAPPY BORTH

prisma wave
#

THANK

jovial warren
#

lol

#

right, I'm home now @hot hull

#

gonna fix the JAR issues

hot hull
#

question to anyone whos fucked around with cross server management, or managing sub servers in general, it should be done by the "parenting" server correct

oblique heath
#

are talking mc servers

hot hull
#

ie.
Lobby
-> Arena 1
-> Arena 2

#

Yes, we are in a mc discord after all

oblique heath
#

i think that's not an ideal way to do it

#

i'm actually dealing with this right now, and all of my current management is happening in bungee

#

lobby bad because what if you want more than one lobby

#

same applies to bungee fyi, so you'd probably want an entirely separate management instance going separate from the MC servers

lunar cypress
#

looks pascal-ish

hot hull
#

Ivan, elaboration is what I require

onyx loom
#

some dodgy language

oblique heath
#

what specifically do you want me to elaborate on 😮

hot hull
#

Imagine coding in german lmao

jovial warren
#

FFS

hot hull
#

I know it's not

jovial warren
#

fucking terminal console appender depends on a different version of Log4j 2

hot hull
oblique heath
#

okay

jovial warren
#

and apparently you can get those issues with multiple Log4J versions on the classpath

#

because apparently Gradle can't figure out that shading 2 different versions of the same dependency is a bad idea

#

fml

prisma wave
#

Maybe pascal or Delphi

oblique heath
prisma wave
#

Possibly Ada

#

An ancient procedural language

jovial warren
oblique heath
#

(/s)

hot hull
#

So let's say I've got multiple arena instances

- Arena 1,
- Arena 2,
- Arena 3

Their creation and management (resetting the world, clearing data etc), should be handled by a single parent server (or just a single input point in general),

Then there's lobby instances (one for an example)

- Lobby 1

The creation of it should also be managed by the parent, however the lobby itself should handle the joining of arenas, (if there's multiple lobbies, that might be a little scuffed so will probably be have to be done differently),

Now the question is, what/how one would have a single entry point for all this, and with what/through what should that entry point be handled.
(Since you said using a MC server for this isn't really ideal, what would be an appropriate thing for this)

lunar cypress
#

quick google search says ada

oblique heath
hot hull
#

Do correct me on anything stupid I said in there cursed_fingerguns

oblique heath
#

each arena is a separate server instance right

#

not just a separate world on the same server

hot hull
#

Indeed

oblique heath
#

okay

#

and you're using docker for this right

hot hull
#

Would be ideal since scaling wouldn't be an issue

#

Not using anything yet, but that could be a possibility yes

oblique heath
#

if you're not using it yet you definitely should

hot hull
#

||Lemmo is gonna love me if I use docker||

oblique heath
#

docker can make the whole 'creation and management' part really simple

#

as far as writing code goes, at least

#

or more specifically docker swarm / k8s will make that easy

hot hull
#

I don't care if it's simple or hard, I just need something which is reliable, and optimal for such a use case

oblique heath
#

docker orchestration is optimal

#

if you use k8s you can deploy the arenas across multiple physical machines with ease

#

now you do have several choices when it comes to where you put the 'brains'

prisma wave
#

Yeah the extension suggests Ada

oblique heath
#

as you said one potential option is the lobby server

#

i think that's silly because you can very easily decide to have more than one lobby down the line

hot hull
#

However that becomes an issue if there's multiple lobbies

oblique heath
#

bingo

#

the next obvious choice is to have the brain running in the bungee instance

hot hull
#

But that also poses an issue if there's multiple machines no?

oblique heath
#

that's what i'm doing and it'll probably be good for as long as you're using one bungee

#

why is that

hot hull
#

Well as you said, multiple bungees

oblique heath
#

right yes once you have multiple bungees it might be a problem

jovial warren
#

2021-03-24 16:12:31,992 main DEBUG null null initializing configuration XmlConfiguration[location=jar:file:/C:/Users/callu/IdeaProjects/MineKraft/server/build/libs/Krypton-0.14.jar!/log4j2.xml] lol

#

ffs

oblique heath
#

if you think you'll get to the point where you will have more than one bungee

#

(wow)

jovial warren
#

why does Log4J just not like JAR files

hot hull
#

Might as well make it as scalable as possible from the scratch no?

oblique heath
#

true

#

in that case i'd say just make a completely independent jar

#

and run it by itself, connected to all the backends and all the proxies

#

that gives you the best scaleability because you still have room to shard that one jar in the future depending on how you design it

hot hull
#

mhm

oblique heath
#

so yeah thats what you want to do as far as the structure goes

#

oh having an independent server for just management is also nice because it's kind of like a microservice

#

so that's an instant cool factor

hot hull
#

probably also performance through the roof

oblique heath
#

yeah since there's no extra overhead on bungee or on spigot

#

definitely a plus

#

so at that point you just need to find a good way to have everything communicate

hot hull
#

Bardy suggested RabbitMQ

oblique heath
#

i'm sure you can use redis for that, i personally use java sockets to some moderate success

jovial warren
#

right, fucking finally fixed the issue with the console

oblique heath
#

i've never heard of rabbitMQ but i'm sure it'd work too

#

you have a lot of options

jovial warren
#

Log4J's Log4J2Plugins.dat file wasn't getting combined with TerminalConsoleAppender's

oblique heath
#

you can even make a REST api for the management server or something

jovial warren
#

but luckily, shadow has a transformer to deal with that

hot hull
oblique heath
#

actually a rest api / communication method would probably be needed for every server, not just the management server

#

so maybe something simpler is better

hot hull
#

well I mean data would be sql, and communication would just be to inform the sub servers/parent of the state of things

jovial warren
#

anyone know if you can work on two separate branches at once in Git without committing changes?

hot hull
#

Does that make sense?

oblique heath
#

yeah you'd keep all your data in an SQL db for sure

#

but you want to be able to give your spigot / bungee servers instructions

ocean quartz
oblique heath
#

i will say you probably want to only connect to the SQL db through the management server

#

or at least not through every single backend

#

because that's a lot of connections

jovial warren
#

looking into a solution where apparently, you can create a new work dir that caches the changes on a certain branch

hot hull
#

Forwarding the info to the management server and then storing it would probably be ideal then

oblique heath
#

yeah, that's what i'm doing right now

hot hull
#

Now to actually try and figure out how to do any of these things :kek:

oblique heath
#

xd good luck

hot hull
#

I've got no experience when it comes to docker, so we'll see how it goes kek

oblique heath
#

if kubernetes turns out to be too intimidating you can try docker swarm

#

both can do the basic orchestration stuff you need

#

but k8s is more powerful, popular, and has more cloud support

#

but also scarier

jovial warren
#

gonna do the hack of just creating two separate projects lol

hot hull
jovial warren
#

fixed btw

tranquil crane
jovial warren
#

yeah that works too

hot hull
#

@oblique heath My head already be hurting from just reading on kubernetes :kek:

heady birch
#

how In maven

#

nevermind

#

u were too slow

prisma wave
#

you are sick in the head

heady birch
#

I pressed maven

#

it is too late to change

#

to gradle

prisma wave
#

untrue

onyx loom
#

gradle init: exists

hot hull
#

Niall

#

My disappointment is immeasurable and my day is ruined

heady birch
#

Not sure about you but i am not fond of 'compiler hacks'

onyx loom
#

kotlin and maven, next ull find out hes using eclipse

heady birch
#

nope

#

intellij and the LATEST java

#

some would say it is the latest available

#

just as the tremendous James Gosling intended

hot hull
#

Latest being 11 or 16?

heady birch
#

16

hot hull
#

Good.

prisma wave
#

17 prerelease or nothing

hot hull
#

smh BM

prisma wave
#

🥴

heady birch
#

Does JDK 17 exist

#

17 being the seventeenth release

prisma wave
#

yes

#

in early access

#

only a SLOWPOKE would use 16

heady birch
#

src/main/java/Main.kt 😄

prisma wave
#

😩

hot hull
#

oh god

onyx loom
#

are there any gains to targeting a higher jvm version on kotlin other than optimisations?

prisma wave
#

Not really

#

Compatibility or optimisations

onyx loom
#

11 - best of both worlds 😄

heady birch
#

If I TARGET JVM 8 But compile with JDK 16 can I run on JRE 8?

static zealot
#

Time for windows reset. See you on the other side

heady birch
#

Class 'kotlin.reflect.KClass' is compiled by a pre-release version of Kotlin and cannot be loaded by this version of the compiler

hot hull
#

what would be proper package naming for the parent, and for the children

heady birch
#

?

#

I can suggest:
+-- parent
+-- child

hot hull
#

imma just go with source and receiver for now

heady birch
#

"For every 1 java bug fixed. 3 Kotlin ones appear"

half harness
heady birch
#

some would say it is not

#

I like to think of it as a good name

#

one of the best

#

and I know alot of java names

half harness
#

ok

#

thx

heady birch
#

There is probably a better one lol

#

What is the name of your program

half harness
#

idk

#

just curious

heady birch
#

IdkBootstrap

#

IdkApp

#

something like that maybe

half harness
#

ok

hot hull
#

@jovial warren I like how velocity handles initialization, (using an initialize event)

jovial warren
#

yeah idk about that personally

#

I don't really like it tbh

urban solar
#

bombardy can I get some support please

jovial warren
#

what with?

urban solar
jovial warren
#

just because you came in here to ask instead of being patient and waiting for someone to answer you in there, no

urban solar
#

I can't be patient, because people are waiting

jovial warren
#

well unfortunately for you, the staff here are volunteers, who dedicate their time off their own back to answer support queries

onyx loom
#

yeah nah

obtuse gale
#
  1. Bardy is not support
  2. Even if people are support, they are volunteers
  3. Wait patiently and don't randomly ask in other channels
jovial warren
#

also, it's PlaceholderAPI, you don't pay for it, so you aren't entitled to premium support

jovial warren
urban solar
#

.. forget it

#

I'll download them manually

jovial warren
#

since you can't have assignments in a while

prisma wave
#

whoops

onyx loom
#

good job.

prisma wave
#

?

jovial warren
#

actually, lemme give that a try for once

obtuse gale
jovial warren
#

let's see if IntelliJ's Java to Kotlin converter can actually be useful

half harness
prisma wave
#

Recursion

#

your stack should be a persistent data structure which you copy with the elements popped

#

🙂

urban solar
#

Please do not ping me, as I didn't ping anyone

jovial warren
half harness
#

it was a reply-

jovial warren
urban solar
#

Doesn't matter, it's still a ping

prisma wave
#

Did my link help you?

half harness
#

@jovial warren

jovial warren
#

what dkim

#

lol

half harness
#

hi

jovial warren
#

hello

half harness
#

hows ur day going

jovial warren
#

not bad

#

wbu

half harness
#

good

#

i just took a test

#

and didn't even know

jovial warren
half harness
#

there was going to be a test

#

ok

#

lol

old wyvern
#

Another one!!!

#

Last minute gang

frail glade
#

Says late

hot hull
#

I'm gonna start sending this to people who have closed source plugins

forest pecan
hot hull
#

Good thing you did

steel heart
#

yoooo kotlin karens so does kotlin have some sort of static inheritance or whatever idk companion inheritance maybe

#

just like the concept that'd be

prisma wave
#

Companions can inherit

#

But there's no forced inheritance

ocean quartz
#

Something I thought was kinda weird at first but it's pretty cool

class MainClass {
  companion object : AnotherInterface
}

Where the companion is an implementation but the "parent" class isn't

jovial warren
#

why is the code for aikar's timings so whack

half harness
#

how do timings even work?!

jovial warren
#

some whacky unpublished code

#

that uses a lot of static abuse

half harness
jovial warren
#

and when I say a lot I mean a fucking shit ton

steel heart
#

bruh

jovial warren
#

lemme show you

steel heart
#

dkim deliberately codes horrible code?

jovial warren
half harness
jovial warren
#

just feast your eyes upon that

#

every class is just filled with static abuse

onyx loom
#

theres always a workaround

ocean quartz
jovial warren
#

I know the workaround I want to choose

#

figure out how the timings works by myself and write the entire code from scratch

#

not using aikar's existing code

steel heart
half harness
#

i dont want to get bullied :c

half harness
#

what am i doing

onyx loom
#

when do we ever bully you 🤔

#

bullying is mean!

ocean quartz
half harness
#

how

#

what will you bully me about

ocean quartz
#

About those horrible elses you have there

onyx loom
#

u know that project that u privated after i looked at it 👀

half harness
#

oh wait

jovial warren
#

actually, maybe copying aikar's code is just the way it's meant to be

#

screw it

#

static abuse it is

half harness
#

lol

ocean quartz
#

Oi Dkim, never do this lol

half harness
#

whats wrong with it?

ocean quartz
#
method(
  param1,
  param2
)

Never

method(param1,
  param2)
#

Wtf

half harness
#

oh

steel heart
#

lol dkim chose the latter?

half harness
#

but

#

ok

#

i wont question

steel heart
#

no its fine

#

just

lunar cypress
#

this is ok imo

#

it just gets confusing with nested method calls

steel heart
#

I guess it's just somewhat counter intuitive for me

ocean quartz
#

It's very confusing though, makes it look like the code has bad indentation

jovial warren
#

now, who to copy from 🤔

lunar cypress
#

I disagree

jovial warren
#

Sponge or Nukkit

#

or Paper

half harness
#

paper

lunar cypress
#

nukkit is a cesspool from what I've seen

jovial warren
#

I'm trying to implement aikar's timings btw Johnny

#

just as context

#

but the code for it isn't published anywhere

#

and it's horrid

#

and yes, Nukkit already looks like a cesspit

#

I think the API and server are combined into one

#

anyway, copy from Sponge or Paper then

#

screw it, copying from Paper

old wyvern
frail glade
#

Still says late.

jovial warren
#

though Paper loves exposing literally all of the backend for timings

old wyvern
#

Yea ofc xD

#

Last minute

onyx loom
#

ok but yugi have u ever been 4 days late

old wyvern
#

I get marks as long as I make the submission

old wyvern
onyx loom
#

@ me rn

old wyvern
#

@onyx loom There we go

onyx loom
#

🥲

#

5 months late lmao

forest pecan
#

FUCK i forgot to go to my conference i was supposed to have with the teacher

old wyvern
#

lmao

forest pecan
#

my grade report has it as 'missing' now

#

FUCK

#

FUCK

old wyvern
#

so.. yea

#

xD

forest pecan
#

FUCKKKK

onyx loom
#

F

old wyvern
#

L

forest pecan
#

I got an 89 ON MY ESSAY

onyx loom
#

someones definitely getting muted

forest pecan
#

shoot

#

yea

#

thx for the reminder

onyx loom
#

🤣

forest pecan
#

🙂

old wyvern
#

I gotta make a game and submti for review in less than 48 hours

#

🙂

old wyvern
half harness
#

100 prob

old wyvern
#

Oh isnt that good?

jovial warren
#

actually, no

half harness
#

lol

jovial warren
#

I'm better than Paper and Sponge

old wyvern
#

Wha?

half harness
forest pecan
#

well

jovial warren
#

lol ik that sounds a bit random

forest pecan
#

my la grade is a 96

#

now

#

🥲

old wyvern
#

Ah

#

welp

jovial warren
#

I'm trying to implement aikar's timings into Krypton Yugi

forest pecan
#

gl

jovial warren
#

but it's a fucking mess

old wyvern
#

gl bard

jovial warren
#

like literally a mess on top of a mess on top of a mess

#

is that a "I've seen that shit and ik what it's like" or a "I've done that shit and ik what it's like" gl

#

I'm gonna search through the PHP code and stuff to see if I can find what and how it works

#

then try and implement it for myself

old wyvern
#

um what? xD

#

Its just a casual good luck

#

Dont overthink it bruh lol

jovial warren
#

lol

#

looks like it's all JSON

#

this should be easy

forest pecan
#

Warnings I hate in Intellij:

Unused warning - hate it for making libraries/apis
Inverting warning - hate it cause you may want to use it sometime later

...

#

what else

half harness
#

just suppress it

obtuse gale
#

Unused return value

#

Dkim no

forest pecan
#

No

half harness
#

y

obtuse gale
#

You can turn them off

forest pecan
#

lmao

half harness
#

but they're useful

obtuse gale
#

Then don't suppress them

half harness
#

maybe not the inverted one

obtuse gale
#

¯_(ツ)_/¯

forest pecan
#

i dont wanna see that in a library

#

like gson

#

lmfao

half harness
#

lol

forest pecan
#

they use @PublicApi

#

i think

obtuse gale
forest pecan
#

yea true

obtuse gale
#

It's for you that are building it

forest pecan
#

dkim i think your brain cells decreased by 1

#

dkim is at 2 braincells now

obtuse gale
#

mill

forest pecan
#

man you were smart for once

#

yesterday

#

telling bardy something useful

#

but now

#

it decreased

half harness
#

lol

forest pecan
#

Dkim in the inside: 🥲

half harness
jovial warren
sweet cipher
#

Ask Masked, and do the opposite of what he says

jovial warren
#

who?

sweet cipher
ocean quartz
#

TimingsPls lmao

sweet cipher
#

Lol

jovial warren
#

lol

jovial warren
#

let me show you the static abuse I want to avoid

#

also, Sponge uses an IAbstractSpongeTimingsFactoryBean here

#

and I don't want factories in Krypton

#

or statics

dawn hinge
#

FactoryBean?

jovial warren
#

yeah I'm taking the piss

#

point is: factories in Kotlin big ew

#

I wanna do all of this with DI and proper instances

obtuse gale
#

[5:41 PM] BomBardyGamer: point is: blah blah Kotlin big ew

obtuse gale
#

lol

jovial warren
#

trying to think of how I want to actually do the DI though

#

since this is so riddled with static abuse

#

actually, the sponge one doesn't seem to be

onyx loom
#

a little static abuse wont hurt 🙂

jovial warren
#

I will NOT let Krypton travel down the same path as Bukkit

ocean quartz
jovial warren
#

🤣

onyx loom
#

heinz beans

obtuse gale
#

Heinz Beinz

onyx loom
#

is heinz not just uK?

ocean quartz
#

Lol no

onyx loom
#

o interesting

jovial warren
#

why have I only just noticed that Heinz think they're cool by spelling "Beans" "Beanz"?

ocean quartz
#

Nice ketchup brand

onyx loom
#

ive always thought heinz was uk for no reason whatsoever

jovial warren
#

same

obtuse gale
#

seen it here too, was pretty shocked lol

dawn hinge
ocean quartz
#

It's a bean factory!

dawn hinge
jovial warren
#

man

#

this is such a pain

dawn hinge
#

Just do it Bardy

jovial warren
#

it means you are stupid in Spanish xD

#

nah I'm kidding, it means today at

#

or, today to the

#

bien, gracias

#

y tu?

obtuse gale
#

lmao

jovial warren
#

yes

obtuse gale
#

puta is more like whore but yeah

jovial warren
#

yeah

#

anyway, can someone help pls

#

I need to make this less staticy

obtuse gale
#

I mean that does make sense (except for the question mark lol)

ocean quartz
#

Mama, just killed a man

obtuse gale
#

ispkspis

jovial warren
#

at this point, I might just say fuck timings and just not support it

sweet cipher
#

Isn't Spark better?

obtuse gale
#

spark tho

#

yea

jovial warren
#

if aikar and his cronies wanna keep it all secretly between them then screw them too

#

yeah I'll use spark I guess

ocean quartz
#

Lichthund

#

Ye

jovial warren
#

wait how do you know that

onyx loom
#

please educate me
who is mini
and why does this matter

#

for hypixel i assume?

ocean quartz
#

No idea who those are

onyx loom
#

yup

jovial warren
#

oh btw, it's probably worth adding events to the ticking right?

prisma wave
#

these people need to get a job

sweet cipher
#

Like tick start and tick end?

jovial warren
#

yeah

prisma wave
#

/s before anyone tries any funny business

sweet cipher
jovial warren
#

well then

#

your wish is my command

sweet cipher
#

There wouldn't be any harm in doing it right?

jovial warren
#

nah

#

it's just as simple as calling an event

#

just like always

#

still gotta fix watchdog just randomly making the server go bye byes for no reason

#

it says the last tick time exceeded 60 seconds, but that's literally impossible

sweet cipher
#

lol

jovial warren
#
while (true) {
    lastTickTime = System.currentTimeMillis()
    val tickTime = measureTimeMillis(::tick)
    if (tickTime > 2000L && lastTickTime - lastOverloadWarning >= 15000L) {
        LOGGER.warn("Woah there! Can't keep up! Running ${tickTime}ms (${tickTime / 50} ticks) behind!")
        lastTickTime += tickTime
        lastOverloadWarning = lastTickTime
    }
    lastTickTime += 50L
    eventBus.call(TickEndEvent(tickCount, tickTime, System.nanoTime()))

    if (tickTime < TICK_INTERVAL) delay(TICK_INTERVAL - tickTime)
}
```nothing wrong with that btw is there?
#

the watchdog process watches lastTickTime

#

actually wait a minute

#
while (true) {
    val tickTime = System.currentTimeMillis() - server.lastTickTime
    if (tickTime > tickThreshold) {
        WatchdogProcess.LOGGER.fatal("A single server tick took ${"%.2f".format(Locale.ROOT, tickTime / 1000.0f)} seconds (threshold: $tickThreshold)!")
        WatchdogProcess.LOGGER.fatal("Considering it crashed, shutting down...")
        exitProcess(1)
    }
}
```that's the watchdog code
#

that could get out of sync couldn't it?

sweet cipher
#

Is that in a different thread?

forest pecan
#

could you please use a boolean instead of true

#

lol

jovial warren
jovial warren
forest pecan
#

while (running)

#

or smthing

jovial warren
#

guess I could

sweet cipher
#
while(thisBooleanIsTrueBecausePulseWantedMeToUseIt)
jovial warren
#

but that'll stop anyway

forest pecan
#

Better control

jovial warren
#

then I can just set that to false when the shutdown hook gets ran

#

ez

forest pecan
#

yea

sweet cipher
#

Just wondering but how come its in a separate thread?

forest pecan
#

Exactly

jovial warren
forest pecan
#

lol

sweet cipher
#

oh

jovial warren
#

that's not the ticking mechanism

forest pecan
#

watchdog is not an anticheat it just checks the server's state

jovial warren
#

watchdog makes sure the server hasn't crashed

sweet cipher
#

Oh wait I'm dumb

forest pecan
#

if it was on the main thread..

#

lmao

sweet cipher
#

Yeah I just realized

forest pecan
#

if the main thread stops

#

watch dog stops

sweet cipher
#

It wouldn't do anything

forest pecan
#

:kekw:

sweet cipher
#

lol

jovial warren
#

yeah if it was on the main thread it would be useless lol

forest pecan
#

im not a big fan of exitProcess

#

or that

ocean quartz
#

I wish Kotlin had

for {
}
// or
while {
}

Rust has the for one

forest pecan
#

cause that is not the life cycle of a thread

#

a proper one at least

forest pecan
#

like elara

#

lol

prisma wave
#

instead of while true

jovial warren
#

I use exitProcess btw because I have a runtime hook

forest pecan
#

Ic

ocean quartz
#

Yeah instead of while true

prisma wave
#
for {
  let blah = blah();
  if !blah {
    break;
  }
}```
forest pecan
#

i just prefer while(boolean) because it is the proper way to exit a thread

#

threads of life cycles and end cycles

jovial warren
#
Runtime.getRuntime().addShutdownHook(Thread({
    KryptonServer.LOGGER.info("Stopping Krypton...")
    isRunning = false
    KryptonServer.LOGGER.debug("Shutting down scheduler...")
    scheduler.shutdown()
    KryptonServer.LOGGER.info("Shutting down plugins...")
    pluginManager.shutdown()
    KryptonServer.LOGGER.info("Goodbye")
}, "Shutdown Handler"))
forest pecan
#

and that stuff

jovial warren
#

that shutdown handler is why I use exitProcess

#

because it avoids me repeating code

prisma wave
#
for {
  blah := blah()
  if blah {
    break
  }
}```
jovial warren
#

since exiting the JVM will run the hooks anyway

forest pecan
#

you could make a listener for the boolean

#

but prolly nah

#

cause that adds extra resources

half harness
#

How does SRV work?

#

(simply)

#

and would Krypton support it?

forest pecan
#

whats SRV again

half harness
#

dns

forest pecan
#

its a dns?

#

wot

obtuse gale
#

@jovial warren can I run WorldEdit on Krypton?

half harness
#

dns record type

#

thingy

forest pecan
#

oh

jovial warren
obtuse gale
#

Hehe

forest pecan
#

but isnt that bukkit or spigot?

jovial warren
#

when Krypton has the tools for me to make an implementation for it, I will do so

forest pecan
#

how can you run it together lol

onyx loom
#

FAWE on krypton? 🤨

jovial warren
#

WE is multiplatform silly

jovial warren
forest pecan
half harness
forest pecan
#

stfu

half harness
#

😦

forest pecan
#

/s

ocean quartz
jovial warren
forest pecan
jovial warren
#

actually wait

forest pecan
#

😖

jovial warren
#

okay I think I'm an idiot

ocean quartz
jovial warren
#

val address = buf.readString(255).toInetAddress() because that'll definitely work for most situations

forest pecan
#

🥲

jovial warren
#

totally

#

soon™️

forest pecan
#

🌚

jovial warren
#

I'm not going to support aikar's timings until aikar gets his shit together and gives me at least something to go off of

prisma wave
#

inline tho

ocean quartz
#

Yeah

eternal compass
#

join :p

pale shell
#

it doesn't load @eternal compass

old wyvern
steel heart
#

I dont get what the difference is between compile and transpile, compile is when u make human readable code into machine code and transpile is just human readable code to human readable code or what?

onyx loom
#

i guess so

old wyvern
#

Transpiling means you are "compiling"/"converting" something written in one language to another non-machine language

onyx loom
#

converting is probably the better word yeah

steel heart
#

hmm

#

btw bms bday today?

old wyvern
#

Yesterday

onyx loom
#

yes what a special occasion

steel heart
#

fuck

onyx loom
#

in uk its still his bday 😊

old wyvern
#

Ah

onyx loom
#

10pm rn

old wyvern
#

Ah

#

2 more hours

steel heart
#

@prisma wave congrats afterwards :]Pickaxe

eternal compass
onyx loom
#

yes congrats on staying alive bm (for 17 years now?)

half harness
old wyvern
#

fred that aint even opening

half harness
#

for me its 6

pale shell
#

i made bm a gift but he no reply i scared

onyx loom
#

pain.

steel heart
#

was it monads?

old wyvern
#

Do be monads

onyx loom
#

now thats one hell of a gift

old wyvern
#

yup

pale shell
#

I painted him a QR code. 😦

steel heart
#

intriguing

#

@half harness no work

#

bad

half harness
#

wdym

#

im in it tho

steel heart
#

okay and eat pizza

old wyvern
#

Let me introduce to you the "Mitten" monad
It holds values such as "Brister", "bitter", "Elara", "insert party cap emote, cant find it" and more as such. It is usually represented with the value appended with the "Mitten" word

prisma wave
#

🥲

half harness
#

how do i read console again?

#

i forgot

#

like console output

steel heart
#

scanner of system in

#

then call nextline or smtng

half harness
#

not user input

old wyvern
#

Console.ReadLine

steel heart
#

oh

old wyvern
#

a <- getLine

#

getLine >>=

half harness
old wyvern
#

cin

onyx loom
#

that is infact java.

old wyvern
steel heart
#

System.console().readLine() then mb

#

idk

old wyvern
#

Wait was that a serious question?

steel heart
#

yeah dkim questions

half harness
#

...

half harness
#

?

old wyvern
#

You want to read user input?

half harness
#

no

old wyvern
#

Or read the output stream?

half harness
half harness
#

actually

#

nvm ive found a better way

old wyvern
#

Alright

steel heart
#

I mean you could add like a log listener

#

or whatever its called

half harness
#

....

cinder flare
#

y'all ever had to use Alice?

#

it's JVM scratch

#

and i wanna die

obtuse gale
old wyvern
obtuse gale
#

And Rebecca or something like that

half harness
cinder flare
old wyvern
#

Aight. To confirm, do you want to read from the logger or the actual output stream?

obtuse gale
#

It's like the same crap

cinder flare
#

wanna see my project for this shitty online class

obtuse gale
#

Literally

obtuse gale
#

Oh my fucking God

cinder flare
#

yup

obtuse gale
#

It has images...

cinder flare
#

im over here making full plugins in kotlin and I have to do this shit 🙃

#

at least let me use blender lmao

#

oh and also the Alice download servers apparently suck because it's going to take 41 minutes to download 1.5GB

obtuse gale
#

I mean fair enough that really is an intro to programming (mainly the whole flow & logic things), but for dummies lmao

cinder flare
#

yeah and I'm in my second semester as a CS Major lol

obtuse gale
#

Oh what...

cinder flare
#

in my other class, I'm talking about QuickSort lmao

#

wanna help me with my homework?

obtuse gale
#

Yee

#

Busy tho

half harness
#

lol

cinder flare
#
8.4 When all keys are equal, what is the running time of
a. Insertion sort
b. Shellsort
c. Mergesort
d. Quicksort

8.5 When the input has been sorted, what is the running time of
a. Insertion sort
b. Shellsort
c. Mergesort
d. Quicksort

8.6 When the input has been sorted in reverse order, what is the running
time of
a. Insertion sort
b. Shellsort
c. Mergesort
d. Quicksort```
obtuse gale
#

Just put

#

5 seconds

#

Boom you're done lmao

cinder flare
#

It's in Big Oh notation lmao

forest pecan
#

yea its testing you the worst/average/best complexities

#

they should've asked you that directy lol

#

would've been much easier

cinder flare
#

nothing in life is easy lol

#

but yeah very true

obtuse gale
#

ok basically I hjave to make something that when a user clicks on a button it lets them input the dimensions of the shape on the button they pressed
but i want it to be fairly easy for me to add shapes in future
whats the best way to do this? (Windows forms app with VB)

#

Radix tho 🤤

forest pecan
#

there is a sort thats faster than quicksort in all scenarios

#

its called quadsort

forest pecan
#

or is counting sort different

#

Oh wait they are different

#

counting sort is radix sort but using whole value

#

omg

#

all my builds passed

#

😍

cinder flare
#

all my homies like merge sort

#

also constructing worst case scenarios for sorting is kinda fun lol

#

but I guess yeah the worst case would be 1 2 3 50000 6 3 49999

forest pecan
#

bogo sort

#

ftw

cinder flare
#

awee i like stalin sort

steel heart
#

lol

#

thats a thing?

forest pecan
#

https://www.geeksforgeeks.org/add-elements-in-start-to-sort-the-array-variation-of-stalin-sort/#:~:text=Stalin sort (also%20'dictator%20sort,simply%20eliminated%20from%20the%20list.&text=The%20process%20is%20then%20repeated%20until%20the%20list%20is%20sorted.

#

yep

#

also know as trump sort

#

lol

cinder flare
#

ayyy

#

trump sort is if you're not sorted, you get fired lol

#

fuck

oak coyote
#

@cinder flare got caught using block coding #lacking

cinder flare
ocean quartz
#

@old wyvern Did you make the todo? ;p

half harness
#

how do i fix this?

#

and no, there is no configure button

ocean quartz
#

Add it to Gradle?

half harness
#

i already did

#

nvm

#

it just disappeared

#

okay now its just broken

#

intellij hates me 😦

cinder flare
#

invalidate caches and restart ij

half harness
#

nooo

#

maybe

cinder flare
#

lol

old wyvern
#

💀

ocean quartz
#

Oh take your time, was just wondering ;p

old wyvern
#

Alrighty

#
switch (mark)
{
    case int n when n >= 80:
        Console.WriteLine("Grade is A");
        break;

    case int n when n >= 60:
        Console.WriteLine("Grade is B");
        break;

    case int n when n >= 40:
        Console.WriteLine("Grade is C");
        break;

    default:
        Console.WriteLine("Grade is D");
        break;
}
```😮
cinder flare
#

is uh.. is that declaring a new int for every case line?

old wyvern
#

No

#

That exists only in the scope of the case I think

#

Just stumbled on this randomly

cinder flare
#

so does it reassign the value of mark* to int n?

#

im so confused

old wyvern
#

No no

#

Its like inside that case, mark is called n

cinder flare
#

why lol

old wyvern
#

I assume theres also some form of type matching?

#

Maybe like you could switch a base class and handle cases of diff child classes

cinder flare
#

ah I see

#

I prefer Kotlin's when, but that's kinda cute

old wyvern
#

Might wanna confirm that

old wyvern
sweet cipher
#

Has anyone here ever used JavaFX with fxml files with ImageViews?

old wyvern
#

Nope, but might be better if you mentioned the problem itself

sweet cipher
#

Alright

half harness
#

imagine not using scenebuilder

forest pecan
#

i use javafx for my malware

#

lol

sweet cipher
#

So, my images won't load, there is no errors or anything, I'll put the code in a paste one sec

old wyvern
#

I have used TornadoFX, just not JavaFX directly

sweet cipher
#

=paste

compact perchBOT
#
HelpChat Paste

Please use a paste service to share configs, errors, code and long logs.
HelpChat Paste

forest pecan
#

i used javafx for my jumpscares

old wyvern
#

lmao

forest pecan
#

they cant alt f4 out

#

lol

old wyvern
#

Have you played Scary Maze?

forest pecan
#

nope

#

whats that

old wyvern
#

Its basically a troll game

forest pecan
#

oh

#

ik

#

if you touch the walls, you get jumpscared?

sweet cipher
old wyvern
#

When you pass level 3, it shows a jumpscare and starts screaming

#

Yea

forest pecan
#

lmao

old wyvern
#

I remember doing that on facebook

#

God I ran

#

xD

sweet cipher
#

The images just won't show up

old wyvern
#

The path is probably incorrect

steel heart
#

yugi

#

about slimjar

#

wat u need

#

im rdy to pr

old wyvern
#

Setting up the downloader first

#

Ill let you guys know once I setup a proper roadmap

steel heart
#

okay 😄

sweet cipher
sweet cipher
#

I fixed it

clear junco
#

yo guys i am new to this minecraft deving

#

if someone could help from where i could get sources like yt

obtuse gale
#

Useful resources:

Java API: https://docs.oracle.com/en/java/javase/11/docs/api/
Basic Java Tutorials: https://docs.oracle.com/javase/tutorial/
Online Java Course: https://www.codecademy.com/learn/learn-java/
Object-Oriented programming in Java: https://java-programming.mooc.fi/
Interactive tutorials through projects: https://hi.hyperskill.org/
____________________________________________

Start with this -
https://docs.oracle.com/javase/tutorial/java/concepts/index.html
Breeze through this skipping stuff that doesn't seem relevant like bitwise operators-
https://docs.oracle.com/javase/tutorial/java/nutsandbolts/index.html
and then hit this
https://docs.oracle.com/javase/tutorial/java/javaOO/index.html

They're the first three from this larger thing - https://docs.oracle.com/javase/tutorial/java/index.html
Which you should definitely go through overall. But those three should be enough for slightly better understanding of wtf is happening here without feeling like a huge time sink
That one is a small part of this larger site - https://docs.oracle.com/javase/tutorial/index.html
wherein "Essential Java Classes" and "Collections" also have good useful stuff
____________________________________________

For plugins: https://bukkit.gamepedia.com/Plugin_Tutorial

A few challenges you can try and solve: https://github.com/PiggyPiglet/Challenges

Things you want to take a look at when making plugins: https://bukkit.gamepedia.com/Plugin_Tutorial#onEnable.28.29_and_onDisable.28.29
https://bukkit.gamepedia.com/Plugin_Tutorial#Commands
https://bukkit.gamepedia.com/Event_API_Reference

hot hull
#

@ocean quartz where triumph chat

obtuse gale
#

@clear junco there you go ^^ plugin making isn't a fun ride at the park, you have to know how to program (as the official Bukkit page says, it is a necessity), it will take a lot of time to learn if you are not familiar with the concept, way, way more than "just a few weeks", you will go to hell and back in the process especially since Bukkit has its own twists... I know you are all "but I want to make plugins, not 'just learn java'" and in reality it's "but I don't want to read this boring article that takes me 3 minutes to read and 15 to comprehend, I want to spend a whole frustrating week trying to do something without knowing how to"

But after all that's what we are here for, to help you out of this endless hell loop (also #development for dev support)

ocean quartz
hot hull
#

'tis 6:23 am, time to wake up

ocean quartz
#

Tis 5:24am time to go sleep

clear junco
#

@obtuse gale yes sir

hot hull
#

Yikes

obtuse gale
#

orange boys

hot hull
#

If either amazon or microsoft buy discord and I see one fucking ad I'm nuking something

obtuse gale
#

My house

ocean quartz
#

Can i visit your house when that happens?

hot hull
#

How ew would something like this be

cinder flare
#

very pretty actually

#

and a very logical way of ordering servers

#

what format is that?

hot hull
#

hocon

#

very smexy

cinder flare
#

do you prefer it over YAML?

hot hull
#

first time using hocon, so not sure yet

#

yaml is fugly tho

cinder flare
#

i think yaml's kinda cute

#

and it's very simple

hot hull
#

for commissions I use yaml and properties, this is not a commission so testing out new things

cinder flare
#

bro you get commissions

#

i wish I were cool

hot hull
#

stop doubting yourself

#

go do this

cinder flare
#

hmm lemme eat my oreo mcflurry first

hot hull
#

😫

#

organisation on point

#

wdym kek ;C

#

I'm aware, but what's so funny about that 😢

steel heart
#

UpperCamelCase module names

#

😆

hot hull
#

Could not care less about that

steel heart
#

Also ur name is Dom

hot hull
#

No

#

Means Home in my language

steel heart
#

Like document object model

steel heart
hot hull
#

yeye

steel heart
#

Sure u cane have the folders uppercamelcase I guess but then change the names to kebab case ?

hot hull
#

Now I want a kebab

steel heart
jovial warren
#

Luckily, Krypton natively bundles kotlinx.serialization, so you can very easily add support for a multitude of formats

#

It comes bundled with JSON and HOCON though

jovial warren
#

whatever-this-case-is

#

And because it supports kotlinx.serialization, you can avoid messy code for transforming your configs into objects, since kotlinx.serialization handles that conversion for you

#

Just make a data class and annotate it with @Serializable

cinder flare
#

but what about yaml

jovial warren
#

Kaml exists

cinder flare
#

ooh?

jovial warren
#

It's not official, but it works

#

It's a converter for kotlinx.serialization for YAML

cinder flare
#

not that?

jovial warren
#

And it's promoted as a format serialiser in the official repo

cinder flare
#

oooh spicy

jovial warren
#

All you gotta do is manually read the files as text

#

Which I may add some helper functions for

cinder flare
#

that uh, that sounds like a lot of work

#

yea lol

jovial warren
#

I mean, it's one line

#

FileReader(File(context.folder, "config.yml")).readText()

#

You might wanna use use there actually (basically Kotlin's equivalent of try with resources)

cinder flare
#

I do like try with resources

jovial warren
#

I like Kotlin's lambda function for it

#

FileReader(File(context.folder, "config.yml")).use { it.readText() }

#

Since Kotlin doesn't actually have try with resources

#

Mainly because of that lambda function lol

#

Kotlin doesn't need it

cinder flare
#

It still takes me a sec to remember that it is a special keyword in Kotlin lol

jovial warren
#

It's not a keyword, it's just the implicit name for the receiver parameter in a lambda

#

Avoids you writing use { reader -> reader.readText() }

cinder flare
#

Well yeah I know, I'm just not used to it is all

jovial warren
#

Fair

#

Yeah Java gets you into bad habits of being over verbose lol

#

It can be difficult to get out of those habits

cinder flare
#

yeah man like I love those series of . calls that, in one line, (or many for prettiness) take an array or something and sort it and return an arraylist or something

#

those things are super cool

jovial warren
#

Yeah the declarative reactivity is amazing

#

A.k.a Kotlin's answer to streams

prisma wave
#

No need for a reader

jovial warren
#

And apparently I don't know Kotlin that well

cinder flare
#

👀

#

bm big brain

cinder flare
jovial warren
#

I mean the filtering and stuff

prisma wave
#

that's not reactive

cinder flare
#

I know lol, it just seems like a buzzword name haha

onyx loom
#

everything is a buzzword around here

quiet depot
#

wouldn't say declarative is a buzzword

#

reactive definitely is

jovial warren
#

yeah I guess that’s not reactive

#

oh also, is it worth me adding flat world generation to Krypton just so you can have something generated by default instead of having to copy your own world over?

cinder flare
#

oh shit wait can you not reuse the vanilla worldgen code? cause that's gonna suck

jovial warren
#

I could look at some of it, but I really have to limit the amount of time I spend looking at Mojang code, so I don’t end up going insane

#

also, their world generator is probably also a mess

cinder flare
#

but it must be pretty tough to generate a world exactly like how vanilla does it? I'm only now seeing the precarious balance we have that every server utility generates worlds exactly like vanilla

jovial warren
#

I plan to make my own world generator from scratch for Krypton

#

it’ll be a huge project, but I can do it I think

cinder flare
#

catch Krypton in 30 years with a fully redone worldgen system lol

jovial warren
#

lol

#

the world generator is last on the priority list atm

cinder flare
#

ah yes, krypton users will be forced to enjoy their new server in the void >:)

jovial warren
#

lol

cinder flare
#

got a trello or something? i'd love to keep up to date on the progress of this bad boy if I ever miss a few discord messages in the infinite stream

jovial warren
#

nah I’ll make a really simple flat generator

jovial warren
cinder flare
#

bro trello is so satisfying tho

#

though I do agree it is better when other people make the boxes for you and you just get to move them

#

coming up with them yourself is the hard part

jovial warren
#

Trello is alright, but SaaS

cinder flare
#

free for indiviuduals, im sure?

hot hull
#

clickup better

jovial warren
#

I need people to make issues on GitHub with suggestions and bugs lol

cinder flare
#

and atlassian is kinda cool

cinder flare
jovial warren
#

not sure if I really like Atlassian tbh

cinder flare
#

jira kinda slaps

jovial warren
#

their services are a bit expensive for what they are

#

yeah Jira is an example of a good service that’s just overpriced

cinder flare
#

hey man, you can't put a price on reliability and ease of use

jovial warren
#

I guess?

cinder flare
#

why do you think Adobe still exists despite charging way too much

jovial warren
#

true

onyx loom
#

because theres nothing else that fully competes against them lol

steel heart
unreal briar
#

For companies Jira is worth it

#

Overpriced for consumers doesn't necessarily mean overpriced for businesses

jovial warren
#

for individuals though and hobbyists making open-source projects, it’s a rip off