3 ms·
Really nice. Recently I built a very simple game and I used springy[1]. It's great to have other beautiful written alternatives. https://github.com/dhotson/spr
by slig 15y ago
Really nice. Recently I built a very simple game and I used springy[1]. It's great to have other beautiful written alternatives.
https://github.com/dhotson/springy https://github.com/dhotson/springy
- anvaka 15y agoVery good for 500 lines of code :)! Thanks for sharing. O(n^2) for n-body simulation could hurt performance for the larger graph, i guess. But it should work really well for smaller ones. BTW this one by Lars Rönnbäck is also very impressive: http://js1k.com/2010-first/demo/618 http://js1k.com/2010-first/demo/618 - press any key to add nodes. It's only 1016 bytes. Amazing.