
In the Beginning
Before I launch into my next programming adventure I should figure out what went wrong and what went right with the development of both the PointClickPress engine and with The Great Underground Adventure game. Its important to learn from your mistakes, so here we go.
I started this project because I wanted to learn a PHP framework and I thought it would be straight forward (and fun) to make an in-browser point-and-click style game. Maybe that could’ve been true but, between major life changes outside of this project and getting bogged down in game-engine hell, it ended up taking two years. I think that is way to much time for the small game that was ultimately the result of the project, but then again, its not like I was working on it full time. Sometimes maybe I got an hour a week between changing dirty diapers. I think other people would’ve (wisely?) abandoned this project when so little progress was being made for such little results, but for better or worse I stubbornly stuck with it.
What went right?
1. Choosing the Kohana Framework
I spent a lot of time researching and testing frameworks before I selected one to learn. I’ve touched on this subject before. Kohana made the development of the PointClickPress game engine very straight forward. The framework allowed me to stay organized, leverage existing libraries, and be productive very quickly without getting bogged down in framework guts or configuration. I was even able to find a Kohaha module that came with fully developed user registration, authorization, and admin sections which allowed me to focus on building the game engine and not go through the dry exercise of user management again. Of course, I had spent a weekend building the user admin already by the time I found that nice module.
2. Breaking the project into phases
I broke PCP development into manageable chunks that would be functional and releasable when completed. Software development is an iterative process and you can’t plan for everything along the way. Marking out stopping points in the development allowed me to make sure that I’d get something released. Nothing keeps up my motivation like releasing something playable for people to try.
3. Mobile & desktop support
Right from the start I made sure that PointClickPress was going to work as well as in a mobile browser as it did on a desktop. Every design decision considered mobile. I think it would have been very difficult to ignore mobile and then try to shoehorn the site into a mobile browser after the desktop was done. Everything works equally well on large and small screens. I did go overboard keeping by javascript to a minimum however.
4. Using photos for game art
I really like how the photos came out for The Great Underground Adventure. I think they look great and since you are (for the most part) exploring real locations it adds an extra level of interest to the game. Scouting and taking the photos was also an adventure that lead me to all sorts of interesting places.
What went wrong?
1. Getting lost in game engine hell
Despite choosing a light framework that had many built in libraries I still over engineered the PCP game engine and administration area way beyond what was needed to make a straightforward point-and-click adventure game. If I had just kept my head out of the clouds and built only what I needed to get my game working I’d have finished a year earlier. I kept wanting the engine and admin to be “perfect” before I started building the game. I was re-architecting things constantly and still finding ways to refactor and abstract. Eventually I just had to stop!
I also stubbornly refused to use ORM, so as my database model evolved I was constantly tinkering with the SQL. Later on I was constantly fixing SQL bugs rather than just loading the ORM library at the start and being done with it.
I greatly admired how WordPress allows a user to add additional functionality easily. I wanted the engine to have plugins, to be extensible, so that end users could easily add features that I hadn’t thought of. I spent way to much time thinking of how to de-couple functionality from the engine “core” than was healthy. Depending on the ability for users to extend the existing functionality by adding their own clickable actions was also a trap that eventually doomed the idea of a public PointClickPress portal game website due to security issues.
2. User-created extension security issues derail game creation
I consider this the biggest problem with the current version of PointClickPress.com. This is not an issue for the stand-alone version however.
The first iteration of PointClickPRess was as single-user, multi-story creator. The use-case was that an author could self-host an installation of PCP and build “stories” (aka games) with it. In this use-case PCP supported only a few out-of-the box clickable actions such as linking two locations together. The plan was that an author could easily write any intermediate to advanced click actions directly in PHP and connect to the PCP API. It is very straight forward to create a small action file and place it in the action directory. Then it was available to use. Alternately there was an out-of-the-box clickable action that was simply a PHP eval() call. This allowed the user to type PHP in from the admin area without needing to create a file. This ability to create new actions easily allowed PCP to support whatever an author would want.
Of course neither of these options is viable on a multi-user public installation such as PointClickPress.com. The authors no longer have access to the filesystem, and allowing the use of eval() is also out of the question for security reasons. This loss of extensibility severely hinders game development. The built-in clickable actions by themselves don’t do much. They were only meant to be shortcuts for simple tasks. Now an author on PointClickPress.com must chain many simple actions together to equal what one action on a self-hosted version of PCP could do. This is what I have done for The Great Underground Adventure. Often there is a cascade of three or four clickable actions that are called behind the scenes as the result of one click. Chaining actions together is a fairly arduous task. And I don’t expect anybody to enjoy using the public site for this reason.
3. Using photos for game art
Using photos for game art was a million times harder than I thought it was going to be. I talked about this already in a blog post here. I estimate I took around 3000 photos over the course of two years. Many I got on vacations, but also I scouted locations around me. Probably about 400 of these photos made it into the game either by themselves or as part of a composition. I’m not a strong “Photoshopper”, so creating the composite photos, such as the views surrounding the cable car area. Took many evenings to get right.

Conclusion
In the journey from the start to the end of this project the game felt as if it became an after-thought unfortunately and the PCP admin seemed to be the central focus. Maybe I’m just born to be a back-end programmer. I certainly accomplish my goal of learning a PHP framework from this project. I did plan on making other games using this engine, but now that I am finished I find myself brainstorming the next project around learning new technologies. I’d like to play with the canvas and try designing a multiplayer game. Maybe learning Python and Tornado, or Node.js, at the same time. I’m not sure many people but me will enjoy playing The Great Underground Adventure, but I’m proud of it. I think its charming in its own decidedly low-tech way. The same goes for the PointClickPress engine.
If anyone wants to try their hand at building a game you are welcome to give it a try at PointClickPress.com or you can download and host your own copy. PointClickPress is open sourced under the BSD license and is available for download at SourceForge.net.