particle simulator with collisions and gravity