Unable to set default value for Object variables

I am making a blueprint which has an object variable that accepts any Actor objects. I made the variable editable and compiled the blueprint. But I cannot set a default value for this object (which is exactly what I want). I checked the Defaults tab as well; but it is not seen there either. I tried restarting the editor also.

Hi mindfane,

In the details window make sure your variable type is set to object. I noticed if it is set to something like “Actor” the value cannot be edited.
Unfortunately I cannot see your variable type since it is scrolled down. Here’s a screenshot of it working.

Let me know if this works

Cheers

Thanks. That worked.

However I wanted to to restrict the type of objects you could set. In my case, I wanted to allow only objects derived from Actor class to be selected. Do you think this is bug?

PS: Do you know how I can create a BP variable, for whch I could select an Actor placed in the level as a default value? Like I have this Actor I placed in the level (could be any actor). The Blue print should hold a reference to this Actor instance - the level designer selects the Actor. Any idea?

Hi mindfane,

Glad it helped. I am also looking at using the construction script to only display a designated amount of assets. However it is just me so I just type in the search field and find what I’m looking for. Good naming conventions can make it easier on your level designer. Just give them a doc stating all actors that start with i.e. “act_” are your actors.

I don’t know if it necessarily a bug, it just might mean we have to go about it a different way. My first guess is create a variable for each actor you want listed and then find the correct node to pass all those variables to the Object or Actor like before. I want to say you can store that info in an array but I could be wrong.

If I come up with something I will surely let you know. I have fell in love with the construction script and it’s power and I am definitely trying to learn more ways do more.