mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-11 15:22:16 +00:00
- changed last commit to let the replacement take the original's place and add the old texture at the end with its name cleared.
This is to ensure that this won't break ranged animations but aside from that should produce the same end result.
This commit is contained in:
parent
120b950291
commit
d140d767a4
1 changed files with 3 additions and 3 deletions
|
@ -468,10 +468,10 @@ void FTextureManager::ReplaceTexture (FTextureID picnum, FTexture *newtexture, b
|
||||||
|
|
||||||
newtexture->Name = oldtexture->Name;
|
newtexture->Name = oldtexture->Name;
|
||||||
newtexture->UseType = oldtexture->UseType;
|
newtexture->UseType = oldtexture->UseType;
|
||||||
// Add the new texture at the end of the texture list and clear the old one's name to ensure it won't be found anymore
|
Textures[index].Texture = newtexture;
|
||||||
// We cannot actually replace it because it may be referenced by some other texture.
|
newtexture->id = oldtexture->id;
|
||||||
oldtexture->Name = "";
|
oldtexture->Name = "";
|
||||||
AddTexture(newtexture);
|
AddTexture(oldtexture);
|
||||||
}
|
}
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
Loading…
Reference in a new issue