Is there randomness in the physics-module's simulation?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Is there randomness in the physics-module's simulation?
Currently making my Ludumdare-game using love.physics, I had it happen to me that on two equal scenarios there would be different outcomes. Why? How do I fix it?
Re: Is there randomness in the physics-module's simulation?
Maybe because of different dt's?
If so, an obvious fix would be to call world:update with a constant.
Edit: I've tried setting a fixed seed with this: https://www.love2d.org/forums/viewtopic ... 43#p191579 and while the initial positions and velocities were all the same, very quickly the results diverged between runs. Changing world:update(dt) to world:update(1/60) made everything behave the same way even after about 1 minute.
If so, an obvious fix would be to call world:update with a constant.
Edit: I've tried setting a fixed seed with this: https://www.love2d.org/forums/viewtopic ... 43#p191579 and while the initial positions and velocities were all the same, very quickly the results diverged between runs. Changing world:update(dt) to world:update(1/60) made everything behave the same way even after about 1 minute.
Who is online
Users browsing this forum: Ahrefs [Bot] and 52 guests