Autopush: Improve handeling on speedup
Signed-off-by: fly <merspieler@airmail.cc>
This commit is contained in:
parent
ee25322c4a
commit
5981539a38
3 changed files with 4 additions and 2 deletions
|
@ -85,12 +85,13 @@ var _loop = func() {
|
|||
}
|
||||
|
||||
var _timer = maketimer(0.0167, func{_loop()});
|
||||
_timer.simulatedTime = 1;
|
||||
|
||||
var _start = func() {
|
||||
# Else overwritten by dialog.
|
||||
settimer(func() {
|
||||
setprop("/sim/model/autopush/target-speed-km_h", 0.0)
|
||||
}, 0.1);
|
||||
}, 0.1, 1);
|
||||
_K_p = getprop("/sim/model/autopush/K_p");
|
||||
_F_p = getprop("/sim/model/autopush/F_p");
|
||||
_K_i = getprop("/sim/model/autopush/K_i");
|
||||
|
|
|
@ -88,6 +88,7 @@ var _loop = func() {
|
|||
}
|
||||
|
||||
var _timer = maketimer(0.051, func{_loop()});
|
||||
_timer.simulatedTime = 1;
|
||||
|
||||
var _done = func() {
|
||||
stop();
|
||||
|
|
|
@ -89,7 +89,7 @@ var _stop = func(fail = 0) {
|
|||
settimer(func() {
|
||||
_finalize_top_view();
|
||||
gui.popupTip("Done");
|
||||
}, 1.0);
|
||||
}, 1.0, 1);
|
||||
} else {
|
||||
_finalize_top_view();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue