[Lua] Thread

Section's for general approaches on hacking various options in games. No online-related discussions/posts OR warez!
Post Reply
User avatar
TheyCallMeTim13
Administration
Administration
Posts: 980
Joined: Fri Mar 03, 2017 12:31 am
Reputation: 154
Contact:

[Lua] Thread

Post by TheyCallMeTim13 » Tue Apr 17, 2018 3:54 am

https://wiki.cheatengine.org/index.php? ... ass:Thread

Code: Select all

local function luaThread(thread)
    while RunLuaThread do
        -- Body
        sleep(0)
    end
    thread.terminate()
end
RunLuaThread = true
createThread(luaThread)

Code: Select all

{$lua}
------------------------------ ENABLE ------------------------------
[ENABLE]
local function luaThread(thread)
    while RunLuaThread do
        -- Body
        sleep(0)
    end
    thread.terminate()
end
----------------------------------
if syntaxcheck then return end
RunLuaThread = true
createThread(luaThread)
------------------------------ DISABLE ------------------------------
[DISABLE]
if syntaxcheck then return end
RunLuaThread = false
Last edited by TheyCallMeTim13 on Tue May 01, 2018 1:08 am, edited 4 times in total.

Post Reply

Who is online

Users browsing this forum: No registered users