init.lua 640 B

123456789101112
  1. return {
  2. summary = 'A message channel for communicating between threads.',
  3. description = [[
  4. A Channel is an object used to communicate between `Thread` objects. Channels are obtained by
  5. name using `lovr.thread.getChannel`. Different threads can send messages on the same Channel to
  6. communicate with each other. Messages can be sent and received on a Channel using
  7. `Channel:push` and `Channel:pop`, and are received in a first-in-first-out fashion. The
  8. following types of data can be passed through Channels: nil, boolean, number, string, and any
  9. LÖVR object.
  10. ]],
  11. constructor = 'lovr.thread.getChannel'
  12. }