PDA

Click to See Complete Forum and Search --> : [VB6] Friction Force


Jacob Roman
Feb 17th, 2006, 01:47 PM
This is a very simple physics implementation that adds friction to your sprites which should make your game more realistic. It uses a 2nd Order Euler, which is more accurate than regular Euler:

x = x0 + v * dt - 0.5 * a * dt * dt
v = v0 + a * dt

Where a = f/m

It even includes a scalefactor to where you can make kilometers as big as you want in pixels.

Friction.zip (http://www.vbforums.com/attachment.php?attachmentid=44325)

Kal_Torak
Feb 18th, 2006, 01:34 PM
*Kal goes to look up Euler*

Jacob Roman
Feb 20th, 2006, 11:43 AM
And? :ehh:

SNIPER.PS
Dec 10th, 2009, 03:47 AM
thanks