Expose more variables (mouse_pos_percent etc) to JavaScript

While for one-off actions having these variables in advanced conditions is easier - you have this very cool live debugging mode where a screen turns green when a condition is met, for some batch of actions it's easier to match conditions within a few if statements, especially if you plan to use the results of those matches later

So would be great if all of these extra variables were also available to scripts in addition to Available Standard Variables · GitBook

Or is there some available trick to get them?

I think they should already work, I'll check again later!

Ah, I see, some of them indeed do (e.g., the % works with get_number_variable, not get_string_variable, so I just used the wrong function and didn't check further since I assumed from the docs that these weren't exposed), but then some others don't work with either of string/number function, e.g., leftmost_touch_y returns undefined

(async ()=> {
const varName = 'leftmost_touch_y'
const var_str	= await callBTT('get_string_variable',{variable_name:varName})
const var_num	= await callBTT('get_number_variable',{variable_name:varName})
returnToBTT(`var_str=${var_str} var_num=${var_num}`);