Thanks for helping me again. Seems to work with your tip:)
I have an AI Controller associated with an AICharacter (Character class). I spawn the AICharacter with the function “spawn ai from class”. If I destroy the AICharacter the AI Controller gets destroyed too. Why does it happen? Its very important that the AI Controller should persist.
Thanks for help:)
Try disabling auto possess ai controller and spawn the controller + possess the pawn manually. That might prevent the controller from getting destroyed.
before destroying just un possess your Controller and make a reference for it now you can assign your ai to a new character.
or just possess the new pawn before destroying the previous one, that’s probably the easiest - that way the controller wont get destroyed