mirror of
https://github.com/celisej567/mcpe.git
synced 2026-09-17 20:10:23 +03:00
Misc patches
This commit is contained in:
@@ -19,11 +19,17 @@ int Textures::loadTexture(const std::string& name, bool bIsRequired)
|
||||
|
||||
Texture t = m_pPlatform->loadTexture(name, bIsRequired);
|
||||
|
||||
int result = -1;
|
||||
if (t.m_pixels)
|
||||
result = assignTexture(name, t);
|
||||
|
||||
return result;
|
||||
if (!t.m_pixels)
|
||||
{
|
||||
t.field_C = 1;
|
||||
t.field_D = 0;
|
||||
t.m_width = 2;
|
||||
t.m_height = 2;
|
||||
t.m_pixels = new uint32_t[t.m_width * t.m_height];
|
||||
t.m_pixels[0] = t.m_pixels[2] = 0xfff800f8;
|
||||
t.m_pixels[1] = t.m_pixels[3] = 0xff000000;
|
||||
}
|
||||
return assignTexture(name, t);
|
||||
}
|
||||
|
||||
int Textures::assignTexture(const std::string& name, Texture& texture)
|
||||
|
||||
Reference in New Issue
Block a user