Build 10 games and learn game development along the way in this fast paced game development course

Get the source code of 12 commercial games, loaded 50+ million times, and learn the secrets of game design

Learn how to make a successful Flash game from a real world example. Fully commented source code

Create realistic Flash physics games from scratch with advanced features, from Angry Birds to Crush the Castle

Create a Flash game like The Impossible Line – Final prototype

As promised, here is the final prototype of The Impossible Line game.

In first step I showed you how to draw following mouse movement.

In second step I showed you how to create the collision radar.

In this big update I am introducing the remaining features:

* Goal: you now have to reach the green circle at the right of the stage.

* Death: happens when you hit a wall.

* Light powerup: in the original game you activate it with an icon, in this version you have to touch it to activate it. I am using the same principle seen in the second step to create the radar, together with some gradient fill to achieve quite the same effect you can see in the original game.

* Replay: once you win or lose the game, you can see the replay of your action. This is an amazing feature which can be done just recording player position at every frame by storing it into a vector, then moving the player according to vector values.

To make everything fit into a quite small and still readable full commented script, I removed some basic features introduce at step 1 such as drawing and rotating.

You should be able to add them by yourself in a matter of seconds. Here is the script:

And this is the result:

Move the white circle to the green circle avoiding white walls and looking at the red radar. Get the yellow circle to turn on the light. Refresh once you win or die.

Download the source code. Next time, I am going to show you how to port it to iPad using Starling.

Rate this post: 1 Star2 Stars3 Stars4 Stars5 Stars (11 votes, average: 4.45 out of 5)
Loading...Loading...
Learn how to make a successful commercial Flash game from a real world example: get the fully commented source code of Globez, a Flash game played millions of times which generated a four figure income. Limited copies available.

Get it now
Be my fan on Facebook and follow me on Twitter! Exclusive content for my Facebook fans and Twitter followers

This post has 4 comments

  1. Adam Dickinson

    on September 5, 2013 at 7:48 pm

    Dear Emanuele Feronato,

    please do not show people how to copy our game and then port to ipad…it’s not nice.
    Instead please show them how to make original games.
    many thanks

    Adam (production Director Mi)

  2. Ashwin

    on September 5, 2013 at 8:04 pm

    Wonderful… thanks for making Actionscript 3 tutorials in this pro HTML5 driven times !!!

  3. Nix

    on September 5, 2013 at 11:41 pm

    Emanuele can you make flash as3 level editor tutorials?
    Why? It will be unique tutorial, I cant find any as3 level editor tutorials, there are a few source code for basic level editor but not tuts, its alomost useless.
    Why level editor?
    Look it this website http://www.pouetpu-games.com/index.php
    This guy created only two flash games with level editor, only 2, and sometimes there are 250 users online. His website is better than most other flash website with hundrets flash games.

  4. Victoria

    on September 9, 2013 at 1:56 pm

    Wow! Thank you for such detailed step-by-step tutorial! It’s very useful for all starting game developers who want to develop their own HTML5 game! Wish there were more such resources when I started

Thank you for the download!!

I hope you will find it useful and make something interesting out of it

To keep up to date with the blog, why don't you like my Facebook page and follow me on Twitter?

Want to learn more? Don't miss this:

Learn how to make a successful commercial Flash game from a real world example: get the fully commented source code of Globez, a Flash game played millions of times which generated a four figure income. Limited copies available.

Get it now

×