#dev-general

1 messages · Page 536 of 1

prisma wave
#

evaluate context (AddExpression left right) = liftA2 (+) (evaluate context left) (evaluate context right) 😌

distant sun
#

H🤢skell

prisma wave
#

dont even

steel heart
#

Gaby I have to disagree you from your incredibly bad subjective opinion as opposed to the objective facts Haskell is good (;

prisma wave
#
instance Evaluate Expression where
   evaluate context expr = case expr of
     (VariableExpression name) -> maybeToRight UnboundVariableError $ variables context M.!? name
     (ConstantExpression value) -> pure value
     (AddExpression left right) ->  binaryCombine (+) left right context
     (SubtractExpression left right) -> binaryCombine (-) left right context
     (MultiplyExpression left right) -> binaryCombine (*) left right context
     (DivideExpression left right) -> binaryCombine (/) left right context
``` 😌
sly sonnet
#

it literally looks like expanded version of kotlin's when

prisma wave
#

expanded?

sly sonnet
#

bigger

#

larger

#

more to write

prisma wave
#

this would be longer in kotlin

#
when (expr) {
  is AddExpression -> binaryCombine(Int::plus, expr.left, expr.right, context)
}
sly sonnet
#

how is it longer?

prisma wave
#

is AddExpression -> binaryCombine(Int::plus, expr.left, expr.right, context)
(AddExpression left right) -> binaryCombine (+) left right context
how isn't it?

sly sonnet
#

at least i can normally read it, your code block looks like some c code

prisma wave
#

not sure what c code you've been looking at

jovial warren
#

lol

jovial warren
prisma wave
#

😌

ocean quartz
#

config[BanConfig.ENABLED] smh

half harness
#

has anyone used graalvm native image before 🥺

prisma wave
#

Yeah

#

That sounds suspiciously like asking to ask though

half harness
#

oop

hot hull
#

Hey @cinder flare How's FJ doin

gusty glen
#

what lift does?

half harness
gusty glen
#

lift function

hot hull
#

Show the function

gusty glen
#

ops I forgot to turn ping off

prisma wave
#

Uh

#

idk exactly what it "does" but the signature is something like (Applicative a) => (b -> c -> d) -> a b -> a c -> a d

prisma wave
#
lexDigit :: String -> Int
lexDigit ('-' : str) = negate $ lexDigit str
lexDigit str = foldl (\acc val -> acc * 10 + val) 0 $ map charToInt $ takeWhile isDigit str
``` 😌
#

😌 😌

#

oh shit i need decimals

#

hmm

#

it reverses the decimals

#

fixed it

prisma wave
#

on the downside the code now looks borderline obfuscated

#

and doesnt fully work

#

😩

static zealot
#

😌

half harness
#

😌

prisma wave
#

shut

#

nvm

#

i found a lovely fix

#

man

#

an hour just to get number parsing working

prisma wave
onyx loom
#

i am once again a peasant 😖

half harness
#

🥲

#

jetbrains toolbox ftw

prisma wave
onyx loom
#

shut it

hot hull
#

How come?

static zealot
onyx loom
static zealot
#

@half harness is that time of the month again

half harness
#

wat

prisma wave
onyx loom
#

no

onyx loom
#

maybe

#

but oh well

half harness
static zealot
half harness
#

exe file

#

packaged jre

#

spent like 7 hours on it

#

so far

#

like the past 2 days

#

i might be getting somewhere

#

it always errored out at like 1 minute

static zealot
#

well then time to play alone again

half harness
static zealot
#

o

half harness
#

plzplzplzplzplzplzplzplz

#

f

#

noooooooooooooooooooo

#

whyyyyyyyyyyyyyyyyyyyyyyy

#

it no workey

static zealot
#

its telling you to take a break

#

👍

half harness
#

i shall persist

static zealot
#

and the problems shall persist too

half harness
static zealot
#

well it tells you exactly what's the problem

half harness
#

idk how to fix it

prisma wave
#

shade it

#

obviously

half harness
#

but

#

what

prisma wave
#

lexer working

#

not sure why it didnt print with spaces

#

but

steel heart
#

lombok be like

@Getter
@Setter
@AllArgConstructor
@HashCode
@ToString
@ValueOf
@LolIdkSomeShit
@InlineMethodOfSomeShit
@HahahEvenMoreAnnotsIamTrueProProgrammerNow
class Popo {
  final Object state;
}```
ocean quartz
#

"Reducing boilerplate"

potent nest
#

🤔

#

while I don't like lombok, I never had the impression that you have a lot of annotations with it

steel heart
#

its a joke mostly

#

But you do end up with a lot of annots tho

#

well if u follow lombok purism

static zealot
#

just to make sure, the last one was saying that type of dev doesn't exist right?

#

@half harness u got your thing working btw? xD

old wyvern
#

Yea

static zealot
# old wyvern Yea

ok good. bcz I was confused. I thought they either mean that, or those devs are super clean or something

old wyvern
#

lol

static zealot
#

spiderman

obtuse gale
static zealot
#

ok

steel heart
static zealot
#

a month?

#

damn how the hell did he survive that

steel heart
#

🥲

distant sun
steel heart
#

imagine not having an about me cough blitz cough

distant sun
#

tbh should be c

steel heart
#

lolol

static zealot
#

what for? I'd just set it to NO!

#

I think my name and my status does the job

#

oh I Lost my status bcz it is 12:08

#

lmao

steel heart
static zealot
#

I've set it 10 minutes ago...

steel heart
static zealot
#

oh also @steel heart

steel heart
#

ye

static zealot
#

there we go

steel heart
#

tried telling u

#

AYE

static zealot
#

oh.

steel heart
#

NO! NO! NO!

static zealot
#

I didn't know they rolled it out to everyone

#

thought you were trying to flex

#

or something

steel heart
#

lmfaooo

obtuse gale
#

whats the new javascript engine called

prisma wave
#

deno?

#

or do u mean the papi one

obtuse gale
#

in papi

#

engine: nashorn is the old one

#

what should i change it to

#

i tried engine: javascript, didnt work

steel heart
#

lol

prisma wave
#

you shouldn't need to change it

potent nest
#

I hink it's using a V8 java implementation

steel heart
#

It uses monads

prisma wave
#

i think they gave up on v8

#

quickjs now iirc

#

cc @old wyvern

obtuse gale
#

one sec ill show ya

steel heart
#

prisma wave
prisma wave
#

it's painful

steel heart
#

Oo

obtuse gale
#

we cant send pics rip

prisma wave
#

use imgur

steel heart
#

u r the man alex

prisma wave
#

ty ty

#

well

#

probably not

#

it's not going very well

obtuse gale
#

ty lightshot

steel heart
#

once you succeed you shall find the true power I promise 😄

#

ImporterAdapterCandidateParameterWorkerInterpreterSingletonDatabaseTagProducerPoolModelClientBroadcasterDatabaseDecoratorIteratorPrototypeStrategyAdapterAdapterCloneHelperSetterQueueConfigurationTestTestsExpressionTestComposerAdvisorThreadTestContainerFilterTestInterpreterErrorSchemaOrderDatabasePoolInterpreterAuthenticationDecoratorDefinitionMapperDatabaseWorkerBroadcasterRequestComparatorDescriptorDefinitionUtilsPropertyTemplateErrorMappingAuthenticationWrapperListBroadcasterContextSchemaCallbackFieldSingletonIteratorBridgeWorkerObserverUtilsConfigurationWrapperValueHelperMessageCandidateEventMethodPublisherIteratorConsumerContextPoolMapFacadeTemplateObserverProccesorModelComposerManagerStateComparatorWrapperListenerSingletonBroadcasterStrategyInterpreterInterpreterTestTaskClientRepositoryAuthenticationAdvisorAttributeClientAnnotationMethodInstanceWrapperComparatorReponseExpressionCallbackPublisherPolicyCandidateInstanceSerializerUtilsProducerPrototypeSingletonPrototypeConsumer
anyways enjoy

obtuse gale
#

sooo

#

what do i put in the engine name field

#

;-;

steel heart
#

quickjs maybe

prisma wave
#

are you even using the updated version?

#

o maybe it is v8

#

well

#

nevertheless

obtuse gale
#

v8?

#

just type in v8?

#

thats with quickjs

prisma wave
obtuse gale
#

i tried graalvm, but it doesnt work anymore since there isnt a stable graalvm for 1.16

obtuse gale
prisma wave
#

i am reasonably sure that the engine type won't matter whatsoever

obtuse gale
#

When i changed it to quickjs the error changed lol

old wyvern
prisma wave
#

hmm

forest pecan
#

From meh

steel heart
#

hehehehe

old wyvern
#

Thats J2V8

steel heart
#

Pulse wyd rn

old wyvern
#

Ill get the qjs one out soon

forest pecan
#

Playing clarinet

steel heart
#

ooo

forest pecan
#

I got it polished

prisma wave
#

odd

steel heart
#

nice

#

record and upload for me

#

😄

obtuse gale
#

omg lol

#

I think papi deleted the new extension

#

and replaced it with the old one

steel heart
#

😬

prisma wave
#

classic

obtuse gale
#

probably one of my devs messed with the ecloud download command

#

that ones my bad sorry XD

prisma wave
#

np np

forest pecan
#

Idk if the sound quality is great cause I put the phone in front of my clarinet

#

Lol

prisma wave
#

sounds nice

prisma wave
#

i did it

#

bind :: Parser a -> (a -> Parser b) -> Parser b
bind p f = Parser $ \tokens -> do
  let initialParsed = parse p tokens
  concatMap flatten initialParsed
  where
    flatten (resEither, remainingTokens) = case resEither of
      Left err -> [(Left err, remainingTokens)]
      Right a -> parse (f a) remainingTokens
#

not sure if it works

#

but it compiles

#

😌

static zealot
forest pecan
#

Great job

static zealot
#

yeah Ik

forest pecan
#

Embrace my playing lmao

obtuse gale
ocean quartz
forest pecan
#

Oh no

obtuse gale
#

I use to run the violin and piano I feel the music vibes

prisma wave
#

nah this is a learning project

forest pecan
#

Yeah lol

prisma wave
#

creating a competitor to redempt's crunch lib

#

for fun ofc

ocean quartz
#

Was gonna say, it started in Kotlin (i think) then Go now Haskell xD

prisma wave
#

😌

#

it's scala now

#

not that it really matters

old wyvern
#

bm

prisma wave
#

yo

old wyvern
#

Is the parser spec being prepared?

prisma wave
#

uhhh

#

sure

old wyvern
#

oh ok

prisma wave
#

lol

old wyvern
#

xD

prisma wave
#

i will try do a bit tomorrow

#

feel free to do some yourself if u want ofc

old wyvern
#

Alrighty, awesome

#

@cinder flare are you busy rn?

cinder flare
#

Uh not really just woke up why?

old wyvern
#

oh nvm then, just needed some help testing the js exp

cinder flare
#

Oh ya I'll be there in like an hour

old wyvern
#

Alrighty

steel heart
obtuse gale
#

man why do gradle stack traces have to be SO FUCKING HUGE

forest pecan
obtuse gale
#

uranus

forest pecan
#

Lmao

#

There will be only 7 planets left after I destroy Uranus

obtuse gale
#

damn okay

ocean quartz
obtuse gale
cinder flare
#

@sacred frigate yeah I gave it a look, their custom repo is down so you literally can't even compile the plugin right now

#

I think I need some more ram guys

old wyvern
#

Download some 😌

cinder flare
#

ya seriously

#

bro why it be so expensive

cinder flare
#

literally a 403 forbidden lol

sacred frigate
#

not really sure how this works haha

cinder flare
#

I mean I literally cloned their repo and it is so over-engineered

#

You can't compile without accessing their repo for the compat modules or something

sacred frigate
#

i see

cinder flare
#

Also that thing is a beast, it looks very painful to maintain

#

I doubt you'll get it by July

placid palm
#

does anyone offer services to create a tebex website for a discord shop?

boreal needle
placid palm
#

alr!

delicate cradle
#

anyone know anything about the legality of reproducing things?

old wyvern
#

reproducing what exactly?

#

What?

delicate cradle
#

Im making a portfolio site for my java development and one of my projects was the recreation of NES tetris using no libraries. I didnt know if I was allowed to have that content on my site know it is copyrighted and whatnot

old wyvern
#

tetris itself probably doesnt belong to a company, its kind of a general game

delicate cradle
#

ah

old wyvern
#

Just make sure you dont refer to anything specific from other versions in your version

delicate cradle
#

what does that mean

old wyvern
#

As in dont have references to other companies

delicate cradle
old wyvern
#

Remove the NES and redesign the background if you copied that

#

I mean even if you do release this with references, I doubt they really care

prisma wave
#

Or Sega

old wyvern
#

really?

prisma wave
#

Oh maybe not

old wyvern
#

arent there like a lots of tetris implementations?

prisma wave
#

But it's definitely owned by some company

#

Probably yeah

old wyvern
#

The Tetris Company, Inc. (TTC) is based in Nevada and is owned by Henk Rogers, Alexey Pajitnov and Blue Planet Software. The company is the exclusive licensee of Tetris Holding LLC, the company that owns Tetris rights worldwide. It licenses the Tetris brand to third parties.

delicate cradle
#

ok this

#

like that

#

i changed that to say,

Original concept and design by Alexey Pazhitnov, code written by Jonah M
prisma wave
#

Yeah

delicate cradle
#

okay

#

im not releasing the actual game

prisma wave
#

I am not a lawyer tho so don't quote me on that

delicate cradle
#

yea np

#

i just wanted to make sure it wouldnt like instantly blacklist my site for copyright reasons idk

obtuse gale
#

Nothing will happen lol

#

Nobodies gonna come after you

lunar cypress
#

You can't copyright concepts or general gameplay ideas I think

cinder flare
#

EA sure tried for lootboxes

eternal compass
#

Really? That's a pretty broad idea

#

What about cards that give stuff?

#

Same concept

cinder flare
#

yeah I think it's like luck-based rewards or something vague

main knot
#

Just installed Java 16 on linux and the server had this error:
[16:53:53 INFO]: [STDERR]: java.lang.UnsatisfiedLinkError: Can't load library: /usr/lib/jvm/java-16-openjdk-16.0.1.0.9-3.rolling.fc33.x86_64/lib/libawt_xawt.so
It won't start, should i try and reinstall java?

cinder flare
#

which distro?

#

also I recommend you install it with SDKMan, that is definitely worth a try

main knot
#

Managed to get it to work, thankyou

jovial warren
#

@prisma wave remind me of what that system is called that shows all those stats on your profile

prisma wave
#

hmm?

timber oak
#

How do I get the HTTPS URL from a new project?

#

Doing step 7 rn but can't figure it out

hallow crane
timber oak
#

Ohhh right so it's from the already existing repo I should do it

hallow crane
#

Usually

timber oak
#

ty

hallow crane
#

np

timber oak
#

How is this wrong then?

#

@hallow crane

hallow crane
#

remove that second 'remote'

prisma wave
#

remote repository url means the url

#

so git remote add origin [url]

hallow crane
#

yeah

prisma wave
#

kinda weirdly worded

timber oak
#

Ohhhh

#

I see

#

ty

hallow crane
#

np

timber oak
#

I use gradle 7.1?

boreal needle
#

my plugin reached 100 servers today, might not be much but i'm really proud of it

timber oak
#

Grats!

boreal needle
#

thanks :)

hallow crane
#

It's not on that project

#

do that

#

or do ./gradlew wrapper --gradle-version 7.1

#

depends what type of wrapper you're using but if one doesn't the other will

hallow crane
#

Ah so basically youre in a stuck spot

#

Using an unsupported version to get to a supported version

timber oak
hallow crane
#

Try to change your java version to like 11

#

Then change to gradle 7.1

#

Then change back to 16

timber oak
hallow crane
#

Awesome, np

timber oak
#

I can't find any events like PlayerBowShootEvent or smth

#

Does someone know one like that?

obtuse gale
#

ProjectileLaunched or smth

timber oak
#

Ahhh yeah ty

timber oak
#

e.getEntity() returns the projectile entity lol

#

So idk what to do

obtuse gale
#

Projectile#getShooter or something

timber oak
#

Ahhh great, thanks

timber oak
#

Ughhh I remember having to fix this but I forgot how it's fixed, it was something simple I remember, that's not on the given link

obtuse gale
#

Show your gradle build script @timber oak

timber oak
obtuse gale
#

Replace everything in processResources with this

eachFile { expand version: version }
timber oak
#

Alright, and btw ik I fkd it up with the DuplicatesStrategy, I just didn't know what to do lol

timber oak
#

Oh what, I thought that Java 16 could run servers in 1.16.5?

half harness
#

ooooooooooooof

obtuse gale
#

Paper totally can

timber oak
#

Oh lol

#

Anyways

#

Can someone explain this???

#

I did try restarting cmd multiple times

#

And the env variables

half harness
#

make sure you set it in the PATH

#

JAVA_HOME by itself does nothing but create an env variable, which some apps do use, java command does not

timber oak
#

In Path:

#

Wait u mean system variables or what?

#

or user variables

obtuse gale
#

system ones yeah

timber oak
#

Weird that it's java 16 enabled then

obtuse gale
#

so it "picks" that one first

timber oak
#

Hmmm

#

maybe

#

difficult to say lol

#

Yeah moved 8 one up

#

and it worked

obtuse gale
#

ew

#

8

timber oak
#

I'm just testinnggggg lol

steel heart
#

yylime

half harness
turbid geode
#

is there a dev version of 1.17 deluxemenus?

half harness
#

?dm-builds

compact perchBOT
half harness
#

@turbid geode maybe

ocean quartz
pallid gale
#

1.17 dev build ^

half harness
pallid gale
#

correct

#

why on earth are they in different spots

half harness
#

¯_(ツ)_/¯

#

ask blitz

#

:))

pallid gale
#

i wanna speak to the manager

half harness
#

👀

pallid gale
half harness
pallid gale
#

damn

half harness
#

He will be back soon, don't worry

#

Don't you dare worry :)

ocean quartz
#

But.. you are the manager!

pallid gale
#

wot. no

old wyvern
#

😏

tranquil crane
#

Anyone know if there's a feasible limit to the amount of data that can be stored on an entity/chunk's PersistentDataContainer? Like, a couple megabytes? Maybe even a few hundred megabytes? This seems like a https://tryitands.ee situation and also kind of sounds like a stupid idea but I may as well find out

hot hull
#

Don't think there's a limit

#

But I mean might have issues with larger data as per usual

tranquil crane
#

My only concern would be if it ends up slowing down the chunk loading process for entities with a ton of data stored in their nbt

hot hull
#

My question is tho, why in the hell would you need that much data

tranquil crane
#

:)

#

I'm considering trying to move the stack data for my stacker plugin onto the chunks and entities instead of in the database since there are some possible data loading issues with it

hot hull
#

Storing your pron collection on chunks?

tranquil crane
#

I serialize entities into their nbt and store them in an array in the database as the stack data on an entity so I have a 1:1 copy of the entity when I respawn it out of a stack

#

I probably need to find a way to compress that array down since most of it is identical info anyway

hot hull
#

You're storing more than you actually need so yea

tranquil crane
#

The main things it really needs to store are entity equipment and the different variants of mobs, guess I'll just do some experimentation and see if this is even a good idea or not

obtuse gale
#

i just can't find where 🙃

#

probably either wiki.vg or the minecraft fandom

#

chunk/region/world format etc

hot hull
#

I mean you realistically will never reach that limit if you're using atleast 1% of your brain so

obtuse gale
#

ya bet

tranquil crane
#

good thing I can use 2% of my brain then

prisma wave
obtuse gale
#

exactly

old wyvern
#

The chunk book one

#

@prisma wave you're using spring for the dev-den backend right?

prisma wave
#

Yup

old wyvern
#

ok, was messing around with some spring stuff, for security config, would basic auth be enough or is oauth2 a significant improvement?

prisma wave
#

define "enough"

#

oauth2 is definitely better

old wyvern
old wyvern
prisma wave
old wyvern
#

ah

old wyvern
#

@prisma wave Album worthy?

prisma wave
#

absolutely

#

There's this one too

#

oh it's the same guy

#

🥲

cinder flare
#

yeahhh

old wyvern
#

🥲

obtuse gale
#

cl;ear lag sooo good

cinder flare
#

They didn't remove your message

#

And it was most likely removed because you double-messaged

ruby dew
#

alr thats ridiculous but ok

cinder flare
#

It's also not recent

#

If you read the pin

old wyvern
#

Ghost ping?

cinder flare
#

the palace guy as mad at you two for "removing his message" lol

old wyvern
#

Lmao

jovial warren
#

@tranquil crane the only limit I can think of in terms of data is with the actual packet sending

#

like the maximum packet size is 2 MB iirc

tranquil crane
#

The actual nbt of the entities isn't sent over packets so that should be fine

jovial warren
#

so if your chunk data, for example, exceeds that, the client complains

tranquil crane
#

I don't think spigot sends over the custom data saved on chunks either

jovial warren
#

probably doesn't, since I doubt the client would understand it

ruby dew
#

cuz i rarely come to this server

pallid gale
#

Showcases need to be recent

ruby dew
#

oh alr gotcha

#

sorry mate i just came back to mc

pallid gale
#

No worries

quaint isle
#

Hey plugin devs, is it allowed to post Spigot plugins to dev.bukkit.org?

cinder flare
#

Why would you ever want to?

ruby dew
#

also why did i got showcase muted lmao

quaint isle
#

More organic reach, bukkit still gets some traffic, no?

ruby dew
#

doubt anyone even still use bukkit these days

pallid gale
cinder flare
#

And I don't know what "organic reach" means

ruby dew
#

just curious

pallid gale
#

24 hours or something

prisma wave
#

Please sir do not ghost ping me

ruby dew
#

alr

ruby dew
quaint isle
#

Well, I checked a few plugins and for every 100 downloads they have on Spigot they have like 15-30 on bukkit. That's worth the effort imo 😄

pallid gale
#

surprised people still use bukkit dev

cinder flare
#

Yeah I'm surprised people even post their updated plugins on bukkit dev

#

Curseforge needs to take that site down or archive it or something

pallid gale
#

lol

quaint isle
#

I guess the bukkit forums are still somewhat active, no? Maybe people over there enjoy using bukkitDev 💁‍♀️

ruby dew
#

i thought bukkit was down back in 1 year ago

cinder flare
#

Bukkit doesn't exist anymore

#

No reason for that site or forum to exist

obtuse gale
#

theres still older versions

cinder flare
#

For like, beta minecraft?

#

That's why I said archive it 🙂

quaint isle
#

isn't bukkit just the api that plugins use?

cinder flare
#

No

obtuse gale
#

im getting sent to a different school for 2 days

cinder flare
#

Spigot is

obtuse gale
#

bruh

cinder flare
#

Bukkit was yeeted from existence due to the DMCA

ruby dew
#

what is bukkit?

obtuse gale
#

bruh

#

yh what is it

cinder flare
#

so they made Spigot, which is literally bukkit but with a fresh coat of paint and a little less copyrighted code

obtuse gale
#

alright im confused af bye

#

WTFFF

#

nms>all

ruby dew
#

nms is really painful

#

for me

obtuse gale
#

goku>all

cinder flare
#

good thing it's not relocated starting in 1.17 🙂

obtuse gale
#

lol i love how yo use see the msg people send before it gets deleted

cinder flare
#

hmmm

obtuse gale
#

yea youre weird bro lol

#

who

#

if you hard r youre fucking werid

#

i aint hard

#

tf

obtuse gale
#

Until hangar™️ soon

#

wafflers

quaint isle
#

Good point emily, thanks

cinder flare
#

curseforge still runs bukkit dev that's what I'm talking about

obtuse gale
#

Yeah and?

cinder flare
#

and I don't see how your message is a response to what I was saying

#

I said "Why would you ever want to upload to Bukkit dev"

quaint isle
#

Yes and she explained why 😄

cinder flare
#

I can understand uploading to normal curseforge

obtuse gale
#

Hey plugin devs, is it allowed to post Spigot plugins to dev.bukkit.org?
Why would you ever want to?

#

why would you ever make plugins for free :::))))

ruby dew
#

looool

cinder flare
obtuse gale
#

If you want to publish a paper only plugin you can do it in there, spigotmc will take it down instead

cinder flare
#

I was under the impression that you were talking about that

#

not bukkitdev

quaint isle
#

isn't bukkit dev / curseforge the same tho? Different sites but the same plugins, no?

pallid gale
#

Has left 😦

pallid gale
#

Didn't let me ban him

cinder flare
#

sad!

obtuse gale
cinder flare
#

ya but on their main website

pallid gale
#

just post ur plugins to a discord channel

#

ez profit

cinder flare
#

they literally do

obtuse gale
#

idk but the plugins section is the same as dbo I think

#

It's literally the same thing

obtuse gale
cinder flare
#

well lets get rid of dbo it's ugly 🙂

obtuse gale
#

Lmao

#

Special

quaint isle
#

ok funnycube I'm boutta post rn 😎

cinder flare
#

are you saying I'm special?

pallid gale
#

didn't say post it here

#

get your own discord D:

quaint isle
#

D:

obtuse gale
cinder flare
#

you motherfucker

pallid gale
#

wew

obtuse gale
#

In a good way ::))

pallid gale
#

banned

obtuse gale
#

It's so cold I cannot feel my toes

cinder flare
#

good

obtuse gale
#

Not good

#

put the heat on

pallid gale
obtuse gale
#

Shh

cinder flare
#

maybe your toes will feel special

obtuse gale
#

Lol

distant sun
#

Ok

jovial warren
#

kek

timber oak
#

Difference between World.playEffect() and World.spawnParticle()?

#

I know that one uses Effect and the other uses Particle

#

But I can't get the effect one to work

#

I'm trying to make coloured fireworks

jovial warren
#

what makes this even more confusing though is that particles are sometimes called "particle effects"

#

actually, ik what playEffect does

#

@timber oak

#

you want spawn particle with a dust effect I think

timber oak
#

Ohhh so effects are basically just sound effects?

jovial warren
#

yes

#

an effect in terms of the protocol is literally just a sound effect from a list of pre-defined sound effects specific to that effect packet

#

actually, apparently you can send particles with this as well, though nothing you want

#

these are all block particles

timber oak
#

So I just need to play the dust effect particle?

jovial warren
#

no, you need to send the firework particle from the looks of it

timber oak
#

Yeah but there's only FIREWORKS_SPARK in 1.16.5

#

Which isn't really what I'm looking for

jovial warren
#

@tranquil crane maybe you can help here?

tranquil crane
#

what's up?

#

do I hear particles

jovial warren
#

my knowledge of particles is running out lol

timber oak
#

Yeah lol

#

particles

tranquil crane
#

I have all particle knowledge

timber oak
#

Firework particles basically

tranquil crane
#

they can't be colored

timber oak
#

Just like the ones made ingame

#

Oh

tranquil crane
#

fireworkspark particles are colored client side

jovial warren
#

oof

tranquil crane
#

Yeah trust me I wish you could color them but you just can't

timber oak
#

Damn

#

How about trails

tranquil crane
timber oak
#

How are they made

tranquil crane
#

wdym trails

timber oak
#

arrow trails for example

tranquil crane
#

lol

#

just keep track of spawned arrows and spawn particles in a runnable at the arrow locations

timber oak
#

But how do I color those particles?

#

I've seen it on servers before

tranquil crane
#

consult the particle spawning guide above :3

tranquil crane
#

ye

#

see the colored particles section in there

timber oak
#

Yup, ty

tranquil crane
#

my guide still helping people to this day

#

need to update it with the new 1.17 data types

timber oak
#

Is it yours?

tranquil crane
#

yeah lol

timber oak
#

Damn, nice

tranquil crane
#

I know essentially everything about particles so if you have any questions feel free to just ask

timber oak
#

Alright, sounds good

tranquil crane
#

most of the knowledge dump is in that spigot post though

timber oak
#

Great guide ngl

#

Good examples

tranquil crane
#

tyty

timber oak
#

Hmmm it won't work

#

Lemme show what I made

#
        double note = 6 / 24D; // 6 is the value of the red note

        new BukkitRunnable(){
            @Override
            public void run() {
                arrow.getWorld().spawnParticle(Particle.NOTE, player.getLocation(), 0, note, 0, 0, 1);
            }
        }.runTaskTimer(customBows, 1, 1);
#

Nothing happens

tranquil crane
#

You probably want to spawn the particles at the arrow location and not the player

timber oak
#

oh bruh

tranquil crane
#

lol

#

it do be like that sometimes

timber oak
#

Same thing tho

#

No particles

#

This is the entire event

    @EventHandler
    public void onShoot(ProjectileLaunchEvent e){
        if(!(e.getEntity().getShooter() instanceof Player) && !(e.getEntity() instanceof Arrow)) {return;}
        Player player = (Player) e.getEntity().getShooter();
        Arrow arrow = (Arrow) e.getEntity();

        NamespacedKey key = new NamespacedKey(customBows, "Special-boy-arrow");
        PersistentDataContainer tagContainer = arrow.getPersistentDataContainer();

        if(!(tagContainer.has(key, PersistentDataType.STRING))){return;}
        System.out.println("debug 1");

        double note = 6 / 24D; // 6 is the value of the red note

        new BukkitRunnable(){
            @Override
            public void run() {
                arrow.getWorld().spawnParticle(Particle.NOTE, arrow.getLocation(), 0, note, 0, 0, 1);
            }
        }.runTaskTimer(customBows, 1, 1);
    }
#

and customBows is just the main class

tranquil crane
#

And it actually prints debug 1?

timber oak
#

Wait fk

#

...

tranquil crane
#

in that first if statement you want to use || instead of &&

timber oak
#

True

#

But I fkd the PDC up, first time using it

tranquil crane
#

that tag container will probably never contain that key since you never actually saved it unless you're doing that somewhere else

timber oak
#

So gotta fix that rq

#

I did set it somewhere else

#

But it's in the onHit event... lol

#

So gotta move that around

tranquil crane
#

You're going to want to put a check inside that runnable for if (!arrow.isValid()) this.cancel();

#

otherwise you'll just get particles endlessly spawning even when the arrow despawns

timber oak
#

I've got a ProjectileHitEvent that removes the arrow

tranquil crane
#

if it doesn't hit a player I mean

timber oak
#

Also got EntityDamageByEntity event

#

Should handle it

tranquil crane
#

oh that event does handle block hits ok

#

if you shoot an arrow into an upwards bubble channel it could still despawn without ever hitting a block

timber oak
#

Ah yeah true, will isValid() check for that?

tranquil crane
#

yeah it should

#

it'll return false if the entity is dead/removed

timber oak
#

Any way to increase count with SPELL_MOB?

#

You're saying in the guide it needs to be 0

steel heart
#

@old wyvern RRCATWebSecurityConfigurerAdapter the enterprise level PES_Blush

tranquil crane
#

It does need to be 0, if you want to spawn multiple you need to use a for loop

#

If you use anything other than 0 it'll either use black or just randomly color the particles, I don't remember which

timber oak
#

Alright, I'll just make a loop, not sure if it will be bad for performance tho, with all those particles

steel heart
#

😌

tranquil crane
#

you can spawn particles async if that makes you feel any better

old wyvern
#

Blame spring

steel heart
#

🥲

timber oak
steel heart
#

lmao spring ok u have a reason

tranquil crane
#

ah yes do love me some AbstractAnnotationConfigDispatcherServletInitializer

winter iron
#

yummy

#

😋

tranquil crane
#

still pales in comparison to HasThisTypePatternTriedToSneakInSomeGenericOrParameterizedTypePatternMatchingStuffAnywhereVisitor.java

winter iron
#

+1

steel heart
cinder flare
#

the only acceptable part of eclipse

timber oak
#

Nicole what would you do to make something like a firework explosion at the onHit then?

#

Right now I use the spark

#

But it's kinda bad

#

@tranquil crane

#

Atleast I want to make the sparks smaller if possible

tranquil crane
#

You can simulate your own little firework explosion by applying a velocity to the particles but they wouldn't be colorable

#

there aren't really any terribly good options

#

you could try spawning a firework with a power of 0 at the location but then you'd have to cancel the damage it deals too

timber oak
tranquil crane
#

I say how to make them directional in that particle guide, though you'd need to probably do some vector math to get them to spread out in a sphere from a point

old wyvern
timber oak
#

How how can I handle vectors from a particle?

#

Can't find that in your guide

tranquil crane
#

It's the directional particles section

#

I guess that one is quite a bit less documented than the others

#

still tells you how though I suppose

timber oak
#

But setting count to 0 just allows the use of colors in the particle I use

tranquil crane
#

pass the vector x, y, and z to the offsetX, offsetY, and offsetZ particles

#

only some particle types can have a velocity applied

#

the list is in a spoiler

#

none of the colored ones can have a set velocity

timber oak
#

Oh right I don't use colors for this particle

tranquil crane
#

to make things worse the velocity applied isn't even consistent across all the particle types so you'll just have to experiment with it

timber oak
#

The difficult thing will be to make it like an explosion

timber oak
#

Might help a bit, but the explosion has to go all around in 3d

tranquil crane
#
Vector v = Vector.getRandom().subtract(0.5, 0.5, 0.5).multiply(2);

you could just try using that as the vector and see if it explodes in a circle like you'd expect

#

use a different randomized vector for each particle

timber oak
#

Java util vector or bukkit?

tranquil crane
#

bukkit

timber oak
#

Bukkit doesnt have getRandom()

tranquil crane
#

the java util vector is a List type class

#

are you using a bukkit version that's older than dirt

timber oak
#

wait nvm

tranquil crane
#

lol

timber oak
#

I copied your code just before and it said random() instead of getRandom() lol

tranquil crane
#

o yeah my b didn't remember exactly what it was called

#

Which particle type are you using?

timber oak
#

Ehhh wat

timber oak
tranquil crane
#

I didn't remember the exact parameter types of the vector methods

timber oak
#

I'll ask google rq

tranquil crane
#

just wrap it in new Vector(0.5, 0.5, 0.5)

#

so like .subtract(vectorhere)

#

Vector.getRandom() returns a vector with all the values between 0 and 1, subtracting 0.5 from them all makes it between -0.5 and 0.5 and then multiplying it by 2 makes it between -1 and 1

#

doing that should get you a spherical looking particle distribution

#

You might need to do .normalize() on the end if you want them to all go the same distance away from the center point

timber oak
#

Alright, I'll test that now

tranquil crane
#

I'm going to head to sleep, if you need my response ping me and I should be away for at least the next 10 minutes

timber oak
#

Alright sounds perfect, this should work tho

#

Not sure what I'm doing wrong here

        Vector v =  Vector.getRandom().subtract(new Vector(0.5, 0.5, 0.5)).multiply(2).normalize();

        projectile.getWorld().spawnParticle(Particle.FIREWORKS_SPARK, projectile.getLocation(), 0, v);
#

Just reply whenever you got time @tranquil crane

tranquil crane
#

Instead of passing the vector as the data parameter pass v.getX(), v.getY(), and v.getZ() as the offset parameters instead

timber oak
#

Oh right

#

Aight no particles spawns lmao

#

Oh wait nvm, I need to loop it to do it multiple times

#

Ayeee it works

tranquil crane
#

can you record a gif or video so I can see it 👀

timber oak
#

Sure 🙂

#

Give me like 2 min lol

tranquil crane
#

If you want the particles to go a different distance just change what it gets multiplied by

timber oak
timber oak
#

Wait the clip doesnt work does it?

tranquil crane
#

no lol

timber oak
#

This should work

#

I'll just make the explosions a bit smaller

tranquil crane
#

oo pretty

timber oak
#

Yeah, 4th of July theme

#

Is what I was going for lol

#

Kinda annoying with no colors in explosion tho

tranquil crane
#

Looks like it lol

#

You might be able to get away with using an actual firework explosion using a small ball if you wanted to

timber oak
#

Yeah I'll try that, but for now this is great

#

Thank you very much for the help

tranquil crane
#

It looks really nice

#

Yeah np

obtuse gale
#

So what’s suppose to be the difference between dev general and development

static zealot
#

this is where developers talk about general stuff, not really just development I guess

#

its more of an off-topic

#

where development is where you get support/help

#

or give it

steel heart
#

Supposedly no support here

#

Just circlejerk and shit

timber oak
prisma wave
dusky drum
#

anyone has any good API for placing structures in world with plugin, like schematics from bukkit, but smaller objects like max 10x10x10?

distant sun
#

Fawe?

dusky drum
#

i dont want to have another dependency

#

not everyone has worldedit on server

#

and i dont want to force them to have it if they want to use my plugin

ocean quartz
#

Oooh Gasper long time no see

dusky drum
#

hellu Matt

#

trying to implement custom trees into my plugin and i cant find a good way to generating trees

onyx loom
#

theres something called RedLib (iirc) which u could try out

#

ill try get a link

dusky drum
onyx loom
#

yes

half harness
#

redlib is also a plugin dependency btw

dusky drum
#

ya just reading right now

#

i want some sort of api that i can just inject into my plugin

onyx loom
#

didnt realise it was in a plugin 😛

ocean quartz
#

Dammit Redempt why wouldn't make it a plugin 😩

half harness
#

¯_(ツ)_/¯

dusky drum
#

so no ideas, only way would be to make my own structure thingie i guess?

ocean quartz
#

It's MIT so i guess you can copy the part of code that handles that

dusky drum
#

ya i guess

half harness
#

wait if it's MIT do you have to credit them? if so how do u do it? since i thought u have to copy and paste the license header but redlib doesn't have them..

ocean quartz
lunar cypress
#

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

#

This means you put it in the file(s) you copy, for example

steel heart
#

bruh Fabric let me down for the first time

prisma wave
#

classic java

#

java might seem nice but it will always let you down

onyx loom
prisma wave
steel heart
prisma wave
#

what is fabric written in then HUH?

steel heart
#

you can refactor variable names and function names in haskell also?

#

or am I wrong?

prisma wave
#

probably

#

i dont rename things

#
a x = blah x

b = a -- a is "renamed" to b
#

ez

steel heart
#

oh god

#

totally couldn't do that in java

prisma wave
#
public void doSmthing(String x) { // bad, typo
    return x.hashCode(x.toString());
}

public void doSomething(String x) { return doSmthing(x); } // "refactored" to have a proper name, no code modifications necessary

how to refactor whilst adhering to the open closed principle

steel heart
#

well

#

java be popo no function first class object

#

(functional interfaces donot count)

prisma wave
#

it does

#

every variable is a first class identity function

steel heart
#

no

distant sun
#

void return

prisma wave
#
String s = "what";
s
steel heart
#

thats a pointer to the string

#

no?

prisma wave
#

and

#

so what

cinder flare
#

mmm reference variables

prisma wave
#

first class functions are a pointer to a functions

cinder flare
#

having a crush is just a pointer to them in your heart

steel heart
#

well its not a function ?

prisma wave
#

it can be seen as the identity function but it only works with 1 value

#

id 3 = 3

#

so 3 is the same as the function id 3

#

so 3 is a function

#

ish

#

not really

steel heart
#

Hello sir, allow me to agree to disagree but yeah

#

I guess

cinder flare
#

I mean that's literally mathematics

#

Technically anything can be represented as a function

prisma wave
#

i do not care about mathematics

#

exactly

#

strings are functions

#

ints are functions

cinder flare
#

It's the same with set theory, everything is a set

prisma wave
#

yes 😌

steel heart
#

god

prisma wave
#

see star gets it

cinder flare
#

ya I think math is cool

#

I'm just bad at applying it 😌

prisma wave
#

fun fact void and return are functions in haskell

steel heart
#

well from java point of view

#

it is not a function

cinder flare
#

Implementation detail

prisma wave
#

im not interested in "points of view"

steel heart
#

String x = "a"

prisma wave
#

i only care about facts

prisma wave
steel heart
#

okay sotp

#

stop

onyx loom
#

Veritasium 😌

cinder flare
#

woah there's a Veritasium video about set theory

#

I watched like a few hour long lectures about it

onyx loom
#

i dont think it was the whole video

#

but yes

prisma wave
#

looking forward to the veritasium video on profunctors

#

haha good one brister mitten

#

thanks

cinder flare
#

i think you forgot to swap to your alt there bro

prisma wave
#

what no

onyx loom
# cinder flare woah there's a Veritasium video about set theory

Not everything that is true can be proven. This discovery transformed infinity, changed the course of a world war and led to the modern computer. This video is sponsored by Brilliant. The first 200 people to sign up via https://brilliant.org/veritasium get 20% off a yearly subscription.

Special thanks to Prof. Asaf Karagila for consultation on...

▶ Play video
cinder flare
#

oh ya I watched taht

onyx loom
#

alan turing is also in here 😌

prisma wave
#

EWWWW

cinder flare
#

Did you know that in the Java specification, a method is executable code that can be invoked, passing a fixed number of values as arguments

prisma wave
#

varargs

#

arrays

cinder flare
#

So technically a String literal is executable code, that can be invoked, by passing itself as the argument

prisma wave
#

😌

cinder flare
#

I think varargs, at runtime, counts as a fixed number of arguments

prisma wave
#

yes in deed

cinder flare
#

The last formal parameter of a method or constructor is special: it may be a variable arity parameter, indicated by an ellipsis following the type.

#

Dude I need to read more of the Java spec

#

Look at how cool this shit is

#

I've never even heard of the word arity

prisma wave
#

theres some quite fancy type theory in there

#

arity just means like how many args it can take i think

#

recognise that from the clojure days

lunar cypress
#

yes

#

where do you think binary and ternary come from

cinder flare
#

uh I did not think it came from arity

prisma wave
#

carity

#

because i dont care

#

😎

cinder flare
lunar cypress
#

not smooth

cinder flare
#

bini

prisma wave
#

i dont care

cinder flare
#

so yeah not from arity lmao

#
"threefold," early 15c., from Late Latin ternarius "consisting of three," from terni "three by three," from ter "thrice," which is related to tres "three" (see three).```
lunar cypress
#

latin is a fake language that never existed

cinder flare
#

ah true true

prisma wave
#

^

cinder flare
#

they made it up like Klingon or something

frosty hill
#

sa

#

sa çet

cinder flare
#

Arity isn't even a word on this etymology site lmao

lunar cypress
#

dogru

frosty hill
#

türk var mı

cinder flare
#

what the fuck

prisma wave
frosty hill
#

I am Turkish

lunar cypress
#

evet KEKebab

onyx loom
#

hello kardes

prisma wave
frosty hill
#

johny

cinder flare
onyx loom
#

maybe

frosty hill
#

ay em törkiş

#

TÜRK

#

I AM TÜRK

#

Mustafa Kemal Atatürk

prisma wave
#

ISH

#

COME ON ENGERLAND

onyx loom
#

👍 👍 👍

cinder flare
#

MERICA

onyx loom
#

its coming home !!!

cinder flare
#

FUCK YEAH

frosty hill
#

come come Türk

#

FUCK

prisma wave
#

wrong

frosty hill
#

fuck you

#

brister fuck you

prisma wave
#

WTF

#

EZ btw

#

wasnt even close

frosty hill
#

1v1

#

COME

cinder flare
#

damn

frosty hill
#

COME

#

1V1

lunar cypress
static zealot
cinder flare
prisma wave