Jump to content

[1.10.2] Custom Doors metadata is not saved


Roxane

Recommended Posts

I'm trying to update my mod from 1.9 to 1.10.2 (forge version 12.16.1.1887 to 12.18.2.2098).

 

My Doors save all their information in metadata. When placing a new door it works fine, but after saving, quitting to title and reloading the world all metadata seems to be lost. I even tried to copy parts of my code into the vanilla doors code, but I get the same problem there...

 

It is NOT a problem of my doors having more than 16 possible values to store in their metadata. Each single door block only stores part of the combined data and gets the data it doesn't store itself from the blocks above or below it. That's the same as vanilla doors work.

 

This is the code of my BlockDoorOneByThree.java:

 

package net.roxa.tallDoors;

import java.util.Random;

import net.minecraft.block.Block;
import net.minecraft.block.BlockDoor;
import net.minecraft.block.SoundType;
import net.minecraft.block.material.EnumPushReaction;
import net.minecraft.block.material.Material;
import net.minecraft.block.properties.IProperty;
import net.minecraft.block.properties.PropertyBool;
import net.minecraft.block.properties.PropertyDirection;
import net.minecraft.block.properties.PropertyEnum;
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import net.minecraft.client.audio.SoundList;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import net.minecraft.init.SoundEvents;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.BlockRenderLayer;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.EnumHand;
import net.minecraft.util.IStringSerializable;
import net.minecraft.util.SoundCategory;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.RayTraceResult;
import net.minecraft.util.math.Vec3d;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.client.event.sound.SoundEvent;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;

public class BlockDoorOneByThree extends Block
{
    public static final PropertyDirection FACING = PropertyDirection.create("facing", EnumFacing.Plane.HORIZONTAL);
    public static final PropertyBool OPEN = PropertyBool.create("open");
    public static final PropertyEnum HINGE = PropertyEnum.create("hinge", BlockDoor.EnumHingePosition.class);
    public static final PropertyBool POWERED = PropertyBool.create("powered");
    public static final PropertyEnum HALF = PropertyEnum.create("half", BlockDoorOneByThree.EnumDoorHalf.class);
    
