The routes module
Overview
API: routes
RouteCommsFocus
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteCommsFocus
@label
def handle_comms_focus():
....
yield PollResults.OK_YIELD
RouteCommsMessage
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteCommsMessage
@label
def handle_comms_message():
....
yield PollResults.OK_YIELD
RouteCommsSelect
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteCommsSelect
@label
def handle_comms_select():
....
yield PollResults.OK_YIELD
RouteDamageDestroy
Bases: RouteLifetime
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDestroy
@label
def handle_destroy():
....
yield PollResults.OK_YIELD
RouteDamageHeat
Bases: RouteDamageSource
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDamageHeat
@label
def handle_damage_heat():
....
yield PollResults.OK_YIELD
RouteDamageInternal
Bases: RouteDamageSource
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDamageInternal
@label
def handle_damage_internal():
....
yield PollResults.OK_YIELD
RouteDamageKilled
Bases: RouteLifetime
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDestroy
@label
def handle_destroy():
....
yield PollResults.OK_YIELD
RouteDamageObject
Bases: RouteDamageSource
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDamageObject
@label
def handle_damage_object():
....
yield PollResults.OK_YIELD
RouteDockHangar
Bases: RouteLifetime
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteDockHangar
@label
def handle_dock():
....
yield PollResults.OK_YIELD
RouteGridFocus
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteGridFocus
@label
def handle_grid_focus():
....
yield PollResults.OK_YIELD
RouteGridMessage
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteGridMessage
@label
def handle_grid_message():
....
yield PollResults.OK_YIELD
RouteGridPoint
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteGridPoint
@label
def handle_grid_point():
....
yield PollResults.OK_YIELD
RouteGridSelect
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteGridSelect
@label
def handle_grid_select():
....
yield PollResults.OK_YIELD
RouteGridSpawn
Bases: RouteLifetime
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteGridSpawn
@label
def handle_grid_spawn():
....
yield PollResults.OK_YIELD
RouteScienceFocus
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteScienceFocus
@label
def handle_science_focus():
....
yield PollResults.OK_YIELD
RouteScienceMessage
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteScienceMessage
@label
def handle_science_message():
....
yield PollResults.OK_YIELD
RouteSciencePoint
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteSciencePoint
@label
def handle_science_point():
....
yield PollResults.OK_YIELD
RouteScienceSelect
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteScienceSelect
@label
def handle_science_select():
....
yield PollResults.OK_YIELD
RouteSpawn
Bases: RouteLifetime
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteSpawn
@label
def handle_spawn():
....
yield PollResults.OK_YIELD
RouteWeaponsFocus
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteWeaponsFocus
@label
def handle_weapons_focus():
....
yield PollResults.OK_YIELD
RouteWeaponsPoint
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteWeaponsPoint
@label
def handle_weapons_point():
....
yield PollResults.OK_YIELD
RouteWeaponsSelect
Bases: RouteConsole
decorator for routing to a python function or python class method
Note
The route is expected to be a label
Example
@RouteWeaponsSelect
@label
def handle_weapons_select():
....
yield PollResults.OK_YIELD
follow_route_select_comms(origin_id, selected_id)
cause the comms selection route to execute
Parameters:
Name | Type | Description | Default |
---|---|---|---|
origin_id
|
agent
|
The agent id of the player ship |
required |
selected_id
|
agent
|
The agent id of the target space object |
required |
follow_route_select_grid(origin_id, selected_id)
cause the engineering grid selection route to execute
Parameters:
Name | Type | Description | Default |
---|---|---|---|
origin_id
|
agent
|
The agent id of the player ship |
required |
selected_id
|
agent
|
The agent id of the target grid object |
required |
follow_route_select_science(origin_id, selected_id)
cause the science selection route to execute
Parameters:
Name | Type | Description | Default |
---|---|---|---|
origin_id
|
agent
|
The agent id of the player ship |
required |
selected_id
|
agent
|
The agent id of the target space object |
required |
route_change_console(label)
called when a change console button is pressed.
Note
Typically this redirects the console gui to a console selection gui.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_collision_interactive(label)
called when a space_object takes a collision.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_collision_passive(label)
called when a space_object takes a collision.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_comms_navigate(path, label)
called to extend a comms navigation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
path
|
(str): The navigation path to extend |
required | |
label
|
label
|
The label to run |
required |
route_console_mainscreen_change(label)
called when a change to the main screen view occurs
Note
Typically this redirects the console gui to a gui_console
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_damage_destroy(label)
called when a space_object is destroyed.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_damage_heat(label)
called when a player ship takes heat damage.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_damage_internal(label)
called when a player ship takes internal damage.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_damage_killed(label)
called when a space_object is about to be removed from the engine.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_damage_object(label)
called when a space_object takes hull damage.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_dock_hangar(label)
called when a space_object docks.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_comms(label)
called when comms changes selection.
Note
The label called should not be long running. Use route_select_comms for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_comms_2d(label)
called when comms changes selection.
Note
The label called should not be long running. Use route_select_comms for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_grid(label)
called when engineering grid changes selection.
Note
The label called should not be long running. Use route_select_grid for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_normal(label)
called when comms changes selection.
Note
The label called should not be long running. Use route_select_comms for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_science(label)
called when science changes selection.
Note
The label called should not be long running. Use route_select_science for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_focus_weapons(label)
called when weapons changes selection.
Note
The label called should not be long running. Use route_select_weapons for long running tasks.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_gui_navigate(path, label)
called to extend a gui navigation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
path
|
(str): The navigation path to extend |
required | |
label
|
label
|
The label to run |
required |
route_message_science(label)
called when science changes selection.
Note
Typically used to run a task that uses an await scan
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_object_grid(label)
called when a grid object event occurs. i.e. grid object reached a location.
Note
Typically not a long running task
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_comms(label)
called when a a point event occurs in comms.
Note
No know use for this currently
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_comms_2d(label)
called when a a point event occurs in comms.
Note
No know use for this currently
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_grid(label)
called when a a point event occurs in the engineering grid.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_normal(label)
called when a a point event occurs in comms.
Note
No know use for this currently
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_science(label)
called when a a point event occurs in science by clicking the 2d view.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_point_weapons(label)
called when a a point event occurs in weapons by clicking the 2d view.
Note
This is not intended for long running tasks
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_science_navigate(path, label)
called to extend a gui navigation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
path
|
(str): The navigation path to extend |
required | |
label
|
label
|
The label to run |
required |
route_select_comms(label)
called when comms changes selection. Note: Typically used to run a task that uses an await comms
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_select_comms_2d(label)
called when comms changes selection. Note: Typically used to run a task that uses an await comms
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_select_grid(label)
called when grid changes selection.
Note
Typically used to run a task that uses an await comms
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_select_normal(label)
called when comms changes selection. Note: Typically used to run a task that uses an await comms
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_select_science(label)
called when science changes selection.
Note
Typically used to run a task that uses an await scan
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_select_weapons(label)
called when weapons changes selection.
Note
No know use for this yet
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_spawn(label)
called when a space_object is spawned.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |
route_spawn_grid(label)
called when a grid_object is spawned.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
label
|
label
|
The label to run |
required |
Returns:
Type | Description |
---|---|
The route: Used rarely to cancel the route |