love.threaderror (日本語)

LÖVE 0.9.0 から使用可能
このコールバックは以前のバージョンでは非対応です。

Thread でエラーが起きたときに起動するコールバック関数です。

関数

概要

love.threaderror( thread, errorstr )

引数

Thread thread
エラーが発生したスレッド。
string errorstr
エラーメッセージ。

返値

ありません。

用例

function love.load()
  mythread = love.thread.newThread("thread.lua")
  mythread:start()
end

function love.threaderror(thread, errorstr)
  print("Thread error!\n"..errorstr)
  --  thread:getError() は同一内容のエラー文字列を返します。
end

関連



そのほかの言語