#dev-general
1 messages · Page 434 of 1
Yeah
Same
you only found out now?
lmao
lol
yeah and sometimes its not even readable or usable
wdym the converter is flawless??????????????????????????
ah that's how they meant it to work right?
my bad
How2 convert skript to jaba?
jaba lmao
Jaba
You press CTRL + ALT + JABA
he's so ugly it's incomprehensible
yeah because I definitely want to use the block registry for item ID lookups
what?
o_O
why o.o
about fucking time
its been said for a while now
👀
wow kotlin has so many weird operators
maybe Krypton needs to switch to registries too
kotlin bitwise is shit
tf does * do
multiply
of all the things, that's the first thing you think is the most important?
wdym
because bitwise are the only operations that are actually fucked
Exactly what my message says
everything else is okay
you mean those comments?
at the top of the file?
yea
Yes
nice
operator fun
does anyone know of a language with custom operators?
Spread operator
but.. if the comments are applied during build... I thought comments were removed when compiled?
English
sure
Gradle does more than just build
haskell does too btw 😄
comments are not included in compilation
Haskell....? 😳
correct
thats actually pog
and F# 😄
is it a separate task that changes all the source files?
Yes
ah
but i thought that the license only needed to be in the project root
or something
no, some licenses are required in every source file
oh
Not that it's required it's just better
several licenses state a provided snippet should be included at the top of every source file
not all of them
but many
also
can someone quickly tell me when to use gnu and when to use mit? i see u guys using both
and idk which one to use
(+=+) a b = a + b + a * b -- custom operator function for a*b + a + b
main = print ( 3 +=+ 4 ) -- wow!! it just works :DDD
use mit
and i usually dont even have a license
WHO DID THAT
let me recheck
lol
that wasnt me
Surprising
👀
pp
STOP
no I dont think he is
someone call 911
assuming thats what the number is in the uk
nah mate 999
assuming bm lives in the uk
afk
it is indeed 999
bakc
this is so cute
❤️
if only I were followed by someone so cool 
Don't worry dkim will follow you
xD
Ayy nice, got this working and without needing to repeat all the code like I had before
lol
Imagine not resolving it if the material is player head Matt
I actually wanted that, but it's impossible
How so?
You can't generically return different types in the same method
That's dumb
Well you can but not pretty
This would work, but what would the point be if you have to specify the builder anyways
ew
Exactly
Lol
That's something C++ can solve 
I could be wrong by Kotlin can too with reified types
C++ is nice I just found out the vararg template thing
Ooo the vararg templates are awesome
A very good reason to start with C++
loved your relocated dependencies ❤️
Also Yugi I just finished most of the rework and the builder stuff for mf-gui so feel free to do the Kotlin stuff when you want ;p
override fun getName(): String = "command"
override fun getDescription(): String = "Do the very important thing"``` does this work in kotlin?
yes
noice
useless return type
ooh even nicer
👍 👍 😎
also do i need to shade the kotlin stdlib
yes
like 2mb i think
rythm is down 😢
less james
actually yea
~1.4 iirc
Awesome
i could minimise it
Its on the master branch itself right?
It's on the 3.0.0 branch
@jovial warren I love what you're working on https://i.imgur.com/Yx66D4V.png
xD
I can almost read that
lol
Eh those are some negligible inconveniences
im pretty sure the stream goes fucked like that if u ever highlight text
You gotta see the big picture, it as a whole
alrighty
lol
lemme set this back to like 15 FPS
that seems to work
it just happens when he either scrolls or when I tab out then come back it stays like that for a long time
oh now its better
a lot better
ty @jovial warren . not that I understand a thing
also are you even listening to Rythm?
you think I know any more?
I played you some nice music xD
ffs
bardy u should see the commits i just done to ezblocks 😎
you made the main class
i did not
and set up build.gradle
setMessage 🤢
oh not even that?
i havent touched the main class lmao
yeah that was part me and part @errant geyser
ok would like me to call it applyColoursAndPlaceholders
just .color smh
hm what now
and setPapi
.format
for another one
hell katsumag
hola
where are ur ezblocks commits at
nah I want you to create a new class called AbstractColorAndPlaceholderApplierBuilderFactoryInstanceProviderBean
yeah could do this ig
AbstractColorFactoryAndPlaceholderFactoryApplierFactoryBuilderFactoryInstanceProviderFactoryProviderInstanceFactoryBean
epic
I must have made some, don't see them in the repo tho
AbstractColorAndPlaceholderApplierBuilderFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryFactoryInstanceProviderBean
that's more like it
I set up JBs db thing before Bardy tore it down with "wtf have you done"
😂
wait where is the EzBlocks github at?
Prevarinite account blitz
😌
koltin branch superior
who's Prevarinite ?
honestly i just need someone to do the database shit, im too small brain for that
an old organisation of mine
tf is this
imagine not remembering Prevarinite
oh org
Yugi remembers
Yes
wym its epic music yugi
you dare hate on Frosty's playlist?
lol
you deserver to die sir
is it actually lol
^
its not bad 😢
yeah maybe not the best
yeah Kaliber
there's like 250 songs
in queu
trying to figure out how Minecraft generates world UUIDs
I must have had a commit at some point 🤔
that's why I used Rithm
Wonder where it went
bcz Barry cant' do that yet
you made 2 commits
this will get done eventually :kekw:
am I missing something? I can't see any commits
Hey Bardy you wouldn't know how to decode a single byte key stream cipher where you don't know the key would you?
🥲
nice
without knowing the key, you gotta compute it
if it's only a single byte long then that's ez
what base?
256-bit 😳
No idea
just 2^8 possibilities
if it's a byte then the key can only be 2^8 different things
just brute force it
I wrote this to do it and uh, I need to compute 950k of them (don't ask). None of them came out coherently though. https://bin.katsumag.me/yeqisihuhu.py It's most likely me using the wrong stuff for keys but eh
my ass can all of those characters be in it
you said the key is only a single byte right?
yeah
that means that it's 8 bits
each bit having 2 possibilities
so 2^8 possible values for keys
wait I'm confusion rn kt fun blocksCommand(sender: CommandSender, @Optional arg: String?) { if (sender !is Player) { return sender.sendMessage("Player Command Only.") }
why?
which is 256 possible keys
what is thee confused about?
There's only 95 in possible_keys
you can just set the sender as player using Matt's lib
no need for that check
yeah I don't think we knew that at the time
ah ok
understandable have a great day
or nice day
I don't even remember the meme 😢
Components when?
How would I find the different possible keys though bardy?
you already know them
Soon™️
exqueezle moi wot
wdym
The only keys I could think of were the alphabet, numbers, symbols and space

are you shitting me
That's all I had to do
Yes
Blocked mirror for repositories: [mvdw-software (http://repo.mvdw-software.be/content/groups/public/, default, releases+snapshots), sk89q-snapshots (http://maven.sk89q.com/artifactory/repo, default, releases+snapshots), placeholderapi (http://repo.extendedclip.com/content/repositories/placeholderapi/, default, releases+snapshots)
Can someone help me figure out what this means?
a fat jar? like shaded?
send build.gradle
ooh wait nvm
Keep in mind you need to run ./gradlew shadowJar instead of ./gradlew build
yeah i missed that somehow
is there a way so i can add it to the build lifecycle?
nvm got it
bruh I'm about to set my discord to light theme so I can see
excuse me
i see
My god what is your ui there
Thats not even dark theme though
I see?
It's the TOS breaking UI
there is a dark dark theme in discord
if you spam click the dark theme in settings
you'll get it
really?
Only mobile, no?
idk.. for me it doesn't work. it just crashes discord xD
on pc
at least
never tried on mobile
I just know thgat's how you get it
how?
TOS Breaking
For me only works on mobile
he probably usess Better Discord
It looks like some old minecraft forum or something
which is against discord's tos
Any modification is
oh yeah its mobile only. Well I never knew xD
oh its called Amoled optimize mode so I can see why
lmao
oh shit this shit is not that bad
and I save more battery
nice
even tho I don't use discord on phone usually xD
Best theme
wait @ocean quartz wtf is this? https://i.imgur.com/oELUAQp.png
do you have the sidebar thing and its locked>?
its for light theme blitz
ohh yeah I remember
if u turn on light theme the option becomes available
🙃
busy
coc
Oh ive heard of that
@onyx loom @half harness @jovial warren (if you wanna take a break), @old wyvern @ocean quartz @surreal quarry @lunar cypress @obtuse gale @prisma wave @steel heart @cinder flare @oblique heath and the others I've missed
wanna join?
no.
im busy for the next 6 minutes
hm
consider it a handicap
Just normal darkmode
cant
wot
yeah talking about the sidebar thing. I forgot they added dark sidebar on white theme
ikr, imagine putting loads of effort and time into a project and then having people tell you that it's shit, and question why you bother
o
ugh that's to be expected. All great projects go thru that phase
well if no one joins I guess I'll have to beat ivan's ass
oh I missed @forest pecan
is that a challenge
wana join?
Uh not home
CoC
usually I say that when I know I'm going to get my ass kicked just so at least I look cool when I do
@obtuse gale wby? wanna join?
oh bbg joined
ok now I'm not going to be the only one getting his ass beat
gonna start
👀
kotlin 
um
clash?
Yes
link plz
nvm
got it
oh ok
can you join using ide? https://www.codingame.com/ide/383269688c9fa4b13939cb49f23cc3b4edfab33c
No?
Why is Blitz such a kek man is the question
I didn't even read all of it, just read "sum of numbers" and that was enough
well idk but I don't even know what a kek man is so
(1..n+1).filter { it%2==1 }.sum() shouldn't this work?
ugh
||just square it||
is this problem weird or is it just me
its weird
yeah it says sum of odd numbers but that's not what the test cases want
wait are you serious?
You shouldnt need the n + 1
That was exactly what it wanted
silly user submissions
share
but it ain't working
Thats the equation for sum of n odd numbers
unless you can get the sum of all odd numbers like that
Its an arithmetic progression
Look it up
somehow discovered that by accident
lol
I'm a 4head
Sn = (n/2) * (2 * a + (n-1) * d)
I know that the sum of numbers from 1 to n is n * (n - 1), or so I remember seeing somewhere
or is it n * (n + 1)
Its not
abuse
n * (n-1) / 2
^
yeah /2
new game?
yis
I think the problem is the hidden message
I mean, I asked about Starlight earlier in Tuinity's Discord and SpottedLeaf said "i would hope you would not disgrace its name by porting it to some shitty language like kotlin" so idk
not Kotlin
it's s c a l e a b l e
Starlight?
why no shortest
the lighting engine
😦
Most people will look down on any language they don't like, nothing new
I mean a lot of people here hated Kotlin before trying it
^
I mean honestly you wanna port something just fork and port it
Why do you give a shit what he wants
lol
The user is bard
??
You on drugs or?
easy
nvm
it worked for like 4 or 5 test cases
but of course its 33%
someone send a screenshot of the problem please
You already are more than enough
Nice, typed on google ScheiBe since I don't have the letter on my keyboard and it actually translated it correctly
i didn't know that was how you write "shit"
@oblique heath send ss of problem please. ty
Swamp germany (it's a joke don't kill me lemmo)
or is it
@static zealot
oh so it wasn't the number of os in it lmao
its the number of the most used char
that's why it passed like 3 or 4 tests
smh
well fuck
but at least I did it in 1 11
heh I thought it was o's as well at the start Blitz, test 4 fails tho
hi frosty
No, I'm busy
cringe
lol
I gotta go sleep, but I got stuff to finish
ffs I got beaten by dkim
explain
how
🥲
right, I gtg and eat now
ok
xD
okay Yugi that's actually cool
lol
that took too long
😌
i'm ashamed
i was first 😤
why not just use print @oblique heath ?
so that u dont have to do show
because the putStrLn was already there
oh
I don't know if I could have ever figured that out within the time limit
smh
Anyone know if theres a better way to use a jar library in a java 9 module than just adding the jar library to the classpath?
that seems like a old school and terrible way to go
there were some more examples that i didn't include in the screenshot that actually made it a lot easier to figure out
stuff like
a -> 1
aa -> 2
aaa -> 3
bbbbe -> 4
eebbb -> 3
ccdd -> 2
oh alright
that's not as bad then
basically just sort the string and count the highest number of consecutive letters
Doesnt have to be consective though does it?
almost, it was to get the number of the most common letter
Chestly?
Dkim
im not feeling well today
well what I just said would still find that solution lol
ah
ah you're right lol
Ill change it for one second
i didn't read that correctly xd
that's even worse
By worse i assume you mean better?
..I guess
I wish I could do the debug thing like how piggy does
Excuse me sir
Your name
is hideous
its good
I have to disagree on your opinion.
Lets agree to disagree then
lemme think, hm... no 🙂
Then sure, you have agreed that haskell is truely the best language
no
Too bad, so sad
Thats a weird statement
haskell is an actual language
^
no
It unfortunately is
It fortunately is 😌
can java have infinite lists? didn't think so 😎
yes it can
someone revive Rythm please
False
Just make a list within a list within a list on a for loop.
huh?
Thats not what an infinite list is
It is now
How does Haskell have infinite lists?
cause i compiled my first file and i fixed a bunch of errors by using casts
am i doing something wrong?
what
it doesnt feel right to cast from void to int lmao
lmao
wait is blackstone a thing in 1.16.5?
Wouldn’t it still use memory though?
No
not until it has to
Each element is only generated when it is needed
No element of the list exists before you use some terminal operation
Oh
it's like lying on a resume
So does it exist when you add to the list?
you pretend you have everything until it's time to use it, and then you quickly get it
not particularly
is there a way to pull from a fork?
or from the original
I have the fork
without having to PR
I remember there being something about git checkout or something
@humble silo I just noticed you're listening to my spotify feed, why lol
Idk i have nothing else to do
im judging you btw
fair enough
@tranquil crane bruh
kek
nice rickroll
fine I'll put it back
lol
lmao
I was legally required to do that
lmao
hmm
didnt see that but totally :p
@tranquil crane DJ switch the mix up
..ok
lol
what do you even expect me to play next
More rick astely
defintely
Or i wil get bored and leave
I didnt know "coming up next" was trade marked
yep™️
supposedly
wat
ngl when I saw that thumbnail I thought its something else
@tranquil crane Well thank you for being my personal DJ but im gonna have to lay you off... im sorry
sucks to suck
Hmm
:(
i turn on pc, start up minecraft and see my saved servers file corrupted, intellij throwing invalid errors, then my pc bluescreening
this is going great
why you dont use windows 
but windows is most user friendly
Windows isn't bad
No, but ive used both and i prefer Mac
racket
WHAT
yeah
what is btec
o
technically its a british course? u can take, but it sucks
so everyone makes fun of it for being a knockoff of something
bm what do u call it, because its not really a course tho is it
qualification, thats the word
Lmao
clash?
nap
is it against github TOS to make another account?
I don't see why it would
^
just making sure
many people do that in fact
It isn't
ah makes sense
yeah but you never know what strange rules there might be and ofc I didn't read them
xD
k
you could just use organisations
that's not what I want it for
I just wanna test some stuff
with git commands and PRs and stuff like that
Just use your main acc and then delete the repos?
well I am going to fork it from the other account
jesus
like 99% of that time is due to downloading nms
you see, I could of pointed my middle finger towards spigot and just zipped the nms files
and dropped it into the local repository
but im a good boy
wait why would you be downloading them each time
dont they get cached in your local maven repo or something
not in the ci
it's like its own instance each time so yeah
ahh
http 🤢
oh look there goes my data hahaha
Not anymore
Do you need the healthline called?
exactly
It begins.... 👀
https://hackage.haskell.org/package/async
Install via cabal install async.
[rating:2.75/3(n=7)]
Just delete it?
but it would be a ghost ping
dms dont ghost ping I think
fite me u bitch
Deleted?
Yeah
Oh ok yea, it doesnt go
ok
What im planning to do might be a bit over the top to implement in this
Hopefully this works
Wait what
lol
Wonderful
Time to make a web request race, may the IO-est win
what on earth
where would that function ever be useful
Ah maybe
Ok I've reached an issue
I guess it's useful enough to have it in the standard library
I need to figure out how to get it to respond to reactions and continue the action
I think the time may have come for the state monad
👀
DJ Maybe
A new challenger appears
what are you making yugi
Improving hasklash
Rewrote the part that already works in a better way
Now adding extra features
oooooh
hasklash 😩
I didnt even change much of how auth worked
Maybe just the difference in the library being used
no idea
Haskell works in mysterious ways
Altho Req is supposed to be more higher level than Http.Client
So it should be slower if anything
😌
Compiler Optimizations all the way
Oh speaking of which
I need a suggestion on something bm
So currently to search command flags, this is what im doing
lookupFlag :: [T.Text] -> T.Text -> T.Text -> Bool
lookupFlag args tag argPrefix =
any ((== (argPrefix <> tag)) . fst) $
zip args $ tail (args ++ [""])
But
(args ++ [""])
This
Ew
Will copy the entire list
So it doesnt discard 1 element from the command
zip ignores any extra elements
using tail means the second arg will have exactly 1 less element
Yea, only cons doesnt copy
yes from the head
The only other option would be to use Seq
Seems like they'd have an optimisation for that
Hopefully
Can someone quickly explain dependency inversion? Is it just using getters for getting objects?
?di
Dependency Injection
Dependency Injection is a way of providing objects with the objects they need ("dependencies"). This is usually done with a constructor, but can also be done for individual methods
Read more here: https://en.m.wikipedia.org/wiki/Dependency_injection
Dependency Injection in Java:
https://paste.helpch.at/yijawupoju.java
Dependency Injection in Kotlin:
https://paste.helpch.at/esogakutod.kt
That's dependency injection though, not inversion
np lol
Writing clean code is tough, and is one of the largest differences between junior and senior developers. One way that you can quickly improve your code and start writing well designed code now is to implement the dependency inversion principle. This principle is part of the SOLID design principles.
The main idea of the dependency inversion prin...
JS but the concept is there
@old wyvern how do you feed the CoC email + password into the bot here?
Dependency injection is a sort of dependency inversion
What's the difference then?
🤔
Thats the old source btw
Oh sry, didn't see that
eeh i thought i updated it
Thats poorly written, check out the rewrite branch
It's not really a bad video
also, it fetches it from environment variables
referring to this lol
Ah lmao yeah
Modern and pragmatic
Hasklashnikov 47
Valdemar
//dodo
class Alpha {
Beta beta = new Gamma();
}
//better
class Alpha {
Beta beta;
Alpha(Beta beta) {
this.beta = beta;
}
}
then
new Alpha();
vs
new Alpha(new Gamma());
wha xD
so are you alpha or beta
Sounds like Kalashnikov xD
Whose that?
Idk I’m lambda (:
lmao
The name of the AK rifles
kalashnikov sounds so much cooler than ak
From SOLID right?
But also that we shouldn’t depend on low level details
Yeah I think so
You saw, in the first example that beta variable was tightly coupled with the gamma implementation
Dependency Injection is about passing dependencies of an object to it, dependency inversion is about high level objects using abstractions to interact with low level objects rather than directly
Ohhh
So dependency inversion requires the use of abstract classes?
Or interfaces
abstraction is a general term here
Not refering to how the abstraction occurs
mhm
So dependency inversion is just like using a super class to access child classes objects or what?
Can't exactly remember if it's called super and child
Yeah abstracting as just specifying the behavior, but generally when we speak of abstraction I would say it’s to take away.
the child
super sub
i felt like i wasnt actually taught these keywords tbh lol. I just kinda
did it
i never knew it was called dependency inversion until someone brought up SOLID
All the SOLID principles complement each other, this is related to liskov if you understand that
Your program shouldn’t depend on subclasses
Depend on specific abstractions depending on the requirements rather than implementations. In short, all implementations details must be hidden and assumed to not exist
I mean my explanation is poor
liskov substitution principle is the simplest of them all
It simply states that any object should be replaceable by an object of a sub type without problems
Wait what? That's not what was explained above though
Meaning if I have class A and B and C extend A, I should be able to replace A a = new B() with A a = new C() without changing the program correctness
Its the same thing vald
it's not the same thing
They are complementary perhaps, but Liskov didn't say anything like that for this principle
So B and C are just subclasses of A?
Yeah or subtypes
Mhm
Whatever though of course this doesn’t mean you should go around only using the super type Object
this is it
But B and C does not contain the same code?
everything that works for parent classes should also work for their subclasses
if you want to put it another way
no
If they did it would be meaningless to have 2 both B and C
One example of a violation of this principle is the Java collections framework
