

Multiplayer Genetic Cars - gwil
http://gencar.co

======
alan_cx
Probably missing something ...

Which is my car? Is it competing? If so, against who? How can I tell? I have
no idea what Im looking at, which is my car, who Im competing against, who is
doing well.

Is there some sort of dummies guide for the likes of me???? :)

Despite all that, Im mesmerized!!!

Edit: I see down votes? How is it wrong to not understand something and ask
for some help. Why is that a down vote?

~~~
pubnub
Good question! See "Your Car" in the list of car health meters.

~~~
alan_cx
Yes. Its all of the health meters.

------
artjumble
So did you ask Rafael Matsunaga if you could copy and release his code as open
source?

~~~
shmageggy
Seriously. They even copied his text verbatim. The original code didn't
mention any license which I don't think means it's a free-for-all. Also, they
apparently copied the code before he pushed a bug-fix I emailed him yesterday
:)

~~~
the_prestige
So do you know what the license is. I'm planning to fork this awesomeness for
some other variants, and I'm sure others are thinking about that too.

~~~
mikeash
Best assume that there is no license unless it's posted obviously.

------
jsnell
I don't think this idea works. All players will very soon have the same top
car (or the descendant of the same top car), and get a copy of that car from
all other players. This creates a massively inbred mono-population.

Not sure what the appropriate fix would be. Import the top car from one random
player in each generation?

~~~
Cthulhu_
And yet, isn't having the strongest species the goal of an evolutionary
algorithm? Having multiple players do multiple runs (parallelization) and
ending up with the same / a similar species sounds like a goal to me.

Perhaps you'd like to see more varied species get comparable end-results, but
I think you'll need a more varied obstacle course / 'goals' in that case.

~~~
coderzach
The issue is that you'll hit a local optimum, and all progress will halt.

------
ynniv
The biggest problem here is a lack of server-side validation. The "remote
champion" is determined by the score claimed by a client, so set a breakpoint
in the function that posts the score and you can claim that any car parameters
achieved any score... You see where this is going.

A proper implementation would run the simulation server-side to verify that a
configuration achieves a high score. Almost as good would be to rank
configurations based on the average runs across clients. This still lets a
client submit an absurd configuration, but won't let an inferior configuration
continue to be "champion".

------
eterm
One problem is that everyone shares their best, which becomes someone else's
best, which then gets shared. Very quickly all my cars are all the same car
ID.

It needs a way to prevent 2 identical copies racing each other.

~~~
pubnub
Looking into this shortly.

------
jstanley
Is this based at all on the HTML5 genetic cars project submitted the other
day?

~~~
Ashuu
Looks very similar! But better!

~~~
pubnub
This is an improvement over the original with Distributed Computing. The more
players there are, the faster the best car is discovered. We want as many
players as possible to find the BEST CAR faster than ever possible before.

------
mistercow
This is a neat idea, although currently I can't really figure out what the
deal is. It seems that I'll have a really effective car, and then the next
round, I'll end up with a completely new set of cars, none of which resemble
the previous winner, and all of which are less effective.

Anyway, would would be really cool to see would be something like Picbreeder,
but for cars, where you can manually choose which cars to breed, then let them
evolve on different courses, etc. Having some extra control over the situation
would make for something extremely addictive.

~~~
pubnub
good call!

------
pubnub
We've pushed a few updates but are still working on making improvements! Soon
a Chat feature will be added too....

------
Glyptodon
It seems a bit opaque/confusing. Pretty soon everyone seems to be based on the
same root 'genome' and you can't even tell which cars are 'yours' so to speak.
Likewise, you can't wall off your own gene pool so that it doesn't get cross-
contaminated.

~~~
pubnub
We added the "Your Car" label which is mutated based on the current Champion
of the World. We are working on improving the manipulation capabilities for
Intelligent Design.

