Download

Player pawn not getting deleted when owner player disconnects if I use APawn instead of ACharacter??

Hey, here’s some more context for you.

I’m working on a game lobby and I noticed that when a player disconnects, his pawn isn’t getting deleted. Nothing special about the lobby, everything is handled by standard UE code. When someone joins, GameMode spawns DefaultPawnClass and the player possesses it as usual. The only difference is that I’m not using an ACharacter for the DefaultPawnClass, just a standard APawn. I’ve overrided nothing in it, apart from disabling movement replication for them (so that I can relocate them locally without any issues). That’s all really. As soon as I change the DefaultPawnClass to be an ACharacter, everything works as expected again.

Is this working as intended? If so, how can I get it to work as if it was an ACharacter?

Thanks in advance!

Oh my god, just as I posted this as a cry for help, I realized that I didn’t call Super for the pawn’s BeginPlay…