Saturday, November 7, 2009

Unreal Development Kit

The Unreal Development Kit (UDK) can be downloaded and used to make games using the Unreal Engine 3. However, there is a licensing fee if you release the games for profit which is supposed to be affordable even for independent developers.
November 5, 2009 - "Epic Games, Inc. announces the launch of the Unreal Development Kit (UDK), a free edition of Unreal Engine 3 that provides community access to the award-winning toolset like never before. This software release is available to anyone interested in using 3D game engine technology, including game developers, students, hobbyists, researchers, creators of 3D visualizations and simulations, and digital filmmakers. Anyone can start working with the industry-leading Unreal Engine 3 toolset by downloading UDK at www.udk.com, where detailed product features, technical documentation, commercial licensing terms, support resources and more are also available.

An unprecedented milestone in game development, the release of UDK awards free access to the same world-class tools and technology used by many of the world’s best video game developers and publishers. Unreal Engine 3 is a constantly evolving game engine, and UDK contains all the most recently added features and technological enhancements, including many that have yet to be seen in an Unreal Engine game. Furthermore, Epic Games will release ongoing, upgraded builds of UDK for free.

There is no charge for noncommercial or educational use of UDK. Over 100 academic campuses currently use Unreal Technology as part of teaching game development-related courses, and colleges with plans to incorporate UDK into their curricula include the University of Pennsylvania, North Carolina State University, The Art Institute system of schools, Drexel University, Westwood College, DeVry University and Atlantic College, with many others to be announced.

Individuals and companies wishing to develop software for commercial purposes should refer to licensing terms at www.udk.com/licensing. Commercial terms have been structured to make it easy for independent developers, start-up firms and seasoned professionals to use UDK with minimal financial barrier from concept to deployment. UDK is currently for PC use only, although console support is under consideration. Developers approved to make games for Xbox 360® and PLAYSTATION®3 may inquire for more information by emailing udklicensing@epicgames.com."

[Source: udk.com]
They even have a 74 page PDF document on how they created a simple game called Whizzle (vertical scrolling puzzle game) using only the UDK.

Thursday, October 15, 2009

[Event] 'Doing Business in Singapore' @ Tampines Regional Library

Going indie means you will need to probably consider setting up a company.

Well, I have no idea. Hopefully I will know more after November 7. *sigh* It's a Saturday.

"
'Doing Business in Singapore' at Tampines Regional Library on 7 November 2009






12 October 2009

Thinking of starting a business? Planning to be an entrepreneur?

Here is an opportunity to know more about being your own boss at an upcoming talk of the popular ACRA@Heartlands series. Jointly organised by the Accounting and Corporate Regulatory Authority (ACRA) and National Library Board (NLB), the talk on ‘Doing Business in Singapore’ will provide you with information and useful tips on starting a business.

To register, please log on to http://golibrary.nlb.gov.sg/Event.aspx?EventID=30320


Date : Saturday, 7 November 2009
Time : 1.30pm to 4.30pm
Venue : Auditorium, Tampines Regional Library

Jointly organised by ACRA and NLB

" - [Source: acra.gov.sg]

Registration is absolutely free.

Tuesday, October 13, 2009

Review: Battleships Forever

Battleships Forever is a game in development by 22 year old Singaporean poly grad and indie game developer, Sean "th15" Chan. It was a IGF 2008 Finalist where it received a "Design Innovation Award".
"I like games that have depth and strategy to them and as such I try to make intelligent games. As far as possible, my design philosophy is to keep the player engaged all the time and to have a good reason for everything that exists in the game. Every gimmick, every unit, every mechanic is there to encourage a particular play style. When I make games, I think about specific scenarios that I think would be exciting." - Sean

During an interview by GameDev.net, Sean mentions that he initially started making custom maps for Warcraft 3 and then progressed to using Game Maker.

Battleships Forever is a 2D real-time strategy (although it is more tactical, with no resource gathering or diplomacy) where you control multiple spaceships and fight other spaceships. The main feature of it is that each spaceship is built from multiple modules like: turrets with fixed firing arcs, deflector shields, linking structure, etc and each can be individually destroyed. Thus, positioning is very important and you will have to decide between facing your offensive modules or protective modules towards the enemy.

There are currently 17 pre-designed spaceships that you can control and over 50 enemy designs, each with their own weakness and strength. Also, you can create your own custom designs. [Download: wyrdysm.com]





Sean has said that Battleships Forever is inspired by and loosely based on Warning Forever by Hikoza.T.Ohkubo, where the each round had only one boss which evolved based on how you killed it the previous round. [Download: cnet.com]






If you like the concept where spaceships are modularized, then you may wish to also check out another indie game, Captain Forever (US$15) which puts you in control of a single ship that you need to upgrade in battle using part from destroyed enemy spaceships.

Wednesday, September 23, 2009

Games Convention Asia

Last week end, the Games Convention Asia was held here in sunny Singapore at Suntec.

While no where as big as E3, the main Leipzig Games Convention or the Tokyo Game Show, it still attracted 102,500 attendees.

I am not the kind of person who takes photos, so here are a few from Kotaku's write up of it:







[Pictures: Kotaku.com]

Wednesday, September 16, 2009

Review: Red Bull Soap Racer

A while back I got demoralized when I saw how Papervision3D slowed down when building complex scenes. After taking a look at this racing game, I realized that's any slowness I noticed previously in other games is due to unoptimized/inefficient use of Papervision3D.

The game is a cartoon-ish kart racer where you can fully customize your kart and then race with other friends online. Even race tracks can be customized too. While the game concept is not new, this may be the first time that it has been done using flash.



Our friends at Less Rain have set once again the benchmark for 3D games in Flash, using the powerful combination of Papervision3D and Box2D. Check out their blog for more info.

[Source: papervision3d.org]


FYI, they used Box2D for physics as Papervision3D does not include physics.


Another thing worth mentioning is that it is brought to us by Red Bull. This is what I call a good advertisement (and something that I will "watch" repeatedly).

Saturday, September 12, 2009

Tool: PasteBin (collaborative debugging tool)

