1.12 conversion

This commit is contained in:
Corail31
2018-03-09 11:56:31 +01:00
parent edff82acca
commit 489fb82fbd
126 changed files with 1044 additions and 563 deletions
@@ -121,7 +121,7 @@ public class EntityBlackHole extends EntityMagicConstruct {
((EntityPlayerMP)target).connection.sendPacket(new SPacketEntityVelocity(target));
}
if(this.getDistanceToEntity(target) <= 2){
if(this.getDistance(target) <= 2){
// Damages the target if it is close enough
if(this.getCaster() != null){
target.attackEntityFrom(
@@ -74,7 +74,7 @@ public class EntityEarthquake extends EntityMagicConstruct {
for(EntityLivingBase target : targets){
// Searches in a 1 wide ring.
if(this.getDistanceToEntity(target) > (this.ticksExisted * speed) + 0.5 && target.posY < this.posY + 1
if(this.getDistance(target) > (this.ticksExisted * speed) + 0.5 && target.posY < this.posY + 1
&& target.posY > this.posY - 1){
// Knockback must be removed in this instance, or the target will fall into the floor.
@@ -3,7 +3,8 @@ package electroblob.wizardry.entity.construct;
import java.util.List;
import electroblob.wizardry.Wizardry;
import electroblob.wizardry.registry.WizardryAchievements;
import electroblob.wizardry.advancement.AdvancementHelper;
import electroblob.wizardry.advancement.AdvancementHelper.EnumAdvancement;
import electroblob.wizardry.registry.WizardrySounds;
import electroblob.wizardry.util.MagicDamage;
import electroblob.wizardry.util.MagicDamage.DamageType;
@@ -103,7 +104,7 @@ public class EntityTornado extends EntityMagicConstruct {
// The 'Not Again...' achievement
if(target instanceof EntityPig && WizardryUtilities.getRider(target) instanceof EntityPlayer){
((EntityPlayer)WizardryUtilities.getRider(target)).addStat(WizardryAchievements.pig_tornado);
AdvancementHelper.grantAdvancement((EntityPlayer)WizardryUtilities.getRider(target), EnumAdvancement.pig_tornado);
}
}
}