- reworking some lower level texture code.

This commit is contained in:
Christoph Oelckers 2020-04-14 20:45:26 +02:00
commit 9099bc8420
21 changed files with 76 additions and 61 deletions

View file

@ -148,8 +148,8 @@ FTexture::FTexture (const char *name, int lumpnum)
FTexture::~FTexture ()
{
FTexture *link = fileSystem.GetLinkedTexture(SourceLump);
if (link == this) fileSystem.SetLinkedTexture(SourceLump, nullptr);
FGameTexture *link = fileSystem.GetLinkedTexture(SourceLump);
if (link->GetTexture() == this) fileSystem.SetLinkedTexture(SourceLump, nullptr);
if (areas != nullptr) delete[] areas;
areas = nullptr;