using System; using System.Collections.Generic; using Goap.Agent.Core; namespace Goap.Core { public interface IWorldData { Dictionary> States { get; } Dictionary> Targets { get; } ITarget GetTarget(IGoapAction action); void SetState(IWorldKey key, int state); void SetState(Type key, int state); void SetState(int state) where TKey : IWorldKey; //void SetTarget(ITargetKey key, ITarget target); void SetTarget(Type key, ITarget target); void SetTarget(ITarget target) where TKey : ITargetKey; bool IsTrue(Comparison comparison, int value); bool IsTrue(IWorldKey worldKey, Comparison comparison, int value); (bool Exists, int Value) GetWorldValue(TKey worldKey) where TKey : IWorldKey; (bool Exists, int Value) GetWorldValue(Type worldKey); ITarget GetTargetValue(Type targetKey); IWorldDataState GetTargetState(Type targetKey); IWorldDataState GetWorldState(Type worldKey); } public interface IWorldDataState { public bool IsLocal { get; } public Type Key { get; } public T Value { get; set; } public ITimer Timer { get; } } }