------
webjprgm
I've been watching "PubNub-World-4" for a while (28 generations, animation is
still on). It has a nasty hill to climb that stops all cars at about 160
meters. I saw one _almost_ make it over. So now I don't want to refresh and
lose the chance that one might eventually evolve to make it.

Most of the cars seem to be quite similar, though. Also, the one that almost
made it over doesn't seem to be marked as the leader so there's no net
improvement in the cars. I saw one more, in about Gen 30, almost make it over
too (it jumps up and sits on the ledge a while before falling back, as opposed
to not getting past the ledge or jumping straight up in the air and falling
back down).

Very mesmerizing thing.

~~~
pubnub
After some improvements on the multiplayer aspects we are starting to see
better generations being created and breading between champions.

------
qwerty_asdf
Let's all coordinate on the "HackerNews" world.

Join World: HackerNews

------
Ra1d3n
Im hitting performance problems after about 5 minutes. I get massive lags.
Running on latest Chrome i5 3.4GHz x 4 and 8GB RAM.

Edit: Just press "New Population" a few times and watch your browser slow
down. There is a memory leak somewhere.

------
emehrkay
Hmm, things started off interesting with the best car i've seen thus far
(short, wheels covered the top and bottom, etc) then this

[http://imgur.com/a/XFCYZ](http://imgur.com/a/XFCYZ)

~~~
extrapolate
The track/car generation is done through JS, so some modifications aren't
anything Chrome Dev Tools can't handle. Add to that the fact that the "best"
car is populated into the gene pools of all the other users and that's the
outcome.

------
hyramgraff
I've found the the string "HN" generates a nice but challenging world.

~~~
pubnub
Tried it here at the office, Yes it is challenging indeed.

------
pubnub
Adding the chat shortly and we will change the world number again.

FORK us - [https://github.com/pubnub/genetic-
car-2](https://github.com/pubnub/genetic-car-2)

------
ndr
Now put a js based bitcoin miner on the background and you're done.

~~~
pubnub
Haha good idea. >: D

------
MWil
The go button is not working for me (firefox 22)

~~~
pubnub
Thank you for the detail we are fixing this ASAP.

~~~
MWil
All buttons seem to work well when it first loads but then over time
(generations) they seem to require a reload to work again.

~~~
pubnub
good to know. we are looking into this.

------
pubnub
We just pushed a new update go check it out. Upgraded Chat. Soon to come is a
Intelligent Design (God Mode).

------
pubnub
We are working on improvements to the Genetic Algorithm! Updates Shortly.

~~~
profquail
You might be able to further increase performance with parallel.js[1]:

[1]:
[http://adambom.github.io/parallel.js/](http://adambom.github.io/parallel.js/)

~~~
pubnub
This looks like it may work out! Looking into it a bit more.

------
deletes
Is the world based on the same map(terrain) or the same pool of cars?

~~~
pubnub
Same pool of champion cars that work best across a similar terrain.

~~~
deletes
Identical terrain for the example `PubNub-World-2`?

EDIT: Looks identical to me.

>>Join World: The same seed always creates the same track, so you can agree on
a seed with your friends and compete. :)<<

------
snake_plissken
Ummm can someone explain to me what exactly is going on here?

~~~
pubnub
This game is connected to the world, all players are sharing their best cars
each game round. Only the dominant cars win. The TOP car from each player in
the world is added to your car list each game cycle. This car is therefore
added to your gene pool and is then genetically spliced and paired with your
other cars. Top cars are transmitted around the world from other players who
are online RIGHT NOW using WebSockets style technology for data streaming (
PubNub ).

------
dta5003
Watch out for the XSS in the chat.

~~~
alan_cx
Yeah. I've been sat here watching people trying it as they update the site to
combat it.

Still dont know what Im looking at though...

~~~
qwerty_asdf
Hmmm... people are complaining about their browsers mysteriously crashing,
interspersed with random strings of Russian conversation...

~~~
prithee
likely a 100k gen bot gone sentient, learned Russian.

------
pubnub
VERSION 2.35 UPDATED!

