>>819
if (x+dt<0) then x=0 else x+=dt;