Add some error handling to sprites