UNPKG

mdkjs

Version:

mdk is a framework for developing Datapacks for Minecraft. It uses the typescript language.

35 lines (34 loc) 1.12 kB
import { RotationModifier } from 'mdk-nbt'; export declare function rotation(): Rotation; export declare function rotation(text: string): Rotation; export declare function rotation(x: number, y: number): Rotation; /** * 旋转类 */ export declare class Rotation { /** x */ x: number; /** y */ y: number; static east: number; static south: number; static west: number; static north: number; static copy(rotation: Rotation): Rotation; constructor(); constructor(text: string); constructor(x: number, y: number); merge(rotation: Rotation): Rotation; merge(offset: [number, number]): Rotation; translate(rotation: Rotation): Rotation; translate(offset: number): Rotation; translate(offset: [number, number]): Rotation; multiply(matrix: number): Rotation; multiply(matrix: [number, number]): Rotation; getOffset(rotation: Rotation): number[]; toArray(): [number, number]; toString(modifier?: RotationModifier): string; toRelative(): string; toAbsolute(): string; toNbtString(): string; }