This commit is contained in:
MCHost
2025-07-06 21:55:54 -04:00
parent ab5b0194eb
commit cdd69bd19b
3 changed files with 3 additions and 212 deletions

View File

@@ -80,23 +80,6 @@ if (window.location.href === 'https://my-mc.link' || window.location.href === 'h
}
}
const tiltCards = document.querySelectorAll('.tilt-card');
tiltCards.forEach(card => {
card.addEventListener('mousemove', (e) => {
const rect = card.getBoundingClientRect();
const x = e.clientX - rect.left;
const y = e.clientY - rect.top;
const centerX = rect.width / 2;
const centerY = rect.height / 2;
const tiltX = (y - centerY) / 12;
const tiltY = (centerX - x) / 12;
card.style.transform = `perspective(1200px) rotateX(${tiltX}deg) rotateY(${tiltY}deg)`;
});
card.addEventListener('mouseleave', () => {
card.style.transform = 'perspective(1200px) rotateX(0) rotateY(0)';
});
});
const buttons = document.querySelectorAll('.btn-minecraft');
buttons.forEach(button => {
button.addEventListener('mousemove', (e) => {