I added a new demo, DetermisticTest which test that the simulation is locally deterministic (on the same machine, objects falling from same point, at same speed, colliding with a bunch of other objects bounce in the exact same trajectory each time)
I also modified the Demo base class to clean up some of the mouse functions, such that they are now part of the demo prototype, allowing subclassing demo's to overwrite them, while preventing issues of having more than one demo instance on the screen at a time.
Finally I added a queryString to the index.html page load function, which will look for a querystring parameter (demoIndex=x), and load that demo or use a random one as before. When a demo is selected the query string is set, so that refreshing it reloads the same demo (useful when testing)
I added a new demo, DetermisticTest which test that the simulation is locally deterministic (on the same machine, objects falling from same point, at same speed, colliding with a bunch of other objects bounce in the exact same trajectory each time)
I also modified the Demo base class to clean up some of the mouse functions, such that they are now part of the demo prototype, allowing subclassing demo's to overwrite them, while preventing issues of having more than one demo instance on the screen at a time.
Finally I added a queryString to the index.html page load function, which will look for a querystring parameter (demoIndex=x), and load that demo or use a random one as before. When a demo is selected the query string is set, so that refreshing it reloads the same demo (useful when testing)