player can work now
This commit is contained in:
@@ -22,6 +22,7 @@ public class Player : MonoBehaviour
|
||||
private AnimationStates _currentAnimation;
|
||||
|
||||
public Dictionary<StatsId, Stat> Stats;
|
||||
public JobPositions JobPosition { get; set; }
|
||||
|
||||
private readonly Queue<PlayerTasks> _tasks = new Queue<PlayerTasks>();
|
||||
private PlayerTasks _currentTask;
|
||||
@@ -43,6 +44,8 @@ public class Player : MonoBehaviour
|
||||
PlayerPrefs.SetString("lastExitName", string.Empty);
|
||||
Instance = this;
|
||||
Stats = PlayerStats.CreateInitialStats();
|
||||
JobPosition = JobPositions.Unemployed;
|
||||
|
||||
DontDestroyOnLoad(gameObject);
|
||||
}
|
||||
|
||||
@@ -227,6 +230,11 @@ public class Player : MonoBehaviour
|
||||
Stats[StatsId.Money].deduct(amount);
|
||||
}
|
||||
|
||||
public void AddMoney(float amount)
|
||||
{
|
||||
Stats[StatsId.Money].increase(amount);
|
||||
}
|
||||
|
||||
public void SetContainerItem(ContainerItem containerItem)
|
||||
{
|
||||
containerItem.transform.parent = _holdPoint;
|
||||
|
||||
Reference in New Issue
Block a user