Run formatter

This commit is contained in:
Nicholas Ignoffo 2017-08-15 21:30:48 -07:00
parent 61c44a831b
commit 08258fd6ef
606 changed files with 13464 additions and 22975 deletions

View file

@ -9,20 +9,16 @@ import net.minecraft.util.EnumParticleTypes;
import net.minecraft.util.math.RayTraceResult;
import net.minecraft.world.World;
public class EntitySoulSnare extends EntityThrowable
{
public EntitySoulSnare(World worldIn)
{
public class EntitySoulSnare extends EntityThrowable {
public EntitySoulSnare(World worldIn) {
super(worldIn);
}
public EntitySoulSnare(World worldIn, EntityLivingBase throwerIn)
{
public EntitySoulSnare(World worldIn, EntityLivingBase throwerIn) {
super(worldIn, throwerIn);
}
public EntitySoulSnare(World worldIn, double x, double y, double z)
{
public EntitySoulSnare(World worldIn, double x, double y, double z) {
super(worldIn, x, y, z);
}
@ -30,30 +26,24 @@ public class EntitySoulSnare extends EntityThrowable
* Called when this EntityThrowable hits a block or entity.
*/
@Override
protected void onImpact(RayTraceResult result)
{
if (result.entityHit == this.getThrower() && this.ticksExisted < 20)
{
protected void onImpact(RayTraceResult result) {
if (result.entityHit == this.getThrower() && this.ticksExisted < 20) {
return;
}
if (result.entityHit != null && result.entityHit != this.getThrower())
{
if (result.entityHit instanceof EntityLivingBase && result.entityHit.getEntityWorld().rand.nextDouble() < 0.25)
{
if (result.entityHit != null && result.entityHit != this.getThrower()) {
if (result.entityHit instanceof EntityLivingBase && result.entityHit.getEntityWorld().rand.nextDouble() < 0.25) {
((EntityLivingBase) result.entityHit).addPotionEffect(new PotionEffect(RegistrarBloodMagic.SOUL_SNARE, 300, 0));
}
result.entityHit.attackEntityFrom(DamageSource.causeThrownDamage(this, this.getThrower()), (float) 0);
}
for (int j = 0; j < 8; ++j)
{
for (int j = 0; j < 8; ++j) {
this.getEntityWorld().spawnParticle(EnumParticleTypes.SNOWBALL, this.posX, this.posY, this.posZ, 0.0D, 0.0D, 0.0D);
}
if (!this.getEntityWorld().isRemote)
{
if (!this.getEntityWorld().isRemote) {
this.setDead();
}
}