2025-09-09 18:23:55 +03:00
|
|
|
import { audioPath } from './path.js'
|
2025-06-11 09:36:54 +03:00
|
|
|
let pipe = document.getElementById("meow");
|
2025-06-16 16:31:53 +03:00
|
|
|
let preload = new Image();
|
|
|
|
preload.src = "/assets/img/button/braixdragon-cat2.gif";
|
|
|
|
|
2025-06-11 09:36:54 +03:00
|
|
|
pipe.addEventListener("mouseover", func, true);
|
2025-06-16 16:31:53 +03:00
|
|
|
|
2025-06-11 09:36:54 +03:00
|
|
|
function func() {
|
2025-06-16 16:31:53 +03:00
|
|
|
pipe.src = preload.src;
|
2025-06-11 09:36:54 +03:00
|
|
|
}
|
2025-06-16 16:31:53 +03:00
|
|
|
|
2025-06-11 09:36:54 +03:00
|
|
|
let audio = document.createElement("audio");
|
2025-09-09 18:23:55 +03:00
|
|
|
audio.src = `${audioPath}anvil_land_low.ogg`;
|
2025-06-16 16:31:53 +03:00
|
|
|
pipe.appendChild(audio);
|
|
|
|
|
|
|
|
pipe.addEventListener(
|
|
|
|
"mouseover",
|
|
|
|
function () {
|
|
|
|
setTimeout(() => {
|
|
|
|
audio.play();
|
|
|
|
}, 1700);
|
|
|
|
},
|
|
|
|
{ once: true }
|
|
|
|
);
|