I'm trying to refactor someone else's code, including making it much more OO, and moving things around between types. It's going very nicely in all ways except one. Types are not being Delete()'d. I have a Destroy() method which removes the object from the global type list and also removes a reference from a container type. There should not be any more references anywhere except locals which go out of scope. I call FlushMem in the main loop only.
I'm just wondering if there's anything I could be checking to help me find why it's not being freed correctly. I remember seeing something about FlushMem having scope but there's nothing in the FlushMem documentation when I double F1 ( well there wouldn't be, would there? )
I doubt that's the problem, but I have to consider all possibilities now. For reference, yes, the destroy method is verified as being called, and yes, FlushMem is definitely being called every frame.
I'm just wondering if there's anything I could be checking to help me find why it's not being freed correctly. I remember seeing something about FlushMem having scope but there's nothing in the FlushMem documentation when I double F1 ( well there wouldn't be, would there? )
I doubt that's the problem, but I have to consider all possibilities now. For reference, yes, the destroy method is verified as being called, and yes, FlushMem is definitely being called every frame.