c8047bd170
add food indicator
22 lines
542 B
C#
22 lines
542 B
C#
using Assets.Scripts.Actions.Interfaces;
|
|
|
|
namespace Assets.Scripts.Actions
|
|
{
|
|
public class Eat : BaseAction, ISellableItem
|
|
{
|
|
public float Price { get; private set; }
|
|
private int _energy;
|
|
public Eat(int duration, int energy, float price) : base(duration)
|
|
{
|
|
Price = price;
|
|
_energy = energy;
|
|
}
|
|
|
|
|
|
public override void ApplyAction(PlayerManager playerController)
|
|
{
|
|
playerController.food.increase(_energy);
|
|
}
|
|
}
|
|
}
|