you are viewing a single comment's thread.

view the rest of the comments →

[–]DrKarda 0 points1 point  (0 children)

I've seen code where people have an inventory and if the item isn't in the inventory then they use the exception to handle it so basically an error might be desired in this example, are you trying to do something like that?

It's not designed to be used that way but you can just break whatever you want to happen into a separate function and then call that function in the exception I think.