moved Color to Defines.h

This commit is contained in:
2023-01-02 12:21:27 +01:00
parent 386ea5b6ad
commit 7d30017742
6 changed files with 27 additions and 20 deletions

View File

@@ -20,7 +20,7 @@ WorldClient::WorldClient(ClientGame* game) : game::World(game), protocol::Packet
void WorldClient::HandlePacket(const protocol::WorldBeginDataPacket* packet) {
LoadMap(packet);
if (m_Game->GetGameState() == game::GameState::Game) {
const game::Color& backgroundColor = GetBackgroundColor();
const Color& backgroundColor = GetBackgroundColor();
m_Game->GetRenderer()->SetBackgroundColor({ static_cast<float>(backgroundColor.r / 255.0f), static_cast<float>(backgroundColor.g / 255.0f),
static_cast<float>(backgroundColor.b / 255.0f) });
}