package net.shadowfacts.enfusion.entity;

import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.projectile.EntityThrowable;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;
import net.shadowfacts.enfusion.EnFusion;
import net.shadowfacts.enfusion.config.Configurator;
import cpw.mods.fml.common.registry.EntityRegistry;

public class EntityLaserBolt extends EntityThrowable {
	
	public static void initialize() {
		EntityRegistry.registerModEntity(EntityLaserBolt.class, "LaserBolt", Configurator.laserBoltEntityId, EnFusion.instance, 120, 3, true);
	}

	public EntityLaserBolt(World par1World) {
		super(par1World);
		this.motionX *= 8;
		this.motionY *= 8;
		this.motionZ *= 8;
	}
	
	public EntityLaserBolt(World par1World, EntityLivingBase par2EntityLivingBase) {
		super(par1World, par2EntityLivingBase);
		this.motionX *= 8;
		this.motionY *= 8;
		this.motionZ *= 8;
	}
	
	public EntityLaserBolt(World par1World, double par2, double par4, double par6) {
		super(par1World, par2, par4, par6);
		this.motionX *= 8;
		this.motionY *= 8;
		this.motionZ *= 8;
	}

	@Override
	protected void onImpact(MovingObjectPosition movingobjectposition) {
		this.worldObj.createExplosion(this, this.posX, this.posY, this.posZ, (float)6, true);
		this.setDead();
	}
	
	@Override
	protected float getGravityVelocity() {
		return 0;
	}
}

@@ -1123,24 +1123,21 @@
 rride%0A%09p
-rotected
+ublic
  void on
@@ -1188,16 +1188,50 @@
 tion) %7B%0A
+%09%09if (!this.worldObj.isRemote) %7B%0A%09
 %09%09this.w
@@ -1300,16 +1300,17 @@
  (float)
+ 
 6, true)
@@ -1307,24 +1307,25 @@
 ) 6, true);%0A
+%09
 %09%09this.setDe
@@ -1330,16 +1330,20 @@
 Dead();%0A
+%09%09%7D%0A
 %09%7D%0A%09%0A%09@O
@@ -1356,16 +1356,13 @@
 e%0A%09p
-rotected
+ublic
  flo

Fix laser pistol creating explosion twice