check(PIEInstanceID != -1) assertion failed

I still don’t know what “Error” is doing (if it’s a variable you created or part of the class). Please provide the code for you class so that I can ensure that my setup matches what you’re doing.