IamThatGuy Posted February 2, 2015 Share Posted February 2, 2015 So I been playing around with this experiment and I am starting to realize how important math is for games. =] A snipplet, I didnt include varscontext.beginPath();context.arc(centerX, centerY, radius, 0, 2 * Math.PI, false);context.fillStyle = 'green';context.fill();context.lineWidth = 3;context.strokeStyle = 'yellow';context.stroke(); context.closePath(); context.beginPath();context.moveTo(centerX - radius, centerY);context.lineTo(centerX - 100, centerY);context.stroke();context.closePath(); context.beginPath();context.arc(centerX, centerY, 100, startAngle, endAngle, counterClockwise); context.lineWidth = 1; context.stroke();context.closePath();The outcome: Anyone know how if there is a built in function to get the Length of the arc and the last Point of the created Arc? If not, anyone know of a formula for such a thing =0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.