UNPKG

@minecraft/creator-tools

Version:

Minecraft Creator Tools command line and libraries.

37 lines (36 loc) 914 B
"use strict"; // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. Object.defineProperty(exports, "__esModule", { value: true }); class BlockActor { rootTag; x; y; z; id; isMovable; constructor(rootTagIn) { this.rootTag = rootTagIn; let tag = this.rootTag.find("x"); if (tag !== null) { this.x = tag.valueAsInt; } tag = this.rootTag.find("y"); if (tag !== null) { this.y = tag.valueAsInt; } tag = this.rootTag.find("z"); if (tag !== null) { this.z = tag.valueAsInt; } tag = this.rootTag.find("id"); if (tag !== null) { this.id = tag.valueAsString; } tag = this.rootTag.find("isMovable"); if (tag) { this.isMovable = tag.valueAsBoolean; } } } exports.default = BlockActor;