HISE Logo Forum
    • Categories
    • Register
    • Login

    include files

    Scheduled Pinned Locked Moved Scripting
    3 Posts 2 Posters 425 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.
    • ustkU
      ustk
      last edited by

      Hi
      Is it possible to include an external file that contains both onInit and onTimer functions?

      Generally, in my main code (onInit), I try to keep it short and throw every part in external files...
      If I want two separated parts, do I have to use two separated .js? like one in the onInit and the other in the onTimer?

      It is certainly basics but I can't catch it...
      Thanks

      Hise made me an F5 dude, browser just suffers...

      1 Reply Last reply Reply Quote 0
      • d.healeyD
        d.healey
        last edited by

        Kind of. In your external file create a function called onInitCB and then call that function in your main onInit callback once you've included the file. Do the same for the onTimer callback.

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

        1 Reply Last reply Reply Quote 1
        • ustkU
          ustk
          last edited by

          Thanks, David! I'm on it...

          Hise made me an F5 dude, browser just suffers...

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

          13

          Online

          2.0k

          Users

          12.7k

          Topics

          110.2k

          Posts