You are browsing as a guest. Sign up (or log in) to start making projects!

7h 56m 34s logged

Okay – Back from vacation… put a pretty hefty chunk of time in today! Forgot to do a halfway devlog again today, but I’ll make up for it later or tomorrow!

I added a live physics readout
And added the labels while making the gravity exclusive (like I said I would :D)

   ctx.font = "11px sans-serif";
ctx.fillStyle = "#ffffff";
ctx.textAlign = "center";
const label = `${ball.speed.toFixed(1)} m/s | ${ball.kinetic_energy.toFixed(1)} J`;
ctx.fillText(label, ball.x, ball.y - ball.radius - 6);
const line1 = `${ball.mass.toFixed(1)}kg @ ${ball.gravity.toFixed(1)}m/s²`;
const line2 = `${ball.speed.toFixed(1)} m/s | ${ball.kinetic_energy.toFixed(1)} J`;
ctx.fillText(line1, ball.x, ball.y - ball.radius - 18);
ctx.fillText(line2, ball.x, ball.y - ball.radius - 6);

}

if (dragStart && dragCurrent) {

some sample code for your liking..

no one commented on my last devlog, so if you have any ideas comment on this one.

I have a couple QoL upgrades i’m going to make but then ship.

Often feedback on my projects says that it doesn’t take the reviewer as long as it took me to code, and I completely understand that take, but personally, I am pretty new at coding, so I do take a lot of time debugging and understanding what I am coding, so just a little behind-the-scenes!

Oh yeah, also a sweet little speed indicator!

0
15

Comments 0

No comments yet. Be the first!