#dev-general

1 messages · Page 162 of 1

empty flint
#

It seems the dependency I'm trying to add to the subprojects doesn't transfer to the subproject

#
allprojects {
    apply(plugin = "org.jetbrains.kotlin.jvm")
    repositories {
        mavenCentral()
        jcenter()
        maven {
            url = uri("https://hub.spigotmc.org/nexus/content/repositories/snapshots")
        }
    }
    dependencies {
        implementation(kotlin("stdlib"))
        compileOnly("org.spigotmc:spigot-api:1.16.2-R0.1-SNAPSHOT")
    }
}
#

but I'm still getting the error: Unresolved reference: bukkit

signal tinsel
#

Nice my command framework works a little bit so far

empty flint
#

fuuuuuck gradle

#

so stupid man

hot hull
#

No.

empty flint
#

yes

#

it shows the dependency but still can't resolve the org.bukkit reference

#

@hot hull what do I do with this error for example: "is not part of the build defined by settings file <path to gradle settings>"

prisma wave
#

Do you have multiple modules?

empty flint
#

not yet

#

why?

#

@prisma wave also, why do you keep changing your name? ^^

onyx loom
#

because he realised that clojure is bad and so is vbscript so he changed back to normal

prisma wave
#

no

#

why?
@empty flint
Because you're using allprojects which is useless for single module builds

empty flint
#

So if I create another project it should work?

signal tinsel
#

Aight my cmd framework works

#

Still a lot of work todo but I'm happy for today lol

empty flint
#

@empty flint
Because you're using allprojects which is useless for single module builds
@prisma wave Still getting "Kotlin: Unresolved reference: bukkit" again

signal tinsel
#

Gotta do tab completion and usage/help generation

empty flint
#

@prisma wave Do I have to remove the auto-generated iml files for gradle to work?

#

I've been at this for the past 6 hours. Can somebody please help me out, I'm going insane

surreal quarry
#

no you don't remove the imls

empty flint
#

So I'm trying this step by step, right

surreal quarry
#

why do you have url = uri("")

#

just do url 'url'

ocean quartz
#

Iml is generated by IJ

empty flint
#

New Project -> Gradle (Kotlin DSL), Kotlin JVM library

surreal quarry
#

oh your using kts

empty flint
#

Then I go New -> Module -> Kotlin but no build.gradle is created for the module

#

How do I do this?!

prisma wave
#

You need to make a gradle module

steel heart
#

Alex, does guava have a Map<K1, K2, V> where you'd need both keys to put and get a value from the map?

#

or is there any libs out there that has that?

prisma wave
#

Table

empty flint
#

You need to make a gradle module
@prisma wave Tried that as well. No src folder was created so I made one and it still didn't work

steel heart
#

Table as of what? A library?

prisma wave
#

Do you actually want to use multiple modules?

#

@steel heart that's the class name

steel heart
#

Oh I see

empty flint
#

Do you actually want to use multiple modules?
@prisma wave I want to have all my plugins be submodules of one root project that only handles dependencies

steel heart
#

But no Multitable?

prisma wave
#

Jesus

#

@empty flint if you want an example have a look at the pdm repo

#

It's in groovy but you should be able to get the gist

empty flint
#

do you have a link? Idk what pdm means and google doesn't help

steel heart
#

LinkedHashBasedMultiSetTable

prisma wave
#

oh lol

#

Pdm is one of my projects

#

Uses multi module stuff

empty flint
#

right, how do I find it?

prisma wave
hot hull
#

What's the exclude syntax for gradle again?

steel heart
#

dependency() {
transitive false
}

#

or

#

exclude group: 'lol'

#

iirc

empty flint
#

man

#

this was so much easier in maven

steel heart
#

not rly

heady birch
#

yeah gradle over hyped

prisma wave
#

Not

eager patio
#

hello

#

I need a help

#

Someone help me please ?

static zealot
#

well

compact perchBOT
#
FAQ Answer:
» Give the helpers some details
» Ask suitable questions
» Be polite
» Wait

Source

static zealot
#

how ?

#

xD

distant sun
#

There we go

eager patio
#

Sorry for my bad english

#

I say first

#

I gonna open a server

#

I don't want cheaters to join my server

hot hull
#

Just cancel the player cheat event

eager patio
#

How do block this

distant sun
#

Dont @hot hull

hot hull
#
@EventHandler
public void onCheat(final PlayerCheatEvent event) {
  event.setCancelled(true);
}
eager patio
#

