I was messing around with a "realistic" bullet penetration prototype and currently the detection of the collisions is less than desirable. Currently it completely bypasses any object smaller than the green box and will sometimes even skip it at its current size.
It runs fine locally at mostly 60fps, but this is just a messy prototype so don't expect the best performance. Firing too fast seems to wreck the fps in some cases also sounds might repeat or not play etc etc.
I have tried altering the stepping of the physics object, but this seems to have no effect.
I saw a posted example of pixel perfect collision detection, but unfortunately the performance was lackluster and used a messy loop that caused the cpu to hit 100% after 50+ shots.
Not looking for a concrete example, but anyone that can point me in the right direction would be much appreciated.
Trying not to get too heavily into the math side of things, but I'm thinking custom movement and some trajectory equations might have to happen.
Test:
WASD = Move gun around
R = reload
X = clear all lines/magazines
Left click = fire
B= Enable blood
https://dl.dropboxusercontent.com/u/14181859/bullet%20Test/index.html
EDIT: Updated the example to adjust velocity and fixed it so no matter what angle you shoot it should go out the right side.
Green = less than 50% the original speed
Yellow = between 90-51% original speed
Reload your cache or load it in a incognito tab to see changes.
Still can't get the collision to work right on thin objects, but I am working on another prototype using custom movement and some trajectory formulas.
Got it to be a little more accurate but not much.