Hello,
I have a hard time slowing time in a matter physics scene. this.matter.world.timeScale = 0.5
doesn’t do anything at all, the objects are moving with the unchanged velocity and colliding like in a normal timeScale. Have you any ideas what might be the problem?
I’ve had this problem too. It’s actually not a property of matter.world. The only way I could do it was put it in the gameObject’s Matter Body Config. That’s definitely not the proper solution, so I hope someone else knows more.
This really seems to be what I need, but it doesn’t work well either. It doesn’t really do proper slow motion effect, because the friction stops the object much sooner than needs to be. (I set this.matter.world.engine.timing.timeScale = 4
) And if I set friction to (0,0,0), it actually runs faster and ignores collisions. (The reason for ignoring collisions seems to be ignoring some physics updates.)
For slow motion effect this.matter.world.engine.timing.timeScale
must be between 0 and 1.
Timescale = 0.25 doesn’t slow anything, and friction is weaker.
I have tested it here and works as expected.
You can try to reproduce your specific case using the Phaser examples:
http://labs.phaser.io/index.html?dir=physics/matterjs/&q=
I can’t reproduce it there and have no idea why the objects behave so strange in my case. I am giving up for now, will try another approach. Thank you for showing me.