1
0
Fork 0

Controls: Remove debug prints

This commit is contained in:
Richard Harrison 2018-09-16 19:21:23 +02:00
parent e1c0c70c4a
commit 02643d36cd

View file

@ -271,21 +271,15 @@ setElevatorTrimToPosition = func() {
nv = math.min(math.max(-1.0,nv),1.0);
var lv = getprop("/controls/flight/elevator");
if (math.abs(lv) <= 0.001){
print("Elevator trim: centre");
setprop("/controls/flight/elevator-trim", 0);
} else {
#print("Trim when centered stick");
setElevatorTrimToPosition_listener = setlistener("/controls/flight/elevator", func(v){
if (math.abs(v.getValue()) <= 0.001) {
setprop("controls/flight/elevator",0);
removelistener(setElevatorTrimToPosition_listener);
setElevatorTrimToPosition_listener = nil;
# print("set trim to ",nv);
setprop("/controls/flight/elevator-trim", nv);
}
# else
# print("Not trimming yet ",v.getValue());
}, 0, 0);
}
}