The Holy Grail of Flash
As any of you who have messed with Actionscript know, smooth collision detection is the Holy Grail of flash game developers.Suprisingly enough, Flash only has bounding box collision detection, and no built-in smooth collision detection. Now, there are plugins or something that you can buy (I've only found 1 though), but they cost money.It wouldn't have been very hard for the Flash Developers to code in advanced collision detection, but they didn't. So I did. Smooth, complex-polygon collision detection. It is pure awesomeness, and way better than the default hitTest() which uses bounding boxes only. I wrote this in just under 2 days, and I'll post the actionscript files if you want me to. This code can be used in any language (allowing for syntax changes) like C++, for game development and complex-polygon collision detection.Its fricken sweet. If you don't think it's fricken sweet, go make your own smooth collision detection in 2 days. From scratch. Remember, Flash doesn't even have built-in line-segment intersection code.*may take a few seconds to load*to see the new version, clear your cache!<p align=center><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="550" height="400" id="Collider" align="middle"><param name="allowScriptAccess" value="sameDomain" /><param name="movie" value="Collider.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#ffffff" /><embed src="http://64digits.com/users/DesertFox/Collider.swf" quality="high" bgcolor="#ffffff" width="550" height="400" name="Collider" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /></object></p>And I invoke [url=http://en.wikipedia.org/wiki/Godwin's_Law]Godwin's Law <p align=center>*cough*Hitler*cough*<br>
lol
Nice collision detectionHitler only had one testicle.
-Fact.Actually TG is right XD
Hitler has only got one ball,
Göring has two but very small,Himmler is somewhat sim'lar,But poor old Goebbels has no balls at all.I win!!!
Hitler
Has only got one ball!The otherIs in the Albert HallHis motherThe dirty buggerSucked it off when he was smallOh and BTW how can we trust you whether it is actually polygon-intersection? Maybe it is just line-line intersection…
@Dragonos - Nice - thats because you are overlapping them by just about a pixel =D Or *gasp* you edited the pic!@Cat - I give you a challenge - make your own complex polygon collision detection. You can't do it without line-intersection detection. But its not JUST line-intersection detection. What if a poly completely surrounds another poly? No intersection, but its still colliding with it.
Nice work.
VERY nice job. I can't use AS for my life…