Create two instances of ecctrl for online
Hello, I am setting up a project in which I make the movement of the main character with ecctrl. The problem is that if I load another ecctrl for a second player, the movement that I apply to the main one also applies to the second, even if they are different references. I have tried creating two separate components, with different ecctrl and group references and it remains the same. Does anyone have any ideas on how to use it?
Thanks a lot.
@algoritcom have you found a solution for this?
I want to create another instance of ECCTRL with only physics and animation features, but I failed too. This problem is serious! If only the main player can use ECCTRL, the universality is significantly reduced.
I have successfully set this up in production with a fork of ECCTRL.
The solution was to remove all internal dependencies on zustand and use an internal context provider for each character instead.
One caveat though is that the collider logic is quite heavy and does not scale well for multiple instances, so you are probably better off using a separate controller for NPCs and multiplayer instances of other players.