Why did that happen?

This commit is contained in:
TheBukor 2016-03-13 04:15:06 -03:00
parent 48685db4be
commit d83015f11a

View File

@ -175,7 +175,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -189,7 +189,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -240,7 +240,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -269,7 +269,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -285,7 +285,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -298,7 +298,18 @@ public class EffSetPathGoal extends Effect {
double spd = (meleeSpeed == null ? 1.0D : meleeSpeed.getSingle(e).doubleValue());
boolean memorize = (meleeMemorize == null ? false : meleeMemorize.getSingle(e));
Class<?> goalMeleeAttack = ReflectionUtils.getNMSClass("PathfinderGoalMeleeAttack");
newGoals.add(goalMeleeAttack.getConstructor(entCreature, double.class, boolean.class).newInstance(nmsEnt, spd, memorize));
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
className = "Living";
}
Class<?> nmsClass = ReflectionUtils.getNMSClass("Entity" + className);
newGoals.add(goalMeleeAttack.getConstructor(entCreature, Class.class, double.class, boolean.class).newInstance(nmsEnt, nmsClass, spd, memorize));
}
}
} else if (mark == 13) {
double spd = (moveTargetSpeed == null ? 1.0D : moveTargetSpeed.getSingle(e).doubleValue());
@ -313,7 +324,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -328,7 +339,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {
@ -439,7 +450,7 @@ public class EffSetPathGoal extends Effect {
for (EntityData<?> entData : types) {
if (!LivingEntity.class.isAssignableFrom(entData.getType()))
return;
String className = entData.getType().getSimpleName();
String className = entData.getType().getClass().getSimpleName();
if (className.equals("HumanEntity")) {
className = "Human";
} else if (className.equals("EntityLiving")) {