#Applying potion effects
29 messages · Page 1 of 1 (latest)
Here's what im trying to fix
import net.minecraft.potion.Potions; is already there
You got the important for StatusEffectInstance too? Also why the instanceof check? It's always true.
As far as I can find StatusEffectInstance isn't an import
unless its under something other than net.minecraft.potion
Ahh sorry I forgot to mention this is 1.21.3
in case that changes it
Alt+enter with the typing cursor over it should give you a list of options
!yc StausEffectInstance 1.21.3
Edit: lol didn't notice the spelling mistake
no matches for the given class name, MC version and query namespace
would you have any idea how to find this out and how I would change my code for this?
I'd expect it to be mentioned in the blog, but maybe it's just cuz there wasn't one for 1.20.3. I'd check for places where it would be used - maybe EffectCommand.
I can't figure this out haha
Im very much a beginner-- is there anywhere where I could find the syntax I need?
I know there are the changelogs but I don't want to go through every one recentely 😢
net.minecraft.entity.LivingEntity#addStatusEffect(net.minecraft.entity.effect.StatusEffectInstance) it's still there
did you properly import StatusEffectInstance?
do you know java?
not very well
fix that first. importing class is java 101. it's very important that you know the language basics
Fair