home subscribe to email updates subscribe to RSS updates

Learning: ActionScript Physics Engine (APE)

In the next week or two I’m going to have to put together a game that involves bouncing balls off inclined lines. About half way towards implementing my own solution, I kicked myself for forgetting about APE and then clicked off in hot pursuit.

Michael Battle - Learning APE

So I just thought I’d show you the simple little ditty that I through together this morning before work. APE, by ActionScript gun Alec Cove, was surprisingly quite simple to get into and it provides you with a variety of options that will hopefully suit your (and my) introductory needs.

At the moment it supports circular, rectangular and wheel-like particles and spring constraints. Take a quick look and check back in a few days for more APE mischief.

This demo has 30 eyes (wheel particles), 4 fixed rectangular particles and 3 fixed circular particles. The wheel particles show angular momentum (the spinning that occurs when the balls hit other surfaces). The mass of each of the individual eyes is directly proportional to its respective size.

I’m pretty excited about this stuff… looking forward to getting stuck into some more complicated ideas. Between APE, Papervision3D, Tweener, AIR and the Adobe Core Library, the average Flash developers tools are getting quite sophisticated!

Link: APE (ActionScript Physics Engine)
Link2: Alec Cove


« First Person 3D Engine in Flash
AddThis Social Bookmark Button

Related Posts:

Comments:

The Samster said,

October 8, 2007 @ 9:43 am

I find your recurring bouncing eyeball theme in your experiments interesting…yet disturbing :)

Michael said,

October 8, 2007 @ 9:45 am

Don’t worry, babe. I’ve only got eyes for you. :P

RossK said,

October 9, 2007 @ 3:24 pm

get a room you two

Jono said,

October 12, 2007 @ 9:07 am

I like how you’ve got the highlight staying still at the top of the ball. Nice little detail there.. Would it be possible to simulate something like an hour glass? How many objects/particles could it handle?

Michael said,

October 12, 2007 @ 9:47 am

Jono - An hourglass is totally possible… here’s an example using another AS3 Engine (Fisix)…

http://tinyurl.com/2tkuvy

I’m guessing the number of balls would vary alot between computers and the other number of obstacles in the scene.

Yehuda Berlinger said,

October 24, 2007 @ 1:33 am

Oh, how cute! Look at the bouncing eyeballs! I have to get me some.

I’m suddenly hankering for a Minority Report game.

Yehuda
http://www.come2play.com

Ben said,

October 26, 2007 @ 2:42 am

very nice, I haven’t dived into his stuff yet. But I worked briefly with Alec at FB, he’s quite an amazing flash developer.

Justin said,

December 8, 2007 @ 3:54 am

Hi Michael,

Glad to see you getting stuck into APE ;) I like the idea of integrating it with PV3D, that sounds like it will have a lot of potential.

I actually had a little play with APE recently myself: http://tinyurl.com/2hkrj8

Have you had any thoughts on extending it? I built a couple of classes extending the group class for the pinball type paddles I’ve got going on in my example, perhaps the same for PV3D would be good? Like a library of 3D groups for various uses. I’ll keep my bouncing eyeballs on your work!

All the best mate, keep up the tip-top AS trickery.

Julie said,

March 9, 2008 @ 6:55 am

sorry… I’m a bit new in that … and I want to know how to install the APE… can u help me with that…

thx

Michael said,

March 9, 2008 @ 7:44 am

Hi Julie

You don’t actually ‘install’ APE, you download the source files and include/reference them with your own actionscript code.

The easiest way for you to get your head around how it all works is to go through a tutorial - have a look at these two:

- http://tinyurl.com/3dy6r5
- http://www.cove.org/ape/quickstart_fb.htm

That’s where I started too. Good luck!

Michael

RSS feed for comments on this post · TrackBack URI

Leave a Comment



« First Person 3D Engine in Flash