    protected BlockDoorOneByThree(Material materialIn, String material)
    {
        super(materialIn);
        
        this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH).withProperty(OPEN, Boolean.valueOf(false)).withProperty(HINGE, BlockDoor.EnumHingePosition.LEFT).withProperty(POWERED, Boolean.valueOf(false)).withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.LOWER));
        this.setHardness(2.0F);
    	this.setResistance(1F);
    	if (material.equals("oak")) this.setUnlocalizedName("blockDoorOneByThreeOak");
    	else if (material.equals("birch")) this.setUnlocalizedName("blockDoorOneByThreeBirch");
    	else if (material.equals("spruce")) this.setUnlocalizedName("blockDoorOneByThreeSpruce");
    	else if (material.equals("jungle")) this.setUnlocalizedName("blockDoorOneByThreeJungle");
    	else if (material.equals("acacia")) this.setUnlocalizedName("blockDoorOneByThreeAcacia");
    	else if (material.equals("darkOak")) this.setUnlocalizedName("blockDoorOneByThreeDarkOak");
    	else this.setUnlocalizedName("blockDoorOneByThreeIron");
        if (material.equals("oak")) this.setRegistryName("blockDoorOneByThreeOak");
    	else if (material.equals("birch")) this.setRegistryName("blockDoorOneByThreeBirch");
    	else if (material.equals("spruce")) this.setRegistryName("blockDoorOneByThreeSpruce");
    	else if (material.equals("jungle")) this.setRegistryName("blockDoorOneByThreeJungle");
    	else if (material.equals("acacia")) this.setRegistryName("blockDoorOneByThreeAcacia");
    	else if (material.equals("darkOak")) this.setRegistryName("blockDoorOneByThreeDarkOak");
    	else this.setRegistryName("blockDoorOneByThreeIron");
        if(this.getDoorMaterial().equals("iron")) this.setSoundType(SoundType.METAL);
    	else this.setSoundType(SoundType.WOOD);
        
    }
    
    @Override
    public boolean isOpaqueCube(IBlockState state)
    {
        return false;
    }

    @Override
    public boolean isPassable(IBlockAccess worldIn, BlockPos pos)
    {
        return isOpen(combineMetadata(worldIn, pos));
    }

    @Override
    public boolean isFullCube(IBlockState state)
    {
        return false;
    }

    @SideOnly(Side.CLIENT)
    @Override
    public AxisAlignedBB getSelectedBoundingBox(IBlockState state, World worldIn, BlockPos pos)
    {
    	this.getBoundingBox(state, worldIn, pos);
        return super.getSelectedBoundingBox(state, worldIn, pos);
    }

    @Override
    public AxisAlignedBB getCollisionBoundingBox(IBlockState state, World worldIn, BlockPos pos)
    {
        this.getBoundingBox(state, worldIn, pos);
        return super.getCollisionBoundingBox(state, worldIn, pos);
    }
    
    @Override
    //public void setBlockBoundsBasedOnState(IBlockAccess worldIn, BlockPos pos)
    public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess source, BlockPos pos)
    {
        return this.setBoundBasedOnMeta(combineMetadata(source, pos));
    }

    private AxisAlignedBB setBoundBasedOnMeta(int combinedMeta)
    {
        float f = 0.1875F;
        AxisAlignedBB axis;
        axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, 1.0F, 2.0F, 1.0F);
        EnumFacing enumfacing = getFacing(combinedMeta);
        boolean open = isOpen(combinedMeta);
        boolean left = isHingeLeft(combinedMeta);

        if (open)
        {
            if (enumfacing == EnumFacing.EAST)
            {
                if (!left)
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, f);
                }
                else
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 1.0F - f, 1.0F, 1.0F, 1.0F);
                }
            }
            else if (enumfacing == EnumFacing.SOUTH)
            {
                if (!left)
                {
                	axis = new AxisAlignedBB(1.0F - f, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
                }
                else
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, f, 1.0F, 1.0F);
                }
            }
            else if (enumfacing == EnumFacing.WEST)
            {
                if (!left)
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 1.0F - f, 1.0F, 1.0F, 1.0F);
                }
                else
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, f);
                }
            }
            else if (enumfacing == EnumFacing.NORTH)
            {
                if (!left)
                {
                	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, f, 1.0F, 1.0F);
                }
                else
                {
                	axis = new AxisAlignedBB(1.0F - f, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
                }
            }
        }
        else if (enumfacing == EnumFacing.EAST)
        {
        	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, f, 1.0F, 1.0F);
        }
        else if (enumfacing == EnumFacing.SOUTH)
        {
        	axis = new AxisAlignedBB(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, f);
        }
        else if (enumfacing == EnumFacing.WEST)
        {
        	axis = new AxisAlignedBB(1.0F - f, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
        }
        else if (enumfacing == EnumFacing.NORTH)
        {
        	axis = new AxisAlignedBB(0.0F, 0.0F, 1.0F - f, 1.0F, 1.0F, 1.0F);
        }
        return axis;
    }
    
    @Override
    public boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, EnumHand hand, ItemStack heldItem, EnumFacing side, float hitX, float hitY, float hitZ)
    {
    	return this.toggleDoor(worldIn, pos, state, playerIn, false);
    }
    
    public boolean toggleDoor(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, boolean powered)
    {
    	boolean returnValue = false;
    	/*
    	if (this.blockMaterial == Material.iron && powered == false)
        {
            return returnValue; //Allow items to interact with the door
        }
        */
        if (this.blockMaterial != Material.IRON || powered)
        {
        	boolean openNew;
        	IBlockState fullState = this.getActualState(state, worldIn, pos);
            BlockPos blockposLower;
            if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER) blockposLower = pos;
            else if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE) blockposLower = pos.down();
            else blockposLower = pos.down(2);
            
            IBlockState stateLower = pos.equals(blockposLower) ? state : worldIn.getBlockState(blockposLower);
            
            if (stateLower.getBlock() == this)
            {
            	openNew = (Boolean)stateLower.getValue(OPEN);
                openNew = openNew ? false : true;
                
            	worldIn.setBlockState(blockposLower, stateLower.withProperty(OPEN, openNew), 2);
    			worldIn.markBlockRangeForRenderUpdate(blockposLower, pos);
                //worldIn.playAuxSFXAtEntity(playerIn, 1003, pos, 0);
    			//worldIn.playAuxSFXAtEntity(playerIn, ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getSoundOpen() : this.getSoundOpen(), pos, 0);
    			worldIn.playSound(playerIn, (double)pos.getX(), (double)pos.getY(), (double)pos.getZ(), ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getSoundOpen() : this.getSoundOpen(), SoundCategory.BLOCKS, 1.0F, 1.0F);
    			returnValue = true;
            }
        }
        return returnValue;
    }
    
    @Override
    public void neighborChanged(IBlockState state, World worldIn, BlockPos pos, Block neighborBlock)
    {
    	BlockPos blockposLower = pos;
    	BlockPos blockposMiddle = pos;
        BlockPos blockposUpper = pos;
        
        if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        {
        	blockposMiddle = pos.up();
        	blockposUpper = pos.up(2);
        }
        else if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
        {
        	blockposLower = pos.down();
        	blockposUpper = pos.up();
        }
        else
        {
        	blockposLower = pos.down(2);
        	blockposMiddle = pos.down();
        }
        
        IBlockState iblockstateLower = worldIn.getBlockState(blockposLower);
        IBlockState iblockstateMiddle = worldIn.getBlockState(blockposMiddle);
        IBlockState iblockstateUpper = worldIn.getBlockState(blockposUpper);
        
        boolean destroyed = false;
        boolean dropItem = false;
        boolean links = false;
        boolean offen = false;
        EnumFacing facing = null;
        
    	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        {
    		if (iblockstateMiddle.getBlock() != this) //Wenn Mitte keine Tür ist
            {
            	if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper); //Wenn oberer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos); 
                destroyed = true;
            }
            
            if (iblockstateUpper.getBlock() != this) //Wenn Oben keine Tür ist
            {
            	if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle); //Wenn mittlerer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos); 
                destroyed = true;
            }

            if (!worldIn.getBlockState(pos.down()).isFullyOpaque()) //wenn drunter kein solider Block ist
            {
                worldIn.setBlockToAir(pos);
                destroyed = true;

                if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle);//Wenn mittlerer Block Tür => Block entfernen
                if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper);//Wenn oberer Block Tür => Block entfernen
                
                dropItem = true;
            }
            
            if (!destroyed)
            {
            	boolean powered = worldIn.isBlockPowered(pos) || worldIn.isBlockPowered(blockposMiddle) || worldIn.isBlockPowered(blockposUpper);
            	
            	if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)iblockstateUpper.getValue(POWERED)).booleanValue())
            	{
            		worldIn.setBlockState(blockposUpper, iblockstateUpper.withProperty(POWERED, Boolean.valueOf(powered)), 2);

                    if (powered != ((Boolean)state.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
        }
        else if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
        {
        	if (iblockstateLower.getBlock() != this) //Wenn unten keine Tür ist
            {
            	if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper); //Wenn oberer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (iblockstateUpper.getBlock() != this) //Wenn oben keine Tür ist
            {
            	worldIn.setBlockToAir(pos);
            }
        	
            else if (!destroyed)
            {
            	boolean powered = worldIn.isBlockPowered(blockposLower) || worldIn.isBlockPowered(pos) || worldIn.isBlockPowered(blockposUpper);
            	if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)iblockstateUpper.getValue(POWERED)).booleanValue())
                {
                	worldIn.setBlockState(blockposUpper, iblockstateUpper.withProperty(POWERED, Boolean.valueOf(powered)), 2);
                	if (powered != ((Boolean)iblockstateLower.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
            
        }
        else //UPPER
        {
        	if (iblockstateLower.getBlock() != this) //Wenn unten keine Tür ist
            {
            	if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle); //Wenn mittlerer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (iblockstateMiddle.getBlock() != this) //Wenn mitte keine Tür ist
            {
            	if (iblockstateLower.getBlock() == this) worldIn.setBlockToAir(blockposLower); //Wenn unterer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (neighborBlock != this)
            {
                this.neighborChanged(iblockstateMiddle,worldIn, blockposMiddle,  neighborBlock);
                this.neighborChanged(iblockstateLower, worldIn, blockposLower, neighborBlock);
            }
            else if (!destroyed)
            {
                boolean powered = worldIn.isBlockPowered(blockposLower) || worldIn.isBlockPowered(blockposMiddle) || worldIn.isBlockPowered(pos);

                if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)state.getValue(POWERED)).booleanValue())
                {
                    worldIn.setBlockState(pos, state.withProperty(POWERED, Boolean.valueOf(powered)), 2);

                    if (powered != ((Boolean)state.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
        }
    	if (!worldIn.isRemote && dropItem) this.dropBlockAsItem(worldIn, pos, state, 0);
    }
    
    @Override
    public Item getItemDropped(IBlockState state, Random rand, int fortune)
    {
        return this.getItem();
    }

    @Override
    public RayTraceResult collisionRayTrace(IBlockState state, World worldIn, BlockPos pos, Vec3d start, Vec3d end)
    {
    	this.getBoundingBox(state, worldIn, pos);
        return super.collisionRayTrace(state, worldIn, pos, start, end);
    }

    @Override
    public boolean canPlaceBlockAt(World worldIn, BlockPos pos)
    {
        return pos.getY() >= worldIn.getHeight() - 1 ? false : worldIn.getBlockState(pos.down()).isSideSolid(worldIn,  pos.down(), EnumFacing.UP) && super.canPlaceBlockAt(worldIn, pos) && super.canPlaceBlockAt(worldIn, pos.up()) && super.canPlaceBlockAt(worldIn, pos.up(2));
    }

    @Override
    public EnumPushReaction getMobilityFlag(IBlockState state)
    {
        return EnumPushReaction.DESTROY;
    }

    public static int combineMetadata(IBlockAccess worldIn, BlockPos pos)
    {
    	int combinedMeta = 0;
        IBlockState iblockstate = worldIn.getBlockState(pos);
        int metaThis = iblockstate.getBlock().getMetaFromState(iblockstate);
        int metaLower = 0;
        int metaMiddle = 0;
        int metaUpper = 0;
        if ((metaThis &  == 0) //unterer Teil
        {
        	metaLower = metaThis;
        	IBlockState iblockstateMiddle = worldIn.getBlockState(pos.up());
        	metaMiddle = iblockstateMiddle.getBlock().getMetaFromState(iblockstateMiddle);
        	IBlockState iblockstateUpper = worldIn.getBlockState(pos.up(2));
        	metaUpper = iblockstateUpper.getBlock().getMetaFromState(iblockstateUpper);
        }
        else if ((metaThis & 4) == 0)
        {
        	metaMiddle = metaThis;
        	IBlockState iblockstateLower = worldIn.getBlockState(pos.down());
        	metaLower = iblockstateLower.getBlock().getMetaFromState(iblockstateLower);
        	IBlockState iblockstateUpper = worldIn.getBlockState(pos.up());
        	metaUpper = iblockstateUpper.getBlock().getMetaFromState(iblockstateUpper);
        }
        else
        {
        	metaUpper = metaThis;
        	IBlockState iblockstateLower = worldIn.getBlockState(pos.down(2));
        	metaLower = iblockstateLower.getBlock().getMetaFromState(iblockstateLower);
        	IBlockState iblockstateMiddle = worldIn.getBlockState(pos.down());
        	metaMiddle = iblockstateMiddle.getBlock().getMetaFromState(iblockstateMiddle);
        }
        
        int facing = (metaLower & 3);
        boolean open = (metaLower & 4) != 0;
        boolean upperHalf = (metaThis &  != 0;
        boolean middle = (metaThis &  != 0 && (metaThis & 4) == 0;
        boolean right = (metaMiddle & 1) != 0;
        boolean power = (metaUpper & 1) != 0;
        
        combinedMeta = facing | (open ? 4 : 0) | (upperHalf ? 8 : 0) | (middle ? 16 : 0) | (right ? 32 : 0) | (power ? 64 : 0);// | (distal ? 128 : 0);
        
        return combinedMeta;
    }

    @Override
    public ItemStack getItem(World worldIn, BlockPos pos, IBlockState state)
    {
        return new ItemStack(this.getItem());
    }

    private Item getItem()
    {
    	Item item;
    	if (getDoorMaterial().equals("oak")) item = RoxaTallDoorsMod.itemDoorOneByThreeOak;
    	else if (getDoorMaterial().equals("birch")) item = RoxaTallDoorsMod.itemDoorOneByThreeBirch;
    	else if (getDoorMaterial().equals("spruce")) item = RoxaTallDoorsMod.itemDoorOneByThreeSpruce;
    	else if (getDoorMaterial().equals("jungle")) item = RoxaTallDoorsMod.itemDoorOneByThreeJungle;
    	else if (getDoorMaterial().equals("acacia")) item = RoxaTallDoorsMod.itemDoorOneByThreeAcacia;
    	else if (getDoorMaterial().equals("darkOak")) item = RoxaTallDoorsMod.itemDoorOneByThreeDarkOak;
    	else item = RoxaTallDoorsMod.itemDoorOneByThreeIron;    	
        return item;
    }
    
    @Override
    public void onBlockHarvested(World worldIn, BlockPos pos, IBlockState state, EntityPlayer player)
    {
        BlockPos blockposDown = pos.down();
        BlockPos blockposDown2 = pos.down(2);
        BlockPos blockposUp = pos.up();
        BlockPos blockposUp2 = pos.up(2);

        if (player.capabilities.isCreativeMode)
        {
        	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.UPPER)
        	{
        		if(worldIn.getBlockState(blockposDown2).getBlock() == this) worldIn.setBlockToAir(blockposDown2);
        		if(worldIn.getBlockState(blockposDown).getBlock() == this) worldIn.setBlockToAir(blockposDown);
        	}
        	
        	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
        	{
        		if(worldIn.getBlockState(blockposDown).getBlock() == this) worldIn.setBlockToAir(blockposDown);
        		if(worldIn.getBlockState(blockposUp).getBlock() == this) worldIn.setBlockToAir(blockposUp);
        	}
        	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        	{
        		if(worldIn.getBlockState(blockposUp).getBlock() == this) worldIn.setBlockToAir(blockposUp);
        		if(worldIn.getBlockState(blockposUp2).getBlock() == this) worldIn.setBlockToAir(blockposUp2);
        	}
        }
    }
    
    @Override
    public IBlockState getActualState(IBlockState state, IBlockAccess worldIn, BlockPos pos)
    {
        IBlockState iblockstateLower;
        IBlockState iblockstateMiddle;
        IBlockState iblockstateUpper;

        if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        {
        	iblockstateMiddle = worldIn.getBlockState(pos.up());
        	iblockstateUpper = worldIn.getBlockState(pos.up(2));
            
            if (iblockstateMiddle.getBlock() == this)
            {
                state = state.withProperty(HINGE, iblockstateMiddle.getValue(HINGE));
                //state = state.withProperty(DISTAL, iblockstateMiddle.getValue(DISTAL));
            }
            if (iblockstateUpper.getBlock() == this)
            {
                state = state.withProperty(POWERED, iblockstateUpper.getValue(POWERED));
            }
        }
        else if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
        {
        	iblockstateUpper = worldIn.getBlockState(pos.up());
        	iblockstateLower = worldIn.getBlockState(pos.down());
        	
            if (iblockstateLower.getBlock() == this)
            {
                state = state.withProperty(OPEN, iblockstateLower.getValue(OPEN));
                state = state.withProperty(FACING, iblockstateLower.getValue(FACING));
            }
            if (iblockstateUpper.getBlock() == this)
            {
                state = state.withProperty(POWERED, iblockstateUpper.getValue(POWERED));
            }
        }
        else //HALF == UPPER
        {
        	iblockstateMiddle = worldIn.getBlockState(pos.down());
        	iblockstateLower = worldIn.getBlockState(pos.down(2));
        	
            if (iblockstateLower.getBlock() == this)
            {
                state = state.withProperty(OPEN, iblockstateLower.getValue(OPEN));
                state = state.withProperty(FACING, iblockstateLower.getValue(FACING));
            }
            if (iblockstateMiddle.getBlock() == this)
            {
                state = state.withProperty(HINGE, iblockstateMiddle.getValue(HINGE));
                //state = state.withProperty(DISTAL, iblockstateMiddle.getValue(DISTAL));
            }
        }

        return state;
    }
    
    public IBlockState getStateFromCombinedMeta(int combinedMeta)
    {
    	IBlockState state = this.getDefaultState();
    	
        state.withProperty(FACING, EnumFacing.getHorizontal(combinedMeta & 3).rotateYCCW());
        state.withProperty(OPEN, Boolean.valueOf((combinedMeta & 4) > 0));
        if ((combinedMeta &  == 0 && (combinedMeta & 16) == 0) state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.LOWER);
        //if ((combinedMeta &  == 0 && (combinedMeta & 16) != 0) state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.LOWERMIDDLE);
        if ((combinedMeta &  != 0 && (combinedMeta & 16) == 0) state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.UPPER);
        if ((combinedMeta &  != 0 && (combinedMeta & 16) != 0) state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.MIDDLE);//UPPERMIDDLE
        state.withProperty(HINGE, ((combinedMeta & 32) > 0 ? BlockDoor.EnumHingePosition.RIGHT : BlockDoor.EnumHingePosition.LEFT));
        state.withProperty(POWERED, Boolean.valueOf((combinedMeta & 64) > 0));
        //state.withProperty(DISTAL, Boolean.valueOf((combinedMeta & 128) > 0));
        
        return state;
    }
    
    @Override
    public IBlockState getStateFromMeta(int meta)
    {
    	IBlockState state = this.getDefaultState();
    	
        if ((meta &  == 0) //Unten
        {
        	state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.LOWER);
        	state.withProperty(FACING, EnumFacing.getHorizontal(meta & 3).rotateYCCW());
        	state.withProperty(OPEN, Boolean.valueOf((meta & 4) > 0));
        }
        else //Oberer Teil
        {
        	if ((meta & 4) == 0) //Mitte
        	{
        		state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.MIDDLE);
        		state.withProperty(HINGE, (meta & 1) > 0 ? BlockDoor.EnumHingePosition.RIGHT : BlockDoor.EnumHingePosition.LEFT);
        		//state.withProperty(DISTAL, Boolean.valueOf((meta & 2) > 0));
        	}
        	else //Oben
        	{
        		//Bei 4 hohen Rüren kommt hier noch die Unterscheidung zw. UPPER und UPPERMIDDLE
        		state.withProperty(HALF, BlockDoorOneByThree.EnumDoorHalf.UPPER);
        		state.withProperty(POWERED, Boolean.valueOf((meta & 1) > 0));
        	}
        }
        return state;
    }
    
    @SideOnly(Side.CLIENT)
    @Override
    public BlockRenderLayer getBlockLayer()
    {
        return BlockRenderLayer.CUTOUT;
    }

    @Override
    public int getMetaFromState(IBlockState state)
    {
        byte b0 = 0;
        int i;

        if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        {
            i = b0 | ((EnumFacing)state.getValue(FACING)).rotateY().getHorizontalIndex();

            if (((Boolean)state.getValue(OPEN)).booleanValue())
            {
                i |= 4;
            }
        }
        else
        {
        	i = b0 | 8;
        	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
            {
        		/*if (((Boolean)state.getValue(DISTAL)).booleanValue())
                {
                    i |= 2;
                }*/
                if (state.getValue(HINGE) == BlockDoor.EnumHingePosition.RIGHT)
                {
                    i |= 1;
                }
            }
        	else
        	{
        		i |= 4;
        		/* Noch Freie Variable
                if (((Boolean)state.getValue(FREI)).booleanValue())
                {
                    i |= 2;
                }
                */
        		if (((Boolean)state.getValue(POWERED)).booleanValue())
                {
                    i |= 1;
                }
        	}
        }

        return i;
    }

    public static boolean isOpen(IBlockAccess worldIn, BlockPos pos)
    {
        return isOpen(combineMetadata(worldIn, pos));
    }

    protected static boolean isOpen(int combinedMeta)
    {
        return (combinedMeta & 4) != 0;
    }

    public static EnumFacing getFacing(IBlockAccess worldIn, BlockPos pos)
    {
        return getFacing(combineMetadata(worldIn, pos));
    }

    public static EnumFacing getFacing(int combinedMeta)
    {
        return EnumFacing.getHorizontal(combinedMeta & 3).rotateYCCW();
    }

    protected static boolean isLower(int meta)
    {
        return (meta &  == 0;
    }

    protected static boolean isHingeLeft(int combinedMeta)
    {
        return (combinedMeta & 32) != 0;
    }

    @Override
    protected BlockStateContainer createBlockState()
    {
        return new BlockStateContainer(this, new IProperty[] {HALF, FACING, OPEN, HINGE, POWERED});
    }

    public static enum EnumDoorHalf implements IStringSerializable
    {
        UPPER,
        MIDDLE,
        LOWER;
        
        public String toString()
        {
            return this.getName();
        }

        public String getName()
        {
        	String name;
        	if (this == UPPER) name = "upper";
        	else if (this == MIDDLE) name = "middle";
        	else name = "lower";
            return name;
        }
    }
    
    public String getDoorMaterial()
    {
    	String material;
    	if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeOak")) material = "oak";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeBirch")) material = "birch";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeSpruce")) material = "spruce";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeJungle")) material = "jungle";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeAcacia")) material = "acacia";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeDarkOak")) material = "darkOak";
    	else material = "iron";
    	
    	return material;
    }
    
    private net.minecraft.util.SoundEvent getSoundClose()
    {
        return this.blockMaterial == Material.IRON ? SoundEvents.BLOCK_IRON_DOOR_CLOSE : SoundEvents.BLOCK_WOODEN_DOOR_CLOSE;
    }
    
    private net.minecraft.util.SoundEvent getSoundOpen()
    {
        return this.blockMaterial == Material.IRON ? SoundEvents.BLOCK_IRON_DOOR_OPEN : SoundEvents.BLOCK_WOODEN_DOOR_OPEN;
    }
}

 

