hedgewars/GSHandlers.inc
changeset 1920 302835d554d8
parent 1919 390d3f685a80
child 1922 88cdabb51995
equal deleted inserted replaced
1919:390d3f685a80 1920:302835d554d8
    27     begin
    27     begin
    28     skipSpeed:= _0_25;  // was 0.36 - couldn't manage baseball bat. Tiy's build is 0.36...
    28     skipSpeed:= _0_25;  // was 0.36 - couldn't manage baseball bat. Tiy's build is 0.36...
    29     skipAngle:= _1 + _0_9;  // these should perhaps also be constants, once work out what proper values are
    29     skipAngle:= _1 + _0_9;  // these should perhaps also be constants, once work out what proper values are
    30     skipDecay:= _0_87;  // this could perhaps be a tiny bit higher.
    30     skipDecay:= _0_87;  // this could perhaps be a tiny bit higher.
    31     if  (hwSqr(Gear^.dX) + hwSqr(Gear^.dY) > skipSpeed) and
    31     if  (hwSqr(Gear^.dX) + hwSqr(Gear^.dY) > skipSpeed) and
    32         (hwAbs(Gear^.dX) > skipAngle * hwAbs(Gear^.dY) then
    32         (hwAbs(Gear^.dX) > skipAngle * hwAbs(Gear^.dY)) then
    33        begin
    33        begin
    34        Gear^.dY.isNegative:= true;
    34        Gear^.dY.isNegative:= true;
    35        Gear^.dY:= Gear^.dY * skipDecay;
    35        Gear^.dY:= Gear^.dY * skipDecay;
    36        Gear^.dX:= Gear^.dX * skipDecay;
    36        Gear^.dX:= Gear^.dX * skipDecay;
    37        CheckGearDrowning:= false
    37        CheckGearDrowning:= false