20 lines
446 B
C#
20 lines
446 B
C#
|
|
using UnityEngine;
|
||
|
|
|
||
|
|
namespace Rokojori
|
||
|
|
{
|
||
|
|
|
||
|
|
// There is no inventory/object system yet, so "having an object" is modelled
|
||
|
|
// as a GameStateBoolVariable flag until one exists.
|
||
|
|
[CreateAssetMenu( menuName = "Rokojori/Dialog/Conditions/Has Object" )]
|
||
|
|
public class HasObject : GameStateCondition
|
||
|
|
{
|
||
|
|
public GameStateBoolVariable variable = null;
|
||
|
|
|
||
|
|
public override bool Evaluate()
|
||
|
|
{
|
||
|
|
return GameStateManager.instance.GetValue( variable );
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|