You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
88 lines
2.2 KiB
88 lines
2.2 KiB
|
4 days ago
|
const animation = (kind, duration = 350) => ({
|
||
|
|
kind,
|
||
|
|
duration,
|
||
|
|
easing: 'ease-out',
|
||
|
|
});
|
||
|
|
const finish = {
|
||
|
|
start: animation('reveal', 500),
|
||
|
|
win: animation('celebrate', 900),
|
||
|
|
loss: animation('fade', 400),
|
||
|
|
draw: animation('reveal', 400),
|
||
|
|
finish: animation('celebrate', 900),
|
||
|
|
};
|
||
|
|
export const gameAnimations = {
|
||
|
|
ajedrez: {
|
||
|
|
...finish,
|
||
|
|
move: animation('slide', 300),
|
||
|
|
capture: animation('capture', 350),
|
||
|
|
check: animation('pulse', 650),
|
||
|
|
promotion: animation('reveal', 450),
|
||
|
|
},
|
||
|
|
damas: {
|
||
|
|
...finish,
|
||
|
|
move: animation('slide', 320),
|
||
|
|
capture: animation('jump', 400),
|
||
|
|
promotion: animation('reveal', 450),
|
||
|
|
},
|
||
|
|
parchis: {
|
||
|
|
...finish,
|
||
|
|
roll: animation('cup', 800),
|
||
|
|
shake: animation('shake', 180),
|
||
|
|
move: animation('path', 600),
|
||
|
|
capture: animation('capture', 600),
|
||
|
|
goal: animation('celebrate', 700),
|
||
|
|
pass: animation('fade', 250),
|
||
|
|
},
|
||
|
|
go: {
|
||
|
|
...finish,
|
||
|
|
move: animation('place', 240),
|
||
|
|
capture: animation('capture', 400),
|
||
|
|
pass: animation('fade', 200),
|
||
|
|
mark: animation('pulse', 300),
|
||
|
|
'accept-score': animation('reveal', 300),
|
||
|
|
},
|
||
|
|
oca: {
|
||
|
|
...finish,
|
||
|
|
roll: animation('cup', 800),
|
||
|
|
shake: animation('shake', 180),
|
||
|
|
move: animation('path', 700),
|
||
|
|
bonus: animation('jump', 650),
|
||
|
|
penalty: animation('shake', 450),
|
||
|
|
goal: animation('celebrate', 700),
|
||
|
|
},
|
||
|
|
monopoli: {
|
||
|
|
...finish,
|
||
|
|
roll: animation('cup', 800),
|
||
|
|
move: animation('path', 650),
|
||
|
|
buy: animation('reveal', 400),
|
||
|
|
payment: animation('transfer', 450),
|
||
|
|
build: animation('place', 300),
|
||
|
|
},
|
||
|
|
cluedo: {
|
||
|
|
...finish,
|
||
|
|
roll: animation('cup', 800),
|
||
|
|
move: animation('slide', 500),
|
||
|
|
suggestion: animation('pulse', 500),
|
||
|
|
reveal: animation('flip', 450),
|
||
|
|
accusation: animation('reveal', 650),
|
||
|
|
},
|
||
|
|
risk: {
|
||
|
|
...finish,
|
||
|
|
reinforce: animation('place', 250),
|
||
|
|
attack: animation('shake', 500),
|
||
|
|
conquest: animation('reveal', 650),
|
||
|
|
move: animation('transfer', 450),
|
||
|
|
},
|
||
|
|
tute: {
|
||
|
|
...finish,
|
||
|
|
play: animation('flip', 350),
|
||
|
|
trick: animation('transfer', 500),
|
||
|
|
sing: animation('reveal', 600),
|
||
|
|
},
|
||
|
|
brisca: {
|
||
|
|
...finish,
|
||
|
|
play: animation('flip', 350),
|
||
|
|
trick: animation('transfer', 500),
|
||
|
|
},
|
||
|
|
};
|