News for hackers. Stuff that matters.
Re: by midnightsine on Saturday March 09, 2013 @10:50AM (#5348663)
You know, I've actually spent the hours leading up to the SimCity launch coding a simple clone.

Here's a link http://www.browserpolis.com/, you need a webgl enabled browser though.

And a screenshot (http://imgur.com/4ixB2lO) in case you can't see anything.

Re: by networked on Saturday March 09, 2013 @11:03AM (#5348697)
Works here in Firefox 19.0 and Chromium 24.0.1312.56 on 64-bit Linux.

I didn't see the GitHub link in Firefox, though, so in case anybody missed it here it is: https://github.com/dreamingofelectricsheep/browserpolis.

Say, how do you plan to add terrain height to the game? At a glance it seems that your engine wasn't built with it in mind. It might warrant a total rewrite to put it in as early as possible since it's such a major feature of how SimCity-type games play and (especially) look.

Edit: I was thinking more about how you'd manage placing Bezier roads over an uneven heightmap.

Re: by midnightsine on Saturday March 09, 2013 @11:10AM (#5348725)
Heightmap based 3d would be very simple to add via something like f(x, y) -> x, y, heightmap(x, y). The city building genre is essentially "2.5D", as the gameplay itself is purely 2d with the third dimension existing solely in the presentation layer.

Edit: As for the roads on uneven terrain, I'm thinking about deriving z coordinate from another 2d Bezier curve traced along 't' of the road. Control points could be derived from a convex polygon obtained via the road/heightmap intersection.