after playing too much minecraft i wanted to do 'something like it', i.e. persistant and grindy, but it had to be an RTS because i love 'em and it would let me get away with 2D.
* play the game: http://apps.gamejs.org/pirateking/alpha/
* source: https://github.com/oberhamsi/pirateking-gamejs
* a gameplay video (without sound): http://vimeo.com/36223841
a short weekend later, i had the obligatory perlin noise generator pumping out landscapes. which turns out to be the tinyist problem of them all. i spent more time tweaking the noise *rules* to output what i wanted (most of the time...) than implementing the noise algorithm.
the landscape generator now churns out islands with (mostly) interconnected regions and forests & hills in between. it also puts a couple of shop buildings on the map and the enemy spawn portals.
besides that i dug out ye'old boid classes and slapped A* behaviour on the flocks. which is neat! because A* would give you "rough", edgy paths, but the flock behaviour on top of it smoothens it out "for free" (CPU...A* is why i needed webworkers).
during the week i always found time to hammer out the gameplay: you start as the captain with one pirate under your control. you have to survive 9 waves on enemies, which get increasingly stronger and more of the throw-rockets-straight-in-your-face type.
besides the fighting, you hire pirates with the gold you find or get for killing foes. the gold is also well spent on throw-able bombs, or at a doctors to fix up the captain for the next wave.
now how is it an RTS? not much, but in this first version you can at least toggle your pirate squad between "follow me and shoot everything" and "stay here and shoot everything", which also gives you the emergent order "come to me and shoot everything in between".
so that's about it. it has a 5 different enemy types, two weapons for the player, sound and even shows you statistics about how awful you did, when you die
it's fun for roughly 16 minutes, which is about the time you need to play it twice. i overshot my target of making a 5min fun game and am content. if i'm super lazy, i might wait this one out: i think by summer all browsers should play it well and i can tune the gameplay until then and maybe even add protect-the-convoy-missions.