Hello guys.
i created a local multiplayer game, where first player plays via keyboard and second player via gamepad.
So far all is working and i am able to separate the player with their index.
Now ther is one particular issue i can not overcome:
When the Player is starting the Overlap Event on a checkpoint, it gets executed to all players not only to the one that triggered the overlap event.
Some help would be appreciated, so that when one player triggers the overlapp event only he is affected and not all players.
The solution you suggested i was able to find too, by research. But it looked to me as if it is only for online multiplayer, as from my understanding in local multiplayer all players are local. First Player uses keyboard and the second a gamepad?
But maybe i am missunderstanding something, i’ll try it out and let you know if it was successful.
I don’t know exactly how local multiplayer differs from regular multiplayer, buy I guess its basically the same. As I see it, your character (car) exists both on the server and all the clients, and the overlap event is fired on all of them. Try checking if your car IsLocallyControlled, and only then do the rest.
Okay, but if it’s one level and one object, I can’t really see how it would be possible to change it for one player and not for the other. Maybe you can pull it off with Post Process settings for players’ cameras, like make them not render some objects.
I have solved the problem in a way, it seems to me not the perfect solution but it works.
The Overlap Event still fires two times (2 Players in game) which is not nice , but this time he will check only the Player which really Overlaps the trigger.
Here is a screenshot for all those that maybe encountered the same problem and could not find a solution in the web.
Few Remarks:
Pass Index is a Interface which sends the Player Index from Controller to the bpCheckout blueprint
PassControllerArray is a Interface which send the saved Controller in the GameMode to bpCheckout
Call Checkpoint cleared has now a Input (CarController), so that when this Event is triggered it will proceed the right Controller which has been triggered.
Hi, I had the same issue, and from my tests the overlap is sent to all players which are in range of the trigger, I assume this is useful when for example a player triggers a platform or similar, so all players in range should see it.
If the second player is far away enough, the overlap event is not triggered.
In any case you should filter by checking the player like suggested below.