Every wanted to share a short snippet of code online with others and still preserve the native language formatting?

I have. I been annoyed with how all the nice coloring, indentation and italics got lost when I copied a piece of code from my editor to a web "rich text box".

A friend of mine shared a small function using PasteBin a while back; and now I can't imagine sharing code any other way.

When you paste a snippet of code, you select the language you want to format it in and there is a wide selection to chose from including AS3, etc.

It then generates a link for you that you can send to your friends, e.g. http://flash.pastebin.com/mc95f230.

You can post anonymously or log in so all your posts are linked. Also, anyone can add their changes as a comment.

Friday, September 4, 2009

Pretty pictures

When making a game, it is always nice to have inspiration to draw on.

One of my interests has always been space ships; and one good site that frequently have new concept art is Concept Ships.

Here's a few to show you what you can find there:


[Artist: Andrew Lee]


[Artist: Mike Doscher]


[Artist: Alfredo Dosztal]

Wednesday, August 26, 2009

[Concept] Coding Tricks

I was reading an article of Dirty Coding Tricks that game developers use to meet deadlines or simply cut down work needed. Here's a few I found interesting (some of which were comments posted by readers):

"At university there was a team (not related to me, but these guys are the perfect example :P) that made a FPS flash game...

For some bizarre reason, the programmer instead of checking if you was colliding with the wall and not allow you go there, he made the inverse, he checked if there was a wall, and allowed you to move parallel to it...

This sparked a bizarre bug: In crossings, you could not actually cross, only turn to the passage on your left or right.

The deadline was closing, and they had no idea on how to fix it...

Then the team writer fixed the issue! He told the artist to draw a animation of hands touching the walls, and then he wrote in the story that the protagonist was blind and needed to touch the walls to know where he was going.

-Hélder Gomes Filho



Back on Wing Commander 1 we were getting an exception from our EMM386 memory manager when we exited the game. We'd clear the screen and a single line would print out, something like "EMM386 Memory manager error. Blah blah blah." We had to ship ASAP. So I hex edited the error in the memory manager itself to read "Thank you for playing Wing Commander."

- Ken Demarest



I was fresh out of college, still wet behind the ears, and about to enter the beta phase of my first professional game project -- a late-90s PC title. It had been an exciting rollercoaster ride, as projects often are. All the content was in and the game was looking good. There was one problem though: We were way over our memory budget.

Since most memory was taken up by models and textures, we worked with the artists to reduce the memory footprint of the game as much as possible. We scaled down images, decimated models, and compressed textures. Sometimes we did this with the support of the artists, and sometimes over their dead bodies.

We cut megabyte after megabyte, and after a few days of frantic activity, we reached a point where we felt there was nothing else we could do. Unless we cut some major content, there was no way we could free up any more memory. Exhausted, we evaluated our current memory usage. We were still 1.5 MB over the memory limit!

At this point one of the most experienced programmers in the team, one who had survived many years of development in the "good old days," decided to take matters into his own hands. He called me into his office, and we set out upon what I imagined would be another exhausting session of freeing up memory.

Instead, he brought up a source file and pointed to this line:

static char buffer[1024*1024*2];

"See this?" he said. And then deleted it with a single keystroke. Done!

He probably saw the horror in my eyes, so he explained to me that he had put aside those two megabytes of memory early in the development cycle. He knew from experience that it was always impossible to cut content down to memory budgets, and that many projects had come close to failing because of it. So now, as a regular practice, he always put aside a nice block of memory to free up when it's really needed.

He walked out of the office and announced he had reduced the memory footprint to within budget constraints -- he was toasted as the hero of the project.

As horrified as I was back then about such a "barbaric" practice, I have to admit that I'm warming up to it. I haven't gotten into the frame of mind where I can put it to use yet, but I can see how sometimes, when you're up against the wall, having a bit of memory tucked away for a rainy day can really make a difference. Funny how time and experience changes everything.

- Noel Llopis"

[Source: GamaSutra.com]

Friday, August 21, 2009

Review: I MAED A GAM3 W1TH Z0MB1ES!!!1

This XBox 360 Live Arcade game, I MAED A GAM3 W1TH Z0MB1ES!!!1 is my definition of a realy simple yet fun game.



From the title of this game (which is almost the only lyrics of the soundtrack), I think you realise what the creator of this game is implying. Games with zombies are the current fad. So yet another zombie game to join the ranks of Left 4 Dead, Plants vs. Zombies, Killing Floor, Burn, Zombie Burn!, etc

And killing wave after wave of zombies really does feel good. This game is the pure essense of it.

FYI, It's going for just 80 points (or about a dollar).

Thursday, August 20, 2009

Concept: Custom TCG cards from your MMO character

The world of gaming is not only on video games on the PC, consoles and portable devices; it also includes board games, miniatures, card games, Trading Card Games (TCGs), etc.

I would saw that video games and card games are being produced based on each other. For example, Magic: the Gathering (TCG) has expanded into Magic Online (PC game), likewise World of Warcraft (PC game) has expanded into World of Warcraft: Trading Card Game and World of Warcraft: Miniatures Game.

However, Sony Online Entertainment's Free Realms has come out with a MMO (PC game), a Physical TCG and a Digital TCG, all at the same and linked them in a unique way.

"What Is a Digital TCG Card?

The Free Realms Trading Card Game is built right into the Free Realms virtual world! Click the card fan icon on the menu dock, and you'll be taken into the TCG.

What Is a Physical TCG Card?

The Free Realms Trading Card Game is also a physical trading card game manufactured by Topps™ and is available wherever trading card games are sold!

The ... Starter Pack contains ..., exclusive virtual rewards and your first-month Free Realms Membership!"

[Source: freerealms.com]


As you can see they have tightly coupled these two TCGs to their PC game and vice versa; and that's not all. The have come up with a new and innovative way to link them together: they allow players to use their character in the MMO to print out cards for the TCGs.

From MMO
Step 1: Dress up your character from the MMO.

Converting from MMO to TCG
Step 2: Your TCG personal card stats are based on your MMO character stats.

To TCG
Step 3: The finished card is ready for printing or use in the digital game.

Step 4: Trade your personal card with friend!

"Sony Online Entertainment has teamed up with trading card company Topps to let players create their own official personalized cards for the Free Realms collectible card game.

The Duelist on Demand Program allows players to turn their Free Realms character into a personalized card for use in the physical version of the tie-in trading card game. Using Topps' print-on-demand technology, players will be able to create and share themselves with friends in a distinctively family-friendly way."

[Source: Kotaku.com]

Thursday, August 13, 2009

New forum for this blog

As suggested by a friend, I have just created a forum for everyone to discuss game development in Singapore. It is still a work-in-progress.


I hope that you enjoy using it. ;D

Saturday, August 1, 2009

Unity - Game Development Tool

Unity (or "Unity3D" as it was first known as). It is currently at version 2.5.

It is a multi-platform game development tool, designed from the start to ease creation. A fully integrated professional application, Unity just happens to contain the most powerful engine this side of a million dollars.

Besides publishing standalone games, it has its own web player add-in (the download is about 9 MB) for browsers and IPhone publishing (at an additional charge). Currently in two versions: Unity Indie (US$199) and Unity Pro (US$1499).

"Unity supports three scripting languages: JavaScript, C#, and a dialect of Python called Boo. All three are equally fast and interoperate. All three can use the underlying .NET libraries which support databases, regular expressions, XML, file access and networking.

Scripting is frequently thought of as limited and slow. But in Unity your scripts are compiled to native code and run nearly as fast as C++. You get the fast iteration times and ease of use everyone loves about scripting languages."

[Source: Unity3D.com]

That seems very believable after viewing their Tropical Paradise demo.

Also, according to some bloggers, it is apparently easy to convert a game written with Papervision3D (Actionscript) to Unity. Something which they mostly do so as to publish their games to the iPhone.

Something to comeback to once I made something with Flash.



Update:

Here are some reviews/comments on Unity:
DevMaster.net - Engine details of Unity
StackOverflow.com - What’s the best indie game development environment?

Thursday, July 30, 2009

Code Optimization in Actionscript

3D graphics in Flash are usually handled by the CPU almost no assistance of any fancy 3D acceleration GPU. Thus, framerate is a very important concern.

I found a very useful guide on Code Optimization in Actionscript. For exampled, it states:

"Denormal numbers are floating point numbers that are really small. When such a number occurs the CPU switches into denormal mode and calculations become very slow.

Example


In this example the framerate will jump from approximately 40fps to 1fps. The reason are denormal numbers.


private var _denormals: Vector.;

private function init(): void
{
_denormals = new Vector.( 0xfffff, true );

var n: int = 0xfffff;

while( --n > -1 )
_denormals[ n ] = 1e-256;//very small number!

EnterFrameProvider.connect( enterFrame );
}

private function enterFrame(): void
{
var n: int = 0xfffff;

while( --n > -1 )
_denormals[ n ] *= 0.5;//do some calculations with very small numbers
}


ActionScript Solution

There are a couple of solutions to deal with denormal numbers. Some try to avoid them by adding always a very small value or by adding some white noise. In ActionScript the best and most simple solution is by adding and subtracting an anti-denormal constant.
[edit] Solution

Example

This solution is easy to implement in ActionScript and will result in real zero values.


_denormals[ n ] = _denormals[ n ] * 0.5 + 1e-18 - 1e-18;//avoiding denormals


This is the same example with the fix for denormal numbers. The framerate will now stay at approximately 40fps."

Saturday, July 25, 2009

Using Actionscript for 3D

Recently, I have toying around with 3D in flash. There are several frameworks to produce 3D graphics (e.g. Papervision 3D, Sandy, Away3D, Yogurt3D, FIVe3D, etc) which you can use together with other frameworks for physics (Wow-Engine, JigLibFlash, box2dflash, APE), object distortion (AS3Dmod), augmented reality (FlarToolKit), etc.

When working, I quickly realized that using primitive shapes to build a 3D scene with ActionScript was only useful to a certain point. To supplement this, some allow the importing of COLLADA models, which is a standard that represents models with an XML file and an image used for texture mapping.

When searching for some models to use in my projects, I stumbled on Google's 3D Warehouse (a place that stores 3D models that people created) and SketchUp (a tool to create 3D models).


[Source: papervision2.com]

Hope you found that interesting.

Thursday, July 9, 2009

Flash Kit Community Forums

I recently been spending a lot of time on the Games sub-forum on the Flash Kit Community Forums.

There are lots of existing and new Flash developers discussion making games there.

Check it out if you have time.

Monday, June 29, 2009

Using FaceBook API from ActionScript

About two month ago, FaceBook announced it's Open Stream API (also known as Facebook Connect) that allowed applications to interact with FaceBook and replicate most of it features.

To demonstrate this, they got their partner, Adobe to create Facebook for Adobe AIR, which is an application that runs on your desktop. You log in with your Facebook account and can then read your News Feed and publish content to your Wall and friends' News Feed.

The source code for this application is publicly available and I recently took a look at it.
(UPDATE: there is now a project on Google Code for it too)

Of particular interest is how it communicate with FaceBook:


var request:URLRequest = new URLRequest("http://api.facebook.com/restserver.php");
request.contentType = "application/x-www-form-urlencoded";
request.method = URLRequestMethod.GET;
request.data = urlArgs; // a flash.net.URLVariables object


But all this is nicely encapsulated for you in the "fb" package.

Some uses would be to upload screenshots and post achievements in Flash games directly to your FaceBook wall. Or it can be used to allow easy multiplayer game matchmaking with your friends.


The source code from this application also show some advanced ways to display HTML formatted text using ActionScript (and Flex). Thus, its a rather nice example.


Also, here is a tutorial (from Adobe) that walks beginners like me on how to register a FaceBook application and get its API key, however it uses Flex instead of Flash.

Thursday, June 25, 2009

The new mouse

Mice replaced joysticks for gaming a decade ago; however here is something that might finally replace them.



What to know more, check out Novint.com.

Wednesday, June 24, 2009

Games I really liked

Below are 10 games (or series) that I really like playing, of all time.

(In the order that I started played them)

1. Sid Meier's Civilization - taught me a lot about history and made it fun; always wanted one more turn

2. Wing Commander - great sound, cinematics and story for its time; NPCs in the game mattered; often your role was just a part of a larger battle

3. Master of Orion - deep strategy, interesting research, enjoyed designing my own ships

4. Command and Conquer - best installation ever; very polish; nice cut scenes too

5. Sid Meier's Pirates - who does not love playing as a pirate; enjoyed improving my ship

6. Diablo - dark and very atmospheric; loved the feeling of getting a rare drop; freedom to play which ever part I wanted, fast drop-in even in multilayer

7. Counter-Strike - fast action, lots or re-playability with user-created content

8. World of Warcraft - simple to get in; very polished; lots of activities to do; constant addition of new content

9. Ultracorps - only web based game that made my list; diplomacy is part of the strategy; your decisions often have a major impact

10. Guitar Hero - taught it was dumb till I tried it; challenging; great fun to play with friends



Why not list a couple of yours?

Friday, June 19, 2009

Consoles Overrun By Motion Controllers at E3

Now that the dust has settled after E3, I like to mention about what caught my attention the most.

The solid sales from Nintendo of their Wii which targeted the casual, non-gamer with their motion controller has resulted in the other two consoles (Microsoft's Xbox 360 and Sony's PlayStation 3) announcing plans for their own motion controllers.

