diff options
Diffstat (limited to 'src/main/java/com/thatgravyboat/skyblockhud/api/sbentities')
3 files changed, 0 insertions, 90 deletions
diff --git a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeHelper.java b/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeHelper.java deleted file mode 100644 index 2d8a17e4b..000000000 --- a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeHelper.java +++ /dev/null @@ -1,36 +0,0 @@ -//package com.thatgravyboat.skyblockhud.api.sbentities; -// -//import com.thatgravyboat.skyblockhud.location.LocationHandler; -//import com.thatgravyboat.skyblockhud.location.Locations; -//import net.minecraft.entity.Entity; -//import net.minecraft.entity.monster.EntityEnderman; -//import net.minecraft.entity.monster.EntityZombie; -//import net.minecraft.init.Blocks; -//import net.minecraft.init.Items; -// -//public class EntityTypeHelper { -// -// public static boolean isZealot(Entity entity) { -// if (entity instanceof EntityEnderman) { -// EntityEnderman enderman = ((EntityEnderman) entity); -// double maxHealthBase = enderman.getAttributeMap().getAttributeInstanceByName("generic.maxHealth").getBaseValue(); -// if (maxHealthBase == 13000 || (maxHealthBase == 2000d && enderman.getHeldBlockState().getBlock().equals(Blocks.end_portal_frame))) { -// return LocationHandler.getCurrentLocation().equals(Locations.DRAGONSNEST); -// } -// } -// return false; -// } -// -// public static boolean isCrypt(Entity entity) { -// if (entity instanceof EntityZombie) { -// EntityZombie zombie = ((EntityZombie) entity); -// double maxHealthBase = zombie.getAttributeMap().getAttributeInstanceByName("generic.maxHealth").getBaseValue(); -// if (maxHealthBase != 2000d) return false; -// if (zombie.getEquipmentInSlot(0) == null || !zombie.getEquipmentInSlot(0).getItem().equals(Items.iron_sword)) return false; -// if (zombie.getEquipmentInSlot(1) == null || !zombie.getEquipmentInSlot(1).getItem().equals(Items.chainmail_boots)) return false; -// if (zombie.getEquipmentInSlot(2) == null || !zombie.getEquipmentInSlot(2).getItem().equals(Items.chainmail_leggings)) return false; -// return zombie.getEquipmentInSlot(3) != null && zombie.getEquipmentInSlot(3).getItem().equals(Items.chainmail_chestplate); -// } -// return false; -// } -//} diff --git a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeRegistry.java b/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeRegistry.java deleted file mode 100644 index d507eecfd..000000000 --- a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/EntityTypeRegistry.java +++ /dev/null @@ -1,27 +0,0 @@ -//package com.thatgravyboat.skyblockhud.api.sbentities; -// -//import com.google.common.collect.ImmutableList; -//import com.google.common.collect.Maps; -//import java.util.List; -//import java.util.Map; -//import net.minecraft.entity.Entity; -//import net.minecraft.entity.monster.EntityEnderman; -//import net.minecraft.entity.monster.EntityZombie; -// -//public class EntityTypeRegistry { -// -// private static final Map<Class<? extends Entity>, List<SkyBlockEntity>> entities = Maps.newHashMap(); -// -// static { -// entities.put(EntityEnderman.class, ImmutableList.of(SkyBlockEntity.of("ZEALOT", EntityTypeHelper::isZealot))); -// entities.put(EntityZombie.class, ImmutableList.of(SkyBlockEntity.of("CRYPT_GHOUL", EntityTypeHelper::isCrypt))); -// } -// -// public static String getEntityId(Entity entity) { -// if (!entities.containsKey(entity.getClass())) return null; -// for (SkyBlockEntity skyBlockEntity : entities.get(entity.getClass())) { -// if (skyBlockEntity.isEntity(entity)) return skyBlockEntity.getName(); -// } -// return null; -// } -//} diff --git a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/SkyBlockEntity.java b/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/SkyBlockEntity.java deleted file mode 100644 index bcd1196f5..000000000 --- a/src/main/java/com/thatgravyboat/skyblockhud/api/sbentities/SkyBlockEntity.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.thatgravyboat.skyblockhud.api.sbentities; - -import java.util.function.Predicate; -import net.minecraft.entity.Entity; - -public class SkyBlockEntity { - - private final String name; - private final Predicate<Entity> predicate; - - public static SkyBlockEntity of(String name, Predicate<Entity> predicate) { - return new SkyBlockEntity(name, predicate); - } - - private SkyBlockEntity(String name, Predicate<Entity> predicate) { - this.name = name; - this.predicate = predicate; - } - - public String getName() { - return name; - } - - public boolean isEntity(Entity entity) { - return predicate.test(entity); - } -} |