mirror of
https://github.com/glest/glest-source.git
synced 2025-02-25 12:12:25 +01:00
make transition to new command less choppy
This commit is contained in:
parent
f2e497f855
commit
fdb2b65bf7
@ -1535,11 +1535,6 @@ void Unit::updateTimedParticles() {
|
||||
bool Unit::update() {
|
||||
assert(progress <= 1.f);
|
||||
|
||||
if(changedActiveCommand) {
|
||||
changedActiveCommand = false;
|
||||
return true;
|
||||
}
|
||||
|
||||
//highlight
|
||||
if(highlight > 0.f) {
|
||||
const Game *game = Renderer::getInstance().getGame();
|
||||
@ -1817,6 +1812,15 @@ bool Unit::update() {
|
||||
}
|
||||
}
|
||||
|
||||
if(changedActiveCommand) {
|
||||
changedActiveCommand = false;
|
||||
highlight = 0.0f;
|
||||
lastAnimProgress = 0.0f;
|
||||
animProgress = 0.0f;
|
||||
progress = 0.0f;
|
||||
return_value = true;
|
||||
}
|
||||
|
||||
return return_value;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user