Does anyone know how to calculate the coordinates of the rectangle/square box on the surface of the circle?
I can get the center of the rectangle and draw a line through it but trying to get the coordinates.
var lineHeight = 25;
var baseX = circle.x + circleRadius/2 * Math.cos(angleRadians);
var baseY = circle.y + circleRadius/2 * Math.sin(angleRadians);
var x1 = baseX + lineHeight*Math.cos(angleRadians);
var y1 = baseY + lineHeight*Math.sin(angleRadians);
this.testgraphics = this.add.graphics();
this.testgraphics.lineStyle(4, 0xff0000);
this.testgraphics.beginPath();
this.testgraphics.moveTo(baseX, baseY);
this.testgraphics.lineTo(x1, y1);
this.testgraphics.closePath();
this.testgraphics.strokePath();
