Forum
    • Categories
    • Register
    • Login

    getIdList misses hardcoded scripts

    Scheduled Pinned Locked Moved Bug Reports
    3 Posts 1 Posters 879 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • David HealeyD
      David Healey
      last edited by

      Synth.getIdList("Script Processor") doesn't return hardcoded scripts such as the MidiMuter.

      <?xml version="1.0" encoding="UTF-8"?>
      
      <Processor Type="SynthChain" ID="Master Chain" Bypassed="0" Gain="1" Balance="0"
                 VoiceLimit="128" KillFadeTime="20" IconColour="0" packageName=""
                 views="32.rk1bzA.....A.........DC...................." currentView="-1">
        <EditorStates BodyShown="0" Visible="1" Solo="0"/>
        <ChildProcessors>
          <Processor Type="MidiProcessorChain" ID="Midi Processor" Bypassed="0">
            <EditorStates BodyShown="1" Visible="1" Solo="0" Folded="0"/>
            <ChildProcessors>
              <Processor Type="ScriptProcessor" ID="Test Script" Bypassed="0" Script="const var scriptNames = Synth.getIdList(&quot;Script Processor&quot;);&#13;&#10;&#13;&#10;for (i = 0; i &lt; scriptNames.length; i++)&#13;&#10;{&#13;&#10;&#9;Console.print(scriptNames[i]);&#10;}&#13;&#10;function onNoteOn()&#10;{&#10;&#9;&#10;}&#10;function onNoteOff()&#10;{&#10;&#9;&#10;}&#10;function onController()&#10;{&#10;&#9;&#10;}&#10;function onTimer()&#10;{&#10;&#9;&#10;}&#10;function onControl(number, value)&#10;{&#10;&#9;&#10;}&#10;">
                <EditorStates BodyShown="1" Visible="1" Solo="0" contentShown="1" onInitOpen="1"
                              onNoteOnOpen="0" onNoteOffOpen="0" onControllerOpen="0" onTimerOpen="0"
                              onControlOpen="0"/>
                <ChildProcessors/>
                <Content/>
              </Processor>
              <Processor Type="MidiMuter" ID="MidiMuter" Bypassed="0">
                <EditorStates BodyShown="1" Visible="1" Solo="0"/>
                <ChildProcessors/>
                <Content>
                  <Control type="ScriptButton" id="ignoreButton" value="0"/>
                  <Control type="ScriptButton" id="fixStuckNotes" value="0"/>
                </Content>
              </Processor>
              <Processor Type="ScriptProcessor" ID="Another Test Script" Bypassed="0"
                         Script="function onNoteOn()&#10;{&#10;&#9;&#10;}&#10;function onNoteOff()&#10;{&#10;&#9;&#10;}&#10;function onController()&#10;{&#10;&#9;&#10;}&#10;function onTimer()&#10;{&#10;&#9;&#10;}&#10;function onControl(number, value)&#10;{&#10;&#9;&#10;}&#10;">
                <EditorStates BodyShown="1" Visible="1" Solo="0" contentShown="1" onInitOpen="1"
                              onNoteOnOpen="0" onNoteOffOpen="0" onControllerOpen="0" onTimerOpen="0"
                              onControlOpen="0" Folded="1"/>
                <ChildProcessors/>
                <Content/>
              </Processor>
            </ChildProcessors>
          </Processor>
          <Processor Type="ModulatorChain" ID="GainModulation" Bypassed="0" Intensity="1">
            <EditorStates BodyShown="1" Visible="0" Solo="0" Folded="1"/>
            <ChildProcessors/>
          </Processor>
          <Processor Type="ModulatorChain" ID="PitchModulation" Bypassed="1" Intensity="0">
            <EditorStates BodyShown="1" Visible="0" Solo="0" Folded="1"/>
            <ChildProcessors/>
          </Processor>
          <Processor Type="EffectChain" ID="FX" Bypassed="0">
            <EditorStates BodyShown="1" Visible="0" Solo="0" Folded="1"/>
            <ChildProcessors/>
          </Processor>
        </ChildProcessors>
        <RoutingMatrix NumSourceChannels="2" Channel0="0" Send0="-1" Channel1="1" Send1="-1"/>
        <macro_controls>
          <macro name="Macro 1" value="0" midi_cc="-1"/>
          <macro name="Macro 2" value="0" midi_cc="-1"/>
          <macro name="Macro 3" value="0" midi_cc="-1"/>
          <macro name="Macro 4" value="0" midi_cc="-1"/>
          <macro name="Macro 5" value="0" midi_cc="-1"/>
          <macro name="Macro 6" value="0" midi_cc="-1"/>
          <macro name="Macro 7" value="0" midi_cc="-1"/>
          <macro name="Macro 8" value="0" midi_cc="-1"/>
        </macro_controls>
        <MidiAutomation/>
      </Processor>
      

      Free HISE Bootcamp Full Course for beginners.
      YouTube Channel - Public HISE tutorials
      My Patreon - HISE tutorials

      1 Reply Last reply Reply Quote 0
      • David HealeyD
        David Healey
        last edited by

        Oh I just realised I have to use Synth.getIdList("MidiMuter"). I'll leave this here for future reference :)

        Free HISE Bootcamp Full Course for beginners.
        YouTube Channel - Public HISE tutorials
        My Patreon - HISE tutorials

        1 Reply Last reply Reply Quote 0
        • David HealeyD
          David Healey
          last edited by David Healey

          Ran in to this again. It works for the MidiMuter but doesn't seem to work for others like CCSwapper or LegatoWithRetrigger

          Edit: So it does work but you need to know the secret spellings. CC Swapper and Legato with Retrigger - spacing and capitalisation are important.

          Free HISE Bootcamp Full Course for beginners.
          YouTube Channel - Public HISE tutorials
          My Patreon - HISE tutorials

          1 Reply Last reply Reply Quote 3
          • First post
            Last post

          75

          Online

          2.1k

          Users

          13.0k

          Topics

          112.7k

          Posts