-
- All Implemented Interfaces:
-
it.unibo.alchemist.model.interfaces.Action,java.io.Serializable
public final class HeadTowardTarget<T extends Object> extends AbstractAction<T>
Reads the target's absolute coordinates from the target molecule contained in node and sets the node's heading accordingly.
-
-
Constructor Summary
Constructors Constructor Description HeadTowardTarget(Node<T> node, Physics2DEnvironment<T> environment, Reaction<T> reaction, Molecule target, Double angularSpeedDegrees)HeadTowardTarget(Node<T> node, Physics2DEnvironment<T> environment, Reaction<T> reaction, Molecule target)
-
Method Summary
Modifier and Type Method Description HeadTowardTarget<T>cloneAction(Node<T> node, Reaction<T> reaction)Unitexecute()Sets the heading of the node according to the target molecule. ContextgetContext()-
Methods inherited from class it.unibo.alchemist.model.implementations.actions.HeadTowardTarget
declareDependencyTo, getConcentration, getNode, getOutboundDependencies, nodeContains, removeConcentration, setConcentration, toString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
cloneAction
HeadTowardTarget<T> cloneAction(Node<T> node, Reaction<T> reaction)
-
getContext
Context getContext()
-
-
-
-