Casting to Actor Class causes crash on project startup

I think the problem is not the casting. It’s in the Selected function of that actor. Crash while the editor is loading is usually caused by corrupt object, maybe you store a reference to a selected transient actor in a property that is serialized, when you click save in the editor the actor (which is transient) is serialized but when the editor starts it tries to look up the object using the saved object path and see that it’s not there and breaks the execution.