diff options
author | Stijn Buys <ingar@osirion.org> | 2008-09-10 19:17:52 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2008-09-10 19:17:52 +0000 |
commit | 83fb219e62113a9f41888af4f2726e5ce5305970 (patch) | |
tree | 3ba9780192fc7aa7d1fe7988b30a85c5ba08d422 /src/client | |
parent | 033bd59cfc2dff93529ad448459ad6348ea29c8d (diff) |
serverside entities
Diffstat (limited to 'src/client')
-rw-r--r-- | src/client/targets.cc | 4 | ||||
-rw-r--r-- | src/client/view.cc | 7 |
2 files changed, 8 insertions, 3 deletions
diff --git a/src/client/targets.cc b/src/client/targets.cc index 7e852ad..a18392f 100644 --- a/src/client/targets.cc +++ b/src/client/targets.cc @@ -40,7 +40,9 @@ core::Cvar *snd_engines = 0; bool is_legal_target(core::Entity *entity) { - if (entity->id() == core::localcontrol()->id()) { + if (entity->serverside()) { + return false; + } else if (entity->id() == core::localcontrol()->id()) { return false; } else if (entity->state()->distance() < 0.001f) { return false; diff --git a/src/client/view.cc b/src/client/view.cc index 32f2971..8cf1af9 100644 --- a/src/client/view.cc +++ b/src/client/view.cc @@ -204,8 +204,11 @@ void draw_entity_offscreen_target(core::Entity *entity, bool is_active_target) } const float r = 16; - cx = (0.5f - cx) * (float) video::width; - cy = (0.5f - cy) * (float)video::height; + const float margin = 24; + cx = (0.5f - cx) * ((float) video::width - margin*2); + cx += margin; + cy = (0.5f - cy) * ((float)video::height - margin*2); + cy += margin; render::gl::disable(GL_TEXTURE_2D); render::gl::color(0, 0, 0, 1); |