Microsoft's Project Natal seems the most genre changing as it makes people the controller. Its' facial and voice recognition is also something that will likely become expected not only in game consoles, but likely most electronic devices (e.g. changing your air conditioner's temperature to suit who is in the room, blocking mature-rated TV shows when kids are around, etc). Let's hope the cost is reasonable.



Nowadays it is even easier that ever for an indie game company to make a console game. With freely available development kits and publishing platforms (of either the Xbox Live Marketplace or PlayStation Store), making a console game has never been easier.

Time to start dreaming of making games that make use of motion control.

Monday, June 1, 2009

E3 First Look @ GameTrailers.com

The years biggest game expo is coming, E3. Here's a "first look" of some of the new information will be announced at E3.



[Source: gametrailers.com]

Friday, May 29, 2009

Wing Commander Saga

The Wing Commander (WC) series was one of the first few that really got me into PC gaming. I would also speculate it was the reason Sound Blaster sound cards became popular too. The first WC came out almost two decades ago in 1990. Sadly, Origin who developed it is no more.


A while back a group of people got together and began work on a project to make a updated WC game, Wing Commander Saga. Using a modified and enhanced version of the Freespace 2 engine’s source code has been released to the public. It will be set in the same time frame as WC3 where humans and Kiralthi are still at war (and not WC4).




Cockpit View


TCS Concordia, the carrier you launch from in WC2.
[Source: WCSaga.com]

Quite an amazing piece of work from an indie team.

By the way, it will be free to play when it is done. And they expect to be done "soon". They already have a demo ("prologue") out.



While on the topic of WC, there is a "work-in-progress" remake of WC Privateer, named WC Privateer Gemini Gold, that is striving for the same missions and look-and-feel as the original.



Cockpit View


In the hangar.
[Source: Priv.SolSector.net]

This is done by another indie team and also available for free.

Friday, May 22, 2009

Interview: Jonathan Blow discusses his platformer, Braid

Jonathan Blow is the developer of Braid, a platformer that makes use of the manipulation of time to solves puzzles. The game first came out on XBox 360 Arcade, and is now out on PC.

You can download the demo from Steam, here.

It has a lot of similarities to platformers like Mario done on purpose to make it sort of a platformer parody. This also allows Braid to introduce the concept of time manipulation (rewind, slow, etc) from early in the game. For example, your character never dies in Braid, instead you are allow to rewind when that happens.



Here's some excepts form his interview with Leigh Christian Ashton of TIGSource:
"I have to admit I don’t really enjoy programming very much any more, because in order to get things done I have adopted a style of programming that makes it as simple as I can, so that it is just easy to get things done, and it only requires time and a lot of typing. So I am not really solving any difficult puzzles or challenges when programming, as beginning programmers might. On the plus side, this means I can program in a relatively efficient manner; on the minus side, it’s a less-engaging activity. I make up for that on the design side; whether I am making a prototype or a full game, it’s about exploring some interesting space of ideas. Programming is now just the implementation detail of how I do that exploration.

It’s not really about innovation so much as exploring interestingness. There is this idea of chasing innovation in game design that I used to be a big proponent of, but that I now suspect is a little bit misdirected."

"I try to encourage people to be willing to delete stuff that is mediocre or just kind of good – or at least put that stuff in a closet for some future day – so that they can focus on the stuff that is great. Many people don’t think that way, though. When it is so hard to get anything substantial done, you just don’t want to throw away any of your hard-earned progress."

"I think gameplay innovation can result in things that are interesting, but at the same time it doesn’t automatically result in something that is deep—often it’s a gimmick. I am interested in deepness and richness of game design. At the same time, I think if a designer is working on something he really cares about, and is really exploring some ideas in his own style, bringing his own particular insight to the table, then he will automatically come up with something different than most other games; furthermore, this will be a deeper, more-compelling kind of innovation."

[Source: tigsource.com]
So innovation does not mean interesting, but interesting usually mean innovation.

Also, the phrase "less is more" comes to mind when he challenges others to delete anything that is not extremely core to the experience. While this may cause a game to receive a great review, it does not necessarily mean the game will be played for a long time (and thus maximizes profitability). Will have to see how many people are still playing Braid a year from now.

Sunday, May 17, 2009

Tutorial: Simulating inertia in 2D with Flash

I was playing around with ActionScript 3.0, in particular making an object accelerate in 2D to simulate inertia. Below is a partial snippet of code that I ended up using:

public var thrust:Number = 1;
public var decay:Number = .9;
public var speed:Number = 0;
public var xSpeed:Number = 0;
public var ySpeed:Number = 0;
public var maxSpeed:Number = 15;
public var xThrustPercent:Number = 0;
public var yThrustPercent:Number = 0;

public var leftkeyPressed:Boolean = false;
public var rightkeyPressed:Boolean = false;
public var upKeyPressed:Boolean = false;

// Respond to keyboard presses
stage.addEventListener( KeyboardEvent.KEY_DOWN, keyPressHandler );
stage.addEventListener( KeyboardEvent.KEY_UP, keyReleaseHandler );

// Update movement every frame
addEventListener( Event.ENTER_FRAME, enterFrameHandler );

protected function keyPressHandler( event:KeyboardEvent ):void
{
  switch( event.keyCode )
  {
    case Keyboard.LEFT:
      leftKeyPressed = true;
      break;

    case Keyboard.RIGHT:
      rightKeyPressed = true;
      break;

    case Keyboard.UP:
      upKeyPressed = true;
      break;
  }
}

protected function enterFrameHandler( event:Event ):void
{
  if( leftKeyPressed )
  {
    rotation -= 10;
  }
  if( rightKeyPressed )
  {
    rotation += 10;
  }
  if( upKeyPressed )
  {
    // Calculate how much thrust to apply to
    // x and y based on the rotation of the object
    xThrustPercent = Math.sin( rotation * ( Math.PI / 180 ) );
    yThrustPercent = Math.cos( rotation * ( Math.PI / 180 ) );

    // Apply the trust to x and y
    // thus accelerating the object
    xSpeed += thrust * xThrustPercent;
    ySpeed += thrust * yThrustPercent;

    // Maintain speed limit
    speed = Math.sqrt( ( xSpeed * xSpeed ) + (ySpeed * ySpeed ) );
    if( speed > maxSpeed )
    {
      xSpeed *= maxSpeed / speed;
      ySpeed *= maxSpeed / speed;
    }
  } else {
    xSpeed *= decay;
    ySpeed *= decay;
  }

  // Move object based on calculations above if ship is visible
  y -= ySpeed;
  x += xSpeed;
}


Obviously, the keyReleaseHandler (which is not shown) does the opposite of keyPressHandler.
Also, you can add a brake functionality to the down arrow if you wish.

Some interesting maths used:

sin( 2700 ) = -1
sin( 00 ) = 0
sin( 900 ) = 1

cos( 00 ) = 1
cos( 900 ) = 0
cos( 1800 ) = -1


Since rotation specifies the rotation of the object in degrees and ActionScript's trigonometric functions (e.g. sin, cos, etc) use radians, you have to convert between the two.

radians = degress * ( PI / 180 )


Lastly, calculating the diagonal distance is done using this simple formula we all learn in school.

diagonal distance = sqrt( x2 + y2 )

Concept: Procedurally-generated content

Designing content (like levels, models, maps, items, etc) by hand can take a lot of time, so this acts as a limit the amount of detail that is put into a game.

The alternative is to generate the content procedurally, which means to create programs that do the design for you in a random and believable way.

One early example is the games Diablo which always create new areas and items so that players never have the same experience twice.

Here's a video that demonstrate this concept:



There is a HQ (Higher Quality) version which you can view by clicking on the "HQ" button on the bottom right of the video.

If you like it, you can download it as a screensaver.
(Note: press "F1" for settings)

Saturday, May 16, 2009

Cinematic: Team Fortress 2's Meet the Spy

Valve has been doing a series of updates to their team-based FPS, Team Fortress 2.

They have been updating each class one at a time, probably to maximize the news coverage they receive, making short movies for each.

Here's a new movie of theirs showcasing their Spy class.



[Source: Kotaku.com]


They really managed to fit in the personalities of each class in this short video.

Truly inspirational...

Friday, May 15, 2009

Tutorial: Handling touch gestures in Flash Lite

I came across this interesting tutorial on how to handle touch gestures made famous by Iphone in a Flash Lite application.

Here's the code from the tutorial:

var startX:Number;
var startY:Number;
var endX:Number;
var endY:Number;

var gesturesListener:Object = new Object();

gesturesListener.onMouseDown = function()
{
  startX = _root._xmouse;
  startY = _root._ymouse;
}

gesturesListener.onMouseUp = function()
{
  endX = _root._xmouse;
  endY = _root._ymouse;

  checkGesture();
}

Mouse.addListener(gesturesListener);

// minimum length of an horizontal gesture
var MIN_H_GESTURE:Number = Stage.width / 3;
// minimum length of a vertical gesture
var MIN_V_GESTURE:Number = Stage.height / 3;

// flags for each kind of gesture
var UP_TO_DOWN:Number = 1;
var DOWN_TO_UP:Number = 2;
var LEFT_TO_RIGHT:Number = 4;
var RIGHT_TO_LEFT:Number = 8;

function checkGesture()
{
  var xDelta:Number = endX - startX;
  var yDelta:Number = endY - startY;

  var gesture:Number = 0;

  if(xDelta > MIN_H_GESTURE)
    gesture |= LEFT_TO_RIGHT;
  else if(xDelta < - MIN_H_GESTURE)
    gesture |= RIGHT_TO_LEFT;
  if(yDelta > MIN_V_GESTURE)
    gesture |= UP_TO_DOWN;
  else if(yDelta < - MIN_V_GESTURE)\
    gesture |= DOWN_TO_UP;
  if(gesture > 0)
    handleGesture(gesture);
}

function handleGesture(gestureFlags:Number)
{
  if(gestureFlags & LEFT_TO_RIGHT)
    trace("left to right gesture");
  if(gestureFlags & RIGHT_TO_LEFT)
    trace("right to left gesture");
  if(gestureFlags & UP_TO_DOWN)
    trace("up to down gesture");
  if(gestureFlags & DOWN_TO_UP)
    trace("down to up gesture");
}


It was from a mobile games development blog, Jappit which covers all the different platforms, namely J2Me, Flash Lite, Symbian, Iphone and Andriod.

Monday, May 11, 2009

Concept: Making money from advertising

As an indie developer, one possible source of revenue is from advertising.

Games are made available freely so as to generate web traffic to the site, which generates a small amount revenue each time users view the site, however this revenue is generated on each visit and does not require any purchase from players.


There are two possible routes for this: self-hosting and third-party hosting.

With self-hosting, the creator gains all the revenue from advertising and does not require to share it with anyone else. However he has to pay for the hosting of his application, manage the advertisements (usually through Google's AdSense) and handle publicity of his game.

With third-party hosting, the creator can publish his game to one (or more) of the many game sites which will host if for free, manage the advertisements and help with the publicity of the game by listing it on their site (and sometimes providing reviews, ratings and usage statistics). In exchange for this, the revenue from advertising is shared.


Here are some such game sites:


Newgrounds: They have been paying for embedding advertisements into Flash games for a while, and recently (on 14 May 2009) started paying for any game (or content like animations, music, or even blogs) hosted on their site.
If you make browser games, you know the Flash portal Newgrounds. They’ve had their own embedded ads service since about May 2008, but now they’ve kicked it up a notch. Newgrounds now automatically share their ad revenue whether you sign up for the ads or not.

For example- I made a game recently and got it sponsored by a third party. The terms were that I wasn’t allowed to embed any ads in the game. So I didn’t, there are no ads in the game. Now Newgrounds will pay me regardless just because my game’s on their site. Not just games either, ad impressions come from audio submissions, animations and even my damn userpage. I made 3 cents for having a blog. Thanks!

[Source: TIGSource.com]

GameJolt: Unlike other sites, they deal with not only Flash games but freeware too. They are just one of the new independent gaming sites that have been recently appearing.
Their new Ad Revenue Sharing plan will go into closed beta very soon, at which time every member who has signed up to the site and uploaded at least one game will go into a hat to join the beta and start earning a whopping 50% of the ad monies.

[Source: IndieGames.com]

Kongregate: A flash game site that has been around since 2006, they have built quite a reputation for themselves. Sadly, unless you host on their site exclusively and use their API, the percentage of revenue that they give you is much lower than other sites.
By default, all developers receive 25% of the ad revenue generated from their games. This includes all ads within the games and any potential ads on the game page that may be added in the future. Games that are integrated with all of Kongregate’s APIs earn an additional 10%, and games that are offered exclusively on Kongregate’s site earn an additional 15%. Thus, it’s possible for a game to earn 25%, 35%, 40%, or 50% of ad revenue.

[Source: Kongregate.com]

BigPoint: They host both Flash and downloadable games, however are very selective on game submissions. Their revenue model is not visible and probably depends on the type of game.
We'll take care of the success of your game. In addition, we offer promising developers interesting financing models.

You profit from business and marketing cooperations for single titles or
for your entire portfolio.

In this way we can support you with professional advertising campaigns and an established distribution network with some of the largest media partners and portals, such as Pro7Sat1 AG, Yahoo, Web.de, etc.

[Source: BigPoint.net]


There are a lot more of such sites. And while you will not make a ton of money, they are a good way to build a reputation for yourself or your indie company.

Friday, May 8, 2009

Concept: Customizing Games for Donations

Daniel Benmergui, has released several Flash games that can be downloaded and played for free.
The unusual thing is that he also offers to customize two of them: Today I Die and I Wish I Were the Moon if you donate to help him build his next game.

  • $27 … and you become an silver sponsor of my next game and your name will appear in the credits, including a link of your choice [17 available]

  • $75 … and I’ll make a “pixelated”, moon-style version of yourself or whoever you want [5 available]

  • $497 … and make you a custom version of I Wish I Were the Moon or Today I Die, creating both characters after whoever you want, making the game the most original gift ever [2 available]

  • $995 … including a new ending of your liking! [Only 1 available]
[Source: Ludomancy.com]
That is a very interesting idea. An interactive gift in the form of a game.

And, people who donated get something nice and special.


By the way, I found "Today I Die" (puzzle) game play where it uses words as part of the game to be unique. Substituting words cause the background and certain object to change allowing to progress further. Really requires thinking outside the box.

Thursday, May 7, 2009

Flash Lite

Adobe Flash Lite is a highly optimized implementation of the Flash runtime for mobile phones, consumer electronic devices, and Internet-connected digital home devices.

Additionally, Flash Lite 3 allows developers to quickly create engaging applications, accelerate time to market, and increase customer adoption. With the new distributable player solution from Adobe, developers can directly distribute rich mobile applications with the latest Flash Lite player to millions of smartphones.

[Source: Adobe.com]
The popularity of Flash Lite is much less that that of J2ME which is the current dominate market holder for mobile games (with IPhone currently second, but increasing rapidly).

This is mostly due to the limited number of mobile phones that support it (mainly high end Nokia and Sony Erickson models) and those that do support it likely only support the older releases (e.g. Flash Lite 2.0, 2.1, etc).

Hopefully this will change, as the power of it and ease of development is far superior to J2ME from my point of view, hence the limited support for it currently. But as time goes by, phones become more powerful, and I expect J2ME to lose it majority.

Here's a Flash Lite game, as you can see it is also playable using any Flash Player on a browser. Notice the numbers on the buttons, they allowing using a mobile phone's number pad to play.


Tic Tac Toe (Flash Lite, v1.0)
[Source: ClickGamer.com]




Anyone has any opinions on this? If so, please do comment as I would like to hear what you think.

Wednesday, May 6, 2009

Flash Animation Tutorial by NCH85

While surfing the internet, stumbled on a two-part tutorial on animating using Flash.




[Source: DeviantArt.com]



If you're a newbie to Flash like me, they you may find them useful.
I really loved the animation, and the script was good too.

I especially liked how he showed the way he drew the rabbit with the different Flash tools in part 2.

Tuesday, May 5, 2009

Concept: Complexity... the good and the bad

An ex-colleague and good friend of mine, Andrew posted the following, and I thought it would be good to share it. Here it is paraphrased to be more generic:
There are two types of complexities in games: inherent complexity and emergent complexity.



The inherent complexity is inherent within the basic mechanics of the game. Those things that you need to know in order just to be able to play it. This complexity includes the rules and interface to play the game.

In a board game, this complexity is a necessary evil as it is what creates the game in the first place. It defines the shape of the board, the pieces and the basic constraints on their movement. To play the game you must understand these constraints. (Perhaps this is less so in computer games where the interface prevents you from straying beyond them, but an overall big picture view is still really quite essential even if some details can be left till later).

To be able to play the game you need to know this. Without it you can still be clicking away but much of what is going on around you wont make sense, and I'm not sure that you could be considered to be 'playing' any more than a monkey behind the wheel of an out of control truck could be considered as 'driving'.



Then there is the other type of complexity, emergent complexity.

This includes our understanding of the consequences of the basic mechanics, and the strategies and counter-strategies we apply to playing the game.

If the inherent complexity is the game board, then emergent complexity is the game that is played upon it, for it is but a function of the various strategies, techniques and styles that players come up with given the constraints imposed upon them by the basic game mechanics.



There is a very critical difference between the two types of complexity and it is this difference that makes inherent complexity bad and emergent complexity good.

Inherent complexity is a roadblock that must be passed before a player can participate in the game. The bigger the barrier the fewer who will pass it. Learning the details that make up the inherent complexity will not let you compete better, it will merely let you compete.

It follows that we would want to minimize this aspect.

I wont argue that there is a certain satisfaction - especially for the geekier among us - in learning systems of byzantine complexity and memorizing vast tables of obscure statistics and the such, but I think its accurate to say that for the most part players would like to get their basic training out of the way and get down to the real business of playing.

Emergent complexity does not prevent you from playing.

In fact it is the secret sauce that keeps you playing, because every time you play you learn a little more about the game. Something you think you did wrong this time and are eager for next time to try and correct it. Some new idea you want to try applying in the next game.

You will notice I use the words 'think' and 'idea' here. These are not cold hard facts to be learned, instead these are subjective. They are opinions, styles, choices. Making these choices is playing the game.

Eliminating the emergent complexity means eliminating these choices. Eliminating the emergent complexity means eliminating the gameplay.

So I want people to minimize the inherent complexity and maximize the emergent complexity. Because while the inherent aspect is the price of the ticket, the emergent part is the game itself.

To finish with an example, take a look at the games of Chess and Wei Qi. Both have very simple inherent complexity but extremely high emergent complexity. They take but an hour to learn yet a lifetime is needed to master them.

I gather that both games still enjoy a certain level of popularity despite having been released quite a while ago.

[Source: forums.sjgames.com]
With this in mind, I always aim to design games that are extremely simple to get started with, but have a lot of depth that can be slowly learnt over time.

I think this is the simple reasons that some good games become so popular, and other good games rarely have more than a small fan following.


Make a game with too much inherent complexity and few people will finish learning to play it, whereas if you make a game with too little emergent complexity and most people will get bored after playing it a while.

Saturday, April 25, 2009

PopCap Developer Program moving to SourceForge

PopCap has both online and download-able games. Their most popular is probably Bejeweled.

They had previously released the framework used for their download-able games (built with Visual C++) for anyone to use free of charge.

Sadly, they are discontinuing support for this and hopefully moving it to SourceForge as open-source.
"The PopCap Developer program has had a good run, but we've been unable to spare the developer time required to keep the Framework (and related tools) up to date here, and it doesn't make sense for us to publicly support an increasingly old version of it.

That being said, everyone who is currently using the Framework may continue to do so, and we plan on making the Framework available on SourceForge so the developer community can continue to have access to it and even support and enhance it as they (you) see fit.

Details of the SourceForge move will be forthcoming, but the plan is to move toward shutting down this site on May 1st. If anyone is interested in stepping forward to volunteer to host the message archive as a knowledge base, please let me know."

-Brian Fiete
CTO & CoFounder, PopCap Games

[Source: developer.popcap.com]
It's nice to see companies so open with their technologies.



While on the topic of PopCap, I would like to talk about their recent move to add their games (at the moment on Bejeweled and Peggle) into another game, World of Warcraft (WoW) as add-ons.

Their first attempt, Bejeweled was a direct port that allowed you to pass time in-game and has some nice extras like keeping highscore for you, your friends and your guild.

Their second attempt, Peggle has a lot more integration with WoW like using WoW's dueling feature to start a two player Peggle game, distributing loot based using Peggle, and adding WoW concept of talent trees into Peggle.

Games-within-games is nothing new, but having another commercial companies making the game-within-game is new. PopCap is probably doing this as a form of in-game advertising and hoping to tap into WoW's 11 million active subscribers. I am curious as to what this will lead to.

Wednesday, April 22, 2009

Ex-Ubisoft staff goes indie and likes it

Interesting story of a person, Phil Fish who was working for an established game developer and developing a game, Fez during his own free time.

He quit when he received an IGF nomination for Excellence in Visual Art (which he later won in 2008) for Fez and his boss did not allow him to attend it.
Not bad for someone fired from Ubisoft, who still calls his experience at the publisher "the worst experience of my life." It was his first gig in games, and initially he was jazzed.

"The way these people make games, it's so horrible," he says. "Hundred of people on your team, you don't know any of their names. It's so big and impersonal." Some people find ways to persevere, to grow in that environment, Fish adds — like weeds pushing up through cracks in concrete.

"In my case it made me want to give up games altogether," he continues. "It was an extremely dark period of my life. Years and years thinking this was my dream only to realize it's a sweatshop."


Gaming was changing, the way games were being made was changing and with the rise of the video game blogs, the way gaming was covered was changing, too. Everything was in flux. Indie developers were saying "Screw the corporate ladder" and going off and making their own games — devs like World of Goo's Ron Carmel and Kyle Gabler. Young developers, like Everyday Shooter's Jonathan Mak, weren't even climbing that ladder.

[Source: Kotaku.com]

Working in an established game developer is not for everyone. I am sure there are advantages too, but as it seems some people just prefer being indie.

Events like the Independent Games Festival held every March are slowly helping indies gain awareness and popularity, by listing finalist and winners of the event. One such winner was Portal in 2006, which became very famous and got snapped up by Valve.

Here's an IGF trailer... excuse the language.

Tuesday, April 21, 2009

Bought two books to learn Flash

I recently decided to learn (self study) Flash after seeing a web site make rather interesting web game, that allowed two players across the internet to play a game against each other, while storing ranking and other information (in a database I presume) which was displayed using HTML.

The current version is Adobe Flash CS4, which uses its own scripting language, ActionScript 3.0. So I went down to the local IT Mall, Funan Center and bought two books on it.

The first book was Flash CS4 "All-In-One" For Dummies (S$69) which I am currently reading. It is a very easy to read book to give me a general background on flash. As I have never used Flash before, I found it helpful, but I think any existing user would find it too simplistic. The jokes it had did not always make me laugh, but together with the colorful pictures, helped break the monotony of reading through each individual tool and option.

The second book ActionScript 3.0 Game Programming University (S$61) was purely on using ActionScript 3.0 with source code of examples, including some games that are available from its companion website, FlashGameU.com. That should be a lot more useful to what I plan to do.

In this day and age of downloading books to read, you may ask why did I buy them. Well, I personally like to support stuff I like. Also, I prefer reading actual books instead of binded printouts or photocopies.



In related news yesterday, Adobe is planning that the digital living room will likely support Flash and Flash-based applications at the end of 2009.

Specifically, Adobe has convinced a wide swath of leading technology companies to support a new, optimized Flash Lite runtime for a number of chips that will form the foundation of connected TVs, DVD players, game consoles, and digital media adapters.

[Source: PCMag.com]

Saturday, April 18, 2009

More user-created content in City of Heroes that developer-created content

User created content in games has been getting more noticed from developers in recent times.

I think it was the Counter-Strike that was the first to make me aware of user created content. This FPS had tons of user created maps, models, weapon skins and mods available for it. The funny thing is, that it itself was a free user created mod of another game, HalfLife.

Valve Software marketing director Doug Lombardi has told GamesIndustry.biz that consoles must embrace user-created content.

"I would argue that it's the biggest component those guys have to get over if they want online to matter," said Lombardi.

"Half-Life 1 was okay as a multiplayer game and Team Fortress Classic was really good, but Counter-Strike kicked both their asses no question. And that came from a kid going to college in Canada and another kid going to high school in New Jersey, who had our code and thought it would be cool to play our game"

[Source: GamesIndustry.biz]

After reading the next article, I hope a lot of people mindset on this will change. This is no longer a just a potential. It is already here and now.
Only one day after NCsoft released their player-created content focused Issue 14: Architect update, and players have already crafted more than 20,000 mission arcs.



In a letter to the community posted on the official City of Heroes website, Matt "Positron" Miller revealed that within the first 24 hours of the new updates' existence, players in both hero and villain factions had created more than 3800 story arcs, each consisting of five missions a piece - more content than the development team had created during the game's entire existence.

Players have been busy trying out missions and critiquing them in the forums as well. Out of the more that 20,000 arcs now available in game, 2,860 of them have been rated 5-stars by players, with only 582 rated at 1-star.

[Source: Kotaku.com]

The sheer amount of content is outstanding; and all done in 24 hours. And with a rating system in place, that helps ensure quality remains.

Games soon may be like Second Life (a virtual world where users create almost all of the content: locations, models, activities and economy). Already games like Little Big Planet (levels), World of Warcraft (user interface), The Sims are heavily using this.

So if you make a game, try to consider this and include some sort of Map Editor.

Why start this blog?

Some friends have ask why I have just started this blog about Indie Game Development in Singapore.

After reading some success stories, I have recently decided to give it a try; not for the money but simply because it is something I think I will enjoy doing.

I have been interested in gaming, and not just computer gaming. I have enjoyed playing card games, board games, table-top war games, brain games... you name, I think I played it.

When I was schooling, there were no available game-related courses, so I went into the next closest thing, IT. Got a degree and worked in a few IT companies (including NCS, Mercury Interactive, HP) doing programming, technical support, etc. Nowadays, there are private schools and even universities offering courses in computer game design, both from the computer science and art perspectives. I envision courses from the business perceptive to appear in the next 10 years, as the gaming industry is rapidly becoming more of a serious field of business.



Next question these friends of mine ask will usually be either why or what is Indie? This is a short for for independent, which means without the financial support of a publisher.

Most computer games are so huge and expensive to develop now, that they require huge amount of funding from a publisher (like Electronic Arts, Activision, THQ) in return developers get payed for work done and earn royalties, while the publishers keeps the rest of the profit (which is sometime used to offset games that make a loss). As such, some decision as when to release, what to focus on, etc are out of the control of developers.

Being independent "in my opinion" allows more creativity when designing a game, there is less pressure to keep releasing sequel after sequel just to keep profits high. Also, joining or starting up an indie game company should give a higher chance to be involve in the design process, which is really what I am interested in.

While being involve in making a game by following instructions handed down to me is something I would still enjoy, I would enjoy it a lot better having a part in the game design too. Thus, I am now searching to either join or start up an indie game company here in Singapore

Friday, April 17, 2009

My trip to ERC Institute

Saw an advertisement in Today a few days back on how to learn to make your own game.

It was by ERC Institute, a private school that does both full-time and part-time diploma level courses in a range of subjects.

So yesterday, I went down for a preview of their course.
The place is located just next to Great World City and I was able to take a bus, SBS 195 from Tioung Bahru MRT to reach it.



They conduct two gaming related courses Diploma in Game Design & Development and Advanced Diploma in Game Design & Development (each lasting 12-15 months and costing S$10K), and these lead to a Degree offered University of Greenwich in UK.

They had two presenters. The first was Bryan, from a prospective hirer of graduates, Crystal CG whose main office in China did the CG for the Beijing 2008 Olympics. The second was from ERC and explain what their course offered. I was really impressed when they mentioned having a lot of industry contacts, guest lecturers and internships available. Before leaving, I asked to see some of the completed projects that their students have done, to get a better idea of what you can do after completing their course, so waiting for them to get back to me.

The course entry requirements are GCE 'O' Levels, and I would probably have enrolled it if that was my highest education level. However, this course is probably not suited for me as I have already done a degree.



There is another school for gaming in Singapore, Digipen which I plan to attend their upcoming information session (May 22, Friday). From what I hear, they are a lot more expensive but they offer Bachelor Degrees.