#dev-general
1 messages ยท Page 254 of 1
The Birmingham Boi will get you
NOT ME
uh
big mistake
knife licensing in the UK ๐คฃ ๐คฃ
๐ฅฒ
okay the TV license is just a tax sheesh kalm
he has a point
โน๏ธ
but the BBC needs money
fuck the bbc
โน๏ธ
They get enough as it is
they are what my parents watch on TV and what i used to
Kali the BBC aren't that bad
they are 'unbiased'
No news outlet is unbiased
who needs tv in the first place ๐
some people think they are right wing, some people think they are left wing
who cares, get ur news from spotify instead
yes
thats right, spotify
import elara/news
if they are biased to all sides, that makes them unbiased
Display it on your HiFive after downloading it from the Internet using a script you made
I'm assuming you all know about the BBC HiFive Inventor?
Theyre actually decent, if you get rid of the Doctor Who stuff
ohhh ive seen ads for that
dr who good ๐ฆ
Not with the HiFive
reactions not allowed at ur rank i think
look further into the vid
I can react to other messages
YES
JUST NOT THAT ONE MESSAGE!!!_ _
I was the first childerino in the country to get one from the BBC (alpha tester & stuff). The Doctor Who stuff is really not great
Who?
you alpha tested it?
how
idk
My CS teacher worked with the BBC to design and make it
o
(they have java devs in manchester btw :)))))
ur a cool kid
nice CS teacher
Not as cool as u Kali
I like him
my GCSE CS teacher was just a fat wanker who typed at like 5 wpm in python and only did kahoot quizzes
that was a bit rude
Probably accurate though
I'm lucky to have that good of a teacher
IDLE ftw
idle ๐คข
all CS and IT teachers ive had have been dicks
surprised that im in this field lol
when all my physics teachers have been lovely
physics ๐คข
the thing is, everyone smart enough to be a CS teacher doesn't want to because private industry pays much more
so
๐
yeah lol
i had to have a PE teacher for CS lessons in year 10 or smth
gamer life
let toString(Any[] list) => {
return "[" + list.join(", ") + "]"
}
``` the most beautiful thing ive ever seen
๐ฎ
fuck the github main branch
just saying
https://github.com/ElaraLang/elara-stdlib however this is hot
[\w\d]{3,16} is nickname regex right
think so
I gotchu just etransfer the fee and I'll send it out
LARRY
O/
I'll pay you in definitely real Internet points
That works too
Ok ๐
Thanks bb
No u
Lmao
Emacs
Lisp
My arch nemesis
I thought we changed the file extension to stop that
But NO
It never leaves
Emacs Lisp will soon dominate the world and elara will be overshadowed
Not if I have anything to say about it
why? 
cube is a yaml dev
certified?
by me
i needa talk to clip then
i spoke with him b4 but he said he didnt know
but he solved it in dchat
clips ded
oh no

Hey look it's that @obtuse gale person who got mad with me because I didn't understand how to read the LuckPerms highlight
Y'know the website highlighting a section
hey look its the guy that uses eclipse typing in dev general
About the section that was not only highlighted but I literally linked
lol
I use Atom what you on about
Vim ftw
Oh yeah
also that argument doesnt change anything lol atoms no better afaik
what do you code bots in?
py
sublime >
Does anyone have any idea if its possible that if you boost a discord server you get special perm on the server? Like DiscordSRV does alot of discord-> minecraft and viceversa but idk if it has this feature
Booster role?
If you're using LuckPerms you can set a perm with booster context
Like on the default group idk, and it will only apply to those that boost the server (i.e. to those that have the booster context as true)
Was it fulltime $?
how much was it approx?
I legit don't know Pepper, this was like half a year ago
how much do u think it was around?
Again, no clue
How much uc harge?
Depends on the project
I usually don't get paid hourly since everyone get's scared of how much it'll cost
same
how much would u charge for a say a mines plugin?
Ur aware of prisons right?
I am aware yes, however if it ain't latest I don't want it
Latest?
The 1.8 fan switches?
ye but what i mean that like make it sync discord and minecraft so if someone boosts the discord server it automaticly gives a perm in the minecraft server
I am big 1.8 fan
Removed legacy support from my actions lib cause fuck that
u cant havee as many players on 1.16
Got annoyed when it was spazzing out on latest due to it being a thot
Most servers dont anyway
Yeah you can do that with DSRV & LP @little hamlet
and if ur not a dev good luck running server with custom shit on 1.16
o perfect thanks
Quick question does DSRV really breaks if server is reloaded?
There arent any active dupes rn im p sure
I truly am hoping 1.17 has a better performance
Many plugins do
Probably not
i hope it odesnt so people stick to 1.8 xD so i dont needa update
So, don't /reload and you're good to go
I don't believe there are any atm
i mean i have a ton of plugins and when i reload the server non of them break lmao
1.16 is not that bad
Debatable
WorldEdit, WorldGuard, LuckPerms, DSRV, Quests, slimefun, Towny, blah blah blah....
It's not that bad, but it's getting worse because they keep adding useless shit, instead of addressing performance issues
Literally thousands of plugins go nuts when /reloading
Yea Towny especially really fucks up
especially the big ones
Adds weird db values
yea but hoesntly man 1.8 alloweeed people who arent loaded to run servers and profit of em good
Like multiple references to a resident in towns causing it go into safe mode
cus how else are u gonna get devs?
I have WE WG LP and Quests non of them have ever break for me when i reload from console the server, i am a new "dev" so learning about this stuff
on top of that the constant shit breaking after version updates and shit
It's not all about profit
Oh Jesus don't mention safe mode XD
You also do realize you're missing out on 6 years+ worth of features
i can guarentee u, finding a dupe on one of my servers vs a random 1.16 server
would be 100x easier
Probably not
But then if you say that if a server restarts DSRV goes nuts then if server crashes or anything DSRV dies thats a bit sad / sucks
If anything that is just through patches from the long time since it has been out
๐
What plugins did funnycube make btw?
Restarts are totally fine
Reloads are fuckery
o i see what you mean like reloading a plugin ok my b i thought server restarting
And I can tell you neither WG, WE nor LP work fine when /reload
Nah full restarts are a bliss
Running /reload or /plugman reload break shit
cube's not really a plugin dev, but he has a couple of things on spigot that he made for fun
You shouldn't even have plugman installed
plugman unload and load <- is always better than plugman reload from waht I have seen
well i dont use plugman i use somehting else
but unload load seems better than reload to me
It's quite literally the same process lol
Well thanks for the help Oliver ๐
plugman on a test server is a blessing
that adds up
setup hotswapping
i frankly dont care and will use plugman on my test server because it's a test server used for quickly checking if features i changed/added worked
Well yea, aslong as you aren't doing any data storage it's fine 
Execution took 3.439168ms
Managed to shave a few ms off so far
congrats
thanks
few ms very important
gonna be difficult to do much more tho
25% of total execution time going on GC?
that can't be right
changing from kotlin to go because of jvm gc problems when go is doing the exact same ๐
unless jvm gc is even slower lmao
i mean go is still a lot faster
it executes almost instantly compared to the 1-2s JVM startup time
but
that seems too much
It's always ready to.... go go go.
wow
that's actually unbelievable
using a pool to cache Contexts and avoid reallocations brought the average time from 4-5ms to 0.8ms

What contexts
Ahh
How to run in debug mode on IntelliJ
click debug button
So i can edit code and it update in the game at the same time
piggy has a guide for that
Yeah but im not using gradle
i cba to find the link but google "piggypiglet hotswapping"
Or spigot
wdym?
My project is very very big
not really
IJ building isn't the fastest thing in the world
maybe consider JRebel, but that's ludicrously expensive
oh
you don't need gradle to hotswap
my guide still applies
and jrebel is more expensive than ij ultimate last time I checked
it's simply not worth it
i don't see much point of optimizing while on go
or any language that isn't elara
build your poc in go
then from there on out, build in elara
poc?
proof of concept
havent been able to record anything, but i can tomorrow
johnny has been giving some feedback for the slides which is good too
Any good config file lib or something that isn't too complicated ๐
ConfigMe, Triumph config, Configurate
thx
Bukkit config (:
if I am using maven modules for nms abstraction, is it okay for the nms modules to depend on the spigot plugin? Something about having spigot module depending on nms and nms depending on spigot doesn't sit right, don't know why
cyclic dependency, that won't work
you could skip 2 for speed but that'd create security problems
Yeah in theory
although most of the time, skipping 2 would just defer the problem to somewhere else
oh well there is no compile time at the moment
the rumor is bm is here and im a big fan so now im here
That would work once we get proper type inference
but so far, it's just dynamically typed
D:
I know, gross
haven't I given you the dynamically typed languages lecture
Probably
I'm not a fan either, so I'm making it as static as possible
and eventually we will add type inference + compiler
Arenโt dynamic typed languages good?
no
the key point is a true statically typed language can also be typed dynamically as a side effect
forcing a language to only be dynamic is unnecessarily limiting
JavaScript?
That's kind of what I'm aiming for. Because the type system is contract based, it can effectively be dynamic, but with static type checking still
sounds good
you could theoretically have "perfect" type inference for function parameters for example, by just looking at the methods that are used and constructing a contract from that
Anyway, the next thing I did was adjust how values are returned. Consider the following code ```rust
let blah = blah()
return blah
x()
Currently, the `return` was implemented by panicking, which causes the stack to be unwound (similar to throw an exception). The function simply looks for a panic, catches it, and extracts the returned value.
This was very wasteful, as the "panic, defer, recover" loop introduces some overhead on the stack.
So instead, I made each expression return a value with a boolean to mark whether it was being returned or not. Then the function call can just check for that boolean, and if it's true, it stops executing. This saved about 0.5ms I noticed
lol
Wait can statically typed languages be dynamically typed? Is this the case for java?
Oh yeah thatโs true
although it would be a lot messier
it would
wouldnโt var accomplish the same thing or is it just inferred?
Hmm okay nice
๐ฎ
;-;
for reference that uses about 19GB of memory to compress
ram?
yes ram
lol
is there much point compressing it at all?
I'm uploading this over sftp to my laptop & nuc
no
ok
I would never use filezilla for something like this
then wut
not sure tbh
I'm going to change my statement
I would never use filezilla.
winscp โค๏ธ
filezilla is pretty wack
oof this uses a lot of cpu
wtf it's not even running hot
100% cpu usage and it's under 70
70 what?
70 of the only respectable temperature unit, which is used in every day society
celcius ?
ok
๐
imperial system is the worst thing to ever be invented
^
I don't get to control what my country has adopted and uses on a regular basis
too bad yako
you get the blame for it anyway
when I say you, not you in particular, all americans in general
even the ones who live in solitary with their treasured si units
you're all guilty
still
is the official title actually mr president?
I thought "president" itself was the title
not so cute
but people call him Mr president
that's like calling the queen mrs queen elizabeth
actually that doesn't even sound so bad
yeah
There's nothing cute about being american ๐ฉ
still not right
Americans have dentists
it's the high magisty queen elizabeth
what's your point
oh wauw
nothing in particular
sure...
and the bill is like 20.000 dollar
what @normal talon
#FreeHealthCare
no
Still no DMs 
insurance
true tho no free health care
use this BM
wack
I meant commission DMs, not hi's
hi
Aha
Who likes to contribute to my plugin. You do all the work and I upload the plugin?
if fun != nil
nil ?
nil
tf is dat
null
like null but quirky
ooh what language uses that again?
lua
lol
it's really not ok
Well ~ is associated with not
did u invent Lua
yes
good for you
obviously
Yes :)
no no I was saying yes to him asking if johnny invented it
johnny is the sole maintainer of lua
tf is lua
yep johnny has been working non stop on lua since 1994
yep
johnny sins isn't just an astronaut or a doctor
or a fireman
or a police man
or my step dad
he's also a programmer
my mothers boy friend
A man of many talents
yeah did you know he does porn?
yeah
Yea
really is a man of many talents
Big fan
what exactly does that word mean
I'm on MOBILE
I'd call it interesting
autocorrect
when github goes down they open the arctic vault and release the penguins
Uh oh
oh I have code there
I think most of us do
it has been 2 months since I applied for my role stuff
the penguins restore order to the world
almost*
feels bad cozy
what role
artist
oh
that's cube's responsibility cozy
does music count as artist
annoy him
yes yako
i think
idk
I guess we'll just say if it sounds shit or not
Sick
It has the drawing thing
if it's revolutionary
`Artist (Drawing/GFX/Video Creation):
- Link to portfolio of past
projects (10+ Examples). - Proof that you own
said work.`
it has the word art
math is art
math is brain damage
math is not brain damage
life is art, I'm living. give me the role
math is great
im thinking something like this, so i've got a config.yml right? what if, we put the name of the plugin at the top in big ascii art
how's that for revolutionary?
it is fun if you understand it
big brain
well is it though
with one step you're committed to that route
or else you've wasted time
tbh I'd rather be stuck at the drawing board
I used to do graphic design before I had a life
I used to
___ _____ _ _ ___ ___ ___ / __|_ _| | | | _ \_ _| \ \__ \ | | | |_| | _/| || |) | |___/ |_| \___/|_| |___|___/
I can't finish that sentence because I still don't have a life
who does
he doesn't have it
-_-
xd
What does compileClasspath do? Like compared to implementation and compileOnly etc
something weird
.-. .-') _ .-') _ _ .-') _
\ ( OO ) ( ( OO) )( ( OO) )
,--. ,-.-') ,--. ;-----.\ ,--. ,--. \ .'_ \ .'_ ,--. ,--.
| |.-') | |OO) | |.-') | .-. | | | | | ,`'--..._),`'--..._) \ `.' /
| | OO ) | | \ | | OO ) | '-' /_) | | | .-') | | \ '| | \ ' .-') /
| |`-' | | |(_/ | |`-' | | .-. `. | |_|( OO )| | ' || | ' |(OO \ /
(| '---.',| |_.'(| '---.' | | \ | | | | `-' /| | / :| | / : | / /\_
| |(_| | | | | '--' /(' '-'(_.-' | '--' /| '--' / `-./ /.__)
`------' `--' `------' `------' `-----' `-------' `-------' `--'
compile classpath means it's available to the program at compile time
๐
i.e. compileOnly
that is my rapper name
Okay so compileClasspath and compileOnly function equally the same?
wtff
Hi guys, may i get some help with plugins for free here?
I have a lesson at 18:30
no, my rates are $18/hour
wait is compileClasspath actually a keyword in gradle?
yeah
yeah that's what I thought he was talking about
Yeah
That implies there are some places that charge for it, I'm in on that
don't use it
only things you will ever need are compileOnly, api, and implementation
HelpChatPro
hmm so runtimeOnly doesnโt have a usage?
$20/minute for Premium Deluxe support
Monthly subscription
almost definitely not
per minute tf
what on earth could runtimeonly be used for
one time kits
practically
probably nothing?
buildscripts arent even preserved at runtime most of the time so...
This is where you declare dependencies which are only required at runtime, and not at compile time.
what
is it just a marker?
Can be relevant for other components as well
E.g. testing, although there you have an own configuration for that
Well take tests
Often times you'll want to have the testing engine as a runtime dependency
surely it's just a marker though? it wouldn't actually do anything
In this case it does
Because you run the tests with gradle
Same thing with gradle run I would assume
i guess
idk im confusing myself here
wouldn't you just use the test configuration for that?
So I have an abstract message to join in all the components, add hover, click, and parse papi placeholders, however i just realized that the system i have is not great, since a normal message will only require 1 player, but since private messages required both sender and recipient to parse placeholders i need to change this
My idea was to have the abstract message required 2 players by default and have recipient nullable, then normal messages would pass null to it
Any thoughts on this?
Ok
Hey fellas, anyone wanna hop on my server for a sec, I need data 
โ
How is that confusing
what kind of data
Probably player data
InetAddress' to be exact 
sounds like a virus
True
Just your IP and shit, cba to continue today tho
yeah not risking that
Kotlin is failing me
Author is null lmao
yeet
How? Lol
;-;
Lol BM
I don't know, it makes no sense
Where is author coming from
Gotta get money somehow if people don't dm for commissions yknow
what is : ChatPlayer?
Like whatโs providing the value
The type of author is ChatPlayer
ah ok
kotlin confusing
can't that happen if you try and reference it in an init block before its initialised or something?
agreed
I feel like Iโve read that you can do it with reflection and set it to null
Ah ok
this is basically the exact same as java with <Type> <name> but in kotlin its <name>: <Type>, however the type can be inferred in kotlin
its just reversed, nothing confusing about that lol
brain hurts
yeah it's trying to warn you about that
it's not final in that it can be extended
and overridden
Iโm dropping java 8 support now, itโs fine right cuz lts has run out?
wut
because iirc, the init block will be called before constructors, so author might not yet be initialised
ur 7 versions behind kek
btw super constructors are called before init block iirc
yeah that's what it is
i think
that's why it does the warning probably
idk, it's something like that
i can't remember the exact details
Yeyeye
Had author overridden in the implementation without noticing
classic
you want confusing?
switch t := c.Invoking.(type){
case *VariableCommand:
variable := t.findVariable(ctx)
if variable != nil && !variable.Mutable {
c.cachedFunc = fun
}
}```
Is that go?
yup
Gross
thats a yikes
๐
even java makes a switch nicer than that
Yup, it works now
yes
is java 11 the most up-to-date LTS version
When is better
but still looks disgusting
yes
k good
rolling_eyes
am i wrong
Yes use 11
i'd like to see java be this fast
Technically java could add a switch that support class types
switch (getClass()) {
case Object.class: {
}
}``` does this exist in kotlin?
that wouldnt work
You would use when but i think so
because the switch bytecode instruction only works with constants
Fucking java
Wouldn't that be the equivalent to this?
when {
this.javaClass == Object::class.java -> {
}
}
yes
switch this.(type) {
case Object:
//blah
}```
https://i.imgur.com/ykBA3nY.png welp better change that
15 even better
https://i.imgur.com/GxCtEbI.png doot done
Nice
maven
ridedPlayer
Side effects on constructor ๐คฎ
lol
This is yikes
wwhat is SRP
Single responsibility principle
Bad
Have a class for each thing you need. A class for each command, a class for main etc
Super red poop
ok
is that bad?
Really bad
ah
if null
4/10
nullcheck
NPE should be handled, never caught
Catch Throwable in onEnable 
if you catch NPE you're dead to me
^
catch a KNPE
๐คฎ
KotlinNPE

Nil Pointer Exception? 
there is never a reason for u to catch npe
Noob Pointer Exception
Yes one time
Also use a lambda
go doesn't have exceptions ๐
the hecks a llama
(() -> lambda)
Anon function
#(fun %)
oh that weird arrow thing i copy from stack overflow sometimes
okay ๐
im kidding ill google it
Lambda expressions are similar to methods, but they do not need a name and they can be implemented right in the body of a method.
fun
that name makes more sense now
Is this a lambda then? js function() {}
Lol
import java.util.ArrayList;
public class Main {
public static void main(String[] args) {
ArrayList<Integer> numbers = new ArrayList<Integer>();
numbers.add(5);
numbers.add(9);
numbers.add(8);
numbers.add(1);
numbers.forEach( (n) -> { System.out.println(n); } );
}
}
```yeet
Ah god
Stream.of
lambda => anonymous function but not anonymous function => lambda?
@obtuse gale Why do you use a Consumer<BukkitTask> for the schedule?
all my homies use ```rust
[5, 9, 8, 1].forEach(n => print(n))
(run println [5 9 8 1])
nice
Runnable lambda would make much more sense there, you don't use any bukkit task specific things nor consumer specific things
() -> {}
definitely lmao
putStrLn (show [5, 9, 8, 1])
eh
what's this now
Bukkit.getScheduler().runTaskTimer(plugin, new Consumer<BukkitTask>() {
@Override
public void accept(BukkitTask task) {
if (ridedPlayer.getPassengers().isEmpty()) {
ridedPlayer.setGlowing(false);
}
}
}, 0, 4L);
To
Bukkit.getScheduler().runTaskTimer(plugin, () -> {
if (ridedPlayer.getPassengers().isEmpty()) {
ridedPlayer.setGlowing(false);
}
}, 0, 4L);
poorly written haskell
You mean haskell?

Clojaskell
The second scheduler you use cancel, so probably not
Don't use it in a scheduler, but you can use it on it's own
If you want to cancel your task inside and outside BukkitRunnable might fit you better but no lambda
And lambda iirc is somewhat more optimized
Good you are a little less dead to us now
sounds amazing
If i have like
blah.forEach { first, second ->
myMethod(first, second)
}```
Is that the same as like ```kotlin
blah.forEach(ClassName::myMethod)```
Whatโs the difference between the two?
I can't find it right now but last time I looked at it I was terrified
not a lot
oof
โข jdk โข 1.14.3
โข jda โข 1.14.2
โข 1.16.4/latest/spigot โข 1.14.1
โข 1.16.3 โข 1.14
โข 1.16.2 โข 1.13.2
โข 1.16.1 โข 1.13.1
โข 1.15.2 โข 1.13
โข 1.15.1 โข 1.12.2
โข 1.15 โข 1.12.1
โข 1.14.4 โข 1.12
There was no direct match for that query, did you mean any of the following?: dynenum menu enumsyntax menuitem beans
aham
@quiet depot hmm is jdk 8? If so, is there any possibilities of adding jdk 11?
Consider java 8 died
itโs 8
Add guava :*
Ye what u need help with?
what does that method do
Okay sure ty
Enums#getIfPresent
is from guava
Enums.getIfPresent(EntityType.class, args[0]).orNull()
does docdex not have guava/gson support?
It does i think
d;guava
There was no direct match for that query, did you mean any of the following?: guard canvas pgpdata data area
it has gson and guice
o
Why are all results lowe case @quiet depot
d;guice
There was no direct match for that query, did you mean any of the following?: publickey source choice dragsource uiresource
He did it for case insensitivity
it returns an Optional<EnumClass>
you dont need #toUpperCase
What is entity?
Do you spawn one?
well you use || so if any is null it will send the message
d;spigot entitytype%sheep
public static final EntityType SHEEP```
@obtuse gale ๐ sign ๐ your ๐ commits
Hm
always sign them
if u set it up right, its automatic
and I have no idea how on windows
that's good
use getPlayer after checking if the entity is null
if (entityType == null)
player = getPlayer()
if (entityType == null && player == null)
sendMessage()
return true;
Or
if (entityType != null)
run code
return true;
a sign of good code
Cant always use "if not return"
when comments are also confusing, yeet
- get the entity type
- if entityType is not null spawn an entity etc and return
- get a player by its name
- if player is null send usage message and return
- do the thing on a player
Would also be an idea to check if the entity is not something like exp orb
btw compare the uuid of two players instead the object itself
full error?
gj
uh
check if the argument is an entity. If it isnt, that means it's a player
so then u can separately do the player and entity code
uh wht
oooh that
uh google 'how to sign git commits windows' assuming u use windows
AIOOB
ride player 
Dont access an index that doesnt exist
check array size
AntiObjectOrientedBoolean
lol
does that let u basically teleport to another player without their consent?
you should
you should
fair
java bad
the fastest code in the west
very fast
nanoseconds
micro
if only gradle was that quick
nice
congrats
Already finished it tho
Thats what she said


๐
Ew
outstanding
why thank you
GOD




