mirror of
https://github.com/opentx/opentx.git
synced 2025-07-15 04:15:26 +03:00
Fixes #3329: playDuration() second parameter is now really optional
This commit is contained in:
parent
fb3dd1303c
commit
19f392131c
1 changed files with 1 additions and 1 deletions
|
@ -580,7 +580,7 @@ Play a time value (text to speech)
|
|||
static int luaPlayDuration(lua_State *L)
|
||||
{
|
||||
int duration = luaL_checkinteger(L, 1);
|
||||
bool playTime = (luaL_checkinteger(L, 2) != 0);
|
||||
bool playTime = (luaL_optinteger(L, 2, 0) != 0);
|
||||
playDuration(duration, playTime ? PLAY_TIME : 0, 0);
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue