#Modifying the Ender dragon to be affected by potions (EntityJS)

7 messages · Page 1 of 1 (latest)

urban inlet
#

Hey, I'm trying to use EntityJS to modify the ender dragon so they can have potion effects applied to them like so,

EntityJSEvents.modifyEntity(event => {
    event.modify("minecraft:ender_dragon", modifyBuilder => {
        modifyBuilder.isAffectedByPotions(entity => true);
    })
})

however this doesn't seem to be changing anything. Any help?
entity => { return true; } also doesn't work

brisk jacinthBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

silk acorn
#

its probably because the ender dragon explicitly overrides this method in which case the modifyEntity event wont work on it hmmm the way they've overridden it makes it so the forge event onadded wont work either which is annoying

#

do you want it so splash potions effect it or are you trying to give it some effect through scripts because i think you can do entity.forceAddEffect(someeffect,entity) if its the latter

urban inlet
#

so ideally things like tipped arrows and modded weapons as well

silk acorn
#

yeah not sure about splash potions but for tipped arrows + other weapons you can try going through the EntityEvents.hurt and manually add the effect