2D particles simulator (c++, java)