Guest User

Entity Class Code

a guest
Sep 28th, 2014
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. package mymod.entity.EntityRifleBolt;
  2.  
  3. import net.minecraft.entity.EntityLivingBase;
  4. import net.minecraft.entity.projectile.EntityThrowable;
  5. import net.minecraft.util.MovingObjectPosition;
  6. import net.minecraft.world.World;
  7.  
  8. public class EntityRifleBolt extends EntityThrowable
  9. {
  10. private String texturePath = "mymod:";
  11. public EntityRifleBolt(World par1World)
  12. {
  13. super(par1World);
  14.  
  15. }
  16. public EntityRifleBolt(World par1World, EntityLivingBase par2EntityLivingBase)
  17. {
  18. super(par1World, par2EntityLivingBase);
  19. }
  20. public EntityRifleBolt(World par1World, double par2, double par4, double par6)
  21. {
  22. super(par1World, par2, par4, par6);
  23. }
  24. @Override
  25. protected void onImpact(MovingObjectPosition par1MovingObjectPosition)
  26. {
  27. this.worldObj.createExplosion(this, this.posX, this.posY, this.posZ, (float)1.0F, true);
  28. this.setDead();
  29. }
  30. protected float getGravityVelocity()
  31. {
  32. return 0.0F;
  33. }
  34. {
  35. }}
Advertisement
Add Comment
Please, Sign In to add comment