Reuse same tween for monster shaking
authorMegaBrutal <code+git@megabrutal.com>
Fri, 29 Dec 2017 23:25:00 +0000 (00:25 +0100)
committerMegaBrutal <code+git@megabrutal.com>
Fri, 29 Dec 2017 23:25:00 +0000 (00:25 +0100)
Now one tween is created and reused to shake a monster when it is
damaged. As a side-effect, the amplitude of shaking is now constant
while it was random in the previous commit.

I decided to use one tween for a monster to avoid creating a memory
leak by leaving unused tweens in memory.

modified:   ld40.js


No differences found