How to obscure a lua file?

If you already tried to open the chartboost lua library, you may have noticed that the file is obscured. 

Does any one know who to do that? (obscure a file that can be required normally in lua)

UPDATE: For those people looking for that same info, I suggest looking here.

http://www.lua.org/manual/4.0/luac.html

Is a good place to start :slight_smile:

In my testing I’ve found that not all versions of luac will produce a file compatible with Corona. (I’m on OSX)

Not sure if it’s a 32/64 bit thing or not. 

Haven’t used it myself in a released app, just played around with it some time back…

Thanks guys. I will check luac.

There is also a website i found that can do it for you. You upload your Lua file, it byte encodes it on their server and sends you back the byte encoded file.

I cannot find the link now, but i bookmarked it somewhere. If i find the link i’ll post it.

Could be a nice idea for someone to make a gui based tool for doing this.

Cheers

Thanks. If you find, please post here. I will google it.

Another thing, since you both are enterprise users, maybe you can help me with a simple question.  In Java, I am adding a View to the Corona Activity, do you know if it is possible for me to access that view from the Corona code (To just its position for example)?

Found it: http://luac.mtasa.com/

I tried using it with the main.lua file from the fishies sample code and it ran fine in the simulator. That is as far as my testing went.

I know our Lua code gets compiled into byte code when we do a release build, so i’m not sure how having code that is already in byte code form would affect that process.

If you do any experimentation, let us know the results :slight_smile:

I also do not know anything else about that site than what i posted above, bar the test i did. I am not affiliated with it in any way, so use at your own risk :wink:

Hope this helps.

http://www.lua.org/manual/4.0/luac.html

Is a good place to start :slight_smile:

In my testing I’ve found that not all versions of luac will produce a file compatible with Corona. (I’m on OSX)

Not sure if it’s a 32/64 bit thing or not. 

Haven’t used it myself in a released app, just played around with it some time back…

Thanks guys. I will check luac.

There is also a website i found that can do it for you. You upload your Lua file, it byte encodes it on their server and sends you back the byte encoded file.

I cannot find the link now, but i bookmarked it somewhere. If i find the link i’ll post it.

Could be a nice idea for someone to make a gui based tool for doing this.

Cheers

Thanks. If you find, please post here. I will google it.

Another thing, since you both are enterprise users, maybe you can help me with a simple question.  In Java, I am adding a View to the Corona Activity, do you know if it is possible for me to access that view from the Corona code (To just its position for example)?

Found it: http://luac.mtasa.com/

I tried using it with the main.lua file from the fishies sample code and it ran fine in the simulator. That is as far as my testing went.

I know our Lua code gets compiled into byte code when we do a release build, so i’m not sure how having code that is already in byte code form would affect that process.

If you do any experimentation, let us know the results :slight_smile:

I also do not know anything else about that site than what i posted above, bar the test i did. I am not affiliated with it in any way, so use at your own risk :wink:

Hope this helps.