So nexus, what you recommend?
I have already given you some improvement suggestions, so I don't know what you mean.
To delete the class from memory, i invoke:
delete this;
And now the destructor is called.
I wouldn't do that. In the very most cases, the instance which is in charge of allocating the object should also deallocate it for symmetry reasons. With your approach, you enforce the use of the
new operator and therefore manual memory management (which should be avoided wherever possible). One can neither lay an Enemy on the stack, nor create a temporary object of it, nor put it inside a smart-pointer.
If I were you, I would either use Boost's pointer containers (the probably best approach), or delete each element before it is erased. If you have the TR1, std::tr1::shared_ptr might be an alternative.