Old 01-11-2017, 04:12 PM   #1
AndreyMarchenko
Human being with feelings
 
AndreyMarchenko's Avatar
 
Join Date: Dec 2013
Posts: 166
Default How to import Lua script?

Hi

Could someone tell me please how to import Lua script? I'm on Reaper v.5311/64

Best,
Andrey
__________________
Soundcloud, Bandcamp
AndreyMarchenko is offline   Reply With Quote
Old 01-12-2017, 01:24 AM   #2
solger
Human being with feelings
 
solger's Avatar
 
Join Date: Mar 2013
Posts: 3,759
Default

1) Open the Action List
2) Hit the Reascript [Load...] button
solger is offline   Reply With Quote
Old 01-13-2017, 11:42 PM   #3
AndreyMarchenko
Human being with feelings
 
AndreyMarchenko's Avatar
 
Join Date: Dec 2013
Posts: 166
Default

Quote:
Originally Posted by solger View Post
1) Open the Action List
2) Hit the Reascript [Load...] button
Very strange... When i did it first i can't load it. Thank anyway!
__________________
Soundcloud, Bandcamp
AndreyMarchenko is offline   Reply With Quote
Old 01-13-2017, 11:59 PM   #4
EpicSounds
Human being with feelings
 
EpicSounds's Avatar
 
Join Date: Jul 2009
Posts: 5,540
Default

just to be clear for everyone coming across this thread with the same question

loading just adds it to the action list, it doesn't run automatically. You only need to do this once.

after that you can search for, assign shortcut and run as needed.
__________________
REAPER Video Tutorials, Tips & Tricks and more at The REAPER Blog
EpicSounds is online now   Reply With Quote
Old 01-14-2017, 01:21 AM   #5
vanhaze
Human being with feelings
 
vanhaze's Avatar
 
Join Date: Jul 2012
Location: Netherlands
Posts: 4,772
Default

To add another rather important thing:

You first should move a Script you wanna load in Reaper into Reaper's Script folder.
And then:
1) Open the Action List
2) Hit the Reascript [Load...] button and choose the Script.

Reason is, is that the Reascript Load function not really IMPORTS the Script into Reaper's Script folder.
(Which is abit cumbersome imho).

For instance:
Let's say you have a Script on your desktop.
You then do:
1) Open the Action List
2) Hit the Reascript [Load...] button and choose the Script.

You then delete the Script from desktop, maybe assuming the Script is imported into Script folder already.

Next time you wanna execute the Script in Reaper, Reaper gives error that it can't find the Script.

Maybe this all isn't the case for PC users, but for mac users, it certainly is.
vanhaze is offline   Reply With Quote
Old 01-14-2017, 10:05 AM   #6
EpicSounds
Human being with feelings
 
EpicSounds's Avatar
 
Join Date: Jul 2009
Posts: 5,540
Default

That's a good point Rob

moving or deleting a script from the system doesn't remove it from the action list, so attempting to run it will cause an error.

mpl has a script in ReaPack for this situation
Script: mpl_Delete nonexistent scripts from ActionList.lua
__________________
REAPER Video Tutorials, Tips & Tricks and more at The REAPER Blog
EpicSounds is online now   Reply With Quote
Old 01-14-2017, 10:07 AM   #7
vanhaze
Human being with feelings
 
vanhaze's Avatar
 
Join Date: Jul 2012
Location: Netherlands
Posts: 4,772
Default

Wow, great tip Jon !
Wasn't aware of this handy one, thx !
vanhaze is offline   Reply With Quote
Old 01-15-2017, 03:29 AM   #8
solger
Human being with feelings
 
solger's Avatar
 
Join Date: Mar 2013
Posts: 3,759
Default

Quote:
Originally Posted by AndreyMarchenko View Post
Very strange... When i did it first i can't load it. Thank anyway!
Which lua script are you trying to load or use?
Can you maybe post a link ...


Quote:
Originally Posted by vanhaze View Post
For instance:
Let's say you have a Script on your desktop.
You then do:
1) Open the Action List
2) Hit the Reascript [Load...] button and choose the Script.

You then delete the Script from desktop, maybe assuming the Script is imported into Script folder already.

Next time you wanna execute the Script in Reaper, Reaper gives error that it can't find the Script.

Maybe this all isn't the case for PC users, but for mac users, it certainly is.
It's the same on PC.


Moving or deleting the file will break the action since it basically just points to the script file using an absolute file path.

So in case you move the script file, you have the following options:
- Put the script file back to the original location
- Or edit the file-path in reaper-kb.ini
- Or remove the broken action from the action list and import the script file again

Last edited by solger; 01-15-2017 at 03:47 AM.
solger is offline   Reply With Quote
Old 10-10-2019, 01:03 AM   #9
buckman
Human being with feelings
 
buckman's Avatar
 
Join Date: Jul 2008
Posts: 1,670
Default

Sorry for asking, but as its now 2019 and I am using latest Reaper, I have just downloaded a Custom Action and 3 scripts .RAR

Have extracted these, into 3 x .lua files and a 'ReaperKeyMap' file.

What do I add where and in what order for these to work? or do I add the whole .RAR file and these become extracted within Reaper itself?

Do I need SWS or any sort of add on at all before installing?

I believe once these are in Reaper, I can then use my own custom Action Key to trigger this?
__________________
==
Reaper 6 needs Area Selection!
http://forum.cockos.com/project.php?issueid=122
buckman is offline   Reply With Quote
Old 10-10-2019, 07:14 AM   #10
solger
Human being with feelings
 
solger's Avatar
 
Join Date: Mar 2013
Posts: 3,759
Default

Quote:
Originally Posted by buckman View Post
... I have just downloaded a Custom Action and 3 scripts .RAR

Have extracted these, into 3 x .lua files and a 'ReaperKeyMap' file...
Which ones exactly? Can you please post links.
__________________
ReaLauncher
solger is offline   Reply With Quote
Old 10-10-2019, 07:20 AM   #11
buckman
Human being with feelings
 
buckman's Avatar
 
Join Date: Jul 2008
Posts: 1,670
Default

Quote:
Originally Posted by solger View Post
Which ones exactly? Can you please post links.
Yes;
https://drive.google.com/file/d/1ckd...RGJsmXRXS/view

What goes where exactly for this to run correctly?
__________________
==
Reaper 6 needs Area Selection!
http://forum.cockos.com/project.php?issueid=122
buckman is offline   Reply With Quote
Old 10-10-2019, 07:36 AM   #12
solger
Human being with feelings
 
solger's Avatar
 
Join Date: Mar 2013
Posts: 3,759
Default

Quote:
Originally Posted by buckman View Post
Yes;
https://drive.google.com/file/d/1ckd...RGJsmXRXS/view

What goes where exactly for this to run correctly?
When using ReaPack, the three scripts from me2beats are automatically installed into the [Main] and [Main (alt recording)] Section of the Action List:
  • set project bpm according to selected take name bpm.lua
  • Paste BPM.lua
  • Copy BPM.lua

If you want to install them manually:
  1. Put the lua files into (a subfolder of) the Scripts folder in the Reaper resource path (Options > Show Reaper resource path ...)
  2. Load the lua files via the Action List into the [Main] Sections mentioned above
  3. Assign these actions to a key shortcut, a toolbar button, a menu, etc.

By the way, any specific reason why you're not installing these scripts directly via ReaPack?


ReaperKeyMap files
  1. Put the Audio take to project tempo.ReaperKeyMap file, for instance, in the KeyMaps or Scripts folder in the Reaper resource path
  2. Then Import it into the Action List via the [Import/export] button at the bottom left of the Action List
  3. And assign it to a key shortcut, a toolbar button, a menu, etc.
__________________
ReaLauncher
solger is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 08:10 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.