Introducing Chris

July 28, 2006 on 5:28 pm | In Miscellaneous | Comments Off

Hi,

I’m Chris and will be helping building the flash physics engine. Hopefully it will improve my coding skills (I wish I had some), and help me use the knowledge I crammed into my head.

Motor Flash Physics: Part 2, frame dependent collision detection

July 28, 2006 on 1:48 pm | In Actionscript, Physics | Comments Off

Ok, a simple collision detection is up and running. It’s just an extension of part1, but now I use the computed normal vector to push the objects apart to prevent intersection.

Flash Demo (requires Flash Player 8)

Probably the best design patterns book out there

July 25, 2006 on 7:17 pm | In Miscellaneous | Comments Off

I just finished reading the book Head First Design Patterns. If you always struggled around with design patterns this is definitely the best point to start.

The book is covering all details for becoming familiar with the idea of design patterns in short time. It is comprehensive, easy to understand and suprisingly also entertaining and fun to read at the same time which you won’t usually except from this kind of topic.

The code examples are all in Java, but you should have no problem at all understanding them because Actionscript is not really that much different at all.

Motor Flash Physics: Part 1, seperation axis theorem

July 4, 2006 on 11:15 pm | In Actionscript, Physics | Comments Off

This is my attemt to create a 2d rigid body physics engine in flash. Everyone nowadays makes engines, so I decided to build a motor instead and call that thing Motor Flash Physics ;-).
I will document the creating process (let’s see how far I get…) and since physics is a rough and complicated field, Chris (studying physics at the moment!) will hopefully help me when its getting hairy.

A good point to start is gamedev.net, which has tons of material for game development.
There I found a nice C++ tutorial implementing a 2d physics engine by Oliver Renault.
Another gem I found is geometrictools.com and geometryalgorithms.com, both providing solutions and algorithms for geometric problems.

The first implementation shows the ’seperation axis theorem’ in action - an algorithm to detect when two convex polygons overlap which of course is needed for collision detection and response.

If you are interested how this works, here is a paper describing the principle of the algo. Basically it tries to fit a plane between two polygons. If such a plane exists, both polygons are disjoint and cannot intersect, otherwise an intersection must occur.

Flash Demo (requires Flash Player 8)

Proudly powered by WordPress Theme based upon Pool theme by Borja Fernandez.
Entries and comments feeds.