unreal.PCGBlueprintBaseElement¶
- class unreal.PCGBlueprintBaseElement(outer: Object | None = None, name: Name | str = 'None')¶
Bases:
ObjectPCGBlueprint Base Element
C++ Source:
Plugin: PCG
Module: PCG
File: PCGBlueprintBaseElement.h
Editor Properties: (see get_editor_property/set_editor_property)
category(Text): [Read-Write]compute_full_data_crc(bool): [Read-Write] In cases where your node is non-cacheable but is likely to yield the same results on subsequent executions, this controls whether we will do a deep & computationally intensive CRC computation (true), which will allow cache usage in downstream nodes in your graph, or, by default (false), a shallow but quick crc computation which will not be cache-friendly.custom_input_pins(Array[PCGPinProperties]): [Read-Write]custom_output_pins(Array[PCGPinProperties]): [Read-Write]dependency_parsing_depth(int32): [Read-Write]description(Text): [Read-Write]enable_preconfigured_settings(bool): [Read-Write]expose_to_library(bool): [Read-Write]has_default_in_pin(bool): [Read-Write]has_default_out_pin(bool): [Read-Write]has_dynamic_pins(bool): [Read-Write] If enabled, by default, the Out pin type will have the union of In pin types. Default only works if the pins are In and Out. For custom behavior, implement DynamicPinTypesOverride.is_cacheable(bool): [Read-Write] Controls whether results can be cached so we can bypass execution if the inputs & settings are the same in a subsequent execution. If you have implemented the IsCacheableOverride function, then this value is ignored. Note that if your node relies on data that is not directly tracked by PCG or creates any kind of artifact (adds components, creates actors, etc.) then it should not be cacheable.only_expose_preconfigured_settings(bool): [Read-Write]preconfigured_info(Array[PCGPreConfiguredSettingsInfo]): [Read-Write]requires_game_thread(bool): [Read-Write] Controls whether this node execution can be run from a non-game thread. This is not related to the Loop functions provided/implemented in this class, which should always run on any thread.
- apply_preconfigured_settings(preconfigure_info) None¶
Apply the preconfigured settings specified in the class default. Used to create nodes that are configured with pre-defined settings. Use InPreconfigureInfo index to know which settings it is.
- Parameters:
preconfigure_info (PCGPreConfiguredSettingsInfo)
- property compute_full_data_crc: bool¶
[Read-Write] In cases where your node is non-cacheable but is likely to yield the same results on subsequent executions, this controls whether we will do a deep & computationally intensive CRC computation (true), which will allow cache usage in downstream nodes in your graph, or, by default (false), a shallow but quick crc computation which will not be cache-friendly.
- Type:
(bool)
- dynamic_pin_types_override(settings, pin) int32¶
If Dynamic Pins is enabled in the BP settings, override this function to provide the type for the given pin. You can use “GetTypeUnionOfIncidentEdges” from the settings to get the union of input types on a given pin. Use the bitwise OR to combine multiple types together.
- Parameters:
settings (PCGSettings)
pin (PCGPin)
- Return type:
int32
- execute(input) PCGDataCollection¶
Main execution function that will contain the logic for this PCG Element. Use GetContextHandle to have access to the context.
- Parameters:
input (PCGDataCollection) – Input collection containing all the data passed as input to the node.
- Returns:
output (PCGDataCollection): Data collection that will be passed as the output of the node, with pins matching the ones provided during the execution.
- Return type:
- get_context_handle() PCGBlueprintContextHandle¶
Get Context Handle
- Return type:
- get_input_pin_by_label(pin_label) PCGPinProperties or None¶
Returns true if there is an input pin with the matching label. If found, will copy the pin properties in OutFoundPin
- Parameters:
pin_label (Name)
- Returns:
out_found_pin (PCGPinProperties):
- Return type:
PCGPinProperties or None
- get_input_pins() Array[PCGPinProperties]¶
Get Input Pins
- Return type:
- get_output_pin_by_label(pin_label) PCGPinProperties or None¶
Returns true if there is an output pin with the matching label. If found, will copy the pin properties in OutFoundPin
- Parameters:
pin_label (Name)
- Returns:
out_found_pin (PCGPinProperties):
- Return type:
PCGPinProperties or None
- get_output_pins() Array[PCGPinProperties]¶
Get Output Pins
- Return type:
- get_random_stream_with_context(context_handle) RandomStream¶
Creates a random stream from the settings & source component
- Parameters:
context_handle (PCGBlueprintContextHandle)
- Return type:
- get_seed_with_context(context_handle) int32¶
Gets the seed from the associated settings & source component
- Parameters:
context_handle (PCGBlueprintContextHandle)
- Return type:
int32
- property has_dynamic_pins: bool¶
[Read-Write] If enabled, by default, the Out pin type will have the union of In pin types. Default only works if the pins are In and Out. For custom behavior, implement DynamicPinTypesOverride.
- Type:
(bool)
- property is_cacheable: bool¶
[Read-Write] Controls whether results can be cached so we can bypass execution if the inputs & settings are the same in a subsequent execution. If you have implemented the IsCacheableOverride function, then this value is ignored. Note that if your node relies on data that is not directly tracked by PCG or creates any kind of artifact (adds components, creates actors, etc.) then it should not be cacheable.
- Type:
(bool)
- is_cacheable_override() bool¶
Override for the IsCacheable node property when it depends on the settings in your node. If true, the node will be cached, if not it will always be executed.
- Return type:
- node_color_override() LinearColor¶
Override for the default node color.
- Return type:
- node_type_override() PCGSettingsType¶
Override to change the node type.
- Return type: