Home > AS3, News > Globequest

Globequest

October 12th, 2009 alducente

A World of Wonders has just launched Globequest, a game that lets you “travel” around the world to learn about different cultures and places. Learn more about the television series on their website.

Globequest Title Screen

While developing the game was loads of fun, there were a couple challenges that we had to overcome in order to get this game off the ground…(OH SNAP! See what I did there? off the ground? traveling? airplane? no?…okay)

After being presented with the idea, the first thing that came to mind was how to manage the HUGE map the player had to travel around in. I’m talkin’ loading and moving a 6400×1600 bitmap without sacrificing image quality or performance.

Many tests later, we decided that the best way to solve the filesize issue was to seperate the map into 800×600 tiles, keeping low resolution tiles embedded in the swf file so the player can start the game as soon as possible. While the player travels, the high resolution tiles are being loaded in the background, replacing the low res images one by one as they finish loading. Not only does this reduce the total filesize of the main swf, but it also lets the player continue without having to wait for the giant map to load.

Globequest Big Map

As for performance, most of us know that moving something as big as 6400×1600 around on screen can be choppy. To improve the animation, I used the display object’s scrollRect property. For those who aren’t familiar with this handy feature, it basically acts like a mask, displaying only a section of a display object on screen but with way better performance than a mask. Read more about it in the docs here.

So that takes care of the map, but what about the mini games?

Globequest Puzzle

In order to keep the games organized, each one is a separate swf file that gets loaded. This let’s me encapsulate each mini game, keeping its functionality hidden from the rest of the game. A manager had to be created in order to keep track of all the different games and is in charge of displaying a game when needed, communicating the user’s performance to the main swf, and cleaning up after a game so the game engine can be reused.

Videos…so many videos…

Globequest Video

For the videos, we wanted to do something simple, using only basic controls to toggle between play and pause states plus a couple events that we can listen for. The FLVPlayback component, while convenient, has too many bells and whistles for our purpose and using the Video class didn’t give us the amount of control that we wanted. So I decided to go with the built-in VideoPlayer class, which is also a subclass of the Video object but a lot simpler than the FLVPlayback component.

#$%@#!!!

While this wasn’t an issue, it was something that was completely new to me and thought I’d share the experience. Since this is a children’s game after all, we needed to make sure that text inputs filter out “no-no” words. Luckily, there’s only one text input in the entire game (*high-five!). Instead of clearing the field when a bad word is detected, I chose to just disable the “go” button. This makes it less frustrating for children with names like “Dickson”.

Globequest Player: Dickson

Now, how am I suppose to detect inappropriate words? Should I just type out every word I could think of?….Interwebz to the rescue!!! Check out the list. Now the only thing I needed to do was copy the entire list and write a quick script to format it the way I want, instant digital earmuffs.

So in the end, I would have to say that this project was probably one of the biggest I had the opportunity to code on my own (yes, I’m a big boy now). I had a chance to take my time, lay out an architecture, and execute smoothly and with ease. While there were some speed bumps along the way, mostly flash “gotchas”, there was definitely a lot to learn from this project.

Comments are closed.