Phyballs: when Arkanoid meets Box2D – Full source code
Filed Under Actionscript 3, Box2D, Flash, Game design, Users contributions • 16 Comments
Box2D is getting more and more popular among developers, and I am proud to have the permission to publish the first source code for a complete Box2D game.
The author is Esteban Gallardo, author of Free Creation Games.
The game is called Phyballs
And this is the source code.
I have to say, this is the most complete source code I have ever seen. Inside the package you will find a pdf file with the description of how is organized the library of the game, a flow diagram showing you the class structure, and even the php files to insert and list records for highscores management. And more stuff, such as the level editor.
Amazing job.
They can be easily customized to meet the unique requirements of your project.
16 Responses to “Phyballs: when Arkanoid meets Box2D – Full source code”
Leave a Reply
Trackbacks
-
Box2D breakout prototype : Emanuele Feronato on
February 4th, 2009 2:27 pm
[...] days ago I showed you Phyballs, now it’s time for Andre Vidal to show his [...]
- Get up to $100,000 for your next Flash game with Mochi GAME Developer Fund
- Create a dynamic content animated footer ad for your site in just 9 jQuery lines – 17 lines version
- Sell sitelocked version of your Flash games and even .fla sources to Free Online Games
- Protect your work from ActionScript code theft with SWF Protector
- Create a dynamic content animated footer ad for your site in just 9 jQuery lines
- Understanding Box2D’s one-way platforms, aka CLOUDS
- Triqui MochiAds Arcade plugin for WordPress upgraded to 1.2
- Box2D Flash game creation tutorial – part 2
- 11 Flash isometric engines you can use in your games
- Monetize your Flash games with GamesChart
- Create a Lightbox effect only with CSS - no javascript needed
- Flash game creation tutorial - part 1
- Create a Flash Racing Game Tutorial
- Flash game creation tutorial - part 2
- Make a Flash game like Flash Element Tower Defense - Part 2
- Flash game creation tutorial - part 3
- Make a Flash game like Flash Element Tower Defense - Part 1
- Create a flash draw game like Line Rider or others - part 1
- Triqui MochiAds Arcade plugin for WordPress official page
- Create a flash artillery game - step 1
- Flash game creation tutorial – part 5.2 (4.88/5)
- Create a flash artillery game – step 1 (4.79/5)
- Create a Flash Racing Game Tutorial (4.76/5)
- Create a flash artillery game – step 2 (4.74/5)
- Create a survival horror game in Flash tutorial – part 1 (4.73/5)
- Creation of a Flash arcade site using WordPress – step 2 (4.73/5)
- Flash game creation tutorial – part 2 (4.71/5)
- Flash game creation tutorial – part 1 (4.70/5)
- Create a flash draw game like Line Rider or others – part 1 (4.69/5)
- Creation of a platform game with Flash – step 2 (4.68/5)


(5 votes, average: 4.20 out of 5)





Hi,
Nice article. However, I have to remind you that it’s ‘Free Creation Games’ and not ‘Free Action Games’. I hope you will correct it :)
Thanks.
Done :)
The game has a (big) problem: sometimes the ball is blocked on top of a brick roof, and the player can’t do anything.
Adding bouncing capability to bricks may help.
Didn’t look at the source code, but nice sharing anyway ;)
Yes, “gludion”, you are right, that’s why I made the button “Shake”, because it was possible that the ball could rest forever in the top any complex structure. Pressing the “Shake” button you will apply a random impulse to the ball that will avoid that “bug”.
Emanuele, thanks a lot for the post, if it’s possible I will make another tutorial of another simple game, let’s see if I recover well from a cold and work a little.
the game has “shake” button on the right side for this problem :)
That is the dumbest game I have seen. Why would you make a game at such a low frame rate? That is just plain stupid, and completely ruins what could have been a good game. Why is it even necessary to mention it. That should just be common sense to the developer. Try the game, notice instantly that it looks like crap, and then increase the frame rate.
Should blocks collide with each other? If I hit one on the top of others it stays while imo it should fall. ;) Try with B2Body.maskBits
oops, didn’t notice the shake button was actually part of the game. Thanks.
Why not just reset the ball when the ball sleeps?
There’s a bug where the ball will bounce off something invisible immediately above the batton. Needs some decent graphics, but otherwise not a bad game.
Hi Emanuele – have you looked at Glaze – http://code.google.com/p/glaze/ – I’ve been using this on my latest project because the API seems simpler than Box2D, and it runs very fast with lots of objects. Any thoughts?
Pretty awesome concept, coulda been pulled off better though.
And I’m sure it will be now the source is here :P
Congratulations on the good work, I had done something similar a couple of months ago, nice to see it taken up a notch ( and what a notch ;) ).
hy, here is just a source code, do you have, somewhere, tutorial, about creating this game?
tnx
Hi, I tried to compile phyballs from the source,
but found that there are some classes missing,
for example:
cGameBackground
cGameWall
Focusmanager
is there some sourcecode missing in the zip file ?
best
reesy