Class ActionPlanResult
Collects all action plans with the lowest costs.
Inheritance
System.Object
ActionPlanResult
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Mars.Components.Services.Planning
Assembly: Mars.Components.dll
Syntax
public class ActionPlanResult
Methods
| Improve this Doc View SourceAddIfCheapest(IList<IGoapAction>, Single)
Adds an action plan to the list if it is the cheapest so far.
Declaration
public void AddIfCheapest(IList<IGoapAction> actionPlan, float costs)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IList<IGoapAction> | actionPlan | That may be stored |
System.Single | costs | Of the corresponding action plan |
Any()
Indicates that a result exists.
Declaration
public bool Any()
Returns
Type | Description |
---|---|
System.Boolean | true, if any result plan is available, false otherwise |
GetAny()
Provides any of the stored action plans.
Declaration
public IList<IGoapAction> GetAny()
Returns
Type | Description |
---|---|
System.Collections.Generic.IList<IGoapAction> | Any of the cheapest actions plans. An empty list if no action plan is available. |