News for hackers. Stuff that matters.
Re:Show HN: Terra, a JS framework for cellular automata and ... by ttty on Saturday August 23, 2014 @05:52PM (#8216973)
I intent to use this on my planets in my game: http://54.77.31.219/ looking for this kind of stuff for some time. glad it appeared on hn (: thanks
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @06:26PM (#8217049)
Very cool! Let me know when you include it and I'll add a link to the page
Re:Show HN: Terra, a JS framework for cellular automata and ... by ttty on Saturday August 23, 2014 @07:07PM (#8217134)
Ok (: I'm still figuring out the mechanics. The only thing I don't really like is the way it works. Is global... :/
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @07:21PM (#8217160)
It doesn't have to be global! Terra works as a module with most popular module systems. For example:

  var terra = require('./terra.min.js');
should work in any CommonJS environment.
Re:Show HN: Terra, a JS framework for cellular automata and ... by ttty on Saturday August 23, 2014 @07:36PM (#8217186)
I mean when you register

    terra.creatureFactory.register({type: 'firstCreature'});
this is stored in the global `terra` variable... Would be better IMO

    var terra = new Terra();terra.creatureFactory.register({type: 'firstCreature'});
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @07:40PM (#8217191)
I understand what you mean now. Are you able to make a pull request (or an issue) at https://github.com/rileyjshaw/terra? Pretty busy for the next few days but I'll try to get to it
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Monday August 25, 2014 @01:41PM (#8222871)
Actually, I've been thinking more about this and feel it's better to define creatures on the root terra object. Running the same simulation 100 times with slightly different starting conditions, for example, would require a new terrarium for each trial but creatures should be shared between..
Re:Show HN: Terra, a JS framework for cellular automata and ... by azeirah on Saturday August 23, 2014 @09:07PM (#8217345)
I made a really simple l-systems lib if anyone is interested. If fits in the same general vein of natural-computing.

https://github.com/Azeirah/L-Systems

Re:Show HN: Terra, a JS framework for cellular automata and ... by Rhapso on Saturday August 23, 2014 @05:10PM (#8216877)
this is a background in this vein I did a while ago.

http://www.glidr.net/

It runs a lot slower than it could. Running it faster made it less appealing. (works on mobile)

Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @05:18PM (#8216895)
Hahah glidr, nice
Re:Show HN: Terra, a JS framework for cellular automata and ... by kordless on Saturday August 23, 2014 @06:41PM (#8217082)
It would be awesome if the 'examples' actually showed you how to get it going yourself. I don't see any sample HTML anywhere, and your main page's JavaScript is compressed.
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @07:19PM (#8217155)
Good point! I just added a few lines to each to make them complete; if you include terra before running each example they should work now. Is this better?
Re:Show HN: Terra, a JS framework for cellular automata and ... by kordless on Monday August 25, 2014 @12:52PM (#8222586)
I opened a ticket if you are so inclined. The problem defined is that there isn't a clear method for getting this running in a quick webpage hackup way. It's JavaScript, so it should just 'work' when I cut and paste, as long as I'm including a min file somewhere.

There appear to be a good number of dependencies in the terra.js file, which isn't explained on the page. I see something called lowdash and seedrandom in there, both of which I have never seen before and have no clue how to install. I simply want to cut and paste the examples as they are shown and get something working. I don't want to run a bunch of build processes for installing a bunch of third party libraries on my machine when all I want is to include it on a single page in my project!

Anyway, it looks really cool. Wish I could use it.

Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Monday August 25, 2014 @01:42PM (#8222878)
Sorry @kordless! That was just me being dumb and forgetting to push bugfixes. It should "just work" now :)
Re:Show HN: Terra, a JS framework for cellular automata and ... by johnhenry on Saturday August 23, 2014 @10:12PM (#8217441)
Every so often, I sit down and begin making something like this. Then I get distracted and I forget about it for a while. This is really awesome!
Re:Show HN: Terra, a JS framework for cellular automata and ... by RobotCaleb on Saturday August 23, 2014 @03:15PM (#8216577)
This is pretty cool. Thanks for sharing, rileyjshaw.
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @03:29PM (#8216621)
Glad you like it! Let me know if you think of any potential improvements
Re:Show HN: Terra, a JS framework for cellular automata and ... by FranOntanaya on Saturday August 23, 2014 @03:46PM (#8216686)
Do you know DarwinBots? There's plenty to take from there. I've been wishing for years for an alife sim as flexible as DB that would run well on Linux.
Re:Show HN: Terra, a JS framework for cellular automata and ... by Botsareus on Sunday August 31, 2014 @11:36AM (#8249534)
Shameless Promo: You guys can take all you like. Just remember who you getting it from :P

- Paul

Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @04:35PM (#8216803)
Oh wow!! I hadn't seen this, super cool. Thanks for sharing
Re:Show HN: Terra, a JS framework for cellular automata and ... by pokpokpok on Saturday August 23, 2014 @04:01PM (#8216734)
See also: darwin pond
Re:Show HN: Terra, a JS framework for cellular automata and ... by Igglyboo on Saturday August 23, 2014 @03:41PM (#8216663)
Absolutely love this, Game of Life/Cellular Automaton never cease to amaze me even with such simplistic rules.
Re:Show HN: Terra, a JS framework for cellular automata and ... by possibilistic on Sunday August 24, 2014 @06:08AM (#8218154)
Riley, this is beautiful. The design, docs, colors, presentation--just fantastic. Awesome work! :)
Re:Show HN: Terra, a JS framework for cellular automata and ... by josealicarte on Saturday August 23, 2014 @03:49PM (#8216693)
This is awesome, lot of update via code :), thanks this can be use for my future references
Re:Show HN: Terra, a JS framework for cellular automata and ... by binocarlos on Saturday August 23, 2014 @03:42PM (#8216668)
That's really cool and a whole new world to discover via code - thanks!
Re:Show HN: Terra, a JS framework for cellular automata and ... by daemonk on Saturday August 23, 2014 @04:06PM (#8216748)
Hey Riley, this is Damian from hackerschool. Nice work. I remember you showed a prototype of this project on one of the thursday presentations.
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @04:33PM (#8216798)
Damian!! Neeraj and I were just talking about our check-ins yesterday; what are you up to these days?
Re:Show HN: Terra, a JS framework for cellular automata and ... by wismer on Saturday August 23, 2014 @07:53PM (#8217217)
oh yous guys! When are you three gonna come back to nyc ;)
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Sunday August 24, 2014 @04:18AM (#8218016)
The gang's all here..
Re:Show HN: Terra, a JS framework for cellular automata and ... by pokpokpok on Saturday August 23, 2014 @03:29PM (#8216623)
Love it! emergent complexity, pixels, and colors! I'm working on a similar project I want to show you if you make it to a Queens Hack Night this year :)
Re:Show HN: Terra, a JS framework for cellular automata and ... by rileyjshaw on Saturday August 23, 2014 @03:45PM (#8216680)
Cha Gheill!! If I'm back in the area I'll definitely swing by, feel free to send me a link until then