When i create player2, i get player1 duplicated

Hello

Im trying to to do a local multiplayer game with split screen and everything works good except that when i create player2 in the GameMode a clon of player1 appears.

If i dont create player2 i have just one copy of player1

TY for your help

So after creating player 2 there are three characters? 2 player 1 and 1 player 2?

Exactly. In the game mode i have the “default pawn class” set to “player1”, and in the create player function i spawn a pawn just with player2. I have try a lot of combinations but nothing seems to work :frowning:

I don’t see anything wrong in your BP. The only thing I see that is in consistent is the ‘Spawn pawn’ check box on Create Player nodes.

The game is creating 1 player, and when i call the function “Create Player” with the “Controller ID”=0 it fails. So the first part of the graph doesnt work.
But, debugging i have found that when i call the function “Create Player” with the “Controller ID”=1 the constructor of Player1 is been called!!! Creating a pawn that none posses.

So the game is creating 1 pawn, the “Create Player” with the “Controller ID”=1 is creating other and the “Spawn actor” is creating other.

So, if i use the default pawn in the game mode i get 2 default pawns.
I need to find another way…

It’s creating 3 pawns because 1 is created by the game mode and then you’re creating 2 more via the sequence in the blueprint.

Quick fix is to set the game mode’s (in project settings) to use the default pawn from the engine and leave your blueprint as is.

Other option is to let the game mode spawn your player 1 and only spawn the 2nd player via blueprint.

Wouldn’t it be simpler if if you just created player and let the player controller spawn its pawn and the pawn construct would set the right pawn material?

I did it!!!
In the game mode i put “Default Pawn Class” = NONE
I just spawn a pawn to be posses by the player that the game creates.
And then i create a player with a pawn to posses.
TY very much for your help :slight_smile: