a quickfix in the morning
This commit is contained in:
parent
70b0fee526
commit
03a271c731
8 changed files with 64 additions and 54 deletions
|
|
@ -574,7 +574,7 @@ void RendererPolygon3d::renderMissiles() {
|
|||
glm::mat4 model = computeModelMatrix(ship);
|
||||
glUniformMatrix4fv(m_shader_game_objects.location("model"), 1, GL_FALSE, glm::value_ptr(model));
|
||||
|
||||
glm::vec3 c = glm::vec3(0.1, 1.0, 0.2);
|
||||
glm::vec3 c = ship->color;
|
||||
glUniform3f(m_shader_game_objects.location("materialColor"), c.x, c.y, c.z);
|
||||
|
||||
m_shipModel->render();
|
||||
|
|
@ -673,7 +673,8 @@ void RendererPolygon3d::renderMissiles() {
|
|||
fade_out = 1.0 - (trace->age / trace->maxAge);
|
||||
}
|
||||
|
||||
glColor3f(0.0, 0.5*fade_out, 0.5*fade_out);
|
||||
glLineWidth(3);
|
||||
glColor4f(trace->player->color.x, trace->player->color.y, trace->player->color.z, fade_out);
|
||||
glBegin(GL_LINE_STRIP);
|
||||
for (const game::Trace::TracePoint &tp : trace->points) {
|
||||
glVertex2f(tp.position.x, tp.position.y);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue