Skip to content

Commit

Permalink
Fix debug compile error
Browse files Browse the repository at this point in the history
  • Loading branch information
xezon committed Aug 11, 2024
1 parent bd8781e commit 7789c53
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/game/client/w3dassetmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,8 @@ TextureClass *GameAssetManager::Recolor_Texture_One_Time(TextureClass *texture,
char buffer[512];
Create_Color_Texture_Name(buffer, name, color);
new_texture->Set_Texture_Name(buffer);
captainslog_dbgassert(!m_textureHash.Exists(new_texture), "Texture hash collision occurred"); // Thyme specific
captainslog_dbgassert(
!m_textureHash.Exists(new_texture->Get_Name()), "Texture hash collision occurred"); // Thyme specific
m_textureHash.Insert(new_texture->Get_Name(), new_texture);
new_texture->Add_Ref();
Ref_Ptr_Release(surface);
Expand Down
3 changes: 2 additions & 1 deletion src/w3d/renderer/assetmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,8 @@ TextureClass *W3DAssetManager::Get_Texture(const char *filename,
return nullptr;
}

captainslog_dbgassert(!m_textureHash.Exists(new_texture), "Texture hash collision occurred"); // Thyme specific
captainslog_dbgassert(
!m_textureHash.Exists(new_texture->Get_Name()), "Texture hash collision occurred"); // Thyme specific
m_textureHash.Insert(new_texture->Get_Name(), new_texture);
}

Expand Down

0 comments on commit 7789c53

Please sign in to comment.