public override IReGoapActionSettings GetSettings(ReGoapState goalState) { settings = new GenericGoToSettings { ObjectivePosition = GetWantedPositionFromState(goalState) }; return(base.GetSettings(goalState)); }
public override IReGoapActionSettings <string, object> GetSettings(IReGoapAgent <string, object> goapAgent, ReGoapState <string, object> goalState) { settings = new GenericGoToSettings { ObjectivePosition = GetWantedPositionFromState(goalState) }; return(base.GetSettings(goapAgent, goalState)); }
public override void Run(IReGoapActionSettings settings, Action <ReGoapAction> done, Action <ReGoapAction> fail) { base.Run(settings, done, fail); GenericGoToSettings localSettings = (GenericGoToSettings)settings; if (localSettings.ObjectivePosition.HasValue) { smsGoto.GoTo(localSettings.ObjectivePosition, OnDoneMovement, OnFailureMovement); } else { failCallback(this); } }