summaryrefslogtreecommitdiff
path: root/src/gui/viewport.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/viewport.cpp')
-rw-r--r--src/gui/viewport.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gui/viewport.cpp b/src/gui/viewport.cpp
index b71e6530..10c4bc1a 100644
--- a/src/gui/viewport.cpp
+++ b/src/gui/viewport.cpp
@@ -266,12 +266,11 @@ void Viewport::shakeScreen(int intensity)
void Viewport::shakeScreen(float x, float y, float decay, unsigned duration)
{
- ShakeEffect effect;
+ ShakeEffect &effect = mShakeEffects.emplace_back();
effect.x = x;
effect.y = y;
effect.decay = decay;
effect.duration = duration;
- mShakeEffects.push_back(effect);
}
void Viewport::logic()