BlockPos
Importing the class
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.util.math.BlockPos;Extends
BlockPos extends Vec3i.
Implements
Undocumented Interfaces
Comparable<Vec3i>
Constructors
new(x as int, y as int, z as int)
Creates a new BlockPos using the provided values.script.zs 
// new BlockPos(x as int, y as int, z as int);new BlockPos(myInt, myInt, myInt);Parameters:
x: int  Type: int 
- The x value of the blockpos   y: int  Type: int 
- The y value of the blockpos   z: int  Type: int 
- The z value of the blockpos   new(vector as Vec3i)
Members
asLong() as long
// BlockPos.asLong() as long;myBlockPos.asLong();
Return Type:
long
asMutable() as MutableBlockPos
static containing(x as double, y as double, z as double) as BlockPos
static containing(position as Position) as BlockPos
distToCenterSqr(position as Position) as double
distToCenterSqr(x as double, y as double, z as double) as double
// BlockPos.distToCenterSqr(x as double, y as double, z as double) as double;myBlockPos.distToCenterSqr(myDouble, myDouble, myDouble);Parameters:
x: double  Type: double   y: double  Type: double   z: double  Type: double   
Return Type:
double
offset(x as int, y as int, z as int) as BlockPos
offset(other as Vec3i) as BlockPos
relative(direction as Direction) as BlockPos
relative(direction as Direction, distance as int) as BlockPos
relative(axis as Axis, distance as int) as BlockPos
Getter
// BlockPos.toShortString as stringmyBlockPos.toShortString
Return Type:
string
toShortString() as string
// BlockPos.toShortString() as string;myBlockPos.toShortString();
Return Type:
string
Getter
// BlockPos.x as intmyBlockPos.x
Return Type:
int
x() as int
// BlockPos.x() as int;myBlockPos.x();
Return Type:
int
Getter
// BlockPos.y as intmyBlockPos.y
Return Type:
int
y() as int
// BlockPos.y() as int;myBlockPos.y();
Return Type:
int
Getter
// BlockPos.z as intmyBlockPos.z
Return Type:
int
z() as int
// BlockPos.z() as int;myBlockPos.z();
Return Type:
int