{ double tempFollow3Var = f4; f4 = f23; f23 = f9; f9 = tempFollow3Var; } { double radius = Math.sqrt(f13*f13 + f20*f20); double angle = Math.asin(f20/Math.max(.000000001,radius)); if(f13 < 0){ angle += Math.PI; } double speed = 1 / Math.max(.000000001, Math.abs(f6)); angle += f12*speed; f13 = Math.max( -1., Math.min(radius*Math.cos(angle), 1.) ); f20 = Math.max( -1., Math.min(radius*Math.sin(angle), 1.) ); } if(0 < f24 && f3 < 0){ f3 -= 2*f24*f3; } { double radius = Math.sqrt(f22*f22 + f16*f16); double angle = Math.asin(f16/Math.max(.000000001,radius)); if(f22 < 0){ angle += Math.PI; } double speed = 1 / Math.max(.000000001, Math.abs(f19)); angle += f24*speed; f22 = Math.max( -1., Math.min(radius*Math.cos(angle), 1.) ); f16 = Math.max( -1., Math.min(radius*Math.sin(angle), 1.) ); } { double radius = Math.sqrt(f17*f17 + f16*f16); double angle = Math.asin(f16/Math.max(.000000001,radius)); if(f17 < 0){ angle += Math.PI; } double speed = 1 / Math.max(.000000001, Math.abs(f6)); angle += f12*speed; f17 = Math.max( -1., Math.min(radius*Math.cos(angle), 1.) ); f16 = Math.max( -1., Math.min(radius*Math.sin(angle), 1.) ); } { double dx = f17 - f14; double dy = f22 - f0; double distSquared = dx*dx + dy*dy; if(distSquared > 1){ double dist = Math.sqrt(distSquared); double moveEach = (dist - 1)/2; double normDx = dx / dist; double normDy = dy / dist; double moveX = moveEach*normDx; double moveY = moveEach*normDy; f17 -= moveX; f14 += moveX; f22 -= moveY; f0 += moveY; } } f8 = Math.sin( f0 / Math.max(.000000001,Math.abs(f3)) ); f4 = Math.max(f16,f14); { double dx = f15 - f7; double dy = f24 - f6; double distSquared = dx*dx + dy*dy; if(distSquared > 1){ double dist = Math.sqrt(distSquared); double moveEach = (dist - 1)/2; double normDx = dx / dist; double normDy = dy / dist; double moveX = moveEach*normDx; double moveY = moveEach*normDy; f15 -= moveX; f7 += moveX; f24 -= moveY; f6 += moveY; } } f2 *= f16; f12 = Math.max(f16,f14); f16 = Math.sin( f21 / Math.max(.000000001,Math.abs(f10)) ); f21 += f11; if(1 < f21){ f21 -= 2; }else if(f21 < -1){ f21 += 2; } { double swap2Vars = f1; f1 = f5; f5 = swap2Vars; } { double swap2Vars = f14; f14 = f5; f5 = swap2Vars; } if(0 < f15){ f13 = f13*(1-f15) + f15*Math.max(f18,f12); } f18 = Math.sin( f10 / Math.max(.000000001,Math.abs(f12)) ); f10 = Math.sin( f18 / Math.max(.000000001,Math.abs(f12)) ); { double tempFollow3Var = f13; f13 = f11; f11 = f8; f8 = tempFollow3Var; } { double swap2Vars = f6; f6 = f5; f5 = swap2Vars; } f19 = Math.sin( f18 / Math.max(.000000001,Math.abs(f12)) ); if(0 < f1){ f9 = f9*(1-f1) + f1*Math.max(f22,f7); } f20 += f11*f5; if(1 < f20){ f20 -= 2; }else if(f20 < -1){ f20 += 2; } { double dx = f2 - f22; double dy = f13 - f8; f15 = Math.sqrt((dx*dx + dy*dy)/2) - 1; } f10 = Math.sin( f18 / Math.max(.000000001,Math.abs(f3)) ); if(0 < f8 && f3 < 0){ f3 -= 2*f8*f3; }