From abb75acb91ee18b56c3146203d27079eae968bf0 Mon Sep 17 00:00:00 2001 From: gmueller Date: Tue, 4 Jan 2011 22:26:37 +0100 Subject: [PATCH] fix colors --- src/main.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index c7fb8be..4c8afec 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -67,9 +67,9 @@ void setup_opengl() { } void setup_team(team *team, size_t id) { - team->color[0] = 1.0f * (id + 1 & (1 << 0)); - team->color[1] = 1.0f * (id + 1 & (1 << 1)); - team->color[2] = 1.0f * (id + 1 & (1 << 2)); + team->color[0] = .5f + .5f * (id & (1 << 0)); + team->color[1] = .5f + .5f * (id & (1 << 1)); + team->color[2] = .5f + .5f * (id & (1 << 2)); team->color[3] = 1.0f; team->x = 2000.0 * (id & (1 << 0)); @@ -86,7 +86,6 @@ void setup_team(team *team, size_t id) { team->players[i].vy = i * 5.; team->players[i].vz = i * 5.; } - } void update_team(team *team, double dt) {