Fixes #1540: added Lua playDuration()