matrx.actions.object_actions.GrabObjectResult¶
-
class
GrabObjectResult
(result, succeeded)¶ ActionResult for a GrabObjectAction
The results uniquely for GrabObjectAction are (as class constants):
RESULT_SUCCESS: When the object can be successfully grabbed.
RESULT_NO_OBJECT: When object_id is not given.
RESULT_CARRIES_OBJECT: When the agent already carries the maximum nr. objects.
NOT_IN_RANGE: When object_id not within range.
RESULT_AGENT: If the object_id is that of an agent.
RESULT_OBJECT_CARRIED: When the object is already carried by another agent.
RESULT_OBJECT_UNMOVABLE: When the object is not movable.
RESULT_UNKNOWN_OBJECT_TYPE: When the object_id does not exists in the
matrx.grid_world.GridWorld
.FAILED_TO_REMOVE_OBJECT_FROM_WORLD: When the grabbed object cannot be removed from the
matrx.grid_world.GridWorld
.
- Parameters
- resultstr
A string representing the reason for a
matrx.actions.object_actions.GrabObjectAction
(expected) success or fail.- succeededbool
A boolean representing the (expected) success or fail of a
matrx.actions.object_actions.GrabObjectAction
.
See also
GrabObjectAction
-
__init__
(self, result, succeeded)¶ Initialize self. See help(type(self)) for accurate signature.
Methods
__init__
(self, result, succeeded)Initialize self.
Attributes
Result when the specified object is not within range.
Result when the specified object is an agent.
NO_ACTION_GIVEN
Result when no object was specified.
Result when the specified object is already carried by another agent.
Result when the agent is at its maximum carrying capacity.
Result when the specified object does not exist in the
matrx.grid_world.GridWorld
RESULT_OBJECT_UNMOVABLE
Result when the grabbed object cannot be removed from the
matrx.grid_world.GridWorld
.Result when the specified object is not movable.