package org.project.item.consumables;
import org.project.entity.Entity;
import org.project.item.Item;

// TODO: UPDATE IMPLEMENTATION
public abstract class Consumable implements Item {
    /*
    TODO: ADD OTHER REQUIRED AND BONUS METHODS
    */
    // Base economic value for all consumables
    protected int value;

    //To initialize consumable value
    public Consumable(int value) {
        this.value = value;
    }

    // Shared implementation of getValue for all consumables
    @Override
    public int getValue() {
        return value;
    }

    /*
     * Abstract methods force subclasses to define their own identity and behavior.
     */
    @Override
    public abstract String getName();

    @Override
    public abstract String getDescription();

    @Override
    public abstract void use(Entity target);
}
