#Particle Blending in Modern

76 messages · Page 1 of 1 (latest)

lilac otter
#

in 1.20.5, they removed the blending of the potion colors for particle effects that come off you when you have effects.

I'm trying to re-add this to modern mc (1.21.10+), and I think i found where the code changed. The issues is, its slightly different enough where idk what is what and how to reverse what.

#

I want to add this feature to my mod

#

the difference is in LivingEntity#tickEffects at the bottom

#

1.20.5+ vs 1.20.4

#

left is 1.20.5+, right is 1.20.4

#

maybe I should get the list and empty it and combine them all into a new particle type?

#

idk pls help

#

ParticleOptions seems to only be a interface w/ "getType" so uh idk

#

hmm it looks like a "ColorParticleOption" used to exist

old pagoda
#

The change was because some potions no longer use colored swirls, so you'll have to either exclude those or revert them to colored swirls

lilac otter
#

revert

#

trying to restore the old visual

fringe edge
lilac otter
#

lol

#

this actually might be simpler than im thinking

#

now looking into this

#

if im correct, all i gotta do is modify these

#

to restore original logic

#

yippe trol 😭

lilac otter
#

porting the old thing the best way I know how

#

even added back the effect id

#

im gonna need AMBIENT_ENTITY_EFFECT back 😭

lilac otter
#

so uh i had to readd/make my own particle cuz of the newer one missing what i needed

#

but like this is a copy paste from vanilla and i dont wanna get n trouble

#

idk what to do

fringe edge
#

That could be the wrong approach tho idk

lilac otter
#

i got the code ported/loading

#

but its giving stupid null error

fringe edge
lilac otter
#

this.sprites is null

#

somehow

#

in MutableSpriteSet

#

the spriteset given in ParticleProvider

#

Caused by: java.lang.NullPointerException: Cannot invoke "java.util.List.size()" because "this.sprites" is null

fringe edge
# lilac otter

Wherever you're calling AmbientMobProvider(sprites), your sprites is null

lilac otter
#

i dont call it

#

mc does

lilac otter
#

needed to define its sprites trol

fringe edge
#

Yay!

lilac otter
#

was able to minify the code so small

#

it uses the newer code

#

bruh

#

now it aint rendering

#

there was like 0 changes

fringe edge
lilac otter
#

the if state i have around it is being finicky

lilac otter
#

im starting to question if i need the ambient entity effect

#

if its just the alpha being 0.15 thonk

#

maybe i can use the normal entity effect

#

maybe thats why they removed it

#

considering theres this

#

which is ENTITY_EFFECT

#

particle = ColorParticleOption.create(ParticleTypes.ENTITY_EFFECT, ARGB.color(hasAmbience ? 0.15F : 1.0F, color));

#

BOOM SIMPLIFIED IT EVEN MORE

#

at this point, its perfect

#

rah

#

you dont understand

#

how happy i am rn

#

ive been trying to do this for over a year