INNER CODE UNIT · Python
connect_blueprint_nodes
prajwalshettydev/UnrealGenAISupport · Content/Python/mcp_server.py:646
def connect_blueprint_nodes(blueprint_path: str, function_id: str,
source_node_id: str, source_pin: str,
target_node_id: str, target_pin: str) -> str:
command = {
"type": "connect_nodes",
"blueprint_path": blueprint_path,
"function_id": function_id,
"source_node_id": source_node_id,
"source_pin": source_pin,
"target_node_id": target_node_id,
"target_pin": target_pin
}
response = send_to_unreal(command)
if response.get("success"):
return f"Successfully connected {source_node_id}.{source_pin} to {target_node_id}.{target_pin} in Blueprint at {blueprint_path}"
else:
error = response.get("error", "Unknown error")