- Unload behavior with the map, not outside.

This commit is contained in:
Christoph Oelckers 2019-01-31 17:43:12 +01:00
parent 68bff17d63
commit 1dcdfec733
2 changed files with 1 additions and 1 deletions

View file

@ -2952,7 +2952,6 @@ void MapLoader::LoadLevel(MapData *map, const char *lumpname, int position)
ForceNodeBuild = gennodes;
// [RH] Load in the BEHAVIOR lump
Level->Behaviors.UnloadModules();
if (map->HasBehavior)
{
LoadBehavior(map);

View file

@ -335,6 +335,7 @@ void FLevelLocals::ClearLevelData()
memset(playerstarts, 0, sizeof(playerstarts));
Scrolls.Clear();
if (automap) automap->Destroy();
Behaviors.UnloadModules();
}
//==========================================================================