unreal.DataLayerEditorSubsystem

class unreal.DataLayerEditorSubsystem(outer=None, name='None')

Bases: unreal.EditorSubsystem

Data Layer Editor Subsystem

C++ Source:

  • Module: DataLayerEditor

  • File: DataLayerEditorSubsystem.h

add_actor_to_data_layer(actor, data_layer) bool

Adds the actor to the DataLayer.

Parameters
  • actor (Actor) – The actor to add to the DataLayer

  • data_layer (DataLayer) – The DataLayer to add the actor to

Returns

true if the actor was added. false is returned if the actor already belongs to the DataLayer.

Return type

bool

add_actor_to_data_layers(actor, data_layers) bool

Adds the provided actor to the DataLayers.

Parameters
  • actor (Actor) – The actor to add to the provided DataLayers

  • data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if the actor was added to at least one of the provided DataLayers.

Return type

bool

add_actors_to_data_layer(actors, data_layer) bool

Add the actors to the DataLayer

Parameters
  • actors (Array(Actor)) – The actors to add to the DataLayer

  • data_layer (DataLayer) – The DataLayer to add to

Returns

true if at least one actor was added to the DataLayer. false is returned if all the actors already belonged to the DataLayer.

Return type

bool

add_actors_to_data_layers(actors, data_layers) bool

Add the actors to the DataLayers

Parameters
  • actors (Array(Actor)) – The actors to add to the DataLayers

  • data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if at least one actor was added to at least one DataLayer. false is returned if all the actors already belonged to all specified DataLayers.

Return type

bool

add_selected_actors_to_data_layer(data_layer) bool

Adds selected actors to the DataLayer.

Parameters

data_layer (DataLayer) – A DataLayer.

Returns

true if at least one actor was added. false is returned if all selected actors already belong to the DataLayer.

Return type

bool

add_selected_actors_to_data_layers(data_layers) bool

Adds selected actors to the DataLayers.

Parameters

data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if at least one actor was added. false is returned if all selected actors already belong to the DataLayers.

Return type

bool

append_actors_from_data_layer(data_layer)

Appends all the actors associated with the specified DataLayer.

Parameters

data_layer (DataLayer) – The DataLayer to find actors for.

Returns

out_actors (Array(Actor)): The list to append the found actors to.

Return type

Array(Actor)

append_actors_from_data_layers(data_layers)

Appends all the actors associated with ANY of the specified DataLayers.

Parameters

data_layers (Array(DataLayer)) – The DataLayers to find actors for.

Returns

out_actors (Array(Actor)): The list to append the found actors to.

Return type

Array(Actor)

create_data_layer() DataLayer

Creates a UDataLayer Object

Returns

The newly created UDataLayer Object

Return type

DataLayer

delete_data_layer(data_layer_to_delete) None

Deletes the provided DataLayer

Parameters

data_layer_to_delete (DataLayer) – A valid DataLayer

delete_data_layers(data_layers_to_delete) None

Deletes all of the provided DataLayers

Parameters

data_layers_to_delete (Array(DataLayer)) – A valid list of DataLayer.

get_actors_from_data_layer(data_layer)

Gets all the actors associated with the specified DataLayer. Analog to AppendActorsFromDataLayer but it returns rather than appends the actors.

Parameters

data_layer (DataLayer) – The DataLayer to find actors for.

Returns

The list to assign the found actors to.

Return type

Array(Actor)

get_actors_from_data_layers(data_layers)

Gets all the actors associated with ANY of the specified DataLayers. Analog to AppendActorsFromDataLayers but it returns rather than appends the actors.

Parameters

data_layers (Array(DataLayer)) – The DataLayers to find actors for.

Returns

The list to assign the found actors to.

Return type

Array(Actor)

get_data_layer(actor_data_layer) DataLayer

Gets the UDataLayer Object of the ActorDataLayer

Parameters

actor_data_layer (ActorDataLayer) – The ActorDataLayer whose UDataLayer Object is returned

Returns

The UDataLayer Object of the provided ActorDataLayer

Return type

DataLayer

get_data_layer_from_label(data_layer_label) DataLayer

Gets the UDataLayer Object of the DataLayer label

Parameters

data_layer_label (Name) – The label of the DataLayer whose UDataLayer Object is returned

Returns

The UDataLayer Object of the provided DataLayer label

Return type

DataLayer

is_actor_valid_for_data_layer(actor) bool

Checks to see if the specified actor is in an appropriate state to interact with DataLayers

Parameters

actor (Actor) – The actor to validate

Return type

bool

make_all_data_layers_visible() None

Set the visibility of all DataLayers to true

