Yes, it's another one. Except this ones a little different. I don't (yet) know much about arrays, or things such as that, but I wanted to create a sort of terrain generator that created a random terrain for a side scrolling "survival game". So I created the most simple one I could think of.
This is created only with a single "rock" object, with ten image points on random spots, and each rock at the beginning of the layout spawns another rock at a random angle and image point, which in turns spawns another rock etc... until 4 seconds, and each rock stops spawning more rocks, and the "terrain" is complete. After that, the rocks are pasted onto a canvas object and deleted, which makes the game run far faster than having hundreds of rock objects on the screen.
<img src="http://i56.tinypic.com/ke9jjd.jpg">
I know its not as fancy or good as the other countless generators on this forum, but I thought it worked OK and it works well anyway for the game I'm building. It's also not very efficient, but, tell me what you think!
CAP:
http://dl.dropbox.com/u/31490769/terraingen.zip