: (

#

you make me sad

static zealot
#

ugh /ban xD

hot hull
#

I make myself sad as well

eager patio
#

Version checker or

#

something like

hot hull
#

Get an anticheat, not really much else you can do

static zealot
#

actually

ocean quartz
#

Preventing cheaters from joining the server is virtually impossible

static zealot
#

make your own client

#

and only allow people to join using that

#

ezz

eager patio
#

I can't

distant sun
#

Stop trolling smh

#

Explain your issue

eager patio
#

How do I protect my server from grief?

static zealot
#

WorldGuard + WorldEdit

#

and CoreProtect

ocean quartz
#

Worldguard or grief prevention

eager patio
#

no

static zealot
#

best combo

eager patio
#

not like this

hot hull
#

What then?

old wyvern
#

delete system32

eager patio
#

like this

hot hull
#

:lmao:

static zealot
#

?

ocean quartz
#

Preventing cheaters from joining the server is virtually impossible

eager patio
#

ya pezevenkler

#

oh sorry

#

aaa

old wyvern
#

That just looked like he had OP

hot hull
#

^

#

Which was probably given to him by a shitty staff member

#

99% of the time that's the case

old wyvern
#

Dont give staff members permission to /op command

static zealot
#

well the server was shitty if they gave op to staff memebers

obtuse gale
#

who gives staff op tho

static zealot
#

don't give them op and the * permission

#

a lot of people do Aj

#

for like 200%

#

200$ *

eager patio
#

any plugin or something like ?

obtuse gale
#

rip

ocean quartz
#

They had plugman, you know how good it is just by that

static zealot
#

Mixwox this is not the place to ask for plugins or support at all

hot hull
#

:kek:

static zealot
#

is for that

old wyvern
#

any plugin or something like ?
@eager patio
Plugins to prevent you from oping staff?

ocean quartz
#

And you'll find many plugins that claim to be anti cheat, but none will protect you 100% if someone wants to cheat they will

jovial warren
#

guess who's back

#

back again

old wyvern
#

shadys back

eager patio
#

bekle senin amına koyacam bekle

static zealot
#

tell a friend

eager patio
#

Thanks for helping

old wyvern
#

Guess who's back

jovial warren
#

my power supply finally came today

static zealot
#

nice

old wyvern
#

You can do that to yourself @eager patio Have a nice day

eager patio
#

ty

static zealot
#

mixwox please find another place to troll

eager patio
#

🇹 🇷

static zealot
#

also don't swear and keep it english

#

thanks

jovial warren
#

my new specs are:

CPU: AMD Ryzen 7 3700X
Motherboard: ASRock B550 Phantom Gaming 4
Graphics card (not upgraded): NVIDIA (MSI) GeForce GTX 1050 Ti
RAM: Corsair Vengeance LPX DDR4-3000 32GB (4x8)

hot hull
eager patio
#

bak seni

#

olm yardım edin diyorum

#

ediyormusunuz

static zealot
#

please keep it english

#

and if you want support that's why there is a support area

#

if you don't know english there's google translate

remote goblet
static zealot
#

nice

ocean quartz
#

Functional interfaces

old wyvern
#

ayy

#

finally

static zealot
#

no idea what those are but nice xD

ocean quartz
#
@FunctionalInterface
public interface Test {
  execute();
}
fun interface Test {
  execute()
}
old wyvern
#

^

#

that defenition for function seems weird tho

ocean quartz
#

Basically what i use on my libs for things like GuiItem(item, event -> ) the event stuff is from a functional interface

old wyvern
#

would assigning it to a val be

val a = fun interface Test {
  execute()
}```?
ocean quartz
#

Let me test

old wyvern
#

or can we have an identifier after fun?

#

This is the 3rd time me trying to update xD, ij keeps failing randomly

ocean quartz
#

You can't declare it like that
Why do you want to assign it to a val? ;o

old wyvern
#

I mean in case if there was a need that would have been nice xD

prisma wave
#

Class declaration is a statement

#

I don't see how having it as an expression would work

old wyvern
#

oh that was for defining it

#

I assumed it was to call xD

#

nvm

ocean quartz
#

Oh! Yeah just defining

old wyvern
#

can it just be defined with a lambda where needed?

ocean quartz
#

I assume it'll work just like the Java counterpart

prisma wave
#

It's no different to a normal interface

#

Except it allows SAM conversion

old wyvern
#

yea thats what I meant

#

Test {args... -> }

heady birch
#

heh I reckon I could if I was paid enough

prisma wave
#

what

heady birch
#

Preventing cheaters from joining the server is virtually impossible

prisma wave
#

Just check the evil bit

#

Easy

heady birch
#

playerBits & 0x04

surreal quarry
#
if (e.player.isCheater()) e.player.kickPlayer("Cheater lol")
heady birch
#

Lol

surreal quarry
#

idk why anticheats haven't been doing that

heady birch
#

Kotlin could accomplish that

surreal quarry
#

just have a massive extension

#

lmao

onyx loom
dusky drum
remote goblet
#

most likely

#

yes

dusky drum
#

XD

signal tinsel
#

Not bad

remote goblet
#

is it java?

#

yes

#

then its bad

signal tinsel
#

Yes

jovial warren
#

wait Kotlin 1.4 is out?

remote goblet
#

yeee

jovial warren
#

about time lol

#

no idea what it even adds

old wyvern
signal tinsel
#

Working on auto help generation

#

That's gonna be a bitcchhhhhh

ocean quartz
surreal quarry
#

@signal tinsel check out https://github.com/lucko/LuckPerms. they have a good auto generated help thing that determines what help to show based on what amount of args you provided

signal tinsel
#

I mean, i need to figure out how to format it

#

Tbh doesnt matter too much as users can create their own helpgenerator

hot hull
#

Lmao @turbid chasm

#

Lazy I see

turbid chasm
#

I took the pussy way out.

old wyvern
#

Ayy intellij finally updated

turbid chasm
#

@hot hull Do you code in node.js?

onyx loom
#

i downloaded 2020.2.1 through toolbox... it didnt even update for me

distant sun
#

@signal tinsel whats that? The bin doesnt load for me

old wyvern
distant sun
#

U suc @onyx loom

signal tinsel
#

What bin

distant sun
#

hastebin

signal tinsel
#

Oh

onyx loom
#

wow gaby

signal tinsel
#

Wtf its gone lol

onyx loom
#

how rude

signal tinsel
#

Its a commands thing

old wyvern
#

ew they messed up the splash screen

distant sun
#

Link 👀

signal tinsel
#

Annotations

#

Its nkt piblic rn

old wyvern
#

It looks so.... colorfully weird now

distant sun
#

^

#

I blame kali for that

old wyvern
#

wdym?

onyx loom
#

what i do

#

so rude

#

blaming everything on me 😠

signal tinsel
#

@distant sun gimme a sec I'll re upload

distant sun
#

wdym?
@old wyvern kali - kalibear

hot hull
#

I do not Harvey

old wyvern
#

oh xD

signal tinsel
#

Should I make an @Injectable annotation for my injector system

hot hull
#

bruh @winter iron The hell are you shading in that plugin of yours that it's 14mb

distant sun
#

Nike

signal tinsel
#

Wait no

#

That won't work

winter iron
#

im not minimzing

signal tinsel
#

What's with Nike

winter iron
#

frosty, if I minimize it dont work because of sqlite and mysql drivers not being included

ocean quartz
#

Even not minimizing that's a lot o.O

signal tinsel
#

Anyway gaby I'm not sure if I'm gonna even make the command framework public

distant sun
#

Welp

winter iron
#

I tried to use exclude in gradle, but it didnt work

heady birch
#

Dudes using Hibernate

signal tinsel
#

I mean if people really want I'll publish it no problem

winter iron
#
dependencies {
    compileOnly "org.spigotmc:spigot:1.16.1-R0.1-SNAPSHOT"

    implementation "me.mattstudios.utils:matt-framework-gui:2.0.2"
    implementation "me.mattstudios.utils:matt-framework:1.4"

    implementation "com.zaxxer:HikariCP:3.4.5"
    implementation "org.xerial:sqlite-jdbc:3.32.3.2"
    implementation "mysql:mysql-connector-java:8.0.21"

    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
    implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.8"
}
#

this is all my dependencies

#

Lol

signal tinsel
#

I'm defo gonna work on it first

winter iron
#

not alot

prisma wave
#

p

#

d

#

m

hot hull
#

Well hikari is decently sized

prisma wave
#

the production ready software fingerguns

onyx loom
#

what version of pdm we on now

winter iron
#

I will look at PDM in future

prisma wave
#

0.0.19 i think

onyx loom
#

i need to update from 0.0.1 🙃

prisma wave
#

yes

winter iron
#

but I did this to learn gradle too

ocean quartz
#

You shouldn't need to implement sqlite and mysql though, that's on spigot

prisma wave
#

old version bad

#

new version good

onyx loom
#

u sure?

old wyvern
#

bm you should remake or maybe switch the focus the spigot plugins

winter iron
#

@ocean quartz doesnt work for 1.8

onyx loom
#

uve had like 12 updates in the past 4 days

prisma wave
#

wdym @old wyvern

winter iron
#

so i need my own drivers

#

😦

signal tinsel
#

Should I publish my plugin framework when I work on it a bit more?

onyx loom
#

sounds abit unstable to me

prisma wave
#

no

signal tinsel
#

Currently commands and GUI + some utils

prisma wave
#

well

#

kind of

old wyvern
#

It would be nice to have it be generally easy to use in any project

ocean quartz
#

Oh
Well
Update fingerguns

prisma wave
#

It's pretty much decoupled from spigot anyway

winter iron
#

Its compataible with 1.16 too

#

damn i cant spell

old wyvern
#

Yea but the setup for outside spigot was a hassle right?

prisma wave
#

only a bit

old wyvern
#

Ah

onyx loom
#

fock sake

#

need to update my pdm manager dont i

prisma wave
#

wot

turbid chasm
#

Can someone explain to me why this does not work?

ocean quartz
#

What are the common hex syntax people have been using on spigot?

onyx loom
#

its PDMBuilder now or smth right

prisma wave
#

yes

hot hull
#

Matt, #<HEX> fingerguns

distant sun
#

<#hex> &#hex

ocean quartz
#

Yeah that one is the best one, just wanna add some others in case people suck

onyx loom
signal tinsel
#

I use &#hex

distant sun
#

Once again, that's horrible frosty

hot hull
#

I'll cook your cat Gaby

turbid chasm
#

if(I go poop) => wipe ass, flush toliet
``` Why does this not work? It does it backwards for me. :/
ocean quartz
#

<#hex> best

onyx loom
#

how many times have u said that frosty kekw

distant sun
#

^

steel heart
#

&#hex is nicer

distant sun
#

Shut up @steel heart

heady birch
#

&# is standard

glad spear
#

Nah yesterday it was oven kali

steel heart
#

^

hot hull
#

§x§f§f§f§f§f§f best

onyx loom
#

Nah yesterday it was oven kali
@glad spear last week it was the bbq

steel heart
#

it should be &#hex consider all formattings starts with & currently

prisma wave
#

(apply-hex :FFFFFF) best syntax

old wyvern
#

<#hex> PlusOne &# MinusOne

glad spear
#

Yes true that

heady birch
#

Feels like a casino with all these emojis

prisma wave
#

wow

#

6 votes for lisp syntax

ocean quartz
#

Now i need to make <(?<hex>#[A-Fa-f0-9]{6})> support multiple styles yikes

prisma wave
#

i guess it's objectively superior after all

heady birch
#

Thats wack

onyx loom
#

what was the reasoning behind changing the pdm manager @prisma wave btw?

prisma wave
#

got messy

onyx loom
#

imagine

steel heart
#

alex consider you have 3 facepalms I think not

prisma wave
#

there were like 3 different overloads for a 6 argument constructor

#

in kotlin you could've done default parameters

#

in java it's idiomatic to make a builder

heady birch
#

Ecloud

#

Javascript 🤢

steel heart
#

java is bad but its doable

prisma wave
#

it's no clojure

old wyvern
#

in elara, its idiomatic to not use constructors PlusOne

prisma wave
steel heart
heady birch
#

did you think vue + js was a good idea?

prisma wave
#

vue + clojurescript

#

🙂

heady birch
#

thymeleaf did the job fine

prisma wave
#

more like dumbleaf

onyx loom
#

so kind of u to have already changed the kotlin example on pdm github

#

thanks

#

🙂

steel heart
#

Skript is superior no cap

prisma wave
#

you're welcome

#

🌚

steel heart
#

yep

heady birch
#

Im gonna conitnue ecloud

#

In thymeleaf

old wyvern
#

Why does that emoji look like someone with the plague

heady birch
#

RIP docker but Im different

#

ITs moon

prisma wave
#

poor docker

#

on a similar note

#

dokka 1.4 is the best thing jetbrains have ever made

steel heart
#

i like intellij

prisma wave
#

ok but dokka

ocean quartz
heady birch
#

yes

steel heart
#

can we escape it as well?

ocean quartz
#

I can make that happen

steel heart
#

I mean yeah that would be cool

hot hull
#

#<HEX> :((

ocean quartz
#

Why though? if you will have the # outside might as well just do #hex

steel heart
#

^

heady birch
#

What abt 3 digit

#
public static Colour ofHex(String hex) {
        if (hex.charAt(0) == '#') {
            //remove # if present.
            hex = hex.substring(1);
        }

        switch (hex.length()) {
            case 3:
                //parse format 3-digit 'FFF'. duplicate each char
                hex = shortHand3DigitTo6Digit(hex);
            case 6:
                //parse into decimal value.
                final int decVal = Integer.parseInt(hex, 16);

                //parse format 6-digit 'FFFFFF'
                return new Colour(
                        (decVal >> 16) & 0xFF, (decVal >> 8) & 0xFF, decVal & 0xFF);
        }

        throw new IllegalArgumentException("The value '" + hex + "' could not be constructed into a valid colour.");
    }
#

(c) kiteboard

ocean quartz
#

Sounds fun i can try 3 digits as well

#

Also escaping this is pretty hard because of the many styles

#

might remove it

hot hull
#

do it.

old wyvern
#

#555555> is also matched

ocean quartz
#

Only down side is that <#hex would work, without the las >

old wyvern
#

hmm

ocean quartz
jovial warren
#

@heady birch Thymeleaf?

#

what's that like?

heady birch
#

thymeleaf is pretty nice

jovial warren
#

you using Thymeleaf with Spring?

heady birch
#

Not anymore

#

Ecloud was at first

jovial warren
#

why not?

heady birch
#

lemmo wanted to seperate frontend/backend

winter iron
#

Yo

#

what domain provider do you guys use for a personal website

#

and do you make your own websites with web builder or just create it yourself

onyx loom
#

website builders Kappa

#

namecheap is pretty good afaik

old wyvern
#

I used godaddy for domain for most of mine. and i prefer to create it myself

onyx loom
#

godaddy is good too, abit expensive tho tbh

old wyvern
#

are the domain prices any different?

onyx loom
#

yes

winter iron
#

how do u guys host ur websites then

onyx loom
#

most just have vps

old wyvern
#

mhm

onyx loom
#

using hosts such as hetzner, digital ocean etc

winter iron
#

Sounds good, just looking at some options and I might consider buying one

quiet sierra
#

Check out porkbun for domains

#

got my domain for like 7$

pastel imp
#

hmm question of the day!

#

soo

#

I have always seen people using return true/false in commands

#

I mean... ok when it returns it ignores the rest of the code from that point on

#

but what's the difference between return true and false?

quiet sierra
#

returning false will send the usage defined on the plugin.yml

onyx loom
#

return true will display the command i believe

pastel imp
#

wdym by display the command?

quiet sierra
#

return true will consider it well executed and send nothing more

onyx loom
#

yea that

winter iron
#

it will send message to player

#

the command

pastel imp
#

ooh ok

#

so if I don't want any message to be sent

winter iron
#

like how to use it

onyx loom
#

but ew, using spigot for commands

pastel imp
#

I should use true

quiet sierra
#

If you return false

#

it will automatically send /test

winter iron
#

^

quiet sierra
#

so don't

pastel imp
#

k ty

#

and yes

#

I use spigot's system

winter iron
#

use matt's framwork i suggest

#

very good

pastel imp
#

cause I am stupid enough to NOT make my own

onyx loom
#

matt framework 🙂

#

🌝

pastel imp
#

ye I discovered the framework

#

yesterday

winter iron
pastel imp
#

still need to check how to rlly use it

#

properly

winter iron
#

very simple

onyx loom
#

its easier than spigot imo

winter iron
#

all in the annotations

quiet sierra
#

I barely use commands so..

pastel imp
#

ye rlx

#

gonna check it

#

matt should add dark theme omg

#

my eyes

#

lol

versed ridge
#

Dark Reader extension

onyx loom
#

^^

#

best extension

pastel imp
#

oof ty

versed ridge
pastel imp
#

so just to understannd

#

subcommands are like

#

/defaultcmd subcmd?

onyx loom
#

yup

pastel imp
#

I suppose it only support one subcmd?

onyx loom
#

as many as u want

winter iron
#

u can do like "subcmd subcmd2"

pastel imp
#

what if I want to have a custom argument

#

like /cmd subcmd nick string

winter iron
#

your arguments are put in the method parameters

#

u can use some of the builtin stuff

winter iron
#

or make ur own

hot hull
#

If you have to use more than 1 sub command you should probably restructure your command system fingerguns

pastel imp
#

xd

#

ok I think I understood

#

thx

#

bruh

#

shadowJar {
   relocate 'me.mattstudios.mf', '[YOU PACKAGE].mf'
}
#

how tf is this in kts?

#

cause I am using build.gradle.kts

#

but never used shadow

#

in gradle

#

so don't rlly know

winter iron
#

u need to shade the framework

pastel imp
#

ye

winter iron
#

sec

pastel imp
#

never did it though

winter iron
#

so like

#

u dont need apply

pastel imp
#

and as I am using kts

#

kinda sucks

onyx loom
#

dont use kts then 🙃

versed ridge
#

ez

pastel imp
#

welp kinda late to change from kts to normal don't you think

#

lol

ocean quartz
#

Can't add dark theme since GitBook doesn't have it yet so well

pastel imp
#

oof

#

welp

#

think I am gonna need to see a way to go from kts to java gradle

#

lol

ocean quartz
#

@pastel imp this should do it:

plugins {
    id("com.github.johnrengelman.shadow") version "5.2.0"
}

tasks.shadowJar() {
    relocate("me.mattstudios.mf", "[YOU PACKAGE].mf")
}
winter iron
obtuse gale
#

@ocean quartz, I was looking at some examples for your MF-GUI and in most gifs you have, whenever you click an item it doesn’t get picked up, then placed back, it just stays stationary

#

is there a way to do that in newer versions or was it just skipping frames because it’s a gif

pastel imp
#

isn't that just canceling the click event

#

lol?

#

oh wait

#

ok it fixed

#

lol

ocean quartz
#

@obtuse gale It's because on localhost there is no lag so the event is canceled instantly not letting the client see the picking animation

obtuse gale
#

gotcha

#

I was slightly erect for a second there

ocean quartz
#

It'd be great if the client waited for the handshake before starting the animation, but well minecraft

obtuse gale
#

it would be dope but I guess everyone’s used to it by now

#

maybe I should make a mod for that

#

@winter iron it might be better to make the refund command a little more specific to the plugin. I could see other economy related plugins using /refund

winter iron
#

hmmm

#

maybe

#

I havn't seen a plugin use the refund command before tbh

#

but would make sense

remote goblet
#

ive never seen a single eco plugin doing a /refund cmd

#

@prisma wave would there be anything similar to shadow's mergeServiceFiles in pdm ?

#

using pdm on discord bots is hella useful

heady birch
#

no main manifest attribute

remote goblet
#

congrats

#

you can read

heady birch
#

add a main manifest attribute

#

🙂

onyx loom
#

🌚

remote goblet
#

there is one mmSitStareMocha

onyx loom
#

apparently not 🌝

ocean quartz
#

@remote goblet on your gradle add the plugin id 'application'
Then add mainClassName = "your.path.MainKt" under the group/version

#

Noice this is perfect, now it keeps all the formats including gradient

hot hull
#

Why does it account for one space and not the others?

ocean quartz
#

trying to fix that right now

#

actually i think it does need to save spaces hmm

lavish notch
#

Might anyone know how to cancel the spectator entity perspective view?

IE: When I click on an entity to view it's perspective in spectator

I've tried cancelling PlayerTeleportEvent, PlayerInteractevent, PlayerInteractEntityEvent and PlayerInteractAtEntityEvent.

remote goblet
prisma wave
#

@remote goblet pdm doesn't have any control over the building process, could the jar plugin do that?

#

Or the application plugin

ocean quartz
#

Add Kt at the end

prisma wave
#

^

signal tinsel
#

Should I upload my plugin lib to maven central?

remote goblet
#

I still get it

prisma wave
#

does it actually compile a MANIFEST.MF ?

remote goblet
ocean quartz
#

Maybe it's missing this?

sourceSets {
    main.kotlin.srcDirs = main.java.srcDirs = ['src/main/kotlin']
    main.resources.srcDirs = ['resources']
}
remote goblet
#

lets find out

#

250kb jar file so its not painful to upload

prisma wave
#

pdm gang 😎

onyx loom
#

😎

remote goblet
prisma wave
#

what's your main class/file

#

actually

#

send the jar over or something idk

remote goblet
ocean quartz
#

That's all i have and it works

remote goblet
#

and then it disappeared

#

holup

remote goblet
prisma wave
#

throw NullPointerException("Command aliases is null") 😡

#

also

#

you nicked that code from my unit tests

#

didn't even change the applicationName

#

smh

signal tinsel
#

Lol

remote goblet
#

yeah i directly coppied it

signal tinsel
#

Go fucking cry @prisma wave

#

Lol

prisma wave
#

😭

#

noooo you can't just use the name "PDM Test Suite" for the application name! it's supposed to be the actual application name!!!! nooooo

ocean quartz
#

You bring shame to Kotlin!

prisma wave
#

True shame

#

😔

remote goblet
#

I fixed it now mmSitStareMocha

prisma wave
#

yay

ocean quartz
prisma wave
#

hideous

remote goblet
#

i'll remove that later

signal tinsel
#

Should I upload my plugin lib to central or no

prisma wave
#

why not

remote goblet
#

I gotta sort out this main class entirely

old wyvern
#

🍬

#

km operator precedance finally works

prisma wave
#

throwing NPEs manually, static, unnecessary try/catches, literally using a temp directory for pdm's libraries

#

@old wyvern huge

old wyvern
#

🍉

surreal quarry
#

what would be the way to go about extending a data class in kotlin
for example, if I have a User data class, how can i extend that into another data class with the exact same members but also a couple others? is this possible

signal tinsel
surreal quarry
#

or should the new class be of a User and the new pieces

signal tinsel
#

Is there a java default version of this?

empty flint
#

@prisma wave I just set up the same project structure that you had in the pdm project you linked. When I open the root project and open one of the subprojects' build.gradle.kts files, IntelliJ is telling me that "The associated Gradle Project isn't imported"

#

Any advice?

prisma wave
#

you added it to settings.gradle.kts?

empty flint
#
rootProject.name = "BlockyRoot"
include("BlockyLib")
include("BlockyRanks")
#

The same way you did

prisma wave
#

probably just an intellij thing

#

if you reopen the project it should refresh itself

empty flint
#

Hm no it doesn't

prisma wave
#

@surreal quarry data classes have to be final

#

@empty flint close the project, and do new > project from existing sources

#

and select the root buildscript

signal tinsel
#

Why are java users ignored

empty flint
#

@empty flint close the project, and do new > project from existing sources
@prisma wave Again, no dice. Idk what to do anymore. Probably just gonna go back to Maven

#

It says I can import the gradle subproject

#

but

#

When I look at the Gradle Tool Window, it is already imported

prisma wave
#

Is that a problem?

#

Seems more like it's an intellij bug tbh

#

Maybe delete all the iml and .idea stuff and do a clean reimport

empty flint
#

I don't know and don't care, I just want it to work. The Gradle Tool Window says the dependency is there

prisma wave
#

Why are java users ignored
@signal tinsel inferior

empty flint
signal tinsel
#

No u @round shale

#

Fuck

prisma wave
#

Ha

signal tinsel
#

@prisma wave

prisma wave
#

Wait...

signal tinsel
#

I typed @bri

#

Yes briannas in here

round shale
#

👋

prisma wave
#

Moving on

#

Lol

round shale
#

Hi hi ^-^

prisma wave
#

good day

old wyvern
#

Who is brianna?

round shale
#

Me :3

old wyvern
#

oh wait

prisma wave
#

Songurda person

#

The banned word

#

Lol

round shale
#

Or probably lots of other people with the same name.

old wyvern
#

No heard about you

#

im out

round shale
#

Hmm?

prisma wave
#

@empty flint and it can't find the bukkit classes right?

empty flint
#

@empty flint and it can't find the bukkit classes right?
@prisma wave It can't find the classes, when I open the submodule as a project it says the following 2 things as well:

#

and

round shale
#

Gotta define your sdk ^-^

prisma wave
#

^

ocean quartz
#

You need to set that in the project structure

prisma wave
#

Again seems like more of an intellij problem

empty flint
#

Project directory '... Workspace\Blocky Root\Blocky Ranks' is not part of the build defined by settings file '...Workspace\Blocky Root\settings.gradle.kts'. If this is an unrelated build, it must have its own settings file.

round shale
#

ctrl shift s on windows I think?

ocean quartz
#

I think so yeah

prisma wave
#

Show the entire project structure

empty flint
#

Gotta define your sdk ^-^
@round shale Well shit why did I not think of that. I thought I had to stick a banana in the air intake of my PC

prisma wave
#

lol

round shale
#

I really don't like cursing :c

ocean quartz
#

Jesus

prisma wave
#

That might work too

empty flint
#

I really don't like cursing :c
@round shale I could give a fuck

old wyvern
#

ctrl + alt + shift + s

ocean quartz
#

Blocky chill out

prisma wave
#

let's stay on topic

tranquil crane
#

🤔

round shale
#

Yeah @old wyvern's got the right idea. That sounds right.

remote goblet
deft terrace
#

hmmmm

empty flint
#

Blocky chill out
@ocean quartz Sorry, I'm really agitated by gradle and ij and this off-topic shit is giving me anxiety

#

Show the entire project structure
@prisma wave Coming, just a sec

ocean quartz
#

I understand but no need to discount that on people

prisma wave
#

@empty flint can you put the entire project on github (source code isn't important) and show us as well

round shale
#

Okay well I'll go. You all have a fantastic rest of your day ❤️

prisma wave
#

aidos

remote goblet
empty flint
#

@empty flint can you put the entire project on github (source code isn't important) and show us as well
@prisma wave Gimme a sec

prisma wave
#

ok

remote goblet
#

yeah blame maffie for the demon entering the chat

signal tinsel
#

Lmaooooo

prisma wave
#

lol

old wyvern
#

😂

prisma wave
#

i didn't think it was possible for an online text chat to be awkward

heady birch
#

No cascade?

#

Cascade it all

old wyvern
#

cascade?

heady birch
#

Remove my account

prisma wave
#

ok

old wyvern
#

um?

remote goblet
#

happily

#

ion like you anyway

old wyvern
#

🙃 .

prisma wave
#

wow

#

i thought we were all best friends

#

😭

ocean quartz
#

😢

heady birch
#

Obviously not then

onyx loom
#

besties

#

what happened

heady birch
#

They cant remove my account

prisma wave
#

i will try

#

for you

#

🙂

old wyvern
#

xD

prisma wave
#

tried it

#

didnt work

#

soz

heady birch
#

Ok thank you

#

Appreciate

old wyvern
heady birch
#

Intrisics

old wyvern
#

?

#

just accidental recursion

#

welp

prisma wave
#

there are no accidents

#

🙂

empty flint
old wyvern
#

xD

prisma wave
#

@empty flint it's probably because of the spaces

empty flint
#

in the folder structure you mean?

prisma wave
#

include("BlockyRanks"), the directory itself is called "Blocky Ranks"

#

yeah

#

it probably can't find the module or whatever

empty flint
#

But shouldn't it say so?

#

Because you can set up the project name and the project location

#

the spaces shouldn't matter

#

you're importing the project by name, not by folder structure

#

... I think

prisma wave
#

but if gradle can't find the module

#

just try changing it

#

i'm fairly confident that will fix it

empty flint
#

Will try

#

Well suck my nipples and call me skippy.

include("Blocky Ranks") worked.

#

❤️

prisma wave
#

and i'll pass on the nipple sucking

empty flint
#

That's fine, I wouldn't do that either I don't think

#

But

#

Thank you very much, I've been struggling with all the shit IntelliJ is telling me were problems when it was the spaces all along

tranquil crane
prisma wave
#

the hardest problems have the easiest solutions

#

put that on my gravestone

empty flint
#

the hardest problems have the easiest solutions
@prisma wave Idk man, the Poincaré conjecture has several hundred pages of proofs. I think that only applies to stuff developers do...

#

not to problems of actually smart people

prisma wave
#

indeed

old wyvern
#

@prisma wave SUCESSSSSS

prisma wave
#

👏 👏 👏

old wyvern
#

Writing a quick test and pushin

winter iron
#

anyone has experience with proguard and shadowjar

#

together

jovial warren
#

okay the new Kotlin 1.4 additions are actually pretty useful

#

like being able to declare a functional interface with fun interface, which just makes the language more readable

prisma wave
#

trailing comma support tho

#

And dokka 1.4

steel heart
#

I feel like this is a very nasty constructor

                               (String name,
                               int maxLevel,
                               int startLevel,
                               EnchantmentTarget enchantmentTarget,
                               Predicate<Enchantment> conflictsWith,
                               Predicate<ItemStack> canEnchantItem,
                               EnchantmentTier enchantmentTier,
                               Map<ItemStack, Double> killDrops,
                               Map<ItemStack, Double> mineDrops,
                               Map<String, Double> killEnchantDrops,
                               Map<String, Double> mineEnchantDrops)
jovial warren
#

wait Dokka 1.4?

#

please tell me that adds in the option to configure the CSS

#

I feel like this is a very nasty constructor

                               (String name,
                               int maxLevel,
                               int startLevel,
                               EnchantmentTarget enchantmentTarget,
                               Predicate<Enchantment> conflictsWith,
                               Predicate<ItemStack> canEnchantItem,
                               EnchantmentTier enchantmentTier,
                               Map<ItemStack, Double> killDrops,
                               Map<ItemStack, Double> mineDrops,
                               Map<String, Double> killEnchantDrops,
                               Map<String, Double> mineEnchantDrops)

your feeling is right lol

prisma wave
#

@jovial warren idk about that

#

but it does more important things

#

code samples that you can actually run

#

nice looking docs

#

etc

#

it's great

ocean quartz
jovial warren
#

of course it is lol

prisma wave
#

why does it say them twice?

jovial warren
#

yeah good point

steel heart
#

well

#

its their values before?

ocean quartz
#

One is the this.actions the other is actions

steel heart
#

^

prisma wave
#

ah right

#

makes sense

jovial warren
#

also @prisma wave this may be something you know
how does annotation processing work in Kotlin?

prisma wave
#

good question

#

on the jvm it's pretty much the same as java

#

as far as I know

jovial warren
#

basically I want to do a real sneakys and get all classes on classpath annotated with a specific annotation lol

prisma wave
#

annotation processing won't do that

jovial warren
#

no but reflection can can't it?

prisma wave
#

you want a tool like ClassGraph or org.reflections

#

not pure reflection

steep bough
#

where can i find the dev build for deluxemenus?

#

1.16.1

prisma wave
#

not in this channel

#

lol

steep bough
#

Well obviously xD

onyx loom
#

on the plugin page

steep bough
#

hey thanks i appreciate it

steel heart
#

hello there

#

oh its not even kenobi

prisma wave
#

general kenobi

jovial warren
#

@prisma wave yeah I'll try using org.reflections then

prisma wave
#

eh

#

classgraph better

#

imo

steel heart
#

use Skript lol

jovial warren
#

alright teach me the ways then

#

@steel heart get out

steel heart
prisma wave
jovial warren
ocean quartz
#

Fun, this action becomes empty somewhere that i can't find .-.

prisma wave
#

possibly

#

yes

jovial warren
#

actually I've got a better idea than my original one, one I know exactly how to do with org.reflections

steel heart
jovial warren
#

@prisma wave what's the ClassGraph equivalent of Reflections().getSubTypesOf?

steel heart
#

oo its tuesday for me now

jovial warren
#

noice

prisma wave
#

@jovial warren something in ScanResult

#

idk

#

not used it in a while

onyx loom
#

where u from conclure?

prisma wave
#

the api is fairly self explanatory though

jovial warren
#

wait I've discovered a problem with my new idea

#

maybe my original idea wasn't so bad after all

steel heart
#

isnt it like new ClassGraph().whitelistPackages("package").getClassesImplemeting("package.Interface") or smtng

prisma wave
#

something like that

jovial warren
#

I want to be able to register all of my commands really easily, but the problem is: they all require different Spring services
so I was thinking that I could just annotate them all with a specific annotation that's annotated with @Component to let Spring do the DI and then get all of Spring's component instances using classes annotated with that specific annotation somehow and register them like that

prisma wave
#

wait

jovial warren
#

oh this is easier than I thought

prisma wave
#

there is literally no need to use a classpath scanning tool with spring

jovial warren
#

true

#

ListableBeanFactory#getBeanWithAnnotation maybe

prisma wave
#

might work

#

or just define a common superclass

#

and use multibinding

jovial warren
#

I have a common super class

#

only problem is: it isn't a Spring component

#

since it's Octo's Command class, and since Octo is designed to work with pretty much anything, it can't use Spring

prisma wave
#

it doesn't have to be

jovial warren
#

senpai teach me the ways then

prisma wave
#

you can just @Autowired Set<Command> commands

#

it should pick them all up

jovial warren
#

btw you're forgetting who I am giving me Java code xD

prisma wave
#

was easier to type

#

lol

jovial warren
#

so I can get away with that?

prisma wave
#

I believe so

jovial warren
#

just ```kotlin
@Service
class CommandService(
private val commandManager: CommandManager,
private val commands: Set<Command>
) {

@PostConstruct
fun registerCommands() = commandManager.registerAll(commands)

}

#

that's ez

#

okay Spring is now on god tier

#

oh my god it actually works lol

prisma wave
ocean quartz
#

Fuck me, found the problem, Java's list mutability..

prisma wave
#

classic

jovial warren
#

wait what even was your issue? lol

#

ah an array list's elements disappearing

#

I believe Commons Lang has immutable collections

#

I mean, yes it does, but Guava also has it, and probably does it better

ocean quartz
#

Yup exactly that, had to do new ArrayList<>(actions) which is hacky, so i'll do a better solution in a second

toxic crow
#

Hey I have a problem with my Pluginn i'm doing a cooldown of 24hours but when I /rl or it restart automatically, the cooldown disappears, is there a way to save the cooldown plz ? Thanks 🙂

jovial warren
#

persist it

#

save the time that it'll expire in some sort of on-disk storage format

#

(database, file, etc.)

surreal quarry
#

store it in a file or db

toxic crow
#

how?

ocean quartz
#

The way i handle cooldowns is by saving the System.currentTimeMillis() to a file of when the cooldown starts
Then checking with the current System.currentTimeMillis() and seeing the cooldown

surreal quarry
#

^

empty flint
#

what Matt said

toxic crow
#

oh ok

#

lemme try this

jovial warren
#

@ocean quartz what????

toxic crow
#

so like i can save the System.currentTimeMillis() in my config.yml ?

surreal quarry
#

yes

#

bardy what do you do?

jovial warren
#

save the expiry date and check the expiry date against the current time

#

that's what I would do

surreal quarry
#

i guess thats the smae thing

#

just a bit different

jovial warren
#

so much easier to keep track of

steel heart
#

does commodore work with 1.12-?

#

ik it says 1.13+ but if anyone got it working under 1.13 pls tell me

jovial warren
#

Spigot, just like pretty much every other project ever made, is forwards compatible, not backwards

ocean quartz
#

@jovial warren You do something and save the time of the action, later you check the new time of the action and compare it to the previous one and you get the time difference between them, now you have your cooldown

toxic crow
#

@ocean quartz When I think about it, i don't really know how could i do that can u explain me plz?

jovial warren
#

@ocean quartz yeah that works

toxic crow
#

(i'm french so maybe that's why i don't rlly understand that much ^^" )

jovial warren
#

I'm so glad I don't have to worry about memory usage now I've got 32GB of RAM instead of 8 lol

onyx loom
#

32gb flex 😔

empty flint
#

@ocean quartz When I think about it, i don't really know how could i do that can u explain me plz?
@toxic crow You measure the time since the cooldown started or the time until the cooldown is over. How you measure that is up to you. There's great tutorials on how to use CurrentTimeMillis()

jovial warren
#

currentTimeMillis()* ^

#

Dr. Nitpicker in action

ocean quartz
#

@toxic crow Something like:

final long actionTime = System.currentTimeMillis();
// Save this value to your config or better, a differnt file

// when clicked again:
final long timeDifference = System.currentTimeMillis() - actionTimeFromConfig;
// now turn this from millis to seconds and compare to how big your cooldown is
steel heart
#

imagine static import

jovial warren
#

32gb flex 😔
lol, cost my parents £120 for that

#

actually cost me in money I'm paying them back with when my lego gets sold (which my parents paid for so still their money lol)

steel heart
#

lmao

surreal quarry
#

F in the chat for the legos

onyx loom
empty flint
#

actually cost me in money I'm paying them back with when my lego gets sold (which my parents paid for)
@jovial warren I would have never sold my legos to pay for ram. What kind of monster are you?!

onyx loom
#

that moment when u say its ur money but its actually ur parents money from ur birthday 🙃

steel heart
#

There is no such more powerful thing as lego

ocean quartz
#

Now to make it actually work

steel heart
#

ayee

jovial warren
#

@empty flint everybody knows that building lego is the best part and the only good part

empty flint
#

@empty flint everybody knows that building lego is the best part and the only good part
@jovial warren Boy, how you gonna build Lego if you sell them?!

jovial warren
#

I've had these lego sets for years now

empty flint
#

You build it, let it get dusty, accidentally drop if when cleaning it after a year on your shelf and then you get to re-build it again fool

jovial warren
#

lol

ocean quartz
#

Is there any better solution than new ArrayList<>(oldList) for copying a list? thonking

jovial warren
#

ImmutableList.copyOf

ocean quartz
#

i miss kotlin

jovial warren
#

from Guava

steel heart
#

I believe there is a factory method as well

jovial warren
#

or just make an ImmutableList

#

@ocean quartz if you miss it then why tf aren't you using it you silly goose

empty flint
#

Is there any better solution than new ArrayList<>(oldList) for copying a list? thonking
@ocean quartz Why do you need a better solution? Like what's the problem with that solution for you?

jovial warren
#

it's mutable

#

and that's a problem for Matt

#

because he's a 3 head

#

xD

steel heart
#

its too long to write

ocean quartz
#

@jovial warren There are times that you can't use Kotlin
@empty flint And it's because it's ugly, nothing more

jovial warren
#

@ocean quartz give me one good excuse

#

@prisma wave you can be the judge of this lol

surreal quarry
#

libs sad_fingerguns

ocean quartz
#

No one will want to shade a 1.5MB lib

prisma wave
#

p

empty flint
#

@jovial warren There are times that you can't use Kotlin
@empty flint And it's because it's ugly, nothing more
@ocean quartz make a wrapper method fingerguns

prisma wave
#

pdm

jovial warren
#

^

onyx loom
#

PEE DEE EM

surreal quarry
#

just force them to use kotlin then your lib is smaller fingerguns

prisma wave
ocean quartz
#

Can't pdm a lib of a lib

prisma wave
#

you can now

#

well

#

get whoever uses the lib to use pdm

onyx loom
#

no dont say anymore

empty flint
#

What does pdm do actually?

ocean quartz
#

That would require the user to do all sorts of things lol, it's not worth it

onyx loom
#

you can now
looks like u gotta start rewriting in kotlin fingerguns

surreal quarry
#

@empty flint it stores all your dependencies in your plugins folder for your other plugins to access to make jar size smaller

prisma wave
#

@empty flint downloads dependencies at runtime

empty flint
#

@empty flint downloads dependencies at runtime
@prisma wave What dependencies and why?

onyx loom
#

smaller jar size

surreal quarry
#

the plugin dependencies. make jar size smaller

prisma wave
#

^

#

and speeds up build time

empty flint
#

why would the jar size matter?

prisma wave
#

spigot places restrictions

#

and also

#

it's just cool

onyx loom
#

very cool 😎

empty flint
#

I mean... ok...

prisma wave
#

when it works

old wyvern
#

Also, people cancel random plugin downloads if they are large and dont matter to me too much

jovial warren
#

if only fucking md_5 shaded Kotlin in to Spigot :/

empty flint
#

Dunno, seems like a solution to a problem that isn't actually a problem

prisma wave
#

it is a problem

onyx loom
#

if only fucking md_5 shaded Kotlin in to Spigot :/
@jovial warren thonking

prisma wave
#

since there's a size limit for premium plugins on spigot

jovial warren
#

or better yet just rewrote the entirety of the server-side Spigot in Kotlin (excluding the API)

empty flint
#

Also, people cancel random plugin downloads if they are large and dont matter to me too much
@old wyvern fuck em

onyx loom
#

0 kotlin files in spigot

prisma wave
#

shading kotlin into spigot would be a bad idea

onyx loom
#

shades kotlin

#

👍

prisma wave
#

it would always be hopelessly outdated

old wyvern
#

fuck em
have fun doing that

jovial warren
#

very very true

old wyvern
#

Anyway

#

bm

#

check the git channel

#

🍉

jovial warren
#

git channel? what's this you speak of? xD

old wyvern
#

Not here

empty flint
#

since there's a size limit for premium plugins on spigot
@prisma wave Can't you just provide spigot with the download link to the plugin? That's how I do it anyway, dunno if it works for premium plugins as well tho

prisma wave
#

idk

jovial warren
#

yeah but that's a pain

prisma wave
#

but runtime downloading is nothing new

#

lots of plugins do it

jovial warren
#

since then you have to upload it to like mediafire or something if you're not me and don't own a load of random VPS' you could just shove it on

#

also @prisma wave is there any way to perform assignment in an expression function btw?

prisma wave
#

no

#

assignment isn't an expression in kotlin

#

and rightly so

jovial warren
#

totally not a purposeful plug to get more people to check it out lol

prisma wave
#

not really avoidable