Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

MessageOut Event

Is there a way to find out which script errored?

3 answers

✓ Accepted answer

Instead of using the LogService for getting script errors, I recommend using ScriptContext's error event. It gives you a reference to the script object that errored, as well as the stack trace and the error message.

game:GetService("ScriptContext").Error:connect(function(message, trace, script)
	print(script:GetFullName().." errored!")
	print("Reason: "..message)
	print("Trace: "..trace)
end)

(This example was taken from the wiki page for ScriptContext.Error)

I believe it is the Output Window

5 comments

0

I mean, when the event is fired I want to know which script errored

0

Script Performance?

0

I also mean In-Game

0

I'm not sure how to check In-Game, but your best bet is running server Tools-Test-Play Solo

0

I'm creating an In-Game output system

This discussion is preserved as it was. New answers, comments, and votes are closed.