Uploaded August 2021 | Updated September 2026, 45 minutes ago
Hey folks!
In episode 02 I gave myself and all of y'all some challenges to test your scripting chops, and in this episode I'll reveal the solutions I found to these challenges. Post in the comments if you got a different/better solution so everyone can learn from you!
I'll also be making corrections in these episodes if/when I explained something not-so well in the previous episode.
Episode 03 will come out when Episode 02 hits 555 views. It seems like no one is really interested in this series, so it's starting to feel like the time in takes to do them is not worth it!
Whether or not this series continues is based on demand, but in any event, you can join Leandro and I, plus other special guests, Every Tuesday, 1.30pm EST (10.30am PT, 5.30pm GMT) for live scripting tutorials.
Joins us every Wednesday, 1.30pm EST (10.30am PT, 5.30pm GMT) for audio production livestreams on Leandro's channel: youtube.com/channel/UC_R-6HcHW5V9_FlZe30tnGA
LINKS:
Leandro Facchinetti’s channel: youtube.com/channel/UC_R-6HcHW5V9_FlZe30tnGA
Leafac Repository: github.com/leafac/reaper
Documentation:
REAPER API: https://www.reaper.fm/sdk/reascript/reascripthelp.html
XRaym API: extremraym.com/cloud/reascript-doc
Lua API (for functions that don't start with reaper.): lua.org/manual/5.3
For beginners:
XRaym Repository (tons of micro-scripts to use and learn from): github.com/X-Raym/REAPER-ReaScripts
For Programmers:
Learn X in Y minutes (Where X=Lua): learnxinyminutes.com/docs/lua
Programming in Lua: lua.org/pil
You can donate to me & Leandro here:
Donations ➡️ buymeacoffee.com/iddqdsound
➡️ patreon.com/leafac
My Reaper Stash ➡️ https://stash.reaper.fm/u/IDDQDSound
Copy the link below to Reapack to import my Repository ⬇️
github.com/iddqdsound/reaper/tree/master
Instagram: iddqdmusic
🎧 My Music:
Soundcloud.com/iddqdmusic
iddqdmusic.bandcamp.com
Official Website: iddqdsound.com
Chapters:
0:00 Intro
0:54 1a Correction 1: Boolean arguments are true/false, NOT 1/0!
1:53 1b Correction 2: Global Variables don't communicate across scripts
2:50 2a Challenge #3: Moving Edit cursor by time selection length
4:12 2a.2 When a function returns 2 values
4:30 2a.3 Demonstration
5:29 2b Challenge #1-2: Moving edit cursor by measures/minutes:seconds
5:44 2b.2 Getting minutes:seconds from pure seconds
6:08 2b.3 math.floor function in lua
6:37 2b.4 Modulo math operator in lua
7:15 2b.5 Concatenating values as strings
7:34 2b.6 Calculating measure duration
9:47 2b.7 Demonstration
10:47 2b.8 OnCommand functions
11:45 2b.9 Using Mousewheel/MIDI/OSC to run any action
14:25 2b.10 Moving Edit Cursor forward/back by Mousewheel/CC
17:33 When will the next episode come out?
18:39 Outro
Hey folks!
In episode 02 I gave myself and all of y'all some challenges to test your scripting chops, and in this episode I'll reveal the solutions I found to these challenges. Post in the comments if you got a different/better solution so everyone can learn from you!
I'll also be making corrections in these episodes if/when I explained something not-so well in the previous episode.
Episode 03 will come out when Episode 02 hits 555 views. It seems like no one is really interested in this series, so it's starting to feel like the time in takes to do them is not worth it!
Whether or not this series continues is based on demand, but in any event, you can join Leandro and I, plus other special guests, Every Tuesday, 1.30pm EST (10.30am PT, 5.30pm GMT) for live scripting tutorials.
Joins us every Wednesday, 1.30pm EST (10.30am PT, 5.30pm GMT) for audio production livestreams on Leandro's channel: youtube.com/channel/UC_R-6HcHW5V9_FlZe30tnGA
LINKS:
Leandro Facchinetti’s channel: youtube.com/channel/UC_R-6HcHW5V9_FlZe30tnGA
Leafac Repository: github.com/leafac/reaper
Documentation:
REAPER API: https://www.reaper.fm/sdk/reascript/reascripthelp.html
XRaym API: extremraym.com/cloud/reascript-doc
Lua API (for functions that don't start with reaper.): lua.org/manual/5.3
For beginners:
XRaym Repository (tons of micro-scripts to use and learn from): github.com/X-Raym/REAPER-ReaScripts
For Programmers:
Learn X in Y minutes (Where X=Lua): learnxinyminutes.com/docs/lua
Programming in Lua: lua.org/pil
You can donate to me & Leandro here:
Donations ➡️ buymeacoffee.com/iddqdsound
➡️ patreon.com/leafac
My Reaper Stash ➡️ https://stash.reaper.fm/u/IDDQDSound
Copy the link below to Reapack to import my Repository ⬇️
github.com/iddqdsound/reaper/tree/master
Instagram: iddqdmusic
🎧 My Music:
Soundcloud.com/iddqdmusic
iddqdmusic.bandcamp.com
Official Website: iddqdsound.com
Chapters:
0:00 Intro
0:54 1a Correction 1: Boolean arguments are true/false, NOT 1/0!
1:53 1b Correction 2: Global Variables don't communicate across scripts
2:50 2a Challenge #3: Moving Edit cursor by time selection length
4:12 2a.2 When a function returns 2 values
4:30 2a.3 Demonstration
5:29 2b Challenge #1-2: Moving edit cursor by measures/minutes:seconds
5:44 2b.2 Getting minutes:seconds from pure seconds
6:08 2b.3 math.floor function in lua
6:37 2b.4 Modulo math operator in lua
7:15 2b.5 Concatenating values as strings
7:34 2b.6 Calculating measure duration
9:47 2b.7 Demonstration
10:47 2b.8 OnCommand functions
11:45 2b.9 Using Mousewheel/MIDI/OSC to run any action
14:25 2b.10 Moving Edit Cursor forward/back by Mousewheel/CC
17:33 When will the next episode come out?
18:39 Outro










