#dev-general
1 messages ยท Page 134 of 1
ActionLib
@hot hull You have any example of actions I can use for testing?
Does it display stuff for OP by default or is it defaulted to vanish?
It uses the highest priority format
I'm assuming it's not working then
Why?
Nothing shows
Talking about my changes though
Yea it'll still show you what's going on
Yeah it shows nothing lol
Make sure it actually enabled 
It did
@hot hull Is that supposed to just take the first entry?
Yes
Frosty my boy, I reverted all my changes and still nothing shows, doesn't even error out xD
Alrighty
I mean I've not tested it at all on kotlin, so idk Matt, keep the changes and pr
And I'll do some debugging
(If it doesn't error that's nice
)
Alrighty
@old wyvern It get's sorted above for the player, and then just uses the first one in the sorted list
No no, my changes weren't great it was just for testing xD
Ah ok frost, Im fixing stuff up, ill open a PR in a bit
Okay yea, just don't y'all be pring at the same time, cause my mind gonna explode
๐
Matt, if you don't consider the actions part of it, how does the code look?
Wtf is this class frosty?
If everything in it is going to be a companion object, just make it an object lol
@heady birch Sorry probably last ping I swear, but when I started using Spring you unkowingly consented to provide 240/70 support :))))))))
https://dzone.com/articles/add-login-to-your-spring-boot-app-in-10-mins Is this a good way of doing it? Seems like it'd do what I want, but with GH instead of Discord. I could probably figure that bit out though i hope
Matt, did not know that 
That is not good
Yes
Try it
Make sure you follow the github bit
Theres like 5 seperate tutorials in that page
I think with oauth it should all work the same between github discord e.g
Discord iirc does it a bit differently, thats why I had to do this ```kotlin
@Bean
fun accessTokenResponseClient(): OAuth2AccessTokenResponseClient<OAuth2AuthorizationCodeGrantRequest?>? {
val client = DefaultAuthorizationCodeTokenResponseClient()
client.setRequestEntityConverter(object : OAuth2AuthorizationCodeGrantRequestEntityConverter() {
override fun convert(oauth2Request: OAuth2AuthorizationCodeGrantRequest): RequestEntity<*>? {
return super.convert(oauth2Request)?.withDiscordUserAgent()
}
})
return client
}
@Bean
fun userService(): OAuth2UserService<OAuth2UserRequest?, OAuth2User?>? {
val service = DefaultOAuth2UserService()
service.setRequestEntityConverter(object : OAuth2UserRequestEntityConverter() {
override fun convert(userRequest: OAuth2UserRequest): RequestEntity<*>? {
return super.convert(userRequest)?.withDiscordUserAgent()
}
})
return service
}```
But anyway
ima try it
Hey, does anyone here know MySql?
I can barely code plugins, but I need to make a random code-generating plugin
Why would you need MySQL for that?
Because i'm hooking it up to my Discord bot
So people can get a code in game, and redeem it in discord
I know how to write discord bots that interface with mysql, so I thought it made sense to make the plugin do the same
You could make the bot within the plugin itself so you can use a flatfile storage such as Sqlite or json. This will save money with storage and be easy
Ok
how I need to figure out how to register a command ๐
I'm very new to the spigot api
Ah. Are you new to java?
You may want to learn java before you dive into a project like this
oh, would this be complicated?
Yes. Sorta
ah... ok!
so you think the Discord JDA is simpler than MySQL?
because i've heard MySQL is pretty complicated with java, but idk
Eh depends. Discord Jda is quite simple once you know java syntax. Mysql in java is a bit of complicated process.
ok, got it
MySQL is pretty straightforward with libs like Hikari (even without a lib it's decent)
well, idk what a lib is, so I guess i'll try the Discord JDA ๐
JDS?
Yugi, how's it coming along?
Look into spring boot
Working on message formatter
@hot hull Any reason why you used player#effectivepermissions and compared for permission instead of just has perm?
Is effectivePermissions diff?
It temporarelly fixed having the * perm fucking all the formats
Not sure if it still works tho
Should I keep it like that ?
Yea
Alrighty
Anyone wanna make me a website?
website for?
What u want
Niall
as in a Portfolio?
What you want?
Make a repo with your name and then create a readme, if you are talking about what sxtanna has @heady birch
famalam, can someone gimme a hand? im trying to create an itemstack with a custom player head but i cant figure out the new implementation
sorry for moving this message around, im trying to figure out where it belongs
#development Specifically..
Easy - set skull owner
"Harder" - use a base64 value and some stuff to use any skin
?codeblocks
Use codeblocks for formatting code or configuration files:
```<language name>
<your code here>
```
For example:
```yaml
test:
- โhiโ
- โthereโ
```
Produces:
test:
- โhiโ
- โthereโ```
It doesnt work on skeleton skull
Also, it's PLAYER_HEAD iirc
wha xD
ah xD
is it possible for A plugin that only allows players with certain permissions to enter, if a player without the permission tries to enter it instantly and constantly teleports them back and says you do not have permission to enter this area.
add members to the region?
but then cant they break it
check the wiki <o/
@hot hull Are the actions supposed to be executed before the event is called?
I haven't sorted the events out just yet, I just made placeholders and copied the logic to there
I'll organise that tommorrow
ah ok
(making custom events so people can have more control with different plugin)
The logic will be in the frozenjoinevent listener
Wait what?
which logic are you talking about?
You shouldnt listen to your own event for that purpose
The shit that's currently in the player join event
Ah, I'll make a check to see if mine was cancelled and if it wasn't, execute the logic I guess?
Um yea it should be more of,
Find actions to be executed
Call event -> event resolves
Use result to run your logic```
Kk, I'll do that tommorrow, cause I gotta change the event anyways
Alrighty

:))
hey anyone got any idea how I can do unknown amounts of properties in an application.yml file?
(e.g.) ```yaml
hello:
property1:
key: value
property2:
key: value
its just a map?
what the properties are just a map?
ah okay
@hot hull Heads up
?
PRed
Not on pc anymore, thanks tho
๐
Havent touched action lib things btw
Ill have a look at that at some other time
have to wake up early tmr
Imma remake it from scratch anyways
Alrighty lit!
hey @heady birch I call upon thee
Hi
how good are you with application.yml in Spring?
I've only used application.properties
im fairly sure spring could deserialize a Map<String, Any>
is there a chance that noflyzone will be updated to 1.16?
yea it's called WorldGuardExtraFlags ๐
the one that gets all items in a list, and all the guides I can find have their configs laid out like this: ```yaml
helloworld:
mylist:
myproperty: hello
myotherproperty: world
but I want to remove that - (list declaration) and load them as kinda properties
idfk
what in the config class?
yes
@Configuration
@ConfigurationProperties(prefix = "lavalink")
class LavalinkConfig {
lateinit var nodes: List<NodeConfig>
class NodeConfig {
lateinit var name: String
lateinit var url: String
lateinit var password: String
}
}
```what I got so far (the inner class comes from the stackoverflow answer)
so I just replace that nodes thingy with a map or what?
it's gonna look something like either: yaml lavalink: nodes: "node-1": name: lavalink-node-1 url: wss://localhost:9000 password: TheWorldsBestPassword "node-2": name: lavalink-node-1 url: wss://localhost:9000 password: TheWorldsBestPassword or ```yaml
lavalink:
"node-1":
etc...
it's so if you self-host it you can give it as many nodes as you like
and so I can easily expand it if I need to
yes
okay
which class/field gets annotated with that?
and also what do I replace lateinit with?
configuration classes should always be data classes imo
help
wrong channel
^^^^
anyway, so I should have it look something like: ```kotlin
@Configuration
@ConfigurationProperties(prefix = "lavalink")
@ConstructorBinding
data class LavalinkConfig(val nodes: Map<String, NodeConfig>)
where do I put the inner class though if it's a data class?
but yes
inside the class?
being a data class doesn't change anything about inner classes
can data classes have bodies?
yes lol
all data class means is to generate equals/hashCode/toString/copy for the constructor parameters
apparently says could not autowire now
where?
at nodes
@Configuration
@ConfigurationProperties("lavalink")
@ConstructorBinding
data class LavalinkConfig(val nodes: Map<String, NodeConfig>) {
data class NodeConfig(val name: String, val url: String, val password: String)
}
nodes shows up as red and says could not autowire
does the inner need to be @Configuration or what?
remove @novel badgeruration
oops
sorry
@novel badgeruration
you know what I mean
lol
sorry for the pings
He's a cool dude, he probs won't get mad 
not registered via @EnableConfigurationProperties, marked as spring component, or scanned via @ConfigurationPropertiesScan
okay
yeah that fixed it
@ConfigurationProperties("lavalink")
@ConstructorBinding
data class LavalinkConfig(val nodes: Map<String, NodeConfig>) {
data class NodeConfig(val name: String, val url: String, val password: String)
}
```so this is fine then?
probably
also what do I do about my metadata?
?
since it says it can't resolve the properties of node-1
what's the full error?
lavalink:
nodes:
"node-1":
name: lavalink-node-1 # <-- cannot resolve
url: wss://localhost:9000 # <-- cannot resolve
password: TheWorldsBestPassword # <-- cannot resolve
it's not an error it just shows up yellow
okay
it's probably just because it's not a registered config thingy
okay yeah making it a map and removing the "" part of that yml seemed to fix it
a.k.a: yaml lavalink: nodes: node-1: name: lavalink-node-1 url: wss://localhost:9000 password: TheWorldsBestPassword with: ```json
{
"name": "lavalink.nodes",
"type": "java.util.Map<java.lang.String, dev.bombardy.bardybot.config.LavalinkConfig.NodeConfig>",
"description": "Description for lavalink."
}
don't ask why the descriptions are all the default ones lol
Did that work?
haven't tested it yet, still working on changing the code to make it work
@Bean
fun lavalink(jdaFunction: JDAFunction, linkConfig: LavalinkConfig, botConfig: BotConfig) = JdaLavalink(
botConfig.clientId,
1,
jdaFunction
).apply {
linkConfig.nodes.values.forEach {
addNode(it.name, URI(it.url), it.password)
}
}
```that looks about right haha
that is hideous
I know
ur hideous
not even the worst of it BM
cover your eyes
@Bean
fun jda(jdaFunction: JDAFunction, lavalink: JdaLavalink, config: BotConfig): JDA = runCatching {
val jda = JDABuilder.create(config.token, GATEWAY_INTENTS)
.setActivity(Activity.playing("bot.bardy.me | !help"))
.setVoiceDispatchInterceptor(lavalink.voiceInterceptor)
.setMemberCachePolicy(MemberCachePolicy.VOICE)
.setChunkingFilter(ChunkingFilter.NONE)
.disableCache(DISABLED_FLAGS)
.build()
jdaFunction.jda = jda
return jda
}.getOrElse {
LOGGER.error("Your bot token is empty or invalid! You can configure your token by providing the -Dbot.token=my_token argument when running this application")
exitProcess(0)
}
I mean, it works
the exitProcess() is really sneaky though
that's there so that I can return JDA as the result of that function
Nothing hacks
also for some reason that still returns Nothing without the explicit type there
Parameter 0 of constructor in dev.bombardy.bardybot.config.SentryConfig required a bean of type 'java.lang.String' that could not be found. tf?
@prisma wave any ideas?
send code
@ConfigurationProperties("sentry")
@ConstructorBinding
data class SentryConfig(val dsn: String)
sentry:
dsn: "my_sentry_dsn"
then @ConfigurationPropertiesScan on my main class
Hey, I'm fairly experienced coder in Java looking to get into plugin development. I would love if someone could show me some good resources to learn or teach me the basics
Play around with it I guess, most tuts are garbage so 
Your mistake is not using configurate
yeah gl finding a decent tutorial @restive abyss
also @rotund egret wdym?
@prisma wave you got any ideas either?
@ConfigSerializable
object Config {
@Setting
var sentry = SentryConfig
}
@ConfigSerializable
object SentryConfig {
@Setting
var dsn = "my_sentry_dsn"
}```
๐
No clue, I just like configurate as a config lib
@prisma wave https://blog.repl.it/langjam?ref=newletter
We built Repl.it to make it easy to explore and learn languages and programming paradigms. Weโve grown a community that, like us, is excitedโฆ
This could be our excuse to actually collaborate.
lol
๐
And since they want "unique" we need to have a gimmick
i propose a language that can hack Barry and remove the anti caps thing
@onyx loom fuck you
no fuck u
I imagine something esoteric is out of the question
most likely
Yes
cant be that hard 
I like the sound of that
mostly
the 3 most circlejerky languages combined into 1
also known as perfection
indeed
something modern but not too quirky I think
probably named after something geographical or an element or something
what about "cerise"
yooo
Yo Eclipse users be kinda gang gang
cerise is pretty but ok
elara?
named after a really obscure Jupiter moon
and also something Greek apparently
That sounds fun
cool
ok
so
syntax
I propose either val and fun or a single def for declarations
then maybe mut val for mutable? or just var
or let ofc
I would hate existence typing mut val
likewise
but that's kind of the point
discourage mutability
to build on that, I think mutability as part of the type system could be cool
I think rust does something like this, where you have to explicitly specify mut to be able to call any mutating functions on a type
so like ```
type Player {
let mut xp = 0
mut fun incXP() {
xp++
}
}
let player = blah
player.incXP() //doesn't compile
let mut player = blah
player.incXP() //does compile
could be cool idk
Ima try copy all of you and build KatLang
Its gonna be a massive shitshow
we can split the $10000
join us
You serious? You do realise I've never touched this before right? I mean I've intended to but then I've gone to other things
ยฏ\_(ใ)_/ยฏ
Sounds fancy, I'm in.
you'd better be a fast learner
I meean, we'll soon find out. So you're coding it in Kotlin I assume right?
That seems like the obvious choice
Fair enough
Well, its midnight almost and I have to get up at 6 so I'm going now, but I'm probably free most of tomorrow, tell me what I need to do Sir Mr Senpai Sir
Aye wtf, don't invite the noobs
There we go
Lol
yeah let's not get ahead of ourselves
so: functional
that's not much to go on
You didn't read the damn post
they started talking about Lisp and I just tuned out
which is perfectly fair I think
whats the concept / challenge
make a "unique" language
@topaz bay for uniqueness, what about that type system idea you had a while ago?
typing by contract or whatever it was
might be tricky in a statically typed language though
whats the requirements?
Type by contract wouldn't be hard static
Once a type has all its members defined, any inferred type for it would just include those as a union
true
could be worth doing?
it's definitely a unique idea
not sure if it's practical though
Is anything practical?
well... yes
lol
I can't think of a whole lot of benefits that typing by contract would give, that outweigh the potential messiness
The only practical thing in existence in the new Kotlin script expansion

maybe we should focus on the task at hand
FUCK
No need to shout.
Shut up noob
ok

why so ๐
ยฏ_(ใ)_/ยฏ
what about halsey
i havent listened to any of her songs
New Americana literally shaped my teenage years
but the ones shes featured in are bangers
I remember to this day, the first time I listened to that song
The guy who introduced me to her was pretty hot
i first heard that song from trevor moran 
oh dear god
halsey is cool
o2l
@topaz bay favourite song?
HOPE YOU GUYS EJOYED MY PART 2 OF MY POPSTAR SINGING IMPRESSIONS SERIES??? IM A LIL SICK SO DONT JUDGE TOO HARD ILY BYE
NEW MERCH: http://districtlines.com/trevormoran
Official music video for "Get Me Through the Night" by Trevor Moran.
https://www.youtube.com/watch?v=xhEiY.....
from her
thats where i first heard that song from
@onyx loom Thats pretty tuff
my favourite is clementine
I would say new americana probably
clementine is relaxing 
can i join?
i am a fag
TOO BAD
Jessie Reyez is still one of my favourite singers 
I'm so sad... that I know the words to this song
damn thats sad
ive prob had 1000 hours on spotify in this yetsr alone already
ew wtf is Nightmare sx
this is disgusting
fuck you

hater
clemetine and new americana are ok. i see why u like it but its not my style
FUCK YOU
No need to shout.
let text = "Hello"
print text //paranthesies are optional
let list = [1, 2, 4.5]
let total = list.map(+ 1).reduce(+)
//Total = 10.5
``` @topaz bay theoretically how does this look?
I think something like F#'s pipe operator might be cool too
let sum = (List<Number> list) => list.reduce(+)
let total = [1, 2, 3] |> sum
gives a bit more choice
|> bruh
->
i quite like it
weirdos
lol what a great partner
guess I'll have to carry
And Im playing OW
imagine thinking ow is more important
Give me gimmicks
imagine
let factorial = (Int n) => {
(1..n).fold(*)
}
let recursiveFactorial = (Int n) => {
match n {
1 -> 1
else -> n * recursiveFactorial(n - 1)
}
}``` fairly clean imo. Not that unique yet
We need a gimmick
yall, intellij nis saying my packages no longer exist, pls help Error:(24,23) java: package org.json.simple does not exist
idk what to fucking do
What is spring web? Ive been told its for a rest backend but ive also been told you can hse it for frontend in place of stuff like react. What is the best way of uisng it on a dashboard type website
There's never any reason to couple your frontend and backend
they should be separate
spring handling the backend, and whatever your preferred tool is on the frontend
So I should have a spring backend for data and a reactjs frontend which gets data from the backend?
I assume so
And displays it nicely
I always did it the traditional way
The eCloud guys want the frontend separated
It'll improve the UI though
This problem never occurs with Kotlin ๐
Lmao
@quiet depot (@prisma wave) Go judge and tell me if this is the way I should be approaching this https://github.com/Frcsty/FrozenActions/tree/master/src/main/java/com/github/frcsty/frozenactions
I honestly didn't think of what else to name it :p
Nah I'm deleting it later anyways so 
oh sad.
commenting code is also very nice
Nah, this way people have to use atleast 1 braincell 
most of us started off as spigot developers. We dont have any braincells left
Indeed we did
imagine flooding the spigot market by being a shit dev who gives no shits to any programming concept and only cares about the shit it makes for a shitty spigot plugin taught by some half-arsed youtube tutorial and then having the audacity balls calling yourself a Developer
half the people here
imaging shitting on people for being new and still having to learn certain things
imaging shitting on people for being new and still having to learn certain things
@lunar cypress words
This attitude certainly doesn't help them not "fail miserably"
I dont see spigot getting ideal any time soon even if change my attitude
kotlin good
java doesnt suck as bad as spigot
It sucks way more 
but you're not critisising that, you're just bashing devs
Yakฤซnana
Yugi
If someone requests a paid commission to modify a plugin whose TOS states that it can't be redistributed, is that a bad thing?
sup frost
yes
Go judge it Yugi: https://github.com/Frcsty/FrozenActions/tree/master/src/main/java/com/github/frcsty/frozenactions
lmao he asked me earlier if i can edit it
lol
Go judge it Yugi: https://github.com/Frcsty/FrozenActions/tree/master/src/main/java/com/github/frcsty/frozenactions
ayy nice!
Lemme convert it to kotlin now :p
Did you check the pr? ๐
I'll judge the commit messages instead
I haven't yet Yugi, been doing this, will check in a bit
๐
@old wyvern This might error btw, as not all formats have the inverted attribute
isInverted = formatSection.getBoolean("inverted")
That returns false if the "inverted" section isnt present
What I mean is, the inverted attribute might not even exist in the config for that format
declaration: package: org.bukkit.configuration, interface: ConfigurationSection
yes
If its not specified it will default to false
Ah okay
like you already had it to
what if the inverted section is inverted
what if
@old wyvern Wanna get rid of nulls for me?
The kotlin version right?
Yes
Nah pull the latest thing
ah one sec
I already changed a fuck ton of shit
@hot hull Done ๐
Thanks
If I'm maniac enough, I would re-use my code for kteval cmd from my bot to PAPI expansion ๐
Sx might have the same idea too, if maybe one day
@hot hull why use Long wrapper ๐ฆ
what then 
long
@prisma wave How does one do an instance check in kotlin?
is

fun CommandSender.sendMessage(msg: String) {
var message = msg
if (Bukkit.getServer().pluginManager.getPlugin("PlaceholderAPI") != null) {
if (this is Player) message = PlaceholderAPI.setPlaceholders(this, message)
}
this.sendMessage(message.color())
}
;c
pretty clean apart from that though
Bukkit.getServer().pluginManager => Bukkit.getPluginManager()
wait
does that even work?
i think the instance function would override the extension function
boutta test rn
IJ might give a warning
But a commandsender can be a player, so not sure why it wouldn't
(Doesn't give any warnings)
Bukkit.getServer().pluginManager=>Bukkit.getPluginManager()
Bukkit.server.pluginManager...?
it's not a getter
well it is
but the kotlin compiler knows it isn't tied to an actual field
so you can't do that
In latest doesn't seem to be a thing 
ah okay yeah maybe they changed it since Server is a singleton
idfk
I haven't used the 1.16 API before
The server field was always private
yeah
I'm gonna be attempting to make the craziest placeholder expansion no one would think of
.. if I can move around again
What is it?
#off-topic message I said the same thing with TP Confirm thing a long time ago :p
@ocean quartz What am I missing here? It's not recognizing my aliases
override fun setAliases(aliases: MutableList<String>) {
setAliases(Settings.ALIASES)
}
infinite recursion
Ah
Well yeah you're overriding it dummy
don't take a MutableList
unless you actually need mutability
Liskov applies to Mutable in kotlin
Well yeah you're overriding it dummy
@ocean quartz uh what, should I be setting it somewhere else then or
Why are you even overriding it?
just do setAliases on init
@ocean quartz I still don't understand why it's not working lol, I switched it so it set's them on init, yet still nada
A member of staff has requested I move your message to a paste,
Most likely beacause it contains a config/error/code snippet.
smh
A member of staff has requested I move your message to a paste,
Most likely beacause it contains a config/error/code snippet.
i'm not sure that will work
Yeah i don't like what you're doing with this Settings class
Got suggestions? 
Use ConfigMe for config related stuff, and yeah ^
object is pseudo-static
it's not literally static, but it effectively is in this context
Then what? I'm not about to use DI for this
Why not just setAliases(plugin.config.getStringList("settings.alias"))? You're already passing down the plugin instance, you're just creating more to achieve the same
Changed that now, and for the rest?
what even is the problem lol
I mean Matt, it still doesn't register the aliases lol
And are you sure the value is there?
Print out the stuff from the config on init before you set it
They print out just fine
Hmm, and was it working before you changed to Kotlin?
Okay I'll check in a second
@prisma wave this look ok?
Is that a getter ๐คข
that is the most java-like code I've ever seen
literally no reason to use streams
and that getter could be replaced with a val
you can have properties with custom getters
val registeredStatistics: List<ProperStatistic>
get() = _registeredStatistics
``` is one such way of doing it
why not?
Since the list is immutable
and?
you have 2 properties
you have a private mutable property _registeredStatistics
and a public immutable one
yes
Oh its another thing
lol
kkcool
No need to shout.
Its a senpai learning sesh, whats not to shout about?
Tier 6
๐
yes
๐๐
Frosty is a nerd too
๐
@hot hull
Better?
Idk how else to filter it down a list of the ProperStatistics that are only for that specific type
as usual
Fancy
ok thats done, looks better
I've just realised I don't need a main class do I? Since I'd never use it anyway
IAL doesn't have one
I'll delete it for now
ยฏ_(ใ)_/ยฏ
class ExampleStatistic : StatisticListener() {
private val statistic = ProperStatistic(Material.ACACIA_BOAT, this, JavaPlugin.getPlugin(ExamplePlugin::class.java))
@EventHandler
fun doSmth(e: SomeEvent) {
statistic.increment()
}
}``` What do you think about this for registering a statistic? Ignore the JavaPlugin thing, its just as a quick example
statistic should be a constant 

How would that work, isn't it per player?
global server statistics ๐ฎ
quick question KM, I need to access the config in my MessageFormatter but I don't wanna use DI for it, since that'd be ugly af
?kotlin-dependency
Dependency Injection
Dependency injection is when we pass a class through other class constructors to access that specific class in those other classes.
class Main : JavaPlugin() {
override fun onEnable() {
val other = Other(this)
other.method()
}
fun myMethod() {
/* Some code goes in here */
}
}
class Other(private val main: Main) {
fun method() {
main.myMethod()
}
}
Because I'd have to pass it in like 4 different classes as well
i wouldnt say its not nice
I mean what's the problem with that?
4 different classes
DI good
But it's dumb for a single value..
Also should I use LinkedHashMap over HashMap? (in Java) Since that's what mutableMapOf uses
It maintains order
LinkedHashMap is pretty much the same, but it maintains insertion order, so you might as well use it
Specially good for the paginated items
Yeeah BM I didn't really think that through did I?
I'll revisit that later
This should be ok for registering OfflinePlayer for MF right
๐
is that like 600 lines lol
@errant geyser that register function should be reified
inline fun <reified T : OfflinePlayer> ParameterHandler.register() = register(T::class.java)
```that looks about right
@ocean quartz If it was in kotlin you wouldn't have that issue 
it's probably in Java due to interop, which doesn't make too much sense tbh
Is that just to register OfflinePlayer and Player?
since you can write Kotlin code that's usable in Java if you do it right
Is that just to register OfflinePlayer and Player?
no fucking clue lol
time to check source
you didnt write that?
I didn't write ParameterHandler no
I just created the extension to reify it
actually it's a class of wildcard
what?
lemme just modify that code
Trust me frosty I'd write everything in Kotlin if it was shaded in Spigot
What is ParameterHandler?
wait how tf does that register function work that @errant geyser is using?
function: (T) -> Any?
Can't really use PDM on a lib 
I mean
wait I'm looking at the wrong project that's why I can't figure it out lol
I'm stupid
actually it's exactly the same in normal MF
I see a kotlin
help me out here please KM
avec quoi?
oui oui
๐
inline fun <reified T> ParameterHandler.register(action: (Any) -> TypeResult) = register(T::class.java, action)
there we go
I think I nailed that
that won't compile
why not?
action()
oh yeah true
action: (Any) -> TypeResult
you can probably just pass action itself
the compiler can probably automatically do it
yeah edited it
I think I'm improving my understanding of all these thingys
like inlining and higher-order functions
inlining is easy
yeah but I've never quite grasped it really
never used
in theory it's an easier concept to grasp than functions
how do things like crossinline work then?
both
noinline is obvious
Why did i even write this wtf, this is useless
why useless it?
crossinline afaik just means you can't return
Because i'm validating the slot even though it'll already return null if it's not valid
ah okay
This does the same
I'd write everything in Kotlin if it was shaded in Spigot
having it shaded into spigot would probably be a bad idea
because they'd be at least 3 versions behind
which is why pdm 
lol
Can't really use PDM on a lib
I would if i could
also it's not a library matt
What do you mean it's not a library?
it's a framework...?
I mean you can just shade it, with most plugins you're below the spigot limit so should be good
It's more of a lib than a framework
library and framework are not mutually exclusive
It's a GUI lib
@prisma wave true
The framework is the commands one
never actually used MFGUI
I've heard good things about it though
also look at all these dependents on the dependency graph
It's getting really good right now, rewriting a bunch of it and adding more features ๐
damn you GitHub for not supporting gradle
they don't support Gradle dependency thingys
like they won't process your dependencies if it's a Gradle project
but Gradle is a bit like Linux, people just don't really use it because they think that alternatives are better (which they're often not), and so because not as many people use it, software doesn't always support it
(obviously Gradle is much more popular in its market than Linux is in its, but the point kinda still stands)
first class in android development tho
yeah that's about all that's going for Kotlin and Gradle
but that's a massive portion of the JVM's market anyway
even with large companies like Google backing them, people still don't care
I still know countless people who don't use Kotlin for whatever reason, be it syntax or layout or "Java's superior" or some other BS
people are stupid, what can I say
I still remember once, my friend said something along these lines: "A person can be smart, but people in general are stupid"
ยฏ_(ใ)_/ยฏ
jerk
wdym?
circle
jerk
there are just some straight known facts throughout the universe:
- The universe is constantly expanding
- Bees should not be able to fly
- Kotlin is objectively better than Java
Java bad, Rust bad, C++ bad, ruby bad, python bad, JavaScript bad, Haskell bad, Fortran bad, PHP bad, assembly bad, Odin absolute horseshit, C bad, Go bad, V bad, Dart bad, Swift bad, Objective-C bad, XML bad, Groovy bad, Scala bad, Clojure bad, Lisp bad, COBOL bad, html bad, typescript bad, yaml bad, coffeescript bad, skript bad, C# bad, skript bad
kotlin good
KM, I hope you can forgive me, but I'm updating a project made in java using maven 
๐คฎ
gross
I mean yea
also wait hold on Frosty
Not finna pay 130$ to someone who is gonna scam me for the IGN Frosty 
have you finally opened your eyes and realised that Kotlin is objectively superior?
Indeed I have Bardy
REMASTERED IN HD!
Official Website: https://www.koolandthegang.com/
Stream: https://lnk.to/YY8v1
Facebook: https://www.facebook.com/koolandthegang
Twitter: https://twitter.com/koolnthegnglive
Music video by Kool & The Gang performing Celebration. (C) 1980 The Island Def Jam M...
@prisma wave shut up about circle jerking
I'm just spitting fax
Any group or group activity indulging in mutual gratification.
An online community where a group of people form an echo chamber.
totally not us
"A group of males masturbating ("jerking off") together (with or without interpersonal contact)."
that's the original meaning
::)))
okay #3 is a bit more realistic
Maybe you are doing that. Who knows. 
you guys ever heard of kotlin?
they do that sometimes too @jovial warren
you guys ever heard of kotlin?
wait
Rust
I mean that's where the meaning came from, people talking about what they like or hate just like jerking each other's off
isn't that the name of that objectively superior language that beats out all other competition in the JVM market KM?
probably
and that's actually truth
totally underrated though
Kotlin is the second most popular JVM language, behind Java legacy enterprise code
and some morons who still think Java's somehow "better"
Changed
okay that's a bit far
kotlin good
java bad
actually clojure best jvm language
@ocean quartz as I said, legacy code, enterprise code and a group of morons who still believe it's "better"
Oh fuck no
actually clojure best jvm language
wrong
no
Kotlin is best
@ocean quartz as I said, legacy code, enterprise code and a group of morons who still believe it's "better"
@jovial warren Excuse me
I know yeah was just showing it
Kotlin has been rising super fast
https://tenor.com/r4Hd.gif @prisma wave
๐
you've clearly never used clojure
@heady birch HAHAHAHA
it's the future of programming
This face can be interpreted so many ways
Clojure hurts my eyes
(defn (((())))))))))
lisps read better than normal languages
yeah I've never actually used Clojure, or Scala, or Groovy, or in fact any other JVM language
so I'm, as always, a hypocrite
Kotlin is like better groovy
mixed with scala
:O