remove_actor_from_all_data_layers(actor) bool

Removes an actor from all DataLayers.

Parameters

actor (Actor) – The actor to modify

Returns

true if the actor was changed.

Return type

bool

remove_actor_from_data_layer(actor, data_layer_to_remove) bool

Removes an actor from the specified DataLayer.

Parameters
  • actor (Actor) – The actor to remove from the provided DataLayer

  • data_layer_to_remove (DataLayer) – The DataLayer to remove the actor from

Returns

true if the actor was removed from the DataLayer. false is returned if the actor already belonged to the DataLayer.

Return type

bool

remove_actor_from_data_layers(actor, data_layers) bool

Removes the provided actor from the DataLayers.

Parameters
  • actor (Actor) – The actor to remove from the provided DataLayers

  • data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if the actor was removed from at least one of the provided DataLayers.

Return type

bool

remove_actors_from_all_data_layers(actors) bool

Removes an actor from all DataLayers.

Parameters

actors (Array(Actor)) –

Returns

true if any actor was changed.

Return type

bool

remove_actors_from_data_layer(actors, data_layer) bool

Removes the actors from the specified DataLayer.

Parameters
  • actors (Array(Actor)) – The actors to remove from the provided DataLayer

  • data_layer (DataLayer) –

Returns

true if at least one actor was removed from the DataLayer. false is returned if all the actors already belonged to the DataLayer.

Return type

bool

remove_actors_from_data_layers(actors, data_layers) bool

Remove the actors to the DataLayers

Parameters
  • actors (Array(Actor)) – The actors to remove to the DataLayers

  • data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if at least one actor was removed from at least one DataLayer. false is returned if none of the actors belonged to any of the specified DataLayers.

Return type

bool

remove_selected_actors_from_data_layer(data_layer) bool

Removes the selected actors from the DataLayer.

Parameters

data_layer (DataLayer) – A DataLayer.

Returns

true if at least one actor was added. false is returned if all selected actors already belong to the DataLayer.

Return type

bool

remove_selected_actors_from_data_layers(data_layers) bool

Removes selected actors from the DataLayers.

Parameters

data_layers (Array(DataLayer)) – A valid list of DataLayers.

Returns

true if at least one actor was removed.

Return type

bool

rename_data_layer(data_layer, new_data_layer_label) bool

Renames the provided DataLayer to the provided new label

Parameters
  • data_layer (DataLayer) – The DataLayer to be renamed

  • new_data_layer_label (Name) – The new label for the DataLayer to be renamed

Return type

bool

select_actors_in_data_layer(data_layer, select, notify, select_even_if_hidden=False) bool

Selects/de-selects actors belonging to the DataLayer.

Parameters
  • data_layer (DataLayer) – A valid DataLayer.

  • select (bool) – If true actors are selected; if false, actors are deselected.

  • notify (bool) – If true the Editor is notified of the selection change; if false, the Editor will not be notified.

  • select_even_if_hidden (bool) – [optional] If true even hidden actors will be selected; if false, hidden actors won’t be selected.

Returns

true if at least one actor was selected/deselected.

Return type

bool

select_actors_in_data_layers(data_layers, select, notify, select_even_if_hidden=False) bool

Selects/de-selects actors belonging to the DataLayers.

Parameters
  • data_layers (Array(DataLayer)) – A valid list of DataLayers.

  • select (bool) – If true actors are selected; if false, actors are deselected.

  • notify (bool) – If true the Editor is notified of the selection change; if false, the Editor will not be notified

  • select_even_if_hidden (bool) – [optional] If true even hidden actors will be selected; if false, hidden actors won’t be selected.

Returns

true if at least one actor was selected/deselected.

Return type

bool

set_data_layer_is_dynamically_loaded_in_editor(data_layer, is_loaded_in_editor, is_from_user_change) bool

Set Data Layer Is Dynamically Loaded in Editor deprecated: Use SetDataLayerIsLoadedInEditor instead

Parameters
  • data_layer (DataLayer) –

  • is_loaded_in_editor (bool) –

  • is_from_user_change (bool) –

Return type

bool

set_data_layer_is_loaded_in_editor(data_layer, is_loaded_in_editor, is_from_user_change) bool

Changes the DataLayer’s IsLoadedInEditor flag to the provided state

Parameters
  • data_layer (DataLayer) – The DataLayer to affect.

  • is_loaded_in_editor (bool) – The new value of the flag IsLoadedInEditor. If True, the Editor loading will consider this DataLayer to load or not an Actor part of this DataLayer. An Actor will not be loaded in the Editor if all its DataLayers are not LoadedInEditor.

  • is_from_user_change (bool) – If this change originates from a user change or not.

