- Home /
Can Achieve Deterministic Physics ?
Hello ,
How can I achieve same 3D physics simulation on different Devices.
I know that unity physics is not deterministic . But is there any way i can achieve deterministic physics ?
I'm trying to make a multi-player pool game .So sending transform of the balls every frame(or some defined interval) costs too much. So i was thinking to send Force and Direction only.
I think you are heading down the wrong path. Pool is hardly a game that requires real time physics. Sending the transform position of 15 balls 10 times a second is not going to overwhelm any data caps. Pool is also turn based, which means its not possible for two players to strike the same ball at the same time.
@Bored$$anonymous$$ormon : Yup its turn based. But the opponent can see the balls moving (Real Time) like in $$anonymous$$iniclip 8 Ball Pool. So to show the ball movements i need to send transform to server and then to opponents device.
But the opponent won't actually know if his animation is running two seconds behind. And it won't matter. Send position 10 times a second and interpolate.
Answer by devluz · Nov 24, 2014 at 06:57 AM
Round based is the best scenario. You only need one computer to do the simulation - all others just play it as an animation. Also the transfer of the data is very little and only needs to send data if actually something changes as reaction time is not important. You also don't need to send the whole transform. Only the position is important.
It gets complicated only if you have 2 players actively manipulating the physics at the same time e.g. in fps's
Hi, what do you mean by Round based?, Whould this be suitable for a gunbound style game?, I think I need to shoot proyectiles with accuracy between clients, so the case where one player gets hit on one machine and safe on another doesnt happen.
Your answer
Follow this Question
Related Questions
Is Physics.Raycast deterministic? 1 Answer
Deterministic physics, same platform 5 Answers
How Accurate is Unity Physics? 2 Answers
2D 360 degress platformer example needed 0 Answers
Rigidbody2D.velocity affects the y-axis, but not the x-axis. 1 Answer