So I wanted to mod Sandbox+ to make one of the unused key combinations load a Lua script from a file and run it, so I can test Lua commands without having to keep restarting Saints Row 3. Thankfully Lua provides a function (dofile) specifically for this purpose. Now when I pressed the key combination, nothing happened. Nothing, that is, except that Sandbox+ stopped responding to key presses. I had to restart the game in order for it to work. I tried another key combination to verify that yes, Sandbox+ was running properly, and then tried my key combination again. Sure enough, it stopped responding.
I tried modifying the Lua script a bit and figured out that dofile was what was causing the problem. Okay, I figured, I'll see if io.open works. No luck—same problem. I tried using both a relative and absolute path too, in case it was an issue with the current directory.
So what I'm asking is does anybody know how to access the file system from a Lua script in Saints Row 3? Barring that, is there any way to get a text string from the user in a script (such as an in-game text input function like you use to name an outfit, or even something in an external application) without having to restart the game each time?
Also, in case this isn't possible, I have to give IdolNinja props for dealing with this when making Sandbox+. You must have the patience of a Saint. ;-) Great job either way.
I tried modifying the Lua script a bit and figured out that dofile was what was causing the problem. Okay, I figured, I'll see if io.open works. No luck—same problem. I tried using both a relative and absolute path too, in case it was an issue with the current directory.
So what I'm asking is does anybody know how to access the file system from a Lua script in Saints Row 3? Barring that, is there any way to get a text string from the user in a script (such as an in-game text input function like you use to name an outfit, or even something in an external application) without having to restart the game each time?
Also, in case this isn't possible, I have to give IdolNinja props for dealing with this when making Sandbox+. You must have the patience of a Saint. ;-) Great job either way.