Monthly Archive for May, 2009

ActionScript 3.0 and PHP 5: Doing Design Patterns

Note: This is one of those posts that begs for reader comments. PHP is a much-loved language of mine, but I just don’t do the kind of applications that require PHP often. As a result, it stays on the shelf until I need it. So, while very familiar with PHP, I do not claim a high level expertise in it. However, judging from the online PHP discussions and PHP publications, lots of developers are well versed in the language. So, for you PHP’ers out there, your comments are welcomed. (Likewise if you’re not familiar with PHP, feel free to comment as well.)

PHP, My Old Friend

PHP has always been a developers programming language. From its inception, you could write PHP using Notepad or TextEdit and not have to worry about some cranky API or IDE. Alternatively, there are plenty of development applications for creating PHP, such as Dreamweaver. Further, you could write email apps as easy as a ‘Hello World’ example. Not only is PHP open source, it is constantly updated and improved by developers working on it because it is important to them. You can plunk it down on top of an Apache server (also open source) and use MySQL (also open source—but maybe not for long) for a database. It runs on Linux, Windows and on Mac OS (it comes standard with Macs as does an Apache server). Further, PHP 5 has real abstract classes! What’s not to like?
Continue reading ‘ActionScript 3.0 and PHP 5: Doing Design Patterns’

  • Share/Bookmark

ActionScript 3.0 Design Patterns at Work Survey

A Three-Question Survey

I’m working on a new post about ActionScript 3.0 Design Patterns at work. To help get an accurate measure of what folks are doing in the ActionScript work world, I put together a simple survey. The survey is made with radio buttons and check boxes; so it only takes a minute to fill out. Click below to take the World’s Easiest Survey:

ActionScript Design Patterns at Work Survey

We thank you in advance, and when we get the post up, you’ll see the results from the survey.

  • Share/Bookmark

Golden Lunch Bucket Contest Winners!

We finally finished judging the contestants and here are the results. Instead of having several categories for age, we decided to have only one because the ages did not have a great deal of range. Each of the winners happened to be from a different country, and so we can claim a true World Wide Contest. Congratulations to all! Download winning entries.


goldenbucketgrand

will_wizardbrazilflag50
William Rafael de J. Ribeiro, Brazil
Our grand prize winner created an interactive “funny face” using the basic Decorator and adding a second component class for a face and four decorator classes for angry, normal, and sad eyes plus a smile decorator. By moving the mouse around you can see the face change and eyes move.

goldenbucketfirst

tcpic100usflag50
Todd Coulson, U.S.
Todd’s entry used a creative combination of elements to build a baseball diamond. The field was a simple rectangle, and it was decorated with an infield, the bases, a pitcher’s mound, boundary lines and players scrambling to the field. Todd is interested in adding to this foundation using other design patterns.

goldenbucketsecond

timofinlandflag50
Timo Hannelin, Finland
Theoretical background for Timo comes from Katariina Nyberg’s article about phyllotaxis, fibonacci and the golden ratio. If we had a grand prize for the best algorithm, it would go to Timo. One algorithm makes an amazing amount of shapes—stars, triangles, squares, lines, shells, spirals…if you are lucky you will see almost all kinds of basic symbols. It also demonstrates that you can change a class in design pattern with a complex algorithm and it doesn’t faze it one bit.

goldenbucketthird

kevo_100ukflag50
Kevo X. Thomson, UK
Kevo had a very simple entry. By changing the x and y coordinates of the three concrete decorators, he was able to rearrange the images. Again, the change was made and there was absolutely no negative ripple effect. This is exactly what a good design pattern is supposed to do.

  • Share/Bookmark

The Naked Flash Designer and the ActionScript 3.0 Algorithm Dope

The Naked Flash Designer

As a general way of making sense out of projects, they are divided into design and development. The design component usually means graphic design, but it can also include the UI (HCI) and information design—the kinds of things Edward Tufte talks about. In other words, design refers to everything that the user actually sees and interacts with. Those involved in design must expose their work to the user. It is in no way shrouded, and hence naked.

Developers’ work, on the other hand, has better cloaking than a Romulan space ship. If something goes wrong, and the program blows a gasket, the user can see a problem, but if things work, even in the most pedestrian program, the programming is invisible. The entire program can be one hack piled on top of another (as was the case with ActionScript prior to ActionScript 3.0), and no one would ever know. So, we programmers are safe to write any kind of code we want, and as long as it works, everyone is happy.

In many respects, most projects are design ones. The look, feel, navigation and interaction of a program makes or breaks it. A beautifully programmed project isn’t worth a bean if it looks poor, is difficult to navigate or interacts awkwardly with the user. Conversely, if a program looks and acts good, no one cares about what’s under the hood as long as it works.
Continue reading ‘The Naked Flash Designer and the ActionScript 3.0 Algorithm Dope’

  • Share/Bookmark

Index: ActionScript 3.0 Design Patterns Principles and Design Patterns at Work

Easy to Find

We got to the point where the posts on the Principles of OOP and Design Patterns and the discussions of introducing Design Patterns to the workplace became so numerous that they were difficult to locate on the blog. This is the first index that we have, and as we continue to grow, we’ll have to add more. (We are certainly nearing that point with MVC and Pure MVC posts.) So, in the “Categories” section of our blog, we’ll be adding indices as needed. Look for the Index category to locate all indices.
Continue reading ‘Index: ActionScript 3.0 Design Patterns Principles and Design Patterns at Work’

  • Share/Bookmark