Wonderfl is a service that allows for AS3 coding and swfs to be built online. The site has been running a series of challenges called the Checkmate Challenge. Each month an AS3 superstar sets a challenge each for professionals and amateurs.
Takayuki Fukatsu set a professional challenge to develop an interesting application that used dot patterns to create a visual effect.
I decided to build a generated 3D Cityscape – using the dot patterns to give me a limited variation of windows.
I needed an algorithm that would randomly create the design for a skyscrapers. The building block shapes I decided on were a cube, a cylinder and a tapered cylinder. Each skyscraper was given a maximum number of iterations and a target height. The base was built and each subsequent iteration was at most 70% of the size of the level below it.
3D engine Papervision was used, my choice was restricted here as I was building within Wonderfl.net, which doesn’t have Away3D (my usual weapon of choice) installed. PV3D was fine and did the job well.
The city was built on a grid system, this means I will be able to add roads, traffic, etc at a later date. It employs a very random tower creation system, maybe a Fibonacci sequence pseudo random system would give more useful and recreatable results.
The 3D Cityscape was awarded Knight status and elicited the comment: “The texture of 3D city composed of a monochrome dot was minimal and very fantastic.”
Sources and swf available here.