If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at
the top of the file.
import crafttweaker . api.block . BlockState;
BlockState extends BlockStateBase
.
Undocumented Interfaces IForgeBlockState
// (BlockState | (other as CTBlockIngredient)) as CTBlockIngredient
< blockstate : minecraft:grass > | myCTBlockIngredient
Return Type:
BlockIngredient
// BlockState as CTBlockIngredient
< blockstate : minecraft:grass > as CTBlockIngredient
Return Type:
BlockIngredient
// BlockState.asString() as string;
< blockstate : minecraft:grass > .asString();
Return Type:
string
Gets the base Block
of this BlockState. The Block
will not contain any of the properties of this BlockState. // BlockState.block as Block
< blockstate : minecraft:grass > .block
Return Type:
Block
Gets the base Block
of this BlockState. The Block
will not contain any of the properties of this BlockState. < blockstate : minecraft:grass > as Block
Return Type:
Block
Checks whether this BlockState is solid. // BlockState.canOcclude as bool
< blockstate : minecraft:grass > .canOcclude
Return Type:
bool
Checks whether this BlockState is solid. Returns : True if this BlockState is solid. False otherwise.
// BlockState.canOcclude() as bool;
< blockstate : minecraft:grass > .canOcclude();
Return Type:
bool
Gets the blockstate bracket handler syntax for this BlockState. E.G. <blockstate:minecraft:grass:snowy=true>
// BlockState.commandString as string
< blockstate : minecraft:grass > .commandString
Return Type:
string
Gets the blockstate bracket handler syntax for this BlockState. E.G. <blockstate:minecraft:grass:snowy=true>
Returns : The blockstate bracket handler syntax for this BlockState.
// BlockState.commandString() as string;
< blockstate : minecraft:grass > .commandString();
Return Type:
string
Gets the blockstate bracket handler syntax for this BlockState. E.G. <blockstate:minecraft:grass:snowy=true>
< blockstate : minecraft:grass > as string
Return Type:
string
Gets the hardness of this BlockState. // BlockState.destroySpeed as float
< blockstate : minecraft:grass > .destroySpeed
Return Type:
float
Sets the destroy speed of this BlockState. // BlockState.destroySpeed = (destroySpeed as float);
< blockstate : minecraft:grass > .destroySpeed = myFloat;
Parameters:
destroySpeed: float
Type: float
- the new destroy speed of this BlockState
Gets the hardness of this BlockState. Returns : The hardness of this BlockState.
// BlockState.destroySpeed() as float;
< blockstate : minecraft:grass > .destroySpeed();
Return Type:
float
Sets the destroy speed of this BlockState. // BlockState.destroySpeed(destroySpeed as float);
< blockstate : minecraft:grass > .destroySpeed( 2.4f );
Parameters:
destroySpeed: float
Type: float
- the new destroy speed of this BlockState
Gets a list of allowed values for a given property. Returns : a List of allowed values.
// BlockState.getAllowedValuesForProperty(name as string) as List<string>;
< blockstate : minecraft:grass > .getAllowedValuesForProperty( "snowy" );
Parameters:
name: string
Type: string
- The name of the property to find the allowed values for.
Return Type:
List <string >
Gets the value of the given property. Returns : The value of the property on this BlockState.
// BlockState.getPropertyValue(name as string) as string;
< blockstate : minecraft:grass > .getPropertyValue(myString);
Parameters:
name: string
Type: string
- "snowy"
Return Type:
string
Checks whether this BlockState has the given property. Returns : True if this BlockState has the property. False otherwise.
// BlockState.hasProperty(name as string) as bool;
< blockstate : minecraft:grass > .hasProperty( "snowy" );
Parameters:
name: string
Type: string
- the name of the property to check.
Return Type:
bool
Checks whether this BlockState ticks randomly. // BlockState.isRandomlyTicking as bool
< blockstate : minecraft:grass > .isRandomlyTicking
Return Type:
bool
Checks whether this BlockState ticks randomly. Returns : True if this BlockState ticks randomly. False otherwise.
// BlockState.isRandomlyTicking() as bool;
< blockstate : minecraft:grass > .isRandomlyTicking();
Return Type:
bool
Checks whether this BlockState can provide Redstone Power // BlockState.isSignalSource as bool
< blockstate : minecraft:grass > .isSignalSource
Return Type:
bool
Checks whether this BlockState can provide Redstone Power Returns : True if this BlockState can provide Redstone Power. False otherwise.
// BlockState.isSignalSource() as bool;
< blockstate : minecraft:grass > .isSignalSource();
Return Type:
bool
Gets the light level of this BlockState // BlockState.lightEmission as int
< blockstate : minecraft:grass > .lightEmission
Return Type:
int
Gets the light level of this BlockState Returns : The light level of this BlockState.
// BlockState.lightEmission() as int;
< blockstate : minecraft:grass > .lightEmission();
Return Type:
int
Gets the properties of this BlockState. // BlockState.properties as string[string]
< blockstate : minecraft:grass > .properties
Return Type:
string [string ]
Gets the properties of this BlockState. Returns : a Map of the properties on this BlockState.
// BlockState.properties() as string[string];
< blockstate : minecraft:grass > .properties();
Return Type:
string [string ]
Gets the names of the properties of this BlockState. // BlockState.propertyNames as List<string>
< blockstate : minecraft:grass > .propertyNames
Return Type:
List <string >
Gets the names of the properties of this BlockState. Returns : the List of the names of the BlockStates's properties.
// BlockState.propertyNames() as List<string>;
< blockstate : minecraft:grass > .propertyNames();
Return Type:
List <string >
// BlockState.rotate(rotation as Rotation) as BlockState;
< blockstate : minecraft:grass > .rotate(myRotation);
Return Type:
BlockState
// BlockState.soundType as SoundType
< blockstate : minecraft:grass > .soundType
Return Type:
SoundType
// BlockState.soundType() as SoundType;
< blockstate : minecraft:grass > .soundType();
Return Type:
SoundType
Sets a block property based on it's name. Returns : This BlockState with the new property value.
// BlockState.withProperty(name as string, value as string) as BlockState;
< blockstate : minecraft:grass > .withProperty( "snowy" , "true" );
Parameters:
name: string
Type: string
- The name of the property to set.
value: string
Type: string
- The new value of the property.
Return Type:
BlockState