"use strict";
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
Object.defineProperty(exports, "__esModule", { value: true });
class AttributeComponent {
    id;
    base;
    current;
    minimum;
    maximum;
    defaultMinimum;
    defaultMaximum;
    loadFromNbtTag(tag) {
        const minTag = tag.find("Min");
        if (minTag !== null) {
            this.minimum = minTag.valueAsFloat;
        }
        const maxTag = tag.find("Max");
        if (maxTag !== null) {
            this.maximum = maxTag.valueAsFloat;
        }
        let dminTag = tag.find("DefaultMin");
        if (dminTag !== null) {
            this.defaultMinimum = dminTag.valueAsFloat;
        }
        const dmaxTag = tag.find("DefaultMax");
        if (dmaxTag !== null) {
            this.defaultMaximum = dmaxTag.valueAsFloat;
        }
        const baseTag = tag.find("Base");
        if (baseTag !== null) {
            this.base = baseTag.valueAsFloat;
        }
        const currentTag = tag.find("Current");
        if (currentTag !== null) {
            this.current = currentTag.valueAsFloat;
        }
    }
}
exports.default = AttributeComponent;

//# sourceMappingURL=../../maps/minecraft/components/FloatAttributeComponent.js.map
