lovr.thread.newThread

Creates a new Thread from Lua code.

thread = lovr.thread.newThread(body)

Arguments

NameTypeDescription
bodystringThe code to run in the Thread.

Returns

NameTypeDescription
threadThreadThe new Thread.

Notes

The Thread won't start running immediately. Use Thread:start to start it.

See also