Skip to content

Commit

Permalink
Fade out sounds. Bonus allows 2 seconds.
Browse files Browse the repository at this point in the history
  • Loading branch information
ranbo committed May 30, 2024
1 parent 7395288 commit baf52ba
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion adam/adam.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ function clickAdam(event, lineIndex, pieceIndex, displayTime, wasHover) {
explodeAdam(event.x, event.y, $clickedAdam, lineIndex, pieceIndex);
let soundIndex = wasHover ? 0 : 1;
let elapsedTime = Date.now() - displayTime;
let bonusRate = Math.max((1000 - elapsedTime) / 1000, 0);
let bonusRate = Math.max((2000 - elapsedTime) / 2000, 0);
bonusRate = bonusRate * bonusRate;
let piece = lines[lineIndex].pieces[pieceIndex];
let isIsabel = piece.who === "Isabel";
Expand Down
Binary file modified adam/sounds/JPop.mp3
Binary file not shown.
Binary file modified adam/sounds/bup.mp3
Binary file not shown.
Binary file modified adam/sounds/tiny-pop.mp3
Binary file not shown.

0 comments on commit baf52ba

Please sign in to comment.