From 14ea3d9d037175d4d5326ac9c83fe69ddcd0d9c4 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Mon, 8 Oct 2012 19:58:08 +0000 Subject: added zone flags, renamed Entity::flag_is_set() to Entity::has_flag() --- src/render/draw.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/render') diff --git a/src/render/draw.cc b/src/render/draw.cc index fbc499f..88a08b9 100644 --- a/src/render/draw.cc +++ b/src/render/draw.cc @@ -110,9 +110,9 @@ void pass_prepare(float seconds) } // add zone lights - if (globe->flag_is_set(core::Entity::Bright)) { + if (globe->has_flag(core::Entity::Bright)) { Light *zone_light = new Light(globe->location(), globe->color()); - zone_light->set_attenuation(0.0005f, 0.0005f, 0.0f); + zone_light->set_attenuation(2.0f, 0.0f, 0.0f); lightenv_zone.add(zone_light); } @@ -292,7 +292,7 @@ void draw_pass_globes() gl::push(); gl::translate(location); - if (globe->flag_is_set(core::Entity::Bright)) { + if (globe->has_flag(core::Entity::Bright)) { gl::disable(GL_LIGHTING); if (globe->corona_id()) { // draw globe corona @@ -322,7 +322,7 @@ void draw_pass_globes() gl::disable(GL_TEXTURE_2D); } - if (globe->flag_is_set(core::Entity::Bright)) { + if (globe->has_flag(core::Entity::Bright)) { gl::enable(GL_LIGHTING); } @@ -500,7 +500,7 @@ void draw_pass_default() gl::translate(entity->location()); gl::multmatrix(entity->axis()); - if (entity->flag_is_set(core::Entity::Bright)) { + if (entity->has_flag(core::Entity::Bright)) { gl::disable(GL_LIGHTING); } @@ -524,7 +524,7 @@ void draw_pass_default() break; } - if (entity->flag_is_set(core::Entity::Bright)) { + if (entity->has_flag(core::Entity::Bright)) { gl::enable(GL_LIGHTING); } -- cgit v1.2.3