2019-05-03 18:18:02 +08:00
---
2019-07-09 22:03:58 +08:00
- module_name : command
2020-03-30 17:18:13 +08:00
2019-05-03 18:18:02 +08:00
classes :
- class_name : Response
# - DESCRIPTION ------------------------
doc : >
2020-02-24 20:58:54 +08:00
States the result of executing a command as either the ID of the actor to whom the command was applied to (when succeeded) or an error string (when failed).
2020-09-23 17:53:46 +08:00
actor ID, depending on whether or not the command succeeded. The method __<font color="#7fb800">apply_batch_sync()</font>__ in carla.Client returns a list of these to summarize the execution of a batch.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Actor to whom the command was applied to. States that the command was successful.
2019-05-03 18:18:02 +08:00
- var_name : error
2019-07-01 23:46:27 +08:00
type : str
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
A string stating the command has failed.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : has_error
2020-02-24 20:58:54 +08:00
return : bool
2019-05-03 18:18:02 +08:00
params :
doc : >
2020-04-23 18:40:28 +08:00
Returns <b>True</b> if the command execution fails, and <b>False</b> if it was successful.
2019-05-03 18:18:02 +08:00
# --------------------------------------
- class_name : SpawnActor
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">spawn_actor()</font>__ in carla.World. Spawns an actor into the world based on the blueprint provided and the transform. If a parent is provided, the actor is attached to it.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : transform
2019-07-01 23:46:27 +08:00
type : carla.Transform
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Transform to be applied.
2019-05-03 18:18:02 +08:00
- var_name : parent_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Identificator of the parent actor.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
2019-07-01 23:46:27 +08:00
- def_name : __init__
# --------------------------------------
- def_name : __init__
params :
- param_name : blueprint
type : carla.ActorBlueprint
- param_name : transform
type : carla.Transform
# --------------------------------------
2019-05-03 18:18:02 +08:00
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : blueprint
type : carla.ActorBlueprint
- param_name : transform
type : carla.Transform
- param_name : parent
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2019-05-03 18:18:02 +08:00
# --------------------------------------
- def_name : then
params :
2019-07-01 23:46:27 +08:00
- param_name : command
2020-03-31 07:39:50 +08:00
type : any carla Command
2019-07-01 23:46:27 +08:00
doc : >
2020-03-31 07:39:50 +08:00
a Carla command.
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Links another command to be executed right after. It allows to ease very common flows such as spawning a set of vehicles by command and then using this method to set them to autopilot automatically.
2019-05-03 18:18:02 +08:00
# --------------------------------------
- class_name : DestroyActor
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">destroy()</font>__ in carla.Actor that tells the simulator to destroy this actor. It has no effect if the actor was already destroyed. When executed with __<font color="#7fb800">apply_batch_sync()</font>__ in carla.Client there will be a <b>command.Response</b> that will return a boolean stating whether the actor was successfully destroyed.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2019-08-15 01:44:55 +08:00
Actor affected by the command
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-05-03 18:18:02 +08:00
# --------------------------------------
2021-07-14 16:42:41 +08:00
- class_name : ApplyVehiclePhysicsControl
# - DESCRIPTION ------------------------
doc : >
Command adaptation of __<font color="#7fb800">apply_physics_control()</font>__ in carla.Vehicle. Applies a new physics control to a vehicle,
modifying its physical parameters.
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
Vehicle actor affected by the command.
- var_name : control
type : carla.VehiclePhysicsControl
doc : >
Physics control to be applied.
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or its ID to whom the command will be applied to.
- param_name : control
type : carla.VehiclePhysicsControl
# --------------------------------------
2019-05-03 18:18:02 +08:00
- class_name : ApplyVehicleControl
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">apply_control()</font>__ in carla.Vehicle. Applies a certain control to a vehicle.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Vehicle actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : control
2019-07-01 23:46:27 +08:00
type : carla.VehicleControl
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Vehicle control to be applied.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : control
type : carla.VehicleControl
2019-05-03 18:18:02 +08:00
# --------------------------------------
2020-09-24 18:21:18 +08:00
2019-05-03 18:18:02 +08:00
- class_name : ApplyWalkerControl
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">apply_control()</font>__ in carla.Walker. Applies a control to a walker.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Walker actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : control
2020-02-24 20:58:54 +08:00
type : carla.WalkerControl
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Walker control to be applied.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : control
type : carla.WalkerControl
2019-05-03 18:18:02 +08:00
# --------------------------------------
- class_name : ApplyTransform
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_transform()</font>__ in carla.Actor. Sets a new transform to an actor.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : transform
2019-07-01 23:46:27 +08:00
type : carla.Transform
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Transformation to be applied.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : transform
type : carla.Transform
2019-05-03 18:18:02 +08:00
# --------------------------------------
2019-07-06 00:55:26 +08:00
- class_name : ApplyWalkerState
# - DESCRIPTION ------------------------
doc : >
2020-02-24 20:58:54 +08:00
Apply a state to the walker actor. Specially useful to initialize an actor them with a specific location, orientation and speed.
2019-07-06 00:55:26 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
2020-02-24 20:58:54 +08:00
Walker actor affected by the command.
2019-07-06 00:55:26 +08:00
- var_name : transform
type : carla.Transform
doc : >
2020-02-24 20:58:54 +08:00
Transform to be applied.
2019-07-06 00:55:26 +08:00
- var_name : speed
type : float
2020-09-14 22:58:48 +08:00
var_units : m/s
2019-07-06 00:55:26 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Speed to be applied.
2019-07-06 00:55:26 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-06 00:55:26 +08:00
- param_name : transform
type : carla.Transform
- param_name : speed
type : float
2020-09-14 22:58:48 +08:00
param_units : m/s
2019-07-06 00:55:26 +08:00
# --------------------------------------
2020-09-23 18:06:22 +08:00
- class_name : ApplyTargetVelocity
2019-05-03 18:18:02 +08:00
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_target_velocity()</font>__ in carla.Actor.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2019-08-15 01:44:55 +08:00
Actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : velocity
2019-07-01 23:46:27 +08:00
type : carla.Vector3D
2020-09-14 22:58:48 +08:00
var_units : m/s
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
The 3D velocity applied to the actor.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : velocity
type : carla.Vector3D
2020-09-24 18:21:18 +08:00
param_units : m/s
2020-09-23 17:53:46 +08:00
doc : >
Velocity vector applied to the actor.
2019-05-03 18:18:02 +08:00
# --------------------------------------
2020-09-23 18:06:22 +08:00
- class_name : ApplyTargetAngularVelocity
2019-05-03 18:18:02 +08:00
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_target_angular_velocity()</font>__ in carla.Actor. Sets the actor's angular velocity vector.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : angular_velocity
2019-07-01 23:46:27 +08:00
type : carla.Vector3D
2020-09-17 04:28:30 +08:00
var_units : deg/s
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
The 3D angular velocity that will be applied to the actor.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : angular_velocity
type : carla.Vector3D
2020-09-17 04:28:30 +08:00
param_units : deg/s
2020-09-23 17:53:46 +08:00
doc : >
Angular velocity vector applied to the actor.
2019-05-03 18:18:02 +08:00
# --------------------------------------
- class_name : ApplyImpulse
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">add_impulse()</font>__ in carla.Actor. Applies an impulse to an actor.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : impulse
2019-07-01 23:46:27 +08:00
type : carla.Vector3D
2020-09-17 19:10:57 +08:00
var_units : N *s
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Impulse applied to the actor.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : impulse
type : carla.Vector3D
2020-09-17 19:10:57 +08:00
param_units : N *s
2019-05-03 18:18:02 +08:00
# --------------------------------------
2020-09-24 05:32:23 +08:00
- class_name : ApplyForce
2020-05-04 16:37:09 +08:00
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">add_force()</font>__ in carla.Actor. Applies a force to an actor.
2020-05-04 16:37:09 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
Actor affected by the command.
2020-09-24 05:32:23 +08:00
- var_name : force
type : carla.Vector3D
doc : >
Force applied to the actor over time.
2020-09-24 18:21:18 +08:00
var_units : N
2020-09-24 05:32:23 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or its ID to whom the command will be applied to.
- param_name : force
type : carla.Vector3D
2020-09-24 18:21:18 +08:00
param_units : N
2020-09-24 05:32:23 +08:00
# --------------------------------------
- class_name : ApplyAngularImpulse
# - DESCRIPTION ------------------------
doc : >
Command adaptation of __<font color="#7fb800">add_angular_impulse()</font>__ in carla.Actor. Applies an angular impulse to an actor.
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
Actor affected by the command.
2020-05-04 16:37:09 +08:00
- var_name : impulse
type : carla.Vector3D
2020-09-24 18:21:18 +08:00
var_units : degrees*s
2020-05-04 16:37:09 +08:00
doc : >
2020-09-24 05:32:23 +08:00
Angular impulse applied to the actor.
2020-05-04 16:37:09 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or its ID to whom the command will be applied to.
- param_name : impulse
type : carla.Vector3D
2020-09-24 18:21:18 +08:00
param_units : degrees*s
2020-05-04 16:37:09 +08:00
# --------------------------------------
2020-09-24 05:32:23 +08:00
- class_name : ApplyTorque
# - DESCRIPTION ------------------------
doc : >
Command adaptation of __<font color="#7fb800">add_torque()</font>__ in carla.Actor. Applies a torque to an actor.
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
Actor affected by the command.
- var_name : torque
type : carla.Vector3D
doc : >
Torque applied to the actor over time.
2020-09-24 18:21:18 +08:00
var_units : degrees
2020-09-24 05:32:23 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or its ID to whom the command will be applied to.
- param_name : torque
type : carla.Vector3D
2020-09-24 18:21:18 +08:00
param_units : degrees
2020-09-24 05:32:23 +08:00
# --------------------------------------
2019-05-03 18:18:02 +08:00
- class_name : SetSimulatePhysics
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_simulate_physics()</font>__ in carla.Actor. Determines whether an actor will be affected by physics or not.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
Actor affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : enabled
2019-07-01 23:46:27 +08:00
type : bool
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
If physics should be activated or not.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : enabled
type : bool
2019-05-03 18:18:02 +08:00
# --------------------------------------
- class_name : SetAutopilot
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_autopilot()</font>__ in carla.Vehicle. Turns on/off the vehicle's autopilot mode.
2019-05-03 18:18:02 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
2019-07-01 23:46:27 +08:00
type : int
2019-05-03 18:18:02 +08:00
doc : >
2019-08-15 01:44:55 +08:00
Actor that is affected by the command.
2019-05-03 18:18:02 +08:00
- var_name : enabled
2019-07-01 23:46:27 +08:00
type : bool
2019-05-03 18:18:02 +08:00
doc : >
2020-02-24 20:58:54 +08:00
If autopilot should be activated or not.
2020-04-23 18:40:28 +08:00
- var_name : port
type : uint16
2020-04-09 20:24:38 +08:00
doc : >
2020-04-23 18:40:28 +08:00
Port of the Traffic Manager where the vehicle is to be registered or unlisted.
2019-05-03 18:18:02 +08:00
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
2019-07-01 23:46:27 +08:00
- param_name : actor
2019-07-03 22:18:21 +08:00
type : carla.Actor or int
2020-02-24 20:58:54 +08:00
doc : >
Actor or its ID to whom the command will be applied to.
2019-07-01 23:46:27 +08:00
- param_name : enabled
type : bool
2020-04-23 18:40:28 +08:00
- param_name : port
type : uint16
default : 8000
2020-04-09 20:24:38 +08:00
doc : >
2020-04-23 18:40:28 +08:00
The Traffic Manager port where the vehicle is to be registered or unlisted. If __None__ is passed, it will consider a TM at default port `8000`.
2019-05-03 18:18:02 +08:00
# --------------------------------------
2020-05-27 21:31:28 +08:00
- class_name : SetVehicleLightState
# - DESCRIPTION ------------------------
doc : >
2020-09-24 05:32:23 +08:00
Command adaptation of __<font color="#7fb800">set_light_state()</font>__ in carla.Vehicle. Sets the light state of a vehicle.
2020-05-27 21:31:28 +08:00
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : int
doc : >
Actor that is affected by the command.
- var_name : light_state
type : carla.VehicleLightState
doc : >
Defines the light state of a vehicle.
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or its ID to whom the command will be applied to.
- param_name : light_state
type : carla.VehicleLightState
doc : >
Recaps the state of the lights of a vehicle, these can be used as a flags.
# --------------------------------------
2021-07-29 22:21:02 +08:00
- class_name : SetEnableGravity
# - DESCRIPTION ------------------------
doc : >
Command adaptation of __<font color="#7fb800">set_enable_gravity()</font>__ in carla.Actor. Enables or disables gravity on an actor.
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : carla.Actor or int
doc : >
Actor that is affected by the command.
- var_name : enabled
type : bool
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or Actor ID to which the command will be applied to.
- param_name : enabled
type : bool
# --------------------------------------
- class_name : ShowDebugTelemetry
# - DESCRIPTION ------------------------
doc : >
Command adaptation of __<font color="#7fb800">show_debug_telemetry()</font>__ in carla.Actor. Displays vehicle control telemetry data.
# - PROPERTIES -------------------------
instance_variables :
- var_name : actor_id
type : carla.Actor or int
doc : >
Actor that is affected by the command.
- var_name : enabled
type : bool
# - METHODS ----------------------------
methods :
- def_name : __init__
params :
- param_name : actor
type : carla.Actor or int
doc : >
Actor or Actor ID to which the command will be applied to.
- param_name : enabled
type : bool
# --------------------------------------
2019-05-03 18:18:02 +08:00
...