This is the BlockDoorOneByThree.java where I copied my code fragments into the vanilla door:

 

package net.roxa.tallDoors;

import java.util.Random;

import javax.annotation.Nullable;

import net.minecraft.block.Block;
import net.minecraft.block.BlockDoor;
import net.minecraft.block.BlockHorizontal;
import net.minecraft.block.BlockPlanks;
import net.minecraft.block.SoundType;
import net.minecraft.block.material.EnumPushReaction;
import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
import net.minecraft.block.properties.IProperty;
import net.minecraft.block.properties.PropertyBool;
import net.minecraft.block.properties.PropertyDirection;
import net.minecraft.block.properties.PropertyEnum;
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.BlockRenderLayer;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.EnumHand;
import net.minecraft.util.IStringSerializable;
import net.minecraft.util.Mirror;
import net.minecraft.util.Rotation;
import net.minecraft.util.SoundCategory;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.text.translation.I18n;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;

public class BlockDoorOneByThreeCopiedIntoVanillaDoor extends Block
{
    public static final PropertyDirection FACING = BlockHorizontal.FACING;
    public static final PropertyBool OPEN = PropertyBool.create("open");
    public static final PropertyEnum<BlockDoor.EnumHingePosition> HINGE = PropertyEnum.<BlockDoor.EnumHingePosition>create("hinge", BlockDoor.EnumHingePosition.class);
    public static final PropertyBool POWERED = PropertyBool.create("powered");
    public static final PropertyEnum<BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf> HALF = PropertyEnum.<BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf>create("half", BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.class);
    protected static final AxisAlignedBB SOUTH_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 0.1875D);
    protected static final AxisAlignedBB NORTH_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.8125D, 1.0D, 1.0D, 1.0D);
    protected static final AxisAlignedBB WEST_AABB = new AxisAlignedBB(0.8125D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D);
    protected static final AxisAlignedBB EAST_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 0.1875D, 1.0D, 1.0D);

    protected BlockDoorOneByThreeCopiedIntoVanillaDoor(Material materialIn, String material)
    {
        super(materialIn);
        this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH).withProperty(OPEN, Boolean.valueOf(false)).withProperty(HINGE, BlockDoor.EnumHingePosition.LEFT).withProperty(POWERED, Boolean.valueOf(false)).withProperty(HALF, BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER));
        this.setHardness(2.0F);
    	this.setResistance(1F);
    	if (material.equals("oak")) this.setUnlocalizedName("blockDoorOneByThreeOak");
    	else if (material.equals("birch")) this.setUnlocalizedName("blockDoorOneByThreeBirch");
    	else if (material.equals("spruce")) this.setUnlocalizedName("blockDoorOneByThreeSpruce");
    	else if (material.equals("jungle")) this.setUnlocalizedName("blockDoorOneByThreeJungle");
    	else if (material.equals("acacia")) this.setUnlocalizedName("blockDoorOneByThreeAcacia");
    	else if (material.equals("darkOak")) this.setUnlocalizedName("blockDoorOneByThreeDarkOak");
    	else this.setUnlocalizedName("blockDoorOneByThreeIron");
        if (material.equals("oak")) this.setRegistryName("blockDoorOneByThreeOak");
    	else if (material.equals("birch")) this.setRegistryName("blockDoorOneByThreeBirch");
    	else if (material.equals("spruce")) this.setRegistryName("blockDoorOneByThreeSpruce");
    	else if (material.equals("jungle")) this.setRegistryName("blockDoorOneByThreeJungle");
    	else if (material.equals("acacia")) this.setRegistryName("blockDoorOneByThreeAcacia");
    	else if (material.equals("darkOak")) this.setRegistryName("blockDoorOneByThreeDarkOak");
    	else this.setRegistryName("blockDoorOneByThreeIron");
        if(this.getDoorMaterial().equals("iron")) this.setSoundType(SoundType.METAL);
    	else this.setSoundType(SoundType.WOOD);
    }
    
    @Override
    public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess source, BlockPos pos)
    {
        state = state.getActualState(source, pos);
        EnumFacing enumfacing = (EnumFacing)state.getValue(FACING);
        boolean flag = !((Boolean)state.getValue(OPEN)).booleanValue();
        boolean flag1 = state.getValue(HINGE) == BlockDoor.EnumHingePosition.RIGHT;

        switch (enumfacing)
        {
            case EAST:
            default:
                return flag ? EAST_AABB : (flag1 ? NORTH_AABB : SOUTH_AABB);
            case SOUTH:
                return flag ? SOUTH_AABB : (flag1 ? EAST_AABB : WEST_AABB);
            case WEST:
                return flag ? WEST_AABB : (flag1 ? SOUTH_AABB : NORTH_AABB);
            case NORTH:
                return flag ? NORTH_AABB : (flag1 ? WEST_AABB : EAST_AABB);
        }
    }

    /**
     * Gets the localized name of this block. Used for the statistics page.
     */
    @Override
    public String getLocalizedName()
    {
        return I18n.translateToLocal((this.getUnlocalizedName() + ".name").replaceAll("tile", "item"));
    }

    /**
     * Used to determine ambient occlusion and culling when rebuilding chunks for render
     */
    @Override
    public boolean isOpaqueCube(IBlockState state)
    {
        return false;
    }
    
    @Override
    public boolean isPassable(IBlockAccess worldIn, BlockPos pos)
    {
        return isOpen(combineMetadata(worldIn, pos));
    }
    
    @Override
    public boolean isFullCube(IBlockState state)
    {
        return false;
    }
    private int getCloseSound()
    {
        return this.blockMaterial == Material.IRON ? 1011 : 1012;
    }

    private int getOpenSound()
    {
        return this.blockMaterial == Material.IRON ? 1005 : 1006;
    }

    /**
     * Get the MapColor for this Block and the given BlockState
     */
    @Override
    public MapColor getMapColor(IBlockState state)
    {
    	String material = this.getDoorMaterial();
        return material.equals("iron") ? MapColor.IRON : (material.equals("oak") ? BlockPlanks.EnumType.OAK.getMapColor() : (material.equals("spruce") ? BlockPlanks.EnumType.SPRUCE.getMapColor() : (material.equals("birch") ? BlockPlanks.EnumType.BIRCH.getMapColor() : (material.equals("jungle") ? BlockPlanks.EnumType.JUNGLE.getMapColor() : (material.equals("acacia") ? BlockPlanks.EnumType.ACACIA.getMapColor() : (material.equals("darkOak") ? BlockPlanks.EnumType.DARK_OAK.getMapColor() : super.getMapColor(state)))))));
    }
    
    @Override
    public boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, EnumHand hand, @Nullable ItemStack heldItem, EnumFacing side, float hitX, float hitY, float hitZ)
    {
    	/* Original Door 1.10
        if (this.blockMaterial == Material.IRON)
        {
            return false; //Allow items to interact with the door
        }
        else
        {
            BlockPos blockpos = state.getValue(HALF) == BlockDoor.EnumDoorHalf.LOWER ? pos : pos.down();
            IBlockState iblockstate = pos.equals(blockpos) ? state : worldIn.getBlockState(blockpos);

            if (iblockstate.getBlock() != this)
            {
                return false;
            }
            else
            {
                state = iblockstate.cycleProperty(OPEN);
                worldIn.setBlockState(blockpos, state, 10);
                worldIn.markBlockRangeForRenderUpdate(blockpos, pos);
                worldIn.playEvent(playerIn, ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getOpenSound() : this.getCloseSound(), pos, 0);
                return true;
            }
        }*/
    	return this.toggleDoor(worldIn, pos, state, playerIn, false);
    }
    
    public boolean toggleDoor(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, boolean powered)
    {
    	/* Original Door 1.10
    	public void toggleDoor(World worldIn, BlockPos pos, boolean open){
        IBlockState iblockstate = worldIn.getBlockState(pos);

        if (iblockstate.getBlock() == this)
        {
            BlockPos blockpos = iblockstate.getValue(HALF) == BlockDoor.EnumDoorHalf.LOWER ? pos : pos.down();
            IBlockState iblockstate1 = pos == blockpos ? iblockstate : worldIn.getBlockState(blockpos);

            if (iblockstate1.getBlock() == this && ((Boolean)iblockstate1.getValue(OPEN)).booleanValue() != open)
            {
                worldIn.setBlockState(blockpos, iblockstate1.withProperty(OPEN, Boolean.valueOf(open)), 10);
                worldIn.markBlockRangeForRenderUpdate(blockpos, pos);
                worldIn.playEvent((EntityPlayer)null, open ? this.getOpenSound() : this.getCloseSound(), pos, 0);
            }
        }
        */
    	boolean returnValue = false;
    	/*
    	if (this.blockMaterial == Material.iron && powered == false)
        {
            return returnValue; //Allow items to interact with the door
        }
        */
        if (this.blockMaterial != Material.IRON || powered)
        {
        	boolean openNew;
        	IBlockState fullState = this.getActualState(state, worldIn, pos);
            BlockPos blockposLower;
            if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER) blockposLower = pos;
            else if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE) blockposLower = pos.down();
            else blockposLower = pos.down(2);
            
            IBlockState stateLower = pos.equals(blockposLower) ? state : worldIn.getBlockState(blockposLower);
            
            if (stateLower.getBlock() == this)
            {
            	openNew = (Boolean)stateLower.getValue(OPEN);
                openNew = openNew ? false : true;
                
            	worldIn.setBlockState(blockposLower, stateLower.withProperty(OPEN, openNew), 2);
    			worldIn.markBlockRangeForRenderUpdate(blockposLower, pos);
                //worldIn.playAuxSFXAtEntity(playerIn, 1003, pos, 0);
    			//worldIn.playAuxSFXAtEntity(playerIn, ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getSoundOpen() : this.getSoundOpen(), pos, 0);
    			//worldIn.playSound(playerIn, (double)pos.getX(), (double)pos.getY(), (double)pos.getZ(), ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getSoundOpen() : this.getSoundOpen(), SoundCategory.BLOCKS, 1.0F, 1.0F);
    			worldIn.playEvent(playerIn, ((Boolean)state.getValue(OPEN)).booleanValue() ? this.getOpenSound() : this.getCloseSound(), pos, 0);
    			returnValue = true;
            }
        }
        return returnValue;
    }

    /**
     * Called when a neighboring block was changed and marks that this state should perform any checks during a neighbor
     * change. Cases may include when redstone power is updated, cactus blocks popping off due to a neighboring solid
     * block, etc.
     */
    @Override
    public void neighborChanged(IBlockState state, World worldIn, BlockPos pos, Block neighborBlock)
    {
    	/*Original Door 1.10.2
        if (state.getValue(HALF) == BlockDoor.EnumDoorHalf.UPPER)
        {
            BlockPos blockpos = pos.down();
            IBlockState iblockstate = worldIn.getBlockState(blockpos);

            if (iblockstate.getBlock() != this)
            {
                worldIn.setBlockToAir(pos);
            }
            else if (blockIn != this)
            {
                iblockstate.neighborChanged(worldIn, blockpos, blockIn);
            }
        }
        else
        {
            boolean flag1 = false;
            BlockPos blockpos1 = pos.up();
            IBlockState iblockstate1 = worldIn.getBlockState(blockpos1);

            if (iblockstate1.getBlock() != this)
            {
                worldIn.setBlockToAir(pos);
                flag1 = true;
            }

            if (!worldIn.getBlockState(pos.down()).isSideSolid(worldIn,  pos.down(), EnumFacing.UP))
            {
                worldIn.setBlockToAir(pos);
                flag1 = true;

                if (iblockstate1.getBlock() == this)
                {
                    worldIn.setBlockToAir(blockpos1);
                }
            }

            if (flag1)
            {
                if (!worldIn.isRemote)
                {
                    this.dropBlockAsItem(worldIn, pos, state, 0);
                }
            }
            else
            {
                boolean flag = worldIn.isBlockPowered(pos) || worldIn.isBlockPowered(blockpos1);

                if (blockIn != this && (flag || blockIn.getDefaultState().canProvidePower()) && flag != ((Boolean)iblockstate1.getValue(POWERED)).booleanValue())
                {
                    worldIn.setBlockState(blockpos1, iblockstate1.withProperty(POWERED, Boolean.valueOf(flag)), 2);

                    if (flag != ((Boolean)state.getValue(OPEN)).booleanValue())
                    {
                        worldIn.setBlockState(pos, state.withProperty(OPEN, Boolean.valueOf(flag)), 2);
                        worldIn.markBlockRangeForRenderUpdate(pos, pos);
                        worldIn.playEvent((EntityPlayer)null, flag ? this.getOpenSound() : this.getCloseSound(), pos, 0);
                    }
                }
            }
        }
        */
    	BlockPos blockposLower = pos;
    	BlockPos blockposMiddle = pos;
        BlockPos blockposUpper = pos;
        
        if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER)
        {
        	blockposMiddle = pos.up();
        	blockposUpper = pos.up(2);
        }
        else if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE)
        {
        	blockposLower = pos.down();
        	blockposUpper = pos.up();
        }
        else
        {
        	blockposLower = pos.down(2);
        	blockposMiddle = pos.down();
        }
        
        IBlockState iblockstateLower = worldIn.getBlockState(blockposLower);
        IBlockState iblockstateMiddle = worldIn.getBlockState(blockposMiddle);
        IBlockState iblockstateUpper = worldIn.getBlockState(blockposUpper);
        
        boolean destroyed = false;
        boolean dropItem = false;
        boolean links = false;
        boolean offen = false;
        EnumFacing facing = null;
        
    	if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER)
        {
    		if (iblockstateMiddle.getBlock() != this) //Wenn Mitte keine Tür ist
            {
            	if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper); //Wenn oberer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos); 
                destroyed = true;
            }
            
            if (iblockstateUpper.getBlock() != this) //Wenn Oben keine Tür ist
            {
            	if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle); //Wenn mittlerer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos); 
                destroyed = true;
            }

            if (!worldIn.getBlockState(pos.down()).isFullyOpaque()) //wenn drunter kein solider Block ist
            {
                worldIn.setBlockToAir(pos);
                destroyed = true;

                if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle);//Wenn mittlerer Block Tür => Block entfernen
                if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper);//Wenn oberer Block Tür => Block entfernen
                
                dropItem = true;
            }
            
            if (!destroyed)
            {
            	boolean powered = worldIn.isBlockPowered(pos) || worldIn.isBlockPowered(blockposMiddle) || worldIn.isBlockPowered(blockposUpper);
            	
            	if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)iblockstateUpper.getValue(POWERED)).booleanValue())
            	{
            		worldIn.setBlockState(blockposUpper, iblockstateUpper.withProperty(POWERED, Boolean.valueOf(powered)), 2);

                    if (powered != ((Boolean)state.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
        }
        else if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE)
        {
        	if (iblockstateLower.getBlock() != this) //Wenn unten keine Tür ist
            {
            	if (iblockstateUpper.getBlock() == this) worldIn.setBlockToAir(blockposUpper); //Wenn oberer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (iblockstateUpper.getBlock() != this) //Wenn oben keine Tür ist
            {
            	worldIn.setBlockToAir(pos);
            }
        	
            else if (!destroyed)
            {
            	boolean powered = worldIn.isBlockPowered(blockposLower) || worldIn.isBlockPowered(pos) || worldIn.isBlockPowered(blockposUpper);
            	if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)iblockstateUpper.getValue(POWERED)).booleanValue())
                {
                	worldIn.setBlockState(blockposUpper, iblockstateUpper.withProperty(POWERED, Boolean.valueOf(powered)), 2);
                	if (powered != ((Boolean)iblockstateLower.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
            
        }
        else //UPPER
        {
        	if (iblockstateLower.getBlock() != this) //Wenn unten keine Tür ist
            {
            	if (iblockstateMiddle.getBlock() == this) worldIn.setBlockToAir(blockposMiddle); //Wenn mittlerer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (iblockstateMiddle.getBlock() != this) //Wenn mitte keine Tür ist
            {
            	if (iblockstateLower.getBlock() == this) worldIn.setBlockToAir(blockposLower); //Wenn unterer Block Tür => Block entfernen
                worldIn.setBlockToAir(pos);
            }
            else if (neighborBlock != this)
            {
                this.neighborChanged(iblockstateMiddle,worldIn, blockposMiddle,  neighborBlock);
                this.neighborChanged(iblockstateLower, worldIn, blockposLower, neighborBlock);
            }
            else if (!destroyed)
            {
                boolean powered = worldIn.isBlockPowered(blockposLower) || worldIn.isBlockPowered(blockposMiddle) || worldIn.isBlockPowered(pos);

                if ((powered || neighborBlock.getDefaultState().canProvidePower()) && neighborBlock != this && powered != ((Boolean)state.getValue(POWERED)).booleanValue())
                {
                    worldIn.setBlockState(pos, state.withProperty(POWERED, Boolean.valueOf(powered)), 2);

                    if (powered != ((Boolean)state.getValue(OPEN)).booleanValue()) this.toggleDoor(worldIn, blockposUpper, iblockstateUpper, (EntityPlayer)null, true);
                }
            }
        }
    	if (!worldIn.isRemote && dropItem) this.dropBlockAsItem(worldIn, pos, state, 0);
    }

    /**
     * Get the Item that this Block should drop when harvested.
     */
    @Nullable
    @Override
    public Item getItemDropped(IBlockState state, Random rand, int fortune)
    {
        return this.getItem();
    }
    
    @Override
    public boolean canPlaceBlockAt(World worldIn, BlockPos pos)
    {
    	return pos.getY() >= worldIn.getHeight() - 1 ? false : worldIn.getBlockState(pos.down()).isSideSolid(worldIn,  pos.down(), EnumFacing.UP) && super.canPlaceBlockAt(worldIn, pos) && super.canPlaceBlockAt(worldIn, pos.up()) && super.canPlaceBlockAt(worldIn, pos.up(2));
    }
    
    @Override
    public EnumPushReaction getMobilityFlag(IBlockState state)
    {
        return EnumPushReaction.DESTROY;
    }
    
    public static int combineMetadata(IBlockAccess worldIn, BlockPos pos)
    {
    	/*Original Door 1.10
        IBlockState iblockstate = worldIn.getBlockState(pos);
        int i = iblockstate.getBlock().getMetaFromState(iblockstate);
        boolean flag = isTop(i);
        IBlockState iblockstate1 = worldIn.getBlockState(pos.down());
        int j = iblockstate1.getBlock().getMetaFromState(iblockstate1);
        int k = flag ? j : i;
        IBlockState iblockstate2 = worldIn.getBlockState(pos.up());
        int l = iblockstate2.getBlock().getMetaFromState(iblockstate2);
        int i1 = flag ? i : l;
        boolean flag1 = (i1 & 1) != 0;
        boolean flag2 = (i1 & 2) != 0;
        return removeHalfBit(k) | (flag ? 8 : 0) | (flag1 ? 16 : 0) | (flag2 ? 32 : 0);
        */
    	int combinedMeta = 0;
        IBlockState iblockstate = worldIn.getBlockState(pos);
        int metaThis = iblockstate.getBlock().getMetaFromState(iblockstate);
        int metaLower = 0;
        int metaMiddle = 0;
        int metaUpper = 0;
        if ((metaThis &  == 0) //unterer Teil
        {
        	metaLower = metaThis;
        	IBlockState iblockstateMiddle = worldIn.getBlockState(pos.up());
        	metaMiddle = iblockstateMiddle.getBlock().getMetaFromState(iblockstateMiddle);
        	IBlockState iblockstateUpper = worldIn.getBlockState(pos.up(2));
        	metaUpper = iblockstateUpper.getBlock().getMetaFromState(iblockstateUpper);
        }
        else if ((metaThis & 4) == 0)
        {
        	metaMiddle = metaThis;
        	IBlockState iblockstateLower = worldIn.getBlockState(pos.down());
        	metaLower = iblockstateLower.getBlock().getMetaFromState(iblockstateLower);
        	IBlockState iblockstateUpper = worldIn.getBlockState(pos.up());
        	metaUpper = iblockstateUpper.getBlock().getMetaFromState(iblockstateUpper);
        }
        else
        {
        	metaUpper = metaThis;
        	IBlockState iblockstateLower = worldIn.getBlockState(pos.down(2));
        	metaLower = iblockstateLower.getBlock().getMetaFromState(iblockstateLower);
        	IBlockState iblockstateMiddle = worldIn.getBlockState(pos.down());
        	metaMiddle = iblockstateMiddle.getBlock().getMetaFromState(iblockstateMiddle);
        }
        
        int facing = (metaLower & 3);
        boolean open = (metaLower & 4) != 0;
        boolean upperHalf = (metaThis &  != 0;
        boolean middle = (metaThis &  != 0 && (metaThis & 4) == 0;
        boolean right = (metaMiddle & 1) != 0;
        boolean power = (metaUpper & 1) != 0;
        
        combinedMeta = facing | (open ? 4 : 0) | (upperHalf ? 8 : 0) | (middle ? 16 : 0) | (right ? 32 : 0) | (power ? 64 : 0);// | (distal ? 128 : 0);
        
        return combinedMeta;
    }
    
    @Override
    public ItemStack getItem(World worldIn, BlockPos pos, IBlockState state)
    {
        return new ItemStack(this.getItem());
    }
    
    private Item getItem()
    {
    	Item item;
    	if (getDoorMaterial().equals("oak")) item = RoxaTallDoorsMod.itemDoorOneByThreeOak;
    	else if (getDoorMaterial().equals("birch")) item = RoxaTallDoorsMod.itemDoorOneByThreeBirch;
    	else if (getDoorMaterial().equals("spruce")) item = RoxaTallDoorsMod.itemDoorOneByThreeSpruce;
    	else if (getDoorMaterial().equals("jungle")) item = RoxaTallDoorsMod.itemDoorOneByThreeJungle;
    	else if (getDoorMaterial().equals("acacia")) item = RoxaTallDoorsMod.itemDoorOneByThreeAcacia;
    	else if (getDoorMaterial().equals("darkOak")) item = RoxaTallDoorsMod.itemDoorOneByThreeDarkOak;
    	else item = RoxaTallDoorsMod.itemDoorOneByThreeIron;    	
        return item;
    }
    
    @Override
    public void onBlockHarvested(World worldIn, BlockPos pos, IBlockState state, EntityPlayer player)
    {
    	BlockPos blockposDown = pos.down();
        BlockPos blockposDown2 = pos.down(2);
        BlockPos blockposUp = pos.up();
        BlockPos blockposUp2 = pos.up(2);

        if (player.capabilities.isCreativeMode)
        {
        	if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.UPPER)
        	{
        		if(worldIn.getBlockState(blockposDown2).getBlock() == this) worldIn.setBlockToAir(blockposDown2);
        		if(worldIn.getBlockState(blockposDown).getBlock() == this) worldIn.setBlockToAir(blockposDown);
        	}
        	
        	if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE)
        	{
        		if(worldIn.getBlockState(blockposDown).getBlock() == this) worldIn.setBlockToAir(blockposDown);
        		if(worldIn.getBlockState(blockposUp).getBlock() == this) worldIn.setBlockToAir(blockposUp);
        	}
        	if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER)
        	{
        		if(worldIn.getBlockState(blockposUp).getBlock() == this) worldIn.setBlockToAir(blockposUp);
        		if(worldIn.getBlockState(blockposUp2).getBlock() == this) worldIn.setBlockToAir(blockposUp2);
        	}
        }
    }

    @SideOnly(Side.CLIENT)
    @Override
    public BlockRenderLayer getBlockLayer()
    {
        return BlockRenderLayer.CUTOUT;
    }

    /**
     * Get the actual Block state of this Block at the given position. This applies properties not visible in the
     * metadata, such as fence connections.
     */
    @Override
    public IBlockState getActualState(IBlockState state, IBlockAccess worldIn, BlockPos pos)
    {
    	IBlockState iblockstateLower;
        IBlockState iblockstateMiddle;
        IBlockState iblockstateUpper;

        if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER)
        {
        	iblockstateMiddle = worldIn.getBlockState(pos.up());
        	iblockstateUpper = worldIn.getBlockState(pos.up(2));
            
            if (iblockstateMiddle.getBlock() == this)
            {
                state = state.withProperty(HINGE, iblockstateMiddle.getValue(HINGE));
                //state = state.withProperty(DISTAL, iblockstateMiddle.getValue(DISTAL));
            }
            if (iblockstateUpper.getBlock() == this)
            {
                state = state.withProperty(POWERED, iblockstateUpper.getValue(POWERED));
            }
        }
        else if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE)
        {
        	iblockstateUpper = worldIn.getBlockState(pos.up());
        	iblockstateLower = worldIn.getBlockState(pos.down());
        	
            if (iblockstateLower.getBlock() == this)
            {
                state = state.withProperty(OPEN, iblockstateLower.getValue(OPEN));
                state = state.withProperty(FACING, iblockstateLower.getValue(FACING));
            }
            if (iblockstateUpper.getBlock() == this)
            {
                state = state.withProperty(POWERED, iblockstateUpper.getValue(POWERED));
            }
        }
        else //HALF == UPPER
        {
        	iblockstateMiddle = worldIn.getBlockState(pos.down());
        	iblockstateLower = worldIn.getBlockState(pos.down(2));
        	
            if (iblockstateLower.getBlock() == this)
            {
                state = state.withProperty(OPEN, iblockstateLower.getValue(OPEN));
                state = state.withProperty(FACING, iblockstateLower.getValue(FACING));
            }
            if (iblockstateMiddle.getBlock() == this)
            {
                state = state.withProperty(HINGE, iblockstateMiddle.getValue(HINGE));
                //state = state.withProperty(DISTAL, iblockstateMiddle.getValue(DISTAL));
            }
        }

        return state;
    }

    /**
     * Returns the blockstate with the given rotation from the passed blockstate. If inapplicable, returns the passed
     * blockstate.
     */
    //TODO Versteh ich noch nicht ganz...
    @Override
    public IBlockState withRotation(IBlockState state, Rotation rot)
    {
        return state.getValue(HALF) != BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER ? state : state.withProperty(FACING, rot.rotate((EnumFacing)state.getValue(FACING)));
    }

    /**
     * Returns the blockstate with the given mirror of the passed blockstate. If inapplicable, returns the passed
     * blockstate.
     */
    @Override
    public IBlockState withMirror(IBlockState state, Mirror mirrorIn)
    {
        return mirrorIn == Mirror.NONE ? state : state.withRotation(mirrorIn.toRotation((EnumFacing)state.getValue(FACING))).cycleProperty(HINGE);
    }

    /**
     * Convert the given metadata into a BlockState for this Block
     */
    @Override
    public IBlockState getStateFromMeta(int meta)
    {
IBlockState state = this.getDefaultState();
    	
        if ((meta &  == 0) //Unten
        {
        	state.withProperty(HALF, BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.LOWER);
        	state.withProperty(FACING, EnumFacing.getHorizontal(meta & 3).rotateYCCW());
        	state.withProperty(OPEN, Boolean.valueOf((meta & 4) > 0));
        }
        else //Oberer Teil
        {
        	if ((meta & 4) == 0) //Mitte
        	{
        		state.withProperty(HALF, BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.MIDDLE);
        		state.withProperty(HINGE, (meta & 1) > 0 ? BlockDoor.EnumHingePosition.RIGHT : BlockDoor.EnumHingePosition.LEFT);
        		//state.withProperty(DISTAL, Boolean.valueOf((meta & 2) > 0));
        	}
        	else //Oben
        	{
        		//Bei 4 hohen Rüren kommt hier noch die Unterscheidung zw. UPPER und UPPERMIDDLE
        		state.withProperty(HALF, BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.UPPER);
        		state.withProperty(POWERED, Boolean.valueOf((meta & 1) > 0));
        	}
        }
        return state;
    }

    /**
     * Convert the BlockState into the correct metadata value
     */
    @Override
    public int getMetaFromState(IBlockState state)
    {
        int i = 0;

        if (state.getValue(HALF) == BlockDoorOneByThreeCopiedIntoVanillaDoor.EnumDoorHalf.UPPER)
        {
            i = i | 8;

            if (state.getValue(HINGE) == BlockDoor.EnumHingePosition.RIGHT)
            {
                i |= 1;
            }

            if (((Boolean)state.getValue(POWERED)).booleanValue())
            {
                i |= 2;
            }
        }
        else
        {
            i = i | ((EnumFacing)state.getValue(FACING)).rotateY().getHorizontalIndex();

            if (((Boolean)state.getValue(OPEN)).booleanValue())
            {
                i |= 4;
            }
        }

        return i;
    }

    protected static int removeHalfBit(int meta)
    {
        return meta & 7;
    }

    public static boolean isOpen(IBlockAccess worldIn, BlockPos pos)
    {
        return isOpen(combineMetadata(worldIn, pos));
    }

    public static EnumFacing getFacing(IBlockAccess worldIn, BlockPos pos)
    {
        return getFacing(combineMetadata(worldIn, pos));
    }

    public static EnumFacing getFacing(int combinedMeta)
    {
        return EnumFacing.getHorizontal(combinedMeta & 3).rotateYCCW();
    }

    protected static boolean isOpen(int combinedMeta)
    {
        return (combinedMeta & 4) != 0;
    }

    protected static boolean isTop(int meta)
    {
        return (meta &  != 0;
    }
    
    @Override
    protected BlockStateContainer createBlockState()
    {
        return new BlockStateContainer(this, new IProperty[] {HALF, FACING, OPEN, HINGE, POWERED});
    }

    public static enum EnumDoorHalf implements IStringSerializable
    {
        UPPER,
        MIDDLE,
        LOWER;
        
        public String toString()
        {
            return this.getName();
        }

        public String getName()
        {
        	String name;
        	if (this == UPPER) name = "upper";
        	else if (this == MIDDLE) name = "middle";
        	else name = "lower";
            return name;
        }
    }
    
    public String getDoorMaterial()
    {
    	String material;
    	if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeOak")) material = "oak";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeBirch")) material = "birch";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeSpruce")) material = "spruce";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeJungle")) material = "jungle";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeAcacia")) material = "acacia";
    	else if (this.getUnlocalizedName().substring(5).equals("blockDoorOneByThreeDarkOak")) material = "darkOak";
    	else material = "iron";
    	
    	return material;
    }
}

 

 

