|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.minecraft.block.Block
net.minecraft.block.BlockDirectional
net.minecraft.block.BlockBed
public class BlockBed
Field Summary | |
---|---|
static int[][] |
footBlockToHeadBlockMap
Maps the foot-of-bed block to the head-of-bed block. |
Constructor Summary | |
---|---|
BlockBed(int par1)
|
Method Summary | |
---|---|
void |
dropBlockAsItemWithChance(World par1World,
int par2,
int par3,
int par4,
int par5,
float par6,
int par7)
Drops the block items with a specified chance of dropping the specified items |
int |
getBlockTextureFromSideAndMetadata(int par1,
int par2)
From the specified side and block metadata retrieves the blocks texture. |
int |
getMobilityFlag()
Returns the mobility information of the block, 0 = free, 1 = can't push but can move over, 2 = total immobility and stop pistons |
static ChunkCoordinates |
getNearestEmptyChunkCoordinates(World par0World,
int par1,
int par2,
int par3,
int par4)
Gets the nearest empty chunk coordinates for the player to wake up from a bed into. |
int |
getRenderType()
The type of render function that is called for this block |
int |
idDropped(int par1,
Random par2Random,
int par3)
Returns the ID of the items to drop on destruction. |
int |
idPicked(World par1World,
int par2,
int par3,
int par4)
|
static boolean |
isBedOccupied(int par0)
Return whether or not the bed is occupied. |
static boolean |
isBlockHeadOfBed(int par0)
Returns whether or not this bed block is the head of the bed. |
boolean |
isOpaqueCube()
Is this block (a) opaque and (b) a full 1m cube? This determines whether or not to render the shared face of two adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block. |
boolean |
onBlockActivated(World par1World,
int par2,
int par3,
int par4,
EntityPlayer par5EntityPlayer,
int par6,
float par7,
float par8,
float par9)
Called upon block activation (right click on the block.) |
void |
onBlockHarvested(World par1World,
int par2,
int par3,
int par4,
int par5,
EntityPlayer par6EntityPlayer)
Called when the block is attempted to be harvested |
void |
onNeighborBlockChange(World par1World,
int par2,
int par3,
int par4,
int par5)
Lets the block know when one of its neighbor changes. |
boolean |
renderAsNormalBlock()
If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc) |
static void |
setBedOccupied(World par0World,
int par1,
int par2,
int par3,
boolean par4)
Sets whether or not the bed is occupied. |
void |
setBlockBoundsBasedOnState(IBlockAccess par1IBlockAccess,
int par2,
int par3,
int par4)
Updates the blocks bounds based on its current state. |
Methods inherited from class net.minecraft.block.BlockDirectional |
---|
getDirection |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int[][] footBlockToHeadBlockMap
Constructor Detail |
---|
public BlockBed(int par1)
Method Detail |
---|
public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer, int par6, float par7, float par8, float par9)
onBlockActivated
in class Block
public int getBlockTextureFromSideAndMetadata(int par1, int par2)
getBlockTextureFromSideAndMetadata
in class Block
public int getRenderType()
getRenderType
in class Block
public boolean renderAsNormalBlock()
renderAsNormalBlock
in class Block
public boolean isOpaqueCube()
isOpaqueCube
in class Block
public void setBlockBoundsBasedOnState(IBlockAccess par1IBlockAccess, int par2, int par3, int par4)
setBlockBoundsBasedOnState
in class Block
public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, int par5)
onNeighborBlockChange
in class Block
public int idDropped(int par1, Random par2Random, int par3)
idDropped
in class Block
public static boolean isBlockHeadOfBed(int par0)
public static boolean isBedOccupied(int par0)
public static void setBedOccupied(World par0World, int par1, int par2, int par3, boolean par4)
public static ChunkCoordinates getNearestEmptyChunkCoordinates(World par0World, int par1, int par2, int par3, int par4)
public void dropBlockAsItemWithChance(World par1World, int par2, int par3, int par4, int par5, float par6, int par7)
dropBlockAsItemWithChance
in class Block
public int getMobilityFlag()
getMobilityFlag
in class Block
public int idPicked(World par1World, int par2, int par3, int par4)
idPicked
in class Block
public void onBlockHarvested(World par1World, int par2, int par3, int par4, int par5, EntityPlayer par6EntityPlayer)
onBlockHarvested
in class Block
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |