Many have asked this for years.
- In UE4.27, how can we go to World/map view, click a Blueprint (Lootcrate BP), and edit the Variables (details panel) of a Child Actor Component (Pickup01 BP) that is inside the Blueprint –
- – without using a CastTo the name of the [Child loot] because I wont always have the same name or classes (there is Pickup02, Pickup01, Weapon01, etc).
- Or if I have to use CastTo, how can I do a wildcard cast (or code a wildcard so I can select from a list of Pickup BPs, without always changing the Lootcrate BP code)?
- I also need the [Child Actor Component] or its [replacement Pickup Actor] to be referenced in the Construct code of the Lootcrate BP, so that when I select a different [Pickup BP] that is in the Crate, then the Editor shows an update before playing (so as a dev I can quickly see which Crate will spawn what).
The community asked for years, feature requests were filed (and now the link is broken, so I cant see what was the decision).
Details:
-
I have a main Lootcrate BP actor. Inside of that is a Child Actor Component.
-
In the Right details panel, I set this Child Component as the real Pickup01 Actor.
-
Now while in the BP of the Lootcrate, I can edit the variables of [Child Actor Component, and thus the chosen PickupActor] - set its colors, tier, etc (the PickupActor has the code for all that, by reading from a DT. Im just selecting what the LootCrate spawns with so far).
-
But the problem is I want to place Lootcrate BP in the map, set it to hold Pickup01 near a tree. Then place another Lootcrate BP near a rock, and I want it to spawn a different PIckup02 that I manually set from World view.
-
But I cant because I cannot change the code/variables of the Instance copy of the Lootcrate BPs in the map. And even if I click the Child Component Actor, it doesnt show me its Variables in the details panel (in world view = map view) – as it did when I was in the BP editor.
-
So back to the BP editor. I wanted to add an Actor Variable to Lootcrate BP because I also need code in the Construct script to turn the [Child Actor Component] into whatever [Actor variable] that I set.
-
But problem 1, how do I turn the [Actor variable] into the [Child Actor Component] or replace it, so that in the World view, I can click on the Instance of the Lootcrate BP, and edit the variables of each [Actor variable]? While also on Construct, it updates to display in the map, the current [Actor variable]?
-
Problem 2, even when I add an Actor Variable (and set it as Pickup01 or 02), I still cant access its variables to set its tier, etc. (I can only access the variables of the Pickup01 BP if I set it as a Child Actor Component.)
-
So in Construct, I need to change Actor Variable (the chosen Pickup BP) into Child Actor Component or something that I can edit the variables of, in the World view.
Please help, thanks