import { system } from "@minecraft/server";
import { sendPlayerMessage } from "../../../config";
import { lifesteal } from "../../../lifesteal";
import { Command } from "../../handler";


new Command({
    name: `startamount`,
    staffOnly: true,
    code({ player, args }) {
        let amount = +args[0];
        if (isNaN(amount) || amount < 5 || amount > 15) return sendPlayerMessage(player, `§8[§cX§8] §cYou can only set the start amount to numbers from 5-15!`);

        lifesteal.set(`startamount`, `${amount}`);
        sendPlayerMessage(player, `§8[§a/§8] §aSet the start amount to ${amount}`);
    },
});