reset hex
This commit is contained in:
parent
3e525f0d45
commit
74b250439b
@ -105,7 +105,6 @@ function animations(props) {
|
||||
};
|
||||
|
||||
const combatAnim = anim(event.skill);
|
||||
console.log(combatAnim);
|
||||
if (combatAnim) {
|
||||
return (
|
||||
<div class={`combat-anim`}>
|
||||
|
||||
@ -32,26 +32,18 @@ class Hex extends Component {
|
||||
anime({
|
||||
targets: ['.hex-anim polygon'],
|
||||
points: '64 124.94732621931382 8.574 96.00354944613788 8.62269130211947 32.03166105954991 64 4 119.37730869788052 32.03166105954991 119.426 96.00354944613788',
|
||||
direction: 'alternate',
|
||||
easing: 'easeOutExpo',
|
||||
duration: TIMES.START_SKILL,
|
||||
complete: anim => anim.reset(),
|
||||
});
|
||||
|
||||
anime({
|
||||
targets: ['feTurbulence', 'feDisplacementMap'],
|
||||
baseFrequency: 0,
|
||||
scale: 1,
|
||||
direction: 'alternate',
|
||||
easing: 'easeOutSine',
|
||||
duration: TIMES.START_SKILL,
|
||||
});
|
||||
}
|
||||
|
||||
// reset hexagon
|
||||
componentWillUnmount() {
|
||||
anime.set({
|
||||
targets: ['.hex-anim polygon'],
|
||||
points: '64 124.94732621931382 8.574 96.00354944613788 8.62269130211947 32.03166105954991 64 4 119.37730869788052 32.03166105954991 119.426 96.00354944613788',
|
||||
complete: anim => anim.reset(),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user