-
-
Notifications
You must be signed in to change notification settings - Fork 998
Weird effect in script core.waitForKeypress() #4866
Copy link
Copy link
Labels
importance: mediumA bit annoying, minor miscalculation, but no crashA bit annoying, minor miscalculation, but no crashpurpose: didacticIssues, pull requests and proposals with didactic purposesIssues, pull requests and proposals with didactic purposespurpose: interoperabilityInteroperability issuesInteroperability issuessubsystem: scriptingThe issue related to scripting engine of planetarium…The issue related to scripting engine of planetarium…
Milestone
Metadata
Metadata
Assignees
Labels
importance: mediumA bit annoying, minor miscalculation, but no crashA bit annoying, minor miscalculation, but no crashpurpose: didacticIssues, pull requests and proposals with didactic purposesIssues, pull requests and proposals with didactic purposespurpose: interoperabilityInteroperability issuesInteroperability issuessubsystem: scriptingThe issue related to scripting engine of planetarium…The issue related to scripting engine of planetarium…
Type
Projects
Status
Backlog
Expected Behaviour
According to the contribution (#4864 ) a pause in a script triggered by core.waitForKeypress() can be advanced with a Bluetooth "presenter" device.
Actual Behaviour
I can advance using Alt/Ctrl/Shift/Cursor keys. OK, no bluetooth device needed. My presenter on the other hand (non-BT wireless device with USB dongle, but it does advance/reverse PPT etc) advances/steps back time by 24h2m4s (no idea where this comes from!), but does not advance the script.
EDIT: The time advance is linked to my configured actions (next/previous twilight) for PgUp/PgDn which the presenter works with.
Steps to reproduce
Modify any script and add a
core.waitForKeypress()somewhere. Run it.System
Logfile
If possible, attach the logfile
log.txtfrom your user data directory. Look into the Guide for its location.Other thoughts:
Should there be some visual clue like "Press any key to continue script." near screen bottom that could be configured away in the script panel settings? (If you run somebody else's script for the first time, won't it appear "stuck somewhere"?) You can do other things (move around with the mouse, zoom with mouse wheel, operate RC plugin web interface, ...) while the script is in the wait loop, but there is no indication how to advance. A next obvious idea: extend to a mini menu to run interactive scripts (branch on accepted letters). Should the GUI button to pause be restored on this basis, or is it still limited to predefined pause points?
In any case, #4864 needs an update of SUG section 17.5.1 that should include the answers to these questions and help others to develop useful scripts.