Game Development Community

1.1.1 t2dTileMap - deleteAllTileLayers

by Tomasz Chudy · in Torque Game Builder · 08/12/2006 (6:00 am) · 0 replies

Hi,

There is a problem with deleteAllTileLayers.
If I have more then one tilelayer I have error.
There is:

// Delete All Tile Layers.
while ( mTileLayerList.size() > 0 )
// Delete the Object.
mTileLayerList[0]->deleteObject();

I think it should be like this:

// Delete All Tile Layers.
while ( mTileLayerList.size() > 0 )
{
// Delete the Object.
mTileLayerList[0]->deleteObject();
mTileLayerList.pop_front ();
}

Best regards
Tomasz