local dev = GetSelf()



function animate(targetsweep)
	local sweeprate = 3.0 --degrees per second
	local sweepstep = sweeprate/100
	currentsweep = get_aircraft_draw_argument_value(7)
	if abs(targetsweep-currentsweep) <= sweepstep then
	set_aircraft_draw_argument_value(7,targetsweep)
	elseif targetsweep > currentsweep then
	set_aircraft_draw_argument_value(7,currentsweep+sweepstep)
	timer.scheduleFunction(animate, {targetsweep}, timer.getTime() + .01)
	elseif targetsweep < currentsweep then
	set_aircraft_draw_argument_value(7,currentsweep-sweepstep)
	timer.scheduleFunction(animate, {targetsweep}, timer.getTime() + .01)
	end
end