Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package elec0.luxcraft.entities;
- import elec0.luxcraft.tileentities.MirrorEntity;
- import net.minecraft.entity.Entity;
- import net.minecraft.nbt.NBTTagCompound;
- import net.minecraft.tileentity.TileEntity;
- import net.minecraft.world.World;
- public class BeamEntity extends Entity
- {
- public BeamEntity(World worldIn) {
- super(worldIn);
- this.isImmuneToFire = true;
- this.ignoreFrustumCheck = true;
- setSize(0.1F, 0.5F);
- }
- @Override
- public void onUpdate()
- {
- super.onUpdate();
- System.out.println("Beam entity update " + this.getUniqueID());
- if(!worldObj.isRemote)
- {
- TileEntity e = this.worldObj.getTileEntity(this.getPosition());
- if(e == null || !(e instanceof MirrorEntity))
- {
- System.out.println("No mirror below, dying.");
- setDead(); // If a mirror isn't below the entity, kill it
- }
- }
- }
- /*protected void entityInit() {
- }*/
- @Override
- public boolean canBeCollidedWith() {
- return false;
- }
- @Override
- protected void entityInit() {
- // TODO Auto-generated method stub
- }
- @Override
- protected void readEntityFromNBT(NBTTagCompound compound) {
- // TODO Auto-generated method stub
- }
- @Override
- protected void writeEntityToNBT(NBTTagCompound compound) {
- // TODO Auto-generated method stub
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement