I wonder if there is any idea of a timeline when JS scripts will run again in Logic. I’m aware that it is due to some restrictions in Mac OS of running JS outside sandboxes but still : I very much miss a simple script that can replace ALL the given Phonemes in the selected notes by another Phoneme ( Like hh to br) in one go. I can read JS and even LUA with some difficulty but would appreciate a pointer or an example if someone has something that deals with that. Have a great day!
Ps : It would have to be LUA because of Logic I forgot to mention…
I just tried ChatGTP and it cam up with this. But I am hesitant having seen the failed code it produces in languages and environments I’m familiar with lua
– Define the phoneme you want to replace and the phoneme you want to replace it with
local phoneme_to_replace = “AH”
local replacement_phoneme = “EH”
– Get the selected notes in the Synthesizer V plugin
local selected_notes = plugin.getSelectedNotes()
– Iterate through each selected note
for _, note in ipairs(selected_notes) do
– Iterate through each phoneme in the note
for _, phoneme in ipairs(note:getPhonemes()) do
– Check if the phoneme matches the one to be replaced
if phoneme:getSymbol() == phoneme_to_replace then
– Replace the phoneme
phoneme:setSymbol(replacement_phoneme)
end
end
end