- fixed: FMultiPatchTexture::MakeTexture was missing a range check for the
special colormap index. SVN r1928 (trunk)
This commit is contained in:
parent
dcd4c7fe7a
commit
8390184839
5 changed files with 20 additions and 2 deletions
|
|
@ -320,7 +320,7 @@ FTextureID FTextureManager::AddTexture (FTexture *texture)
|
|||
int trans = Textures.Push (hasher);
|
||||
Translation.Push (trans);
|
||||
if (bucket >= 0) HashFirst[bucket] = trans;
|
||||
return FTextureID(trans);
|
||||
return (texture->id = FTextureID(trans));
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
|
@ -365,10 +365,15 @@ void FTextureManager::ReplaceTexture (FTextureID picnum, FTexture *newtexture, b
|
|||
newtexture->UseType = oldtexture->UseType;
|
||||
Textures[index].Texture = newtexture;
|
||||
|
||||
newtexture->id = oldtexture->id;
|
||||
if (free)
|
||||
{
|
||||
delete oldtexture;
|
||||
}
|
||||
else
|
||||
{
|
||||
oldtexture->id.SetInvalid();
|
||||
}
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue