Hi Jean - I'm struggling with the anglestring() function. This test code shows the problem. You can also see in the graphics. The string for the Moon's position, when at the 'noon' position, does not appear alongside the other positions. It seems that the radius element of the function might have a bug when planets are in this angular position. It might be me alternatively, but I can't see where the code is wrong.
anglestring
Syntax anglestring(int mx, int my, int angle, int radius, char string[$]);
Action: displays the string 'string' from middle mx, my at angle 'angle' and radius 'radius'.
-----------------------------------------------------------------------------------------------------------------------
window(0, 0);
menu(0, "Close", close);
real testAngle[9] = { 25, 270, 275, 265, 48, 110, 199, 230, 18};
int indexAngle[9], i, x, y;
char s[99];
@go;
run;
:go;
visible(0);
fill(0, 0, width, height, -2);
sortplanets(testAngle, indexAngle, 4, 0);
i = 0; for (i < 9){
putplanet(450, 500 + i * 20, i);
putrealnumber(500, 500 + i * 20, testAngle, 4);
putnumber(600, 500 + i * 20, indexAngle);
getcirclepos(width * .725 - width * .0025, height * .5 - width * .0025, height * .39, 180 - indexAngle, x, y);
putplanet(x, y, i);
` angle
strset(s, "%2a", testAngle);
` pushes string out of window
` anglestring(width * .725, height * .5, 180 - indexAngle, height * .45, s);}
` brings string into window
anglestring(width * .725, height * .5, 180 - indexAngle, height * .35, s);}
visible(1);
return;
:close;
quit;