is there any way to make a destroy method for a class? i have an entities class that inherits from sprite, and I'd like to make a destroy method for it. to my understanding, you have to remove all references to the class. in my case, that's just the draw list, and the variable the sprite was initialised in. I can remove the sprite from the draw order, but if i set self to nil, the variable still contains the info from the object. is there any way to also set this to nil?
I've tried looking around in self, and it doesn't look like there are any references to the variable it's assigned too, am I missing something, or is there no way to set the variable to nil from within the class? is there even a need?