And all the “print strings” confirmed that all references where valid.
I want to know if there’s a way to fix this errors, despite of working perfectly, I want to make shure that they don’t cause any issues in the future.
I tryed creating the objects with the array, for some reason it didn’t work. Thaks for trying to help.
But I discovered the reason for the errors:
This is the print string from the clients and the server (P1=Player1, P2="2, P3="3, P4="4, V=Valid, F=NotValid). As you can see all the clients have valid actor and player, but for some reason the server dosent have valid players.
Can you help me making them valid for the server?
How do you spawn the players? Do you need to run this function on all players and the server or can you just run it on the server and replicate the middle vector? Are the player actors replicated?
The players are spawned by a “NetworkPlayerStart”.
The player actors are replicated.
This function runs on a camera actor that is placed on the map and is the view target for all players. I just need the camera to have this middle vector and be centred acording to the position of the players. (I think it would be better to run only on players, but I would like to hear your opinion)
But can you try to set this loop first then when it completes use set view target and destroy actor? This blueprint doesn’t work for me and I don’t wanna fix it as I will possibly change it.
By the way I’v also discovered that if i run on dedicated server all players are invalid, but if I don’t run on dedicated server “player 0” becomes valid and it’s the only one. I think that the server is having trouble finding the clients characters.