It has the same physics properties. (1 mass, 7.5 for linear and angular drag.) The same top speed. I only call rigidbody2D.addforce in the fixed update method and I multiply it by time.fixedDelataTime.
To be clear, I am uploading the project from my PC and running it on my laptop. there is ZERO difference in code or settings.
here is the code in the FixedUpdate method to move my player’s rigidbody2d.
transform.rigidbody2D.AddForce(Time.fixedDeltaTime*(direction * TopSpeed));
I even got the rigidbody2d.velocity vector and calculated its magnitude on each computer and it was the exact same number. but still my player is moving almost twice as fast on the laptop.
Also my Time Setting are exactly the same (default on both computers, 0.02, 0.3333 1)
I have a feeling its due to frames per second on each computer. On my pc, it runs at around 80fps, on my laptop its close to 720fps.
But what’s the point of fixedUpdated and time.fixedDeltaTime if that wont make my players speed universal.
How do I fix this? I’m totally lost. Hope you can help.
ps:( Direction is simply gained from the leftstick, and that is also updated in fixedUpdate. Also I have a screen of my player rigidbody2d setup attached below.)