24 lines
513 B
C#
24 lines
513 B
C#
using Unity.VisualScripting;
|
|
using UnityEngine;
|
|
|
|
public class GetTreated : AI_Action
|
|
{
|
|
public override bool PrePerform()
|
|
{
|
|
target = inventory.FindItemWithTag("Bed");
|
|
if(target == null)
|
|
return false;
|
|
return true;
|
|
}
|
|
|
|
public override bool PostPerform()
|
|
{
|
|
AI_World.Instance.GetWorld().ModifyState("Treated", 1);
|
|
agentWorldStates.ModifyState("IsCured", 1);
|
|
inventory.RemoveItem(target);
|
|
|
|
|
|
return true;
|
|
}
|
|
}
|