package com.loganmagnan.eventcore.menusystem;

import com.loganmagnan.eventcore.utils.ColorUtils;
import com.loganmagnan.eventcore.utils.ItemBuilder;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import lombok.Setter;
import org.bukkit.Material;
import org.bukkit.inventory.ItemStack;

import java.util.List;

@Getter
@Setter
@AllArgsConstructor
@RequiredArgsConstructor
public class ItemStackButton {

    private String name;
    private List<String> lore;
    private Material material;
    private int data;
    private int amount;

    public ItemStack makeItemStack() {
        return new ItemBuilder(this.material).name(ColorUtils.getMessageType(this.name)).lore(ColorUtils.getMessageType(this.lore)).durability(this.data).amount(this.amount).build();
    }
}
