• MARS Website
  • Core API
  • SmartOpenHamburg API
  • Model Components API
  • Common API
Show / Hide Table of Contents
  • Mars.Components
    • DependencyRegistrationModelling
  • Mars.Components.Agents
    • AbstractAgent
    • AbstractEntity
    • Agent
  • Mars.Components.Environments
    • AbstractEnvironment
    • AbstractGraphElement
    • AlwaysPassingNodeGuard
    • EntityLane<TEntity>
    • GeoEnvironment
    • GeoHashEnvironment<T>
    • IEnvironmentMediator
    • IModalChoiceResolver
    • PathHeuristics
    • SpatialEdge
    • SpatialGraphEntityExtensions
    • SpatialGraphEnvironment
    • SpatialGraphHelper
    • SpatialHashEnvironment<TEntity>
    • SpatialLane
    • SpatialNode
    • WorldIndexExtensions
  • Mars.Components.Environments.Cartesian
    • CartesianEnvironment<TEntity>
    • CollisionEnvironment<TCharacter, TObstacle>
    • CollisionKind
    • ConeExplorationView
    • ExplorationView
    • GeometryFactory
    • ICartesianEnvironment<TEntity>
    • ICharacter
    • ICollidable
    • ICollisionEnvironment<TCharacter, TObstacle>
    • IObstacle
    • IVisible
    • RayExplorationView
    • TrapezoidExploration
    • VisibilityKind
  • Mars.Components.Environments.Cartesian.Routing
    • CartesianRoutingService<TObstacle>
    • GeometryCoordinatesRoutingPointsGenerator
    • HomogenousRoutingPointsGenerator
    • IRoutingPointsGenerator
    • RandomRoutingPointsGenerator
    • SectionalRandomRoutingPointsGenerator
  • Mars.Components.Layers
    • AbstractActiveLayer
    • AbstractEnvelopedLayer
    • AbstractLayer
    • AbstractVectorFeature
    • AgentSchedulerLayer<TAgent, TLayer>
    • QuerySourceLoader
    • RasterLayer
    • SchedulerEntry
    • SchedulerLayer
    • VectorFeature
    • VectorLayer
    • VectorLayer<T>
    • VectorLayerHelper
  • Mars.Components.Layers.Temporal
    • IQueryFieldProvider
    • ITemporalObjectCatalog
    • ITemporalObjectIterator
    • TemporalCatalogFeature<TKey>
    • TemporalFeatureKind
    • TemporalMetadataLoader
  • Mars.Components.Services
    • AgentManager
  • Mars.Components.Services.Explorations
    • BoltzmannExploration
    • EpsilonGreedyExploration
    • IExplorationPolicy
    • RouletteWheelExploration
    • TabuSearchExploration
  • Mars.Components.Services.Learning
    • InfiniteQLearning
    • QLearning
    • Sarsa
  • Mars.Components.Services.Planning
    • ActionPlanResult
    • GoapAction
    • GoapAgentStates
    • GoapGoal
    • GoapPlanner
    • GoapStateKey<T>
    • GoapStateProperty
    • GoapStateProperty<TElement>
    • IGoapAction
    • IGoapAgentStates
    • IGoapGoal
    • IGoapPlanner
    • IGoapStateKey
    • StatesCommons
  • Mars.Components.Services.Planning.ActionCommons
    • AllGoalsSatisfiedAction
    • NoGoalReachableAction
  • Mars.Components.Starter
    • Command
    • CommandArgumentContainer
    • CommandParser
    • CommandSet
    • HelpCommand
    • Option
    • OptionContext
    • OptionException
    • OptionSet
    • OptionValueCollection
    • OptionValueType
    • SimulationStarter
  • Mars.Components.Starter.Exceptions
    • SimulationStartupException
  • Mars.Interfaces
    • IModelObject
    • ISimulationContainer
    • ISimulationContext
    • ISimulationModule
    • ISimulationState
    • IStepExecutionContext
    • SimulationContext
    • SimulationContext.WorkflowStateType
    • StepExecutionContext
  • Mars.Interfaces.Agents
    • IAgent
    • IAgent<TLayer>
    • IEntity
    • IMarsDslAgent
    • IModalCapabilitiesAgent
    • ISpatialGraphEntity
    • ITickClient
  • Mars.Interfaces.Annotations
    • ActiveConstructor
    • PropertyDescription
  • Mars.Interfaces.Data
    • AbstractDomainData
    • GeometryData
    • IDomainData
    • IGeometryData
    • IIdentifiableData
    • IMarsFeature
    • IRasterBandData
    • ISource
    • IStringData
    • IStringStructuredData
    • IStructuredData
    • IStructuredDataGeometry
    • IValueData
    • LayerInitData
    • RasterBandData
    • StringDataDto
    • StructuredData
    • VectorStructuredData
  • Mars.Interfaces.Environments
    • BoundingBox
    • DirectionType
    • EdgeExploreResult
    • EdgeStop
    • ExploreDirection
    • GeoPositionExtension
    • HighwayType
    • IEdge<TEdge, TNode>
    • IEntityLane<TEntity>
    • IEnvironment
    • IEnvironment<TEntity>
    • IGeoGridEnvironment<T>
    • IGraphEntity
    • IGraphEnvironment<TEdge, TNode>
    • INode<TEdge, TNode>
    • INodeGuard
    • IPositionable
    • IRoutePlanner
    • ISpatialEdge
    • ISpatialGraphEnvironment
    • ISpatialLane
    • ISpatialNode
    • LaneExploreResult
    • ModalChoice
    • MultimodalRoute
    • NodeIntegrationKind
    • Position
    • Route
    • RouteStop
    • Size
    • SpatialGraphExploreResult
    • SpatialModalityType
    • TrafficLightPhase
  • Mars.Interfaces.Layers
    • FinallySimulationStep
    • IChangingLayer
    • IDataContainer
    • IDataLayer
    • IDataSet
    • IEnvelopDataLayer
    • ILayer
    • IMarsDslLayer
    • IModalChoiceConsumer
    • InitSimulationStep
    • INotifyChangedSource<T>
    • IRaster<TValue>
    • IRasterLayer
    • ISteppedActiveLayer
    • IVectorFeature
    • IVectorLayer
    • IVectorLayer<T>
    • IVectorNode<TEntity>
    • RegisterAgent
    • UnregisterAgent
  • Mars.Interfaces.Model
    • ActiveTypeMapping
    • AgentMapping
    • AgentType
    • ConstructorType
    • ContainsOperator
    • DataContainer
    • DataType
    • EntityMapping
    • EntityType
    • Execution
    • FeatureType
    • Globals
    • IdentifiableElement
    • IndividualMapping
    • Input
    • InputConfiguration
    • LayerMapping
    • LayerType
    • ModelDescription
    • ModelElement
    • ObjectType
    • Output
    • OutputConfiguration
    • OutputFilter
    • OutputKind
    • OutputTargetType
    • ParameterMapping
    • Processing
    • ProcessingConfiguration
    • ProcessingTargetType
    • PropertyType
    • SimulationConfig
    • TimeSpanUnit
    • TimeSpanUnitExtensions
    • TypeElement
    • TypeMapping
  • Mars.Interfaces.Model.Converters
    • CultureConverter
    • SerializationTypeConverter
    • TimeSpanUnitConverter
  • Mars.Interfaces.Model.Exceptions
    • InvalidTypeException
    • MissingTypeException
  • Mars.Interfaces.Model.Options
    • AbstractEndpointOptions
    • AbstractFileOptions
    • AbstractOptions
    • AscOptions
    • CsvOptions
    • GeoJsonOptions
    • MongoOptions
    • MqttOptions
    • PostgresSqlOptions
    • RedisOptions
    • RelationalEndpointOptions
    • SerializationType
    • SocketOutputOptions
    • SpatialGraphOptions
    • SqLiteOptions
    • TripsOptions

Class GoapAction

Inheritance
System.Object
GoapAction
AllGoalsSatisfiedAction
NoGoalReachableAction
Implements
IGoapAction
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 abstract class GoapAction : IGoapAction

Constructors

| Improve this Doc View Source

GoapAction(IGoapAgentStates, Single)

Declaration
protected GoapAction(IGoapAgentStates agentStates, float cost = 0F)
Parameters
Type Name Description
IGoapAgentStates agentStates
System.Single cost

Properties

| Improve this Doc View Source

Cost

Declaration
public float Cost { get; protected set; }
Property Value
Type Description
System.Single
| Improve this Doc View Source

Effects

Declaration
public IDictionary<IGoapStateKey, GoapStateProperty> Effects { get; }
Property Value
Type Description
System.Collections.Generic.IDictionary<IGoapStateKey, GoapStateProperty>
| Improve this Doc View Source

Preconditions

Declaration
public IDictionary<IGoapStateKey, GoapStateProperty> Preconditions { get; }
Property Value
Type Description
System.Collections.Generic.IDictionary<IGoapStateKey, GoapStateProperty>

Methods

| Improve this Doc View Source

AddOrUpdateEffect(GoapStateProperty)

Declaration
public void AddOrUpdateEffect(GoapStateProperty effect)
Parameters
Type Name Description
GoapStateProperty effect
| Improve this Doc View Source

