- Topics: 124
- Replies: 1070
- Total: 1194
back to basics, to figure this out – here is the simplest
form of random by group, with a simple randomize method
mini demo panel:
method: (randomizes only first modulator in customNameGroup)
randomize=function() --randomize a group by customNameGroup --This stops issues during panel bootup if panel:getRestoreState() or panel:getProgramState() then return end --custom group items to randomize local modGroup = panel:getModulatorWithProperty("modulatorCustomNameGroup","custGroup1") --random seeder local t=os.time() local c=os.clock() math.randomseed(t*c) rand = math.random(0,127) --value range to random modGroup:setModulatorValue(rand,false,false,false) end
the ‘format string’ property below is not readable, cannot
see what is required there – is this the key to this?
i cannot see why this method would not ‘get’ all modulators
with same customGroupName. this is a simple method triggered
by button valuechange, no condition required there – and i
removed the ‘for…’ iteration, as it should not be needed.
nb: want to use this to check through all actions for
‘custom’ parameters – seems to be a useful thing to do?