Linked button + control processor id
-
If you have a button linked to another button on a different script processor, is it possible to still have that same button control something else? Like to open or close a panel?
Ive looked at ppl with similar post but, not like this so I haven't had any luck scripting.
-
No. You can either use parameter/processor ID or you can use a custom control callback. Not both.
-
ok, so here is the code, I transferred it to the main script.
is it possible to add a call that opens and closes a panel within this code?inline function onBbutton1Control(component, value) { { local indexes = []; for(i = 0; i < SliderPack2.getNumSliders(); i++) { if (SliderPack2.getSliderValueAt(i) == 1) indexes.push(i); } local arr = getPossibleValues(indexes); arr = shuffle(arr); setSliders(indexes, arr); } }; Content.getComponent("Bbutton1").setControlCallback(onBbutton1Control);
-
@BWSounds Yes, just add it as you would if there was no other code in the callback
-
@BWSounds David is right, but if you make a reference to the scriptprocessor
you can link the 2 buttons together and still have the opportunity to use the mainbtn callback for other purposes, like this:HiseSnippet 949.3oc0V0saaaCElxwrnVatqEaO.D9lo.jkJu1zMfgg0XGmAiM6XDmUr6BnkniHhDofDUyLJ5y5dE1aP6gRhQRIpEtdqWLekO+xuygeGwyhDoGKMUlfr5cwlXFx5KwK2HTAiCnbAZ5IHqGgmQSUrDRgpQahoooLejk0d+pVgUutn7e+yuLhFREdrJUHzqjbO1uyi3pJsKd4uwCCOk5ytfGUy6m+xodRwXYnLCvydXWTL06Z5Ur4TsacvHqGLwmqjIKUTEKE7Yjzeyx.4MhB+eEOkuJjoEFhVBIpPMZb.OzegoVSQHqtKpp78Jp7uAOi6yuUeUG3w4FHUQTuGX0oIj51.RC+PP5TYnuNAe.30oF75V.umfW5kviUUVzX6KvSEvkyZJz1qCqBeQcNpCdrD7PnNLhdM6zDP31Hbdgq6Ajibc2+m5a229oOkPzNQnjD1ZVBbURTRhJfQRySWr4nI2vUADt5aSIqTh91v0Vph7ZZB4NXbH4mI47oCuhoZzdcFT3ZUac3fBXXfxLn+qSOYclvSwkv4vEgbA6VEDoX1wSme4nKlqKxDYnimLJVJfx8..NgYr86a+l918tKrNLkoNVoR3qxTLm6Ycw4mMdxxkmctN0lLAf6s4.zzPgRZr43bFXPxf80IuDOioggq.Rry8PpNc0pi4RE6Lgy91uwtm8asI20z50sZqLYgrjVMqmuR9XA5HxhVwRLknwQfz0jU+fsiU6UzYp4nTLUvUmEyJkq38Cag2iJasvDfUIBAWU47+GUx+GkoTRAhCIwFaZpnb7W+COn+X5ITE0jIHovAEyRTbc8XcB60vGlJlr5gOgkdsRFm6a4EJTyay49WHKrk931X9yMbeUfVvGDBX7qBTFIz1NU+036Mbz1zs0eiIUidMHsvbmglR88KvtyfFtL3.BL8Cy9++gFZ+eEMzToFMtnaKv5pppq5ZyKmVbqR0+Zl8WgabU84fd2cqO76ywagHCORJ8yBoplubpWQnz.bi2fDqeFRjxUapuBwmvyots9bZqeVYKg6SvK3Juf1wamVvq9k5Oy3sb4j93IqWy7TUfsK9z+bW2D4S.JmKyTbwUynvikZhv7rnkv9YdL.IBAKLUyI5nI3ExtFNxRlvOW3cvuRiC0xVkFGZLhhndIxK8JFKzq+7vbM.lD4a90CVAEjICMyAXr6gtnHXehK87zshuCvd6w786PLOaGh446PLGsCw7hcHleXGh4G+nwnWk63LkLpXLATrXR92irrlHn.KKmQhdOymFaTA
That is if you don't want to move your code from the other script processor