OZONE Asylum
Forums
DHTML/Javascript
Pinball game: Collision of a ball with a pinball paddle
This page's ID:
30777
Search
QuickChanges
Forums
FAQ
Archives
Register
Edit Post
Who can edit a post?
The poster and administrators may edit a post. The poster can only edit it for a short while after the initial post.
Your User Name:
Your Password:
Login Options:
Remember Me On This Computer
Your Text:
Insert Slimies »
Insert UBB Code »
Close
Last Tag
|
All Tags
UBB Help
Personally I'd go for expressing the flipper as a distance function to the segment between its two round extremities. Because you must bare in mind that the flipper might very well hit the ball on its way down, in which case it's easier to do this way than having to consider the upper and lower edge of the flipper + the round edge for the collision detection. Of course it'd help to only compute the collision if the ball is within the disc where the flipper can move. But the ball is also a fast moving object, so you should actually compute the intersection of the segment formed by its current and previous position with the cone formed by the flipper at its previous and current position. With that you should be able to estimate the moment and location of the impact. IIRC Ugo Helias had something similar for a snooker simulation or boucing balls simulation. [url=http://www.p01.org/][img]http://poi.ribbon.free.fr/files/p01_ozoneasylum_sig_dk.gif[/img][/url] [small](Edited by [url=http://www.ozoneasylum.com/user/2185]poi[/url] on 01-20-2009 02:56)[/small]
Loading...
Options:
Enable Slimies
Enable Linkwords
« Backwards
—
Onwards »