Old School Race – Mobile Multiplayer Game in AIR
October 26th, 2011
Back to the childhood! Do you guys still remember the “analog era”, where you had to actually build the game from plastic parts in order to make it working? Old School Racer will take you back there, almost. Beautifully designed slot car game from Italy by Creeo Studio, made in Flash Professional, available for iOS, Android and Playbook.
The game has also multiplayer mode, you can play it on one tablet up to 4 people.
Watch the trailer:
Get it now!
Download for iPad
Download for Android
Download for Playbook
The game now temporary free for two days (iOS, Playbook) during the View Conference in Italy. Follow the links above. Free version for Android is available here.
Check out the Old School Race website.
Compiling big Flash/AIR projects with lot of SWFs for iOS
June 13th, 2011
This is a nice little trick that can solve you lot of issues.
When you are building a game for Android or Blackberry Tablet OS in Adobe AIR, you are allowed to load the SWF files on the fly – that’s because the code is interpreted from ActionScript bytecode. With AIR for iOS, there is no such option, all code must compiled into single IPA file (from ActionScript bytecode to native bytecode), which you can make out of one SWF only.
Now – what if I have a project with 30 or 40 levels, where every single level is a single SWF? How do I compile this to iOS?
Well, for testing purposes, you can just use ipa-test-interpreter switch in compiler settings and it will run the same way like on the Android or the BlackBerry Tablet OS. But this method is not allowed by Apple, so you won’t be able to submit the app to the App Store.

Solution = SWC
The proper solution is to compile all levels to SWC libraries, which you link to final SWF file. That way you can make single SWF file with all the necessary levels compiled in it.
In Flash Builder, you have to transform your project from ActionScript project (output SWF) to Flex Library Project (output SWC).

In Flash Pro CS5.5, there is this option in Publish settings

And also last few notes:
- you can use AS3-only projects for AIR, you can’t get AS2 game to iOS with AIR for iOS
- you can load SWF files even on iOS, but the code inside them won’t be interpreted – so it’s useful for graphical assets like animations or vector graphics – you can have a library full of symbols and just pick a symbol that you want
What Creative Suite 5.5 brings to game developers
April 13th, 2011
Building games for mobile devices with various operating systems is one of the biggest challenges for developers. Creative Suite 5.5 makes it easier and allows you to deploy games that run across Android, BlackBerry Tablet OS, and iOS. You can also test your game with different resolutions and DPIs using device profiles in Flash Builder. In Flash Pro, you can rescale content to any screen-size just by ticking one checkbox and so on…

As a game developer CS5.5 brings to you are not only new export options, but also tooling that is tied to mobile publishing and helps you to do things faster.
Let’s have a look at what CS5.5 brings you and how it makes your life easier.
Deploy to web, desktop and mobile
Mobile porting has never been easier. Choose among iOS, Android and BlackBerry Tablet OS or all of them.

Export as Bitmap for better performance
Next to Cache as Bitmap is an option to convert your vector artwork directly to bitmap format right in Flash CS5.5 IDE during export. The good thing is, that you still work with the artwork as with vector, but once you export the SWF, it’s converted to bitmap. Tweening bitmaps is less CPU demanding than vectors and your app will perform better. Unlike Cache as Bitmap, you can rotate and scale the artwork during runtime without having it re-cached – so that’s why Export as Bitmap might work better you. Cache as Bitmap is good choice, but only if you change positions – if you start rotating and scaling – it will re-cache every change. Although this can be solved with cacheAsBitmapMatrix on mobile platforms, Export as Bitmap is another very useful option to consider.

Sharing assets across FLA files
Once you create a new Flash project, you can share Library assets between different FLA files. This makes life easier, especially when you are porting your game to different screen-sizes and devices. While you link libraries together, you can change a symbol in one of the libraries and it will automatically update it in other FLA files.
In the image below I have edited the star in only one of the libraries and it’s been automatically updated in the second one.

Scale content with stage
While porting your game to different screen-sizes, this feature might come very handy. When changing the stage width and height, you can tick “Scale content with stage”, which will resize the content to fit the different stage size.
Copy/paste assets from Illustrator to Flash
I like this one, it makes my workflow faster. Although it’s a feature from CS5, it’s still good to be reminded of it. As you can see, shapes and gradients done in Illustrator are represented natively in Flash.
On-device USB debugging
Helps you to test and debug your app right on the real device. Access multitouch, accelerometer and other device specific features you are implementing in your app.
Device profiles
There are many device profiles ready for you. If there is a new device on the market, just add it by yourself or update the list.

There are many more features you’ll find useful and I hope you will enjoy building games with CS5.5.
Have a look at Lee Brimelow’s video tutorial showing new Flash CS5.5 features.
Check these links for further information about the tooling:
Flash Professional CS 5.5
Flash Builder 4.5
Visit Adobe Game Technology Center for tutorials.
Finally, look at this mobile and tablet game running on iPad, XOOM, iPhone, HTC and more built with Creative Suite 5.5 and AIR 2.6:
FITC Amsterdam Interview About Gaming
April 11th, 2011
Mr. Chris Allen and me featured in this video interview from FITC Amsterdam 2011.
How To Rotate A Cube In 3D With Matrix
April 4th, 2011
Another simple trick to avoid locks when rotating objects in 3D.
Goal: rotate a cube in all axes and avoid axes to switch.
See the problem in a video:
1. Consider following scenario (WRONG):
protected function init():void{ box = new Box(200,200,200,2,2,2); box.setMaterialToAllFaces(new FillMaterial(0xFF0000,1,1));; } protected function onMouseMove(event:MouseEvent):void{ if(!isDragging) return; var deltaX:int = lastX - event.stageX; var deltaY:int = lastY - event.stageY; lastX = event.stageX; lastY = event.stageY; // IMPORTANT PART box.rotationZ += deltaX*Math.PI/180; box.rotationY += deltaY*Math.PI/180; camera.render(); }
When you use rotationZ and rotationY together you will find that by rotating the cube you switch axes and at the end you rotate different axes than you wanted at the beginning.
2. Solution: rotate with Matrix
protected function init():void{ box = new Box(200,200,200,2,2,2); box.setMaterialToAllFaces(new FillMaterial(0xFF0000,1,1));; } protected function onMouseMove(event:MouseEvent):void{ if(!isDragging) return; var deltaX:int = lastX - event.stageX; var deltaY:int = lastY - event.stageY; lastX = event.stageX; lastY = event.stageY; // IMPORTANT PART var matrix:Matrix3D = box.matrix; matrix.appendRotation(deltaX,new Vector3D(0,0,1)); matrix.appendRotation(-deltaY,new Vector3D(1,0,0)); box.matrix = matrix; camera.render(); }
See correct version – rotating a cube with:

Also if you have a different solution – don’t hesitate to share it. I am pretty sure, there are more ways to do this.







