use of net.minecraft.entity.AreaEffectCloudEntity in project NetherEx by LogicTechCorp.
the class WorldHandler method onEntitySpawn.
@SubscribeEvent
public static void onEntitySpawn(EntityJoinWorldEvent event) {
World world = event.getWorld();
Entity entity = event.getEntity();
if (!world.isRemote()) {
if (entity instanceof AreaEffectCloudEntity) {
AreaEffectCloudEntity areaEffectCloudEntity = (AreaEffectCloudEntity) entity;
areaEffectCloudEntity.effects.removeIf(effect -> effect.getPotion() == NetherExEffects.FIRE_BURNING.get());
}
}
}
Aggregations