scatter -> link
This commit is contained in:
@@ -103,7 +103,7 @@ const SKILLS = [
|
||||
'ReflectI',
|
||||
'RestrictI',
|
||||
'RuinI',
|
||||
'ScatterI',
|
||||
'LinkI',
|
||||
'SilenceI',
|
||||
'SiphonI',
|
||||
'SiphonTickI',
|
||||
|
||||
@@ -27,7 +27,7 @@ const Purify = require('./anims/purify');
|
||||
const Recharge = require('./anims/recharge');
|
||||
const Refl = require('./anims/reflect');
|
||||
const Restrict = require('./anims/restrict');
|
||||
const Scatter = require('./anims/scatter');
|
||||
const Link = require('./anims/link');
|
||||
const Siphon = require('./anims/siphon');
|
||||
const SiphonTick = require('./anims/siphon.tick');
|
||||
const Slay = require('./anims/slay');
|
||||
@@ -123,7 +123,7 @@ function animations(props) {
|
||||
case 'Haste': return <Haste />;
|
||||
case 'Triage': return <Triage />;
|
||||
case 'TriageTick': return <TriageTick />;
|
||||
case 'Scatter': return <Scatter player={player} />;
|
||||
case 'Link': return <Link player={player} />;
|
||||
case 'Hybrid': return <Hybrid />;
|
||||
case 'Intercept': return <Intercept player={player} />;
|
||||
|
||||
|
||||
@@ -1,77 +0,0 @@
|
||||
const preact = require('preact');
|
||||
const { Component } = require('preact');
|
||||
|
||||
const anime = require('animejs').default;
|
||||
|
||||
const { TIMES } = require('../../constants');
|
||||
|
||||
class Scatter extends Component {
|
||||
constructor() {
|
||||
super();
|
||||
this.animations = [];
|
||||
}
|
||||
|
||||
render() {
|
||||
return (
|
||||
<svg
|
||||
class='skill-animation blue'
|
||||
version="1.1"
|
||||
id="scatter"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 128 128">
|
||||
<defs>
|
||||
<filter id="scatterFilter">
|
||||
<feGaussianBlur in="SourceGraphic" stdDeviation="5" />
|
||||
<feMerge>
|
||||
<feMergeNode />
|
||||
<feMergeNode in="SourceGraphic" />
|
||||
</feMerge>
|
||||
</filter>
|
||||
</defs>
|
||||
<g class='blue' filter='url(#scatterFilter)' stroke-width="4px" stroke-linecap="round" >
|
||||
<path d= "
|
||||
M 4 4
|
||||
h 30
|
||||
q 30 0 30 30
|
||||
q 0 30 30 30
|
||||
h 30
|
||||
q 0 -30 -30 -30
|
||||
h -60
|
||||
q -30 0 -30 -30
|
||||
"/>
|
||||
</g>
|
||||
</svg>
|
||||
);
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.animations.push(anime({
|
||||
targets: ['#scatter'],
|
||||
opacity: [
|
||||
{ value: 1, delay: TIMES.TARGET_DELAY_MS, duration: 1000 },
|
||||
// { value: 0, delay: TIMES.TARGET_DURATION_MS * 0.6, duration: TIMES.TARGET_DURATION_MS * 0.2 },
|
||||
],
|
||||
easing: 'easeInOutSine',
|
||||
}));
|
||||
|
||||
anime({
|
||||
targets: ['#scatter path'],
|
||||
strokeDashoffset: [anime.setDashoffset, 0],
|
||||
duration: TIMES.TARGET_DURATION_MS * 0.8,
|
||||
delay: TIMES.TARGET_DELAY_MS,
|
||||
easing: 'easeInOutSine',
|
||||
});
|
||||
}
|
||||
|
||||
// this is necessary because
|
||||
// skipping / timing / unmounting race conditions
|
||||
// can cause the animations to cut short, this will ensure the values are reset
|
||||
// because preact will recycle all these components
|
||||
componentWillUnmount() {
|
||||
for (let i = this.animations.length - 1; i >= 0; i--) {
|
||||
this.animations[i].reset();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Scatter;
|
||||
@@ -1823,7 +1823,7 @@ function testInstance(uuid) {
|
||||
"cd": null
|
||||
},
|
||||
{
|
||||
"skill": "Scatter",
|
||||
"skill": "Link",
|
||||
"self_targeting": false,
|
||||
"cd": 2
|
||||
},
|
||||
@@ -4300,7 +4300,7 @@ function testInstance(uuid) {
|
||||
"cd": null
|
||||
},
|
||||
{
|
||||
"skill": "Scatter",
|
||||
"skill": "Link",
|
||||
"self_targeting": false,
|
||||
"cd": 2
|
||||
}
|
||||
|
||||
@@ -353,7 +353,7 @@ const removeTier = skill => {
|
||||
|
||||
if (skill.includes('Intercept')) return 'Intercept';
|
||||
if (skill.includes('Triage')) return 'Triage';
|
||||
if (skill.includes('Scatter')) return 'Scatter';
|
||||
if (skill.includes('Link')) return 'Link';
|
||||
if (skill.includes('Haste')) return 'Haste';
|
||||
if (skill.includes('Hybrid')) return 'Hybrid';
|
||||
if (skill.includes('Amplify')) return 'Amplify';
|
||||
|
||||
Reference in New Issue
Block a user