mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-07 13:15:01 +00:00
More tweaks from the Rubocop overlord
This commit is contained in:
@@ -17,9 +17,10 @@ def pbGetExceptionMessage(e, _script = "")
|
||||
return e.event_message.dup if e.is_a?(EventScriptError) # Message with map/event ID generated elsewhere
|
||||
emessage = e.message.dup
|
||||
emessage.force_encoding(Encoding::UTF_8)
|
||||
if e.is_a?(Hangup)
|
||||
case e
|
||||
when Hangup
|
||||
emessage = "The script is taking too long. The game will restart."
|
||||
elsif e.is_a?(Errno::ENOENT)
|
||||
when Errno::ENOENT
|
||||
filename = emessage.sub("No such file or directory - ", "")
|
||||
emessage = "File #{filename} not found."
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user