Skip to content

Instantly share code, notes, and snippets.

@davormaricdev
Created February 19, 2022 22:45
Show Gist options
  • Select an option

  • Save davormaricdev/390cfb173f338b4ddfc11b07993fbd42 to your computer and use it in GitHub Desktop.

Select an option

Save davormaricdev/390cfb173f338b4ddfc11b07993fbd42 to your computer and use it in GitHub Desktop.
GrandMA2 Quantize FX Plugin
-- Davor's GrandMA2 Quantize FX Plugin
-- davormaric@outlook.com
-- Use this plugin to sync running effects.
-- [USER DEFINEABLE AREA] --
local execs = {"1.101", "1.102", "1.103"} -- Executors that contains effects
local debug = false -- set to true if you want to print debug in console output
-- [DO NOT TOUCH ANYTHING BELOW THIS LINE] --
local cmd = gma.cmd
local get = gma.show.getobj
local handle = get.handle
local print = gma.feedback
function GetActiveExecutors(targetExecutors)
local activeExecutors = {}
for i = 1, #targetExecutors, 1 do
local exec = targetExecutors[i]
local handle = handle('Executor ' .. exec .. ' Cue')
-- Show a warning message if Executor doesn't exist
if debug then
if handle == nil then
print('Warning (Quantize Lua): Executor ' .. exec .. ' does not exist!')
end
end
if handle and get.class(handle) == "CMD_CUE" then
table.insert(activeExecutors, exec)
if debug then
print('Executor ' .. exec .. ' is ON.')
end
end
end
return activeExecutors
end
function ConstructCmdMessage(activeExecutors)
local message = ""
for i = 1, #activeExecutors, 1 do
local e = activeExecutors[i]
message = "" .. message .. "Off Executor " .. e .. "; On Executor " .. e .. "; "
end
return message
end
function Main()
local activeExecutors = GetActiveExecutors(execs)
local cmdMessage = ConstructCmdMessage(activeExecutors)
if debug then
print("Command: " .. cmdMessage)
end
cmd(cmdMessage)
end
return Main
@PriorAd769
Copy link
Copy Markdown

Hi thanks it's working great on executor with a seqenc in it,

but is there any way to get it work with effect assiged direcly on executor?

Thanks

@Nealtver
Copy link
Copy Markdown

Nealtver commented Jun 5, 2024

Where can i get xml file? Sorry for noob

@davormaricdev
Copy link
Copy Markdown
Author

Where can i get xml file? Sorry for noob

Add it manually through onPC and export it from there

Hi thanks it's working great on executor with a seqenc in it,

but is there any way to get it work with effect assiged direcly on executor?

Thanks

Probably yes, you would have to change the line 45 to restart the effect with proper command, not sure which one is needed

@Nealtver
Copy link
Copy Markdown

6524a150-2c8a-4ffe-974f-0778738dee58
NeQrBt
Still cant use plugin because it havent xml file. Below are the screens. LUA file is in plugins folder but MA cant see it because there is no xml file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment