Hi there, I’m working on a local multiplayer game based out of the rolling template where players share a screen / camera (think Bumper Balls from Mario Party).
It’s easy enough to set the default pawn and controller, and have player 1 spawn. But in order to get players 2 through 4 spawned, we’re using UGameplayStatics::CreatePlayer, casting the return of that to our controller, and associating a new pawn to the controller. It DOES create and associate the spawned players to our game pads, so up to 4 players can play. However, it seems like there’s a disconnect in the method we’re spawning player 1, and the way the other players are being spawned.
It’s leading to some weirdness in terms of how many controllers / pawns are being spawned in Play in Viewport versus a Standalone instance. It’s spawning the 4 players we need, plus three additional ones that also have AIControllers spawned (it’s not our own game code doing this). Also, we can dictate where players 2-4 are spawned, but player 1 spawns wherever it pleases (among the PlayerStarts).
TL;DR: What’s the PROPER way to spawn new players into local multiplayer (not online / LAN), and still be able to dictate what PlayerStart they spawn to? Is there a way to override or cancel spawning the default pawn/controller and just handle it ourselves?
I’ve seen some similar threads, but nothing definitive about the difference between default spawned pawn/controller and additional players.
Edit: to be clear this is all in C++. Only want to use blueprint where absolutely necessary