I am using a stateful collision buffer that is updated through ECS and I have a gameobject which then checks for the last collision and takes actions based on it. The problem is that it works perfectly when I play the game inside the editor but it doesn’t work well when I compile it to my VR. Can’t figure out if it’s because of the multi-threading or burst). I know that the FixedUpdates are not synced between ECS and Gameobjects but I was hoping that they would at least run in turns because their timesteps are configurated to be the same in my project.
Is there a way to call a GameObject’s method from within a system? That way I can just have a “HavokUpdate” method/event that calls for the actions in the right time.
UnityEngine FixedUpdate runs multiple times, and then ECS FixedUpdate runs multiple times. It is possible to make the ECS FixedUpdate run once per UnityEngine FixedUpdate, but that requires messing with ComponentSystemGroups and custom bootstraps.
You can interact with GameObjects and call methods anywhere on the main thread, including from systems.
I’m already using some ComponentSystemGroups, I am very confused as to why they are not running one after the other consistently.
I had no idea that you could use GetDataFromEntity on a monobehavior which is on an entity, that seems to be the best practice for my case. Thanks!