Lua:encodeFunction

From Cheat Engine

Jump to: navigation, search

function encodeFunction(function, protect OPTIONAL) : string

Converts a given function into an encoded string that you can pass to decodeFunction.

Contents

[edit] Function Parameters

Parameter Type Description
function function The function to encode

[edit] Examples

local function myCoolFunction(str) print(str) end
print(encodeFunction(myCoolFunction))
local function myCoolFunction(str) print(str) end
local encodedFunc = encodeFunction(myCoolFunction)
local decodedFunc = decodeFunction(encodedFunc)
decodedFunc('I have the power!')

[edit] See also

[edit] Related Functions

Personal tools
Toolbox