I know of two ways to run external .rb-files.
You can require them:
[rgss]$: << '.' # Add the current working directory
require 'my_file' # You don't have to write .rb, but you can do it
[/rgss]
Note that you cannot require .so-files like you can in Ruby.
The other way is to load the data of the file and then evaluate it:
[rgss]file = File.open('my_file.rb', 'r+')
data = f.read
file.close
eval(data)
[/rgss]
With this approach the file extension doesn't have to be .rb
The difference between the former and latter approach is that require only execute the file the first time where as the second way evaluates the data every time it is encountered. There probably are other differences although I doubt they will be of any significance except in rare situations.
*hugs*
- Zeriab