Spawn Actor From Class Returns None

Hello,

I am trying to attach random pickups to floor tiles which I spawn in my endless running game (Paper2D).
Therefore the floor tiles have an Arrow (Pickup Attach Point) at which the pickups should be attached.
This is the function which is called in the construction script of the floor tile:

The problem is now, that nothing at all is spawned. I added string output (as you can see in the blueprint) and it prints “FAIL” all the time. If I step in the branch with a breakpoint, I can see that the return value is “None”.
I absolutely cannot explain why this keeps happening.

Can someone please tell me what I am doing wrong and how it would be done right?
Thanks in advance.

Look on Log (Saved/Log), SpawnActor() prints reason of failed spawn there

1 Like

Thank you.
Found the error. Spawn Actor may not be used in Construction Script.
Greetings.

If you get an existing actor that suddenly becomes ‘None’, check to see if it fell below the “Kill Z” height. Once they go below that, UE4 deletes them and replaces them with a ‘None’ actor.

(Even though this question was answered and it’s not quite the question I had, it is the closest I could find and it’s at the top of the search list. If someone else runs into the problem I had then they will probably find this thread too. That’s why I am putting this post here.)