Return type

bool

set_data_layer_visibility(data_layer, is_visible) None

Changes the DataLayer’s visibility to the provided state

Parameters
  • data_layer (DataLayer) – The DataLayer to affect.

  • is_visible (bool) – If true the DataLayer will be visible; if false, the DataLayer will not be visible.

set_data_layers_is_dynamically_loaded_in_editor(data_layers, is_loaded_in_editor, is_from_user_change) bool

Set Data Layers Is Dynamically Loaded in Editor deprecated: Use SetDataLayersIsLoadedInEditor instead

Parameters
Return type

bool

set_data_layers_is_loaded_in_editor(data_layers, is_loaded_in_editor, is_from_user_change) bool

Changes the IsLoadedInEditor flag of the DataLayers to the provided state

Parameters
  • data_layers (Array(DataLayer)) – The DataLayers to affect

  • is_loaded_in_editor (bool) – The new value of the flag IsLoadedInEditor. If True, the Editor loading will consider this DataLayer to load or not an Actor part of this DataLayer. An Actor will not be loaded in the Editor if all its DataLayers are not LoadedInEditor.

  • is_from_user_change (bool) – If this change originates from a user change or not.

Return type

bool

set_data_layers_visibility(data_layers, is_visible) None

Changes visibility of the DataLayers to the provided state

Parameters
  • data_layers (Array(DataLayer)) – The DataLayers to affect

  • is_visible (bool) – If true the DataLayers will be visible; if false, the DataLayers will not be visible

set_parent_data_layer(data_layer, parent_data_layer) bool

Sets a Parent DataLayer for a specified DataLayer

Parameters
  • data_layer (DataLayer) – The child DataLayer.

  • parent_data_layer (DataLayer) – The parent DataLayer.

Returns

true if succeeded, false if failed.

Return type

bool

toggle_data_layer_is_dynamically_loaded_in_editor(data_layer, is_from_user_change) bool

Toggle Data Layer Is Dynamically Loaded in Editor deprecated: Use ToggleDataLayerIsLoadedInEditor instead

Parameters
Return type

bool

toggle_data_layer_is_loaded_in_editor(data_layer, is_from_user_change) bool

Toggles the DataLayer’s IsLoadedInEditor flag

Parameters
  • data_layer (DataLayer) – The DataLayer to affect

  • is_from_user_change (bool) – If this change originates from a user change or not.

Return type

bool

toggle_data_layer_visibility(data_layer) None

Toggles the DataLayer’s visibility

Parameters

data_layer (DataLayer) – The DataLayer to affect

toggle_data_layers_is_dynamically_loaded_in_editor(data_layers, is_from_user_change) bool

Toggle Data Layers Is Dynamically Loaded in Editor deprecated: Use ToggleDataLayersIsLoadedInEditor instead

Parameters
Return type

bool

toggle_data_layers_is_loaded_in_editor(data_layers, is_from_user_change) bool

Toggles the IsLoadedInEditor flag of all of the DataLayers

Parameters
  • data_layers (Array(DataLayer)) – The DataLayers to affect

  • is_from_user_change (bool) – If this change originates from a user change or not.

Return type

bool

toggle_data_layers_visibility(data_layers) None

Toggles the visibility of all of the DataLayers

Parameters

data_layers (Array(DataLayer)) – The DataLayers to affect

update_actor_all_views_visibility(actor) None

Update Actor All Views Visibility deprecated: Per-view Data Layer visibility was removed.

Parameters

actor (Actor) –

update_actor_visibility(actor, notify_selection_change, redraw_viewports) (out_selection_changed=bool, out_actor_modified=bool) or None

Updates the provided actors visibility in the viewports

Parameters
  • actor (Actor) – Actor to update

  • notify_selection_change (bool) – If true the Editor is notified of the selection change; if false, the Editor will not be notified

  • redraw_viewports (bool) – If true the viewports will be redrawn; if false, they will not

Returns

out_selection_changed (bool): [OUT] Whether the Editors selection changed

out_actor_modified (bool): [OUT] Whether the actor was modified

Return type

tuple or None

update_all_actors_visibility(notify_selection_change, redraw_viewports) bool

Updates the visibility of all actors in the viewports

Parameters
  • notify_selection_change (bool) – If true the Editor is notified of the selection change; if false, the Editor will not be notified

  • redraw_viewports (bool) – If true the viewports will be redrawn; if false, they will not

Return type

bool

update_all_view_visibility(data_layer_that_changed) None

Update All View Visibility deprecated: Per-view Data Layer visibility was removed.

Parameters

data_layer_that_changed (DataLayer) –