diff options
Diffstat (limited to 'src/render')
-rw-r--r-- | src/render/draw.cc | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/src/render/draw.cc b/src/render/draw.cc index 18234f5..af19abe 100644 --- a/src/render/draw.cc +++ b/src/render/draw.cc @@ -150,6 +150,15 @@ void pass_prepare(float seconds) globes_list[globe->state()->distance()] = globe; + // load globe textures + if (!globe->render_texture && globe->texture().size()) { + std::stringstream texname; + texname << "textures/" << globe->texture(); + globe->render_texture = Textures::load(texname.str()); + if (!globe->render_texture) + globe->entity_texture.clear(); + } + if (flag_is_set(globe->flags(), core::Entity::Bright)) { // bright globes set level light @@ -170,16 +179,6 @@ void pass_prepare(float seconds) glLightfv(GL_LIGHT1, GL_SPECULAR, specular_light); gl::enable(GL_LIGHT1); has_zone_light = true; - } else { - - // load globe textures - if (!globe->render_texture && globe->texture().size()) { - std::stringstream texname; - texname << "textures/" << globe->texture(); - globe->render_texture = Textures::load(texname.str()); - if (!globe->render_texture) - globe->entity_texture.clear(); - } } } } |