I am trying to "delete" / kill my entities if they are going outside of the "playzone" or atleast what is visible to the user. I dont get any errors, but when i tried this code sample in the function "killEdgeEntities" and started the game, Everything would be dead already, as if the "if statements" executed directly. And no, i am not spawning anything outside of the arguments. For example, the users Ship is spawned in the middle of the screen. 

If you guys need any more info, just comment about it.

```
void Invaders::killEdgeEntities() {
EntityVector entities;
for (EntityVector::iterator j = mEntities.begin(); j != mEntities.end(); j++) {
    Entity *entity = *j;
    //  * Dödsgränser *
    // Vänster: 
    if (entity->getPosition().getX() < -20) {
        delete entity;
    }
    // Höger: 
    if (entity->getPosition().getX() > VGCDisplay::getWidth() + 20) {
        delete entity;
    }
    // Upp: 
    if (entity->getPosition().getY() < -80) {
        delete entity;
    }
    // Ner: 
    if (entity->getPosition().getY() >  VGCDisplay::getHeight() + 20) {
        delete entity;
    }

}
mEntities = entities;
}

```