Instead of a numerical value like:
<Label Range: 1>
is it possible to have the value of a variable?
For instance:
<Label Range: variable ID1>
As a rule, Notetags don't use JavaScript unless the instructions say they've been coded to accept it. You could spawn different versions of the event with different ranges depending on the variable, or you can submit a suggestion to VisuStella.
The difficult thing in the "tricky" way is to keep track individually of all the events that have a label. On a big map there can be a lot of these events.
So I'm wondering if there wouldn't be a way to make it simpler maybe?
Instead of addressing one "x" event in particular with "$gameMap._events[x]", have all the events with a given label (for instance
<Label: ??>) behave the same.
This way all I would have to do is run a script call changing ALL the labelled events with "visibleRange = $gameVariables.value(y)".
Much easier to manage.
If this is not possible, I would still take a way to manage all same events at the same time, for instance through a specific Note tag (like <Hidden>). Anything that allows me to identify and group them, so I can run something like:
$gameMap._events_with_Hidden_tag._labelWindow.visibleRange = $gameVariables.value(y)
wouldn't be possible for the visibleRange=Number to set it to Eval(Number(RegExp)['$1']))
so variables can be used?
unless there are more places like that to make it work though, or it could throw
error like that.
I know a plugin that can save the variable value, but I'm not sure it will work in MZ though.
but you can give it a try, so you can use the scriptcalls provided?
Olivia_MetaControls persist switches/variables, but need probably be tested in MZ,
unless FOSSIL can help on it?
even if you use eval, the parameters need to be changes too,
if that is obfuscated as well, you need that method to a string.
than type would be left off, in order to use eval ( $gameVariables.value(n); ).
so I think you need to ask the visu team to make the change to use
numbers or eval for a valid JS code (switch, variables, etc).
than it could be done, so that way, I dont think so really.