AddOrUpdateEffect<T>(GoapStateKey<T>, T)

Adds an effect to this action or updates an existing effect with the same key.
Declaration
public void AddOrUpdateEffect<T>(GoapStateKey<T> key, T value)
Parameters
Type Name Description
GoapStateKey<T> key Identifies the state property.
T value The specific manifestation of this state.
Type Parameters
Name Description
T The type of value.
| Improve this Doc View Source

AddOrUpdateEffect<T>(KeyValuePair<GoapStateKey<T>, T>)

Adds an effect to this action or updates an existing effect with the same key.
Declaration
public void AddOrUpdateEffect<T>(KeyValuePair<GoapStateKey<T>, T> kvp)
Parameters
Type Name Description
System.Collections.Generic.KeyValuePair<GoapStateKey<T>, T> kvp Identifies the state property.
Type Parameters
Name Description
T The type of value.
| Improve this Doc View Source

AddOrUpdatePrecondition(GoapStateProperty)

Declaration
public void AddOrUpdatePrecondition(GoapStateProperty precondition)
Parameters
Type Name Description
GoapStateProperty precondition
| Improve this Doc View Source

AddOrUpdatePrecondition<T>(GoapStateKey<T>, T)

Adds a precondition to this action or updates an existing precondition with the same key.
Declaration
public void AddOrUpdatePrecondition<T>(GoapStateKey<T> key, T value)
Parameters
Type Name Description
GoapStateKey<T> key Identifies the state property.
T value The specific manifestation of this state.
Type Parameters
Name Description
T The type of value.
| Improve this Doc View Source

AddOrUpdatePrecondition<T>(KeyValuePair<GoapStateKey<T>, T>)

Adds a precondition to this action or updates an existing precondition with the same key.
Declaration
public void AddOrUpdatePrecondition<T>(KeyValuePair<GoapStateKey<T>, T> kvp)
Parameters
Type Name Description
System.Collections.Generic.KeyValuePair<GoapStateKey<T>, T> kvp Identifies the state property.
Type Parameters
Name Description
T The type of value.
| Improve this Doc View Source

Execute()

Declaration
public bool Execute()
Returns
Type Description
System.Boolean
| Improve this Doc View Source

ExecuteAction()

Simply executes the specific action code, without GOAP overhead organization.
Declaration
protected abstract bool ExecuteAction()
Returns
Type Description
System.Boolean True, if the action instructions were successful, false otherwise
| Improve this Doc View Source

RemoveEffect(GoapStateProperty)

Declaration
public void RemoveEffect(GoapStateProperty effect)
Parameters
Type Name Description
GoapStateProperty effect
| Improve this Doc View Source

RemoveEffect(IGoapStateKey)

Removes an effect with given key.
Declaration
public void RemoveEffect(IGoapStateKey effectKey)
Parameters
Type Name Description
IGoapStateKey effectKey Identifies the effect that should be removed.
| Improve this Doc View Source

RemovePrecondition(GoapStateProperty)

Declaration
public void RemovePrecondition(GoapStateProperty precondition)
Parameters
Type Name Description
GoapStateProperty precondition
| Improve this Doc View Source

RemovePrecondition(IGoapStateKey)

Removes a precondition with given key.
Declaration
public void RemovePrecondition(IGoapStateKey preconditionKey)
Parameters
Type Name Description
IGoapStateKey preconditionKey Identifies the precondition that should be removed.
| Improve this Doc View Source

UpdateCost()

Declaration
public virtual void UpdateCost()

Implements

IGoapAction

Extension Methods

Serializer.Save<T>(T, out Byte[], SerializerCompression)
Serializer.Save<T>(T, Stream, SerializerCompression)
Serializer.Save<T>(T, BinaryFormatter, Stream, SerializerCompression)
Serializer.Save<T>(T, String, SerializerCompression)
Serializer.Save<T>(T, String)
Matrix.Concatenate<T>(T, T[])
Matrix.Replace<T>(T, Object, Object)
DomainDataImporter.Import(Object, InputConfiguration)
ObjectSerialize.Serialize(Object)
Matrix.IsEqual(Object, Object, Decimal, Decimal)
  • Improve this Doc
  • View Source
In This Article
Back to top Copyright © MARS GROUP. HAW Hamburg