Script Encryption (Paid Scripts) #

Protect your Lua source by shipping encrypted .luae modules. Customers must verify an authorization code from the developer portal before the engine decrypts and runs your module.

Overview #

Role Action
Developer Register → create script → generate auth codes → upload .lua → download .luae
Customer Enter auth code once → cached on device → require encrypted module

Step 1: Developer portal #

  1. Open the Developer Portal (opens new window) and log in.
  2. Scripts → create a script (name + description).
  3. Copy the Key column — your DEV_SCRIPT_KEY in Lua.

Step 2: Generate authorization codes #

Generate tab → select script and tier → distribute codes to customers.

Step 3: Encrypt your module #

Upload core .lua in the portal encrypt UI → download .luae. Encryption uses AES-256-CBC tied to your script secret.

Step 4: Entry script #

local DEV_SCRIPT_KEY = "s48_my_script"

if not verifyDeveloperScript(DEV_SCRIPT_KEY) then
    return
end

local core = require("MyScriptCore")
if core and core.run then core.run() end
1
2
3
4
5
6
7
8

Optional popup text: verifyDeveloperScript(key, "Name", "Description").

Check license: isDeveloperScriptVerified(DEV_SCRIPT_KEY).

Layout #

script/scripts/MyBrand/
  MyScript.lua
  MyScriptCore.luae
1
2
3

Never ship the unencrypted core .lua to customers.