diff --git a/Minecraft.Client/Textures/Texture.cpp b/Minecraft.Client/Textures/Texture.cpp index 7b568f402..098642d83 100644 --- a/Minecraft.Client/Textures/Texture.cpp +++ b/Minecraft.Client/Textures/Texture.cpp @@ -224,10 +224,10 @@ void Texture::fill(const Rect2i *rect, int color) int line = y * width * 4; for (int x = myRect->getX(); x < (myRect->getX() + myRect->getWidth()); x++) { - data[0]->put(line + x * 4 + 0, (BYTE)((color >> 24) & 0x000000ff)); - data[0]->put(line + x * 4 + 1, (BYTE)((color >> 16) & 0x000000ff)); - data[0]->put(line + x * 4 + 2, (BYTE)((color >> 8) & 0x000000ff)); - data[0]->put(line + x * 4 + 3, (BYTE)((color >> 0) & 0x000000ff)); + data[0]->put(line + x * 4 + 0, static_cast((color >> 24) & 0x000000ff)); + data[0]->put(line + x * 4 + 1, static_cast((color >> 16) & 0x000000ff)); + data[0]->put(line + x * 4 + 2, static_cast((color >> 8) & 0x000000ff)); + data[0]->put(line + x * 4 + 3, static_cast((color >> 0) & 0x000000ff)); } } delete myRect;