The whole code can be found here:

GitHub Repo

Link to comment
Share on other sites

I assume the following properties have the following amount of possibilities:

- HALF: 3 possibilities (lower, middle and upper)

- FACING: 4 possibilities (north, south, east, west)

- OPEN: 2 possibilities (open or closed)

 

This makes for a total of 3x4x2=24 possibilities you can have. Now, metadata can only have 16 different values (0-15), which is not enough to store the 24 possibilities you have. You probably want to use a

TileEntity

for your blocks.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Link to comment
Share on other sites

I assume the following properties have the following amount of possibilities:

- HALF: 3 possibilities (lower, middle and upper)

- FACING: 4 possibilities (north, south, east, west)

- OPEN: 2 possibilities (open or closed)

 

This makes for a total of 3x4x2=24 possibilities you can have. Now, metadata can only have 16 different values (0-15), which is not enough to store the 24 possibilities you have. You probably want to use a

TileEntity

for your blocks.

That's why I store some of the data in the upper part, some of the data in the middle part and the rest of the data in the lower part. Each part knows its height/position and fetches the things it doesn't store itself from the other parts. Just as vanilla doors do (they have HALF, FACING, HINGE and OPEN resulting in 32 possibilities). That worked fine in the 1.9 version and works on vanilla doors, so that's not the cause of the problem.

