import { sendPlayerMessage } from "../../../config";
import { lifesteal } from "../../../lifesteal";
import { Command } from "../../handler";

new Command({
    name: `banghosts`,
    staffOnly: true,
    code({ player, args }) {
        if (!args[0]) return sendPlayerMessage(player, `§aBanghosts is set to §f${lifesteal.get(`banghosts`)}`);

        if (![`true`, `false`].includes(args[0].toLowerCase())) return sendPlayerMessage(player, `§8[§cX§8] §cMust be true or false`);
        lifesteal.set(`banghosts`, args[0].toLowerCase());

        sendPlayerMessage(player, `§8[§a/§8] §aSet ban ghosts to §f${args[0]}`);
    },
});