Ignore an error?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Ignore an error?
Is it possible to ignore an error? like when an error happens, the error screen won't come, like it will just continue normally. Is that possible?
Code: Select all
fun = true
school = true
function isItFun()
if school then
fun = false
end
if not fun then
me:explode()
end
end
- Positive07
- Party member
- Posts: 1014
- Joined: Sun Aug 12, 2012 4:34 pm
- Location: Argentina
Re: Ignore an error?
you can use [manual]pcall[/manual] and [manual]xpcall[/manual] to catch errors yourself so that they dont propagate to LÖVE
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Re: Ignore an error?
Ok thanks
Code: Select all
fun = true
school = true
function isItFun()
if school then
fun = false
end
if not fun then
me:explode()
end
end
Who is online
Users browsing this forum: No registered users and 233 guests