The variable I am trying to access is the people one you see below to display using a progress bar on the player screen. Not sure what to plug into the object as I think I am on the right path maybe with the cast to CB_BuildingAsset as the variable I want is in there.
Casting is not a form of communication. It’s conversion. You can’t find things with casting. In order to Cast, you need an object reference first.
Access a variable in a blueprint class
called CB_BuildingAsset
That’s not what you need either. You need an instance of an object, not its class. If you wanted a class, you’d:
But that does not give you the access to the instance, of which there may be many.
Not sure what to plug into the object
as I think I am on the right path
maybe with the cast to
CB_BuildingAsset as the variable I
want is in there.
Is there only one? Are there more? How is the editor supposed to tell which of the 10 (let’s say) you’re trying to access? How do we know which one to choose? Are we clicking things, looking at them, getting close to them? Think about a method / trigger that communicates that choice.