Yet another continuation of a thread I started for VLR
. I've got some Lua files from the game. I'm interested in trying to decompile them back into source code. I know that decompiling is often a tricky thing but there do exist decompilers for Lua such as unluac. The problem is that these programs error out for some reason (I don't know why). Here are two sample Lua files
How difficult is the process of bringing a Lua script back to source code? Are there any resources available to help guide me?
LuaDec exists for this purpose however it is kind of limited to what it can/can't restore. If the version of Lua that the application is using does not match the version that LuaDec was compiled with, it wont work. Also, if the Lua library the target uses has custom libraries, alterations or any new byte code added, LuaDec will fail due to it missing the custom things.
These two files do not work with the standard Lua library and LuaDec so it appears they have custom edits in their stuff.
The file header tells you what version of Lua is being used though to help limit things down:
The beginning 1B 4C 75 61 is the typical Lua compiled file header. Afterward the 51 is the version.
This states that Lua 5.1 was used to compile the Lua chunk.