This commit is contained in:
awesomeuser 2023-07-07 20:16:43 +00:00
parent 916057c4b9
commit 4d2f773dd2

View file

@ -81,14 +81,8 @@
<script>
var header = document.getElementById("header");
var prevTimestamp = 0;
async function update(timestamp) {
// get dt
let dt = (timestamp - prevTimestamp);
prevTimestamp = timestamp;
header.style.transform = "translate(50px, 100px)";
header.style.transform = "translate(" + (Math.cos(timestamp) * 20) + "px, " + (Math.sin(timestamp) * 20) + "px)";
// loop
requestAnimationFrame(update);