Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/render/draw.cc')
-rw-r--r--src/render/draw.cc11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/render/draw.cc b/src/render/draw.cc
index 9c5a0d0..415a56c 100644
--- a/src/render/draw.cc
+++ b/src/render/draw.cc
@@ -855,8 +855,11 @@ void draw_pass_model_fx(float elapsed)
// draw model engines for Controlable entities
if ((entity->type() == core::Entity::Controlable) && entity->model()->engines().size()) {
-
- u = static_cast<core::EntityControlable *>(entity)->thrust();
+ core::EntityControlable *ec = static_cast<core::EntityControlable *>(entity);
+ u = ec->thrust();
+ if ((ec->eventstate() == core::Entity::ImpulseInitiate) || (ec->eventstate() == core::Entity::Impulse)) {
+ u = 1;
+ }
if (u > 0) {
t = entity->state()->state_engine_trail_offset;
@@ -901,14 +904,14 @@ void draw_pass_model_fx(float elapsed)
Stats::quads++;
}
- if (!engine->notrail()) {
+ if (!(engine->notrail() || (ec->eventstate() == core::Entity::Impulse))) {
// draw the engine trail
if (current_texture != circle_texture) {
gl::end();
current_texture = Textures::bind(circle_texture);
gl::begin(gl::Quads);
}
- color.assign(1.0f, 1.0f);
+ color.assign(1.0f, 1.0f);
offset.assign(entity->state()->axis().forward() * engine_size);
if (t > 0)