Link to comment
Share on other sites

I assume the following properties have the following amount of possibilities:

- HALF: 3 possibilities (lower, middle and upper)

- FACING: 4 possibilities (north, south, east, west)

- OPEN: 2 possibilities (open or closed)

 

This makes for a total of 3x4x2=24 possibilities you can have. Now, metadata can only have 16 different values (0-15), which is not enough to store the 24 possibilities you have. You probably want to use a

TileEntity

for your blocks.

That's why I store some of the data in the upper part, some of the data in the middle part and the rest of the data in the lower part. Each part knows its height/position and fetches the things it doesn't store itself from the other parts. Just as vanilla doors do (they have HALF, FACING, HINGE and OPEN resulting in 32 possibilities). That worked fine in the 1.9 version and works on vanilla doors, so that's not the cause of the problem.

Ok but vanilla doors only have two halfs 2 * 4 (the facing) * 2 (open or closed) = 16 which is the exact number for metadata. How ever yours would have more than thirteen so i would make three different blocks one for each part of the door atleast for your 1 by 3 door otherwise you will need a TileEntity.

VANILLA MINECRAFT CLASSES ARE THE BEST RESOURCES WHEN MODDING

I will be posting 1.15.2 modding tutorials on this channel. If you want to be notified of it do the normal YouTube stuff like subscribing, ect.

Forge and vanilla BlockState generator.

Link to comment
Share on other sites

No, the metadata IN WHOLE being more than 16 possibilities is not the cause of the problem. Each SINGLE door block only has a max of 16 possibilities and gets the rest of the nessecary data from the door blocks below or above itself. Thats why doors (mine as well as the vanilla ones) have this combineMeta thingy. This worked since I started this mod back in version 1.6.

Even vanilla doors have 32 possibilities in whole! They don't only store the half, the facing and the state (open or closed) but also if the hinge is on the left or on the right!

 

The getMetafromState Method will never return a value > 15:

 

@Override
    public int getMetaFromState(IBlockState state)
    {
        byte b0 = 0;
        int i;

        if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.LOWER)
        {
            i = b0 | ((EnumFacing)state.getValue(FACING)).rotateY().getHorizontalIndex();

            if (((Boolean)state.getValue(OPEN)).booleanValue())
            {
                i |= 4;
            }
        }
        else
        {
        	i = b0 | 8;
        	if (state.getValue(HALF) == BlockDoorOneByThree.EnumDoorHalf.MIDDLE)
            {
        		/*if (((Boolean)state.getValue(DISTAL)).booleanValue())
                {
                    i |= 2;
                }*/
                if (state.getValue(HINGE) == BlockDoor.EnumHingePosition.RIGHT)
                {
                    i |= 1;
                }
            }
        	else
        	{
        		i |= 4;
        		/* Noch Freie Variable
                if (((Boolean)state.getValue(FREI)).booleanValue())
                {
                    i |= 2;
                }
                */
        		if (((Boolean)state.getValue(POWERED)).booleanValue())
                {
                    i |= 1;
                }
        	}
        }

        return i;
    }

 

 

I guess my problem is more like not overwriting the correct super method or something stupid like this... Just something that is so stupidly simple that I didn't see it.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Ligadewa138 telah menjelma menjadi salah satu destinasi utama bagi para pecinta perjudian daring di Asia yang mencari pengalaman bermain slot yang unggul dan menarik. Dengan reputasi yang kokoh dan berbagai koleksi permainan slot yang mengagumkan, Ligadewa138 telah berhasil menarik perhatian banyak pemain dari berbagai belahan dunia. Dalam panduan ini, kami akan membahas mengapa Ligadewa138 dianggap sebagai salah satu situs slot terbaik di Asia saat ini. 1. Koleksi Permainan yang Luar Biasa Ligadewa138 menawarkan koleksi permainan slot yang luar biasa dengan berbagai tema yang menarik dan inovatif. Dari slot klasik hingga slot modern dengan fitur-fitur canggih, pemain dapat menemukan berbagai pilihan permainan yang sesuai dengan preferensi mereka. Kualitas grafis dan animasi yang menakjubkan membuat pengalaman bermain semakin menghibur dan memikat. 2. Keamanan dan Kepercayaan Ligadewa138 dikenal karena komitmennya terhadap keamanan dan kepercayaan pemain. Situs ini dilengkapi dengan teknologi enkripsi terbaru untuk melindungi data pribadi dan keuangan para pemain. Selain itu, Ligadewa138 juga telah mendapatkan lisensi resmi dari otoritas perjudian yang diakui, menjamin bahwa semua permainan di situs ini fair dan adil. 3. Bonus dan Promosi Menarik Ligadewa138 seringkali menawarkan berbagai bonus dan promosi menarik kepada para pemainnya. Mulai dari bonus selamat datang hingga bonus setoran dan putaran gratis, pemain dapat menikmati berbagai penawaran menguntungkan yang dapat meningkatkan peluang mereka untuk meraih kemenangan besar. Program loyalitas yang murah hati juga membuat pemain merasa dihargai dan dihormati. 4. Layanan Pelanggan yang Profesional Ligadewa138 dikenal karena layanan pelanggannya yang profesional dan responsif. Tim dukungan pelanggan yang ramah dan berpengetahuan luas siap membantu pemain dengan segala pertanyaan atau masalah yang mereka hadapi. Dengan layanan pelanggan yang tersedia 24/7, pemain dapat merasa tenang dan yakin bahwa bantuan selalu tersedia jika diperlukan. 5. Kemudahan Transaksi Keuangan Ligadewa138 menyediakan berbagai metode pembayaran yang aman dan nyaman bagi para pemainnya. Dari transfer bank lokal hingga dompet elektronik dan kartu prabayar, pemain dapat melakukan transaksi keuangan dengan mudah dan cepat. Proses penarikan yang cepat dan tanpa ribet juga membuat pemain merasa lebih diuntungkan. Dengan kombinasi koleksi permainan yang luar biasa, keamanan yang terjamin, bonus yang menggiurkan, layanan pelanggan yang profesional, dan kemudahan transaksi keuangan, tidak mengherankan jika Ligadewa138 dianggap sebagai salah satu situs slot terbaik di Asia saat ini.
    • MPOSLOT Merupakan Link Slot Gacor MPO SLOT Terbaru Dan Gampang Menang Dengan Minimal Deposit 10,000 Dapat Dimainkan Semua Jenis Permainan ▶️▶️▶️ DAFTAR KLIK DI SINI ◀️◀️◀️ Dalam dunia taruhan online yang semakin berkembang, mencari platform yang dapat diandalkan dan menyenangkan untuk bermain merupakan hal yang sangat penting bagi para pecinta taruhan. Salah satu opsi teratas yang muncul adalah MPOSLOT dan jaringan link alternatifnya yang menyediakan tingkat pengalaman taruhan yang tinggi. Mari kita gali lebih dalam tentang apa yang membuat MPOSLOT dan daftar situs link alternatif MPOSLOT RTP begitu menarik bagi para penggemar taruhan online. Keyword Terkait : MPOSLOT MPOSLOT Slot MPOSLOT Daftar MPOSLOT Login MPOSLOT Link Alternatif MPOSLOT RTP AGEN MPOSLOT SITUS MPOSLOT
    • DAFTAR KLIK DISINI DAFTAR KLIK DISINI SENJU33☘️ Depo 100 Bonus 100 Link Alternatif Bonus 100% Senju33. SENJU33, seperti kakek Zeus yang berkuasa, menonjolkan dirinya sebagai pemimpin dalam industri perjudian online. Fitur RTP (Return to Player) yang disediakan oleh SENJU33 mencerminkan komitmen untuk memberikan peluang yang adil kepada pemainnya, sebagaimana Ouranos memberikan keadilan di dunia mitologi. Senju33 dengan Akses Login Situs SENJU33 Slot Gacor Hari Ini Gampang menang tanpa pola rtp slot, ada bonus untuk member baru mendaftar di situs senju33 slot gacor hari ini 30%, mencari pengalaman bermain slot yang tak terlupakan di Indonesia? SENJU33 adalah jawabannya! Sebagai situs super gacor paling terdepan di tahun ini, SENJU33 menawarkan ID VIP Pro, akun resmi, dan link login terkini untuk memastikan Anda meraih pengalaman bermain slot yang luar biasa.
    • SUHU77 Situs Cara Deposit Lewat Dana Merupakan Situs Dengan Permainan Terlengkap Dan Login & Daftar Termudah Yang Bisa Anda Gunakan. Selain Itu, Untuk Deposit Juga Sangat Mudah Dan Lengkap Semua Payment Di Terima Dari Deposit Bank Local, E-Wallet / E-Money (Dana, Ovo, Gopay, Shopeepay, Sakuku Dll), Deposit Pulsa Tanpa Potongan Terlengkap DAFTAR KLIK DISINI DAFTAR KLIK DISINI Untuk Bermain Disini Sangat Lah Mudah Dan Untuk Situs Juga Sudah Di Percaya Sejak Lama. Menang Berapapun Pasti Di Bayar Lunas Tanpa Pending. Jadi Jangan Lewatkan Bermain Di SUHU77 Situs Cara Deposit Lewat Dana. Sistem Permainan Yang Ditawarkan Telah Mendapatkan Kepercayaan Dari Berbagai Member Yang Sudah Mendapatkan Keuntungan Dari Hal Itu Yang Berasal Dari Permainan Slot Online. SUHU77 SUHU77 Login SUHU77 Daftar SUHU77 Rtp Slot Scatter SUHU77 Link Alternatif SUHU77 Agen SUHU77 Situs SUHU77
    • OSG888 Merupakan Link Slot Gacor OSG888 Terbaru Dan Gampang Menang Dengan Minimal Deposit 10,000 Dapat Dimainkan Semua Jenis Permainan ▶️▶️▶️ DAFTAR KLIK DI SINI ◀️◀️◀️ ▶️▶️▶️ DAFTAR KLIK DI SINI ◀️◀️◀️ ▶️▶️▶️ DAFTAR KLIK DI SINI ◀️◀️◀️ Dalam dunia taruhan online yang semakin berkembang, mencari platform yang dapat diandalkan dan menyenangkan untuk bermain merupakan hal yang sangat penting bagi para pecinta taruhan. Salah satu opsi teratas yang muncul adalah OSG888 dan jaringan link alternatifnya yang menyediakan tingkat pengalaman taruhan yang tinggi. Mari kita gali lebih dalam tentang apa yang membuat OSG888 dan daftar situs link alternatif OSG888 RTP begitu menarik bagi para penggemar taruhan online. 1. Keandalan dan Kredibilitas OSG888 dikenal karena keandalan dan kredibilitasnya. Dengan lisensi resmi dan regulasi yang ketat, situs ini menawarkan lingkungan taruhan yang aman dan terjamin bagi para pemainnya. Pengguna dapat yakin bahwa setiap taruhan yang mereka tempatkan dilakukan dalam kerangka yang adil dan teratur. 2. Ragam Permainan yang Luas Salah satu daya tarik utama dari OSG888 adalah ragam permainan yang ditawarkan. Mulai dari slot online yang menghibur hingga permainan meja klasik seperti blackjack dan roulette, para pemain memiliki banyak pilihan untuk memilih permainan sesuai dengan preferensi mereka. Selain itu, fitur live casino juga menambahkan dimensi interaktif yang memungkinkan pemain untuk merasakan pengalaman kasino langsung dari kenyamanan rumah mereka. 3. Tingkat Pengembalian (RTP) yang Kompetitif OSG888 menawarkan tingkat pengembalian (RTP) yang kompetitif untuk sebagian besar permainannya. Ini berarti bahwa pemain memiliki peluang lebih baik untuk meraih kemenangan dan menghasilkan keuntungan dari taruhan mereka. Tingkat pengembalian yang tinggi juga menambah keseruan permainan dan membuat pengalaman taruhan menjadi lebih memuaskan. 4. Kemudahan Akses melalui Link Alternatif OSG888 menyediakan daftar situs link alternatif OSG888 RTP, yang memungkinkan para pemain untuk mengakses situs tersebut dengan mudah bahkan jika situs utama mereka diblokir oleh penyedia layanan internet tertentu. Ini memberikan fleksibilitas tambahan bagi para pemain untuk terus menikmati pengalaman taruhan mereka tanpa hambatan. 5. Promosi dan Bonus yang Menarik Situs ini juga terkenal dengan berbagai promosi dan bonus yang menarik bagi para pemainnya. Mulai dari bonus selamat datang hingga promosi loyalitas, ada banyak kesempatan untuk meningkatkan pengalaman taruhan Anda dan menghasilkan keuntungan tambahan dari bermain di OSG888. Kesimpulan OSG888 dan daftar situs link alternatif OSG888 RTP menawarkan pengalaman taruhan online yang luar biasa bagi para penggemar taruhan di seluruh dunia. Dengan keandalan, ragam permainan, tingkat pengembalian yang kompetitif, dan promosi menarik, tidak mengherankan bahwa OSG888 telah menjadi salah satu destinasi utama bagi para pecinta taruhan online. Bagi mereka yang mencari platform yang dapat diandalkan dan menyenangkan untuk bermain, OSG888 adalah pilihan yang sulit untuk dikalahkan Keyword Terkait : OSG888 OSG888 Slot OSG888 Daftar OSG888 Login OSG888 Link Alternatif OSG888 RTP AGEN OSG888 SITUS OSG888
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.